IGLib  1.7.2
The IGLib base library EXTENDED - with other lilbraries and applications.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Events Macros
IG.Forms.DirectorySelector Class Reference
+ Inheritance diagram for IG.Forms.DirectorySelector:
+ Collaboration diagram for IG.Forms.DirectorySelector:

Public Member Functions

 DirectorySelector ()
 
string GetFilePathRepresentation (string directoryPath)
 Returns the presentational form of the specified directory path, with eventual environment variables expanded and with conversion to the appropriate form (relative or absolute). More...
 
void BrowseDirectory ()
 Browses for the file to be hashed. More...
 
void ClearHistory ()
 
 DirectorySelector ()
 
string GetFilePathRepresentation (string directoryPath)
 Returns the presentational form of the specified directory path, with eventual environment variables expanded and with conversion to the appropriate form (relative or absolute). More...
 
void BrowseDirectory ()
 Browses for the file to be hashed. More...
 
void ClearHistory ()
 

Protected Member Functions

virtual void UpdateErrorState ()
 Updates controls according to error state. More...
 
virtual void OnDirectorySelected ()
 Called whenever the selected directory changes. More...
 
virtual void OnDirectoryChanged ()
 Called whenever the directory containing the selected file changes. More...
 
void Handle_CtrlA_CtrlBackspace (TextBox textBox, object sender, KeyEventArgs e)
 Handle the Ctrl-A (select all) and Ctrl-Backspace events for the specified text box. More...
 
override void Dispose (bool disposing)
 Clean up any resources being used. More...
 
virtual void UpdateErrorState ()
 Updates controls according to error state. More...
 
virtual void OnDirectorySelected ()
 Called whenever the selected directory changes. More...
 
virtual void OnDirectoryChanged ()
 Called whenever the directory containing the selected file changes. More...
 
void Handle_CtrlA_CtrlBackspace (TextBox textBox, object sender, KeyEventArgs e)
 Handle the Ctrl-A (select all) and Ctrl-Backspace events for the specified text box. More...
 
override void Dispose (bool disposing)
 Clean up any resources being used. More...
 

Protected Attributes

string _containingDirectoryPath
 
string _directoryPath
 

Properties

bool FileTextBoxInitialized [get, set]
 
string InitialDirectoryPath [get, protected set]
 Directory where files are currently selected. More...
 
bool AllowEnvironmentVariables [get, set]
 If true then environment variables can be used in paths. More...
 
bool AllowExistentDirectories [get, set]
 If true then existent files are allowed to be selected. More...
 
bool AllowNonexistentDirectories [get, set]
 If true then non-existend files are allowed to be selected. More...
 
bool UseRelativePaths [get, set]
 If true then relative paths are used in representation of the selseted file path. More...
 
bool UseAbsolutePaths [get, set]
 If true then absolute paths are used in representation of the selseted file path. More...
 
bool UseFileDialog [get, set]
 If true then an OpenFileDialog is used to browse for directory, rather than Directorydialog bool UseFileDialog More...
 
string DirectoryPath [get, set]
 Path to the file that is currently selected. More...
 
string OriginalDirectoryPath [get, set]
 Gets the original file path representation (as set by user), without any post processing (like environment variables expansion or conversion to relative or absolute path). More...
 
virtual bool IsErrorState [get]
 Returns true if the current selection is invalid, false if it is valid. More...
 
virtual Color ErrorBackground [get, set]
 Background color of selection's text in case of error. More...
 
virtual Color ErrorForeground [get, set]
 Foreground color of button in case of error. More...
 
virtual Color NormalBackground [get, set]
 Background color of selection's text in case of NO error. More...
 
virtual Color NormalForeground [get, set]
 Foreground color of button in case of NO error. More...
 
bool IsBrowsable [get, set]
 Gets or sets the flag specifying whether one can browse for the file to be opened (e.g. by using the file selection dialog). More...
 
bool IsDragAndDrop [get, set]
 Whether the selector provides drag & drop capability. More...
 

Events

EventHandler DirectorySelected
 Event that is fired whenever the selected directory changes. More...
 
EventHandler DirectoryChanged
 Event that is fired whenever directory containing the selected file changes. More...
 

Private Member Functions

void btnFileBrowse_Click (object sender, EventArgs e)
 Browses for the file whose hashRet values will be calculated. More...
 
void txtFile_Click (object sender, EventArgs e)
 
void comboBoxFile_SelectedIndexChanged (object sender, EventArgs e)
 
