private void ResizeControls() { int topborder = 53; //textNumbers resize textNumbers.Top = topborder; textNumbers.Height = ClientSize.Height - topborder; //text resize textContent.Top = topborder; textContent.Height = ClientSize.Height - topborder; textContent.Left = 32; textContent.Width = ClientSize.Width / 2 - 2 - textContent.Left; //Browser resize webBrowserWiki.Top = topborder; webBrowserWiki.Height = ClientSize.Height - topborder; webBrowserWiki.Left = ClientSize.Width / 2 + 2; webBrowserWiki.Width = ClientSize.Width / 2 - 2; //Toolbar resize ToolBarMain.Width = ClientSize.Width; toolBar2.Width = ClientSize.Width; ToolBarMain.Invalidate(); toolBar2.Invalidate(); LayoutToolBars(); //Button move //butRefresh.Left=ClientSize.Width/2+2; }
///<summary></summary> public void LayoutToolBar() { ToolBarMain.Buttons.Clear(); ToolBarMain.Buttons.Add(new ODToolBarButton(Lan.g(this, "Add TaskList"), 0, "", "AddList")); ToolBarMain.Buttons.Add(new ODToolBarButton(Lan.g(this, "Add Task"), 1, "", "AddTask")); //ToolBarMain.Buttons.Add(new ODToolBarButton(Lan.g(this,"Exit"),-1,"","Exit")); ToolBarMain.Invalidate(); }
///<summary></summary> public void LayoutToolBars() { ToolBarMain.Buttons.Clear(); ToolBarMain.Buttons.Add(new ODToolBarButton(Lan.g(this, "Back"), 0, "", "Back")); ToolBarMain.Buttons.Add(new ODToolBarButton(Lan.g(this, "Forward"), 1, "", "Forward")); ToolBarMain.Buttons.Add(new ODToolBarButton(Lan.g(this, "Refresh"), -1, "", "Refresh")); ToolBarMain.Buttons.Add(new ODToolBarButton(Lan.g(this, "Print"), -1, "", "Print")); ToolBarMain.Buttons.Add(new ODToolBarButton(Lan.g(this, "Close"), -1, "", "Close")); ToolBarMain.Invalidate(); }
private void ToolBarMain_ButtonClick(object sender, OpenDental.UI.ODToolBarButtonClickEventArgs e) { switch (e.Button.Tag.ToString()) { case "Save": Save_Click(); break; case "SaveDraft": SaveDraft_Click(); break; case "Cancel": Cancel_Click(); break; case "Int Link": Int_Link_Click(); break; case "Bookmark": Bookmark_Click(); break; case "File Link": File_Link_Click(); break; case "Folder Link": Folder_Link_Click(); break; case "Ext Link": Ext_Link_Click(); break; case "H1": H1_Click(); break; case "H2": H2_Click(); break; case "H3": H3_Click(); break; case "Table": Table_Click(); break; case "Image": Image_Click(); break; case "Lock": if (!Security.IsAuthorized(Permissions.WikiAdmin, true)) { return; } WikiPageCur.IsLocked = !WikiPageCur.IsLocked; if (WikiPageCur.IsLocked) { //The wiki page is was locked, switch the icon to the unlock symbol because they locked it. e.Button.Text = Lan.g(this, "Unlock"); e.Button.ImageIndex = 19; } else { //The wiki page is was unlocked, switch the icon to the lock symbol because they unlocked it. e.Button.Text = Lan.g(this, "Lock"); e.Button.ImageIndex = 20; } ToolBarMain.Invalidate(); break; } }