📄 acshellctrls.hpp
字号:
void __fastcall EnumColumns(void);
TacShellFolder* __fastcall GetFolder(int Index);
void __fastcall SetAutoRefresh(const bool Value);
void __fastcall SetSorted(const bool Value);
void __fastcall SetTreeView(TacCustomShellTreeView* Value);
void __fastcall SetComboBox(TacCustomShellComboBox* Value);
void __fastcall SynchPaths(void);
void __fastcall SetMask(const AnsiString Value);
bool __fastcall GetUpdating(void);
protected:
void __fastcall ClearItems(void);
void __fastcall CreateRoot(void);
virtual void __fastcall CreateWnd(void);
virtual void __fastcall DestroyWnd(void);
DYNAMIC void __fastcall DblClick(void);
DYNAMIC void __fastcall DoContextPopup(const Types::TPoint &MousePos, bool &Handled);
void __fastcall EditText(void);
DYNAMIC void __fastcall Edit(const tagLVITEMA &Item);
DYNAMIC void __fastcall KeyDown(Word &Key, Classes::TShiftState Shift);
virtual void __fastcall Notification(Classes::TComponent* AComponent, Classes::TOperation Operation);
virtual bool __fastcall OwnerDataFetch(Comctrls::TListItem* Item, Comctrls::TItemRequest Request);
virtual int __fastcall OwnerDataFind(Comctrls::TItemFind Find, const AnsiString FindString, const Types::TPoint &FindPosition, void * FindData, int StartIndex, Comctrls::TSearchDirection Direction, bool Wrap);
virtual void __fastcall Populate(void);
void __fastcall SetObjectTypes(TacShellObjectTypes Value);
void __fastcall SetRoot(const AnsiString Value);
virtual void __fastcall WndProc(Messages::TMessage &Message);
public:
bool FUpdating;
void __fastcall RootChanged(void);
void __fastcall SetPathFromID(Shlobj::PItemIDList ID);
void __fastcall TreeUpdate(Shlobj::PItemIDList NewRoot);
__fastcall virtual TacCustomShellListView(Classes::TComponent* AOwner);
__fastcall virtual ~TacCustomShellListView(void);
virtual void __fastcall Loaded(void);
void __fastcall Back(void);
HIDESBASE void __fastcall Refresh(void);
void __fastcall MakeNewFolder(void);
TacShellFolder* __fastcall SelectedFolder(void);
void __fastcall CommandCompleted(AnsiString Verb, bool Succeeded);
void __fastcall ExecuteCommand(AnsiString Verb, bool &Handled);
__property TacShellFolder* Folders[int Index] = {read=GetFolder};
__property TacShellFolder* RootFolder = {read=FRootFolder};
__property Items ;
__property Columns ;
__property AnsiString Mask = {read=FMask, write=SetMask};
__property bool AutoContextMenus = {read=FAutoContext, write=FAutoContext, default=1};
__property bool AutoRefresh = {read=FAutoRefresh, write=SetAutoRefresh, default=0};
__property bool AutoNavigate = {read=FAutoNavigate, write=FAutoNavigate, default=1};
__property TacShellObjectTypes ObjectTypes = {read=FObjectTypes, write=SetObjectTypes, nodefault};
__property AnsiString Root = {read=FRoot, write=SetRoot};
__property TacCustomShellTreeView* ShellTreeView = {read=FTreeView, write=SetTreeView};
__property TacCustomShellComboBox* ShellComboBox = {read=FComboBox, write=SetComboBox};
__property bool Sorted = {read=FSorted, write=SetSorted, nodefault};
__property bool Updating = {read=GetUpdating, nodefault};
__property TacShowExtension ShowExt = {read=FShowExtension, write=FShowExtension, nodefault};
__property TacAddFolderEvent OnAddFolder = {read=FOnAddFolder, write=FOnAddFolder};
__property Comctrls::TLVEditingEvent OnEditing = {read=FOnEditing, write=FOnEditing};
public:
#pragma option push -w-inl
/* TWinControl.CreateParented */ inline __fastcall TacCustomShellListView(HWND ParentWindow) : Slistview::TsCustomListView(ParentWindow) { }
#pragma option pop
private:
void *__IacShellCommandVerb; /* Acshellctrls::IacShellCommandVerb */
public:
operator IacShellCommandVerb*(void) { return (IacShellCommandVerb*)&__IacShellCommandVerb; }
};
class PASCALIMPLEMENTATION TacCustomShellComboBox : public Scomboboxes::TsComboBoxEx
{
typedef Scomboboxes::TsComboBoxEx inherited;
private:
int FImagesHandle;
int FImageHeight;
int FImageWidth;
Imglist::TCustomImageList* FImageList;
AnsiString FOldRoot;
AnsiString FRoot;
TacShellFolder* FRootFolder;
TacCustomShellTreeView* FTreeView;
TacCustomShellListView* FListView;
TacShellObjectTypes FObjectTypes;
bool FUseShellImages;
bool FUpdating;
TacGetImageIndexEvent FOnGetImageIndex;
void __fastcall ClearItems(void);
TacShellFolder* __fastcall GetFolder(int Index);
AnsiString __fastcall GetPath();
void __fastcall SetPath(const AnsiString Value);
void __fastcall SetPathFromID(Shlobj::PItemIDList ID);
void __fastcall SetRoot(const AnsiString Value);
void __fastcall SetTreeView(TacCustomShellTreeView* Value);
void __fastcall SetListView(TacCustomShellListView* Value);
void __fastcall SetUseShellImages(const bool Value);
int __fastcall GetShellImageIndex(TacShellFolder* AFolder);
bool __fastcall GetUpdating(void);
protected:
void __fastcall AddItems(int Index, TacShellFolder* ParentFolder);
DYNAMIC void __fastcall Click(void);
void __fastcall CreateRoot(void);
virtual void __fastcall DestroyWnd(void);
virtual void __fastcall Init(void);
TacShellFolder* __fastcall InitItem(TacShellFolder* ParentFolder, Shlobj::PItemIDList ID);
void __fastcall RootChanged(void);
void __fastcall TreeUpdate(Shlobj::PItemIDList NewPath);
virtual void __fastcall SetObjectTypes(TacShellObjectTypes Value);
public:
bool ExtUpdating;
__fastcall virtual TacCustomShellComboBox(Classes::TComponent* AOwner);
DYNAMIC void __fastcall Change(void);
virtual void __fastcall CreateWnd(void);
int __fastcall IndexFromID(Shlobj::PItemIDList AbsoluteID);
virtual void __fastcall Notification(Classes::TComponent* AComponent, Classes::TOperation Operation);
__fastcall virtual ~TacCustomShellComboBox(void);
virtual void __fastcall Loaded(void);
virtual void __fastcall WndProc(Messages::TMessage &Message);
__property Items ;
__property AnsiString Path = {read=GetPath, write=SetPath};
__property TacShellFolder* Folders[int Index] = {read=GetFolder};
__property AnsiString Root = {read=FRoot, write=SetRoot};
__property TacShellObjectTypes ObjectTypes = {read=FObjectTypes, write=SetObjectTypes, nodefault};
__property TacCustomShellTreeView* ShellTreeView = {read=FTreeView, write=SetTreeView};
__property TacCustomShellListView* ShellListView = {read=FListView, write=SetListView};
__property bool Updating = {read=GetUpdating, nodefault};
__property bool UseShellImages = {read=FUseShellImages, write=SetUseShellImages, default=1};
__property TacGetImageIndexEvent OnGetImageIndex = {read=FOnGetImageIndex, write=FOnGetImageIndex};
public:
#pragma option push -w-inl
/* TWinControl.CreateParented */ inline __fastcall TacCustomShellComboBox(HWND ParentWindow) : Scomboboxes::TsComboBoxEx(ParentWindow) { }
#pragma option pop
};
class PASCALIMPLEMENTATION TacCustomShellTreeView : public Streeview::TsTreeView
{
typedef Streeview::TsTreeView inherited;
public:
TacShellFolder* operator[](int Index) { return Folders[Index]; }
private:
AnsiString FRoot;
AnsiString FOldRoot;
TacShellFolder* FRootFolder;
TacShellObjectTypes FObjectTypes;
int FImage;
bool FLoadingRoot;
bool FAutoContext;
bool FUpdating;
TacCustomShellComboBox* FComboBox;
TacCustomShellListView* FListView;
bool FAutoRefresh;
bool FImageListChanging;
bool FUseShellImages;
TacShellChangeNotifier* FNotifier;
TacAddFolderEvent FOnAddFolder;
AnsiString FSavePath;
Comctrls::TTreeNode* FNodeToMonitor;
TacShowExtension FShowExtension;
Comctrls::TTreeNode* __fastcall FolderExists(Shlobj::PItemIDList FindID, Comctrls::TTreeNode* InNode);
TacShellFolder* __fastcall GetFolder(int Index);
AnsiString __fastcall GetPath();
void __fastcall SetComboBox(TacCustomShellComboBox* Value);
void __fastcall SetListView(const TacCustomShellListView* Value);
void __fastcall SetPath(const AnsiString Value);
void __fastcall SetPathFromID(Shlobj::PItemIDList ID);
void __fastcall SetRoot(const AnsiString Value);
void __fastcall SetUseShellImages(const bool Value);
void __fastcall SetAutoRefresh(const bool Value);
bool __fastcall GetUpdating(void);
protected:
void __fastcall CreateRoot(void);
virtual void __fastcall CreateWnd(void);
virtual void __fastcall DestroyWnd(void);
DYNAMIC void __fastcall DoContextPopup(const Types::TPoint &MousePos, bool &Handled);
DYNAMIC void __fastcall Edit(const tagTVITEMA &Item);
virtual void __fastcall GetImageIndex(Comctrls::TTreeNode* Node);
virtual void __fastcall GetSelectedIndex(Comctrls::TTreeNode* Node);
void __fastcall InitNode(Comctrls::TTreeNode* NewNode, Shlobj::PItemIDList ID, Comctrls::TTreeNode* ParentNode);
virtual void __fastcall Loaded(void);
DYNAMIC void __fastcall MouseUp(Controls::TMouseButton Button, Classes::TShiftState Shift, int X, int Y);
DYNAMIC void __fastcall Delete(Comctrls::TTreeNode* Node);
Comctrls::TTreeNode* __fastcall NodeFromAbsoluteID(Comctrls::TTreeNode* StartNode, Shlobj::PItemIDList ID);
Comctrls::TTreeNode* __fastcall NodeFromRelativeID(Comctrls::TTreeNode* ParentNode, Shlobj::PItemIDList ID);
virtual void __fastcall Notification(Classes::TComponent* AComponent, Classes::TOperation Operation);
DYNAMIC bool __fastcall CanChange(Comctrls::TTreeNode* Node);
DYNAMIC bool __fastcall CanExpand(Comctrls::TTreeNode* Node);
void __fastcall PopulateNode(Comctrls::TTreeNode* Node);
void __fastcall RootChanged(void);
virtual void __fastcall SetObjectTypes(TacShellObjectTypes Value);
HIDESBASE virtual void __fastcall WMDestroy(Messages::TWMNoParams &Message);
virtual void __fastcall WndProc(Messages::TMessage &Message);
void __fastcall ClearItems(void);
void __fastcall RefreshEvent(void);
HIDESBASE MESSAGE void __fastcall WMNCPaint(Messages::TMessage &Message);
public:
__fastcall virtual TacCustomShellTreeView(Classes::TComponent* AOwner);
__fastcall virtual ~TacCustomShellTreeView(void);
HIDESBASE void __fastcall Refresh(Comctrls::TTreeNode* Node);
TacShellFolder* __fastcall SelectedFolder(void);
__property bool AutoRefresh = {read=FAutoRefresh, write=SetAutoRefresh, nodefault};
__property TacShellFolder* Folders[int Index] = {read=GetFolder/*, default*/};
__property Items ;
__property AnsiString Path = {read=GetPath, write=SetPath};
__property bool AutoContextMenus = {read=FAutoContext, write=FAutoContext, default=1};
__property TacShellObjectTypes ObjectTypes = {read=FObjectTypes, write=SetObjectTypes, nodefault};
__property AnsiString Root = {read=FRoot, write=SetRoot};
__property TacCustomShellComboBox* ShellComboBox = {read=FComboBox, write=SetComboBox};
__property TacCustomShellListView* ShellListView = {read=FListView, write=SetListView};
__property bool UseShellImages = {read=FUseShellImages, write=SetUseShellImages, nodefault};
__property bool Updating = {read=GetUpdating, nodefault};
__property TacShowExtension ShowExt = {read=FShowExtension, write=FShowExtension, nodefault};
__property TacAddFolderEvent OnAddFolder = {read=FOnAddFolder, write=FOnAddFolder};
void __fastcall CommandCompleted(AnsiString Verb, bool Succeeded);
void __fastcall ExecuteCommand(AnsiString Verb, bool &Handled);
public:
#pragma option push -w-inl
/* TWinControl.CreateParented */ inline __fastcall TacCustomShellTreeView(HWND ParentWindow) : Streeview::TsTreeView(ParentWindow) { }
#pragma option pop
private:
void *__IacShellCommandVerb; /* Acshellctrls::IacShellCommandVerb */
public:
operator IacShellCommandVerb*(void) { return (IacShellCommandVerb*)&__IacShellCommandVerb; }
};
class DELPHICLASS TsShellTreeView;
class PASCALIMPLEMENTATION TsShellTreeView : public TacCustomShellTreeView
{
typedef TacCustomShellTreeView inherited;
__published:
__property OnAddFolder ;
__property OnGetImageIndex ;
__property OnGetSelectedIndex ;
__property OnClick ;
__property OnEnter ;
__property OnExit ;
__property OnDragDrop ;
__property OnDragOver ;
__property OnStartDrag ;
__property OnEndDrag ;
__property OnMouseDown ;
__property OnMouseMove ;
__property OnMouseUp ;
__property OnDblClick ;
__property OnKeyDown ;
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -