Example #1
0
 public void CopyPrivateFields(CustomNetworkListBox orig)
 {
     if (orig == null)
     return;
       this._currentlyConnected = orig._currentlyConnected;
       this._currSelectedNDI = orig._currSelectedNDI;
       this._hasFocus = orig._hasFocus;
       this._paintHeadersInListbox = orig._paintHeadersInListbox;
       this._tooltip = orig._tooltip;
       this._tooltip_DisplayedForIndex = orig._tooltip_DisplayedForIndex;
       this._tooltip_NDI = orig._tooltip_NDI;
       this._tooltip_NewText = orig._tooltip_NewText;
       this._tooltip_yOffset = orig._tooltip_yOffset;
 }
Example #2
0
 private void AddCustomListBox(bool recreateNetworksListbox)
 {
     if (this._customListBox != null && !recreateNetworksListbox)
     return;
       this.SuspendLayout();
       CustomNetworkListBox customNetworkListBox = new CustomNetworkListBox();
       customNetworkListBox.AccessibleName = "NetworkListPanel_NetworkListBox_CustomListBox";
       customNetworkListBox.Size = new Size(this.Width - 2, this.Height - (this._listBoxHeader.Location.Y + this._listBoxHeader.Height) - 2);
       customNetworkListBox.Location = new Point(1, this._listBoxHeader.Location.Y + this._listBoxHeader.Height + 1);
       customNetworkListBox.BackColor = Color.WhiteSmoke;
       customNetworkListBox.Visible = false;
       this.Controls.Add((Control) customNetworkListBox);
       customNetworkListBox.SendToBack();
       customNetworkListBox.Visible = true;
       if (this._customListBox != null)
       {
     customNetworkListBox.CopyPrivateFields(this._customListBox);
     this._customListBox.SendToBack();
     this.Controls.Remove((Control) this._customListBox);
       }
       this._customListBox = customNetworkListBox;
       this.ResumeLayout(false);
 }