Beispiel #1
0
 /// <summary>
 /// Required method for Designer support - do not modify
 /// the contents of this method with the code editor.
 /// </summary>
 private void InitializeComponent()
 {
     this.components    = new Container();
     this._findEdit     = new TextBox();
     this._lblFind      = new Label();
     this._tmrIncSearch = new Timer(this.components);
     this._listView     = new ResourceListView2();
     this.SuspendLayout();
     //
     // _findEdit
     //
     this._findEdit.Anchor = ((AnchorStyles)(((AnchorStyles.Top | AnchorStyles.Left)
                                              | AnchorStyles.Right)));
     this._findEdit.Location     = new Point(48, 0);
     this._findEdit.Name         = "_findEdit";
     this._findEdit.Size         = new Size(184, 22);
     this._findEdit.TabIndex     = 6;
     this._findEdit.Text         = "";
     this._findEdit.TextChanged += new EventHandler(this.OnSearchTextChanged);
     //
     // _lblFind
     //
     this._lblFind.FlatStyle = FlatStyle.System;
     this._lblFind.Location  = new Point(8, 4);
     this._lblFind.Name      = "_lblFind";
     this._lblFind.Size      = new Size(32, 16);
     this._lblFind.TabIndex  = 8;
     this._lblFind.Text      = "Find:";
     //
     // _tmrIncSearch
     //
     this._tmrIncSearch.Interval = 300;
     this._tmrIncSearch.Tick    += new EventHandler(this.OnSearchTimerTick);
     //
     // _listView
     //
     this._listView.AllowDrop = true;
     this._listView.Anchor    = ((AnchorStyles)((((AnchorStyles.Top | AnchorStyles.Bottom)
                                                  | AnchorStyles.Left)
                                                 | AnchorStyles.Right)));
     this._listView.ExecuteDoubleClickAction = false;
     this._listView.FullRowSelect            = true;
     this._listView.HeaderStyle     = ColumnHeaderStyle.None;
     this._listView.HideSelection   = false;
     this._listView.Location        = new Point(4, 24);
     this._listView.Name            = "_listView";
     this._listView.ShowContextMenu = false;
     this._listView.Size            = new Size(228, 124);
     this._listView.TabIndex        = 9;
     this._listView.DoubleClick    += new JetBrains.JetListViewLibrary.HandledEventHandler(_listView_DoubleClick);
     //
     // GenericResourceSelectPane
     //
     this.Controls.Add(this._listView);
     this.Controls.Add(this._findEdit);
     this.Controls.Add(this._lblFind);
     this.Name = "GenericResourceSelectPane";
     this.Size = new Size(236, 150);
     this.ResumeLayout(false);
 }
Beispiel #2
0
        public void FillResources(ResourceListView2 listView)
        {
            _listView = listView.JetListView;
            _listView.ChildrenRequested += new RequestChildrenEventHandler(HandleChildrenRequested);

            // Set the proper root
            listView.RootResource = _rootResource;

            ExpandResource(_listView.Root, _rootResource);
        }
Beispiel #3
0
        public void FillResources(ResourceListView2 listView)
        {
            #region Preconditions
            if (_listView != null)
            {
                throw new InvalidOperationException("Attempt to attach a ResourceListDataProvider which is already attached");
            }
            #endregion Preconditions

            _listView = listView.JetListView;
            for (int i = 0; i < _store.Count; i++)
            {
                _listView.Nodes.Add(_store[i]);
            }
        }
Beispiel #4
0
        public ResourceTreePaneBase()
        {
            // This call is required by the Windows.Forms Form Designer.
            InitializeComponent();

            _resourceTree                 = new ResourceListView2();
            _resourceTree.Dock            = DockStyle.Fill;
            _resourceTree.BorderStyle     = BorderStyle.None;
            _resourceTree.ContextProvider = this;

            TreeStructureColumn treeStructureColumn = new TreeStructureColumn();

            treeStructureColumn.Width = 20;
            _resourceTree.Columns.Add(treeStructureColumn);
            _resourceTree.Columns.Add(new ResourceIconColumn());

            _resourceTree.JetListView.KeyDown           += HandleResourceTreeKeyDown;
            _resourceTree.JetListView.ActiveNodeChanged += HandleActiveNodeChanged;
            _resourceTree.KeyNavigationCompleted        += HandleKeyNavigationCompleted;

            _textColumn = new RichTextColumn();
            _textColumn.SizeToContent       = true;
            _textColumn.ItemToolTipCallback = HandleToolTipCallback;
            _resourceTree.Columns.Add(_textColumn);

            Controls.Add(_resourceTree);
            Controls.SetChildIndex(_resourceTree, 0);

            _toolbarManager = new ToolbarActionManager(_toolBar);
            _toolbarManager.ContextProvider = this;

            _dataProvider = new ResourceTreeDataProvider();

            SetStyle(ControlStyles.Selectable, false);

            UnreadManager unreadManager = (UnreadManager)Core.UnreadManager;

            if (unreadManager.Enabled)
            {
                _unreadDecorator = new UnreadNodeDecorator();
                _textColumn.AddNodeDecorator(_unreadDecorator);
            }
        }
Beispiel #5
0
        public void FillResources(ResourceListView2 listView)
        {
            if (_listView != null)
            {
                throw new InvalidOperationException("Attempt to attach a ResourceListDataProvider which is already attached");
            }
            _listView = listView.JetListView;
            ApplySortSettings(listView.JetListView, _curSortSettings);

            lock ( _resourceList )
            {
                AddResourceNodes();
                _nodesAdded = true;

                _resourceList.ResourceAdded    += HandleResourceAdded;
                _resourceList.ResourceChanged  += HandleResourceChanged;
                _resourceList.ResourceDeleting += HandleResourceDeleting;
            }

            _listView.ColumnClick += HandleColumnClick;
        }
Beispiel #6
0
 /// <summary>
 /// Required method for Designer support - do not modify
 /// the contents of this method with the code editor.
 /// </summary>
 private void InitializeComponent()
 {
     this.components       = new System.ComponentModel.Container();
     this._listContacts    = new ResourceListView2();
     this._cmbCategory     = new JetBrains.Omea.GUIControls.ResourceComboBox();
     this._lblShowCategory = new System.Windows.Forms.Label();
     this._txtFind         = new JetBrains.Omea.GUIControls.JetTextBox();
     this.SuspendLayout();
     //
     // _listQueries
     //
     this._listContacts.AllowDrop = true;
     this._listContacts.Anchor    = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
                                                                           | System.Windows.Forms.AnchorStyles.Left)
                                                                          | System.Windows.Forms.AnchorStyles.Right)));
     this._listContacts.BorderStyle             = BorderStyle.None;
     this._listContacts.HeaderStyle             = System.Windows.Forms.ColumnHeaderStyle.None;
     this._listContacts.HideSelection           = false;
     this._listContacts.Location                = new System.Drawing.Point(0, 56);
     this._listContacts.Name                    = "_listContacts";
     this._listContacts.Size                    = new System.Drawing.Size(148, 94);
     this._listContacts.TabIndex                = 2;
     this._listContacts.KeyNavigationCompleted += new EventHandler(HandleKeyNavigationCompleted);
     this._listContacts.DoubleClick            += new HandledEventHandler(this._listQueries_DoubleClick);
     this._listContacts.MouseUp                += new System.Windows.Forms.MouseEventHandler(this._listQueries_MouseUp);
     this._listContacts.KeyDown                += new System.Windows.Forms.KeyEventHandler(this._listQueries_KeyDown);
     //
     // _cmbCategory
     //
     this._cmbCategory.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
                                                                      | System.Windows.Forms.AnchorStyles.Right)));
     this._cmbCategory.DrawMode              = System.Windows.Forms.DrawMode.OwnerDrawFixed;
     this._cmbCategory.DropDownStyle         = System.Windows.Forms.ComboBoxStyle.DropDownList;
     this._cmbCategory.Location              = new System.Drawing.Point(48, 28);
     this._cmbCategory.Name                  = "_cmbCategory";
     this._cmbCategory.Size                  = new System.Drawing.Size(100, 22);
     this._cmbCategory.TabIndex              = 1;
     this._cmbCategory.KeyDown              += new System.Windows.Forms.KeyEventHandler(this._cmbCategory_KeyDown);
     this._cmbCategory.SelectedIndexChanged += new System.EventHandler(this.OnSelectedCategoryChanged);
     //
     // _lblShowCategory
     //
     this._lblShowCategory.FlatStyle = System.Windows.Forms.FlatStyle.System;
     this._lblShowCategory.Location  = new System.Drawing.Point(4, 32);
     this._lblShowCategory.Name      = "_lblShowCategory";
     this._lblShowCategory.Size      = new System.Drawing.Size(40, 16);
     this._lblShowCategory.TabIndex  = 5;
     this._lblShowCategory.Text      = "Show:";
     //
     // _txtFind
     //
     this._txtFind.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
                                                                  | System.Windows.Forms.AnchorStyles.Right)));
     this._txtFind.EmptyText = null;
     this._txtFind.ForeColor = System.Drawing.Color.DarkGray;
     this._txtFind.Location  = new System.Drawing.Point(0, 4);
     this._txtFind.Name      = "_txtFind";
     this._txtFind.Size      = new System.Drawing.Size(148, 21);
     this._txtFind.TabIndex  = 0;
     this._txtFind.Text      = "";
     this._txtFind.KeyDown  += new System.Windows.Forms.KeyEventHandler(this._txtFind_KeyDown);
     this._txtFind.IncrementalSearchUpdated += new System.EventHandler(this.OnIncrementalSearchUpdated);
     //
     // CorrespondentCtrl
     //
     this.Controls.Add(this._cmbCategory);
     this.Controls.Add(this._lblShowCategory);
     this.Controls.Add(this._txtFind);
     this.Controls.Add(this._listContacts);
     this.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(204)));
     this.Name = "CorrespondentCtrl";
     this.Size = new System.Drawing.Size(148, 150);
     this.ResumeLayout(false);
 }