Reference TExplorerView
Declared in Codebot.Windows.Explorer.pas on line 108
TExplorerView hosts the Windows explorer browser, the folder view used by Windows Explorer and the file dialogs. Paths are file system paths or shell parsing names, and an empty path is the desktop
TExplorerView = class(TExplorerControl, IComponentBindingClient, IServiceProvider, ICommDlgBrowser, ICommDlgBrowser2, IExplorerBrowserEvents)
protected
procedure CreateWnd; override;
procedure DestroyWnd; override;
procedure Resize; override;
public
{ Create a new explorer view }
constructor Create(AOwner: TComponent); override;
destructor Destroy; override;
{ Show the previous folder in the history }
procedure GoBack;
{ Show the next folder in the history after going back }
procedure GoForward;
{ Show a folder of the history by its index }
procedure GoToHistory(Index: Integer);
{ Remove all folders from the history except the current one }
procedure ClearHistory;
{ Show the parent folder }
procedure GoUp;
{ Reload the items of the folder }
procedure Refresh; reintroduce;
{ Invoke a context menu verb on the selected items, or on the folder if no
items are selected }
procedure ExecuteVerb(const Verb: string);
{ Edit the name of the focused item }
procedure Rename;
{ Copy the selected items to the clipboard }
procedure Copy;
{ Cut the selected items to the clipboard }
procedure Cut;
{ Paste the clipboard into the folder }
procedure Paste;
{ Delete the selected items }
procedure Delete;
{ Show the properties of the selected items }
procedure Properties;
{ Create a new folder and edit its name }
procedure NewFolder;
{ Select an item of the folder by its path }
procedure Select(const ItemPath: string);
{ Select all the items }
procedure SelectAll;
{ Clear the selection }
procedure ClearSelection;
{ Get the paths of the selected or of all the items. With the voCheckBoxes
option the selected items are the checked items }
procedure GetItems(Strings: TStrings; Selection: Boolean = True);
{ Show the items whose names contain Text, searching Scope and its
subfolders. Text may hold the wildcards * and ?. When Scope is empty the
current folder is searched, or the folder of the previous search while
search results are shown. An empty Text returns to the folder searched.
Requires Windows 8 or later }
procedure Search(const Text: string; const Scope: string = '');
{ The explorer browser object, or nil if the window is not created }
property Browser: IExplorerBrowser read FBrowser;
{ There is a previous folder in the history }
property CanGoBack: Boolean read GetCanGoBack;
{ There is a next folder in the history }
property CanGoForward: Boolean read GetCanGoForward;
{ The paths of the folders shown, oldest first }
property History[Index: Integer]: string read GetHistory;
{ The number of folders in the history }
property HistoryCount: Integer read GetHistoryCount;
{ The index of the current folder in the history }
property HistoryIndex: Integer read FHistoryIndex;
{ Search results are shown }
property Searching: Boolean read FSearching;
{ The text of the search results shown }
property SearchText: string read FSearchText;
{ The path of the focused item, or an empty string if there is none }
property FocusedItem: string read GetFocusedItem;
{ The number of items in the folder }
property ItemCount: Integer read GetItemCount;
{ The number of selected items }
property SelectedCount: Integer read GetSelectedCount;
{ The shell view of the folder shown, or nil if there is none }
property ShellView: IShellView read GetShellView;
published
{ The columns of the details view by canonical property name, such as
System.ItemNameDisplay or System.Size, each optionally followed by =width
in pixels. When empty the folder chooses its columns }
property Columns: TStrings read FColumns write SetColumns;
{ Text shown when a folder has no items }
property EmptyText: string read FEmptyText write SetEmptyText;
{ File masks separated by semicolons, such as *.pas;*.lpk. Folders are
always shown. When empty all files are shown }
property Filter: string read FFilter write SetFilter;
{ The canonical name of the property the items are grouped by, such as
System.ItemTypeText. When empty the folder chooses its grouping }
property GroupBy: string read FGroupBy write SetGroupBy;
{ The size of the icons in pixels. When 0 the view mode chooses the size }
property IconSize: Integer read FIconSize write SetIconSize default 0;
{ The folder flags of the view }
property Options: TExplorerViewOptions read FOptions write SetOptions default [];
{ The folder shown }
property Path: string read GetPath write SetPath;
{ Show hidden and system files }
property ShowHidden: Boolean read FShowHidden write SetShowHidden default False;
{ The canonical name of the property the items are sorted by, such as
System.DateModified. When empty the folder chooses its sort order }
property SortColumn: string read FSortColumn write SetSortColumn;
{ Sort from the largest to the smallest value }
property SortDescending: Boolean read FSortDescending write SetSortDescending default False;
property ViewMode: TExplorerViewMode read FViewMode write SetViewMode default evDetails;
{ Invoked after the shell context menu of the view is closed }
property OnContextMenuClose: TNotifyEvent read FOnContextMenuClose write FOnContextMenuClose;
{ Invoked before the shell context menu of the view is shown }
property OnContextMenuOpen: TNotifyEvent read FOnContextMenuOpen write FOnContextMenuOpen;
{ Invoked when an item is opened. Set Allow to false to stop the default
action }
property OnDefaultAction: TExplorerPathEvent read FOnDefaultAction write FOnDefaultAction;
{ Invoked for each item of a folder which passes the Filter. Set Allow to
false to hide the item }
property OnIncludeItem: TExplorerPathEvent read FOnIncludeItem write FOnIncludeItem;
{ Invoked before a folder is shown. Set Allow to false to stay in the
current folder }
property OnNavigate: TExplorerPathEvent read FOnNavigate write FOnNavigate;
{ Invoked after a folder is shown }
property OnNavigated: TNotifyEvent read FOnNavigated write FOnNavigated;
{ Invoked when a folder could not be shown }
property OnNavigationFailed: TExplorerFolderEvent read FOnNavigationFailed write FOnNavigationFailed;
{ Invoked when the selected items change }
property OnSelectionChanged: TNotifyEvent read FOnSelectionChanged write FOnSelectionChanged;
property Align;
property Anchors;
property BorderSpacing;
property BorderStyle default bsNone;
property Constraints;
property DragCursor;
property Enabled;
property Hint;
property ParentShowHint;
property PopupMenu;
property ShowHint;
property TabOrder;
property TabStop default True;
property Visible;
property OnChangeBounds;
property OnClick;
property OnContextPopup;
property OnDblClick;
property OnDragDrop;
property OnDragOver;
property OnEnter;
property OnExit;
property OnKeyDown;
property OnKeyPress;
property OnKeyUp;
property OnMouseDown;
property OnMouseMove;
property OnMouseUp;
property OnMouseWheel;
property OnMouseWheelDown;
property OnMouseWheelUp;
property OnResize;
property OnShowHint;
property OnUTF8KeyPress;
end;See also
IComponentBindingClient in Codebot.Binding.pas