void comboBoxFile_Enter (object sender, EventArgs e)
 
void comboBoxFile_Validated (object sender, EventArgs e)
 
void comboBoxFile_KeyUp (object sender, KeyEventArgs e)
 
void comboBoxFile_MouseEnter (object sender, EventArgs e)
 
void comboBoxFile_TextChanged (object sender, EventArgs e)
 
void FileSelector_DragEnter (object sender, DragEventArgs e)
 
void FileSelector_DragDrop (object sender, DragEventArgs e)
 
void menuClearHistory_Click (object sender, EventArgs e)
 
void menuAllowNonexistent_CheckedChanged (object sender, EventArgs e)
 
void menuAllowExistent_CheckedChanged (object sender, EventArgs e)
 
void menuExpandEnvironment_CheckedChanged (object sender, EventArgs e)
 
void menuAbsolutePaths_CheckedChanged (object sender, EventArgs e)
 
void menuRelativePaths_CheckedChanged (object sender, EventArgs e)
 
void menuPathRepresentation_Click (object sender, EventArgs e)
 
void menuInputTextBox_Click (object sender, EventArgs e)
 
void menuInputTextBox_Validated (object sender, EventArgs e)
 
void menuInputTextBox_KeyUp (object sender, KeyEventArgs e)
 
void menuAllowNonexistent_Click (object sender, EventArgs e)
 Reopens the context menu at its previous position. More...
 
void menuAllowExistent_Click (object sender, EventArgs e)
 Reopens the context menu at its previous position. More...
 
void menuExpandEnvironment_Click (object sender, EventArgs e)
 Reopens the context menu at its previous position. More...
 
void menuUseFileDialog_Click (object sender, EventArgs e)
 
void menuUseFileDialog_CheckedChanged (object sender, EventArgs e)
 
void menuAbsolutePaths_Click (object sender, EventArgs e)
 Reopens the context menu at its previous position. More...
 
void menuRelativePaths_Click (object sender, EventArgs e)
 Reopens the context menu at its previous position. More...
 
void contextMenuMain_Opened (object sender, EventArgs e)
 Stores the position where the menu item has last opened. More...
 
void InitializeComponent ()
 Required method for Designer support - do not modify the contents of this method with the code editor. More...
 
void btnFileBrowse_Click (object sender, EventArgs e)
 Browses for the file whose hashRet values will be calculated. More...
 
void txtFile_Click (object sender, EventArgs e)
 
void comboBoxFile_SelectedIndexChanged (object sender, EventArgs e)
 
void comboBoxFile_Enter (object sender, EventArgs e)
 
void comboBoxFile_Validated (object sender, EventArgs e)
 
void comboBoxFile_KeyUp (object sender, KeyEventArgs e)
 
void comboBoxFile_MouseEnter (object sender, EventArgs e)
 
void comboBoxFile_TextChanged (object sender, EventArgs e)
 
void FileSelector_DragEnter (object sender, DragEventArgs e)
 
void FileSelector_DragDrop (object sender, DragEventArgs e)
 
void menuClearHistory_Click (object sender, EventArgs e)
 
void menuAllowNonexistent_CheckedChanged (object sender, EventArgs e)
 
void menuAllowExistent_CheckedChanged (object sender, EventArgs e)
 
void menuExpandEnvironment_CheckedChanged (object sender, EventArgs e)
 
void menuAbsolutePaths_CheckedChanged (object sender, EventArgs e)
 
void menuRelativePaths_CheckedChanged (object sender, EventArgs e)
 
void menuPathRepresentation_Click (object sender, EventArgs e)
 
void menuInputTextBox_Click (object sender, EventArgs e)
 
void menuInputTextBox_Validated (object sender, EventArgs e)
 
void menuInputTextBox_KeyUp (object sender, KeyEventArgs e)
 
void menuAllowNonexistent_Click (object sender, EventArgs e)
 Reopens the context menu at its previous position. More...
 
void menuAllowExistent_Click (object sender, EventArgs e)
 Reopens the context menu at its previous position. More...
 
void menuExpandEnvironment_Click (object sender, EventArgs e)
 Reopens the context menu at its previous position. More...
 
void menuUseFileDialog_Click (object sender, EventArgs e)
 
void menuUseFileDialog_CheckedChanged (object sender, EventArgs e)
 
void menuAbsolutePaths_Click (object sender, EventArgs e)
 Reopens the context menu at its previous position. More...
 
void menuRelativePaths_Click (object sender, EventArgs e)
 Reopens the context menu at its previous position. More...
 
