Наследование: System.Windows.Forms.Form
Пример #1
0
        private void entryList_DoubleClick(object sender, System.EventArgs e)
        {
            if (entryList.SelectedItems.Count == 0)
            {
                return;
            }

            ListViewItem selectedItem = entryList.SelectedItems [0];

            if (logTree.SelectedNode.Parent == null)
            {
                string logName = (string)selectedItem.Tag;
                // locate corresponding tree node
                foreach (TreeNode node in logTree.Nodes[0].Nodes)
                {
                    if ((string)node.Tag == logName)
                    {
                        logTree.SelectedNode = node;
                        break;
                    }
                }
            }
            else
            {
                EventEntryView selectedEntry = (EventEntryView)selectedItem.Tag;
                if (_eventProperties == null || _eventProperties.IsDisposed)
                {
                    _eventProperties = new EventEntryProperties();
                }
                _eventProperties.DisplayEventEntry(selectedEntry);
                _eventProperties.Activate();
                _eventProperties.Show();
            }
        }
Пример #2
0
        private void entryList_DoubleClick(object sender, System.EventArgs e)
        {
            if (entryList.SelectedItems.Count == 0)
                return;

            ListViewItem selectedItem = entryList.SelectedItems [0];

            if (logTree.SelectedNode.Parent == null) {
                string logName = (string) selectedItem.Tag;
                // locate corresponding tree node
                foreach (TreeNode node in logTree.Nodes [0].Nodes) {
                    if ((string) node.Tag == logName) {
                        logTree.SelectedNode = node;
                        break;
                    }
                }
            } else {
                EventEntryView selectedEntry = (EventEntryView) selectedItem.Tag;
                if (_eventProperties == null || _eventProperties.IsDisposed)
                    _eventProperties = new EventEntryProperties ();
                _eventProperties.DisplayEventEntry (selectedEntry);
                _eventProperties.Activate ();
                _eventProperties.Show ();
            }
        }