Form containing basic object selection list with "select", "remove", and "remove all" buttons. More...
#include <mgui/formfilelist.h>

Public Types | |
| enum | FLAGS { FLAG_Default = 0x0000, FLAG_SelectFolders = 0x0001 } |
Public Member Functions | |
| FORM_FILE_LIST () | |
| virtual | ~FORM_FILE_LIST () |
| void | Clear (bool notify) |
| ERRVALUE | Create (MGUI::LAYOUT_PANE_BASE &ParentPane, const MISTRING &promptstr, int ListHeight=5, MGUI::LAYOUT_SIZEALIGN sizealign=MGUI::LAYOUT_SIZEALIGN_Expand, FLAGS flags=FLAG_Default) |
| const FILEPATH & | GetCurrentFile () const |
| const FILEPATHLIST & | GetFileList () const |
| bool | IsEmpty () const |
| ERRVALUE | Select (bool notify) |
| void | SetDelegateOnFileAdded (FastDelegate< void(const FILEPATH &, INT32)> delegate) |
| void | SetDelegateOnFileRemoved (FastDelegate< void(INT32)> delegate) |
| void | SetDelegateOnFilesAdded (DELEGATE_VOID_NOPARMS delegate) |
| void | SetDelegateOnFilesAllRemoved (DELEGATE_VOID_NOPARMS delegate) |
| void | SetDelegateOnFileSelected (FastDelegate< void(const FILEPATH &, INT32)> delegate) |
| void | SetDelegateOnListChanged (DELEGATE_VOID_NOPARMS delegate) |
| void | SetValidExtensions (const char *extns) |
| ERRVALUE | SetValue (const FILEPATHLIST &PathList, bool notify) |
Protected Member Functions | |
| virtual void | v_OnFileAdded (const FILEPATH &Filepath, INT32 ItemNum) |
| virtual void | v_OnFileRemoved (INT32 ItemNum) |
| virtual void | v_OnFilesAdded () |
| virtual void | v_OnFilesAllRemoved () |
| virtual void | v_OnFileSelected (const FILEPATH &Filepath, INT32 ItemNum) |
| virtual void | v_OnListChanged () |
Form containing basic object selection list with "select", "remove", and "remove all" buttons.
| MGUI::FORM_FILE_LIST::FORM_FILE_LIST | ( | ) |
Constructor.
| virtual MGUI::FORM_FILE_LIST::~FORM_FILE_LIST | ( | ) | [virtual] |
Destructor.
| void MGUI::FORM_FILE_LIST::Clear | ( | bool | notify | ) |
Clears out all of the selected objects.
| notify | Send notifications via virtual methods |
| ERRVALUE MGUI::FORM_FILE_LIST::Create | ( | MGUI::LAYOUT_PANE_BASE & | ParentPane, | |
| const MISTRING & | promptstr, | |||
| int | ListHeight = 5, |
|||
| MGUI::LAYOUT_SIZEALIGN | sizealign = MGUI::LAYOUT_SIZEALIGN_Expand, |
|||
| FLAGS | flags = FLAG_Default | |||
| ) |
Create object list form.
| ParentPane | Parent pane | |
| promptstr | Prompt string to use with DlgGetObjects | |
| ListHeight | Initial list box height |
| const FILEPATH& MGUI::FORM_FILE_LIST::GetCurrentFile | ( | ) | const |
Get the current object, will return an empty OBJITEM if there is nothing in the list.
| const FILEPATHLIST& MGUI::FORM_FILE_LIST::GetFileList | ( | ) | const [inline] |
Get the list of objects in the list.
| bool MGUI::FORM_FILE_LIST::IsEmpty | ( | ) | const [inline] |
Is the list empty?
| ERRVALUE MGUI::FORM_FILE_LIST::Select | ( | bool | notify | ) |
Select objects via form.
Behaves same as when 'Select' button pressed.
| notify | Send notifications via virtual methods |
| void MGUI::FORM_FILE_LIST::SetDelegateOnFileAdded | ( | FastDelegate< void(const FILEPATH &, INT32)> | delegate | ) | [inline] |
Set delegate to call for each object added to list.
| delegate | Delegate parameters: object item, item index in list |
| void MGUI::FORM_FILE_LIST::SetDelegateOnFileRemoved | ( | FastDelegate< void(INT32)> | delegate | ) | [inline] |
Set delegate to call when single object removed from list.
| delegate | Delegate parameter: item index in list |
| void MGUI::FORM_FILE_LIST::SetDelegateOnFilesAdded | ( | DELEGATE_VOID_NOPARMS | delegate | ) | [inline] |
Set delegate to call when objects added to list.
| void MGUI::FORM_FILE_LIST::SetDelegateOnFilesAllRemoved | ( | DELEGATE_VOID_NOPARMS | delegate | ) | [inline] |
Set delegate to call when all objects removed from list.
| void MGUI::FORM_FILE_LIST::SetDelegateOnFileSelected | ( | FastDelegate< void(const FILEPATH &, INT32)> | delegate | ) | [inline] |
Set delegate to call when object selected (highlighted) in list.
| delegate | Delegate parameters: object item, item index in list |
| void MGUI::FORM_FILE_LIST::SetDelegateOnListChanged | ( | DELEGATE_VOID_NOPARMS | delegate | ) | [inline] |
Set delegate to call for any change to objects in list.
| void MGUI::FORM_FILE_LIST::SetValidExtensions | ( | const char * | extns | ) |
Set the valid file extensions.
String should contain the extension(s) without a dot. Multiple extensions can be seperated with a comma.
| ERRVALUE MGUI::FORM_FILE_LIST::SetValue | ( | const FILEPATHLIST & | PathList, | |
| bool | notify | |||
| ) |
Sets the current file list.
| PathList | List to set from | |
| notify | Send notifications via virtual methods |
| virtual void MGUI::FORM_FILE_LIST::v_OnFileAdded | ( | const FILEPATH & | Filepath, | |
| INT32 | ItemNum | |||
| ) | [protected, virtual] |
Called for each object added to list.
Default implementation invokes corresponding delegate. If override call when/if needed to invoke delegate.
| virtual void MGUI::FORM_FILE_LIST::v_OnFileRemoved | ( | INT32 | ItemNum | ) | [protected, virtual] |
Called when single object removed from list.
Default implementation invokes corresponding delegate. If override call when/if needed to invoke delegate.
| virtual void MGUI::FORM_FILE_LIST::v_OnFilesAdded | ( | ) | [protected, virtual] |
Called when objects added to list.
Default implementation invokes corresponding delegate. If override call when/if needed to invoke delegate.
| virtual void MGUI::FORM_FILE_LIST::v_OnFilesAllRemoved | ( | ) | [protected, virtual] |
Called when all objects removed from list.
Default implementation invokes corresponding delegate. If override call when/if needed to invoke delegate.
| virtual void MGUI::FORM_FILE_LIST::v_OnFileSelected | ( | const FILEPATH & | Filepath, | |
| INT32 | ItemNum | |||
| ) | [protected, virtual] |
Called when object selected (highlighted) from list.
Default implementation invokes corresponding delegate. If override call when/if needed to invoke delegate.
| virtual void MGUI::FORM_FILE_LIST::v_OnListChanged | ( | ) | [protected, virtual] |
Called for any change to objects in list.
Default implementation invokes corresponding delegate. If override call when/if needed to invoke delegate.
1.6.1