void contextMenuMain_Opened (object sender, EventArgs e)
 Stores the position where the menu item has last opened. More...
 
void InitializeComponent ()
 Required method for Designer support - do not modify the contents of this method with the code editor. More...
 

Private Attributes

bool _fileTextBoxInitialized = false
 
bool _allowEnvironmentVariables = true
 
bool _allowExistentDirectories = true
 
bool _allowNonexistentDirectories = true
 
bool _useRelativePaths = false
 
bool _useAbsolutePaths = false
 
bool _useFileDialog = true
 
Color _errorBackground = Color.Orange
 
Color _errorForeground = Color.Red
 
Color _normalBackground = Color.White
 
Color _normalforeground = Color.Black
 
bool _isBrowsable = true
 
bool _isDragAndDrop = true
 
bool _skipFileValidationEvent = false
 
Point _lasContectMenuPosition = new Point(0, 0)
 
System.ComponentModel.IContainer components = null
 Required designer variable. More...
 
System.Windows.Forms.Button btnFileBrowse
 
System.Windows.Forms.Label lblFile
 
System.Windows.Forms.FolderBrowserDialog openDirectoryDialog1
 
System.Windows.Forms.ComboBox comboBoxFile
 
System.Windows.Forms.ContextMenuStrip contextMenuMain
 
System.Windows.Forms.ToolStripMenuItem menuClearHistory
 
System.Windows.Forms.ToolStripMenuItem menuAllowNonexistent
 
System.Windows.Forms.ToolStripMenuItem menuAllowExistent
 
System.Windows.Forms.ToolStripMenuItem menuExpandEnvironment
 
System.Windows.Forms.ToolStripMenuItem menuAbsolutePaths
 
System.Windows.Forms.ToolStripMenuItem menuRelativePaths
 
System.Windows.Forms.ToolStripMenuItem menuShowPath
 
System.Windows.Forms.ToolStripMenuItem menuPathRepresentation
 
System.Windows.Forms.ToolStripMenuItem menuInputPath
 
System.Windows.Forms.ToolStripTextBox menuInputTextBox
 
System.Windows.Forms.ToolStripMenuItem menuUseFileDialog
 
System.Windows.Forms.OpenFileDialog openFileDialog1
 

Constructor & Destructor Documentation

IG.Forms.DirectorySelector.DirectorySelector ( )
inline
IG.Forms.DirectorySelector.DirectorySelector ( )
inline

Member Function Documentation

string IG.Forms.DirectorySelector.GetFilePathRepresentation ( string  directoryPath)
inline

Returns the presentational form of the specified directory path, with eventual environment variables expanded and with conversion to the appropriate form (relative or absolute).

Parameters
directoryPathDirectory path whose presentational form is returned.

Presentational form depends on the following properties: <pra> - AllowEnvironmentVariables: If true then environment variable references are expanded.

In Unix-like systems, enviironment variables are referenced as $varName, and on Windows with varName%.

</pra>

- UseAbsolutePaths: If true then paths are presented as absolute paths (independend of the current working directory).

- UseRelativePaths: If true then paths are represented relative to the current working directory.

References IG.Lib.UtilSystem.GetAbsolutePath(), and IG.Lib.UtilSystem.GetRelativePath().

virtual void IG.Forms.DirectorySelector.UpdateErrorState ( )
inlineprotectedvirtual

Updates controls according to error state.

void IG.Forms.DirectorySelector.BrowseDirectory ( )
inline

Browses for the file to be hashed.

void IG.Forms.DirectorySelector.ClearHistory ( )
inline
virtual void IG.Forms.DirectorySelector.OnDirectorySelected ( )
inlineprotectedvirtual

Called whenever the selected directory changes.

virtual void IG.Forms.DirectorySelector.OnDirectoryChanged ( )
inlineprotectedvirtual

Called whenever the directory containing the selected file changes.

void IG.Forms.DirectorySelector.btnFileBrowse_Click ( object  sender,
EventArgs  e 
)
inlineprivate

Browses for the file whose hashRet values will be calculated.

void IG.Forms.DirectorySelector.Handle_CtrlA_CtrlBackspace ( TextBox  textBox,
object  sender,
KeyEventArgs  e 
)
inlineprotected

Handle the Ctrl-A (select all) and Ctrl-Backspace events for the specified text box.

Parameters
textBoxText box for wich the event is handled.
void IG.Forms.DirectorySelector.txtFile_Click ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.comboBoxFile_SelectedIndexChanged ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.comboBoxFile_Enter ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.comboBoxFile_Validated ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.comboBoxFile_KeyUp ( object  sender,
KeyEventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.comboBoxFile_MouseEnter ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.comboBoxFile_TextChanged ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.FileSelector_DragEnter ( object  sender,
DragEventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.FileSelector_DragDrop ( object  sender,
DragEventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuClearHistory_Click ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuAllowNonexistent_CheckedChanged ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuAllowExistent_CheckedChanged ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuExpandEnvironment_CheckedChanged ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuAbsolutePaths_CheckedChanged ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuRelativePaths_CheckedChanged ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuPathRepresentation_Click ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuInputTextBox_Click ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuInputTextBox_Validated ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuInputTextBox_KeyUp ( object  sender,
KeyEventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuAllowNonexistent_Click ( object  sender,
EventArgs  e 
)
inlineprivate

Reopens the context menu at its previous position.

void IG.Forms.DirectorySelector.menuAllowExistent_Click ( object  sender,
EventArgs  e 
)
inlineprivate

Reopens the context menu at its previous position.

void IG.Forms.DirectorySelector.menuExpandEnvironment_Click ( object  sender,
EventArgs  e 
)
inlineprivate

Reopens the context menu at its previous position.

void IG.Forms.DirectorySelector.menuUseFileDialog_Click ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuUseFileDialog_CheckedChanged ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuAbsolutePaths_Click ( object  sender,
EventArgs  e 
)
inlineprivate

Reopens the context menu at its previous position.

void IG.Forms.DirectorySelector.menuRelativePaths_Click ( object  sender,
EventArgs  e 
)
inlineprivate

Reopens the context menu at its previous position.

void IG.Forms.DirectorySelector.contextMenuMain_Opened ( object  sender,
EventArgs  e 
)
inlineprivate

Stores the position where the menu item has last opened.

override void IG.Forms.DirectorySelector.Dispose ( bool  disposing)
inlineprotected

Clean up any resources being used.

Parameters
disposingtrue if managed resources should be disposed; otherwise, false.
void IG.Forms.DirectorySelector.InitializeComponent ( )
inlineprivate

Required method for Designer support - do not modify the contents of this method with the code editor.

string IG.Forms.DirectorySelector.GetFilePathRepresentation ( string  directoryPath)
inline

Returns the presentational form of the specified directory path, with eventual environment variables expanded and with conversion to the appropriate form (relative or absolute).

Parameters
directoryPathDirectory path whose presentational form is returned.

Presentational form depends on the following properties: <pra> - AllowEnvironmentVariables: If true then environment variable references are expanded.

In Unix-like systems, enviironment variables are referenced as $varName, and on Windows with varName%.

</pra>

- UseAbsolutePaths: If true then paths are presented as absolute paths (independend of the current working directory).

- UseRelativePaths: If true then paths are represented relative to the current working directory.

References IG.Lib.UtilSystem.GetAbsolutePath(), and IG.Lib.UtilSystem.GetRelativePath().

virtual void IG.Forms.DirectorySelector.UpdateErrorState ( )
inlineprotectedvirtual

Updates controls according to error state.

void IG.Forms.DirectorySelector.BrowseDirectory ( )
inline

Browses for the file to be hashed.

void IG.Forms.DirectorySelector.ClearHistory ( )
inline
virtual void IG.Forms.DirectorySelector.OnDirectorySelected ( )
inlineprotectedvirtual

Called whenever the selected directory changes.

virtual void IG.Forms.DirectorySelector.OnDirectoryChanged ( )
inlineprotectedvirtual

Called whenever the directory containing the selected file changes.

void IG.Forms.DirectorySelector.btnFileBrowse_Click ( object  sender,
EventArgs  e 
)
inlineprivate

Browses for the file whose hashRet values will be calculated.

void IG.Forms.DirectorySelector.Handle_CtrlA_CtrlBackspace ( TextBox  textBox,
object  sender,
KeyEventArgs  e 
)
inlineprotected

Handle the Ctrl-A (select all) and Ctrl-Backspace events for the specified text box.

Parameters
textBoxText box for wich the event is handled.
void IG.Forms.DirectorySelector.txtFile_Click ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.comboBoxFile_SelectedIndexChanged ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.comboBoxFile_Enter ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.comboBoxFile_Validated ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.comboBoxFile_KeyUp ( object  sender,
KeyEventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.comboBoxFile_MouseEnter ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.comboBoxFile_TextChanged ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.FileSelector_DragEnter ( object  sender,
DragEventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.FileSelector_DragDrop ( object  sender,
DragEventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuClearHistory_Click ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuAllowNonexistent_CheckedChanged ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuAllowExistent_CheckedChanged ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuExpandEnvironment_CheckedChanged ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuAbsolutePaths_CheckedChanged ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuRelativePaths_CheckedChanged ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuPathRepresentation_Click ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuInputTextBox_Click ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuInputTextBox_Validated ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuInputTextBox_KeyUp ( object  sender,
KeyEventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuAllowNonexistent_Click ( object  sender,
EventArgs  e 
)
inlineprivate

Reopens the context menu at its previous position.

void IG.Forms.DirectorySelector.menuAllowExistent_Click ( object  sender,
EventArgs  e 
)
inlineprivate

Reopens the context menu at its previous position.

void IG.Forms.DirectorySelector.menuExpandEnvironment_Click ( object  sender,
EventArgs  e 
)
inlineprivate

Reopens the context menu at its previous position.

void IG.Forms.DirectorySelector.menuUseFileDialog_Click ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuUseFileDialog_CheckedChanged ( object  sender,
EventArgs  e 
)
inlineprivate
void IG.Forms.DirectorySelector.menuAbsolutePaths_Click ( object  sender,
EventArgs  e 
)
inlineprivate

Reopens the context menu at its previous position.

void IG.Forms.DirectorySelector.menuRelativePaths_Click ( object  sender,
EventArgs  e 
)
inlineprivate

Reopens the context menu at its previous position.

void IG.Forms.DirectorySelector.contextMenuMain_Opened ( object  sender,
EventArgs  e 
)
inlineprivate

Stores the position where the menu item has last opened.

override void IG.Forms.DirectorySelector.Dispose ( bool  disposing)
inlineprotected

Clean up any resources being used.

Parameters
disposingtrue if managed resources should be disposed; otherwise, false.
void IG.Forms.DirectorySelector.InitializeComponent ( )
inlineprivate

Required method for Designer support - do not modify the contents of this method with the code editor.

Member Data Documentation

bool IG.Forms.DirectorySelector._fileTextBoxInitialized = false
private
string IG.Forms.DirectorySelector._containingDirectoryPath
protected
bool IG.Forms.DirectorySelector._allowEnvironmentVariables = true
private
bool IG.Forms.DirectorySelector._allowExistentDirectories = true
private
bool IG.Forms.DirectorySelector._allowNonexistentDirectories = true
private
bool IG.Forms.DirectorySelector._useRelativePaths = false
private
bool IG.Forms.DirectorySelector._useAbsolutePaths = false
private
bool IG.Forms.DirectorySelector._useFileDialog = true
private
string IG.Forms.DirectorySelector._directoryPath
protected
Color IG.Forms.DirectorySelector._errorBackground = Color.Orange
private
Color IG.Forms.DirectorySelector._errorForeground = Color.Red
private
Color IG.Forms.DirectorySelector._normalBackground = Color.White
private
Color IG.Forms.DirectorySelector._normalforeground = Color.Black
private
bool IG.Forms.DirectorySelector._isBrowsable = true
private
bool IG.Forms.DirectorySelector._isDragAndDrop = true
private
bool IG.Forms.DirectorySelector._skipFileValidationEvent = false
private
Point IG.Forms.DirectorySelector._lasContectMenuPosition = new Point(0, 0)
private
System ComponentModel IContainer IG.Forms.DirectorySelector.components = null
private

Required designer variable.

System Windows Forms Button IG.Forms.DirectorySelector.btnFileBrowse
private
System Windows Forms Label IG.Forms.DirectorySelector.lblFile
private
System Windows Forms FolderBrowserDialog IG.Forms.DirectorySelector.openDirectoryDialog1
private
System Windows Forms ComboBox IG.Forms.DirectorySelector.comboBoxFile
private
System Windows Forms ContextMenuStrip IG.Forms.DirectorySelector.contextMenuMain
private
System Windows Forms ToolStripMenuItem IG.Forms.DirectorySelector.menuClearHistory
private
System Windows Forms ToolStripMenuItem IG.Forms.DirectorySelector.menuAllowNonexistent
private
System Windows Forms ToolStripMenuItem IG.Forms.DirectorySelector.menuAllowExistent
private
System Windows Forms ToolStripMenuItem IG.Forms.DirectorySelector.menuExpandEnvironment
private
System Windows Forms ToolStripMenuItem IG.Forms.DirectorySelector.menuAbsolutePaths
private
System Windows Forms ToolStripMenuItem IG.Forms.DirectorySelector.menuRelativePaths
private
System Windows Forms ToolStripMenuItem IG.Forms.DirectorySelector.menuShowPath
private
System Windows Forms ToolStripMenuItem IG.Forms.DirectorySelector.menuPathRepresentation
private
System Windows Forms ToolStripMenuItem IG.Forms.DirectorySelector.menuInputPath
private
System Windows Forms ToolStripTextBox IG.Forms.DirectorySelector.menuInputTextBox
private
System Windows Forms ToolStripMenuItem IG.Forms.DirectorySelector.menuUseFileDialog
private
System Windows Forms OpenFileDialog IG.Forms.DirectorySelector.openFileDialog1
private

Property Documentation

bool IG.Forms.DirectorySelector.FileTextBoxInitialized
getsetprotected
string IG.Forms.DirectorySelector.InitialDirectoryPath
getprotected set

Directory where files are currently selected.

bool IG.Forms.DirectorySelector.AllowEnvironmentVariables
getset

If true then environment variables can be used in paths.

bool IG.Forms.DirectorySelector.AllowExistentDirectories
getset

If true then existent files are allowed to be selected.

It might be impossible to insert such a path through the file dialog (launched by the "Browse" button), but one can insert it in the text box.

bool IG.Forms.DirectorySelector.AllowNonexistentDirectories
getset

If true then non-existend files are allowed to be selected.

It might be impossible to insert such a path through the file dialog (launched by the "Browse" button), but one can insert it in the text box.

bool IG.Forms.DirectorySelector.UseRelativePaths
getset

If true then relative paths are used in representation of the selseted file path.

This property is mutually exclusive with UseAbsolutePaths (only one can be true, but both can be false).

bool IG.Forms.DirectorySelector.UseAbsolutePaths
getset

If true then absolute paths are used in representation of the selseted file path.

This property is mutually exclusive with UseRelativePaths (only one can be true, but both can be false).

bool IG.Forms.DirectorySelector.UseFileDialog
getsetprivate

If true then an OpenFileDialog is used to browse for directory, rather than Directorydialog bool UseFileDialog

string IG.Forms.DirectorySelector.DirectoryPath
getset

Path to the file that is currently selected.

Getter returns the output representation of the path, with eventual environment variables expansion (dependent on AllowEnvironmentVariables properties) and in appropriate form (relative or absolute path, according to UseRelativePaths and UseAbsolutePaths properties).

Original path ca be retrieved by the OriginalDirectoryPath property.

string IG.Forms.DirectorySelector.OriginalDirectoryPath
getset

Gets the original file path representation (as set by user), without any post processing (like environment variables expansion or conversion to relative or absolute path).

Setter just calls the setter of the DirectoryPath property.

bool IG.Forms.DirectorySelector.IsErrorState
get

Returns true if the current selection is invalid, false if it is valid.

In the case of invalid selection, OriginalDirectoryPath may return a non-null path but DirectoryPath does not.

Color IG.Forms.DirectorySelector.ErrorBackground
getset

Background color of selection's text in case of error.

Color IG.Forms.DirectorySelector.ErrorForeground
getset

Foreground color of button in case of error.

Color IG.Forms.DirectorySelector.NormalBackground
getset

Background color of selection's text in case of NO error.

Color IG.Forms.DirectorySelector.NormalForeground
getset

Foreground color of button in case of NO error.

bool IG.Forms.DirectorySelector.IsBrowsable
getset

Gets or sets the flag specifying whether one can browse for the file to be opened (e.g. by using the file selection dialog).

If the viewer does not at all have browser capability then setting to true should NOT throw an exception (therefore, the user should verify by getter if setting actually worked).

Setter can be used to disable browsing (e.g. for security, or when used as embedded control and browsing would be disturbing).

bool IG.Forms.DirectorySelector.IsDragAndDrop
getset

Whether the selector provides drag & drop capability.

Setter can be used to disable drag & drop (e.g. for security, or when used with an embedded control and drag & drop would be disturbing).

Event Documentation

EventHandler IG.Forms.DirectorySelector.DirectorySelected

Event that is fired whenever the selected directory changes.

EventHandler IG.Forms.DirectorySelector.DirectoryChanged

Event that is fired whenever directory containing the selected file changes.


The documentation for this class was generated from the following files: