The '''FileBrowser''' component is used to show file lists of files on the user's PC in the [[userspace]] [[dash menu]].
== Fields ==
{{Table ComponentFields
{{Table ComponentFields
|SelectedItem|BrowserItem| The currently selected item being highlighted.
|SelectedItem|BrowserItem| The currently selected item being highlighted.
Line 15:
Line 17:
|_buttonsRoot|Slot| The root of the area being used to show the different button actions.
|_buttonsRoot|Slot| The root of the area being used to show the different button actions.
|_folderGrid|'''[[Component:GridLayout|GridLayout]]'''|TypeAdv7=true| The grid layout Component being used to align the folders in the directory.
|_folderGrid|'''[[Component:GridLayout|GridLayout]]'''|TypeAdv7=true| The grid layout Component being used to align the folders in the directory.
|_itemGrid|'''[[Component:GridLayout|GridLayout]]'''|TypeAdv8=true| The grid layout Component being used to align the files in the directory.
|_itemGrid|'''[[Component:GridLayout|GridLayout]]'''|TypeAdv8=true| The grid layout Component being used to align the files in the directory.
|_tabSprite|'''[[Component:SpriteProvider|SpriteProvider]]'''|TypeAdv9=true| The sprite being used to show the tab sprite.
|_tabSprite|'''[[Component:SpriteProvider|SpriteProvider]]'''|TypeAdv9=true| The sprite being used to show the tab sprite.
|_loadingIndicator|Slot| The slot that stores the loading indicator for a newly opened directory.
|_loadingIndicator|Slot| The slot that stores the loading indicator for a newly opened directory.
|_swapper|'''[[Component:SlideSwapRegion|SlideSwapRegion]]'''|TypeAdv11=true| The component to handle the slide animation when opening a different directory.
|_swapper|'''[[Component:SlideSwapRegion|SlideSwapRegion]]'''|TypeAdv11=true| The component to handle the slide animation when opening a different directory.
|_reloadButton|'''[[Component:Button|Button]]'''|TypeAdv18=true| The button used to refresh the folder and file list.
}}
== Sync Delegates ==
{{Table ComponentTriggers
|CreateDirectory:[[Component:BrowserCreateDirectoryDialog#CreateHandler|CreateHandler]]|[[Component:BrowserCreateDirectoryDialog#CreateHandler|CreateHandler]]|true| Called when a directory is created.
|RunImport:[[Type:ButtonEventHandler|ButtonEventHandler]]|[[Type:ButtonEventHandler|ButtonEventHandler]]|true| Called when an import needs to be made of a file.
|RunRawImport:[[Type:ButtonEventHandler|ButtonEventHandler]]|[[Type:ButtonEventHandler|ButtonEventHandler]]|true| Called when a raw file import needs to be made of a file.
|CreateNew:[[Type:ButtonEventHandler|ButtonEventHandler]]|[[Type:ButtonEventHandler|ButtonEventHandler]]|true| Called when a new item needs to be made.
|Reload:[[Type:ButtonEventHandler|ButtonEventHandler]]|[[Type:ButtonEventHandler|ButtonEventHandler]]|true| Called when a reload needs to be done.
|OnGoUp:[[Type:ButtonEventHandler|ButtonEventHandler]]<[[Type:Int|int]]>|[[Type:ButtonEventHandler|ButtonEventHandler]]<[[Type:Int|int]]>|true| Called when the user wants to go up in directories.
}}
}}
== Behavior ==
== CreateHandler ==
Handles creation of directories. Is a sync delegate type.
This is a userspace component — you cannot attach it anywhere but the userspace. Messing with the userspace can be fun, but it is not recommended as you risk messing your dash up if you don't know what you're doing.