62class Browser :
public QwertyUI {
67 virtual Error getCurrentFilePath(
String* path) = 0;
68 ActionResult buttonAction(deluge::hid::Button b,
bool on,
bool inCardRoutine)
override;
69 ActionResult padAction(int32_t x, int32_t y, int32_t velocity)
override;
70 ActionResult verticalEncoderAction(int32_t offset,
bool inCardRoutine)
override;
71 void currentFileDeleted();
72 Error goIntoFolder(
char const* folderName);
74 Error createFoldersRecursiveIfNotExists(
const char* path);
75 void selectEncoderAction(int8_t offset)
override;
76 static FileItem* getCurrentFileItem();
77 Error readFileItemsForFolder(
char const* filePrefixHere,
bool allowFolders,
char const** allowedFileExtensionsHere,
78 char const* filenameToStartAt, int32_t newMaxNumFileItems,
79 int32_t newCatalogSearchDirection = CATALOG_SEARCH_BOTH);
80 Error setFileByFullPath(OutputType outputType,
char const* fullPath);
83 static void emptyFileItems();
84 static void deleteSomeFileItems(int32_t startAt, int32_t stopAt);
85 static void deleteFolderAndDuplicateItems(Availability instrumentAvailabilityRequirement = Availability::ANY);
86 Error getUnusedSlot(OutputType outputType,
String* newName,
char const* thingName);
108 bool opened()
override;
109 void cullSomeFileItems();
116 static int32_t numFileItemsDeletedAtStart;
117 static int32_t numFileItemsDeletedAtEnd;
122 static String firstFileItemRemaining;
123 static String lastFileItemRemaining;
125 static OutputType outputTypeToLoad;
126 static char const* filenameToStartSearchAt;
131 return ActionResult::ACTIONED_AND_CAUSED_CHANGE;
133 bool isFavouritesVisible()
override;
134 bool isBanksVisible()
override;
137 Error setEnteredTextFromCurrentFilename();
138 Error goUpOneDirectoryLevel();
139 virtual Error arrivedInNewFolder(int32_t direction,
char const* filenameToStartAt =
nullptr,
140 char const* defaultDir =
nullptr);
141 bool predictExtendedText()
override;
142 void goIntoDeleteFileContextMenu();
143 ActionResult mainButtonAction(
bool on);
144 virtual void exitAction();
145 virtual ActionResult backButtonAction();
146 virtual void folderContentsReady(int32_t entryDirection) {}
147 virtual void currentFileChanged(int32_t movementDirection) {}
148 void displayText(
bool blinkImmediately =
false)
override;
150 void clampFileSelectionAndScroll(
bool allowNoFileSelection =
true);
151 static Slot getSlot(
char const* displayName);
155 Error readFileItemsFromFolderAndMemory(Song* song, OutputType outputType,
char const* filePrefixHere,
156 char const* filenameToStartAt,
char const* defaultDirToAlsoTry,
157 bool allowFoldersint,
158 Availability availabilityRequirement = Availability::ANY,
159 int32_t newCatalogSearchDirection = CATALOG_SEARCH_RIGHT);
160 void favouritesChanged();
162 static int32_t fileIndexSelected;
164 static int32_t scrollPosVertical;
167 static bool qwertyVisible;
168 static bool arrivedAtFileByTyping;
169 static bool allowFoldersSharingNameWithFile;
170 static char const** allowedFileExtensions;
172 const uint8_t* fileIcon;
173 const uint8_t* fileIconPt2;
174 int32_t fileIconPt2Width;
177 static int8_t numberEditPos;
178 static NumericLayerScrollingText* scrollingText;
179 bool shouldWrapFolderContents;
181 bool mayDefaultToBrandNewNameOnEntry;
182 bool qwertyAlwaysVisible;
184 char const* filePrefix;
185 bool shouldInterpretNoteNamesForThisBrowser;
static Error surveyNameVariations(char const *stem, String *highestNumbered, uint32_t *takenLetters)
Surveys currentDir in one pass for the existing variations of a name.
Definition browser.cpp:863