TDriveView

Version 2.4

Copyright © 1999 by Ingo Eckel
All rights reserved.

e-mail: mailto:Ingo.Eckel@t-online.de
web site: http://home.t-online.de/home/ingo.eckel/d4comp.htm

Overview:

TDriveView is a visible VCL-component based on the Delphi4-component TCustomTreeView. It is designed to display the drives and directories of the computer as hierarchical tree using shell icons. It supports displaying the system context menu, property sheets, the creating, renaming, deleting, copying and moving of directories and full OLE-drag&drop of directories from and to the explorer using drag&drop cursors and images.It also encapsulates copy, cut and pasting directories from and to the clipboard. Undo the copy and move of directories is supported (not: undelete). It has build-in methods to display the filesize of all files stored in each directory. Changes in the filesystem, done by other applications will be detected automatically and are immediatly displayed in the directory tree.

TDriveView has extended drag&drop capabilities: it automatic scrolls the controls window, if during a drag&drop operation the cursor is near the top, bottom, left or right edge of the control. If the cursor stays on a single node for more than two seconds, the node will be automatically expanded. The node can also be expanded or collapsed by pressing the spacebar.

The internal data to manage each treenode is stored as a pointer to the object TNodeData in the property Data of the treenode.


Features:

 


Public properties:

 

Images
Contains the system image list for small images. Do not change this value!
 
StateImages
Contains the system image list for small state images. Do not change this value!
 
Items Stored False
Redefines Delphi's Item property, because it makes no sense to store the existing directories of your computer in the form. The exisiting directories are allways rescanned at runtime.
 
DriveBox : TObject
Points to the linked component TIEDriveComboBox. Do not set this property manually. It is updated, when the property TIEDriveComboBox is set to the instance of TDriveView.
 
DragDropFilesEx : TDragDropFilesEx (runtime, readonly)
Points to the instance of TDragDropFilesEx, wich implements the drag&drop functions.
 
DragDrive : TDrive (runtime, readonly)
Contains the drive letter of the dragged files, when the controls window is the target of a drag&drop operation.
 
CanUndoCopyMove : Boolean (runtime, readonly)
True, if the TFileOperator can undo the last copy or move of a directory. The TFileOperator cannot undo deleting files, even if they are moved to the recycle bin.
 
DDFileOperator : TFileOperator (readonly)
Points to the instance of TFileOperator wich implements the interface to the shells function shFileOperation.
 
LastPathCut : String (runtime)
Contains the absolute path to the directory, where the key Ctrl-X was pressed. This property should only be set by the method CutToClipBoard.
 

Published properties:

 

Directory : String
Get or set the selected treenode of the treeview. The value should be a valid absolute directory path. Long or short pathnames are allowed. This property should be set at runtime to an existing directory. Set this property at designtime only, if you are shure, that this directory is valid for every target computer.
 
ConfirmDelete : Boolean
Confirm physical deletion of directories. The message window is created by the windows-function shFileOperation. 
 
ConfirmOverwrite : Boolean
Confirm overwriting existing files during a drop or paste of directories. The message window is created by the windows-function shFileOperation.   
 
FullDriveScan : Boolean
Scan all directories of the current drive immediatly, when exanding the rootnode.  
 
DimmHiddenDirs : Boolean
Display directories with the Hidden-attribute set in gray color.
 
WatchDirectory : Boolean
Enables or disables watching the current drive for changes (inserting, renaming and deleting directories). 
 
ChangeInterval : Cardinal
Upate the displayed tree after ChangeInterval milliseconds, when a directory change was detected. 
 
UseSystemContextMenu : Boolean
Enables or disables the display of the system contextmenu, when right-clicking a directory.  If disabled, a right-click will popup the the menu owned by the property PopupMenu, if it exists. Right-clicking in a empty area below the last item allways pops up the menu owned by the property PopupMenu. The system contextmenu is implemented by the unit ItemProp.
 
DirView : TDirView
If set, the linked component TDirView will by automatically updated, when the selected treenode has changed. 
 
ColorBold : TColor
Draw nodes in ColorBold color. To set the bolddrawing for a specific node, call the method SetBoldDraw for the this node. 
 
ShowDirSize : Boolean
Enables or disables the display of the directory size in KB or MB after the directory name. 
 
ShowVolLabel : Boolean
Enable or disable the display of the drives volume label after the drive letter C:\. The style, how the volume label is displayed is controled by the property VolDisplayStyle.
 
VolDisplayStyle : TVolumeDisplayStyle
Determines, how the Volumelabel is formatted:

doPrettyName: The volume label is formatted as 'C: VolumeID', on network drives the UNC-name is not displayed.
doDisplayName: The volume label is formatted like the Explorer's volume-label with UNC-names.
doLongPrettyName: The volume label is formatted like doPrettyName, on network drives the server name and -directories are also shown.

Wether the volume label should be displayed or not is controled by the property ShowVolLabel.

 
DragDetectDelta : Byte
Assume a drag&drop operation after moving the mouse DragDetectDelta pixels with a single mousebutton pressed.
 
UseDragImages : Boolean
Enables or disables the usage of dragimages during a drag&drop operation. When dragging a treenode, a symbol representing this directory will be displayed. Displaying the dragimage on Windows95-systems without system updates (not: Windows98, NT4) may cause a flickering dragcursor. Thus, your application should have a option to disable this feature, if you plan to distribute your application to Windows95-users.
 
TargetPopUpMenu : Boolean
Enables or disables the Explorer-like display of the popupmenu when dropping files or directories on the control using the right mouse button. 
 
ShowAnimation : Boolean
Enables or disables the display of the standard AVI-animation when performing a full drive scan. The animation is shown centered in the comonents window. This property is only applicable, if the property FullDriveScan is set to True and the method ScanDrive was called.
 

Methods:

 

Function UndoCopyMove : Boolean
Initiates the undo of the last copy or move operation with directories or files performed by the TFileOperator. Copy or move file operations can result from dropping files or directories onto the controls window or by using the method PasteFromClipBoard.
 
Procedure EmptyClipboard
Empties the Windows system clipboard.
 
Function CopyToClipBoard(Node : TTreeNode) : Boolean
Copies the node to the clipboard.
 
Function CutToClipBoard(Node : TTreeNode) : Boolean
Cuts the node to the clipboard and set the property TTreeNode.Cut to True.
 
Function CanPasteFromClipBoard : Boolean
Returns True, if the clipboard contains files or directories.
 
Function PasteFromClipBoard : Boolean
Paste the files or directories from the clipboard into the selected treenode. The file operation is performed by the TFileOperator.
 
Function GetDriveStatus(Drive : TDrive) : TDriveStatus
Returns the TDriveStatus record of the given drive letter.
 
Function GetDriveTypetoNode(Node : TTreeNode) : Integer
Returns the drivetype of the given node. The result is the value for drivetypes as defined in windows.pas, for example DRIVE_FIXED, DRIVE_REMOTE, ...
 
Function GetDriveType(Drive : TDrive) : Integer
Returns the drivetype of the given drive letter. The result is the value for drivetypes as defined in windows.pas, for example DRIVE_FIXED, DRIVE_REMOTE, ...
 
Function GetDrive(Node : TTreeNode) : Char
Returns the drive letter of the given node.
 
Function GetDriveText(Drive : TDrive) : String
Returns the volume label or displayname of the given drive.
 
Procedure ScanDrive(Drive : TDrive)
Scans the drive for directories. This method should not be called by your application. The drive will be scanned, if the rootnode of the drive is exanding.
 
Procedure RefreshRootNodes(ScanDirectory : Boolean; dsFlags : Integer)
Resets the rootnodes of the control. The value dsFlags is passed to the method TDriveInfo.ReadDriveStatus except the following values:

dvdsFloppy: Include floppy drives. If not set, this method starts with drive C.
dvdsRereadAllways: Allways reread the drivestatus, even if the displayname or volume label has allready been read.
 
Function GetValidDrivesStr : String
Returns the valid drives as string: for example 'ACD'.
 
Procedure RefreshDirSize(Node : TTreeNode)
Rereads the filesize of all files stored in the given directory.
 
Procedure RefreshDriveDirSize(Drive : TDrive)
Rereads the filesize for all directories of the given drive.
 
Procedure SetImageIndex(Node : TTreeNode)
Sets the imageindex from the system image list as returned by shGetFileInfo for the given node.
 
Function FindNodeToPath(Path : String) : TTreeNode
Returns the node to the given absolute directory path. The path may contains short or long names.
 
Procedure SetBoldDraw(Node : TTreeNode; BoldDraw : Boolean)
Enables or disables the display of the given node in bold letters.
 
Function NodeAttr(Node : TTreeNode) : Integer
Returns the directories file attributes, e.g. faDirectory, faHidden, faSysFile.
 
Function RootNode(Node : TTreeNode) : TTreeNode
Returns the rootnode to the given node. The rootnode represents allways the drive's root directory.
 
Function GetDirPathName(Node: TTreeNode) : String
Returns the absolute path of the given node. If the node is the root directory, the trailing slash is added. Otherwise the trailing slash is removed: for example C:\ and C:\WINDOWS.
 
Function GetDirPath (Node : TTreeNode) : String
Returns the absolute path of the given node without the trailing slash: for example C: and C:\WINDOWS
 
Function GetDirName(Node : TTreeNode) : String
Returns the directory name wich is represented by the node: C:, WINDOWS, SYSTEM. The directory name is allways the long name and may contain blanks.
 
Procedure CenterNode(Node : TTreeNode)
Scrolls the controls window vertical, until the given node is vertically centered within the controls window.
 
Function SortChildren(ParentNode : TTreeNode; Recurse : Boolean) : Boolean
Sorts the childnodes of the given node in alphabetic order. Set the parameter Recurse to True if also the subnodes of the children should be sorted.
 
Function GetDirSize(Node : TTreeNode) : Cardinal
Returns the whole filesize of the files in the specified directory in Bytes. Files stored in subdirectories are ignored. To reread the filesizes use the method SetDirSize.
 
Procedure SetDirSize(Node : TTreeNode)
Reads the filesizes of all files stored in the given directory. To retrieve the value, call the method GetDirSize.
 
Function GetDisplayName(Node : TTreeNode) : String
Returns the directories displayname as displayed in the controls window. If the property ShowDirSize is set to True, the displayname contains also the directory size.
 
Function NodeUpdateAble(Node : TTreeNode) : Boolean
Returns True, if the node is updateable by the filesystem. The directory is not updateable, if it is the root directory or it is stored on a CD-ROM.
 
Function FormatDirSize(Size : Cardinal) : String
Formats the directory size in bytes, KB or MB as displayed by the method GetDisplayName.
 
Procedure ExpandLevel(Node : TTreeNode; Level : Integer)
Expands all subdirectories of the given node up to the parameter level. The rootnode has level 0, the subdirectories of the rootnodes are level 1, ...
 
Procedure ValidateDirectoryEx(Node : TTreeNode; Recurse : TRecursiveScan)
Checks the given directory for existance and searches for new subdirecories. Wether the subdirectories of the given node are also checked is controled by the parameter Recurse. The following values are valid for the parameter Recurse:

rsNoRecursive: Scan the startnode only.
rsRecursive: Scan the startnode and all subnodes of the startnode.
rsRecursiveExisting: Scan the startnode and all subnodes of the startnode but not new created subnodes.
rsRecursiveExpanded: Scan the startnode and all expanded subnodes of the startnode.
 
Procedure ValidateDirectory(Node : TTreeNode)
Checks, wether the given node exists in the filesystem and scans the given node and all exanded subdirectories of this node for new created or deleted subdirectories.
 
Procedure ValidateDirectoryEasy(Node : TTreeNode)
Same as ValidateDirectory but scans the node only, if it has not been verified once.
 
Procedure ValidateExistingDirectories(Node : TTreeNode)
Checks, wether the given node exists in the filesystem and scans the given node and all allready existing subnodes of this node for new created or deleted subdirectories. New directories found by this method are not scanned for subdirectories.
 
Procedure ValidateAllDirectories(Node : TTreeNode)
Same as ValidateExistingDirectories but scans also new subdirectories found by this method. Thus, calling this method for a rootnode performs a full drive scan and may consume a lot of CPU-time.
 
Function GetSubTreeSize(Node : TTreeNode) : Integer
Returns the directory size as reported by the method GetDirSize but also includes the size of all subdirectories. The amount of filesize is allways refreshed from the filesystem.
 
Function CreateDirectory(ParentNode : TTreeNode; NewName : String) : TTreeNode
Creates a new subdirectory of the given node and displays it as subnode of the given node.
 
Function DeleteDirectory(Node: TTreeNode; AllowUndo : Boolean) : Boolean
Erases the directory represented by the given node from the filesystem. The method uses the TFileOperator to delete the directory. If the parameter AllowUndo is set to True, the TFileOperator tries to send the directory to the recycle bin. Otherwise, or if the drive is a floppy- or networkdrive the directory will by physically erased.
 
Function IterateSubTree(Var StartNode : TTreeNode;CallBackFunc : TCallBackFunc; Recurse : TRecursiveScan; ScanStartNode : TScanStartNode; Data : Pointer) : Boolean;
This method calls the Procedure CallBackFunc for the node and all subnodes of the given node. Wich subnodes are included, is controled by the parameter Recurse as described in the method ValidateDirectoryEx. If you want to call the CallBackFunc even for the Startnode, set the parameter ScanStartNode to coScanStartNode, otherwise to coNoScanStartNode.
This method is used by many other methods of this control.
 
Procedure SaveNodesState(Node : TTreeNode)
Stores the actual expanded state of the node and its subnodes in the node's data. This state can by restored by the method RestoreNodesState.
 
Procedure RestoreNodesState(Node : TTreeNode)
Restores the expanded state of the node and its subnodes as stored the last time by calling th method SaveNodesState.
 
Procedure DisplayContextMenu(Node : TTreeNode)
Displays the system context menu as used by the Explorer for the directory as represented by the given node. The file operations (copy, cut, paste) initated by the system context menu are handled by the explorer, so the control cannot react on this operations.
 
Procedure DisplayPropertiesMenu(Node : TTreeNode)
Displays the property sheets as used by the Explorer for the directory as represented by the given node. The file operations (rename, change filetime or attributes) initated by the property sheets are handled by the explorer, so the control cannot react on this operations.
 
Procedure StartWatchThread
Starts or restarts the thread which watches the actual drive for new, renamed or deleted directories. This method is only applicable, if the property WatchDirectory is set to True.
 
Procedure StopWatchThread
Stops watching the filesystem of the current drive for changes. To restart the watchthread use the method StartWatchThread.
 
Procedure TerminateWatchThread(Drive : TDrive)
Terminates the thread which is watching the filesystem of the given drive for changes. To restart the watchthread use the method StartAllWatchThreads.
 
Procedure StartAllWatchThreads
Starts or restarts the threads who are watching the existing drives for new, renamed or deleted directories. This method is only applicable, if the property WatchDirectory is set to True. Only those drives are watched, which where allready expanded once.
 
Procedure StopAllWatchThreads
Stops watching the filesystem for changes for all existing drives. To restart the watchthread use the method StartAllWatchThreads.
 
Function WatchThreadActive : Boolean
Returns True, if the watchthread of the current drive is active. The watching of the filesystem for changes may not work for network drives.
 
Function NodeWatched(Node : TTreeNode) : Boolean
Returns the currently watched node. This node is allways the rootnode of the current drive.
 
Procedure DeleteSubNodes(Node : TTreeNode)
Deletes all childnodes of the given node. If the node is a rootnode representing a drive, then the internal property Scanned is set to False.
 

Events:

 

OnStartScan : TNotifyEvent
This event occurs, when the scanning of a drive starts. This event will only be fired, when the property FullDriveScan is set to True.
 
OnEndScan : TNotifyEvent
This event occurs, when the scanning of a drive has finished. This event will only be fired, when the property FullDriveScan is set to True.
 
OnScanDir : TDriveViewScanDirEvent = Procedure(Sender: TObject; Node: TTreeNode; Var DoScanDir : Boolean)
This event occurs, when a single directory is scanned for subdirectories. To avoid or force the scanning of this directory, set the parameter DoScanDir to False or True. The recycle bin is not scanned by default.
 
OnDiskChange: TDriveViewDiskChangeEvent = Procedure(Sender: TObject; Drive : TDrive)
This event occurs, when the property Selected has changed to another drive or when the serialnumber of the actual drive has changed (a CD-ROM was removed or inserted).
 
OnChangeDetected : TNotifyEvent
The watchthread has detected a change in the filesystem. A directory has been created, renamed or removed by another application.
 
OnChangeInvalid : TNotifyEvent
The watchthread has signalled, that the current drive does not supports watching the filesystem for changes. This problem may occur with novell network drives.
 
OnDDDragEnter : TDDOnDragEnter = Procedure(Sender: TObject; DataObj: IDataObject; grfKeyState: Longint; pt: TPoint; var dwEffect: longint; var Accept:boolean)
The controls windows has become target of a OLE drag&drop operation. The mousecursor has entered the controls window.
For detailed informations about the event and its parameters have a look at Dieter Steinwedel's documentation of the component TDragDrop in the archive DragNDrop.zip.
 
OnDDDragLeave : TDDOnDragLeave = Procedure(Sender: TObject)
The controls windows is not any more target of a OLE drag&drop operation. The mousecursor has leaved the controls window.
For detailed informations about the event and its parameters have a look at Dieter Steinwedel's documentation of the component TDragDrop in the archive DragNDrop.zip.
 
OnDDDragOver : TDDOnDragOver = Procedure(Sender: TObject; grfKeyState: Longint; pt: TPoint; var dwEffect: longint)
The mousecursor is moving within the controls window, while a OLE drag&drop operation is running.
For detailed informations about the event and its parameters have a look at Dieter Steinwedel's documentation of the component TDragDrop in the archive DragNDrop.zip.
 
OnDDDrop : TDDOnDrop = Procedure(Sender: TObject; DataObj: IDataObject; grfKeyState: Longint; pt: TPoint; var dwEffect: longint)
The mouse cursor has dropped some files or directories within the controls window. This event occurs before rendering the filenames of the dropped files.
For detailed informations about the event and its parameters have a look at Dieter Steinwedel's documentation of the component TDragDrop in the archive DragNDrop.zip.
 
OnDDQueryContinueDrag : TDDOnQueryContinueDrag = Procedure(Sender: TObject; fEscapePressed: BOOL; grfKeyState: Longint; var Result: HResult)
There is a OLE-drag&drop operation in progress with the control as the drag source. This event occurs periodical during a drag&drop operation. For detailed informations about the event and its parameters have a look at Dieter Steinwedel's documentation of the component TDragDrop in the archive DragNDrop.zip.
 
OnDDGiveFeedback : TDDOnGiveFeedback = Procedure(Sender: TObject; dwEffect: Longint; var Result: HResult)
There is a OLE-drag&drop operation in progress with the control as the drag source. This event occurs periodical during a drag&drop operation. For detailed informations about the event and its parameters have a look at Dieter Steinwedel's documentation of the component TDragDrop in the archive DragNDrop.zip.
 
OnDDDragDetect : TDDOnDragDetect = Procedure(Sender: TObject; grfKeyState: Longint; DetectStart, Pt: TPoint; DragStatus:TDragDetectStatus)
A OLE drag&drop operation has been initiated by the control.
For detailed informations about the event and its parameters have a look at Dieter Steinwedel's documentation of the component TDragDrop in the archive DragNDrop.zip.
 
OnDDProcessDropped : TOnProcessDropped = procedure(Sender: TObject; grfKeyState: Longint; pt: TPoint; dwEffect: Longint)
The mousecursor has dropped some files or directories within the controls window. This event occurs before rendering the filenames of the dropped files.
For detailed informations about the event and its parameters have a look at Dieter Steinwedel's documentation of the component TDragDrop in the archive DragNDrop.zip.
 
OnDDError : TDDErrorEvent = Procedure(Sender: TObject; ErrorNo : TDDError)
This event occurs, when an error occurs during an OLE drag&drop operation. If this event is not assigned in your application the controls generates the exception EDragDrop. The parameter ErrorNo contains the errorcode and might has one of the folowing values:

DDCreateShortCutError: The control was not able to create a shortcut for the dropped files. The targetdrive might be write-protected or you do not have sufficient access rights to create files in the target directory.
DDPathNotFoundError: The target directory of the drag&drop operation is not valid. This problem can only occur, when the control is the target of the drag&drop operation.
 
OnDDExecuted : TDDExecutedEvent = Procedure(Sender: TObject; dwEffect: Longint)
The OLE drag&drop operation with the controls window as target is completly finished. The directories involved in the operation has beenchecked for existance and new subdirectories. The linked component TDirView has been updated.
 
OnDDFileOperation : TDDFileOperationEvent = Procedure(Sender: TObject; dwEffect: LongInt; SourcePath, TargetPath: String; Var DoOperation : Boolean)
The TFileOperator will immediatly start the file operation initiated by the OLE drag&drop operation or when the method PasteFromClipBoard was called by your application. This event can only occur, when the controls window is the target of the drag&drop operation because this operation is allways handled by the target window or when pasting files from the clipboard using the method PasteFromClipBoard. This event does not occur, when the files are pasted from the clipboard by using the system context menu. In this case, the file operation is handled by the explorer.
 
OnDDFileOperationExecuted : TDDFileOperationExecutedEvent = Procedure(Sender: TObject; dwEffect: LongInt; SourcePath, TargetPath: String)
The TFileOperator has finished the file operation initiated by the OLE drag&drop operation or when the method PasteFromClipBoard was called by your application. This event can only occur, when the controls window is the target of the drag&drop operation because this operation is allways handled by the target window or when pasting files from the clipboard using the method PasteFromClipBoard. This event does not occur, when the files are pasted from the clipboard by using the system context menu. In this case, the file operation is handled by the explorer.
 

Global functions and variables:

 

ErrorInvalidDirName : String
This string contains the language-specific error message wich will by displayed if the user has renamed a directory and the control has found, that the new name contains invalid characters like * or ?.
 

Data structures

 

TNodeData = Class
The object TNodeData is stored with every treenode in the property TTreeNode.Data. TNodeData contains the following properties, wich are used for internal purposes:

Property DirName : String; Physical name of the directory as used by the filesystem.
Property ShortName : TString12; Physical short name of the directory as used by the filesystem.
Property Attr : Integer; File attributes of the directory.
Property Verified : Boolean; The node has been verified once.
Property Data : Pointer; Unused. May be used by your application.
Property Expanded : Boolean; Saved expanded state of node as used by the methods SaveNodeState and RestoreNodeState.
Property DrawBold : Boolean; The node is drawn in bold letters an ColorBold color.
Property NewDir : Boolean; The node is a new directory found by the method VerifyDirectoryEx.
Property DirSize : Cardinal; Filesize of the files stored in this directory. The value is stored by the method SetDirSize.
Property isRecycleBin : Boolean; The directory represents the recycle bin.

 

TDriveStatus = Record
Stores information about the specific drive. You can access this record using the method GetDriveStatus. To retrieve more specific informations about a drive, use the methods of the global instance DriveInfo = TDriveInfo.

Scanned : Boolean The drive has been scanned once.
Verified : Boolean The nodes of the drive have been verified once.
RootNode : TTreeNode Points to the node representing the rootdirectory of the drive.
DiscMonitor : TDiscMonitor Filesystem monitor of the drive, which watches the filesystem for changes. Is only valid, if the rootnode was allready expanded once.
ChangeTimer : TTimer Timer, wich informs the component about pending updates after the specific period stored in the propery ChangeInterval.

 


Limitations:

 

TDriveView uses only pathnames of the filesystem. Virtual folders like Printers or the Control Panel does not have a physical directory and thus cannot be displayed by TDriveView.


History:

 

V1.0: First published release.
V1.1: - Notification handled, when linked component TDirView is removed.
-Added or removed drives could be detected using the method RefreshRootNodes.
Notice: the message WM_DEVICECHANGE must be received by the application, which then should call the method RefreshRootNodes.
- Bug with suspended WatchThread on event Destroy fixed. See TDiscMonitor => modification ie03.
- Centralized drive management (=> TDriveInfo)
- Enhanced startup performance.
- Added property for the display text of the drive nodes.
V2.0: - Complete drag&drop support for files and directories.
- Full access to clipboard operations for files and directories. Requires drag&drop functions.
- Preserves undo informations to undo copy and move file operations. Requires
drag&drop functions.
- Renaming of files or directories dropped from the recycle bin.
- Now supports user-defined context menus, when right-clicking the area below the tree items.
- French language support.
V2.01: - Changed formatting of filesizes (thousandseparators).
- Required compiler options inserted to avoid problems with global compiler settings different to the Delphi4 default settings.
- Bugfix: When property VolDisplayStyle is set to doDisplayName then all drives where scanned when loading the project.
V2.1: - AV in OnDDDragEnter fixed.
- Now uses Dieter Steinwedel's new MappedName feature, when processing dropped files from the recycle bin.
- Bug fixed when renaming a directory from 'Test' to 'TEST'. It was displayed twice in the directory.
- Changed case of directory name does not cause deleting and reinserting the node. This matches only, when the renaming was detected by the watchthread.
- DeleteDirectory should delete the node only if the directory was successfully removed.
- New procedure ExpandLevel to expand all nodes up to the given level and collapse the others.
- Linked component TIEDriveComboBox added and updating the combobox, when the actual drive has changed.
- New Property UseSystemContextMenu to enable/disable the system context menu.
- AV fixed when dragging drive nodes.
- Displaying a dragimage during a drag&drop operation.
- Explorer-like drag-detection. A new node will be selected, when the left mouse button is released.
- Bugfix: in Event OnDDDragOver the vertical scrolling has sometimes ignored the scrolling delay.
- New global variable DropSource to identify the source of a drag&drop operation. This variable is used to perform a faster update of the display, when moving files.
V2.2: - Property WatchedNode removed.
- Now watching all drives for directory changes (not only the current drive).
- New methods StartAllWatchThreads and StopAllWatchThreads.
- New method DeleteSubNodes.
- Property Directory is now restored at runtime if set.
- Property VolDisplayStyle enhanced. Added value: doLongPrettyName.
- New property ShowAnimation.
- Changed drag detect. Now using the standard messages TVN_BEGINDRAG and TVN_BEGINRDRAG. Thus the property DragDetectDelta was removed.
- Bug fixed when displaying dragimages. On Win95-Systems without system updates (shell??) the dragcursor has vanished. Now it is just flickering (!) when dragging within the application's windows.
V2.21: - Changed rename error message.
- Bug fixed when dragging the selected node.
- Bug fixed when extracting a single executable from a Winzip archive.
V2.3: - New method TerminateWatchThread(Drive : TDrive).
- ItemProp replaced by my own version of handling the system context menu. Thus the control now also handles the rename- and cut-menuitem.
- Fixed problem when the rootdirectory of a floppy disk was allready expanded. As a result the WinNT4-shell function refuses to format the floppy disk.
V2.4: - Don't accept files dropped from the recycle bin to the recycle bin.