public void InitializeControl()
        {
            //dont show the Pin button for a while
            btnPinServerLists.Visible = false;
            // set initial panel dock style
            panelServerLists.Tag = DockStyle.None;
            // simulate clicking to Pin Button
            btnPinServerLists_Click(btnPinServerLists, null);

            #region views
            {
                this.m_View_SLIV_Details.Tag  = ServerListViews.Details;
                this.m_View_SLIV_Tile.Tag     = ServerListViews.Tile;
                this.m_View_SLIV_Tree.Tag     = ServerListViews.Tree;
                this.toolbar_SLIV_Details.Tag = ServerListViews.Details;
                this.toolbar_SLIV_Tile.Tag    = ServerListViews.Tile;
                this.toolbar_SLIV_Tree.Tag    = ServerListViews.Tree;
            }
            #endregion

            #region Informatin Window
            {
                GlobalHelper.infoWin.EnableInformationWindow = !GlobalHelper.appSettings.Settings.HideInformationPopupWindow;
                GlobalHelper.infoWin.AddControl(new object[] {
                    this.lvServerLists,
                    this.tlvServerLists,
                    this.toolbar_EditSettings
                });
            }
            #endregion

            #region listview server list control hooks
            {
                lvServerLists.AddControlForEmptyListItem(new object[] {
                    toolbar_DeleteClient,
                    toolbar_EditSettings,
                    toolbar_ConnectAll,
                    m_Edit_DeleteClient,
                    m_File_EditSettings
                });

                lvServerLists.AddControlForItemSelection(new object[] {
                    toolbar_DeleteClient,
                    toolbar_EditSettings,
                    toolbar_ConnectAll,
                    m_Edit_DeleteClient,
                    m_File_EditSettings,
                    lvServerListsContextMenu_DeleteClient,
                    lvServerListsContextMenu_EditClientSettings,
                    lvServerListsContextMenu_ConnectAll
                });
            }
            #endregion

            #region tree listview control hooks
            {
                tlvch = new MultiRemoteDesktopClient.Controls.TreeListViewControlHooks(ref this.tlvServerLists);

                tlvch.AddControlForEmptyListItem(new object[] {
                    toolbar_DeleteClient,
                    toolbar_EditSettings,
                    toolbar_ConnectAll,
                    m_Edit_DeleteClient,
                    m_File_EditSettings
                });

                tlvch.AddControlForItemSelection(new object[] {
                    toolbar_DeleteClient,
                    toolbar_EditSettings,
                    toolbar_ConnectAll,
                    m_Edit_DeleteClient,
                    m_File_EditSettings,
                    lvServerListsContextMenu_DeleteClient,
                    lvServerListsContextMenu_EditClientSettings,
                    lvServerListsContextMenu_ConnectAll
                });
            }
            #endregion

            #region treelistview columns
            // TreeListView's Design time support is so buggy and usually deletes the columns
            tlvServerLists.Columns.AddRange(new CommonTools.TreeListColumn[] {
                new CommonTools.TreeListColumn("server_name", "Server Name", 50),
                new CommonTools.TreeListColumn("server", "Server ", 50),
                new CommonTools.TreeListColumn("descr", "Description", 50)
            });
            tlvServerLists.Columns["server_name"].AutoSize      = true;
            tlvServerLists.Columns["server_name"].AutoSizeRatio = 100;
            tlvServerLists.Columns["server"].AutoSize           = true;
            tlvServerLists.Columns["server"].AutoSizeRatio      = 50;
            #endregion

            this._lastPanelWidth = this.panelServerLists.Width;

            // change server list view
            IconViews(this.toolbar_SLIV_Tree, null);

            // show thumbnail form;
            //RDThumbnailsWindow rdtnwin = new RDThumbnailsWindow();
            //rdtnwin.Show();
        }
        public void InitializeControl()
        {
            //dont show the Pin button for a while
            btnPinServerLists.Visible = false;
            // set initial panel dock style
            panelServerLists.Tag = DockStyle.None;
            // simulate clicking to Pin Button
            btnPinServerLists_Click(btnPinServerLists, null);

            #region views
            {
                this.m_View_SLIV_Details.Tag = ServerListViews.Details;
                this.m_View_SLIV_Tile.Tag = ServerListViews.Tile;
                this.m_View_SLIV_Tree.Tag = ServerListViews.Tree;
                this.toolbar_SLIV_Details.Tag = ServerListViews.Details;
                this.toolbar_SLIV_Tile.Tag = ServerListViews.Tile;
                this.toolbar_SLIV_Tree.Tag = ServerListViews.Tree;
            }
            #endregion

            #region Informatin Window
            {
                GlobalHelper.infoWin.EnableInformationWindow = !GlobalHelper.appSettings.Settings.HideInformationPopupWindow;
                GlobalHelper.infoWin.AddControl(new object[] {
                    this.lvServerLists,
                    this.tlvServerLists,
                    this.toolbar_EditSettings
                });
            }
            #endregion

            #region listview server list control hooks
            {
                lvServerLists.AddControlForEmptyListItem(new object[] {
                    toolbar_DeleteClient,
                    toolbar_EditSettings,
                    toolbar_ConnectAll,
                    m_Edit_DeleteClient,
                    m_File_EditSettings
                });

                lvServerLists.AddControlForItemSelection(new object[] {
                    toolbar_DeleteClient,
                    toolbar_EditSettings,
                    toolbar_ConnectAll,
                    m_Edit_DeleteClient,
                    m_File_EditSettings,
                    lvServerListsContextMenu_DeleteClient,
                    lvServerListsContextMenu_EditClientSettings,
                    lvServerListsContextMenu_ConnectAll
                });
            }
            #endregion

            #region tree listview control hooks
            {
                tlvch = new MultiRemoteDesktopClient.Controls.TreeListViewControlHooks(ref this.tlvServerLists);

                tlvch.AddControlForEmptyListItem(new object[] {
                    toolbar_DeleteClient,
                    toolbar_EditSettings,
                    toolbar_ConnectAll,
                    m_Edit_DeleteClient,
                    m_File_EditSettings
                });

                tlvch.AddControlForItemSelection(new object[] {
                    toolbar_DeleteClient,
                    toolbar_EditSettings,
                    toolbar_ConnectAll,
                    m_Edit_DeleteClient,
                    m_File_EditSettings,
                    lvServerListsContextMenu_DeleteClient,
                    lvServerListsContextMenu_EditClientSettings,
                    lvServerListsContextMenu_ConnectAll
                });
            }
            #endregion

            #region treelistview columns
            // TreeListView's Design time support is so buggy and usually deletes the columns
            tlvServerLists.Columns.AddRange(new CommonTools.TreeListColumn[] {
                new CommonTools.TreeListColumn("server_name", "Server Name", 50),
                new CommonTools.TreeListColumn("server", "Server ", 50),
                new CommonTools.TreeListColumn("descr", "Description", 50)
            });
            tlvServerLists.Columns["server_name"].AutoSize = true;
            tlvServerLists.Columns["server_name"].AutoSizeRatio = 100;
            tlvServerLists.Columns["server"].AutoSize = true;
            tlvServerLists.Columns["server"].AutoSizeRatio = 50;
            #endregion

            this._lastPanelWidth = this.panelServerLists.Width;

            // change server list view
            IconViews(this.toolbar_SLIV_Tree, null);

            // show thumbnail form;
            //RDThumbnailsWindow rdtnwin = new RDThumbnailsWindow();
            //rdtnwin.Show();
        }