ExplorerUserControl.cs
Description du code
ExplorerUserControl.cs est un fichier du projet BrolExplorer.Ce fichier est situé dans /var/www/bin/sniplets/bibliobrol/brolexplorer/.
Projet BrolExplorer :
Explorateur de media en CSharp.
Code source ou contenu du fichier
Code c# (ExplorerUserControl.cs) (1069 lignes)
using System; using System.Collections.Generic; using System.ComponentModel; using System.Drawing; using System.Data; using System.Text; using System.Windows.Forms; using be.gaudry.explorer.model; using System.IO; using be.gaudry.explorer.view; using System.Collections; using be.gaudry.events; using be.gaudry.explorer.filestats.view.controls; using be.gaudry.model.config; using be.gaudry.model.drawing; using be.gaudry.model; using be.gaudry.model.file; using be.gaudry.explorer.metadata.model.tags; using be.gaudry.explorer.metadata.view.dialogs; namespace be.gaudry.explorer.view.controls { public partial class ExplorerUserControl : UserControl { #region constructor and declarations private String shell32Path; private BrolFileStatsControl statsControl; #region treeview private int imageIndex_Desktop, imageIndex_MyDocuments, imageIndex_MyPictures, imageIndex_MyFavorites, imageIndex_MyNetwork, imageIndex_MyComuter, imageIndex_HardDrive, imageIndex_DirectoryNormal, imageIndex_DirectoryExpanded; private String desktopName, myComputerName, myDocumentsName, myPicturesName, myFavoriteName, myNetworkName; private bool showMyDocuments, showMyPictures, showMyFavorites, showMyNetwork, showDesktop; #endregion /// <summary> /// Type of view (explorer or images) used to dislpay the files in the fileListView /// </summary> public enum FILES_DISPLAY { /// <summary> /// Displays an explorer on the right panel /// </summary> explorer, /// <summary> /// Displays an image browser the right panel /// </summary> images, /// <summary> /// Displays a stat view on the right panel /// </summary> stats }; private FILES_DISPLAY display; #region listview private bool groupIcons; // Declare a Hashtable array in which to store the groups. private Hashtable[] groupTables; // Declare a variable to store the current grouping column. int groupColumn = 0; #endregion public ExplorerUserControl() { shell32Path = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.System), "shell32.dll"); groupIcons = false; showMyDocuments = true; showMyPictures = true; showMyFavorites = true; showMyNetwork = true; showDesktop = true; desktopName = "Bureau"; myComputerName = "Poste de travail"; myDocumentsName = "Mes documents"; myPicturesName = "Mes images"; myFavoriteName = "Mes favoris"; myNetworkName = "Favoris réseau"; InitializeComponent(); imagesBrowser.setContextMenuStrip(filesListViewCMS); initStatControl(); toogleIconsGroups(); addSources(); } private void addSources() { "Listview", this.Name, "http://msdn2.microsoft.com/fr-fr/library/z4ka5fex(VS.80).aspx", "Composant utilisé à droite dans l'explorateur" ) ); "Context menu", this.Name, "http://support.microsoft.com/kb/810001/fr", "Un menu contextuel pour treenode" ) ); "Shell Context menu", this.Name, "http://www.theserverside.net/tt/articles/showarticle.tss?id=ShellExtensions", "Context menu utilisant certaines fonctionnalités du shell32" ) ); "Groupes ListView", this.Name, "http://msdn2.microsoft.com/fr-fr/library/system.windows.forms.listviewitem.group(VS.80).aspx", "Utilisation de l'affichage par groupes dans le listview" ) ); } private void initStatControl() { //todo : test if stats exe exists this.explorerSC.Panel2.Controls.Add(this.statsControl); // statsControl.mainCMS.Items.AddRange(filesListViewCMS.Items); statsCTsMi.DropDownItems.Add(statsControl.searchOptionsTsMi); statsCTsMi.DropDownItems.Add(statsControl.displayOptionsTsMi); showStatsOptions(false); statsControl.ContextMenuStrip = filesListViewCMS; this.statsControl.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D; this.statsControl.Dock = System.Windows.Forms.DockStyle.Fill; this.statsControl.Visible = false; } #endregion #region properties [ Category("Action"), Browsable(true), Description("Event called on file selected") ] public event FileSelectedEventHandler FileSelected; [ Category("Action"), Browsable(true), Description("Event called on directory selected") ] public event FileSelectedEventHandler DirectorySelected; /// <summary> /// Show Desktop node /// </summary> [ Category("Explorer options"), Description("Show Desktop node") ] public bool ShowDesktop { get { return showDesktop; } set { showDesktop = value; refreshTreeView(); } } /// <summary> /// Show MyDocument node /// </summary> [ Category("Explorer options"), Description("Show MyDocument node") ] public bool ShowMyDocuments { get { return showMyDocuments; } set { showMyDocuments = value; refreshTreeView(); } } /// <summary> /// Show MyPictures node /// </summary> [ Category("Explorer options"), Description("Show MyPictures node") ] public bool ShowMyPictures { get { return showMyPictures; } set { showMyPictures = value; refreshTreeView(); } } /// <summary> /// Show MyFavorites node /// </summary> [ Category("Explorer options"), Description("Show MyFavorites node") ] public bool ShowMyFavorites { get { return showMyFavorites; } set { showMyFavorites = value; refreshTreeView(); } } /// <summary> /// Show MyNetwork node /// </summary> [ Category("Explorer options"), Description("Show MyNetwork node") ] public bool ShowMyNetwork { get { return showMyNetwork; } set { showMyNetwork = value; refreshTreeView(); } } /// <summary> /// Type of explorer view used to dislpay the files in the fileListView /// </summary> [ Category("Explorer options"), Description("Type of explorer view used to dislpay the files in the fileListView") ] public System.Windows.Forms.View View { get { return filesListView.View; } set { this.filesListView.View = value; } } /// <summary> /// Type of view (explorer or images) used to dislpay the files in the fileListView /// </summary> [ Category("Explorer options"), Description("Type of view (explorer or images) used to dislpay the files in the fileListView") ] public FILES_DISPLAY Display { get { return display; } set { if (this.display != value) { this.display = value; editImageTSB.Enabled = false; switch (display) { case FILES_DISPLAY.explorer: statsControl.Visible = false; imagesBrowser.Visible = false; filesListView.Visible = true; showStatsOptions(false); break; case FILES_DISPLAY.images: imagesBrowser.setThumbsForDirectory(addressTSTB.Text); statsControl.Visible = false; imagesBrowser.Visible = true; filesListView.Visible = false; showStatsOptions(false); break; case FILES_DISPLAY.stats: statsControl.Visible = true; statsControl.parse(addressTSTB.Text); imagesBrowser.Visible = false; filesListView.Visible = false; showStatsOptions(true); break; } } } } #endregion #region form events private void ExplorerUserControl_Load(object sender, EventArgs e) { String ttFormat = "Afficher ou masquer l'élément \"{0}\""; imageIndex_DirectoryNormal = directoriesImageList.Images.Add(IconExtractor.ExtractIcon(shell32Path, 3).ToBitmap(), Color.Transparent); imageIndex_DirectoryExpanded = directoriesImageList.Images.Add(IconExtractor.ExtractIcon(shell32Path, 4).ToBitmap(), Color.Transparent); imageIndex_Desktop = directoriesImageList.Images.Add(IconExtractor.ExtractIcon(shell32Path, 34).ToBitmap(), Color.Transparent); showDesktopTSB.Image = directoriesImageList.Images[imageIndex_Desktop]; showDesktopTSB.ToolTipText = String.Format(ttFormat, desktopName); imageIndex_MyDocuments = directoriesImageList.Images.Add(IconExtractor.ExtractIcon(shell32Path, 126).ToBitmap(), Color.Transparent); showMyDocumentsTSB.Image = directoriesImageList.Images[imageIndex_MyDocuments]; showMyDocumentsTSB.ToolTipText = String.Format(ttFormat, myDocumentsName); imageIndex_MyPictures = directoriesImageList.Images.Add(IconExtractor.ExtractIcon(shell32Path, 127).ToBitmap(), Color.Transparent); showMyPicturesTSB.Image = directoriesImageList.Images[imageIndex_MyPictures]; showMyPicturesTSB.ToolTipText = String.Format(ttFormat, myPicturesName); imageIndex_MyFavorites = directoriesImageList.Images.Add(IconExtractor.ExtractIcon(shell32Path, 43).ToBitmap(), Color.Transparent); showMyFavouritesTSB.Image = directoriesImageList.Images[imageIndex_MyFavorites]; showMyFavouritesTSB.ToolTipText = String.Format(ttFormat, myFavoriteName); imageIndex_MyNetwork = directoriesImageList.Images.Add(IconExtractor.ExtractIcon(shell32Path, 17).ToBitmap(), Color.Transparent); showNetworksTSB.Image = directoriesImageList.Images[imageIndex_MyNetwork]; showNetworksTSB.ToolTipText = String.Format(ttFormat, myNetworkName); imageIndex_MyComuter = directoriesImageList.Images.Add(IconExtractor.ExtractIcon(shell32Path, 15).ToBitmap(), Color.Transparent); imageIndex_HardDrive = directoriesImageList.Images.Add(IconExtractor.ExtractIcon(shell32Path, 8).ToBitmap(), Color.Transparent); filesListView.LargeImageList = largeIconList.ImageList; largeIconList.ImageList.ColorDepth = ColorDepth.Depth32Bit; filesListView.SmallImageList = smallIconList.ImageList; filesListView.StateImageList = smallIconList.ImageList; smallIconList.ImageList.ColorDepth = ColorDepth.Depth32Bit; refreshTreeView(); } #endregion #region treeView #region drives private void addDriveNode(String driveName, DirectoryTreeNode node) { //DriveInfo di = new DriveInfo(driveName); //DirectoryTreeNode n = new DirectoryTreeNode(new DirectoryInfo(path)); n.ImageIndex = directoriesImageList.Images.Add(dih.Icon, Color.Transparent); ; n.SelectedImageIndex = n.ImageIndex; node.Nodes.Add(n); } #endregion private void refreshTreeView() { directoriesTreeView.BeginUpdate(); directoriesTreeView.Nodes.Clear(); if (showDesktop) { desktopNode.ImageIndex = imageIndex_Desktop; desktopNode.SelectedImageIndex = imageIndex_Desktop; directoriesTreeView.Nodes.Add(desktopNode); } myComputerNode.Text = myComputerName; myComputerNode.ImageIndex = imageIndex_MyComuter; myComputerNode.SelectedImageIndex = imageIndex_MyComuter; //myComputerNode.Expand(); directoriesTreeView.Nodes.Add(myComputerNode); if (showMyDocuments) { imageIndex_MyDocuments ); myDocsNode.Text = myDocumentsName; directoriesTreeView.Nodes.Add(myDocsNode); } if (showMyPictures) { imageIndex_MyPictures ); //myPicsNode.Text = myPicturesName; directoriesTreeView.Nodes.Add(myPicsNode); } if (showMyFavorites) { imageIndex_MyFavorites ); //myFavNode.Text = myFavoriteName; directoriesTreeView.Nodes.Add(myFavNode); } /*if (showMyNetwork) { DirectoryTreeNode myNetNode = new DirectoryTreeNode( new DirectoryInfo(Environment.GetFolderPath(Environment.SpecialFolder.n)), imageIndex_MyNetwork ); //myNetNode.Text = myNetworkName; myNetNode.Nodes.Add(new DirectoryTreeNode()); directoriesTreeView.Nodes.Add(myNetNode); }*/ directoriesTreeView.EndUpdate(); } private void directoriesTreeView_BeforeExpand(object sender, TreeViewCancelEventArgs e) { Cursor.Current = Cursors.WaitCursor; DirectoryTreeNode node = e.Node as DirectoryTreeNode; if (node == null) return; if ((e.Action & TreeViewAction.Expand) == TreeViewAction.Expand) { node.Nodes.Clear(); DirectoryTreeNode childnode; if (node.DirectoryInfo != null) { try { foreach (DirectoryInfo directory in node.DirectoryInfo.GetDirectories()) { childnode.ImageIndex = imageIndex_DirectoryNormal; childnode.SelectedImageIndex = imageIndex_DirectoryNormal; node.Nodes.Add(childnode); } } catch (Exception ex) { MessageBox.Show( this, String.Format( "Impossible de lire sur {0} \n\nType d'erreur : {1}", node.DirectoryInfo.FullName, ex.Message ), "Erreur de lecture", MessageBoxButtons.OK, MessageBoxIcon.Warning ); } } else if(node.Text.Equals(myComputerName)) { foreach (String name in Environment.GetLogicalDrives()) { addDriveNode(name, node); } } } } private void directoriesTreeView_AfterExpand(object sender, TreeViewEventArgs e) { Cursor.Current = DefaultCursor; if (e.Node.ImageIndex == imageIndex_DirectoryNormal) { e.Node.ImageIndex = imageIndex_DirectoryExpanded; e.Node.SelectedImageIndex = imageIndex_DirectoryExpanded; } } private void directoriesTreeView_AfterCollapse(object sender, TreeViewEventArgs e) { if (e.Node.ImageIndex == imageIndex_DirectoryExpanded) { e.Node.ImageIndex = imageIndex_DirectoryNormal; e.Node.SelectedImageIndex = imageIndex_DirectoryNormal; } } private void directoriesTreeView_AfterSelect(object sender, TreeViewEventArgs e) { Cursor.Current = Cursors.WaitCursor; DirectoryTreeNode node = e.Node as DirectoryTreeNode; if (node == null) return; if (node.DirectoryInfo != null) { addressTSTB.Text = node.DirectoryInfo.FullName; } else { addressTSTB.Text = node.Text; } if (statsControl != null) { if (statsControl.Visible) { statsControl.parse(addressTSTB.Text); } else { statsControl.setStartPath(addressTSTB.Text); } } switch (display) { case FILES_DISPLAY.explorer: filesListView.BeginUpdate(); if (node.DirectoryInfo != null) { setFileListViewItems(node.DirectoryInfo); } else { filesListView.Items.Clear(); } filesListView.EndUpdate(); break; case FILES_DISPLAY.images: imagesBrowser.setThumbsForDirectory(addressTSTB.Text); break; } Cursor.Current = DefaultCursor; } #endregion #region show items tsb private void showDesktopTSB_Click(object sender, EventArgs e) { } private void showMyDocumentsTSB_Click(object sender, EventArgs e) { } private void showMyPicturesTSB_Click(object sender, EventArgs e) { } private void showMyFavouritesTSB_Click(object sender, EventArgs e) { } private void showNetworksTSB_Click(object sender, EventArgs e) { } #endregion #region private methods private void toggleEditImageTSB_Click(object sender, EventArgs e) { } #endregion private void imagesBrowser_FileSelected(object sender, string filePath) { editImageTSB.Enabled = !String.Empty.Equals(filePath); if (FileSelected != null) FileSelected( sender, filePath ); } private void collapseTreeTSB_Click(object sender, EventArgs e) { explorerSC.Panel1Collapsed = !explorerSC.Panel1Collapsed; } #region listview features private void setFileListViewItems(DirectoryInfo di) { filesListView.Items.Clear(); try { ListViewItem item; foreach (DirectoryInfo di2 in di.GetDirectories()) { item = filesListView.Items.Add( di2.Name, "",//length "Répertoire",//ext, di2.LastAccessTime.ToLongDateString(), "" }) ); item.ImageIndex = largeIconList[di2.FullName]; smallIconList.addIcon(di2.FullName); item.ToolTipText = "Répertoire :\n"+FileTagHelper.getProperty(di2.FullName,FILE_TAG.GeneralTipInformation); item.Tag = di2.FullName; } foreach (FileInfo file in di.GetFiles()) { item = filesListView.Items.Add( file.Name, Units.getLengthString(file.Length), file.Extension, file.LastAccessTime.ToLongDateString(), file.Length.ToString() }) ); item.ImageIndex = largeIconList[file.FullName]; smallIconList.addIcon(file.FullName); item.ToolTipText = "Fichier :\n" + FileTagHelper.getProperty(file.FullName, FILE_TAG.GeneralTipInformation); item.Tag = file.FullName; } if (groupIcons) { //if (groupTables == null) //{ // Create the groupsTable array and populate it with one // hash table for each column. for (int column = 0; column < filesListView.Columns.Count; column++) { // Create a hash table containing all the groups // needed for a single column. groupTables[column] = CreateGroupsTable(column); } //} // Start with the groups created for the ParameterTitle column. SetGroups(0); } } catch (UnauthorizedAccessException) { MessageBox.Show(this, "Accès refusé", di.FullName, MessageBoxButtons.OK, MessageBoxIcon.Warning); } catch (Exception) { } } #region sort files // Groups the items using the groups created for the clicked // column. private void filesListView_ColumnClick(object sender, ColumnClickEventArgs e) { sortFilesListView(e.Column); } private void sortFilesListView(int columnIndex) { // Set the sort order to ascending when changing // column groups; otherwise, reverse the sort order. if (filesListView.Sorting == SortOrder.Descending || (groupIcons && (columnIndex != groupColumn))) { filesListView.Sorting = SortOrder.Ascending; } else { filesListView.Sorting = SortOrder.Descending; } groupColumn = columnIndex; // Set the groups to those created for the clicked column. if (groupIcons) { SetGroups(columnIndex); } } private void iconsOrderByNameTsMi_Click(object sender, EventArgs e) { sortFilesListView(filesListView.Columns.IndexOf(fileNameColumnHeader)); } private void iconsOrderBySizeTsMi_Click(object sender, EventArgs e) { sortFilesListView(filesListView.Columns.IndexOf(fileLengthColumnHeader)); } private void iconsOrderByTypeTsMi_Click(object sender, EventArgs e) { sortFilesListView(filesListView.Columns.IndexOf(fileTypeColumnHeader)); } private void iconsOrderByModDateTsMi_Click(object sender, EventArgs e) { sortFilesListView(filesListView.Columns.IndexOf(fileDateColumnHeader)); } #endregion #region group files private void toogleIconsGroups() { // Determine whether Windows XP or a later operating system is present. if (OSFeature.Feature.IsPresent(OSFeature.Themes)) { groupIcons = !groupIcons; try { } catch (Exception) { } } else groupIcons = false; } // Sets filesListView to the groups created for the specified column. private void SetGroups(int column) { // Remove the current groups. filesListView.Groups.Clear(); // Retrieve the hash table corresponding to the column. Hashtable groups = (Hashtable)groupTables[column]; // Copy the groups for the column to an array. groups.Values.CopyTo(groupsArray, 0); // Sort the groups and add them to filesListView. filesListView.Groups.AddRange(groupsArray); // Iterate through the items in filesListView, assigning each // one to the appropriate group. foreach (ListViewItem item in filesListView.Items) { // Retrieve the subitem text corresponding to the column. string subItemText = item.SubItems[column].Text; // For the Name column, use only the first letter. subItemText = getSubItemText(column, subItemText); // Assign the item to the matching group. item.Group = (ListViewGroup)groups[subItemText]; } } // Creates a Hashtable object with one entry for each unique // subitem value (or initial letter for the parent item) // in the specified column. private Hashtable CreateGroupsTable(int column) { // Create a Hashtable object. // Iterate through the items in filesListView. foreach (ListViewItem item in filesListView.Items) { // Retrieve the text value for the column. string subItemText = item.SubItems[column].Text; // Use the initial letter instead if it is the first column. subItemText = getSubItemText(column, subItemText); // If the groups table does not already contain a group // for the subItemText value, add a new group using the // subItemText value for the group header and Hashtable key. if (!groups.Contains(subItemText)) { groups.Add( subItemText, new ListViewGroup( subItemText, HorizontalAlignment.Left ) ); } } // Return the Hashtable object. return groups; } private void iconsDisplayGroupsTsMi_Click(object sender, EventArgs e) { toogleIconsGroups(); } #endregion private void filesListView_ItemSelectionChanged(object sender, ListViewItemSelectionChangedEventArgs e) { if (e.Item.Selected) { filesListView.ContextMenuStrip = fileSelectedCMS; fileNameTsMi.Text = e.Item.Text; fileNameTsMi.ToolTipText = e.Item.Tag.ToString(); /* ListView lw = (ListView)sender; Point pt = e.Item.Position; string[] strFiles = new string[lw.SelectedItems.Count]; for (int i = 0; i < strFiles.Length; i++) { strFiles[i] = lw.SelectedItems[i].Tag.ToString(); } be.gaudry.model.win32.SysCntxtMenu.ShowContextMenu(this.Handle, strFiles, pt.X, pt.Y, true); */ } else { filesListView.ContextMenuStrip = filesListViewCMS; } if (FileSelected != null && e.Item.Selected) { editImageTSB.Enabled = ImageHelper.isImg(e.Item.Tag.ToString()); FileSelected( filesListView, //filesListView.FocusedItem.ToolTipText e.Item.Tag.ToString() ); } } private void filesListView_DoubleClick(object sender, EventArgs e) { if (filesListView.FocusedItem.SubItems[fileTypeColumnHeader.Index].Text.Equals("Répertoire")) { /*MessageBox.Show( this, "Les actions sur les répertoires ne sont pas encore implémentées...", "Aucune action associée", MessageBoxButtons.OK, MessageBoxIcon.Information );*/ FileHelper.openFileProperties(filesListView.FocusedItem.Tag.ToString()); } else { FileHelper.open( filesListView.FocusedItem.Tag.ToString(), "BrolExplorer" ); } } private String getSubItemText(int columnId, String subItemText) { switch (columnId) { case 0 : return subItemText.Substring(0, 1).ToUpper(); case 1: /*long fileLength = long.Parse(subItemText); long reduc = 1048576;//1024*1024 long result; Math.DivRem(fileLength, reduc, out result); subItemText = BrolFile.getFileSize(result > 0 ? result * reduc : fileLength); */ return subItemText; case 2: //todo : get mime type return subItemText; default: return subItemText; } } #endregion #region listview comparator // Sorts ListViewGroup objects by header value. private class ListViewGroupSorter : IComparer { private SortOrder order; // Stores the sort order. public ListViewGroupSorter(SortOrder theOrder) { order = theOrder; } // Compares the groups by header value, using the saved sort // order to return the correct value. public int Compare(object x, object y) { int result = String.Compare( ((ListViewGroup)x).Header, ((ListViewGroup)y).Header ); if (order == SortOrder.Ascending) { return result; } else { return -result; } } } #endregion #region display menu private void stripTsMi_Click(object sender, EventArgs e) { Display = FILES_DISPLAY.images; } private void smallIconsTsMi_Click(object sender, EventArgs e) { Display = FILES_DISPLAY.explorer; View = System.Windows.Forms.View.SmallIcon; } private void tileTsMi_Click(object sender, EventArgs e) { Display = FILES_DISPLAY.explorer; View = System.Windows.Forms.View.Tile; } private void largeIconsTsMi_Click(object sender, EventArgs e) { Display = FILES_DISPLAY.explorer; View = System.Windows.Forms.View.LargeIcon; } private void listTsMi_Click(object sender, EventArgs e) { Display = FILES_DISPLAY.explorer; View = System.Windows.Forms.View.List; } private void detailsTsMi_Click(object sender, EventArgs e) { Display = FILES_DISPLAY.explorer; View = System.Windows.Forms.View.Details; } private void statsTsMi_Click(object sender, EventArgs e) { Display = FILES_DISPLAY.stats; } private void showStatsOptions(bool show) { foreach (ToolStripMenuItem tsMi in statsCTsMi.DropDownItems) { tsMi.Visible = show; } } #endregion private void explorerTS_Resize(object sender, EventArgs e) { int w = explorerTS.Width - ( addressTSL.Width + addressTSL.Margin.Horizontal + goTSB.Width + goTSB.Margin.Horizontal + explorerTS.Padding.Horizontal + explorerTS.Margin.Horizontal +30//to be sure ;-) ); addressTSTB.Width = (w>100)?w:100; } private void openSearchPanelTSB_Click(object sender, EventArgs e) { ((ExplorerForm)this.ParentForm).openMediaBrowser(); } /// <summary> /// Invoke delegate on path modification /// Reinit the progress max value /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void addressTSTB_TextChanged(object sender, EventArgs e) { if (DirectorySelected != null) { DirectorySelected( this, addressTSTB.Text ); } } #region properties private void openMetadataCTsMi_Click(object sender, EventArgs e) { form.setPath(fileNameTsMi.ToolTipText); form.ShowDialog(this.ParentForm); } private void openPropertySumaryFileCTsMi_Click(object sender, EventArgs e) { FileTagHelper.showProperties(fileNameTsMi.ToolTipText, this.ParentForm); } private void openPropertiesMessageTsMi_Click(object sender, EventArgs e) { FileHelper.openFileProperties(fileNameTsMi.ToolTipText); } #endregion private void openFileCTsMi_Click(object sender, EventArgs e) { FileHelper.open(fileNameTsMi.ToolTipText); } private void openWithCTsMi_Click(object sender, EventArgs e) { FileHelper.openWith(fileNameTsMi.ToolTipText); } } }
Structure et Fichiers du projet
Afficher/masquer...Icône | Nom | Taille | Modification |
Pas de sous-répertoires. | |||
Icône | Nom | Taille | Modification |
| _ | Répertoire parent | 0 octets | 1730416408 01/11/2024 00:13:28 |
Utilisation de l'explorateur de code
- Navigation :
- Un clic sur une icône de répertoire ouvre ce répertoire pour en afficher les fichiers.
- Lorsque le répertoire en cours ne contient pas de sous-répertoires il est possible de remonter vers le répertoire parent.
- La structure de répertoires en treetable (tableau en forme d'arborescence) n'est plus possibledans cette version.
- Un clic sur une icône de fichier ouvre ce fichier pour en afficher le code avec la coloration syntaxique adaptée en fonction du langage principal utilisé dans le fichier.
- Affichage :
- Il est possible de trier les répertoires ou les fichiers selon certains critères (nom, taille, date).
- Actions :
- Les actions possible sur les fichiers dépendent de vos droits d'utilisateur sur le site. Veuillez activer le mode utilisateur pour activer les actions.
English translation
You have asked to visit this site in English. For now, only the interface is translated, but not all the content yet.If you want to help me in translations, your contribution is welcome. All you need to do is register on the site, and send me a message asking me to add you to the group of translators, which will give you the opportunity to translate the pages you want. A link at the bottom of each translated page indicates that you are the translator, and has a link to your profile.
Thank you in advance.
Document created the 30/10/2009, last modified the 26/10/2018
Source of the printed document:https://www.gaudry.be/en/cs-brolexplorer-source-rf-view/controls//ExplorerUserControl.cs.html
The infobrol is a personal site whose content is my sole responsibility. The text is available under CreativeCommons license (BY-NC-SA). More info on the terms of use and the author.