JamBaseShellListView Methods |
The JamBaseShellListView type exposes the following members.
Name | Description | |
---|---|---|
AddShellColumn(Int32) |
Adds a shell column to the list view.
| |
AddShellColumn(Int32, Int32) | Adds a shell column with the given width to the list view. | |
BaseOnDragDrop |
Calls the original inherited OnDragDrop method.
| |
BeginInit |
Signals the object that initialization is starting.
| |
Clear |
Removes all items and columns from the control.
| |
ClearColumns |
Clears the current columns and the header context menu. Please use this method instead of ListView.Columns.Clear()>.
| |
Compare |
Override this method to compare objects given the SortColumn.
The basic implementation compares the items alphabetically.
If you need to change this, you can start out like this:
C# public override int Compare(object x, object y) { ShellListBaseItem item1 = x as ShellListBaseItem; ShellListBaseItem item2 = y as ShellListBaseItem; if (item1 == null || item2 == null) return 0; if (!SortColumnShellID.IsCustomId()) { // the shell is asked ShellBrowser.SpecialFolder = ShellFolder.Desktop; if (Sorting == SortOrder.Ascending) return ShellBrowser.CompareIDs(item1.RelativeItemIdList, item2.RelativeItemIdList, m_SortColumnShellIndex); else return ShellBrowser.CompareIDs(item2.RelativeItemIdList, item1.RelativeItemIdList, m_SortColumnShellIndex); } else { // perform a normal alphanumeric compare if (Sorting == SortOrder.Ascending) return item1.SubItems[SortColumn].Text.CompareTo(item2.SubItems[SortColumn].Text); else return item2.SubItems[SortColumn].Text.CompareTo(item1.SubItems[SortColumn].Text); } } | |
CustomCompare |
Compares the given items by the content of the subitems at the SortColumn index.
| |
DisplayBackgroundContextMenu |
Shows the BackgroundContextMenu if it is non-null.
| |
DisplayContextMenu |
Shows the shell context menu for the currently selected items
| |
DisplayContextMenu(Point) |
Shows the shell context menu for the currently selected items
| |
DisplayHeaderContextMenu | Empty handler of the HeaderRightClick event. This needs to be implemented by the deriving classes. | |
Dispose |
Releases the unmanaged resources used by the ListView and optionally releases the managed resources.
(Overrides ListViewDispose(Boolean).) | |
DoAutoSizeColumn |
Autosizes the column that is set in AutoSizeColumn.
| |
EnableSystemStyles |
Sets system specific behaviour,
i.e. FullRowSelect in Vista and upwards.
(Inherited from SystemListView.) | |
EndInit |
Signals the object that initialization is complete.
After this method is called, IsInitialized is true to indicate
the state of the control.
| |
FinalizeColumnVisibilityChange |
Finalizes the column visibility change. The sort column is checked and the column order updated.
| |
FindContextMenuPosition |
finds the position where to display the context menu based
upon the currently selected items and their positions
| |
FindItemIdList | Searches for the first list item with the given ItemIdList. | |
FindPath | Returns the ListItem for the given path. | |
FolderChanged |
Gets called if the active folder should change.
| |
FullRefresh |
Call a full refresh.
| |
GetColumnHeaderCollectionType |
Gets the type of the column header collection.
| |
GetColumnOrder |
Retrieve the order in which columns appear.
(Inherited from SystemListView.) | |
GetIndexOfShColumnId(SHCOLUMNID) |
Returns the local index for the given ShellColumnID (if the column is existing and visible)
| |
GetIndexOfShColumnId(SHCOLUMNID, Boolean) |
Returns the local index for the given ShellColumnID.
| |
GetItemCollectionType |
Gets the type of the Item Collection. It is used to create the correct JamBaseShellListViewShellListViewItemCollectionT for the inheriting classes.
| |
GetListViewItemSorter |
Return an instance of IComparer that should be used for sorting the lists in subclasses
| |
GetSelectedItemCollectionType |
Gets the type of the Selected Item Collection. It is used to create the correct JamBaseShellListViewShellListViewSelectedItemCollectionT for the inheriting classes.
| |
GetSelectedItemIdLists | Gets the items the command will be executed upon. | |
GetSubItemBounds |
Retrieve the bounds of a ListViewSubItem
(Inherited from SystemListView.) | |
GetUIObject |
Get the UI object.
| |
GoUp |
Goes up one directory level.
| |
HideColumn |
Hides the column with the passed SHCOLUMNID.
| |
InitColumns |
Initializes the columns.
| |
InvalidateSortColumns | For internal use: invalidates the current sort column. | |
InvokeCommandOnSelected |
Invokes the given command on the selected items.
See ShellCommand class for a list of possible commands.
| |
IsColumnVisible(Int32) |
Returns whether the given column id is currently visible or not.
| |
IsColumnVisible(SHCOLUMNID) |
Returns whether the given SHColumnId is currently visible or not.
| |
IsColumnVisibleByDefault |
Determines whether the column with the specified shellcolumnId is a column shown by default.
| |
IsCustomColumn |
Checks whether the given column index is a custom or shell column
| |
IsEmpty |
Checks if the list is empty.
| |
ItemOfPidl |
Returns the ListItem for the given ItemIdList
| |
LogError(String) |
Error method that displays an error messagebox if the
property ShowErrorMessages is set.
The message is always written to the debug output stream
| |
LogError(String, Exception) |
Error method that displays an error messagebox if the
property ShowErrorMessages is set.
The message is always written to the debug output stream
| |
OnAfterInvokeCommand | Is called after the command has been called. | |
OnAfterLabelEdit |
Override the OnAfterLabelEdit event, to rename files or folders in the file system, when the have been renamed in the ShellListView.
(Overrides ListViewOnAfterLabelEdit(LabelEditEventArgs).) | |
OnBeforeInvokeCommand | Is called before the command is called. | |
OnBeforeLabelEdit |
Override the OnBeforeLabelEdit event, to prepare renaming a file or folder in the ShellListView.
(Overrides ListViewOnBeforeLabelEdit(LabelEditEventArgs).) | |
OnBeforeShellColumnChanged |
Calls the BeforeShellColumnChanged event if it is assigned.
| |
OnBeforeShellDrop |
Calls the BeforeShellDrop event if it is assigned.
| |
OnCheckStateChanged |
Fires an event if the CheckState of an item has changed.
| |
OnColumnClick |
Sort the column, which is clicked.
(Overrides ListViewOnColumnClick(ColumnClickEventArgs).) | |
OnColumnWidthChanged |
Tracks column widths. Raises the System.Windows.Forms.ListView.ColumnWidthChanged event.
(Overrides ListViewOnColumnWidthChanged(ColumnWidthChangedEventArgs).) | |
OnColumnWidthChanging |
Prevents changes at designtime.
Raises the ColumnWidthChanging event.
(Overrides ListViewOnColumnWidthChanging(ColumnWidthChangingEventArgs).) | |
OnCreateColumns |
Fires an event after the columns have been created
| |
OnCreateControl |
Raises the CreateControl method.
(Overrides ControlOnCreateControl.) | |
OnDragDrop |
This member overrides OnDragDrop(DragEventArgs) and resets the drag effect.
(Overrides ControlOnDragDrop(DragEventArgs).) | |
OnDragEnter |
This member overrides OnDragEnter(DragEventArgs) and adds drag images and cursors.
(Overrides ControlOnDragEnter(DragEventArgs).) | |
OnDragLeave | This member overrides OnDragLeave(EventArgs) and resets the
DropTargetHelper. (Overrides ControlOnDragLeave(EventArgs).) | |
OnDragOver |
This member overrides OnDragOver(DragEventArgs) and adds drag images and cursors.
(Overrides ControlOnDragOver(DragEventArgs).) | |
OnHandleCreated |
Handles the OnHandleCreated event and e.g. initializes the image list
(Overrides SystemListViewOnHandleCreated(EventArgs).) | |
OnHandleDestroyed | Tracks the handle destruction. (Overrides ListViewOnHandleDestroyed(EventArgs).) | |
OnHeaderContextMenuClick |
Eventhandler for a HeaderContextMenuClick.
| |
OnHeaderRightClick |
Raises the HeaderRightClick-Event
(Inherited from SystemListView.) | |
OnItemChecked | Calls raising of the OnItemCheckedEvent. | |
OnItemDrag |
This member overrides OnItemDrag(ItemDragEventArgs) (Overrides ListViewOnItemDrag(ItemDragEventArgs).) | |
OnItemShowToolTip | This method is extended to show tool tip texts of the particular shell objects. (Overrides SystemListViewOnItemShowToolTip(SystemListViewShowToolTipEventArgs).) | |
OnMouseDown |
Raises the System.Windows.Forms.Control.MouseDown event.
(Overrides ControlOnMouseDown(MouseEventArgs).) | |
OnMouseUp |
Overrides the OnMouseUp event, to handle e.g. double clicks and right clicks on files or folders
and the selection of files or folders, when the CheckBoxes are switched on.
(Overrides ControlOnMouseUp(MouseEventArgs).) | |
OnNotifyMessage |
This method is called if a notification event is performed on the message
pump WndProc(Message) (Inherited from SystemListView.) | |
OnOperation(ShellOperation, PathCollection, String, Exception) |
Fires an event if an operation was performed on the JamBaseShellListView.
| |
OnOperation(ShellOperation, StringCollection, String, Exception) |
Helper function for OnOperation(ShellOperation, PathCollection, String, Exception)
to avoid type conversion.
| |
OnResize |
Raises the OnResize event.
(Overrides ListViewOnResize(EventArgs).) | |
OnShowOptionChanged | Calls the ShowOptionChanged event if it is assigned. | |
PrepareMultiObjects | Obsolete.
Prepares the selected items in the list for being used with the m_ShellBrowser, an instance of ShellBrowser.
| |
PreserveSystemStyle |
This method preserves the Windows Vista light blue selection line if UseSystemStyles is on.
The Setting is lost if e.g. a column is clicked to sort things.
(Inherited from SystemListView.) | |
Refresh(RefreshLevel) | This method indicates that the control should perform a refresh of its contents. | |
Refresh(RefreshLevel, ItemIdList) | This method indicates that the control should perform a refresh of its contents. | |
RemoveItemFromList |
Removes the list element from the list
| |
ResetColumns |
Resets the columns to the initial state.
| |
ResetItems |
Resets the items and their subitems.
| |
RestoreItemSelection | Restores the selection and checkstate of the item. | |
RestoreState | Counterpart of SaveState. Restores properties and possibly contents of the ListView. | |
SaveCheckedItems | Saves the checked items. | |
SaveColumnSettings | Saves the column settings. | |
SaveSelection | Saves the current selection and checked items to a temporary List. | |
SaveState | Saves the column properties of the current view, so that it can be restored later. | |
ScaleControl | Scales a control's location, size, padding and margin. (Overrides ControlScaleControl(SizeF, BoundsSpecified).) | |
SelectAllItemsInternal | Selects all items. | |
SelectedFileChange |
Gets called if the selected file should change.
| |
SelectPidl(ItemIdList) |
Selects the ListItem that corresponds to the given ItemIdList.
| |
SelectPidl(ItemIdList, Boolean) |
Selects the ListItem that corresponds to the given ItemIdList.
| |
SetColumnBitmap |
Set the sort icon among the current sort order in the passed column.
(Inherited from SystemListView.) | |
SetColumnOrder |
Sets the order in which columns appear.
(Inherited from SystemListView.) | |
SetColumnVisibility(Int32, Boolean) |
Sets the visibility of a column.
| |
SetColumnVisibility(SHCOLUMNID, Boolean) |
Sets the visibility of a column.
| |
SetFont |
Sets the font without adjusting other properties.
(Inherited from SystemListView.) | |
SetSortOrder(SHCOLUMNID) | Sets and applies the SortColumn in ascending. | |
SetSortOrder(SHCOLUMNID, SortOrder) | Sets and applies the sortrder. | |
ShowColumn |
Shows the column with the passed ShellColumnId.
| |
SmartRefresh |
Call a smart refresh.
| |
Sort |
Sorts the items of the list view. Uses a custom sort order if an IComparer is assigned to property ListViewItemSorter.
If no custom sortorder is supplied the default sorting handles sorting by columns and is only useful in Details.
In this case SortColumn must be non-negative.
| |
UpdateColumnBitmaps |
Updates the sort icon in the column of the ShellListView.
| |
UpdateSubitemsAfterColumnGetsVisible |
Loads subitems for a column that has been added at the passed position.
| |
WndProc |
Overrides
WndProc(Message).
(Overrides ListViewWndProc(Message).) |
Name | Description | |
---|---|---|
HandleNeeded | A Control extension method that ensures that the handle for a control is created. (Defined by ExtensionMethods.) | |
ScaledPixels | An extension method for controls: It scales the passed pixels according to the current dpi the control is displayed with. (Defined by ExtensionMethods.) | |
ScaleFont | A Control extension method that scales font according to the passed factor. (Defined by ExtensionMethods.) |