From 69598c8466c716b0c547882269a7223b52e853af Mon Sep 17 00:00:00 2001 From: Daniel Grunwald Date: Tue, 5 Aug 2008 15:56:14 +0000 Subject: [PATCH] Make workbench a WPF window. git-svn-id: svn://svn.sharpdevelop.net/sharpdevelop/branches/3.0wpf@3295 1ccf3a8d-04fe-1044-b7c0-cef0b8235c61 --- .../Project/FSharpBinding.fsproj | 24 +- .../Src/Commands/AddWixExtensionToProject.cs | 2 +- .../AddWixItemToProjectBaseCommand.cs | 2 +- .../ClassWizard/Src/AddNewClassCommand.cs | 2 +- .../ClassWizard/Src/ClassesList.cs | 8 +- .../Project/Src/Commands/SideBarCommands.cs | 2 +- .../Project/Src/Gui/AddComponentsDialog.cs | 2 +- .../Project/Src/Services/UIService.cs | 2 +- .../Project/Src/Commands/AddNewFileCommand.cs | 2 +- .../Src/Commands/SaveEntryAsCommand.cs | 2 +- .../Project/Src/ResourceEdit/BitmapView.cs | 2 +- .../Project/Src/AssignStylesheetCommand.cs | 2 +- .../AddInManager/Project/Src/ManagerForm.cs | 7 +- .../Project/Debugger.AddIn.csproj | 17 +- .../Src/Service/DebugeeExceptionForm.cs | 2 +- .../Project/Src/Service/DebuggerEventForm.cs | 2 +- .../Project/Src/Service/WindowsDebugger.cs | 4 +- .../Project/Src/TreeModel/ErrorNode.cs | 5 +- .../Project/Src/ColorButton.cs | 2 +- .../Project/Src/ColorDialog.cs | 2 +- .../Project/Src/EditHighlightingPanel.cs | 2 +- .../Project/Src/Nodes/KeywordListNode.cs | 2 +- .../Project/Src/Nodes/KeywordListsNode.cs | 2 +- .../Project/Src/Nodes/MarkersNode.cs | 2 +- .../Project/Src/Nodes/PropertiesNode.cs | 4 +- .../Project/Src/Nodes/RuleSetsNode.cs | 2 +- .../Project/Src/Nodes/SpansNode.cs | 2 +- .../Src/InsertPInvokeSignaturesCommand.cs | 3 +- .../Src/TextEditorContextMenuCommand.cs | 2 +- .../Project/Src/Commands/MenuCommand.cs | 8 +- .../Project/Src/Dialogs/MainWindow.cs | 4 +- .../NewResourceCodeCompletionData.cs | 2 +- .../Commands/TextEditorContextMenuBuilder.cs | 2 +- .../Project/Engine/SearchReplaceManager.cs | 2 +- .../Project/Gui/SearchAndReplaceDialog.cs | 3 +- .../Project/Src/Gui/SvnGuiWrapper.cs | 3 +- .../Project/Src/SvnClientWrapper.cs | 8 +- .../DockSample/AboutDialog.Designer.cs | 118 -- .../DockPanel_Src/DockSample/AboutDialog.cs | 26 - .../DockPanel_Src/DockSample/AboutDialog.resx | 120 -- .../DockSample/Customization/DockHelper.cs | 113 -- .../DockSample/Customization/Extender.cs | 55 - .../DockSample/Customization/InertButton.cs | 619 -------- .../Customization/Resources.Designer.cs | 133 -- .../DockSample/Customization/Resources.resx | 151 -- .../Resources/DockIndicator_PaneDiamond.bmp | Bin 23286 -> 0 bytes .../DockIndicator_PaneDiamond_Bottom.bmp | Bin 23286 -> 0 bytes .../DockIndicator_PaneDiamond_Hotspot.bmp | Bin 23286 -> 0 bytes ...DockIndicator_PaneDiamond_HotspotIndex.bmp | Bin 90 -> 0 bytes .../DockIndicator_PaneDiamond_Left.bmp | Bin 23286 -> 0 bytes .../DockIndicator_PaneDiamond_Right.bmp | Bin 23286 -> 0 bytes .../DockIndicator_PaneDiamond_Top.bmp | Bin 23286 -> 0 bytes .../Resources/DockIndicator_PanelBottom.bmp | Bin 2782 -> 0 bytes .../DockIndicator_PanelBottom_Active.bmp | Bin 2782 -> 0 bytes .../Resources/DockIndicator_PanelFill.bmp | Bin 3030 -> 0 bytes .../DockIndicator_PanelFill_Active.bmp | Bin 3030 -> 0 bytes .../Resources/DockIndicator_PanelLeft.bmp | Bin 2838 -> 0 bytes .../DockIndicator_PanelLeft_Active.bmp | Bin 2838 -> 0 bytes .../Resources/DockIndicator_PanelRight.bmp | Bin 2838 -> 0 bytes .../DockIndicator_PanelRight_Active.bmp | Bin 2838 -> 0 bytes .../Resources/DockIndicator_PanelTop.bmp | Bin 2870 -> 0 bytes .../DockIndicator_PanelTop_Active.bmp | Bin 2870 -> 0 bytes .../Resources/DockPaneCaption_AutoHideNo.bmp | Bin 114 -> 0 bytes .../Resources/DockPaneCaption_AutoHideYes.bmp | Bin 114 -> 0 bytes .../DockPaneCaption_CloseDisabled.bmp | Bin 114 -> 0 bytes .../DockPaneCaption_CloseEnabled.bmp | Bin 114 -> 0 bytes .../Resources/DockPaneStrip_CloseDisabled.bmp | Bin 114 -> 0 bytes .../Resources/DockPaneStrip_CloseEnabled.bmp | Bin 114 -> 0 bytes .../DockPaneStrip_ScrollLeftDisabled.bmp | Bin 114 -> 0 bytes .../DockPaneStrip_ScrollLeftEnabled.bmp | Bin 114 -> 0 bytes .../DockPaneStrip_ScrollRightDisabled.bmp | Bin 114 -> 0 bytes .../DockPaneStrip_ScrollRightEnabled.bmp | Bin 114 -> 0 bytes .../Dockindicator_PaneDiamond_Fill.bmp | Bin 23286 -> 0 bytes .../Customization/Strings.Designer.cs | 108 -- .../DockSample/Customization/Strings.resx | 135 -- .../Customization/VS2003AutoHideStrip.cs | 507 ------- .../Customization/VS2003DockPaneCaption.cs | 359 ----- .../Customization/VS2003DockPaneStrip.cs | 1085 -------------- .../DockSample/DockSample.csproj | 324 ---- .../DockSample/DummyDoc.Designer.cs | 147 -- .../DockPanel_Src/DockSample/DummyDoc.cs | 83 -- .../DockPanel_Src/DockSample/DummyDoc.resx | 140 -- .../DockSample/DummyOutputWindow.Designer.cs | 83 -- .../DockSample/DummyOutputWindow.cs | 19 - .../DockSample/DummyOutputWindow.resx | 167 --- .../DummyPropertyWindow.Designer.cs | 95 -- .../DockSample/DummyPropertyWindow.cs | 21 - .../DockSample/DummyPropertyWindow.resx | 141 -- .../DummySolutionExplorer.Designer.cs | 462 ------ .../DockSample/DummySolutionExplorer.cs | 24 - .../DockSample/DummySolutionExplorer.resx | 220 --- .../DockSample/DummyTaskList.Designer.cs | 111 -- .../DockPanel_Src/DockSample/DummyTaskList.cs | 19 - .../DockSample/DummyTaskList.resx | 138 -- .../DockSample/DummyToolbox.Designer.cs | 96 -- .../DockPanel_Src/DockSample/DummyToolbox.cs | 19 - .../DockSample/DummyToolbox.resx | 181 --- .../DockSample/Images/ArrowDown.bmp | Bin 370 -> 0 bytes .../DockSample/Images/ArrowUp.bmp | Bin 370 -> 0 bytes .../DockSample/Images/Bitmap.ico | Bin 318 -> 0 bytes .../DockSample/Images/BlankIcon.ico | Bin 1078 -> 0 bytes .../DockSample/Images/CSFile.ico | Bin 318 -> 0 bytes .../DockSample/Images/CSProject.ico | Bin 318 -> 0 bytes .../DockSample/Images/ClosedFolder.ICO | Bin 1078 -> 0 bytes .../DockPanel_Src/DockSample/Images/File.ico | Bin 318 -> 0 bytes .../DockPanel_Src/DockSample/Images/Form.ico | Bin 318 -> 0 bytes .../DockPanel_Src/DockSample/Images/Mouse.bmp | Bin 134 -> 0 bytes .../DockPanel_Src/DockSample/Images/New.ico | Bin 318 -> 0 bytes .../DockPanel_Src/DockSample/Images/Open.ico | Bin 318 -> 0 bytes .../DockSample/Images/OpenFolder.ICO | Bin 1078 -> 0 bytes .../DockSample/Images/OutputWindow.ico | Bin 766 -> 0 bytes .../DockSample/Images/PropertyWindow.ico | Bin 766 -> 0 bytes .../DockSample/Images/Reference.ico | Bin 318 -> 0 bytes .../DockSample/Images/References.ico | Bin 318 -> 0 bytes .../DockSample/Images/SolutionExplorer.ico | Bin 766 -> 0 bytes .../DockSample/Images/TaskListWindow.ico | Bin 766 -> 0 bytes .../DockSample/Images/ToolboxWindow.ico | Bin 766 -> 0 bytes .../DockSample/Images/XmlFile.ico | Bin 318 -> 0 bytes .../DockSample/Images/msenv22.ico | Bin 766 -> 0 bytes .../DockSample/MainForm.Designer.cs | 614 -------- .../DockPanel_Src/DockSample/MainForm.cs | 443 ------ .../DockPanel_Src/DockSample/MainForm.resx | 194 --- .../DockSample/MainForm2.Designer.cs | 635 -------- .../DockPanel_Src/DockSample/MainForm2.cs | 443 ------ .../DockPanel_Src/DockSample/MainForm2.resx | 194 --- .../DockPanel_Src/DockSample/Program.cs | 20 - .../DockSample/Properties/AssemblyInfo.cs | 33 - .../Properties/Resources.Designer.cs | 63 - .../DockSample/Properties/Resources.resx | 117 -- .../Properties/Settings.Designer.cs | 26 - .../DockSample/Properties/Settings.settings | 7 - .../DockSample/Resources/DockPanel.xml | Bin 9744 -> 0 bytes .../DockSample/ToolWindow.Designer.cs | 91 -- .../DockPanel_Src/DockSample/ToolWindow.cs | 19 - .../DockPanel_Src/DockSample/ToolWindow.resx | 123 -- .../DockPanel_Src/DockSample/license.txt | 9 - .../DockPanel_Src/WinFormsUI.Docking.sln | 25 - .../WinFormsUI/Docking/AutoHideStripBase.cs | 508 ------- .../WinFormsUI/Docking/DockAreasEditor.cs | 142 -- .../WinFormsUI/Docking/DockContent.cs | 273 ---- .../Docking/DockContentCollection.cs | 175 --- .../Docking/DockContentEventArgs.cs | 19 - .../WinFormsUI/Docking/DockContentHandler.cs | 1069 -------------- .../WinFormsUI/Docking/DockOutlineBase.cs | 161 -- .../Docking/DockPane.SplitterControl.cs | 157 -- .../WinFormsUI/Docking/DockPane.cs | 1277 ---------------- .../WinFormsUI/Docking/DockPaneCaptionBase.cs | 100 -- .../WinFormsUI/Docking/DockPaneCollection.cs | 47 - .../WinFormsUI/Docking/DockPaneStripBase.cs | 248 ---- .../Docking/DockPanel.AutoHideWindow.cs | 612 -------- .../Docking/DockPanel.DockDragHandler.cs | 811 ---------- .../Docking/DockPanel.DragHandler.cs | 135 -- .../Docking/DockPanel.FocusManager.cs | 571 -------- .../Docking/DockPanel.MdiClientController.cs | 430 ------ .../WinFormsUI/Docking/DockPanel.Persistor.cs | 780 ---------- .../Docking/DockPanel.SplitterDragHandler.cs | 165 --- .../WinFormsUI/Docking/DockPanel.bmp | Bin 822 -> 0 bytes .../WinFormsUI/Docking/DockPanel.cs | 986 ------------- .../WinFormsUI/Docking/DockPanelExtender.cs | 225 --- .../Docking/DockWindow.SplitterControl.cs | 28 - .../WinFormsUI/Docking/DockWindow.cs | 243 --- .../Docking/DockWindowCollection.cs | 38 - .../WinFormsUI/Docking/DragForm.cs | 64 - .../WinFormsUI/Docking/DummyControl.cs | 13 - .../DockPanel_Src/WinFormsUI/Docking/Enums.cs | 51 - .../WinFormsUI/Docking/FloatWindow.cs | 436 ------ .../Docking/FloatWindowCollection.cs | 42 - .../WinFormsUI/Docking/Helpers/DockHelper.cs | 103 -- .../WinFormsUI/Docking/Helpers/DrawHelper.cs | 88 -- .../Docking/Helpers/ResourceHelper.cs | 29 - .../WinFormsUI/Docking/Helpers/Win32Helper.cs | 19 - .../WinFormsUI/Docking/InertButtonBase.cs | 115 -- .../WinFormsUI/Docking/Interfaces.cs | 45 - .../WinFormsUI/Docking/Localization.cs | 46 - .../WinFormsUI/Docking/Measures.cs | 14 - .../WinFormsUI/Docking/NestedDockingStatus.cs | 108 -- .../Docking/NestedPaneCollection.cs | 116 -- .../WinFormsUI/Docking/Resources.Designer.cs | 224 --- .../WinFormsUI/Docking/Resources.resx | 190 --- .../Resources/DockIndicator_PaneDiamond.bmp | Bin 23286 -> 0 bytes .../DockIndicator_PaneDiamond_Bottom.bmp | Bin 23286 -> 0 bytes .../DockIndicator_PaneDiamond_Hotspot.bmp | Bin 23286 -> 0 bytes ...DockIndicator_PaneDiamond_HotspotIndex.bmp | Bin 90 -> 0 bytes .../DockIndicator_PaneDiamond_Left.bmp | Bin 23286 -> 0 bytes .../DockIndicator_PaneDiamond_Right.bmp | Bin 23286 -> 0 bytes .../DockIndicator_PaneDiamond_Top.bmp | Bin 23286 -> 0 bytes .../Resources/DockIndicator_PanelBottom.bmp | Bin 2782 -> 0 bytes .../DockIndicator_PanelBottom_Active.bmp | Bin 2782 -> 0 bytes .../Resources/DockIndicator_PanelFill.bmp | Bin 3030 -> 0 bytes .../DockIndicator_PanelFill_Active.bmp | Bin 3030 -> 0 bytes .../Resources/DockIndicator_PanelLeft.bmp | Bin 2838 -> 0 bytes .../DockIndicator_PanelLeft_Active.bmp | Bin 2838 -> 0 bytes .../Resources/DockIndicator_PanelRight.bmp | Bin 2838 -> 0 bytes .../DockIndicator_PanelRight_Active.bmp | Bin 2838 -> 0 bytes .../Resources/DockIndicator_PanelTop.bmp | Bin 2870 -> 0 bytes .../DockIndicator_PanelTop_Active.bmp | Bin 2870 -> 0 bytes .../Docking/Resources/DockPane_AutoHide.bmp | Bin 774 -> 0 bytes .../Docking/Resources/DockPane_Close.bmp | Bin 774 -> 0 bytes .../Docking/Resources/DockPane_Dock.bmp | Bin 774 -> 0 bytes .../Docking/Resources/DockPane_Option.bmp | Bin 774 -> 0 bytes .../Resources/DockPane_OptionOverflow.bmp | Bin 774 -> 0 bytes .../Dockindicator_PaneDiamond_Fill.bmp | Bin 23286 -> 0 bytes .../WinFormsUI/Docking/Resources/Thumbs.db | Bin 138752 -> 0 bytes .../WinFormsUI/Docking/SplitterBase.cs | 70 - .../WinFormsUI/Docking/Strings.Designer.cs | 747 ---------- .../WinFormsUI/Docking/Strings.resx | 348 ----- .../WinFormsUI/Docking/VS2005AutoHideStrip.cs | 497 ------- .../Docking/VS2005DockPaneCaption.cs | 468 ------ .../WinFormsUI/Docking/VS2005DockPaneStrip.cs | 1301 ----------------- .../Docking/VisibleNestedPaneCollection.cs | 168 --- .../WinFormsUI/Docking/Win32/Enums.cs | 369 ----- .../WinFormsUI/Docking/Win32/NativeMethods.cs | 64 - .../WinFormsUI/Properties/AssemblyInfo.cs | 28 - .../WinFormsUI/WinFormsUI.csproj | 209 --- .../DockPanel_Src/WinFormsUI/license.txt | 9 - src/Libraries/DockPanel_Src/license.txt | 9 - src/Libraries/DockPanel_Src/patchnotes.txt | 31 - .../AbstractCompletionWindow.cs | 17 +- .../CompletionWindow/CodeCompletionWindow.cs | 8 +- .../CompletionWindow/DeclarationViewWindow.cs | 7 +- .../Src/Gui/InsightWindow/InsightWindow.cs | 2 +- .../Project/ICSharpCode.SharpDevelop.csproj | 29 +- .../Project/Src/Commands/AutostartCommands.cs | 10 +- .../Project/Src/Commands/BuildCommands.cs | 2 +- .../Src/Commands/ChooseLayoutCommand.cs | 2 +- .../Base/Project/Src/Commands/EditCommands.cs | 3 +- .../Base/Project/Src/Commands/FileCommands.cs | 15 +- .../Project/Src/Commands/FileMenuCommands.cs | 7 +- .../Base/Project/Src/Commands/HelpCommands.cs | 3 +- .../Project/Src/Commands/MenuItemBuilders.cs | 2 +- .../Project/Src/Commands/ToolsCommands.cs | 20 +- .../Src/Gui/Dialogs/ExtractInterfaceDialog.cs | 3 +- .../Project/Src/Gui/Dialogs/NewFileDialog.cs | 3 +- .../OptionPanels/EditTemplateDialog.cs | 1 - .../Dialogs/OptionPanels/ExternalToolPanel.cs | 2 +- .../ProjectOptions/AbstractBuildOptions.cs | 2 +- .../OptionPanels/ProjectOptions/Signing.cs | 2 +- .../ReferenceDialog/AddWebReferenceDialog.cs | 2 +- .../ReferenceDialog/AssemblyReferencePanel.cs | 2 +- .../Project/Src/Gui/Dialogs/TabbedOptions.cs | 1 - .../Src/Gui/Dialogs/TreeViewOptions.cs | 2 - .../Src/Gui/Dialogs/WordCountDialog.cs | 1 - .../Project/Src/Gui/FormLocationHelper.cs | 6 +- src/Main/Base/Project/Src/Gui/IWorkbench.cs | 19 +- .../Commands/DefaultFileNodeCommands.cs | 2 +- .../Commands/FolderNodeCommands.cs | 4 +- .../Commands/ReferenceFolderNodeCommands.cs | 6 +- .../Commands/SolutionNodeCommands.cs | 6 +- .../Gui/Workbench/Layouts/AvalonDockLayout.cs | 91 ++ .../Src/Gui/Workbench/SingleInstanceHelper.cs | 2 +- .../Project/Src/Gui/Workbench/WpfWorkbench.cs | 142 ++ .../Project/Src/Gui/WorkbenchSingleton.cs | 94 +- .../Templates/Project/ProjectTemplate.cs | 2 +- .../Base/Project/Src/Project/BuildEngine.cs | 2 +- .../AmbienceService/AmbienceService.cs | 2 +- .../Services/Debugger/DebuggerGridControl.cs | 7 +- .../Src/Services/File/FileChangeWatcher.cs | 13 +- .../Pad/BookmarkPadToolbarCommands.cs | 1 - .../Src/TextEditor/Commands/FormatCommands.cs | 3 +- .../Commands/GenerateCodeCommand.cs | 2 +- .../Src/TextEditor/Commands/ToolCommands.cs | 2 +- .../Src/TextEditor/Gui/Dialogs/GotoDialog.cs | 3 +- .../Gui/Editor/SharpDevelopTextAreaControl.cs | 4 +- .../Gui/OptionPanels/CodeTemplatePanel.cs | 4 +- .../Base/Project/Src/Util/ExtensionMethods.cs | 52 + .../Base/Project/Src/Util/NativeMethods.cs | 2 +- .../Project/Src/Util/WpfSynchronizeInvoke.cs | 113 ++ .../ICSharpCode.SharpDevelop.Sda.csproj | 9 + .../Src/CallHelper.cs | 9 +- .../Src/ExceptionBox.cs | 3 +- .../StartUp/Project/Dialogs/SplashScreen.cs | 2 +- src/Main/StartUp/Project/SharpDevelopMain.cs | 2 +- src/SharpDevelop.sln | 16 +- 273 files changed, 661 insertions(+), 24554 deletions(-) delete mode 100644 src/Libraries/DockPanel_Src/DockSample/AboutDialog.Designer.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/AboutDialog.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/AboutDialog.resx delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/DockHelper.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Extender.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/InertButton.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources.Designer.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources.resx delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PaneDiamond.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PaneDiamond_Bottom.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PaneDiamond_Hotspot.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PaneDiamond_HotspotIndex.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PaneDiamond_Left.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PaneDiamond_Right.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PaneDiamond_Top.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PanelBottom.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PanelBottom_Active.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PanelFill.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PanelFill_Active.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PanelLeft.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PanelLeft_Active.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PanelRight.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PanelRight_Active.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PanelTop.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PanelTop_Active.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockPaneCaption_AutoHideNo.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockPaneCaption_AutoHideYes.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockPaneCaption_CloseDisabled.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockPaneCaption_CloseEnabled.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockPaneStrip_CloseDisabled.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockPaneStrip_CloseEnabled.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockPaneStrip_ScrollLeftDisabled.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockPaneStrip_ScrollLeftEnabled.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockPaneStrip_ScrollRightDisabled.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockPaneStrip_ScrollRightEnabled.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Resources/Dockindicator_PaneDiamond_Fill.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Strings.Designer.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/Strings.resx delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/VS2003AutoHideStrip.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/VS2003DockPaneCaption.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Customization/VS2003DockPaneStrip.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/DockSample.csproj delete mode 100644 src/Libraries/DockPanel_Src/DockSample/DummyDoc.Designer.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/DummyDoc.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/DummyDoc.resx delete mode 100644 src/Libraries/DockPanel_Src/DockSample/DummyOutputWindow.Designer.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/DummyOutputWindow.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/DummyOutputWindow.resx delete mode 100644 src/Libraries/DockPanel_Src/DockSample/DummyPropertyWindow.Designer.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/DummyPropertyWindow.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/DummyPropertyWindow.resx delete mode 100644 src/Libraries/DockPanel_Src/DockSample/DummySolutionExplorer.Designer.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/DummySolutionExplorer.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/DummySolutionExplorer.resx delete mode 100644 src/Libraries/DockPanel_Src/DockSample/DummyTaskList.Designer.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/DummyTaskList.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/DummyTaskList.resx delete mode 100644 src/Libraries/DockPanel_Src/DockSample/DummyToolbox.Designer.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/DummyToolbox.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/DummyToolbox.resx delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Images/ArrowDown.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Images/ArrowUp.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Images/Bitmap.ico delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Images/BlankIcon.ico delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Images/CSFile.ico delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Images/CSProject.ico delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Images/ClosedFolder.ICO delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Images/File.ico delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Images/Form.ico delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Images/Mouse.bmp delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Images/New.ico delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Images/Open.ico delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Images/OpenFolder.ICO delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Images/OutputWindow.ico delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Images/PropertyWindow.ico delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Images/Reference.ico delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Images/References.ico delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Images/SolutionExplorer.ico delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Images/TaskListWindow.ico delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Images/ToolboxWindow.ico delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Images/XmlFile.ico delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Images/msenv22.ico delete mode 100644 src/Libraries/DockPanel_Src/DockSample/MainForm.Designer.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/MainForm.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/MainForm.resx delete mode 100644 src/Libraries/DockPanel_Src/DockSample/MainForm2.Designer.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/MainForm2.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/MainForm2.resx delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Program.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Properties/AssemblyInfo.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Properties/Resources.Designer.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Properties/Resources.resx delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Properties/Settings.Designer.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Properties/Settings.settings delete mode 100644 src/Libraries/DockPanel_Src/DockSample/Resources/DockPanel.xml delete mode 100644 src/Libraries/DockPanel_Src/DockSample/ToolWindow.Designer.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/ToolWindow.cs delete mode 100644 src/Libraries/DockPanel_Src/DockSample/ToolWindow.resx delete mode 100644 src/Libraries/DockPanel_Src/DockSample/license.txt delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI.Docking.sln delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/AutoHideStripBase.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockAreasEditor.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockContent.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockContentCollection.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockContentEventArgs.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockContentHandler.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockOutlineBase.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPane.SplitterControl.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPane.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPaneCaptionBase.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPaneCollection.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPaneStripBase.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.AutoHideWindow.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.DockDragHandler.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.DragHandler.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.FocusManager.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.MdiClientController.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.Persistor.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.SplitterDragHandler.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanelExtender.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockWindow.SplitterControl.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockWindow.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockWindowCollection.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DragForm.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/DummyControl.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Enums.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/FloatWindow.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/FloatWindowCollection.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Helpers/DockHelper.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Helpers/DrawHelper.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Helpers/ResourceHelper.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Helpers/Win32Helper.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/InertButtonBase.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Interfaces.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Localization.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Measures.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/NestedDockingStatus.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/NestedPaneCollection.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources.Designer.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources.resx delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PaneDiamond.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PaneDiamond_Bottom.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PaneDiamond_Hotspot.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PaneDiamond_HotspotIndex.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PaneDiamond_Left.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PaneDiamond_Right.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PaneDiamond_Top.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PanelBottom.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PanelBottom_Active.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PanelFill.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PanelFill_Active.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PanelLeft.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PanelLeft_Active.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PanelRight.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PanelRight_Active.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PanelTop.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PanelTop_Active.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockPane_AutoHide.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockPane_Close.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockPane_Dock.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockPane_Option.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockPane_OptionOverflow.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/Dockindicator_PaneDiamond_Fill.bmp delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/Thumbs.db delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/SplitterBase.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Strings.Designer.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Strings.resx delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/VS2005AutoHideStrip.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/VS2005DockPaneCaption.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/VS2005DockPaneStrip.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/VisibleNestedPaneCollection.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Win32/Enums.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Docking/Win32/NativeMethods.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/Properties/AssemblyInfo.cs delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/WinFormsUI.csproj delete mode 100644 src/Libraries/DockPanel_Src/WinFormsUI/license.txt delete mode 100644 src/Libraries/DockPanel_Src/license.txt delete mode 100644 src/Libraries/DockPanel_Src/patchnotes.txt create mode 100644 src/Main/Base/Project/Src/Gui/Workbench/Layouts/AvalonDockLayout.cs create mode 100644 src/Main/Base/Project/Src/Gui/Workbench/WpfWorkbench.cs create mode 100644 src/Main/Base/Project/Src/Util/WpfSynchronizeInvoke.cs diff --git a/src/AddIns/BackendBindings/FSharp/FSharpBinding/Project/FSharpBinding.fsproj b/src/AddIns/BackendBindings/FSharp/FSharpBinding/Project/FSharpBinding.fsproj index ffc8d8dfe5..fb8a62eaf9 100644 --- a/src/AddIns/BackendBindings/FSharp/FSharpBinding/Project/FSharpBinding.fsproj +++ b/src/AddIns/BackendBindings/FSharp/FSharpBinding/Project/FSharpBinding.fsproj @@ -28,7 +28,7 @@ ..\..\RequiredLibraries\FSharp.Build.Tasks.dll - ..\..\..\..\..\Libraries\log4net\log4net.dll + ..\..\..\..\..\..\..\3.0\SharpDevelop\src\Libraries\log4net\log4net.dll False @@ -39,10 +39,19 @@ 3.5 False + ..\..\..\..\..\Libraries\Mono.Cecil\Mono.Cecil.dll False + + + 3.0 + False + + + 3.0 + False @@ -50,9 +59,17 @@ 3.5 False + False + + 3.0 + + + 3.0 + + @@ -75,11 +92,6 @@ - - {D3C782BA-178E-4235-A3BA-8C11DEBB6BEE} - WinFormsUI - False - {2D18BE89-D210-49EB-A9DD-2246FBB3DF6D} ICSharpCode.TextEditor diff --git a/src/AddIns/BackendBindings/WixBinding/Project/Src/Commands/AddWixExtensionToProject.cs b/src/AddIns/BackendBindings/WixBinding/Project/Src/Commands/AddWixExtensionToProject.cs index dbb5bfc748..2f728de1b8 100644 --- a/src/AddIns/BackendBindings/WixBinding/Project/Src/Commands/AddWixExtensionToProject.cs +++ b/src/AddIns/BackendBindings/WixBinding/Project/Src/Commands/AddWixExtensionToProject.cs @@ -25,7 +25,7 @@ namespace ICSharpCode.WixBinding // Display file dialog. using (OpenFileDialog fileDialog = CreateOpenFileDialog()) { - if (DialogResult.OK == fileDialog.ShowDialog(WorkbenchSingleton.MainForm)) { + if (DialogResult.OK == fileDialog.ShowDialog(WorkbenchSingleton.MainWin32Window)) { // Add files to project. WixProject project = ((WixProject)folderNode.Project); project.AddWixExtensions(fileDialog.FileNames); diff --git a/src/AddIns/BackendBindings/WixBinding/Project/Src/Commands/AddWixItemToProjectBaseCommand.cs b/src/AddIns/BackendBindings/WixBinding/Project/Src/Commands/AddWixItemToProjectBaseCommand.cs index 10a2271874..8d50a5c021 100644 --- a/src/AddIns/BackendBindings/WixBinding/Project/Src/Commands/AddWixItemToProjectBaseCommand.cs +++ b/src/AddIns/BackendBindings/WixBinding/Project/Src/Commands/AddWixItemToProjectBaseCommand.cs @@ -39,7 +39,7 @@ namespace ICSharpCode.WixBinding // Display file dialog. using (OpenFileDialog fileDialog = CreateOpenFileDialog(FileFilter)) { - if (DialogResult.OK == fileDialog.ShowDialog(WorkbenchSingleton.MainForm)) { + if (DialogResult.OK == fileDialog.ShowDialog(WorkbenchSingleton.MainWin32Window)) { // Add files to project. WixProject project = ((WixProject)folderNode.Project); AddFiles(project, fileDialog.FileNames); diff --git a/src/AddIns/DisplayBindings/ClassDiagram/ClassWizard/Src/AddNewClassCommand.cs b/src/AddIns/DisplayBindings/ClassDiagram/ClassWizard/Src/AddNewClassCommand.cs index 9299dd9f96..a718c52d78 100644 --- a/src/AddIns/DisplayBindings/ClassDiagram/ClassWizard/Src/AddNewClassCommand.cs +++ b/src/AddIns/DisplayBindings/ClassDiagram/ClassWizard/Src/AddNewClassCommand.cs @@ -27,7 +27,7 @@ namespace ClassWizard using (AddClassForm form = new AddClassForm()) { form.Owner = (Form) WorkbenchSingleton.Workbench; - form.ShowDialog(WorkbenchSingleton.MainForm); + form.ShowDialog(WorkbenchSingleton.MainWin32Window); } } } diff --git a/src/AddIns/DisplayBindings/ClassDiagram/ClassWizard/Src/ClassesList.cs b/src/AddIns/DisplayBindings/ClassDiagram/ClassWizard/Src/ClassesList.cs index 40fcc7f319..47a16ba9aa 100644 --- a/src/AddIns/DisplayBindings/ClassDiagram/ClassWizard/Src/ClassesList.cs +++ b/src/AddIns/DisplayBindings/ClassDiagram/ClassWizard/Src/ClassesList.cs @@ -7,14 +7,14 @@ * To change this template use Tools | Options | Coding | Edit Standard Headers. */ +using ICSharpCode.SharpDevelop.Gui; using System; using System.Collections.Generic; using System.Windows.Forms; - using ICSharpCode.SharpDevelop; -using ICSharpCode.SharpDevelop.Project; -using ICSharpCode.SharpDevelop.Gui.XmlForms; using ICSharpCode.SharpDevelop.Dom; +using ICSharpCode.SharpDevelop.Gui.XmlForms; +using ICSharpCode.SharpDevelop.Project; namespace ClassWizard { @@ -147,7 +147,7 @@ namespace ClassWizard initialized = true; } - classesList.ShowDialog(); + classesList.ShowDialog(WorkbenchSingleton.MainWin32Window); return classesList.DialogResult == DialogResult.OK; } diff --git a/src/AddIns/DisplayBindings/FormsDesigner/Project/Src/Commands/SideBarCommands.cs b/src/AddIns/DisplayBindings/FormsDesigner/Project/Src/Commands/SideBarCommands.cs index 1a93f32039..a1ab90ec07 100644 --- a/src/AddIns/DisplayBindings/FormsDesigner/Project/Src/Commands/SideBarCommands.cs +++ b/src/AddIns/DisplayBindings/FormsDesigner/Project/Src/Commands/SideBarCommands.cs @@ -17,7 +17,7 @@ namespace ICSharpCode.FormsDesigner public override void Run() { using (ConfigureSideBarDialog configureSideBarDialog = new ConfigureSideBarDialog()) { - if (configureSideBarDialog.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (configureSideBarDialog.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { ToolboxProvider.ReloadSideTabs(true); } } diff --git a/src/AddIns/DisplayBindings/FormsDesigner/Project/Src/Gui/AddComponentsDialog.cs b/src/AddIns/DisplayBindings/FormsDesigner/Project/Src/Gui/AddComponentsDialog.cs index 57fa62526a..a03a250d8a 100644 --- a/src/AddIns/DisplayBindings/FormsDesigner/Project/Src/Gui/AddComponentsDialog.cs +++ b/src/AddIns/DisplayBindings/FormsDesigner/Project/Src/Gui/AddComponentsDialog.cs @@ -221,7 +221,7 @@ namespace ICSharpCode.FormsDesigner.Gui fdiag.Multiselect = true; fdiag.CheckFileExists = true; - if (fdiag.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (fdiag.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { ControlDictionary["fileNameTextBox"].Text = string.Join(";", fdiag.FileNames); } } diff --git a/src/AddIns/DisplayBindings/FormsDesigner/Project/Src/Services/UIService.cs b/src/AddIns/DisplayBindings/FormsDesigner/Project/Src/Services/UIService.cs index f4b5e89042..d84fbe9ca5 100644 --- a/src/AddIns/DisplayBindings/FormsDesigner/Project/Src/Services/UIService.cs +++ b/src/AddIns/DisplayBindings/FormsDesigner/Project/Src/Services/UIService.cs @@ -52,7 +52,7 @@ namespace ICSharpCode.FormsDesigner.Services #region Dialog functions public IWin32Window GetDialogOwnerWindow() { - return WorkbenchSingleton.MainForm; + return WorkbenchSingleton.MainWin32Window; } public DialogResult ShowDialog(Form form) diff --git a/src/AddIns/DisplayBindings/ResourceEditor/Project/Src/Commands/AddNewFileCommand.cs b/src/AddIns/DisplayBindings/ResourceEditor/Project/Src/Commands/AddNewFileCommand.cs index 8a31ef65e5..bfc2bc6017 100644 --- a/src/AddIns/DisplayBindings/ResourceEditor/Project/Src/Commands/AddNewFileCommand.cs +++ b/src/AddIns/DisplayBindings/ResourceEditor/Project/Src/Commands/AddNewFileCommand.cs @@ -32,7 +32,7 @@ namespace ResourceEditor fdiag.Multiselect = true; fdiag.CheckFileExists = true; - if (fdiag.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (fdiag.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { foreach (string filename in fdiag.FileNames) { string oresname = Path.ChangeExtension(Path.GetFileName(filename), null); if (oresname == "") oresname = "new"; diff --git a/src/AddIns/DisplayBindings/ResourceEditor/Project/Src/Commands/SaveEntryAsCommand.cs b/src/AddIns/DisplayBindings/ResourceEditor/Project/Src/Commands/SaveEntryAsCommand.cs index de892119f6..4a4aab2a92 100644 --- a/src/AddIns/DisplayBindings/ResourceEditor/Project/Src/Commands/SaveEntryAsCommand.cs +++ b/src/AddIns/DisplayBindings/ResourceEditor/Project/Src/Commands/SaveEntryAsCommand.cs @@ -52,7 +52,7 @@ namespace ResourceEditor return; } - DialogResult dr = sdialog.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm); + DialogResult dr = sdialog.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window); sdialog.Dispose(); if (dr != DialogResult.OK) { return; diff --git a/src/AddIns/DisplayBindings/ResourceEditor/Project/Src/ResourceEdit/BitmapView.cs b/src/AddIns/DisplayBindings/ResourceEditor/Project/Src/ResourceEdit/BitmapView.cs index c93f2ea515..deda2caf34 100644 --- a/src/AddIns/DisplayBindings/ResourceEditor/Project/Src/ResourceEdit/BitmapView.cs +++ b/src/AddIns/DisplayBindings/ResourceEditor/Project/Src/ResourceEdit/BitmapView.cs @@ -42,7 +42,7 @@ namespace ResourceEditor fileDialog.Filter = "All files (*.*)|*.*"; fileDialog.CheckFileExists = true; - if(fileDialog.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { + if(fileDialog.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { try { bitmap = new Bitmap(fileDialog.FileName); } catch { diff --git a/src/AddIns/DisplayBindings/XmlEditor/Project/Src/AssignStylesheetCommand.cs b/src/AddIns/DisplayBindings/XmlEditor/Project/Src/AssignStylesheetCommand.cs index 3d0db5c9a1..fba80cdd21 100644 --- a/src/AddIns/DisplayBindings/XmlEditor/Project/Src/AssignStylesheetCommand.cs +++ b/src/AddIns/DisplayBindings/XmlEditor/Project/Src/AssignStylesheetCommand.cs @@ -52,7 +52,7 @@ namespace ICSharpCode.XmlEditor dialog.FilterIndex = 1; } - if (dialog.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (dialog.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { return dialog.FileName; } } diff --git a/src/AddIns/Misc/AddInManager/Project/Src/ManagerForm.cs b/src/AddIns/Misc/AddInManager/Project/Src/ManagerForm.cs index 84f1efe2ed..7d0f345916 100644 --- a/src/AddIns/Misc/AddInManager/Project/Src/ManagerForm.cs +++ b/src/AddIns/Misc/AddInManager/Project/Src/ManagerForm.cs @@ -32,10 +32,11 @@ namespace ICSharpCode.AddInManager { if (instance == null) { instance = new ManagerForm(); - #if !STANDALONE - instance.Owner = ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm; - #endif + #if STANDALONE instance.Show(); + #else + instance.Show(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window); + #endif } else { instance.Activate(); } diff --git a/src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Debugger.AddIn.csproj b/src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Debugger.AddIn.csproj index 72a206f73b..9f944b3e3b 100644 --- a/src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Debugger.AddIn.csproj +++ b/src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Debugger.AddIn.csproj @@ -19,7 +19,8 @@ 4096 false Always - v2.0 + v3.0 + "C:\Program Files\SharpDevelop\3.0\bin\..\AddIns\AddIns\Misc\SourceAnalysis\Settings.SourceAnalysis" true @@ -35,11 +36,20 @@ TRACE + + 3.0 + + + 3.0 + + + 3.0 + @@ -175,11 +185,6 @@ ICSharpCode.Core.WinForms False - - {80318B5F-A25D-45AB-8A95-EF31D2370A4C} - ICSharpCode.SharpDevelop.Sda - False - diff --git a/src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Service/DebugeeExceptionForm.cs b/src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Service/DebugeeExceptionForm.cs index d7c43398f6..b272afd359 100644 --- a/src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Service/DebugeeExceptionForm.cs +++ b/src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Service/DebugeeExceptionForm.cs @@ -137,7 +137,7 @@ namespace ICSharpCode.SharpDevelop.Services form.exceptionDetails.Refresh(); form.buttonContinue.Enabled = canContinue; - form.ShowDialog(Gui.WorkbenchSingleton.MainForm); + form.ShowDialog(Gui.WorkbenchSingleton.MainWin32Window); return form.result; } } diff --git a/src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Service/DebuggerEventForm.cs b/src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Service/DebuggerEventForm.cs index a69cc4dbbd..6ab99efa0d 100644 --- a/src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Service/DebuggerEventForm.cs +++ b/src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Service/DebuggerEventForm.cs @@ -81,7 +81,7 @@ namespace ICSharpCode.SharpDevelop.Services form.textBox.Text = message; form.pictureBox.Image = icon; form.buttonContinue.Enabled = canContinue; - form.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm); + form.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window); return form.result; } } diff --git a/src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Service/WindowsDebugger.cs b/src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Service/WindowsDebugger.cs index 07ec4dd2c5..932e116f25 100644 --- a/src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Service/WindowsDebugger.cs +++ b/src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Service/WindowsDebugger.cs @@ -189,7 +189,7 @@ namespace ICSharpCode.SharpDevelop.Services public void ShowAttachDialog() { using (AttachToProcessForm attachForm = new AttachToProcessForm()) { - if (attachForm.ShowDialog() == DialogResult.OK) { + if (attachForm.ShowDialog(WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { Attach(attachForm.Process); } } @@ -664,7 +664,7 @@ namespace ICSharpCode.SharpDevelop.Services public void JumpToCurrentLine() { - WorkbenchSingleton.MainForm.Activate(); + WorkbenchSingleton.MainWindow.Activate(); DebuggerService.RemoveCurrentLineMarker(); if (debuggedProcess != null) { SourcecodeSegment nextStatement = debuggedProcess.NextStatement; diff --git a/src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/TreeModel/ErrorNode.cs b/src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/TreeModel/ErrorNode.cs index 86b9c3d645..926e5e1778 100644 --- a/src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/TreeModel/ErrorNode.cs +++ b/src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/TreeModel/ErrorNode.cs @@ -10,7 +10,6 @@ using System.Collections.Generic; using System.Windows.Forms; using ICSharpCode.Core; -using ICSharpCode.SharpDevelop.Sda; using Debugger; using Debugger.Expressions; @@ -48,9 +47,7 @@ namespace Debugger.AddIn.TreeModel showError.Text = StringParser.Parse("${res:MainWindow.Windows.Debug.LocalVariables.ShowFullError}"); showError.Checked = false; showError.Click += delegate { - using (ExceptionBox box = new ExceptionBox(error, null, false)) { - box.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm); - } + MessageService.ShowError(error, null); }; menu.Items.AddRange(new ToolStripItem[] { diff --git a/src/AddIns/Misc/HighlightingEditor/Project/Src/ColorButton.cs b/src/AddIns/Misc/HighlightingEditor/Project/Src/ColorButton.cs index b3b317d216..cec616ad99 100644 --- a/src/AddIns/Misc/HighlightingEditor/Project/Src/ColorButton.cs +++ b/src/AddIns/Misc/HighlightingEditor/Project/Src/ColorButton.cs @@ -58,7 +58,7 @@ namespace ICSharpCode.SharpDevelop.Gui p = PointToScreen(p); using (ColorPaletteDialog clDlg = new ColorPaletteDialog(p.X, p.Y)) { - clDlg.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm); + clDlg.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window); if (clDlg.DialogResult == DialogResult.OK) { CenterColor = clDlg.Color; } diff --git a/src/AddIns/Misc/HighlightingEditor/Project/Src/ColorDialog.cs b/src/AddIns/Misc/HighlightingEditor/Project/Src/ColorDialog.cs index 9d0a247ccf..294346cb06 100644 --- a/src/AddIns/Misc/HighlightingEditor/Project/Src/ColorDialog.cs +++ b/src/AddIns/Misc/HighlightingEditor/Project/Src/ColorDialog.cs @@ -133,7 +133,7 @@ namespace ICSharpCode.SharpDevelop.Gui { using (ColorDialog colDialog = new ColorDialog()) { colDialog.FullOpen = true; - if (colDialog.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (colDialog.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { selectedColor = colDialog.Color; DialogResult = DialogResult.OK; } diff --git a/src/AddIns/Misc/HighlightingEditor/Project/Src/EditHighlightingPanel.cs b/src/AddIns/Misc/HighlightingEditor/Project/Src/EditHighlightingPanel.cs index 69d681516f..6dfc2dfa03 100644 --- a/src/AddIns/Misc/HighlightingEditor/Project/Src/EditHighlightingPanel.cs +++ b/src/AddIns/Misc/HighlightingEditor/Project/Src/EditHighlightingPanel.cs @@ -182,7 +182,7 @@ namespace ICSharpCode.SharpDevelop.Gui.OptionPanels HighlightItem item = (HighlightItem)userList.SelectedItem; using (EditHighlightingDialog dlg = new EditHighlightingDialog(item.Node)) { - DialogResult res = dlg.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm); + DialogResult res = dlg.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window); if (res == DialogResult.OK) { using (XmlTextWriter writer = new XmlTextWriter(item.FileName, Encoding.UTF8)) { diff --git a/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/KeywordListNode.cs b/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/KeywordListNode.cs index f007848dbe..a06099f2bc 100644 --- a/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/KeywordListNode.cs +++ b/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/KeywordListNode.cs @@ -181,7 +181,7 @@ namespace ICSharpCode.SharpDevelop.AddIns.HighlightingEditor.Nodes { using (InputBox box = new InputBox()) { box.Label.Text = ResourceService.GetString("Dialog.HighlightingEditor.KeywordList.EnterName"); - if (box.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.Cancel) return; + if (box.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.Cancel) return; if (box.TextBox.Text == "") return; foreach (string item in listBox.Items) { diff --git a/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/KeywordListsNode.cs b/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/KeywordListsNode.cs index 888c0410a1..d48615b280 100644 --- a/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/KeywordListsNode.cs +++ b/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/KeywordListsNode.cs @@ -82,7 +82,7 @@ namespace ICSharpCode.SharpDevelop.AddIns.HighlightingEditor.Nodes { using (InputBox box = new InputBox()) { box.Label.Text = ResourceService.GetString("Dialog.HighlightingEditor.KeywordLists.EnterName"); - if (box.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.Cancel) return; + if (box.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.Cancel) return; if (box.TextBox.Text == "") return; foreach (ListViewItem item in listView.Items) { diff --git a/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/MarkersNode.cs b/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/MarkersNode.cs index 7a91232bd8..4404c56145 100644 --- a/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/MarkersNode.cs +++ b/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/MarkersNode.cs @@ -86,7 +86,7 @@ namespace ICSharpCode.SharpDevelop.AddIns.HighlightingEditor.Nodes { using (InputBox box = new InputBox()) { box.Label.Text = ResourceService.GetString("Dialog.HighlightingEditor.Markers.EnterName"); - if (box.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.Cancel) return; + if (box.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.Cancel) return; if (box.TextBox.Text == "") return; foreach (ListViewItem item in listView.Items) { diff --git a/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/PropertiesNode.cs b/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/PropertiesNode.cs index fd7d28e109..47e9ec8d5c 100644 --- a/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/PropertiesNode.cs +++ b/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/PropertiesNode.cs @@ -96,7 +96,7 @@ namespace ICSharpCode.SharpDevelop.AddIns.HighlightingEditor.Nodes { using (InputBox box = new InputBox()) { box.Label.Text = ResourceService.GetString("Dialog.HighlightingEditor.Properties.EnterName"); - if (box.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.Cancel) return; + if (box.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.Cancel) return; foreach (ListViewItem item in listView.Items) { if (item.Text == box.TextBox.Text) @@ -121,7 +121,7 @@ namespace ICSharpCode.SharpDevelop.AddIns.HighlightingEditor.Nodes using (InputBox box = new InputBox()) { box.Text = ResourceService.GetString("Dialog.HighlightingEditor.EnterText"); box.Label.Text = String.Format(ResourceService.GetString("Dialog.HighlightingEditor.Properties.EnterValue"), listView.SelectedItems[0].Text); - if (box.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.Cancel) return; + if (box.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.Cancel) return; listView.SelectedItems[0].SubItems[1].Text = box.TextBox.Text; } diff --git a/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/RuleSetsNode.cs b/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/RuleSetsNode.cs index f48b18733c..2e87bab233 100644 --- a/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/RuleSetsNode.cs +++ b/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/RuleSetsNode.cs @@ -84,7 +84,7 @@ namespace ICSharpCode.SharpDevelop.AddIns.HighlightingEditor.Nodes { using (InputBox box = new InputBox()) { box.Label.Text = ResourceService.GetString("Dialog.HighlightingEditor.RuleSets.EnterName"); - if (box.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.Cancel) return; + if (box.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.Cancel) return; if (box.TextBox.Text == "") return; foreach (ListViewItem item in listView.Items) { diff --git a/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/SpansNode.cs b/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/SpansNode.cs index ccbf27556a..fb8ee9e0c8 100644 --- a/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/SpansNode.cs +++ b/src/AddIns/Misc/HighlightingEditor/Project/Src/Nodes/SpansNode.cs @@ -80,7 +80,7 @@ namespace ICSharpCode.SharpDevelop.AddIns.HighlightingEditor.Nodes { using (InputBox box = new InputBox()) { box.Label.Text = ResourceService.GetString("Dialog.HighlightingEditor.Spans.EnterName"); - if (box.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.Cancel) return; + if (box.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.Cancel) return; if (box.TextBox.Text == "") return; diff --git a/src/AddIns/Misc/PInvokeAddIn/Project/Src/InsertPInvokeSignaturesCommand.cs b/src/AddIns/Misc/PInvokeAddIn/Project/Src/InsertPInvokeSignaturesCommand.cs index 79c033985e..cdf9b5d841 100644 --- a/src/AddIns/Misc/PInvokeAddIn/Project/Src/InsertPInvokeSignaturesCommand.cs +++ b/src/AddIns/Misc/PInvokeAddIn/Project/Src/InsertPInvokeSignaturesCommand.cs @@ -7,6 +7,7 @@ using System; using ICSharpCode.Core; +using ICSharpCode.SharpDevelop.Gui; namespace ICSharpCode.PInvokeAddIn { @@ -23,7 +24,7 @@ namespace ICSharpCode.PInvokeAddIn { // Show PInvoke dialog. using(InsertPInvokeSignaturesForm form = new InsertPInvokeSignaturesForm()) { - form.ShowDialog(); + form.ShowDialog(WorkbenchSingleton.MainWin32Window); } } } diff --git a/src/AddIns/Misc/ReflectorAddIn/ReflectorAddIn/Project/Src/TextEditorContextMenuCommand.cs b/src/AddIns/Misc/ReflectorAddIn/ReflectorAddIn/Project/Src/TextEditorContextMenuCommand.cs index 6f17d11383..1eedb42996 100644 --- a/src/AddIns/Misc/ReflectorAddIn/ReflectorAddIn/Project/Src/TextEditorContextMenuCommand.cs +++ b/src/AddIns/Misc/ReflectorAddIn/ReflectorAddIn/Project/Src/TextEditorContextMenuCommand.cs @@ -137,7 +137,7 @@ namespace ReflectorAddIn Application.DoEvents(); Cursor.Current = Cursors.WaitCursor; - ReflectorController.TryGoTo(element, WorkbenchSingleton.MainForm); + ReflectorController.TryGoTo(element, WorkbenchSingleton.MainWin32Window); } finally { Cursor.Current = Cursors.Default; diff --git a/src/AddIns/Misc/RegExpTk/Project/Src/Commands/MenuCommand.cs b/src/AddIns/Misc/RegExpTk/Project/Src/Commands/MenuCommand.cs index 1773c0d109..892c8dcd1b 100644 --- a/src/AddIns/Misc/RegExpTk/Project/Src/Commands/MenuCommand.cs +++ b/src/AddIns/Misc/RegExpTk/Project/Src/Commands/MenuCommand.cs @@ -7,17 +7,17 @@ using System; using ICSharpCode.Core; +using ICSharpCode.SharpDevelop.Gui; namespace Plugins.RegExpTk { public class RegExpTkCommand : AbstractMenuCommand { - public override void Run() { - RegExpTkDialog dialog = new RegExpTkDialog(); - dialog.Owner = ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm; - dialog.Show(); + using (RegExpTkDialog dialog = new RegExpTkDialog()) { + dialog.Show(WorkbenchSingleton.MainWin32Window); + } } } } diff --git a/src/AddIns/Misc/RegExpTk/Project/Src/Dialogs/MainWindow.cs b/src/AddIns/Misc/RegExpTk/Project/Src/Dialogs/MainWindow.cs index 15a65d5b9a..bb3cc1ea55 100644 --- a/src/AddIns/Misc/RegExpTk/Project/Src/Dialogs/MainWindow.cs +++ b/src/AddIns/Misc/RegExpTk/Project/Src/Dialogs/MainWindow.cs @@ -131,7 +131,7 @@ namespace Plugins.RegExpTk { void showGroupForm(Match match) { GroupForm groupform = new GroupForm(match); - groupform.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm); + groupform.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window); } void GroupListView_MouseUp(object sender, MouseEventArgs e) @@ -253,7 +253,7 @@ namespace Plugins.RegExpTk { sfd.DefaultExt = "dll"; sfd.CheckPathExists = true; - if (sfd.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (sfd.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { ((TextBox)ControlDictionary["AssemblyFileCompileFileTextBox"]).Text = sfd.FileName; } } diff --git a/src/AddIns/Misc/ResourceToolkit/Project/Src/CodeCompletion/NewResourceCodeCompletionData.cs b/src/AddIns/Misc/ResourceToolkit/Project/Src/CodeCompletion/NewResourceCodeCompletionData.cs index fb54c1e626..adf93845b3 100644 --- a/src/AddIns/Misc/ResourceToolkit/Project/Src/CodeCompletion/NewResourceCodeCompletionData.cs +++ b/src/AddIns/Misc/ResourceToolkit/Project/Src/CodeCompletion/NewResourceCodeCompletionData.cs @@ -48,7 +48,7 @@ namespace Hornung.ResourceToolkit.CodeCompletion EditStringResourceDialog dialog = new EditStringResourceDialog(this.content, this.preEnteredName, null, true); dialog.Text = this.Description; - if (dialog.ShowDialog(WorkbenchSingleton.MainForm) != DialogResult.OK) { + if (dialog.ShowDialog(WorkbenchSingleton.MainWin32Window) != DialogResult.OK) { return false; } diff --git a/src/AddIns/Misc/ResourceToolkit/Project/Src/Commands/TextEditorContextMenuBuilder.cs b/src/AddIns/Misc/ResourceToolkit/Project/Src/Commands/TextEditorContextMenuBuilder.cs index 10f9554fb4..e7949eb6db 100644 --- a/src/AddIns/Misc/ResourceToolkit/Project/Src/Commands/TextEditorContextMenuBuilder.cs +++ b/src/AddIns/Misc/ResourceToolkit/Project/Src/Commands/TextEditorContextMenuBuilder.cs @@ -100,7 +100,7 @@ namespace Hornung.ResourceToolkit.Commands if (svalue == null) { dialog.Text = String.Format(CultureInfo.CurrentCulture, StringParser.Parse("${res:Hornung.ResourceToolkit.CodeCompletion.AddNewDescription}"), result.ResourceFileContent.FileName); } - if (dialog.ShowDialog(WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (dialog.ShowDialog(WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { if (svalue == null) { // Add new resource. result.ResourceFileContent.Add(dialog.Key, dialog.Value); diff --git a/src/AddIns/Misc/SearchAndReplace/Project/Engine/SearchReplaceManager.cs b/src/AddIns/Misc/SearchAndReplace/Project/Engine/SearchReplaceManager.cs index daf014d8e6..b8cb6d186c 100644 --- a/src/AddIns/Misc/SearchAndReplace/Project/Engine/SearchReplaceManager.cs +++ b/src/AddIns/Misc/SearchAndReplace/Project/Engine/SearchReplaceManager.cs @@ -365,7 +365,7 @@ namespace SearchAndReplace if (monitor != null && monitor.IsCancelled) return; if (monitor != null) monitor.ShowingDialog = true; - MessageBox.Show(WorkbenchSingleton.MainForm, + MessageBox.Show(WorkbenchSingleton.MainWin32Window, ResourceService.GetString("Dialog.NewProject.SearchReplace.SearchStringNotFound"), ResourceService.GetString("Dialog.NewProject.SearchReplace.SearchStringNotFound.Title"), MessageBoxButtons.OK, diff --git a/src/AddIns/Misc/SearchAndReplace/Project/Gui/SearchAndReplaceDialog.cs b/src/AddIns/Misc/SearchAndReplace/Project/Gui/SearchAndReplaceDialog.cs index 8c08a303a2..0e83d92e64 100644 --- a/src/AddIns/Misc/SearchAndReplace/Project/Gui/SearchAndReplaceDialog.cs +++ b/src/AddIns/Misc/SearchAndReplace/Project/Gui/SearchAndReplaceDialog.cs @@ -36,7 +36,7 @@ namespace SearchAndReplace { if (Instance == null) { Instance = new SearchAndReplaceDialog(searchAndReplaceMode); - Instance.Show(WorkbenchSingleton.MainForm); + Instance.Show(WorkbenchSingleton.MainWin32Window); } else { if (searchAndReplaceMode == SearchAndReplaceMode.Search) { Instance.searchButton.PerformClick(); @@ -54,7 +54,6 @@ namespace SearchAndReplace public SearchAndReplaceDialog(SearchAndReplaceMode searchAndReplaceMode) { - this.Owner = WorkbenchSingleton.MainForm; this.FormBorderStyle = FormBorderStyle.FixedToolWindow; this.ShowInTaskbar = false; this.TopMost = false; diff --git a/src/AddIns/Misc/SubversionAddIn/Project/Src/Gui/SvnGuiWrapper.cs b/src/AddIns/Misc/SubversionAddIn/Project/Src/Gui/SvnGuiWrapper.cs index 592ae8c10b..ec893f3dbc 100644 --- a/src/AddIns/Misc/SubversionAddIn/Project/Src/Gui/SvnGuiWrapper.cs +++ b/src/AddIns/Misc/SubversionAddIn/Project/Src/Gui/SvnGuiWrapper.cs @@ -11,6 +11,7 @@ using System.Text; using System.Windows.Forms; using ICSharpCode.Core; +using ICSharpCode.SharpDevelop.Gui; using Microsoft.Win32; namespace ICSharpCode.Svn @@ -46,7 +47,7 @@ namespace ICSharpCode.Svn string path = GetPathFromRegistry("ProcPath"); if (path == null) { using (TortoiseSvnNotFoundForm form = new TortoiseSvnNotFoundForm()) { - form.ShowDialog(); + form.ShowDialog(WorkbenchSingleton.MainWin32Window); } } else { try { diff --git a/src/AddIns/Misc/SubversionAddIn/Project/Src/SvnClientWrapper.cs b/src/AddIns/Misc/SubversionAddIn/Project/Src/SvnClientWrapper.cs index adc0b0d3f3..b2e5266402 100644 --- a/src/AddIns/Misc/SubversionAddIn/Project/Src/SvnClientWrapper.cs +++ b/src/AddIns/Misc/SubversionAddIn/Project/Src/SvnClientWrapper.cs @@ -206,7 +206,7 @@ namespace ICSharpCode.Svn LoggingService.Debug("PasswordPrompt"); try { using (LoginDialog loginDialog = new LoginDialog(realm.Value, username.Value, maySave)) { - if (WorkbenchSingleton.SafeThreadFunction(loginDialog.ShowDialog, WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (WorkbenchSingleton.SafeThreadFunction(loginDialog.ShowDialog, WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { cred = loginDialog.CreateCredential(pool); } } @@ -222,7 +222,7 @@ namespace ICSharpCode.Svn LoggingService.Debug("SslServerTrustPrompt"); try { using (SslServerTrustDialog sslServerTrustDialog = new SslServerTrustDialog(certInfo, failures, maySave)) { - if (WorkbenchSingleton.SafeThreadFunction(sslServerTrustDialog.ShowDialog, WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (WorkbenchSingleton.SafeThreadFunction(sslServerTrustDialog.ShowDialog, WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { cred = sslServerTrustDialog.CreateCredential(pool); } } @@ -238,7 +238,7 @@ namespace ICSharpCode.Svn LoggingService.Debug("SslServerTrustPrompt"); try { using (ClientCertPassphraseDialog clientCertPassphraseDialog = new ClientCertPassphraseDialog(realm.Value, maySave)) { - if (WorkbenchSingleton.SafeThreadFunction(clientCertPassphraseDialog.ShowDialog, WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (WorkbenchSingleton.SafeThreadFunction(clientCertPassphraseDialog.ShowDialog, WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { cred = clientCertPassphraseDialog.CreateCredential(pool); } } @@ -254,7 +254,7 @@ namespace ICSharpCode.Svn LoggingService.Debug("SslServerTrustPrompt"); try { using (ClientCertDialog clientCertDialog = new ClientCertDialog(realm.Value, maySave)) { - if (WorkbenchSingleton.SafeThreadFunction(clientCertDialog.ShowDialog, WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (WorkbenchSingleton.SafeThreadFunction(clientCertDialog.ShowDialog, WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { cred = clientCertDialog.CreateCredential(pool); } } diff --git a/src/Libraries/DockPanel_Src/DockSample/AboutDialog.Designer.cs b/src/Libraries/DockPanel_Src/DockSample/AboutDialog.Designer.cs deleted file mode 100644 index f4f4a832bd..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/AboutDialog.Designer.cs +++ /dev/null @@ -1,118 +0,0 @@ -namespace DockSample -{ - partial class AboutDialog - { - /// - /// Required designer variable. - /// - private System.ComponentModel.IContainer components = null; - - /// - /// Clean up any resources being used. - /// - /// true if managed resources should be disposed; otherwise, false. - protected override void Dispose(bool disposing) - { - if (disposing && (components != null)) - { - components.Dispose(); - } - base.Dispose(disposing); - } - - #region Windows Form Designer generated code - /// - /// Required method for Designer support - do not modify - /// the contents of this method with the code editor. - /// - private void InitializeComponent() - { - this.buttonOK = new System.Windows.Forms.Button(); - this.label1 = new System.Windows.Forms.Label(); - this.label2 = new System.Windows.Forms.Label(); - this.label3 = new System.Windows.Forms.Label(); - this.labelLibVersion = new System.Windows.Forms.Label(); - this.labelAppVersion = new System.Windows.Forms.Label(); - this.SuspendLayout(); - // - // buttonOK - // - this.buttonOK.DialogResult = System.Windows.Forms.DialogResult.Cancel; - this.buttonOK.Location = new System.Drawing.Point(240, 184); - this.buttonOK.Name = "buttonOK"; - this.buttonOK.Size = new System.Drawing.Size(75, 23); - this.buttonOK.TabIndex = 0; - this.buttonOK.Text = "OK"; - // - // label1 - // - this.label1.Location = new System.Drawing.Point(24, 59); - this.label1.Name = "label1"; - this.label1.Size = new System.Drawing.Size(109, 16); - this.label1.TabIndex = 1; - this.label1.Text = "DockSample Version:"; - // - // label2 - // - this.label2.Location = new System.Drawing.Point(24, 119); - this.label2.Name = "label2"; - this.label2.Size = new System.Drawing.Size(272, 32); - this.label2.TabIndex = 2; - this.label2.Text = "Copyright 2007, Weifen Luo"; - // - // label3 - // - this.label3.AutoSize = true; - this.label3.Location = new System.Drawing.Point(24, 81); - this.label3.Name = "label3"; - this.label3.Size = new System.Drawing.Size(128, 13); - this.label3.TabIndex = 3; - this.label3.Text = "DockPanel Suite Version:"; - // - // labelLibVersion - // - this.labelLibVersion.Location = new System.Drawing.Point(148, 81); - this.labelLibVersion.Name = "labelLibVersion"; - this.labelLibVersion.Size = new System.Drawing.Size(97, 13); - this.labelLibVersion.TabIndex = 4; - // - // labelAppVersion - // - this.labelAppVersion.Location = new System.Drawing.Point(129, 59); - this.labelAppVersion.Name = "labelAppVersion"; - this.labelAppVersion.Size = new System.Drawing.Size(97, 13); - this.labelAppVersion.TabIndex = 5; - // - // AboutDialog - // - this.AcceptButton = this.buttonOK; - this.CancelButton = this.buttonOK; - this.ClientSize = new System.Drawing.Size(322, 215); - this.Controls.Add(this.labelAppVersion); - this.Controls.Add(this.labelLibVersion); - this.Controls.Add(this.label3); - this.Controls.Add(this.label2); - this.Controls.Add(this.label1); - this.Controls.Add(this.buttonOK); - this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle; - this.MaximizeBox = false; - this.MinimizeBox = false; - this.Name = "AboutDialog"; - this.ShowInTaskbar = false; - this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent; - this.Text = "About"; - this.Load += new System.EventHandler(this.AboutDialog_Load); - this.ResumeLayout(false); - this.PerformLayout(); - - } - #endregion - - private System.Windows.Forms.Label label2; - private System.Windows.Forms.Label label1; - private System.Windows.Forms.Button buttonOK; - private System.Windows.Forms.Label label3; - private System.Windows.Forms.Label labelLibVersion; - private System.Windows.Forms.Label labelAppVersion; - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/AboutDialog.cs b/src/Libraries/DockPanel_Src/DockSample/AboutDialog.cs deleted file mode 100644 index c84735c1d6..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/AboutDialog.cs +++ /dev/null @@ -1,26 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel; -using System.Data; -using System.Drawing; -using System.Text; -using System.Windows.Forms; -using System.Reflection; -using WeifenLuo.WinFormsUI.Docking; - -namespace DockSample -{ - public partial class AboutDialog : Form - { - public AboutDialog() - { - InitializeComponent(); - } - - private void AboutDialog_Load(object sender, EventArgs e) - { - labelAppVersion.Text = typeof(MainForm).Assembly.GetName().Version.ToString(); - labelLibVersion.Text = typeof(DockPanel).Assembly.GetName().Version.ToString(); - } - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/AboutDialog.resx b/src/Libraries/DockPanel_Src/DockSample/AboutDialog.resx deleted file mode 100644 index 19dc0dd8b3..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/AboutDialog.resx +++ /dev/null @@ -1,120 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/Customization/DockHelper.cs b/src/Libraries/DockPanel_Src/DockSample/Customization/DockHelper.cs deleted file mode 100644 index f5fbf3c50f..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/Customization/DockHelper.cs +++ /dev/null @@ -1,113 +0,0 @@ -using System; -using System.Drawing; -using System.Windows.Forms; -using WeifenLuo.WinFormsUI.Docking; - -namespace DockSample.Customization -{ - internal class DockHelper - { - public static bool IsDockStateAutoHide(DockState dockState) - { - if (dockState == DockState.DockLeftAutoHide || - dockState == DockState.DockRightAutoHide || - dockState == DockState.DockTopAutoHide || - dockState == DockState.DockBottomAutoHide) - return true; - else - return false; - } - - public static bool IsDockStateDocked(DockState dockState) - { - return (dockState == DockState.DockLeft || - dockState == DockState.DockRight || - dockState == DockState.DockTop || - dockState == DockState.DockBottom); - } - - public static bool IsDockBottom(DockState dockState) - { - return (dockState == DockState.DockBottom || dockState == DockState.DockBottomAutoHide) ? true : false; - } - - public static bool IsDockLeft(DockState dockState) - { - return (dockState == DockState.DockLeft || dockState == DockState.DockLeftAutoHide) ? true : false; - } - - public static bool IsDockRight(DockState dockState) - { - return (dockState == DockState.DockRight || dockState == DockState.DockRightAutoHide) ? true : false; - } - - public static bool IsDockTop(DockState dockState) - { - return (dockState == DockState.DockTop || dockState == DockState.DockTopAutoHide ) ? true : false; - } - - public static bool IsDockStateValid(DockState dockState, DockAreas dockableAreas) - { - if (((dockableAreas & DockAreas.Float) == 0) && - (dockState == DockState.Float)) - return false; - else if (((dockableAreas & DockAreas.Document) == 0) && - (dockState == DockState.Document)) - return false; - else if (((dockableAreas & DockAreas.DockLeft) == 0) && - (dockState == DockState.DockLeft || dockState == DockState.DockLeftAutoHide)) - return false; - else if (((dockableAreas & DockAreas.DockRight) == 0) && - (dockState == DockState.DockRight || dockState == DockState.DockRightAutoHide)) - return false; - else if (((dockableAreas & DockAreas.DockTop) == 0) && - (dockState == DockState.DockTop || dockState == DockState.DockTopAutoHide)) - return false; - else if (((dockableAreas & DockAreas.DockBottom) == 0) && - (dockState == DockState.DockBottom || dockState == DockState.DockBottomAutoHide)) - return false; - else - return true; - } - - public static bool IsDockWindowState(DockState state) - { - if (state == DockState.DockTop || state == DockState.DockBottom || state == DockState.DockLeft || - state == DockState.DockRight || state == DockState.Document) - return true; - else - return false; - } - - public static bool IsValidRestoreState(DockState state) - { - if (state == DockState.DockLeft || state == DockState.DockRight || state == DockState.DockTop || - state == DockState.DockBottom || state == DockState.Document) - return true; - else - return false; - } - - public static DockState ToggleAutoHideState(DockState state) - { - if (state == DockState.DockLeft) - return DockState.DockLeftAutoHide; - else if (state == DockState.DockRight) - return DockState.DockRightAutoHide; - else if (state == DockState.DockTop) - return DockState.DockTopAutoHide; - else if (state == DockState.DockBottom) - return DockState.DockBottomAutoHide; - else if (state == DockState.DockLeftAutoHide) - return DockState.DockLeft; - else if (state == DockState.DockRightAutoHide) - return DockState.DockRight; - else if (state == DockState.DockTopAutoHide) - return DockState.DockTop; - else if (state == DockState.DockBottomAutoHide) - return DockState.DockBottom; - else - return state; - } - } -} diff --git a/src/Libraries/DockPanel_Src/DockSample/Customization/Extender.cs b/src/Libraries/DockPanel_Src/DockSample/Customization/Extender.cs deleted file mode 100644 index 180ecb84f1..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/Customization/Extender.cs +++ /dev/null @@ -1,55 +0,0 @@ -using System; -using System.Drawing; -using WeifenLuo.WinFormsUI.Docking; - -namespace DockSample.Customization -{ - public class Extender - { - public enum Schema - { - VS2005, - VS2003 - } - - private class VS2003DockPaneStripFactory : DockPanelExtender.IDockPaneStripFactory - { - public DockPaneStripBase CreateDockPaneStrip(DockPane pane) - { - return new VS2003DockPaneStrip(pane); - } - } - - private class VS2003AutoHideStripFactory : DockPanelExtender.IAutoHideStripFactory - { - public AutoHideStripBase CreateAutoHideStrip(DockPanel panel) - { - return new VS2003AutoHideStrip(panel); - } - } - - private class VS2003DockPaneCaptionFactory : DockPanelExtender.IDockPaneCaptionFactory - { - public DockPaneCaptionBase CreateDockPaneCaption(DockPane pane) - { - return new VS2003DockPaneCaption(pane); - } - } - - public static void SetSchema(DockPanel dockPanel, Extender.Schema schema) - { - if (schema == Extender.Schema.VS2005) - { - dockPanel.Extender.AutoHideStripFactory = null; - dockPanel.Extender.DockPaneCaptionFactory = null; - dockPanel.Extender.DockPaneStripFactory = null; - } - else if (schema == Extender.Schema.VS2003) - { - dockPanel.Extender.DockPaneCaptionFactory = new VS2003DockPaneCaptionFactory(); - dockPanel.Extender.AutoHideStripFactory = new VS2003AutoHideStripFactory(); - dockPanel.Extender.DockPaneStripFactory = new VS2003DockPaneStripFactory(); - } - } - } -} diff --git a/src/Libraries/DockPanel_Src/DockSample/Customization/InertButton.cs b/src/Libraries/DockPanel_Src/DockSample/Customization/InertButton.cs deleted file mode 100644 index 6846fee140..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/Customization/InertButton.cs +++ /dev/null @@ -1,619 +0,0 @@ -using System; -using System.Drawing; -using System.Drawing.Imaging; -using System.Windows.Forms; -using System.ComponentModel; - -namespace DockSample.Customization -{ - internal class InertButton : Button - { - private enum RepeatClickStatus - { - Disabled, - Started, - Repeating, - Stopped - } - - private class RepeatClickEventArgs : EventArgs - { - private static RepeatClickEventArgs _empty; - - static RepeatClickEventArgs() - { - _empty = new RepeatClickEventArgs(); - } - - public new static RepeatClickEventArgs Empty - { - get { return _empty; } - } - } - - private IContainer components = new Container(); - private int m_borderWidth = 1; - private bool m_mouseOver = false; - private bool m_mouseCapture = false; - private bool m_isPopup = false; - private Image m_imageEnabled = null; - private Image m_imageDisabled = null; - private int m_imageIndexEnabled = -1; - private int m_imageIndexDisabled = -1; - private bool m_monochrom = true; - private ToolTip m_toolTip = null; - private string m_toolTipText = ""; - private Color m_borderColor = Color.Empty; - - public InertButton() - { - InternalConstruct(null, null); - } - - public InertButton(Image imageEnabled) - { - InternalConstruct(imageEnabled, null); - } - - public InertButton(Image imageEnabled, Image imageDisabled) - { - InternalConstruct(imageEnabled, imageDisabled); - } - - private void InternalConstruct(Image imageEnabled, Image imageDisabled) - { - // Remember parameters - ImageEnabled = imageEnabled; - ImageDisabled = imageDisabled; - - // Prevent drawing flicker by blitting from memory in WM_PAINT - SetStyle(ControlStyles.ResizeRedraw, true); - SetStyle(ControlStyles.UserPaint, true); - SetStyle(ControlStyles.AllPaintingInWmPaint, true); - - // Prevent base class from trying to generate double click events and - // so testing clicks against the double click time and rectangle. Getting - // rid of this allows the user to press then release button very quickly. - //SetStyle(ControlStyles.StandardDoubleClick, false); - - // Should not be allowed to select this control - SetStyle(ControlStyles.Selectable, false); - - m_timer = new Timer(); - m_timer.Enabled = false; - m_timer.Tick += new EventHandler(Timer_Tick); - } - - protected override void Dispose(bool disposing) - { - if (disposing) - { - if (components != null) - components.Dispose(); - } - base.Dispose(disposing); - } - - public Color BorderColor - { - get { return m_borderColor; } - set - { - if (m_borderColor != value) - { - m_borderColor = value; - Invalidate(); - } - } - } - - private bool ShouldSerializeBorderColor() - { - return (m_borderColor != Color.Empty); - } - - public int BorderWidth - { - get { return m_borderWidth; } - - set - { - if (value < 1) - value = 1; - if (m_borderWidth != value) - { - m_borderWidth = value; - Invalidate(); - } - } - } - - public Image ImageEnabled - { - get - { - if (m_imageEnabled != null) - return m_imageEnabled; - - try - { - if (ImageList == null || ImageIndexEnabled == -1) - return null; - else - return ImageList.Images[m_imageIndexEnabled]; - } - catch - { - return null; - } - } - - set - { - if (m_imageEnabled != value) - { - m_imageEnabled = value; - Invalidate(); - } - } - } - - private bool ShouldSerializeImageEnabled() - { - return (m_imageEnabled != null); - } - - public Image ImageDisabled - { - get - { - if (m_imageDisabled != null) - return m_imageDisabled; - - try - { - if (ImageList == null || ImageIndexDisabled == -1) - return null; - else - return ImageList.Images[m_imageIndexDisabled]; - } - catch - { - return null; - } - } - - set - { - if (m_imageDisabled != value) - { - m_imageDisabled = value; - Invalidate(); - } - } - } - - public int ImageIndexEnabled - { - get { return m_imageIndexEnabled; } - set - { - if (m_imageIndexEnabled != value) - { - m_imageIndexEnabled = value; - Invalidate(); - } - } - } - - public int ImageIndexDisabled - { - get { return m_imageIndexDisabled; } - set - { - if (m_imageIndexDisabled != value) - { - m_imageIndexDisabled = value; - Invalidate(); - } - } - } - - public bool IsPopup - { - get { return m_isPopup; } - - set - { - if (m_isPopup != value) - { - m_isPopup = value; - Invalidate(); - } - } - } - - public bool Monochrome - { - get { return m_monochrom; } - set - { - if (value != m_monochrom) - { - m_monochrom = value; - Invalidate(); - } - } - } - - public bool RepeatClick - { - get { return (ClickStatus != RepeatClickStatus.Disabled); } - set { ClickStatus = RepeatClickStatus.Stopped; } - } - - private RepeatClickStatus m_clickStatus = RepeatClickStatus.Disabled; - private RepeatClickStatus ClickStatus - { - get { return m_clickStatus; } - set - { - if (m_clickStatus == value) - return; - - m_clickStatus = value; - if (ClickStatus == RepeatClickStatus.Started) - { - Timer.Interval = RepeatClickDelay; - Timer.Enabled = true; - } - else if (ClickStatus == RepeatClickStatus.Repeating) - Timer.Interval = RepeatClickInterval; - else - Timer.Enabled = false; - } - } - - private int m_repeatClickDelay = 500; - public int RepeatClickDelay - { - get { return m_repeatClickDelay; } - set { m_repeatClickDelay = value; } - } - - private int m_repeatClickInterval = 100; - public int RepeatClickInterval - { - get { return m_repeatClickInterval; } - set { m_repeatClickInterval = value; } - } - - private Timer m_timer; - private Timer Timer - { - get { return m_timer; } - } - - public string ToolTipText - { - get { return m_toolTipText; } - set - { - if (m_toolTipText != value) - { - if (m_toolTip == null) - m_toolTip = new ToolTip(this.components); - m_toolTipText = value; - m_toolTip.SetToolTip(this, value); - } - } - } - - private void Timer_Tick(object sender, EventArgs e) - { - if (m_mouseCapture && m_mouseOver) - OnClick(RepeatClickEventArgs.Empty); - if (ClickStatus == RepeatClickStatus.Started) - ClickStatus = RepeatClickStatus.Repeating; - } - - /// - protected override void OnMouseDown(MouseEventArgs e) - { - base.OnMouseDown(e); - - if (e.Button != MouseButtons.Left) - return; - - if (m_mouseCapture == false || m_mouseOver == false) - { - m_mouseCapture = true; - m_mouseOver = true; - - //Redraw to show button state - Invalidate(); - } - - if (RepeatClick) - { - OnClick(RepeatClickEventArgs.Empty); - ClickStatus = RepeatClickStatus.Started; - } - } - - /// - protected override void OnClick(EventArgs e) - { - if (RepeatClick && !(e is RepeatClickEventArgs)) - return; - - base.OnClick (e); - } - - /// - protected override void OnMouseUp(MouseEventArgs e) - { - base.OnMouseUp(e); - - if (e.Button != MouseButtons.Left) - return; - - if (m_mouseOver == true || m_mouseCapture == true) - { - m_mouseOver = false; - m_mouseCapture = false; - - // Redraw to show button state - Invalidate(); - } - - if (RepeatClick) - ClickStatus = RepeatClickStatus.Stopped; - } - - /// - protected override void OnMouseMove(MouseEventArgs e) - { - base.OnMouseMove(e); - - // Is mouse point inside our client rectangle - bool over = this.ClientRectangle.Contains(new Point(e.X, e.Y)); - - // If entering the button area or leaving the button area... - if (over != m_mouseOver) - { - // Update state - m_mouseOver = over; - - // Redraw to show button state - Invalidate(); - } - } - - /// - protected override void OnMouseEnter(EventArgs e) - { - // Update state to reflect mouse over the button area - if (!m_mouseOver) - { - m_mouseOver = true; - - // Redraw to show button state - Invalidate(); - } - - base.OnMouseEnter(e); - } - - /// - protected override void OnMouseLeave(EventArgs e) - { - // Update state to reflect mouse not over the button area - if (m_mouseOver) - { - m_mouseOver = false; - - // Redraw to show button state - Invalidate(); - } - - base.OnMouseLeave(e); - } - - /// - protected override void OnPaint(PaintEventArgs e) - { - base.OnPaint(e); - DrawBackground(e.Graphics); - DrawImage(e.Graphics); - DrawText(e.Graphics); - DrawBorder(e.Graphics); - } - - private void DrawBackground(Graphics g) - { - using (SolidBrush brush = new SolidBrush(BackColor)) - { - g.FillRectangle(brush, ClientRectangle); - } - } - - private void DrawImage(Graphics g) - { - Image image = this.Enabled ? ImageEnabled : ((ImageDisabled != null) ? ImageDisabled : ImageEnabled); - ImageAttributes imageAttr = null; - - if (null == image) - return; - - if (m_monochrom) - { - imageAttr = new ImageAttributes(); - - // transform the monochrom image - // white -> BackColor - // black -> ForeColor - ColorMap[] colorMap = new ColorMap[2]; - colorMap[0] = new ColorMap(); - colorMap[0].OldColor = Color.White; - colorMap[0].NewColor = this.BackColor; - colorMap[1] = new ColorMap(); - colorMap[1].OldColor = Color.Black; - colorMap[1].NewColor = this.ForeColor; - imageAttr.SetRemapTable(colorMap); - } - - Rectangle rect = new Rectangle(0, 0, image.Width, image.Height); - - if ((!Enabled) && (null == ImageDisabled)) - { - using (Bitmap bitmapMono = new Bitmap(image, ClientRectangle.Size)) - { - if (imageAttr != null) - { - using (Graphics gMono = Graphics.FromImage(bitmapMono)) - { - gMono.DrawImage(image, new Point[3] { new Point(0, 0), new Point(image.Width - 1, 0), new Point(0, image.Height - 1) }, rect, GraphicsUnit.Pixel, imageAttr); - } - } - ControlPaint.DrawImageDisabled(g, bitmapMono, 0, 0, this.BackColor); - } - } - else - { - // Three points provided are upper-left, upper-right and - // lower-left of the destination parallelogram. - Point[] pts = new Point[3]; - pts[0].X = (Enabled && m_mouseOver && m_mouseCapture) ? 1 : 0; - pts[0].Y = (Enabled && m_mouseOver && m_mouseCapture) ? 1 : 0; - pts[1].X = pts[0].X + ClientRectangle.Width; - pts[1].Y = pts[0].Y; - pts[2].X = pts[0].X; - pts[2].Y = pts[1].Y + ClientRectangle.Height; - - if (imageAttr == null) - g.DrawImage(image, pts, rect, GraphicsUnit.Pixel); - else - g.DrawImage(image, pts, rect, GraphicsUnit.Pixel, imageAttr); - } - } - - private void DrawText(Graphics g) - { - if (Text == string.Empty) - return; - - Rectangle rect = ClientRectangle; - - rect.X += BorderWidth; - rect.Y += BorderWidth; - rect.Width -= 2 * BorderWidth; - rect.Height -= 2 * BorderWidth; - - StringFormat stringFormat = new StringFormat(); - - if (TextAlign == ContentAlignment.TopLeft) - { - stringFormat.Alignment = StringAlignment.Near; - stringFormat.LineAlignment = StringAlignment.Near; - } - else if (TextAlign == ContentAlignment.TopCenter) - { - stringFormat.Alignment = StringAlignment.Center; - stringFormat.LineAlignment = StringAlignment.Near; - } - else if (TextAlign == ContentAlignment.TopRight) - { - stringFormat.Alignment = StringAlignment.Far; - stringFormat.LineAlignment = StringAlignment.Near; - } - else if (TextAlign == ContentAlignment.MiddleLeft) - { - stringFormat.Alignment = StringAlignment.Near; - stringFormat.LineAlignment = StringAlignment.Center; - } - else if (TextAlign == ContentAlignment.MiddleCenter) - { - stringFormat.Alignment = StringAlignment.Center; - stringFormat.LineAlignment = StringAlignment.Center; - } - else if (TextAlign == ContentAlignment.MiddleRight) - { - stringFormat.Alignment = StringAlignment.Far; - stringFormat.LineAlignment = StringAlignment.Center; - } - else if (TextAlign == ContentAlignment.BottomLeft) - { - stringFormat.Alignment = StringAlignment.Near; - stringFormat.LineAlignment = StringAlignment.Far; - } - else if (TextAlign == ContentAlignment.BottomCenter) - { - stringFormat.Alignment = StringAlignment.Center; - stringFormat.LineAlignment = StringAlignment.Far; - } - else if (TextAlign == ContentAlignment.BottomRight) - { - stringFormat.Alignment = StringAlignment.Far; - stringFormat.LineAlignment = StringAlignment.Far; - } - - using (Brush brush = new SolidBrush(ForeColor)) - { - g.DrawString(Text, Font, brush, rect, stringFormat); - } - } - - private void DrawBorder(Graphics g) - { - ButtonBorderStyle bs; - - // Decide on the type of border to draw around image - if (!this.Enabled) - bs = IsPopup ? ButtonBorderStyle.Outset : ButtonBorderStyle.Solid; - else if (m_mouseOver && m_mouseCapture) - bs = ButtonBorderStyle.Inset; - else if (IsPopup || m_mouseOver) - bs = ButtonBorderStyle.Outset; - else - bs = ButtonBorderStyle.Solid; - - Color colorLeftTop; - Color colorRightBottom; - if (bs == ButtonBorderStyle.Solid) - { - colorLeftTop = this.BackColor; - colorRightBottom = this.BackColor; - } - else if (bs == ButtonBorderStyle.Outset) - { - colorLeftTop = m_borderColor.IsEmpty ? this.BackColor : m_borderColor; - colorRightBottom = this.BackColor; - } - else - { - colorLeftTop = this.BackColor; - colorRightBottom = m_borderColor.IsEmpty ? this.BackColor : m_borderColor; - } - ControlPaint.DrawBorder(g, this.ClientRectangle, - colorLeftTop, m_borderWidth, bs, - colorLeftTop, m_borderWidth, bs, - colorRightBottom, m_borderWidth, bs, - colorRightBottom, m_borderWidth, bs); - } - - /// - protected override void OnEnabledChanged(EventArgs e) - { - base.OnEnabledChanged(e); - if (Enabled == false) - { - m_mouseOver = false; - m_mouseCapture = false; - if (RepeatClick && ClickStatus != RepeatClickStatus.Stopped) - ClickStatus = RepeatClickStatus.Stopped; - } - Invalidate(); - } - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/Customization/Resources.Designer.cs b/src/Libraries/DockPanel_Src/DockSample/Customization/Resources.Designer.cs deleted file mode 100644 index 2e92d03e42..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/Customization/Resources.Designer.cs +++ /dev/null @@ -1,133 +0,0 @@ -//------------------------------------------------------------------------------ -// -// This code was generated by a tool. -// Runtime Version:2.0.50727.42 -// -// Changes to this file may cause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -namespace DockSample.Customization { - using System; - - - /// - /// A strongly-typed resource class, for looking up localized strings, etc. - /// - // This class was auto-generated by the StronglyTypedResourceBuilder - // class via a tool like ResGen or Visual Studio. - // To add or remove a member, edit your .ResX file then rerun ResGen - // with the /str option, or rebuild your VS project. - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "2.0.0.0")] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] - internal class Resources { - - private static global::System.Resources.ResourceManager resourceMan; - - private static global::System.Globalization.CultureInfo resourceCulture; - - [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] - internal Resources() { - } - - /// - /// Returns the cached ResourceManager instance used by this class. - /// - [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] - internal static global::System.Resources.ResourceManager ResourceManager { - get { - if (object.ReferenceEquals(resourceMan, null)) { - global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("DockSample.Customization.Resources", typeof(Resources).Assembly); - resourceMan = temp; - } - return resourceMan; - } - } - - /// - /// Overrides the current thread's CurrentUICulture property for all - /// resource lookups using this strongly typed resource class. - /// - [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] - internal static global::System.Globalization.CultureInfo Culture { - get { - return resourceCulture; - } - set { - resourceCulture = value; - } - } - - internal static System.Drawing.Bitmap DockPaneCaption_AutoHideNo { - get { - object obj = ResourceManager.GetObject("DockPaneCaption_AutoHideNo", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockPaneCaption_AutoHideYes { - get { - object obj = ResourceManager.GetObject("DockPaneCaption_AutoHideYes", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockPaneCaption_CloseDisabled { - get { - object obj = ResourceManager.GetObject("DockPaneCaption_CloseDisabled", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockPaneCaption_CloseEnabled { - get { - object obj = ResourceManager.GetObject("DockPaneCaption_CloseEnabled", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockPaneStrip_CloseDisabled { - get { - object obj = ResourceManager.GetObject("DockPaneStrip_CloseDisabled", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockPaneStrip_CloseEnabled { - get { - object obj = ResourceManager.GetObject("DockPaneStrip_CloseEnabled", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockPaneStrip_ScrollLeftDisabled { - get { - object obj = ResourceManager.GetObject("DockPaneStrip_ScrollLeftDisabled", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockPaneStrip_ScrollLeftEnabled { - get { - object obj = ResourceManager.GetObject("DockPaneStrip_ScrollLeftEnabled", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockPaneStrip_ScrollRightDisabled { - get { - object obj = ResourceManager.GetObject("DockPaneStrip_ScrollRightDisabled", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockPaneStrip_ScrollRightEnabled { - get { - object obj = ResourceManager.GetObject("DockPaneStrip_ScrollRightEnabled", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - } -} diff --git a/src/Libraries/DockPanel_Src/DockSample/Customization/Resources.resx b/src/Libraries/DockPanel_Src/DockSample/Customization/Resources.resx deleted file mode 100644 index 37c6946b13..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/Customization/Resources.resx +++ /dev/null @@ -1,151 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - - Resources\DockPaneCaption_AutoHideNo.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockPaneCaption_AutoHideYes.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockPaneCaption_CloseDisabled.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockPaneCaption_CloseEnabled.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockPaneStrip_CloseDisabled.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockPaneStrip_CloseEnabled.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockPaneStrip_ScrollLeftDisabled.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockPaneStrip_ScrollLeftEnabled.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockPaneStrip_ScrollRightDisabled.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockPaneStrip_ScrollRightEnabled.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PaneDiamond.bmp b/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PaneDiamond.bmp deleted file mode 100644 index 70e70e288d70741ca264944ab528dd070fae23f0..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 23286 zcmeI4ZEqFF6@baV=ugNm$d^`0Nfjg_I}T|YP?DxikV6WDmJl$QhCmZAZAhXB0Zj@8 zfk?rhT9ts>VCf>TWyh}X#m1O7`QmF+5NX0ol;lGq(P!rD9uNC+*}HeI#9e1K9?dFG_ z*Ec*oeD2)2%a<=tXK|pjp*A-{xy#|wrAyE_llD-O&CX$LY^+cyP>Xa2c|k#gB6}ll zSwnSVv-XRRe!5`y+^13pRMC|3!C`XXNJQwrTNwChvp_HZ9H?oy?srRa#$jskSj7fS z@RRh^kcqvte~rEJs5v`$EN2|1hd;ey!tpD`Pp1jPCLl3!(FE@TO>m{XAZHw|juftr zoG|eyiNZDW(+2x<=BzK53$Bfv$Qg(0XZx;?_j=)M?{zmI=d5=D347KEjXY-@zPK>> z#YI0j>Hl3AG(k?OoP?jw8HXF?k_i(<6C_9=U|?iqghjbX4&f?CN^-z~#xOoUUM`paQgtMZ ztiB3!zySyo6BCt6g}P|HYE3jX2WEf@fpx{KI5gK1WdMS3xVE?R>Yk1(yH`(t_*!M> zip$%VO}zi|#dlshzx9{nZ$CS>@fRa+JbAjaRpQ|_^Z)buV}q~#?6cp^b=w1~IMCnF z73NHohaq4&b@{%qkMLd3o^Sv4;n$yRzy0@jZ*+HkesJT}zpk75^Q!X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eL4@F^xm&RIzyU4m z%-4`OQGoq@J`jE@3Au6hGfEgDB|^bCU_i%lTp0_pxKMJ<*R=GO1`5U@m;c`^!1#b= zvw7oY>v9nD@t!SNtj4j{*w}Z{#Vq960HQlx@2T(L`K2`&6 Oi*i8i+^>Zj3cdw(sg<(; diff --git a/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PaneDiamond_Hotspot.bmp b/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PaneDiamond_Hotspot.bmp deleted file mode 100644 index e801d382d77400616c5ba7c40646e5a387b0c992..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 23286 zcmeI3J#K?Q5Joq*$Psda93XxAD5uG#(nm4{9VHC{|D7SN^Vv(#CtA-)Sb8Ijur1Gy zp5IJi)^G2>pXC;>I=|@gF+ZNl^X>JY`Tg6I`E<#N@0`dfHZiL(TuO;Ot~nnq;84FY zIKaVs7a#BeADjR_I1T0lKH!5Bzz3(ne82~Ma02+?G?)+gfDcXpADjmB0Uz+e3Ful) z(f57qkM_!TKA*4c_8?IqjN_QW;Zaa55RS)V5{K=ha0se4kHeNxtRQ4_*d_`=7=~e* zCbfeqtdZ(NT|( z!T}E6SNMPr_}~Qa!D%ob@Bts306sVk<^w+9gA>39r@?%{2Yhe>_~0~{5BPu&P5>XA z2J-1+PLZMj^&O!StwAG}}gg}#%QdKK7 zF2XrztBH2qD1TDr;b~Q>BAi1_8(wW{!Xyri03VzN^8p|5!3p4l(_lW}!^#IK5gxuo?DZdhY962f diff --git a/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PaneDiamond_HotspotIndex.bmp b/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PaneDiamond_HotspotIndex.bmp deleted file mode 100644 index e5ef472c56cb9258fdaa5b45bf9df1d5adbcd38c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 90 tcmZ?rjbeZRGa#h_#LQ64$RGihPyv&u#D5@QU;q<93MkhAk%tL`gaEYn5c~iD diff --git a/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PaneDiamond_Left.bmp b/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PaneDiamond_Left.bmp deleted file mode 100644 index 1fbda61c089c95635644e4f5d01905477db17842..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 23286 zcmeI4?Qc~@8o=?t@K5kB@QX$ljU0zJhW0!*1gKW}b7N4(H|e+;h*>-UBDo$=v6hnR(_n zuV{&Ae-^yx`rpKRoZ(#$2B^=4yIDPswG`>!IDamH%Fg7+;C=@6~x{J7=pg|G6F_qT9RMA=c z#XEnvbNl?eQah5ODdmI1`{aIeckn>YI7|a0!is7^AouVi!%}lmrGYU7!f~k3O;B3;wlGT6?xC9!hssEe)me~7eEjfhvG`;7kk@UyW3j2jc;5eihOV=7Kzw*G?x_d@myyIwRtN6puE&S@)+XkPx^~=A`ciRI=aglzljq105 zJ`4fPDa-!~J8}Q*+3}yx-u~s&t(QJ}{m1UEZ+EXd_wMsk|6Ez#y6p6p_TycP#2qJ6edV`}P(?6QGEMfZn_R)`{D-Y4v*>R&9T2#kLoo+S>7#H&(X4y8O=@ zpL}Rt`+aL3y{qG)Kd!v*cJY_ry;5$bNlT#!a?mg%7MU~Z5444T;;P3&p{NZ z#5#c~lG!2K!d6c$OBD0w{hEctm^(Q+IW;v^UGvQEf+CX(2x@@K$}k-$EXmTxBh9?X z16JTjNrMzqJt66G2&fdPc@m*JvQdOmsnpZc6IpA>dwYA`yO9!7a8XnNn?yZ*M)eGE zsM9d5C3R;y^6L3u*Y35QjQp0k?h{IJ|Nky94{i7b{=0%ZdvWC;SuLG<|gb;H5PJ;jN|ZL|31P z$f>32Y-BEz!Bvo7xmd^W{XvS5{TrGu;Agx!U=}k1N*&f zeY-jkmZWCJ$z!%XBV{Ie0f;oYDbQ2 z4*>;4E6Gv%g&iMQS0AEsz42in>G)vBNq=4K_Y2gMT&nme;HoWUNdZBkkWnDP@c0m^ zj6|pUXw2sQLi&YrNIXu$!K|z0{lb6Gl0rr1tHOZV5(Pg63XSW6O~^rVH0vmtFUHM# zRt^2a&YN^1mR@$guYS~K6Chkz(6FPCH43EDoLIu)@ZrOlazH_=;6Dx1U7UX5 z6p(xDLG)~>4+M^ykSSTCKswEdr5r#(tAIv57bN8@kQ{?)C;@2+0)b4)x*pAi151cH z9qB;w$dM!c{rzDSb()`Ox2`cu@M=pS>rAc`6InP4nglqw9fX3^V}5e2V_^tkWqw~t z0EOEs7%J;=q^#C4w>u#JeTy8IyNg0QNQUPIIaJ_whd4Fnf?QEBRxoyDdybUz6;P$e z&DoaVR)L_9xtQJ&cdpotQYB1>B0=dFjFzkungW892vxb5$e5ZLBr`l$OtMv=&B0r< za$qx!eMR;*)x~YEk(9KDrh`De%*ugh*j)8pOV|)2mFxD4ymFwVI-g3Z!~PY*K~RK? zuaYZ=gBCe5aFv5#xym7z9N0CbX4Cn3nm1+lIEA0Heu144Qv$o_#;=UwV{t=h|-j=83zt2VOPRoRgr+_my04X-#{=QK(NmFJVMSmU=%aX`M`wVg~mNk6G*)QiH@xPYiJ>dN` zcXQSrIG|;n`5F=@3b4P=1pIF$Avex`MhQctJdiUE7|?MXSH^-Y&X-*FH7&iRft+#3 zsy{T7|wg=g=uG4(%nr@qy W11Rb@AFBbkNjac)=2zoJg8u`JR+iHM diff --git a/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PaneDiamond_Right.bmp b/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PaneDiamond_Right.bmp deleted file mode 100644 index 1de97a098639b0bb45e11c38ba76ebd8e103e8cf..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 23286 zcmeI4Yi||R8i4U%_!ImEe$l9CB*C<&-Zkp+Mk*?ZB4V*9!ciz5@thc2_o7kM^N@5$nq)3{;dkQl#coEJd@#IzA|#^KaR;nc`J=e%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raries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PaneDiamond_Top.bmp b/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PaneDiamond_Top.bmp deleted file mode 100644 index 95122a0f31b83e03b34977ac7fdea926907d9a83..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 23286 zcmeI4?Q<2?8Nk#3qJKjFf_`a7iyfK4NgB0Q9ktfVM64h!A_hZ6s6uGPb~=nwEmTGZ z3;EPe5vG;QTn3U!Ow7F`hVVAIF`A zo|u?8bLPy&ix(I2xX81G8n-5Em&1h%7ohQR)=NpYJBR7%=~AggEwWvt1qBU?5BPjo&C9ZHmCKR%CgXL+1c4ztwvq6UX2FYngcVPLSSDpFAnXsMHzu09Im|6cX@B`r9B%K-g>U~ z=Gu$9R?q(Gsq?Qrd3MM5XI_0|ddv4FU%K~HUzhk3FRb|J`MbxS`}T)FS?0C}vf?8D zMjO@tKfVtE&8f?OOZ#yD8QlBtKfm?Q_jg_Y!|R_7^#Aq1mdn3;asD^!tGm`**x7TY z|8eoBfA;Xy<_9W$-4nf?q}6?Ui=hor#6m#t13&M>?ccufomV#Od3oLLpFX>*_eZ~6 z-}8&LKiu}rV_SM2+VsTzy^noo{X_SNzxILUYwo@4>8?9_?)fGh)Q+PZ2rSuFkp#h2 zKHu;XM1e}I6PO~I9rCSg{oHayK~}k37<1?5=H}<;>ua9--CUHHOw<6Emti_mS+b>% z$C`PON36iHk`^hZdPX=zREpI+jnEz0s6wSu85|speQ?N!hKAg`u@Z7{QPcsOMm>$A zdPX=jX_(fUx-%VR4ZgSkz~(+ie%I~a)ccqH`wkvFIPm(8H=bR^E&M|}cOb!cB>hN$ zLq7WW2sdLu_w|f$XwopP)g)V(i`vHre*fX0{`mJ#E=3kINRS_TZM)tT$${-#Ba%Zq z``rx5Rtst}pxOEy#43$p5wjZRBrGY|9oRR%R{NM;R$Qby{!et%{L%Tnmp2K7H&^$N zTzwKE=egt4HAsS=Bylqo4t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9e!i9AwM7N%OI5 bx@}($plIHFtOndRAe1M3Ss(A#J zSb@8oUU^0+~+#2UDs_Vo=6tmGS@k%nXQrYkOrA%bj#dkgly(N;QIakcs!0zDb6B$ z#y?5QyoXRIluRZmw=`)kPM8*LBZcwdg$IWB*5ldxhtszQQ#bYrqk9vU-TcL#s98&W z_{`4G=^cUL?Qc$Yfa`L(>b}Q3&!P=;{IuPepF?#=asU7T diff --git a/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PanelBottom_Active.bmp b/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PanelBottom_Active.bmp deleted file mode 100644 index 212fb0d366643c01ddb73ad88d5caac25db236fc..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2782 zcmds(+iTNc7{=qRe}OmRt$%@6f^1^JvDz^v6PcouiicTrbyn-Cc$#M~3hJP9f(*1* zUO0zrg{(BCwWl;a#I82gwWXyxHWcwfp*~-d)^?4HjTOO{Cok{!yx;pvQYiU4^}Rh4TfP{ zS_88nC~zGey?-J+4_;K6``-UTLB2+F#Znx>1GUb@WHYPLQQ_tS(+i?%1(v9DL6YUV zx<}mkl5_*pD%^Z{ra&}Xh|J`nFcBP*BSi9sT7jM71{H3Rql?@e$uSgki7Z8l%b(q< zFKsAsb1K|&(p%;kSxKf`FZk%n8&HT{ViI44yEq?MOjlJ`f1D2xNv)cXqFSqPm$EF8 z5FwK4EW0egVVB7gKB*-UN2;^zKjMDQ^SHCNyxRYwqBT^02d&tOb}lAYxvNGl#w7g; zt%du{pm!R&og@<}qFd&=26eM_avjjYX-2oqZAK_M{{h$U_s8RLd`j^yitqS4ro!(K z3Wbu%q{J;vSc~J9f@35EaK2X``C)cNCrvl08U=pYW$i_uN)Iih&^%686 z=xm5$pqV5gpe~?ZV$3JWSY*XSnh)_ZvPNRqKwU(dPmF0;)evbuBr36*fJYFhi%9eF z7=mAlNb`rf`$y9cp7IBn2Jj~mJhCGs{m`NOgjfMdsF3W2i-f3ws3$V~fy&4RKxg2u zzn;!1eKND?`P_0Kg0LS=%X=_6`(A(A?e3(T9kJJ2qOLZCUaAeaSmg^L&y{(eEpa_v zMK}_b2Dv=}EoO9tR<> zHbq>n3%O9`f3DmIXg;vzgD3qj?W_W##cdTpG{3oYPJQ9@n%v3dnSI5nU3rPESuqW% z;nfL2!q8_N1 zp!q;&LlgteBnbg^0re7NK1s$RD<;x>h?kKy62k`SBGP%Nb@04iPZ!=f(9UL+iMm7LC z1AqPXbWZ7$nMKd%mID!l{b*X=gUQ+V`qOTAC*ACbz1|XawITFUZNSAUUkG`w%=2uC z>**rrQw5F$&Huf3?)RND{~TBVL=g7Zt&=}(=zYJc{q@p@=kqEb&nUh>IpW%g| z2zj+B;&NTcg)0AZ3?Zw6%Z|Ms{o?;&82hd3#ZrQPA<>vD^BgoOKi=G zX-EyPP6#TG@hcAZf{=M3ZaD!?8NT+ZUN%7UZ``PoPCKLcsPd0CV;=cmMzZ diff --git a/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PanelLeft.bmp b/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PanelLeft.bmp deleted file mode 100644 index 551fd88624747761b970c653d7449ec33dbddc13..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2838 zcmZ?r72{?A12Z700mSk^EDOYp3=%++f#Crcm_i}8(h>k|0vdnf#EHw7FW`yRCc zn)yI0u3o(gw2MLjGz8*WH1mPtM~@!eOECZ%0yGL37-;6taSWmg0y+>F0$9y|cybF6 zJwCnt>ABr6E**Sz?bzGfr{CYd@bS@=&rhxc(SJe!=t3gRe}3t}t7}I==HI*U=^@B` zpk6}8|0l-$N2j+vJ-6ot(ERI1-`)b5{}F6HwcP&*96nI@-#Y!_K2_a+VhhmxC+Bt} zhtJ1HSE(5OAorgKn|~b~zj(ucZ;~5wq!0-I6NvN!az8BmKjBC}tNeZUCX-@5EPaB* z2bMm8@e4K|E&TwwK=b#ImuYzYodo zKe6TU8F2c!49Z_X^Fiq!NBFNKHGI(G7o2}T0MidP_d}8mY3TKr|6z&4-Vm_6^|LL64Co_wl&n<_L5bmRCc@HLM-|J7i-JNu^Bldbr)YXR2OSJ(P zt9&8kxiZhQC9bE7oKF=v;t&7dd*^=NIrGnf1rQR#{knDXrwzUDSGB)h+VFf{<>MK} z_b2Dv=}EoO9tR<>Hbq>n3%O9`f3DmIXg;3$cWGx85G`)2fROW>OXt)VPOr(GT%Ori zoZ6L_*qRm7kQ!c{5L6!HR~+sIA@f4qasr$(eC<=cY=GvYwI7ZhJ9hEn#p~Cv0~;08 s1(5c`kt0XWoH+xug2HAGrgn(=2M!znS^@M0upviX05P9-El{BO02Xyfj{pDw diff --git a/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PanelLeft_Active.bmp b/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PanelLeft_Active.bmp deleted file mode 100644 index 5182318ed3d451f969799e09333f85e60ede5ad8..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2838 zcmZ?r72{?A12Z700mSk^EDOYp3=%++f#Crcm_i}`GceE&0c`>re&WQ5%a1 zwE>#>Kr60Zy$ZC8LI5-b;#xHGf#OGx9^FeZ02%@`3K$q@=Ff2qq6z{!5Euej&3|}u z3lKd%z5VIA-7hX3e0A;E+uNt#-@owj(Us3nt^?73LICJOBF%q(>A>?#=LOLG>qp<-0-662Y(BNz{|FpDQ1{W(EKOo zb|Z(+$46JG82%vlp9h%m^^aFA~Ec`#=NI$FmefK7lVm>T= zg2M-vK7sKIHXkkh0J%W(_mJd%u=$AaxpwRgDE*(uO#eW`$u=L9zo6lN^bI8a;B>za z$?iX~tEhk_~C;2NwP)=^vQCaJU~i zWkT4%NFiAMK=K!;e1Mccu<{M47t=sA5n|1U#4pf%VEDtz2Wpi+(DVb0Uts_F-&$A`2r;D6V6*%G#|KEG(e&0Fs&w&LH62kqub@HbTz3*4Gzh2t#d|u__ z8O8S}=iKQ@z0n>AA+I(?T&@ebQ00HF+y`hrp89ubXB7}FZmWQh^P5ZO)E7>#$(>xD z*;ky}m6zC>71NL!UY!tB9^+RW?gb(9Lfmo!oHBgvQ@w0}=A*SAjvYI8@#4kn*RKN` s71RZg_QR1QN6wr%1GIv|W)G%zi1`N&8~|DY^aZdXM_m9hpQi0k0Kv25U;qFB diff --git a/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PanelRight.bmp b/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PanelRight.bmp deleted file mode 100644 index 003cbb02a6df99653e66cf887fff26d684f97f09..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2838 zcmZ?r72{?A12Z700mSk^EDOYp3=%++f#Crcm_i}8(h>k|0vdnf#EHw7FW`yRCc zn)yI0fZ*!Yt3c~00YDRg<^UawWA;h7yC0w4{_x}$AOgCO67zxDf#!dLn1B29 ztLsOfUpn~o-0nwIG9Tgod*|Om%|Gz;+#YI~4{`s;hgaUi&A)u$>3OP!55)bSfaXKP z9~eFdo}4EqeD)@}Va7Jp{qXR=cJu`}e#r=*JxOjW{e97_fVv;ad`S8s&-_*XK0pT} zTLDi$AMRZM#qTvx_yE%nG<}{RA$bIN<{zYD`G812 zK=Xm&4+$T#;ukGsAY5qr0p(wC`ngVi_+T|37XDYE=7ZBGFnmDaPh$GPYChckACSri z>X)C8@BxQEuzUcQpWBEj|DVn&eKND?`P^~{3E@7PmiJ(C_PzeJ+ucbwJ7TZ5L|ttN zy;K`;vC0=ho-6Y_TjF}U$oW)(BhZ6*>X+Yp=YHQg^Ur|=5E8=ux^?oW4ZZJIwZC54 z@O)n7;~B;GC+FPhNxjh?2O+OEMO>~6xlrYQt{haJ;HiI?c2)t=;$$Wa$S%%@!o6lgvGL|{nP diff --git a/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PanelRight_Active.bmp b/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PanelRight_Active.bmp deleted file mode 100644 index dad423551dc270a8fc196ced8f72bf9c9e01ecac..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2838 zcmZ?r72{?A12Z700mSk^EDOYp3=%++f#Crcm_i}`GceE&0d3m4b?b=}CoW&UeEat8 zdsGELXQP=9v;qjOUcCymjuHSg0cZ}U`9Sdt7cLw+bZ9SS;ONn#K%+3tpW_%r6$Er0 z(EC`;|4#^fesUd%K0dng{{Drxw@$yhcI^4315eKFetdfS!;@Qp2EP3IyB|@>e1!Y&oqr28|G?98d#GhT#Qh&1UU?5U|MG#S=cyJx5chuq znhyV72iA?b%a^H=%% z03D2M1w8$HxOV{*zt=$F157{A^m&4W^a*tTDt}*~fyh=MrJoCLKdNHkd1Kv{qt`?;RDLQ!1PH*_!CG!(C`PEe~^mh z10wwZ%?E}*Bz(w4re>$i1$;_hXbITzlg!^b(-h;{6_xjUrcPHKKh`rtt zb+sY%Qfcy!1f^k Dd#2bL diff --git a/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PanelTop.bmp b/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockIndicator_PanelTop.bmp deleted file mode 100644 index f6293fd2bc2b474bdb32322ee92ba986f7fa0233..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2870 zcmZ?rHREOg12Z700mQOEtN_G}3=%*R2%z#14uqV!Vht@2!`7`^PnfA?H~^T^+FtnZZ1&b=+UEl$pt{YKofv|MmKkkV-O_>=pLX)v77s! zTmW>?sJXzvBRL%QCb{iRcH5JLKtK`9SRmP4pb@M5ePPIFrN1wxq2#z1VhTL{VKtO| zb0Io$8A_44cnlqW=6-&19T-LAk@)g4&_wbOf%NFttPCzrz})xuFTB48LLXoZ2>1Q{^AM2_Kv|#^1l>FT9*Dqf0_MKGeHw&rff1a2 z`}7+ix&=Z|1rRk51z!l6P=T$zQQG9=L&Yhmr8|`rr@@iAW<+_jyRsQG7eSqfTtml_@RsqrCwu<@9 zrE}^Fr`P08F3;>MPVLG|Y|V;kNDZ$}2r7^9D-QR9ka;0)IRQ=?zV@kJHb8UH+a<@2 z9lLn(;`Qs-fvpv)0BF19$dMyw&YS@nO{89I?YNv{O`%R=bZb?okz%Rv$w1j zsI|av#8{890b`A@4j#tqY{LA!AOxR0Yp%c)Fk-P-Hk(ydHQyww=K?LuGQPu_VJ+KS zJr{*&G#a*QSPKHKxt<$p?OKhnA6)3-+dg%xvw z7gMkG;0KGsuxl$Gm9!pO!<@!(b$ChO^p*xQq^KL z{uP=e;ti~aHPG0ETbYn56VZwiC7uKljge%5k>^#~Ntz`SZaMR|lo87r5&kccBvF

|x4stI={`G#r?zKA$QraVZ|fKHJqqC~2^(}X)6e+6mrmm2XzMur9nR$VC7dQ7#DpB2ayPTOS?#GU6{iJU#uuQwa2Zy5;&XxQBW9;?C^(?s1Foe_ z$^ZG0>ptl5)lda;5~H5(wZ9nFKIIT3r__-t!i6jyUpsgLB8dq_yD2hO1*Ej$+#W)uqO_%To D=uj!( diff --git a/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockPaneCaption_AutoHideNo.bmp b/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockPaneCaption_AutoHideNo.bmp deleted file mode 100644 index e952891bd4e8e934126d208bef63bac9024854aa..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 114 zcmZ?rEn diff --git a/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockPaneCaption_CloseDisabled.bmp b/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockPaneCaption_CloseDisabled.bmp deleted file mode 100644 index 98fb0f8b004fe261133dbaa7a5fba0d64d3d2cfc..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 114 zcmZ?rEnQfe?S_D0fj#p#Q*>R diff --git a/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockPaneStrip_ScrollRightDisabled.bmp b/src/Libraries/DockPanel_Src/DockSample/Customization/Resources/DockPaneStrip_ScrollRightDisabled.bmp deleted file mode 100644 index 84470405376d7406d06de0b4356ee4a38d28369c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 114 zcmZ?rEn%o0i}h=gp!apgy7(mkQ5RJ2p|+efF>m( z3Qhc}RYRhdSh^^&Wn<&J*f`FceDT?7qVSp^-~&kTn|XF0kN4%gx3{PIHd&2FbI? zQ>RXyKYxBUi;FaysBv?Wb~&6ocMck#q`j16t8WahMrCT(wRE{3JXx zVtg;`KVzRfWbO_h&KZZ<(GM>ecjQ9p!&%&@aY&3`GR}KI13YOT$Qg%=W5tVOM~y#D zpm@prw9fvVyX(v4flFgYbH?HF$$`t0{hmA7f7x}&x$8YZz}_`NBhML!&(92he%5zR z__H&^#>p*}6Y#@1E;ItPOycO1T+o#f4? z^Yb*1N`SM|*EaTd(nri$swR4y97* z^y$-)?V|6IrAHjsw|ps*Fp3;-7#bQH8yjO&E|NpI$dQs9aG)|wPEJ-TmA}>O2_uWI z!W?h_!qn7MwOXYtTCREnt<9lOPzdZRX2pS|ek>H~CHa4Qem(@@aOvIdi@Uon>{>Vb z_LJ2&SD)Xpa_Y55&%XS~>21H8eBu6yO}`y`_Kp+X?c$FJ16)>y=|EvgmNp(~ z=0zT`0!K=kq?qa%;1EzLQu8E2w`ZdW<#M^NuP^e&A@A?+ckf0@NWn!>18frY^cmGN zz@b6Iw3gHz>By_^{k{7(cGL5_ZtsS!|L)zhfB*j8SGK+J#0qZVAK1PP3BDugK>{4o z(bq?~5d(Ty&j5!84bxgol7+dbeYE!RplS+qyX*Ik3IQ zO^{?YqXq+-Y?y;sr7PcxB?Y?!`^HzQpRmh{3lt~(6Wug@bbkN24FciKm7PRa zpNPnL@AxzgqTt6#+ysR~INyLov_)-{#~MOGu$o~#q-at`SI^oUh=@_iaF{Azoi-eZ z8^|vF(@kG>mg0+U;v*q$IKfCs3J#=0MpuQy*;-#^gdi1Lz)`s_2a#i~CEL~=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ause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -namespace DockSample.Customization { - using System; - - - ///

- /// A strongly-typed resource class, for looking up localized strings, etc. - /// - // This class was auto-generated by the StronglyTypedResourceBuilder - // class via a tool like ResGen or Visual Studio. - // To add or remove a member, edit your .ResX file then rerun ResGen - // with the /str option, or rebuild your VS project. - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "2.0.0.0")] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] - internal class Strings { - - private static global::System.Resources.ResourceManager resourceMan; - - private static global::System.Globalization.CultureInfo resourceCulture; - - [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] - internal Strings() { - } - - /// - /// Returns the cached ResourceManager instance used by this class. - /// - [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] - internal static global::System.Resources.ResourceManager ResourceManager { - get { - if (object.ReferenceEquals(resourceMan, null)) { - global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("DockSample.Customization.Strings", typeof(Strings).Assembly); - resourceMan = temp; - } - return resourceMan; - } - } - - /// - /// Overrides the current thread's CurrentUICulture property for all - /// resource lookups using this strongly typed resource class. - /// - [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] - internal static global::System.Globalization.CultureInfo Culture { - get { - return resourceCulture; - } - set { - resourceCulture = value; - } - } - - /// - /// Looks up a localized string similar to Auto Hide. - /// - internal static string DockPaneCaption_ToolTipAutoHide { - get { - return ResourceManager.GetString("DockPaneCaption_ToolTipAutoHide", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Close. - /// - internal static string DockPaneCaption_ToolTipClose { - get { - return ResourceManager.GetString("DockPaneCaption_ToolTipClose", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Close. - /// - internal static string DockPaneStrip_ToolTipClose { - get { - return ResourceManager.GetString("DockPaneStrip_ToolTipClose", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Scroll Left. - /// - internal static string DockPaneStrip_ToolTipScrollLeft { - get { - return ResourceManager.GetString("DockPaneStrip_ToolTipScrollLeft", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Scroll Right. - /// - internal static string DockPaneStrip_ToolTipScrollRight { - get { - return ResourceManager.GetString("DockPaneStrip_ToolTipScrollRight", resourceCulture); - } - } - } -} diff --git a/src/Libraries/DockPanel_Src/DockSample/Customization/Strings.resx b/src/Libraries/DockPanel_Src/DockSample/Customization/Strings.resx deleted file mode 100644 index 72b3d85bd7..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/Customization/Strings.resx +++ /dev/null @@ -1,135 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - Auto Hide - - - Close - - - Close - - - Scroll Left - - - Scroll Right - - \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/Customization/VS2003AutoHideStrip.cs b/src/Libraries/DockPanel_Src/DockSample/Customization/VS2003AutoHideStrip.cs deleted file mode 100644 index 14ce75286e..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/Customization/VS2003AutoHideStrip.cs +++ /dev/null @@ -1,507 +0,0 @@ -using System; -using System.Drawing; -using System.Windows.Forms; -using System.Drawing.Drawing2D; -using System.ComponentModel; -using WeifenLuo.WinFormsUI.Docking; - -namespace DockSample.Customization -{ - /// - internal class VS2003AutoHideStrip : AutoHideStripBase - { - private class TabVS2003 : Tab - { - internal TabVS2003(IDockContent content) - : base(content) - { - } - - private int m_tabX = 0; - protected internal int TabX - { - get { return m_tabX; } - set { m_tabX = value; } - } - - private int m_tabWidth = 0; - protected internal int TabWidth - { - get { return m_tabWidth; } - set { m_tabWidth = value; } - } - - } - - private const int _ImageHeight = 16; - private const int _ImageWidth = 16; - private const int _ImageGapTop = 2; - private const int _ImageGapLeft = 4; - private const int _ImageGapRight = 4; - private const int _ImageGapBottom = 2; - private const int _TextGapLeft = 4; - private const int _TextGapRight = 10; - private const int _TabGapTop = 3; - private const int _TabGapLeft = 2; - private const int _TabGapBetween = 10; - - private static Matrix _matrixIdentity; - private static DockState[] _dockStates; - - #region Customizable Properties - private static StringFormat _stringFormatTabHorizontal = null; - /// - protected virtual StringFormat StringFormatTabHorizontal - { - get - { - if (_stringFormatTabHorizontal == null) - { - _stringFormatTabHorizontal = new StringFormat(); - _stringFormatTabHorizontal.Alignment = StringAlignment.Near; - _stringFormatTabHorizontal.LineAlignment = StringAlignment.Center; - _stringFormatTabHorizontal.FormatFlags = StringFormatFlags.NoWrap; - } - return _stringFormatTabHorizontal; - } - } - - private static StringFormat _stringFormatTabVertical; - /// - protected virtual StringFormat StringFormatTabVertical - { - get - { - if (_stringFormatTabVertical == null) - { - _stringFormatTabVertical = new StringFormat(); - _stringFormatTabVertical.Alignment = StringAlignment.Near; - _stringFormatTabVertical.LineAlignment = StringAlignment.Center; - _stringFormatTabVertical.FormatFlags = StringFormatFlags.NoWrap | StringFormatFlags.DirectionVertical; - } - return _stringFormatTabVertical; - } - } - - /// - protected virtual int ImageHeight - { - get { return _ImageHeight; } - } - - /// - protected virtual int ImageWidth - { - get { return _ImageWidth; } - } - - /// - protected virtual int ImageGapTop - { - get { return _ImageGapTop; } - } - - /// - protected virtual int ImageGapLeft - { - get { return _ImageGapLeft; } - } - - /// - protected virtual int ImageGapRight - { - get { return _ImageGapRight; } - } - - /// - protected virtual int ImageGapBottom - { - get { return _ImageGapBottom; } - } - - /// - protected virtual int TextGapLeft - { - get { return _TextGapLeft; } - } - - /// - protected virtual int TextGapRight - { - get { return _TextGapRight; } - } - - /// - protected virtual int TabGapTop - { - get { return _TabGapTop; } - } - - /// - protected virtual int TabGapLeft - { - get { return _TabGapLeft; } - } - - /// - protected virtual int TabGapBetween - { - get { return _TabGapBetween; } - } - - /// - protected virtual Brush BrushTabBackground - { - get { return SystemBrushes.Control; } - } - - /// - protected virtual Pen PenTabBorder - { - get { return SystemPens.GrayText; } - } - - /// - protected virtual Brush BrushTabText - { - get { return SystemBrushes.FromSystemColor(SystemColors.ControlDarkDark); } - } - #endregion - - private Matrix MatrixIdentity - { - get { return _matrixIdentity; } - } - - private DockState[] DockStates - { - get { return _dockStates; } - } - - static VS2003AutoHideStrip() - { - _matrixIdentity = new Matrix(); - - _dockStates = new DockState[4]; - _dockStates[0] = DockState.DockLeftAutoHide; - _dockStates[1] = DockState.DockRightAutoHide; - _dockStates[2] = DockState.DockTopAutoHide; - _dockStates[3] = DockState.DockBottomAutoHide; - } - - public VS2003AutoHideStrip(DockPanel panel) : base(panel) - { - SetStyle(ControlStyles.ResizeRedraw, true); - SetStyle(ControlStyles.UserPaint, true); - SetStyle(ControlStyles.AllPaintingInWmPaint, true); - BackColor = Color.WhiteSmoke; - } - - /// - protected override void OnPaint(PaintEventArgs e) - { - Graphics g = e.Graphics; - DrawTabStrip(g); - } - - /// - protected override void OnLayout(LayoutEventArgs levent) - { - CalculateTabs(); - base.OnLayout (levent); - } - - private void DrawTabStrip(Graphics g) - { - DrawTabStrip(g, DockState.DockTopAutoHide); - DrawTabStrip(g, DockState.DockBottomAutoHide); - DrawTabStrip(g, DockState.DockLeftAutoHide); - DrawTabStrip(g, DockState.DockRightAutoHide); - } - - private void DrawTabStrip(Graphics g, DockState dockState) - { - Rectangle rectTabStrip = GetLogicalTabStripRectangle(dockState); - - if (rectTabStrip.IsEmpty) - return; - - Matrix matrixIdentity = g.Transform; - if (dockState == DockState.DockLeftAutoHide || dockState == DockState.DockRightAutoHide) - { - Matrix matrixRotated = new Matrix(); - matrixRotated.RotateAt(90, new PointF((float)rectTabStrip.X + (float)rectTabStrip.Height / 2, - (float)rectTabStrip.Y + (float)rectTabStrip.Height / 2)); - g.Transform = matrixRotated; - } - - foreach (Pane pane in GetPanes(dockState)) - { - foreach (TabVS2003 tab in pane.AutoHideTabs) - DrawTab(g, tab); - } - g.Transform = matrixIdentity; - } - - private void CalculateTabs() - { - CalculateTabs(DockState.DockTopAutoHide); - CalculateTabs(DockState.DockBottomAutoHide); - CalculateTabs(DockState.DockLeftAutoHide); - CalculateTabs(DockState.DockRightAutoHide); - } - - private void CalculateTabs(DockState dockState) - { - Rectangle rectTabStrip = GetLogicalTabStripRectangle(dockState); - - int imageHeight = rectTabStrip.Height - ImageGapTop - ImageGapBottom; - int imageWidth = ImageWidth; - if (imageHeight > ImageHeight) - imageWidth = ImageWidth * (imageHeight/ImageHeight); - - using (Graphics g = CreateGraphics()) - { - int x = TabGapLeft + rectTabStrip.X; - foreach (Pane pane in GetPanes(dockState)) - { - int maxWidth = 0; - foreach (TabVS2003 tab in pane.AutoHideTabs) - { - int width = imageWidth + ImageGapLeft + ImageGapRight + - (int)g.MeasureString(tab.Content.DockHandler.TabText, Font).Width + 1 + - TextGapLeft + TextGapRight; - if (width > maxWidth) - maxWidth = width; - } - - foreach (TabVS2003 tab in pane.AutoHideTabs) - { - tab.TabX = x; - if (tab.Content == pane.DockPane.ActiveContent) - tab.TabWidth = maxWidth; - else - tab.TabWidth = imageWidth + ImageGapLeft + ImageGapRight; - x += tab.TabWidth; - } - x += TabGapBetween; - } - } - } - - private void DrawTab(Graphics g, TabVS2003 tab) - { - Rectangle rectTab = GetTabRectangle(tab); - if (rectTab.IsEmpty) - return; - - DockState dockState = tab.Content.DockHandler.DockState; - IDockContent content = tab.Content; - - OnBeginDrawTab(tab); - - Brush brushTabBackGround = BrushTabBackground; - Pen penTabBorder = PenTabBorder; - Brush brushTabText = BrushTabText; - - g.FillRectangle(brushTabBackGround, rectTab); - - g.DrawLine(penTabBorder, rectTab.Left, rectTab.Top, rectTab.Left, rectTab.Bottom); - g.DrawLine(penTabBorder, rectTab.Right, rectTab.Top, rectTab.Right, rectTab.Bottom); - if (dockState == DockState.DockTopAutoHide || dockState == DockState.DockRightAutoHide) - g.DrawLine(penTabBorder, rectTab.Left, rectTab.Bottom, rectTab.Right, rectTab.Bottom); - else - g.DrawLine(penTabBorder, rectTab.Left, rectTab.Top, rectTab.Right, rectTab.Top); - - // Set no rotate for drawing icon and text - Matrix matrixRotate = g.Transform; - g.Transform = MatrixIdentity; - - // Draw the icon - Rectangle rectImage = rectTab; - rectImage.X += ImageGapLeft; - rectImage.Y += ImageGapTop; - int imageHeight = rectTab.Height - ImageGapTop - ImageGapBottom; - int imageWidth = ImageWidth; - if (imageHeight > ImageHeight) - imageWidth = ImageWidth * (imageHeight/ImageHeight); - rectImage.Height = imageHeight; - rectImage.Width = imageWidth; - rectImage = GetTransformedRectangle(dockState, rectImage); - g.DrawIcon(((Form)content).Icon, rectImage); - - // Draw the text - if (content == content.DockHandler.Pane.ActiveContent) - { - Rectangle rectText = rectTab; - rectText.X += ImageGapLeft + imageWidth + ImageGapRight + TextGapLeft; - rectText.Width -= ImageGapLeft + imageWidth + ImageGapRight + TextGapLeft; - rectText = GetTransformedRectangle(dockState, rectText); - if (dockState == DockState.DockLeftAutoHide || dockState == DockState.DockRightAutoHide) - g.DrawString(content.DockHandler.TabText, Font, brushTabText, rectText, StringFormatTabVertical); - else - g.DrawString(content.DockHandler.TabText, Font, brushTabText, rectText, StringFormatTabHorizontal); - } - - // Set rotate back - g.Transform = matrixRotate; - - OnEndDrawTab(tab); - } - - private Rectangle GetLogicalTabStripRectangle(DockState dockState) - { - return GetLogicalTabStripRectangle(dockState, false); - } - - private Rectangle GetLogicalTabStripRectangle(DockState dockState, bool transformed) - { - if (!DockHelper.IsDockStateAutoHide(dockState)) - return Rectangle.Empty; - - int leftPanes = GetPanes(DockState.DockLeftAutoHide).Count; - int rightPanes = GetPanes(DockState.DockRightAutoHide).Count; - int topPanes = GetPanes(DockState.DockTopAutoHide).Count; - int bottomPanes = GetPanes(DockState.DockBottomAutoHide).Count; - - int x, y, width, height; - - height = MeasureHeight(); - if (dockState == DockState.DockLeftAutoHide && leftPanes > 0) - { - x = 0; - y = (topPanes == 0) ? 0 : height; - width = Height - (topPanes == 0 ? 0 : height) - (bottomPanes == 0 ? 0 :height); - } - else if (dockState == DockState.DockRightAutoHide && rightPanes > 0) - { - x = Width - height; - if (leftPanes != 0 && x < height) - x = height; - y = (topPanes == 0) ? 0 : height; - width = Height - (topPanes == 0 ? 0 : height) - (bottomPanes == 0 ? 0 :height); - } - else if (dockState == DockState.DockTopAutoHide && topPanes > 0) - { - x = leftPanes == 0 ? 0 : height; - y = 0; - width = Width - (leftPanes == 0 ? 0 : height) - (rightPanes == 0 ? 0 : height); - } - else if (dockState == DockState.DockBottomAutoHide && bottomPanes > 0) - { - x = leftPanes == 0 ? 0 : height; - y = Height - height; - if (topPanes != 0 && y < height) - y = height; - width = Width - (leftPanes == 0 ? 0 : height) - (rightPanes == 0 ? 0 : height); - } - else - return Rectangle.Empty; - - if (!transformed) - return new Rectangle(x, y, width, height); - else - return GetTransformedRectangle(dockState, new Rectangle(x, y, width, height)); - } - - private Rectangle GetTabRectangle(TabVS2003 tab) - { - return GetTabRectangle(tab, false); - } - - private Rectangle GetTabRectangle(TabVS2003 tab, bool transformed) - { - DockState dockState = tab.Content.DockHandler.DockState; - Rectangle rectTabStrip = GetLogicalTabStripRectangle(dockState); - - if (rectTabStrip.IsEmpty) - return Rectangle.Empty; - - int x = tab.TabX; - int y = rectTabStrip.Y + - (dockState == DockState.DockTopAutoHide || dockState == DockState.DockRightAutoHide ? - 0 : TabGapTop); - int width = tab.TabWidth; - int height = rectTabStrip.Height - TabGapTop; - - if (!transformed) - return new Rectangle(x, y, width, height); - else - return GetTransformedRectangle(dockState, new Rectangle(x, y, width, height)); - } - - private Rectangle GetTransformedRectangle(DockState dockState, Rectangle rect) - { - if (dockState != DockState.DockLeftAutoHide && dockState != DockState.DockRightAutoHide) - return rect; - - PointF[] pts = new PointF[1]; - // the center of the rectangle - pts[0].X = (float)rect.X + (float)rect.Width / 2; - pts[0].Y = (float)rect.Y + (float)rect.Height / 2; - Rectangle rectTabStrip = GetLogicalTabStripRectangle(dockState); - Matrix matrix = new Matrix(); - matrix.RotateAt(90, new PointF((float)rectTabStrip.X + (float)rectTabStrip.Height / 2, - (float)rectTabStrip.Y + (float)rectTabStrip.Height / 2)); - matrix.TransformPoints(pts); - - return new Rectangle((int)(pts[0].X - (float)rect.Height / 2 + .5F), - (int)(pts[0].Y - (float)rect.Width / 2 + .5F), - rect.Height, rect.Width); - } - - /// - protected override IDockContent HitTest(Point ptMouse) - { - foreach(DockState state in DockStates) - { - Rectangle rectTabStrip = GetLogicalTabStripRectangle(state, true); - if (!rectTabStrip.Contains(ptMouse)) - continue; - - foreach(Pane pane in GetPanes(state)) - { - foreach(TabVS2003 tab in pane.AutoHideTabs) - { - Rectangle rectTab = GetTabRectangle(tab, true); - rectTab.Intersect(rectTabStrip); - if (rectTab.Contains(ptMouse)) - return tab.Content; - } - } - } - - return null; - } - - /// - protected override int MeasureHeight() - { - return Math.Max(ImageGapBottom + - ImageGapTop + ImageHeight, - Font.Height) + TabGapTop; - } - - /// - protected override void OnRefreshChanges() - { - CalculateTabs(); - Invalidate(); - } - - protected override AutoHideStripBase.Tab CreateTab(IDockContent content) - { - return new TabVS2003(content); - } - - /// - protected virtual void OnBeginDrawTab(Tab tab) - { - } - - /// - protected virtual void OnEndDrawTab(Tab tab) - { - } - } -} diff --git a/src/Libraries/DockPanel_Src/DockSample/Customization/VS2003DockPaneCaption.cs b/src/Libraries/DockPanel_Src/DockSample/Customization/VS2003DockPaneCaption.cs deleted file mode 100644 index b9eb769be0..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/Customization/VS2003DockPaneCaption.cs +++ /dev/null @@ -1,359 +0,0 @@ -using System; -using System.Drawing; -using System.Windows.Forms; -using System.ComponentModel; -using WeifenLuo.WinFormsUI.Docking; - -namespace DockSample.Customization -{ - /// - internal class VS2003DockPaneCaption : DockPaneCaptionBase - { - #region consts - private const int _TextGapTop = 2; - private const int _TextGapBottom = 0; - private const int _TextGapLeft = 3; - private const int _TextGapRight = 3; - private const int _ButtonGapTop = 2; - private const int _ButtonGapBottom = 1; - private const int _ButtonGapBetween = 1; - private const int _ButtonGapLeft = 1; - private const int _ButtonGapRight = 2; - #endregion - - private InertButton m_buttonClose; - private InertButton m_buttonAutoHide; - - /// - protected internal VS2003DockPaneCaption(DockPane pane) : base(pane) - { - SuspendLayout(); - - Font = SystemInformation.MenuFont; - - m_buttonClose = new InertButton(ImageCloseEnabled, ImageCloseDisabled); - m_buttonAutoHide = new InertButton(); - - m_buttonClose.ToolTipText = ToolTipClose; - m_buttonClose.Anchor = AnchorStyles.Top | AnchorStyles.Right; - m_buttonClose.Click += new EventHandler(this.Close_Click); - - m_buttonAutoHide.ToolTipText = ToolTipAutoHide; - m_buttonAutoHide.Anchor = AnchorStyles.Top | AnchorStyles.Right; - m_buttonAutoHide.Click += new EventHandler(AutoHide_Click); - - Controls.AddRange(new Control[] { m_buttonClose, m_buttonAutoHide }); - - ResumeLayout(); - } - - #region Customizable Properties - /// - protected virtual int TextGapTop - { - get { return _TextGapTop; } - } - - /// - protected virtual int TextGapBottom - { - get { return _TextGapBottom; } - } - - /// - protected virtual int TextGapLeft - { - get { return _TextGapLeft; } - } - - /// - protected virtual int TextGapRight - { - get { return _TextGapRight; } - } - - /// - protected virtual int ButtonGapTop - { - get { return _ButtonGapTop; } - } - - /// - protected virtual int ButtonGapBottom - { - get { return _ButtonGapBottom; } - } - - /// - protected virtual int ButtonGapLeft - { - get { return _ButtonGapLeft; } - } - - /// - protected virtual int ButtonGapRight - { - get { return _ButtonGapRight; } - } - - /// - protected virtual int ButtonGapBetween - { - get { return _ButtonGapBetween; } - } - - private static Image _imageCloseEnabled = null; - /// - protected virtual Image ImageCloseEnabled - { - get - { - if (_imageCloseEnabled == null) - _imageCloseEnabled = Resources.DockPaneCaption_CloseEnabled; - return _imageCloseEnabled; - } - } - - private static Image _imageCloseDisabled = null; - /// - protected virtual Image ImageCloseDisabled - { - get - { - if (_imageCloseDisabled == null) - _imageCloseDisabled = Resources.DockPaneCaption_CloseDisabled; - return _imageCloseDisabled; - } - } - - private static Image _imageAutoHideYes = null; - /// - protected virtual Image ImageAutoHideYes - { - get - { - if (_imageAutoHideYes == null) - _imageAutoHideYes = Resources.DockPaneCaption_AutoHideYes; - return _imageAutoHideYes; - } - } - - private static Image _imageAutoHideNo = null; - /// - protected virtual Image ImageAutoHideNo - { - get - { - if (_imageAutoHideNo == null) - _imageAutoHideNo = Resources.DockPaneCaption_AutoHideNo; - return _imageAutoHideNo; - } - } - - private static string _toolTipClose = null; - /// - protected virtual string ToolTipClose - { - get - { - if (_toolTipClose == null) - _toolTipClose = Strings.DockPaneCaption_ToolTipClose; - return _toolTipClose; - } - } - - private static string _toolTipAutoHide = null; - /// - protected virtual string ToolTipAutoHide - { - get - { - if (_toolTipAutoHide == null) - _toolTipAutoHide = Strings.DockPaneCaption_ToolTipAutoHide; - return _toolTipAutoHide; - } - } - - /// - protected virtual Color ActiveBackColor - { - get { return SystemColors.ActiveCaption; } - } - - /// - protected virtual Color InactiveBackColor - { - get { return SystemColors.Control; } - } - - /// - protected virtual Color ActiveTextColor - { - get { return SystemColors.ActiveCaptionText; } - } - - /// - protected virtual Color InactiveTextColor - { - get { return SystemColors.ControlText; } - } - - /// - protected virtual Color InactiveBorderColor - { - get { return SystemColors.GrayText; } - } - - /// - protected virtual Color ActiveButtonBorderColor - { - get { return ActiveTextColor; } - } - - /// - protected virtual Color InactiveButtonBorderColor - { - get { return Color.Empty; } - } - - private static TextFormatFlags _textFormat = - TextFormatFlags.SingleLine | - TextFormatFlags.EndEllipsis | - TextFormatFlags.VerticalCenter; - /// - protected virtual TextFormatFlags TextFormat - { - get - { - return _textFormat; - } - } - - #endregion - - /// - protected override int MeasureHeight() - { - int height = Font.Height + TextGapTop + TextGapBottom; - - if (height < ImageCloseEnabled.Height + ButtonGapTop + ButtonGapBottom) - height = ImageCloseEnabled.Height + ButtonGapTop + ButtonGapBottom; - - return height; - } - - /// - protected override void OnPaint(PaintEventArgs e) - { - base.OnPaint (e); - DrawCaption(e.Graphics); - } - - private void DrawCaption(Graphics g) - { - BackColor = DockPane.IsActivated ? ActiveBackColor : InactiveBackColor; - - Rectangle rectCaption = ClientRectangle; - - if (!DockPane.IsActivated) - { - using (Pen pen = new Pen(InactiveBorderColor)) - { - g.DrawLine(pen, rectCaption.X + 1, rectCaption.Y, rectCaption.X + rectCaption.Width - 2, rectCaption.Y); - g.DrawLine(pen, rectCaption.X + 1, rectCaption.Y + rectCaption.Height - 1, rectCaption.X + rectCaption.Width - 2, rectCaption.Y + rectCaption.Height - 1); - g.DrawLine(pen, rectCaption.X, rectCaption.Y + 1, rectCaption.X, rectCaption.Y + rectCaption.Height - 2); - g.DrawLine(pen, rectCaption.X + rectCaption.Width - 1, rectCaption.Y + 1, rectCaption.X + rectCaption.Width - 1, rectCaption.Y + rectCaption.Height - 2); - } - } - - m_buttonClose.ForeColor = m_buttonAutoHide.ForeColor = (DockPane.IsActivated ? ActiveTextColor : InactiveTextColor); - m_buttonClose.BorderColor = m_buttonAutoHide.BorderColor = (DockPane.IsActivated ? ActiveButtonBorderColor : InactiveButtonBorderColor); - - Rectangle rectCaptionText = rectCaption; - rectCaptionText.X += TextGapLeft; - if (ShouldShowCloseButton && ShouldShowAutoHideButton) - rectCaptionText.Width = rectCaption.Width - ButtonGapRight - - ButtonGapLeft - TextGapLeft - TextGapRight - - (m_buttonAutoHide.Width + ButtonGapBetween + m_buttonClose.Width); - else if (ShouldShowCloseButton || ShouldShowAutoHideButton) - rectCaptionText.Width = rectCaption.Width - ButtonGapRight - - ButtonGapLeft - TextGapLeft - TextGapRight - m_buttonClose.Width; - else - rectCaptionText.Width = rectCaption.Width - TextGapLeft - TextGapRight; - rectCaptionText.Y += TextGapTop; - rectCaptionText.Height -= TextGapTop + TextGapBottom; - TextRenderer.DrawText(g, DockPane.CaptionText, Font, rectCaptionText, DockPane.IsActivated ? ActiveTextColor : InactiveTextColor, TextFormat); - } - - /// - protected override void OnLayout(LayoutEventArgs levent) - { - SetButtonsPosition(); - base.OnLayout (levent); - } - - /// - protected override void OnRefreshChanges() - { - SetButtons(); - Invalidate(); - } - - private bool ShouldShowCloseButton - { - get { return (DockPane.ActiveContent != null)? DockPane.ActiveContent.DockHandler.CloseButton : false; } - } - - private bool ShouldShowAutoHideButton - { - get { return !DockPane.IsFloat; } - } - - private void SetButtons() - { - m_buttonClose.Visible = ShouldShowCloseButton; - m_buttonAutoHide.Visible = ShouldShowAutoHideButton; - m_buttonAutoHide.ImageEnabled = DockPane.IsAutoHide ? ImageAutoHideYes : ImageAutoHideNo; - - SetButtonsPosition(); - } - - private void SetButtonsPosition() - { - // set the size and location for close and auto-hide buttons - Rectangle rectCaption = ClientRectangle; - int buttonWidth = ImageCloseEnabled.Width; - int buttonHeight = ImageCloseEnabled.Height; - int height = rectCaption.Height - ButtonGapTop - ButtonGapBottom; - if (buttonHeight < height) - { - buttonWidth = buttonWidth * (height / buttonHeight); - buttonHeight = height; - } - m_buttonClose.SuspendLayout(); - m_buttonAutoHide.SuspendLayout(); - Size buttonSize = new Size(buttonWidth, buttonHeight); - m_buttonClose.Size = m_buttonAutoHide.Size = buttonSize; - int x = rectCaption.X + rectCaption.Width - 1 - ButtonGapRight - m_buttonClose.Width; - int y = rectCaption.Y + ButtonGapTop; - Point point = m_buttonClose.Location = new Point(x, y); - if (ShouldShowCloseButton) - point.Offset(-(m_buttonAutoHide.Width + ButtonGapBetween), 0); - m_buttonAutoHide.Location = point; - m_buttonClose.ResumeLayout(); - m_buttonAutoHide.ResumeLayout(); - } - - private void Close_Click(object sender, EventArgs e) - { - DockPane.CloseActiveContent(); - } - - private void AutoHide_Click(object sender, EventArgs e) - { - DockPane.DockState = DockHelper.ToggleAutoHideState(DockPane.DockState); - if (!DockPane.IsAutoHide) - DockPane.Activate(); - } - } -} diff --git a/src/Libraries/DockPanel_Src/DockSample/Customization/VS2003DockPaneStrip.cs b/src/Libraries/DockPanel_Src/DockSample/Customization/VS2003DockPaneStrip.cs deleted file mode 100644 index 6761cadb5e..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/Customization/VS2003DockPaneStrip.cs +++ /dev/null @@ -1,1085 +0,0 @@ -using System; -using System.Drawing; -using System.Drawing.Drawing2D; -using System.Windows.Forms; -using System.ComponentModel; -using WeifenLuo.WinFormsUI.Docking; - -namespace DockSample.Customization -{ - internal class VS2003DockPaneStrip : DockPaneStripBase - { - private class TabVS2003 : Tab - { - internal TabVS2003(IDockContent content) - : base(content) - { - } - - private int m_tabX; - protected internal int TabX - { - get { return m_tabX; } - set { m_tabX = value; } - } - - private int m_tabWidth; - protected internal int TabWidth - { - get { return m_tabWidth; } - set { m_tabWidth = value; } - } - - private int m_maxWidth; - protected internal int MaxWidth - { - get { return m_maxWidth; } - set { m_maxWidth = value; } - } - - private bool m_flag; - protected internal bool Flag - { - get { return m_flag; } - set { m_flag = value; } - } - } - - protected override DockPaneStripBase.Tab CreateTab(IDockContent content) - { - return new TabVS2003(content); - } - - private class DocumentButton : Label - { - public DocumentButton(Image image) - { - Image = image; - } - - - } - - #region consts - private const int _ToolWindowStripGapLeft = 4; - private const int _ToolWindowStripGapRight = 3; - private const int _ToolWindowImageHeight = 16; - private const int _ToolWindowImageWidth = 16; - private const int _ToolWindowImageGapTop = 3; - private const int _ToolWindowImageGapBottom = 1; - private const int _ToolWindowImageGapLeft = 3; - private const int _ToolWindowImageGapRight = 2; - private const int _ToolWindowTextGapRight = 1; - private const int _ToolWindowTabSeperatorGapTop = 3; - private const int _ToolWindowTabSeperatorGapBottom = 3; - - private const int _DocumentTabMaxWidth = 200; - private const int _DocumentButtonGapTop = 5; - private const int _DocumentButtonGapBottom = 5; - private const int _DocumentButtonGapBetween = 0; - private const int _DocumentButtonGapRight = 3; - private const int _DocumentTabGapTop = 3; - private const int _DocumentTabGapLeft = 3; - private const int _DocumentTabGapRight = 3; - private const int _DocumentIconGapLeft = 6; - private const int _DocumentIconHeight = 16; - private const int _DocumentIconWidth = 16; - #endregion - - private InertButton m_buttonClose, m_buttonScrollLeft, m_buttonScrollRight; - private IContainer m_components; - private ToolTip m_toolTip; - - /// - protected IContainer Components - { - get { return m_components; } - } - - private int m_offsetX = 0; - private int OffsetX - { - get { return m_offsetX; } - set - { - m_offsetX = value; - #if DEBUG - if (m_offsetX > 0) - throw new InvalidOperationException(); - #endif - } - } - - #region Customizable Properties - /// - protected virtual int ToolWindowStripGapLeft - { - get { return _ToolWindowStripGapLeft; } - } - - /// - protected virtual int ToolWindowStripGapRight - { - get { return _ToolWindowStripGapRight; } - } - - /// - protected virtual int ToolWindowImageHeight - { - get { return _ToolWindowImageHeight; } - } - - /// - protected virtual int ToolWindowImageWidth - { - get { return _ToolWindowImageWidth; } - } - - /// - protected virtual int ToolWindowImageGapTop - { - get { return _ToolWindowImageGapTop; } - } - - /// - protected virtual int ToolWindowImageGapBottom - { - get { return _ToolWindowImageGapBottom; } - } - - /// - protected virtual int ToolWindowImageGapLeft - { - get { return _ToolWindowImageGapLeft; } - } - - /// - protected virtual int ToolWindowImageGapRight - { - get { return _ToolWindowImageGapRight; } - } - - /// - protected virtual int ToolWindowTextGapRight - { - get { return _ToolWindowTextGapRight; } - } - - /// - protected virtual int ToolWindowTabSeperatorGapTop - { - get { return _ToolWindowTabSeperatorGapTop; } - } - - /// - protected virtual int ToolWindowTabSeperatorGapBottom - { - get { return _ToolWindowTabSeperatorGapBottom; } - } - - private static Image _imageCloseEnabled = null; - /// - protected virtual Image ImageCloseEnabled - { - get - { - if (_imageCloseEnabled == null) - _imageCloseEnabled = Resources.DockPaneStrip_CloseEnabled; - return _imageCloseEnabled; - } - } - - private static Image _imageCloseDisabled = null; - /// - protected virtual Image ImageCloseDisabled - { - get - { - if (_imageCloseDisabled == null) - _imageCloseDisabled = Resources.DockPaneStrip_CloseDisabled; - return _imageCloseDisabled; - } - } - - private static Image _imageScrollLeftEnabled = null; - /// - protected virtual Image ImageScrollLeftEnabled - { - get - { - if (_imageScrollLeftEnabled == null) - _imageScrollLeftEnabled = Resources.DockPaneStrip_ScrollLeftEnabled; - return _imageScrollLeftEnabled; - } - } - - private static Image _imageScrollLeftDisabled = null; - /// - protected virtual Image ImageScrollLeftDisabled - { - get - { - if (_imageScrollLeftDisabled == null) - _imageScrollLeftDisabled = Resources.DockPaneStrip_ScrollLeftDisabled; - return _imageScrollLeftDisabled; - } - } - - private static Image _imageScrollRightEnabled = null; - /// - protected virtual Image ImageScrollRightEnabled - { - get - { - if (_imageScrollRightEnabled == null) - _imageScrollRightEnabled = Resources.DockPaneStrip_ScrollRightEnabled; - return _imageScrollRightEnabled; - } - } - - private static Image _imageScrollRightDisabled = null; - /// - protected virtual Image ImageScrollRightDisabled - { - get - { - if (_imageScrollRightDisabled == null) - _imageScrollRightDisabled = Resources.DockPaneStrip_ScrollRightDisabled; - return _imageScrollRightDisabled; - } - } - - private static string _toolTipClose = null; - /// - protected virtual string ToolTipClose - { - get - { - if (_toolTipClose == null) - _toolTipClose = Strings.DockPaneStrip_ToolTipClose; - return _toolTipClose; - } - } - - private static string _toolTipScrollLeft = null; - /// - protected virtual string ToolTipScrollLeft - { - get - { - if (_toolTipScrollLeft == null) - _toolTipScrollLeft = Strings.DockPaneStrip_ToolTipScrollLeft; - return _toolTipScrollLeft; - } - } - - private static string _toolTipScrollRight = null; - /// - protected virtual string ToolTipScrollRight - { - get - { - if (_toolTipScrollRight == null) - _toolTipScrollRight = Strings.DockPaneStrip_ToolTipScrollRight; - return _toolTipScrollRight; - } - } - - private static TextFormatFlags _toolWindowTextFormat = - TextFormatFlags.EndEllipsis | - TextFormatFlags.HorizontalCenter | - TextFormatFlags.SingleLine | - TextFormatFlags.VerticalCenter; - /// - protected virtual TextFormatFlags ToolWindowTextFormat - { - get { return _toolWindowTextFormat; } - } - - private static TextFormatFlags _documentTextFormat = - TextFormatFlags.PathEllipsis | - TextFormatFlags.SingleLine | - TextFormatFlags.VerticalCenter; - /// - public static TextFormatFlags DocumentTextFormat - { - get { return _documentTextFormat; } - } - - /// - protected virtual int DocumentTabMaxWidth - { - get { return _DocumentTabMaxWidth; } - } - - /// - protected virtual int DocumentButtonGapTop - { - get { return _DocumentButtonGapTop; } - } - - /// - protected virtual int DocumentButtonGapBottom - { - get { return _DocumentButtonGapBottom; } - } - - /// - protected virtual int DocumentButtonGapBetween - { - get { return _DocumentButtonGapBetween; } - } - - /// - protected virtual int DocumentButtonGapRight - { - get { return _DocumentButtonGapRight; } - } - - /// - protected virtual int DocumentTabGapTop - { - get { return _DocumentTabGapTop; } - } - - /// - protected virtual int DocumentTabGapLeft - { - get { return _DocumentTabGapLeft; } - } - - /// - protected virtual int DocumentTabGapRight - { - get { return _DocumentTabGapRight; } - } - - /// - protected virtual int DocumentIconGapLeft - { - get { return _DocumentIconGapLeft; } - } - - /// - protected virtual int DocumentIconWidth - { - get { return _DocumentIconWidth; } - } - - /// - protected virtual int DocumentIconHeight - { - get { return _DocumentIconHeight; } - } - - /// - protected virtual Pen OutlineInnerPen - { - get { return SystemPens.ControlText; } - } - - /// - protected virtual Pen OutlineOuterPen - { - get { return SystemPens.ActiveCaptionText; } - } - - /// - protected virtual Brush ActiveBackBrush - { - get { return SystemBrushes.Control; } - } - - /// - protected virtual Color ActiveTextColor - { - get { return SystemColors.ControlText; } - } - - /// - protected virtual Pen TabSeperatorPen - { - get { return SystemPens.GrayText; } - } - - /// - protected virtual Color InactiveTextColor - { - get { return SystemColors.ControlDarkDark; } - } - #endregion - - public VS2003DockPaneStrip(DockPane pane) : base(pane) - { - SetStyle(ControlStyles.ResizeRedraw, true); - SetStyle(ControlStyles.UserPaint, true); - SetStyle(ControlStyles.AllPaintingInWmPaint, true); - - SuspendLayout(); - - Font = SystemInformation.MenuFont; - BackColor = Color.WhiteSmoke; - - m_components = new Container(); - m_toolTip = new ToolTip(Components); - - m_buttonClose = new InertButton(ImageCloseEnabled, ImageCloseDisabled); - m_buttonScrollLeft = new InertButton(ImageScrollLeftEnabled, ImageScrollLeftDisabled); - m_buttonScrollRight = new InertButton(ImageScrollRightEnabled, ImageScrollRightDisabled); - - m_buttonClose.ToolTipText = ToolTipClose; - m_buttonClose.Anchor = AnchorStyles.Top | AnchorStyles.Right; - m_buttonClose.Click += new EventHandler(Close_Click); - - m_buttonScrollLeft.Enabled = false; - m_buttonScrollLeft.RepeatClick = true; - m_buttonScrollLeft.ToolTipText = ToolTipScrollLeft; - m_buttonScrollLeft.Anchor = AnchorStyles.Top | AnchorStyles.Right; - m_buttonScrollLeft.Click += new EventHandler(ScrollLeft_Click); - - m_buttonScrollRight.Enabled = false; - m_buttonScrollRight.RepeatClick = true; - m_buttonScrollRight.ToolTipText = ToolTipScrollRight; - m_buttonScrollRight.Anchor = AnchorStyles.Top | AnchorStyles.Right; - m_buttonScrollRight.Click += new EventHandler(ScrollRight_Click); - - Controls.AddRange(new Control[] { m_buttonClose, - m_buttonScrollLeft, - m_buttonScrollRight }); - - ResumeLayout(); - } - - protected override void Dispose(bool disposing) - { - if (disposing) - { - Components.Dispose(); - } - base.Dispose (disposing); - } - - protected override int MeasureHeight() - { - if (Appearance == DockPane.AppearanceStyle.ToolWindow) - return MeasureHeight_ToolWindow(); - else - return MeasureHeight_Document(); - } - - private int MeasureHeight_ToolWindow() - { - if (DockPane.IsAutoHide || Tabs.Count <= 1) - return 0; - - int height = Math.Max(Font.Height, ToolWindowImageHeight) - + ToolWindowImageGapTop + ToolWindowImageGapBottom; - - return height; - } - - private int MeasureHeight_Document() - { - int height = Math.Max(Font.Height + DocumentTabGapTop, - ImageCloseEnabled.Height + DocumentButtonGapTop + DocumentButtonGapBottom); - - return height; - } - - protected override void OnPaint(PaintEventArgs e) - { - base.OnPaint (e); - CalculateTabs(); - DrawTabStrip(e.Graphics); - } - - protected override void OnRefreshChanges() - { - CalculateTabs(); - SetInertButtons(); - Invalidate(); - } - - protected override GraphicsPath GetOutline(int index) - { - Point[] pts = new Point[8]; - - if (Appearance == DockPane.AppearanceStyle.Document) - { - Rectangle rectTab = GetTabRectangle(index); - rectTab.Intersect(TabsRectangle); - int y = DockPane.PointToClient(PointToScreen(new Point(0, rectTab.Bottom))).Y; - Rectangle rectPaneClient = DockPane.ClientRectangle; - pts[0] = DockPane.PointToScreen(new Point(rectPaneClient.Left, y)); - pts[1] = PointToScreen(new Point(rectTab.Left, rectTab.Bottom)); - pts[2] = PointToScreen(new Point(rectTab.Left, rectTab.Top)); - pts[3] = PointToScreen(new Point(rectTab.Right, rectTab.Top)); - pts[4] = PointToScreen(new Point(rectTab.Right, rectTab.Bottom)); - pts[5] = DockPane.PointToScreen(new Point(rectPaneClient.Right, y)); - pts[6] = DockPane.PointToScreen(new Point(rectPaneClient.Right, rectPaneClient.Bottom)); - pts[7] = DockPane.PointToScreen(new Point(rectPaneClient.Left, rectPaneClient.Bottom)); - } - else - { - Rectangle rectTab = GetTabRectangle(index); - rectTab.Intersect(TabsRectangle); - int y = DockPane.PointToClient(PointToScreen(new Point(0, rectTab.Top))).Y; - Rectangle rectPaneClient = DockPane.ClientRectangle; - pts[0] = DockPane.PointToScreen(new Point(rectPaneClient.Left, rectPaneClient.Top)); - pts[1] = DockPane.PointToScreen(new Point(rectPaneClient.Right, rectPaneClient.Top)); - pts[2] = DockPane.PointToScreen(new Point(rectPaneClient.Right, y)); - pts[3] = PointToScreen(new Point(rectTab.Right, rectTab.Top)); - pts[4] = PointToScreen(new Point(rectTab.Right, rectTab.Bottom)); - pts[5] = PointToScreen(new Point(rectTab.Left, rectTab.Bottom)); - pts[6] = PointToScreen(new Point(rectTab.Left, rectTab.Top)); - pts[7] = DockPane.PointToScreen(new Point(rectPaneClient.Left, y)); - } - - GraphicsPath path = new GraphicsPath(); - path.AddLines(pts); - return path; - } - - private void CalculateTabs() - { - if (Appearance == DockPane.AppearanceStyle.ToolWindow) - CalculateTabs_ToolWindow(); - else - CalculateTabs_Document(); - } - - private void CalculateTabs_ToolWindow() - { - if (Tabs.Count <= 1 || DockPane.IsAutoHide) - return; - - Rectangle rectTabStrip = ClientRectangle; - - // Calculate tab widths - int countTabs = Tabs.Count; - foreach (TabVS2003 tab in Tabs) - { - tab.MaxWidth = GetTabOriginalWidth(Tabs.IndexOf(tab)); - tab.Flag = false; - } - - // Set tab whose max width less than average width - bool anyWidthWithinAverage = true; - int totalWidth = rectTabStrip.Width - ToolWindowStripGapLeft - ToolWindowStripGapRight; - int totalAllocatedWidth = 0; - int averageWidth = totalWidth / countTabs; - int remainedTabs = countTabs; - for (anyWidthWithinAverage=true; anyWidthWithinAverage && remainedTabs>0;) - { - anyWidthWithinAverage = false; - foreach (TabVS2003 tab in Tabs) - { - if (tab.Flag) - continue; - - if (tab.MaxWidth <= averageWidth) - { - tab.Flag = true; - tab.TabWidth = tab.MaxWidth; - totalAllocatedWidth += tab.TabWidth; - anyWidthWithinAverage = true; - remainedTabs--; - } - } - if (remainedTabs != 0) - averageWidth = (totalWidth - totalAllocatedWidth) / remainedTabs; - } - - // If any tab width not set yet, set it to the average width - if (remainedTabs > 0) - { - int roundUpWidth = (totalWidth - totalAllocatedWidth) - (averageWidth * remainedTabs); - foreach (TabVS2003 tab in Tabs) - { - if (tab.Flag) - continue; - - tab.Flag = true; - if (roundUpWidth > 0) - { - tab.TabWidth = averageWidth + 1; - roundUpWidth --; - } - else - tab.TabWidth = averageWidth; - } - } - - // Set the X position of the tabs - int x = rectTabStrip.X + ToolWindowStripGapLeft; - foreach (TabVS2003 tab in Tabs) - { - tab.TabX = x; - x += tab.TabWidth; - } - } - - private void CalculateTabs_Document() - { - Rectangle rectTabStrip = TabsRectangle; - - int totalWidth = 0; - foreach (TabVS2003 tab in Tabs) - { - tab.TabWidth = Math.Min(GetTabOriginalWidth(Tabs.IndexOf(tab)), DocumentTabMaxWidth); - totalWidth += tab.TabWidth; - } - - if (totalWidth + OffsetX < rectTabStrip.Width && OffsetX < 0) - OffsetX = Math.Min(0, rectTabStrip.Width - totalWidth); - - int x = rectTabStrip.X + OffsetX; - foreach (TabVS2003 tab in Tabs) - { - tab.TabX = x; - x += tab.TabWidth; - } - } - - protected override void EnsureTabVisible(IDockContent content) - { - if (Appearance != DockPane.AppearanceStyle.Document || !Tabs.Contains(content)) - return; - - Rectangle rectTabStrip = TabsRectangle; - Rectangle rectTab = GetTabRectangle(Tabs.IndexOf(content)); - - if (rectTab.Right > rectTabStrip.Right) - { - OffsetX -= rectTab.Right - rectTabStrip.Right; - rectTab.X -= rectTab.Right - rectTabStrip.Right; - } - - if (rectTab.Left < rectTabStrip.Left) - OffsetX += rectTabStrip.Left - rectTab.Left; - - OnRefreshChanges(); - } - - private int GetTabOriginalWidth(int index) - { - if (Appearance == DockPane.AppearanceStyle.ToolWindow) - return GetTabOriginalWidth_ToolWindow(index); - else - return GetTabOriginalWidth_Document(index); - } - - private int GetTabOriginalWidth_ToolWindow(int index) - { - IDockContent content = Tabs[index].Content; - using (Graphics g = CreateGraphics()) - { - Size sizeString = TextRenderer.MeasureText(g, content.DockHandler.TabText, Font); - return ToolWindowImageWidth + sizeString.Width + ToolWindowImageGapLeft - + ToolWindowImageGapRight + ToolWindowTextGapRight; - } - } - - private int GetTabOriginalWidth_Document(int index) - { - IDockContent content = Tabs[index].Content; - - int height = GetTabRectangle_Document(index).Height; - - using (Graphics g = CreateGraphics()) - { - Size sizeText; - if (content == DockPane.ActiveContent && DockPane.IsActiveDocumentPane) - { - using (Font boldFont = new Font(this.Font, FontStyle.Bold)) - { - sizeText = TextRenderer.MeasureText(g, content.DockHandler.TabText, boldFont, new Size(DocumentTabMaxWidth, height), DocumentTextFormat); - } - } - else - sizeText = TextRenderer.MeasureText(content.DockHandler.TabText, Font, new Size(DocumentTabMaxWidth, height), DocumentTextFormat); - - if (DockPane.DockPanel.ShowDocumentIcon) - return sizeText.Width + DocumentIconWidth + DocumentIconGapLeft; - else - return sizeText.Width; - } - } - - private void DrawTabStrip(Graphics g) - { - OnBeginDrawTabStrip(); - - if (Appearance == DockPane.AppearanceStyle.Document) - DrawTabStrip_Document(g); - else - DrawTabStrip_ToolWindow(g); - - OnEndDrawTabStrip(); - } - - private void DrawTabStrip_Document(Graphics g) - { - int count = Tabs.Count; - if (count == 0) - return; - - Rectangle rectTabStrip = ClientRectangle; - g.DrawLine(OutlineOuterPen, rectTabStrip.Left, rectTabStrip.Bottom - 1, - rectTabStrip.Right, rectTabStrip.Bottom - 1); - - // Draw the tabs - Rectangle rectTabOnly = TabsRectangle; - Rectangle rectTab = Rectangle.Empty; - g.SetClip(rectTabOnly); - for (int i=0; i rectTabOnly.Right; - - // show/hide close button - if (Appearance == DockPane.AppearanceStyle.ToolWindow) - m_buttonClose.Visible = false; - else - { - bool showCloseButton = DockPane.ActiveContent == null ? true : DockPane.ActiveContent.DockHandler.CloseButton; - if (m_buttonClose.Visible != showCloseButton) - { - m_buttonClose.Visible = showCloseButton; - PerformLayout(); - } - } - } - - /// - protected override void OnLayout(LayoutEventArgs levent) - { - Rectangle rectTabStrip = ClientRectangle; - - // Set position and size of the buttons - int buttonWidth = ImageCloseEnabled.Width; - int buttonHeight = ImageCloseEnabled.Height; - int height = rectTabStrip.Height - DocumentButtonGapTop - DocumentButtonGapBottom; - if (buttonHeight < height) - { - buttonWidth = buttonWidth * (height / buttonHeight); - buttonHeight = height; - } - Size buttonSize = new Size(buttonWidth, buttonHeight); - m_buttonClose.Size = m_buttonScrollLeft.Size = m_buttonScrollRight.Size = buttonSize; - int x = rectTabStrip.X + rectTabStrip.Width - DocumentTabGapLeft - - DocumentButtonGapRight - buttonWidth; - int y = rectTabStrip.Y + DocumentButtonGapTop; - m_buttonClose.Location = new Point(x, y); - Point point = m_buttonClose.Location; - bool showCloseButton = DockPane.ActiveContent == null ? true : DockPane.ActiveContent.DockHandler.CloseButton; - if (showCloseButton) - point.Offset(-(DocumentButtonGapBetween + buttonWidth), 0); - m_buttonScrollRight.Location = point; - point.Offset(-(DocumentButtonGapBetween + buttonWidth), 0); - m_buttonScrollLeft.Location = point; - - OnRefreshChanges(); - - base.OnLayout (levent); - } - - private void Close_Click(object sender, EventArgs e) - { - DockPane.CloseActiveContent(); - } - - /// - protected override int HitTest(Point ptMouse) - { - Rectangle rectTabStrip = TabsRectangle; - - for (int i=0; i - protected override void OnMouseMove(MouseEventArgs e) - { - int index = HitTest(PointToClient(Control.MousePosition)); - string toolTip = string.Empty; - - base.OnMouseMove(e); - - if (index != -1) - { - Rectangle rectTab = GetTabRectangle(index); - if (Tabs[index].Content.DockHandler.ToolTipText != null) - toolTip = Tabs[index].Content.DockHandler.ToolTipText; - else if (rectTab.Width < GetTabOriginalWidth(index)) - toolTip = Tabs[index].Content.DockHandler.TabText; - } - - if (m_toolTip.GetToolTip(this) != toolTip) - { - m_toolTip.Active = false; - m_toolTip.SetToolTip(this, toolTip); - m_toolTip.Active = true; - } - } - - /// - protected virtual void OnBeginDrawTabStrip() - { - } - - /// - protected virtual void OnEndDrawTabStrip() - { - } - - /// - protected virtual void OnBeginDrawTab(Tab tab) - { - } - - /// - protected virtual void OnEndDrawTab(Tab tab) - { - } - } -} diff --git a/src/Libraries/DockPanel_Src/DockSample/DockSample.csproj b/src/Libraries/DockPanel_Src/DockSample/DockSample.csproj deleted file mode 100644 index e0234e468a..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/DockSample.csproj +++ /dev/null @@ -1,324 +0,0 @@ - - - Debug - AnyCPU - 8.0.50727 - 2.0 - {40793A27-478B-4357-B4C3-FC8943131F3D} - WinExe - Properties - DockSample - DockSample - - - true - full - false - bin\Debug\ - DEBUG;TRACE - prompt - 4 - - - pdbonly - true - bin\Release\ - TRACE - prompt - 4 - - - - - - - - - - - Form - - - AboutDialog.cs - - - Form - - - MainForm2.cs - - - Form - - - DummyDoc.cs - - - Form - - - DummyOutputWindow.cs - - - Form - - - DummyPropertyWindow.cs - - - Form - - - DummySolutionExplorer.cs - - - Form - - - DummyTaskList.cs - - - Form - - - DummyToolbox.cs - - - - - Component - - - Component - - - Component - - - Component - - - Form - - - MainForm.cs - - - - - Designer - AboutDialog.cs - - - Designer - DummyDoc.cs - - - Designer - DummyOutputWindow.cs - - - Designer - DummyPropertyWindow.cs - - - Designer - DummySolutionExplorer.cs - - - Designer - DummyTaskList.cs - - - Designer - DummyToolbox.cs - - - Designer - MainForm.cs - - - ResXFileCodeGenerator - Resources.Designer.cs - Designer - - - True - Resources.resx - True - - - SettingsSingleFileGenerator - Settings.Designer.cs - - - True - Settings.settings - True - - - Resources.resx - True - True - - - Strings.resx - True - True - - - Form - - - ToolWindow.cs - - - - - {C75532C4-765B-418E-B09B-46D36B2ABDB1} - WinFormsUI - - - - - - - - - - - - - - - - - - - - - - - - - - - - - MainForm2.cs - Designer - - - ResXFileCodeGenerator - Resources.Designer.cs - Designer - - - - ResXFileCodeGenerator - Strings.Designer.cs - Designer - - - Designer - ToolWindow.cs - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Always - - - - - \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/DummyDoc.Designer.cs b/src/Libraries/DockPanel_Src/DockSample/DummyDoc.Designer.cs deleted file mode 100644 index 4c55edf266..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/DummyDoc.Designer.cs +++ /dev/null @@ -1,147 +0,0 @@ -namespace DockSample -{ - partial class DummyDoc - { - /// - /// Required designer variable. - /// - private System.ComponentModel.IContainer components = null; - - /// - /// Clean up any resources being used. - /// - /// true if managed resources should be disposed; otherwise, false. - protected override void Dispose(bool disposing) - { - if (disposing && (components != null)) - { - components.Dispose(); - } - base.Dispose(disposing); - } - - #region Windows Form Designer generated code - /// - /// Required method for Designer support - do not modify - /// the contents of this method with the code editor. - /// - private void InitializeComponent() - { - this.components = new System.ComponentModel.Container(); - System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(DummyDoc)); - this.mainMenu = new System.Windows.Forms.MenuStrip(); - this.menuItem1 = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItem2 = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemCheckTest = new System.Windows.Forms.ToolStripMenuItem(); - this.contextMenuTabPage = new System.Windows.Forms.ContextMenuStrip(this.components); - this.menuItem3 = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItem4 = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItem5 = new System.Windows.Forms.ToolStripMenuItem(); - this.toolTip = new System.Windows.Forms.ToolTip(this.components); - this.richTextBox1 = new System.Windows.Forms.RichTextBox(); - this.mainMenu.SuspendLayout(); - this.contextMenuTabPage.SuspendLayout(); - this.SuspendLayout(); - // - // mainMenu - // - this.mainMenu.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.menuItem1}); - this.mainMenu.Location = new System.Drawing.Point(0, 4); - this.mainMenu.Name = "mainMenu"; - this.mainMenu.Size = new System.Drawing.Size(448, 24); - this.mainMenu.TabIndex = 1; - this.mainMenu.Visible = false; - // - // menuItem1 - // - this.menuItem1.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.menuItem2, - this.menuItemCheckTest}); - this.menuItem1.MergeAction = System.Windows.Forms.MergeAction.Insert; - this.menuItem1.MergeIndex = 1; - this.menuItem1.Name = "menuItem1"; - this.menuItem1.Size = new System.Drawing.Size(89, 20); - this.menuItem1.Text = "&MDI Document"; - // - // menuItem2 - // - this.menuItem2.Name = "menuItem2"; - this.menuItem2.Size = new System.Drawing.Size(127, 22); - this.menuItem2.Text = "Test"; - this.menuItem2.Click += new System.EventHandler(this.menuItem2_Click); - // - // menuItemCheckTest - // - this.menuItemCheckTest.Name = "menuItemCheckTest"; - this.menuItemCheckTest.Size = new System.Drawing.Size(127, 22); - this.menuItemCheckTest.Text = "Check Test"; - this.menuItemCheckTest.Click += new System.EventHandler(this.menuItemCheckTest_Click); - // - // contextMenuTabPage - // - this.contextMenuTabPage.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.menuItem3, - this.menuItem4, - this.menuItem5}); - this.contextMenuTabPage.Name = "contextMenuTabPage"; - this.contextMenuTabPage.Size = new System.Drawing.Size(116, 70); - // - // menuItem3 - // - this.menuItem3.Name = "menuItem3"; - this.menuItem3.Size = new System.Drawing.Size(115, 22); - this.menuItem3.Text = "Option &1"; - // - // menuItem4 - // - this.menuItem4.Name = "menuItem4"; - this.menuItem4.Size = new System.Drawing.Size(115, 22); - this.menuItem4.Text = "Option &2"; - // - // menuItem5 - // - this.menuItem5.Name = "menuItem5"; - this.menuItem5.Size = new System.Drawing.Size(115, 22); - this.menuItem5.Text = "Option &3"; - // - // richTextBox1 - // - this.richTextBox1.Dock = System.Windows.Forms.DockStyle.Fill; - this.richTextBox1.Location = new System.Drawing.Point(0, 4); - this.richTextBox1.Name = "richTextBox1"; - this.richTextBox1.Size = new System.Drawing.Size(448, 389); - this.richTextBox1.TabIndex = 2; - this.richTextBox1.Text = ""; - // - // DummyDoc - // - this.ClientSize = new System.Drawing.Size(448, 393); - this.Controls.Add(this.richTextBox1); - this.Controls.Add(this.mainMenu); - this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); - this.MainMenuStrip = this.mainMenu; - this.Name = "DummyDoc"; - this.Padding = new System.Windows.Forms.Padding(0, 4, 0, 0); - this.TabPageContextMenuStrip = this.contextMenuTabPage; - this.mainMenu.ResumeLayout(false); - this.mainMenu.PerformLayout(); - this.contextMenuTabPage.ResumeLayout(false); - this.ResumeLayout(false); - this.PerformLayout(); - - } - #endregion - - private System.Windows.Forms.MenuStrip mainMenu; - private System.Windows.Forms.ToolStripMenuItem menuItem1; - private System.Windows.Forms.ToolStripMenuItem menuItem2; - private System.Windows.Forms.ContextMenuStrip contextMenuTabPage; - private System.Windows.Forms.ToolStripMenuItem menuItem3; - private System.Windows.Forms.ToolStripMenuItem menuItem4; - private System.Windows.Forms.ToolStripMenuItem menuItem5; - private System.Windows.Forms.ToolStripMenuItem menuItemCheckTest; - private System.Windows.Forms.ToolTip toolTip; - private System.Windows.Forms.RichTextBox richTextBox1; - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/DummyDoc.cs b/src/Libraries/DockPanel_Src/DockSample/DummyDoc.cs deleted file mode 100644 index 193d7357f9..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/DummyDoc.cs +++ /dev/null @@ -1,83 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel; -using System.Data; -using System.Drawing; -using System.Text; -using System.Windows.Forms; -using WeifenLuo.WinFormsUI.Docking; -using System.IO; - -namespace DockSample -{ - public partial class DummyDoc : DockContent - { - public DummyDoc() - { - InitializeComponent(); - } - - private string m_fileName = string.Empty; - public string FileName - { - get { return m_fileName; } - set - { - if (value != string.Empty) - { - Stream s = new FileStream(value, FileMode.Open); - - FileInfo efInfo = new FileInfo(value); - - string fext = efInfo.Extension.ToUpper(); - - if (fext.Equals(".RTF")) - richTextBox1.LoadFile(s, RichTextBoxStreamType.RichText); - else - richTextBox1.LoadFile(s, RichTextBoxStreamType.PlainText); - s.Close(); - } - - m_fileName = value; - this.ToolTipText = value; - } - } - - // workaround of RichTextbox control's bug: - // If load file before the control showed, all the text format will be lost - // re-load the file after it get showed. - private bool m_resetText = true; - protected override void OnPaint(PaintEventArgs e) - { - base.OnPaint(e); - - if (m_resetText) - { - m_resetText = false; - FileName = FileName; - } - } - - protected override string GetPersistString() - { - return GetType().ToString() + "," + FileName + "," + Text; - } - - private void menuItem2_Click(object sender, System.EventArgs e) - { - MessageBox.Show("This is to demostrate menu item has been successfully merged into the main form. Form Text=" + Text); - } - - private void menuItemCheckTest_Click(object sender, System.EventArgs e) - { - menuItemCheckTest.Checked = !menuItemCheckTest.Checked; - } - - protected override void OnTextChanged(EventArgs e) - { - base.OnTextChanged (e); - if (FileName == string.Empty) - this.richTextBox1.Text = Text; - } - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/DummyDoc.resx b/src/Libraries/DockPanel_Src/DockSample/DummyDoc.resx deleted file mode 100644 index a7b68f4a21..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/DummyDoc.resx +++ /dev/null @@ -1,140 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 261, 17 - - - 102, 17 - - - 17, 17 - - - - - AAABAAEAEBAQAAAAAAAoAQAAFgAAACgAAAAQAAAAIAAAAAEABAAAAAAAgAAAAAAAAAAAAAAAEAAAABAA - AAAAAAAAAACAAACAAAAAgIAAgAAAAIAAgACAgAAAgICAAMDAwAAAAP8AAP8AAAD//wD/AAAA/wD/AP// - AAD///8AAAAAAAAAAAAAeIiIiIiIAAB///////gAAH+IiIiI+AAAf//////4AAB/iIiIiPgAAH////// - +AAAf4iIiIj4AAB///////gAAH+IiIiI+AAAf/////+IAAB/iIiI8AAAAH/////3BwAAf/////dwAAB3 - d3d3dwAAAAAAAAAAAADAAQAAwAEAAMABAADAAQAAwAEAAMABAADAAQAAwAEAAMABAADAAQAAwAEAAMAB - AADACwAAwAcAAMAPAAD//wAA - - - \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/DummyOutputWindow.Designer.cs b/src/Libraries/DockPanel_Src/DockSample/DummyOutputWindow.Designer.cs deleted file mode 100644 index a543d0d65b..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/DummyOutputWindow.Designer.cs +++ /dev/null @@ -1,83 +0,0 @@ -namespace DockSample -{ - partial class DummyOutputWindow - { - /// - /// Required designer variable. - /// - private System.ComponentModel.IContainer components = null; - - /// - /// Clean up any resources being used. - /// - /// true if managed resources should be disposed; otherwise, false. - protected override void Dispose(bool disposing) - { - if (disposing && (components != null)) - { - components.Dispose(); - } - base.Dispose(disposing); - } - - #region Windows Form Designer generated code - /// - /// Required method for Designer support - do not modify - /// the contents of this method with the code editor. - /// - private void InitializeComponent() - { - System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(DummyOutputWindow)); - this.comboBox = new System.Windows.Forms.ComboBox(); - this.textBox1 = new System.Windows.Forms.TextBox(); - this.SuspendLayout(); - // - // comboBox - // - this.comboBox.Dock = System.Windows.Forms.DockStyle.Top; - this.comboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; - this.comboBox.Items.AddRange(new object[] { - "Build"}); - this.comboBox.Location = new System.Drawing.Point(0, 2); - this.comboBox.Name = "comboBox"; - this.comboBox.Size = new System.Drawing.Size(255, 21); - this.comboBox.TabIndex = 1; - // - // textBox1 - // - this.textBox1.Dock = System.Windows.Forms.DockStyle.Fill; - this.textBox1.Location = new System.Drawing.Point(0, 23); - this.textBox1.Multiline = true; - this.textBox1.Name = "textBox1"; - this.textBox1.ScrollBars = System.Windows.Forms.ScrollBars.Both; - this.textBox1.Size = new System.Drawing.Size(255, 340); - this.textBox1.TabIndex = 2; - this.textBox1.Text = resources.GetString("textBox1.Text"); - this.textBox1.WordWrap = false; - // - // DummyOutputWindow - // - this.ClientSize = new System.Drawing.Size(255, 365); - this.Controls.Add(this.textBox1); - this.Controls.Add(this.comboBox); - this.DockAreas = ((WeifenLuo.WinFormsUI.Docking.DockAreas)(((((WeifenLuo.WinFormsUI.Docking.DockAreas.Float | WeifenLuo.WinFormsUI.Docking.DockAreas.DockLeft) - | WeifenLuo.WinFormsUI.Docking.DockAreas.DockRight) - | WeifenLuo.WinFormsUI.Docking.DockAreas.DockTop) - | WeifenLuo.WinFormsUI.Docking.DockAreas.DockBottom))); - this.HideOnClose = true; - this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); - this.Name = "DummyOutputWindow"; - this.Padding = new System.Windows.Forms.Padding(0, 2, 0, 2); - this.ShowHint = WeifenLuo.WinFormsUI.Docking.DockState.DockBottomAutoHide; - this.TabText = "Output"; - this.Text = "Output"; - this.ResumeLayout(false); - this.PerformLayout(); - - } - #endregion - - private System.Windows.Forms.ComboBox comboBox; - private System.Windows.Forms.TextBox textBox1; - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/DummyOutputWindow.cs b/src/Libraries/DockPanel_Src/DockSample/DummyOutputWindow.cs deleted file mode 100644 index 51dfee8317..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/DummyOutputWindow.cs +++ /dev/null @@ -1,19 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel; -using System.Data; -using System.Drawing; -using System.Text; -using System.Windows.Forms; -using WeifenLuo.WinFormsUI.Docking; - -namespace DockSample -{ - public partial class DummyOutputWindow : ToolWindow - { - public DummyOutputWindow() - { - InitializeComponent(); - } - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/DummyOutputWindow.resx b/src/Libraries/DockPanel_Src/DockSample/DummyOutputWindow.resx deleted file mode 100644 index bb68f5893a..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/DummyOutputWindow.resx +++ /dev/null @@ -1,167 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - ------ Build started: Project: WeifenLuo.WinFormsUI.Docking, Configuration: Debug .NET ------ - -Preparing resources... -Updating references... -Performing main compilation... - -Build complete -- 0 errors, 0 warnings -Building satellite assemblies... - - - ------- Build started: Project: DockSample, Configuration: Debug .NET ------ - -Preparing resources... -Updating references... -Performing main compilation... - -Build complete -- 0 errors, 0 warnings -Building satellite assemblies... - - - ----------------------- Done ---------------------- - - Build: 2 succeeded, 0 failed, 0 skipped - - - - - - - AAABAAEAICAQAAAAAADoAgAAFgAAACgAAAAgAAAAQAAAAAEABAAAAAAAAAIAAAAAAAAAAAAAEAAAABAA - AAAAAAAAAACAAACAAAAAgIAAgAAAAIAAgACAgAAAgICAAMDAwAAAAP8AAP8AAAD//wD/AAAA/wD/AP// - AAD///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA - AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA/////////////wAAAAAA - AP////////////8AAAAAAAD/d3d3d3d3d///AAAAAAAA/3d3d3d3d3f//wAAAAAAAP////////////8A - AAAAAAD/////////////AAAAAAAA/3d3d3d3d3d3/wAAAAAAAP93d3d3d3d3d/8AAAAAAAD///////// - ////AAAAAAAA/////////////wAAAAAAAP8AAAAAAAAA//8AAAAAAAD/AAAAAAAAAP//AAAAAAAA//// - /////////wAAAAAAAP////////////8AAAAAAAD/d3d3d3d3d3f/AAAAAAAA/3d3d3d3d3d3/wAAAAAA - AP////////////8AAAAAAAD/////////////AAAAAABEREREREREREREREQAAAAARERERERERERERERE - AAAAAERERERERERERERERAAAAABEREREREREREREREQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA - AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAD/////////////////////8AAAD/AA - AA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AA - AA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP/////////////////////w== - - - \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/DummyPropertyWindow.Designer.cs b/src/Libraries/DockPanel_Src/DockSample/DummyPropertyWindow.Designer.cs deleted file mode 100644 index 7bcb62b7df..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/DummyPropertyWindow.Designer.cs +++ /dev/null @@ -1,95 +0,0 @@ -namespace DockSample -{ - partial class DummyPropertyWindow - { - /// - /// Required designer variable. - /// - private System.ComponentModel.IContainer components = null; - - /// - /// Clean up any resources being used. - /// - /// true if managed resources should be disposed; otherwise, false. - protected override void Dispose(bool disposing) - { - if (disposing && (components != null)) - { - components.Dispose(); - } - base.Dispose(disposing); - } - - #region Windows Form Designer generated code - /// - /// Required method for Designer support - do not modify - /// the contents of this method with the code editor. - /// - private void InitializeComponent() - { - this.components = new System.ComponentModel.Container(); - System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(DummyPropertyWindow)); - this.propertyGrid = new System.Windows.Forms.PropertyGrid(); - this.comboBox = new System.Windows.Forms.ComboBox(); - this.mainMenu1 = new System.Windows.Forms.MainMenu(this.components); - this.menuItem1 = new System.Windows.Forms.MenuItem(); - this.SuspendLayout(); - // - // propertyGrid - // - this.propertyGrid.Dock = System.Windows.Forms.DockStyle.Fill; - this.propertyGrid.LineColor = System.Drawing.SystemColors.ScrollBar; - this.propertyGrid.Location = new System.Drawing.Point(0, 3); - this.propertyGrid.Name = "propertyGrid"; - this.propertyGrid.Size = new System.Drawing.Size(208, 283); - this.propertyGrid.TabIndex = 0; - // - // comboBox - // - this.comboBox.Dock = System.Windows.Forms.DockStyle.Top; - this.comboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList; - this.comboBox.Items.AddRange(new object[] { - "propertyGrid"}); - this.comboBox.Location = new System.Drawing.Point(0, 3); - this.comboBox.Name = "comboBox"; - this.comboBox.Size = new System.Drawing.Size(208, 21); - this.comboBox.TabIndex = 1; - // - // mainMenu1 - // - this.mainMenu1.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] { - this.menuItem1}); - // - // menuItem1 - // - this.menuItem1.Index = 0; - this.menuItem1.Text = "File"; - // - // DummyPropertyWindow - // - this.ClientSize = new System.Drawing.Size(208, 289); - this.Controls.Add(this.comboBox); - this.Controls.Add(this.propertyGrid); - this.DockAreas = ((WeifenLuo.WinFormsUI.Docking.DockAreas)(((((WeifenLuo.WinFormsUI.Docking.DockAreas.Float | WeifenLuo.WinFormsUI.Docking.DockAreas.DockLeft) - | WeifenLuo.WinFormsUI.Docking.DockAreas.DockRight) - | WeifenLuo.WinFormsUI.Docking.DockAreas.DockTop) - | WeifenLuo.WinFormsUI.Docking.DockAreas.DockBottom))); - this.HideOnClose = true; - this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); - this.Menu = this.mainMenu1; - this.Name = "DummyPropertyWindow"; - this.Padding = new System.Windows.Forms.Padding(0, 3, 0, 3); - this.ShowHint = WeifenLuo.WinFormsUI.Docking.DockState.DockRight; - this.TabText = "Properties"; - this.Text = "Properties"; - this.ResumeLayout(false); - - } - #endregion - - private System.Windows.Forms.PropertyGrid propertyGrid; - private System.Windows.Forms.ComboBox comboBox; - private System.Windows.Forms.MainMenu mainMenu1; - private System.Windows.Forms.MenuItem menuItem1; - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/DummyPropertyWindow.cs b/src/Libraries/DockPanel_Src/DockSample/DummyPropertyWindow.cs deleted file mode 100644 index 0c69557916..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/DummyPropertyWindow.cs +++ /dev/null @@ -1,21 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel; -using System.Data; -using System.Drawing; -using System.Text; -using System.Windows.Forms; -using WeifenLuo.WinFormsUI.Docking; - -namespace DockSample -{ - public partial class DummyPropertyWindow : ToolWindow - { - public DummyPropertyWindow() - { - InitializeComponent(); - comboBox.SelectedIndex = 0; - propertyGrid.SelectedObject = propertyGrid; - } - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/DummyPropertyWindow.resx b/src/Libraries/DockPanel_Src/DockSample/DummyPropertyWindow.resx deleted file mode 100644 index 35aa996be5..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/DummyPropertyWindow.resx +++ /dev/null @@ -1,141 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 17, 17 - - - - - AAABAAEAICAQAAAAAADoAgAAFgAAACgAAAAgAAAAQAAAAAEABAAAAAAAAAIAAAAAAAAAAAAAEAAAABAA - AAAAAAAAAACAAACAAAAAgIAAgAAAAIAAgACAgAAAgICAAMDAwAAAAP8AAP8AAAD//wD/AAAA/wD/AP// - AAD///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA - AAAAAAAAAAAAAAD/////////////AAAAAAAA/////////////wAAAAAAAP8AAP8AAAAAAP8AAAAAAAD/ - AAD/AAAAAAD/AAAAAAAA/////////////wAAAAAAAP////////////8AAAAAAAD/AAD/AAAAAAD/AAAA - AAAA/wAA/wAAAAAA/wAAAAAAAP////////////8AAAAAAAD/////////////AAAAAAAA//8AAP///wD/ - /wAAAAAAAP//AAD///8A//8AAAAAAAD//wAAAP8AAAD/AAAAAEQA//8AAAD/AAAA/wAAAABEAP///wAA - AAAAAAAAAABERAD///8AAAAAAAAAAAAAREQAAAAAAAAAAAAAAAAAAEREAAAAAAAAAAAAAAAAAABERAAA - AAAAAAAAAAAAAAAAREQAAAAAAAAAAAAAAAAAAEREAAAAAAAAAAAAAAAAAABERAAAAAAAAAAAAAAAAAAA - REQAAAAAAAAAAAAAAAAAAEREAAAAAAAAAAAAAAAAAABERAAAAAAAAAAAAAAAAAAAREQAAAAAAAAAAAAA - AAAAAEREAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAD//////////wAAAP8AAAD/AAAA/wAA - AP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AMDA/ADAwPwAMzAwADMwMAAM - z8AADM/A//M/8P/zP/D//P/w//z/8P//AAD//wAA////8P////D//////////w== - - - \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/DummySolutionExplorer.Designer.cs b/src/Libraries/DockPanel_Src/DockSample/DummySolutionExplorer.Designer.cs deleted file mode 100644 index 66abaa2bf2..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/DummySolutionExplorer.Designer.cs +++ /dev/null @@ -1,462 +0,0 @@ -namespace DockSample -{ - partial class DummySolutionExplorer - { - /// - /// Required designer variable. - /// - private System.ComponentModel.IContainer components = null; - - /// - /// Clean up any resources being used. - /// - /// true if managed resources should be disposed; otherwise, false. - protected override void Dispose(bool disposing) - { - if (disposing && (components != null)) - { - components.Dispose(); - } - base.Dispose(disposing); - } - - #region Windows Form Designer generated code - /// - /// Required method for Designer support - do not modify - /// the contents of this method with the code editor. - /// - private void InitializeComponent() - { - this.components = new System.ComponentModel.Container(); - System.Windows.Forms.TreeNode treeNode1 = new System.Windows.Forms.TreeNode("Solution \'WinFormsUI\' (2 projects)"); - System.Windows.Forms.TreeNode treeNode2 = new System.Windows.Forms.TreeNode("System", 6, 6); - System.Windows.Forms.TreeNode treeNode3 = new System.Windows.Forms.TreeNode("System.Data", 6, 6); - System.Windows.Forms.TreeNode treeNode4 = new System.Windows.Forms.TreeNode("System.Drawing", 6, 6); - System.Windows.Forms.TreeNode treeNode5 = new System.Windows.Forms.TreeNode("System.Windows.Forms", 6, 6); - System.Windows.Forms.TreeNode treeNode6 = new System.Windows.Forms.TreeNode("System.XML", 6, 6); - System.Windows.Forms.TreeNode treeNode7 = new System.Windows.Forms.TreeNode("WeifenLuo.WinFormsUI.Docking", 6, 6); - System.Windows.Forms.TreeNode treeNode8 = new System.Windows.Forms.TreeNode("References", 4, 4, new System.Windows.Forms.TreeNode[] { - treeNode2, - treeNode3, - treeNode4, - treeNode5, - treeNode6, - treeNode7}); - System.Windows.Forms.TreeNode treeNode9 = new System.Windows.Forms.TreeNode("BlankIcon.ico", 5, 5); - System.Windows.Forms.TreeNode treeNode10 = new System.Windows.Forms.TreeNode("CSProject.ico", 5, 5); - System.Windows.Forms.TreeNode treeNode11 = new System.Windows.Forms.TreeNode("OutputWindow.ico", 5, 5); - System.Windows.Forms.TreeNode treeNode12 = new System.Windows.Forms.TreeNode("References.ico", 5, 5); - System.Windows.Forms.TreeNode treeNode13 = new System.Windows.Forms.TreeNode("SolutionExplorer.ico", 5, 5); - System.Windows.Forms.TreeNode treeNode14 = new System.Windows.Forms.TreeNode("TaskListWindow.ico", 5, 5); - System.Windows.Forms.TreeNode treeNode15 = new System.Windows.Forms.TreeNode("ToolboxWindow.ico", 5, 5); - System.Windows.Forms.TreeNode treeNode16 = new System.Windows.Forms.TreeNode("Images", 2, 1, new System.Windows.Forms.TreeNode[] { - treeNode9, - treeNode10, - treeNode11, - treeNode12, - treeNode13, - treeNode14, - treeNode15}); - System.Windows.Forms.TreeNode treeNode17 = new System.Windows.Forms.TreeNode("AboutDialog.cs", 8, 8); - System.Windows.Forms.TreeNode treeNode18 = new System.Windows.Forms.TreeNode("App.ico", 5, 5); - System.Windows.Forms.TreeNode treeNode19 = new System.Windows.Forms.TreeNode("AssemblyInfo.cs", 7, 7); - System.Windows.Forms.TreeNode treeNode20 = new System.Windows.Forms.TreeNode("DummyOutputWindow.cs", 8, 8); - System.Windows.Forms.TreeNode treeNode21 = new System.Windows.Forms.TreeNode("DummyPropertyWindow.cs", 8, 8); - System.Windows.Forms.TreeNode treeNode22 = new System.Windows.Forms.TreeNode("DummySolutionExplorer.cs", 8, 8); - System.Windows.Forms.TreeNode treeNode23 = new System.Windows.Forms.TreeNode("DummyTaskList.cs", 8, 8); - System.Windows.Forms.TreeNode treeNode24 = new System.Windows.Forms.TreeNode("DummyToolbox.cs", 8, 8); - System.Windows.Forms.TreeNode treeNode25 = new System.Windows.Forms.TreeNode("MianForm.cs", 8, 8); - System.Windows.Forms.TreeNode treeNode26 = new System.Windows.Forms.TreeNode("Options.cs", 7, 7); - System.Windows.Forms.TreeNode treeNode27 = new System.Windows.Forms.TreeNode("OptionsDialog.cs", 8, 8); - System.Windows.Forms.TreeNode treeNode28 = new System.Windows.Forms.TreeNode("DockSample", 3, 3, new System.Windows.Forms.TreeNode[] { - treeNode8, - treeNode16, - treeNode17, - treeNode18, - treeNode19, - treeNode20, - treeNode21, - treeNode22, - treeNode23, - treeNode24, - treeNode25, - treeNode26, - treeNode27}); - System.Windows.Forms.TreeNode treeNode29 = new System.Windows.Forms.TreeNode("System", 6, 6); - System.Windows.Forms.TreeNode treeNode30 = new System.Windows.Forms.TreeNode("System.Data", 6, 6); - System.Windows.Forms.TreeNode treeNode31 = new System.Windows.Forms.TreeNode("System.Design", 6, 6); - System.Windows.Forms.TreeNode treeNode32 = new System.Windows.Forms.TreeNode("System.Drawing", 6, 6); - System.Windows.Forms.TreeNode treeNode33 = new System.Windows.Forms.TreeNode("System.Windows.Forms", 6, 6); - System.Windows.Forms.TreeNode treeNode34 = new System.Windows.Forms.TreeNode("System.XML", 6, 6); - System.Windows.Forms.TreeNode treeNode35 = new System.Windows.Forms.TreeNode("References", 4, 4, new System.Windows.Forms.TreeNode[] { - treeNode29, - treeNode30, - treeNode31, - treeNode32, - treeNode33, - treeNode34}); - System.Windows.Forms.TreeNode treeNode36 = new System.Windows.Forms.TreeNode("DockWindow.AutoHideNo.bmp", 9, 9); - System.Windows.Forms.TreeNode treeNode37 = new System.Windows.Forms.TreeNode("DockWindow.AutoHideYes.bmp", 9, 9); - System.Windows.Forms.TreeNode treeNode38 = new System.Windows.Forms.TreeNode("DockWindow.Close.bmp", 9, 9); - System.Windows.Forms.TreeNode treeNode39 = new System.Windows.Forms.TreeNode("DocumentWindow.Close.bmp", 9, 9); - System.Windows.Forms.TreeNode treeNode40 = new System.Windows.Forms.TreeNode("DocumentWindow.ScrollLeftDisabled.bmp", 9, 9); - System.Windows.Forms.TreeNode treeNode41 = new System.Windows.Forms.TreeNode("DocumentWindow.ScrollLeftEnabled.bmp", 9, 9); - System.Windows.Forms.TreeNode treeNode42 = new System.Windows.Forms.TreeNode("DocumentWindow.ScrollRightDisabled.bmp", 9, 9); - System.Windows.Forms.TreeNode treeNode43 = new System.Windows.Forms.TreeNode("DocumentWindow.ScrollRightEnabled.bmp", 9, 9); - System.Windows.Forms.TreeNode treeNode44 = new System.Windows.Forms.TreeNode("Resources", 2, 1, new System.Windows.Forms.TreeNode[] { - treeNode36, - treeNode37, - treeNode38, - treeNode39, - treeNode40, - treeNode41, - treeNode42, - treeNode43}); - System.Windows.Forms.TreeNode treeNode45 = new System.Windows.Forms.TreeNode("Enums.cs", 7, 7); - System.Windows.Forms.TreeNode treeNode46 = new System.Windows.Forms.TreeNode("Gdi32.cs", 7, 3); - System.Windows.Forms.TreeNode treeNode47 = new System.Windows.Forms.TreeNode("Structs.cs", 7, 7); - System.Windows.Forms.TreeNode treeNode48 = new System.Windows.Forms.TreeNode("User32.cs", 7, 7); - System.Windows.Forms.TreeNode treeNode49 = new System.Windows.Forms.TreeNode("Win32", 2, 1, new System.Windows.Forms.TreeNode[] { - treeNode45, - treeNode46, - treeNode47, - treeNode48}); - System.Windows.Forms.TreeNode treeNode50 = new System.Windows.Forms.TreeNode("AssemblyInfo.cs", 7, 7); - System.Windows.Forms.TreeNode treeNode51 = new System.Windows.Forms.TreeNode("Content.cs", 8, 8); - System.Windows.Forms.TreeNode treeNode52 = new System.Windows.Forms.TreeNode("CotentCollection.cs", 7, 7); - System.Windows.Forms.TreeNode treeNode53 = new System.Windows.Forms.TreeNode("CotentWindowCollection.cs", 7, 7); - System.Windows.Forms.TreeNode treeNode54 = new System.Windows.Forms.TreeNode("DockHelper.cs", 7, 7); - System.Windows.Forms.TreeNode treeNode55 = new System.Windows.Forms.TreeNode("DragHandler.cs", 7, 7); - System.Windows.Forms.TreeNode treeNode56 = new System.Windows.Forms.TreeNode("DragHandlerBase.cs", 7, 7); - System.Windows.Forms.TreeNode treeNode57 = new System.Windows.Forms.TreeNode("FloatWindow.cs", 8, 8); - System.Windows.Forms.TreeNode treeNode58 = new System.Windows.Forms.TreeNode("HiddenMdiChild.cs", 8, 8); - System.Windows.Forms.TreeNode treeNode59 = new System.Windows.Forms.TreeNode("InertButton.cs", 7, 7); - System.Windows.Forms.TreeNode treeNode60 = new System.Windows.Forms.TreeNode("Measures.cs", 7, 7); - System.Windows.Forms.TreeNode treeNode61 = new System.Windows.Forms.TreeNode("NormalTabStripWindow.cs", 8, 8); - System.Windows.Forms.TreeNode treeNode62 = new System.Windows.Forms.TreeNode("ResourceHelper.cs", 7, 7); - System.Windows.Forms.TreeNode treeNode63 = new System.Windows.Forms.TreeNode("WeifenLuo.WinFormsUI.Docking", 3, 3, new System.Windows.Forms.TreeNode[] { - treeNode35, - treeNode44, - treeNode49, - treeNode50, - treeNode51, - treeNode52, - treeNode53, - treeNode54, - treeNode55, - treeNode56, - treeNode57, - treeNode58, - treeNode59, - treeNode60, - treeNode61, - treeNode62}); - System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(DummySolutionExplorer)); - this.treeView1 = new System.Windows.Forms.TreeView(); - this.imageList1 = new System.Windows.Forms.ImageList(this.components); - this.SuspendLayout(); - // - // treeView1 - // - this.treeView1.Dock = System.Windows.Forms.DockStyle.Fill; - this.treeView1.ImageIndex = 0; - this.treeView1.ImageList = this.imageList1; - this.treeView1.Indent = 19; - this.treeView1.Location = new System.Drawing.Point(0, 24); - this.treeView1.Name = "treeView1"; - treeNode1.Name = ""; - treeNode1.Text = "Solution \'WinFormsUI\' (2 projects)"; - treeNode2.ImageIndex = 6; - treeNode2.Name = ""; - treeNode2.SelectedImageIndex = 6; - treeNode2.Text = "System"; - treeNode3.ImageIndex = 6; - treeNode3.Name = ""; - treeNode3.SelectedImageIndex = 6; - treeNode3.Text = "System.Data"; - treeNode4.ImageIndex = 6; - treeNode4.Name = ""; - treeNode4.SelectedImageIndex = 6; - treeNode4.Text = "System.Drawing"; - treeNode5.ImageIndex = 6; - treeNode5.Name = ""; - treeNode5.SelectedImageIndex = 6; - treeNode5.Text = "System.Windows.Forms"; - treeNode6.ImageIndex = 6; - treeNode6.Name = ""; - treeNode6.SelectedImageIndex = 6; - treeNode6.Text = "System.XML"; - treeNode7.ImageIndex = 6; - treeNode7.Name = ""; - treeNode7.SelectedImageIndex = 6; - treeNode7.Text = "WeifenLuo.WinFormsUI.Docking"; - treeNode8.ImageIndex = 4; - treeNode8.Name = ""; - treeNode8.SelectedImageIndex = 4; - treeNode8.Text = "References"; - treeNode9.ImageIndex = 5; - treeNode9.Name = ""; - treeNode9.SelectedImageIndex = 5; - treeNode9.Text = "BlankIcon.ico"; - treeNode10.ImageIndex = 5; - treeNode10.Name = ""; - treeNode10.SelectedImageIndex = 5; - treeNode10.Text = "CSProject.ico"; - treeNode11.ImageIndex = 5; - treeNode11.Name = ""; - treeNode11.SelectedImageIndex = 5; - treeNode11.Text = "OutputWindow.ico"; - treeNode12.ImageIndex = 5; - treeNode12.Name = ""; - treeNode12.SelectedImageIndex = 5; - treeNode12.Text = "References.ico"; - treeNode13.ImageIndex = 5; - treeNode13.Name = ""; - treeNode13.SelectedImageIndex = 5; - treeNode13.Text = "SolutionExplorer.ico"; - treeNode14.ImageIndex = 5; - treeNode14.Name = ""; - treeNode14.SelectedImageIndex = 5; - treeNode14.Text = "TaskListWindow.ico"; - treeNode15.ImageIndex = 5; - treeNode15.Name = ""; - treeNode15.SelectedImageIndex = 5; - treeNode15.Text = "ToolboxWindow.ico"; - treeNode16.ImageIndex = 2; - treeNode16.Name = ""; - treeNode16.SelectedImageIndex = 1; - treeNode16.Text = "Images"; - treeNode17.ImageIndex = 8; - treeNode17.Name = ""; - treeNode17.SelectedImageIndex = 8; - treeNode17.Text = "AboutDialog.cs"; - treeNode18.ImageIndex = 5; - treeNode18.Name = ""; - treeNode18.SelectedImageIndex = 5; - treeNode18.Text = "App.ico"; - treeNode19.ImageIndex = 7; - treeNode19.Name = ""; - treeNode19.SelectedImageIndex = 7; - treeNode19.Text = "AssemblyInfo.cs"; - treeNode20.ImageIndex = 8; - treeNode20.Name = ""; - treeNode20.SelectedImageIndex = 8; - treeNode20.Text = "DummyOutputWindow.cs"; - treeNode21.ImageIndex = 8; - treeNode21.Name = ""; - treeNode21.SelectedImageIndex = 8; - treeNode21.Text = "DummyPropertyWindow.cs"; - treeNode22.ImageIndex = 8; - treeNode22.Name = ""; - treeNode22.SelectedImageIndex = 8; - treeNode22.Text = "DummySolutionExplorer.cs"; - treeNode23.ImageIndex = 8; - treeNode23.Name = ""; - treeNode23.SelectedImageIndex = 8; - treeNode23.Text = "DummyTaskList.cs"; - treeNode24.ImageIndex = 8; - treeNode24.Name = ""; - treeNode24.SelectedImageIndex = 8; - treeNode24.Text = "DummyToolbox.cs"; - treeNode25.ImageIndex = 8; - treeNode25.Name = ""; - treeNode25.SelectedImageIndex = 8; - treeNode25.Text = "MianForm.cs"; - treeNode26.ImageIndex = 7; - treeNode26.Name = ""; - treeNode26.SelectedImageIndex = 7; - treeNode26.Text = "Options.cs"; - treeNode27.ImageIndex = 8; - treeNode27.Name = ""; - treeNode27.SelectedImageIndex = 8; - treeNode27.Text = "OptionsDialog.cs"; - treeNode28.ImageIndex = 3; - treeNode28.Name = ""; - treeNode28.SelectedImageIndex = 3; - treeNode28.Text = "DockSample"; - treeNode29.ImageIndex = 6; - treeNode29.Name = ""; - treeNode29.SelectedImageIndex = 6; - treeNode29.Text = "System"; - treeNode30.ImageIndex = 6; - treeNode30.Name = ""; - treeNode30.SelectedImageIndex = 6; - treeNode30.Text = "System.Data"; - treeNode31.ImageIndex = 6; - treeNode31.Name = ""; - treeNode31.SelectedImageIndex = 6; - treeNode31.Text = "System.Design"; - treeNode32.ImageIndex = 6; - treeNode32.Name = ""; - treeNode32.SelectedImageIndex = 6; - treeNode32.Text = "System.Drawing"; - treeNode33.ImageIndex = 6; - treeNode33.Name = ""; - treeNode33.SelectedImageIndex = 6; - treeNode33.Text = "System.Windows.Forms"; - treeNode34.ImageIndex = 6; - treeNode34.Name = ""; - treeNode34.SelectedImageIndex = 6; - treeNode34.Text = "System.XML"; - treeNode35.ImageIndex = 4; - treeNode35.Name = ""; - treeNode35.SelectedImageIndex = 4; - treeNode35.Text = "References"; - treeNode36.ImageIndex = 9; - treeNode36.Name = ""; - treeNode36.SelectedImageIndex = 9; - treeNode36.Text = "DockWindow.AutoHideNo.bmp"; - treeNode37.ImageIndex = 9; - treeNode37.Name = ""; - treeNode37.SelectedImageIndex = 9; - treeNode37.Text = "DockWindow.AutoHideYes.bmp"; - treeNode38.ImageIndex = 9; - treeNode38.Name = ""; - treeNode38.SelectedImageIndex = 9; - treeNode38.Text = "DockWindow.Close.bmp"; - treeNode39.ImageIndex = 9; - treeNode39.Name = ""; - treeNode39.SelectedImageIndex = 9; - treeNode39.Text = "DocumentWindow.Close.bmp"; - treeNode40.ImageIndex = 9; - treeNode40.Name = ""; - treeNode40.SelectedImageIndex = 9; - treeNode40.Text = "DocumentWindow.ScrollLeftDisabled.bmp"; - treeNode41.ImageIndex = 9; - treeNode41.Name = ""; - treeNode41.SelectedImageIndex = 9; - treeNode41.Text = "DocumentWindow.ScrollLeftEnabled.bmp"; - treeNode42.ImageIndex = 9; - treeNode42.Name = ""; - treeNode42.SelectedImageIndex = 9; - treeNode42.Text = "DocumentWindow.ScrollRightDisabled.bmp"; - treeNode43.ImageIndex = 9; - treeNode43.Name = ""; - treeNode43.SelectedImageIndex = 9; - treeNode43.Text = "DocumentWindow.ScrollRightEnabled.bmp"; - treeNode44.ImageIndex = 2; - treeNode44.Name = ""; - treeNode44.SelectedImageIndex = 1; - treeNode44.Text = "Resources"; - treeNode45.ImageIndex = 7; - treeNode45.Name = ""; - treeNode45.SelectedImageIndex = 7; - treeNode45.Text = "Enums.cs"; - treeNode46.ImageIndex = 7; - treeNode46.Name = ""; - treeNode46.SelectedImageIndex = 3; - treeNode46.Text = "Gdi32.cs"; - treeNode47.ImageIndex = 7; - treeNode47.Name = ""; - treeNode47.SelectedImageIndex = 7; - treeNode47.Text = "Structs.cs"; - treeNode48.ImageIndex = 7; - treeNode48.Name = ""; - treeNode48.SelectedImageIndex = 7; - treeNode48.Text = "User32.cs"; - treeNode49.ImageIndex = 2; - treeNode49.Name = ""; - treeNode49.SelectedImageIndex = 1; - treeNode49.Text = "Win32"; - treeNode50.ImageIndex = 7; - treeNode50.Name = ""; - treeNode50.SelectedImageIndex = 7; - treeNode50.Text = "AssemblyInfo.cs"; - treeNode51.ImageIndex = 8; - treeNode51.Name = ""; - treeNode51.SelectedImageIndex = 8; - treeNode51.Text = "Content.cs"; - treeNode52.ImageIndex = 7; - treeNode52.Name = ""; - treeNode52.SelectedImageIndex = 7; - treeNode52.Text = "CotentCollection.cs"; - treeNode53.ImageIndex = 7; - treeNode53.Name = ""; - treeNode53.SelectedImageIndex = 7; - treeNode53.Text = "CotentWindowCollection.cs"; - treeNode54.ImageIndex = 7; - treeNode54.Name = ""; - treeNode54.SelectedImageIndex = 7; - treeNode54.Text = "DockHelper.cs"; - treeNode55.ImageIndex = 7; - treeNode55.Name = ""; - treeNode55.SelectedImageIndex = 7; - treeNode55.Text = "DragHandler.cs"; - treeNode56.ImageIndex = 7; - treeNode56.Name = ""; - treeNode56.SelectedImageIndex = 7; - treeNode56.Text = "DragHandlerBase.cs"; - treeNode57.ImageIndex = 8; - treeNode57.Name = ""; - treeNode57.SelectedImageIndex = 8; - treeNode57.Text = "FloatWindow.cs"; - treeNode58.ImageIndex = 8; - treeNode58.Name = ""; - treeNode58.SelectedImageIndex = 8; - treeNode58.Text = "HiddenMdiChild.cs"; - treeNode59.ImageIndex = 7; - treeNode59.Name = ""; - treeNode59.SelectedImageIndex = 7; - treeNode59.Text = "InertButton.cs"; - treeNode60.ImageIndex = 7; - treeNode60.Name = ""; - treeNode60.SelectedImageIndex = 7; - treeNode60.Text = "Measures.cs"; - treeNode61.ImageIndex = 8; - treeNode61.Name = ""; - treeNode61.SelectedImageIndex = 8; - treeNode61.Text = "NormalTabStripWindow.cs"; - treeNode62.ImageIndex = 7; - treeNode62.Name = ""; - treeNode62.SelectedImageIndex = 7; - treeNode62.Text = "ResourceHelper.cs"; - treeNode63.ImageIndex = 3; - treeNode63.Name = ""; - treeNode63.SelectedImageIndex = 3; - treeNode63.Text = "WeifenLuo.WinFormsUI.Docking"; - this.treeView1.Nodes.AddRange(new System.Windows.Forms.TreeNode[] { - treeNode1, - treeNode28, - treeNode63}); - this.treeView1.SelectedImageIndex = 0; - this.treeView1.Size = new System.Drawing.Size(245, 297); - this.treeView1.TabIndex = 0; - // - // imageList1 - // - this.imageList1.ImageStream = ((System.Windows.Forms.ImageListStreamer)(resources.GetObject("imageList1.ImageStream"))); - this.imageList1.TransparentColor = System.Drawing.Color.Transparent; - this.imageList1.Images.SetKeyName(0, ""); - this.imageList1.Images.SetKeyName(1, ""); - this.imageList1.Images.SetKeyName(2, ""); - this.imageList1.Images.SetKeyName(3, ""); - this.imageList1.Images.SetKeyName(4, ""); - this.imageList1.Images.SetKeyName(5, ""); - this.imageList1.Images.SetKeyName(6, ""); - this.imageList1.Images.SetKeyName(7, ""); - this.imageList1.Images.SetKeyName(8, ""); - this.imageList1.Images.SetKeyName(9, ""); - // - // DummySolutionExplorer - // - this.ClientSize = new System.Drawing.Size(245, 322); - this.Controls.Add(this.treeView1); - this.DockAreas = ((WeifenLuo.WinFormsUI.Docking.DockAreas)((((WeifenLuo.WinFormsUI.Docking.DockAreas.DockLeft | WeifenLuo.WinFormsUI.Docking.DockAreas.DockRight) - | WeifenLuo.WinFormsUI.Docking.DockAreas.DockTop) - | WeifenLuo.WinFormsUI.Docking.DockAreas.DockBottom))); - this.HideOnClose = true; - this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); - this.Name = "DummySolutionExplorer"; - this.Padding = new System.Windows.Forms.Padding(0, 24, 0, 1); - this.ShowHint = WeifenLuo.WinFormsUI.Docking.DockState.DockRight; - this.TabText = "Solution Explorer"; - this.Text = "Solution Explorer - WinFormsUI"; - this.ResumeLayout(false); - - } - #endregion - - private System.Windows.Forms.TreeView treeView1; - private System.Windows.Forms.ImageList imageList1; - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/DummySolutionExplorer.cs b/src/Libraries/DockPanel_Src/DockSample/DummySolutionExplorer.cs deleted file mode 100644 index f8b83d245d..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/DummySolutionExplorer.cs +++ /dev/null @@ -1,24 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel; -using System.Data; -using System.Drawing; -using System.Text; -using System.Windows.Forms; -using WeifenLuo.WinFormsUI.Docking; - -namespace DockSample -{ - public partial class DummySolutionExplorer : ToolWindow - { - public DummySolutionExplorer() - { - InitializeComponent(); - } - - protected override void OnRightToLeftLayoutChanged(EventArgs e) - { - treeView1.RightToLeftLayout = RightToLeftLayout; - } - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/DummySolutionExplorer.resx b/src/Libraries/DockPanel_Src/DockSample/DummySolutionExplorer.resx deleted file mode 100644 index d4b535f276..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/DummySolutionExplorer.resx +++ /dev/null @@ -1,220 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 23, 17 - - - - AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2lu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ATADAAEBAQABAQUAAYABARYAA/8BAAT/BAABgAEBAYABAQQAAYABAQGAAQEEAAGA - AQEBgAEBBAABgAEBAYABAQQAAYABAQGAAQEEAAGAAQEBgAEBBAABgAEBAYABAQQAAYABAQGAAQEEAAGA - AQEBgAEBBAABgAEBAYABAQQAAYABAQGAAQEEAAGAAQEBgAEBBAABgAEBAYABAQQAAv8BgAEBBAAE/wQA - Av8BwAEBAv8BwAEBAeABAAHAAQEC/wHAAQEBwAEAAcABAQL/AcABAQHAAQABwAEBAv8BwAEBAYABAAHA - AQEB/AEBAcABAQGDAsABAQH4AQABwAEBAgABwAEBAZgBAAHAAQECAAHAAQECAAHAAQECAAHAAQEBmAEA - AcABAQGAAQABwAEBAfgBAAHAAQEBgAEAAcABAQH4AQABwAEBAYABAQHAAQEB/AEBAcABAQHAAX8BwAEB - Av8BwAELAeAB/wHAAQMC/wHAAQcC/wHAAQcC/wHAAQ8C/wHAAQ8E/wIABP8BwAE/AgAE/wHAAT8CAAHg - AQABgAEBAQABPwIAAcACAAEBAQABPwIAAcACAAEBBAABgAIAAQEEAAGAAgABAQcAAQEHAAEBBwABAQQA - AYACAAEBBAABgAIAAQEBwAMAAYABAQEAAQMBwAMAAcABfwGAAf8BwAMAAeAB/wHBAf8BwAMABv8L - - - - - - AAABAAEAICAEAAAAAADoAgAAFgAAACgAAAAgAAAAQAAAAAEABAAAAAAAAAIAAAAAAAAAAAAAAAAAAAAA - AAAAAAAAAACAAACAAAAAgIAAgAAAAIAAgACAgAAAgICAAMDAwAAAAP8AAP8AAAD//wD/AAAA/wD/AP// - AAD///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA - QAAAAAAwAAAAAAAAAAAABMGZEAADiIgAAAAAAAAAAEzBmZEAP7u4AgAAAAAAAATMQZmZEIu7uAogAAAA - AAB0xAGZmZEIu7gKogAHiIiIgED/GZmZEIuACqoAB/j4+PIP//GZmZEID/KqAAf//4+CIP//GZmZEP// - KgAH//j48qIP84GZmZEP//IAB////4KqID+4GZmZEP9MAAf///jyqqD7u4GZmZEEzAAH////jyqg+7u4 - GZmRDMxAB/////jyoPu7gPGZkQzEAAf///+P/yD//w+PGZEMQAAH//////jzMzP4+PERBAAAB/////// - j4+Pj4+Pj4AAAAf///////j4+Pj4+PiAAAAH////////j4+Pj4+PgAAAB///////+P/4+Pj4+IAAAAf/ - ////////j/+Pj4+AAAAH///////////4+Pj4gAAAB////////////4+Pj4AAAAf///////////j4+PiA - AAAH//////////+Pj4+PgAAABEREREREREREREREREQAAAREREREREREREREREREAAAERERERERERERE - RERERAAABEREREREREREREREREQAAAAAAAAAAAAAAAAAAAAAAAD/////////////////8Hwf/+A4D//A - EAf/gAADgAAAAYAAAAGAAAABgAAAAYAAAAGAAAABgAAAAYAAAAGAAAADgAAAB4AAAA+AAAAPgAAAD4AA - AA+AAAAPgAAAD4AAAA+AAAAPgAAAD4AAAA+AAAAPgAAAD4AAAA+AAAAP/////w== - - - \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/DummyTaskList.Designer.cs b/src/Libraries/DockPanel_Src/DockSample/DummyTaskList.Designer.cs deleted file mode 100644 index 89ad51bb4f..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/DummyTaskList.Designer.cs +++ /dev/null @@ -1,111 +0,0 @@ -namespace DockSample -{ - partial class DummyTaskList - { - /// - /// Required designer variable. - /// - private System.ComponentModel.IContainer components = null; - - /// - /// Clean up any resources being used. - /// - /// true if managed resources should be disposed; otherwise, false. - protected override void Dispose(bool disposing) - { - if (disposing && (components != null)) - { - components.Dispose(); - } - base.Dispose(disposing); - } - - #region Windows Form Designer generated code - /// - /// Required method for Designer support - do not modify - /// the contents of this method with the code editor. - /// - private void InitializeComponent() - { - System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(DummyTaskList)); - this.listView1 = new System.Windows.Forms.ListView(); - this.columnHeader1 = new System.Windows.Forms.ColumnHeader(); - this.columnHeader2 = new System.Windows.Forms.ColumnHeader(); - this.columnHeader3 = new System.Windows.Forms.ColumnHeader(); - this.columnHeader4 = new System.Windows.Forms.ColumnHeader(); - this.columnHeader5 = new System.Windows.Forms.ColumnHeader(); - this.SuspendLayout(); - // - // listView1 - // - this.listView1.AllowColumnReorder = true; - this.listView1.AutoArrange = false; - this.listView1.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] { - this.columnHeader1, - this.columnHeader2, - this.columnHeader3, - this.columnHeader4, - this.columnHeader5}); - this.listView1.Dock = System.Windows.Forms.DockStyle.Fill; - this.listView1.FullRowSelect = true; - this.listView1.HideSelection = false; - this.listView1.Location = new System.Drawing.Point(0, 3); - this.listView1.MultiSelect = false; - this.listView1.Name = "listView1"; - this.listView1.Size = new System.Drawing.Size(337, 370); - this.listView1.TabIndex = 0; - this.listView1.UseCompatibleStateImageBehavior = false; - this.listView1.View = System.Windows.Forms.View.Details; - // - // columnHeader1 - // - this.columnHeader1.Text = "!"; - this.columnHeader1.Width = 16; - // - // columnHeader2 - // - this.columnHeader2.Text = ""; - this.columnHeader2.Width = 16; - // - // columnHeader3 - // - this.columnHeader3.Text = "Description"; - this.columnHeader3.Width = 300; - // - // columnHeader4 - // - this.columnHeader4.Text = "File"; - this.columnHeader4.Width = 150; - // - // columnHeader5 - // - this.columnHeader5.Text = "Line"; - // - // DummyTaskList - // - this.ClientSize = new System.Drawing.Size(337, 376); - this.Controls.Add(this.listView1); - this.DockAreas = ((WeifenLuo.WinFormsUI.Docking.DockAreas)(((((WeifenLuo.WinFormsUI.Docking.DockAreas.Float | WeifenLuo.WinFormsUI.Docking.DockAreas.DockLeft) - | WeifenLuo.WinFormsUI.Docking.DockAreas.DockRight) - | WeifenLuo.WinFormsUI.Docking.DockAreas.DockTop) - | WeifenLuo.WinFormsUI.Docking.DockAreas.DockBottom))); - this.HideOnClose = true; - this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); - this.Name = "DummyTaskList"; - this.Padding = new System.Windows.Forms.Padding(0, 3, 0, 3); - this.ShowHint = WeifenLuo.WinFormsUI.Docking.DockState.DockTopAutoHide; - this.TabText = "Task List"; - this.Text = "Task List"; - this.ResumeLayout(false); - - } - #endregion - - private System.Windows.Forms.ListView listView1; - private System.Windows.Forms.ColumnHeader columnHeader1; - private System.Windows.Forms.ColumnHeader columnHeader2; - private System.Windows.Forms.ColumnHeader columnHeader3; - private System.Windows.Forms.ColumnHeader columnHeader4; - private System.Windows.Forms.ColumnHeader columnHeader5; - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/DummyTaskList.cs b/src/Libraries/DockPanel_Src/DockSample/DummyTaskList.cs deleted file mode 100644 index 17f467b7a4..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/DummyTaskList.cs +++ /dev/null @@ -1,19 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel; -using System.Data; -using System.Drawing; -using System.Text; -using System.Windows.Forms; -using WeifenLuo.WinFormsUI.Docking; - -namespace DockSample -{ - public partial class DummyTaskList : ToolWindow - { - public DummyTaskList() - { - InitializeComponent(); - } - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/DummyTaskList.resx b/src/Libraries/DockPanel_Src/DockSample/DummyTaskList.resx deleted file mode 100644 index 89b780eb23..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/DummyTaskList.resx +++ /dev/null @@ -1,138 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - - - AAABAAEAICAQAAAAAADoAgAAFgAAACgAAAAgAAAAQAAAAAEABAAAAAAAAAIAAAAAAAAAAAAAEAAAABAA - AAAAAAAAAACAAACAAAAAgIAAgAAAAIAAgACAgAAAgICAAMDAwAAAAP8AAP8AAAD//wD/AAAA/wD/AP// - AAD///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA - AAAAAAAAAAAAAAAAd/////////////8AAAAAAHf/////////////AAAAAAB3////iIj//////wAAAAAA - d////4iI//////8AAAAAAHf///8RiIj/////AAAAAAB3////EYiI/////wAAAAAAd///ERERiIj///8A - AAAAAHf//xEREYiI////AAAAAAB3/xER/xERiP///wAAAAAAd/8REf8REYj///8AAAAAAHf//////xF3 - iP//AAAAAAB3//////8Rd4j//wAAAAAAd////////xGIiP8AAAAAAHf///////8RiIj/AAAAAAB3//// - /////xGI/wAAAAAAd/////////8RiP8AAAAAAHf//////////xH/AAAAAAB3//////////8R/wAAAAAA - d/////////////8AAAAAAHf/////////////AAAAAAB3//8AAAAAAAD//wAAAAAAd///AAAAAAAA//8A - AAAAAAB3dwD/iIiIAHd3AAAAAAAAd3cA/4iIiAB3dwAAAAAAAAAAAHd3d3cAAAAAAAAAAAAAAAB3d3d3 - AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAD///////////wAAD/8AAA/8AAAD/AA - AA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AA - AA/wAAAP8AAAD/AAAA/wAAAP8AAAD/wAAD/8AAA///AP///wD////////////w== - - - \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/DummyToolbox.Designer.cs b/src/Libraries/DockPanel_Src/DockSample/DummyToolbox.Designer.cs deleted file mode 100644 index 1b1764912c..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/DummyToolbox.Designer.cs +++ /dev/null @@ -1,96 +0,0 @@ -namespace DockSample -{ - partial class DummyToolbox - { - /// - /// Required designer variable. - /// - private System.ComponentModel.IContainer components = null; - - /// - /// Clean up any resources being used. - /// - /// true if managed resources should be disposed; otherwise, false. - protected override void Dispose(bool disposing) - { - if (disposing && (components != null)) - { - components.Dispose(); - } - base.Dispose(disposing); - } - - #region Windows Form Designer generated code - /// - /// Required method for Designer support - do not modify - /// the contents of this method with the code editor. - /// - private void InitializeComponent() - { - this.components = new System.ComponentModel.Container(); - System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(DummyToolbox)); - this.label2 = new System.Windows.Forms.Label(); - this.imageList = new System.Windows.Forms.ImageList(this.components); - this.label1 = new System.Windows.Forms.Label(); - this.SuspendLayout(); - // - // label2 - // - this.label2.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) - | System.Windows.Forms.AnchorStyles.Right))); - this.label2.BackColor = System.Drawing.SystemColors.ControlLightLight; - this.label2.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D; - this.label2.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft; - this.label2.ImageIndex = 0; - this.label2.ImageList = this.imageList; - this.label2.Location = new System.Drawing.Point(2, 26); - this.label2.Name = "label2"; - this.label2.Size = new System.Drawing.Size(215, 19); - this.label2.TabIndex = 5; - this.label2.Text = " Pointer"; - this.label2.TextAlign = System.Drawing.ContentAlignment.MiddleLeft; - // - // imageList - // - this.imageList.ImageStream = ((System.Windows.Forms.ImageListStreamer)(resources.GetObject("imageList.ImageStream"))); - this.imageList.TransparentColor = System.Drawing.Color.Transparent; - this.imageList.Images.SetKeyName(0, "Mouse.bmp"); - // - // label1 - // - this.label1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) - | System.Windows.Forms.AnchorStyles.Right))); - this.label1.FlatStyle = System.Windows.Forms.FlatStyle.Popup; - this.label1.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft; - this.label1.Location = new System.Drawing.Point(2, 7); - this.label1.Name = "label1"; - this.label1.Size = new System.Drawing.Size(215, 19); - this.label1.TabIndex = 6; - this.label1.Text = "General"; - // - // DummyToolbox - // - this.ClientSize = new System.Drawing.Size(221, 365); - this.Controls.Add(this.label1); - this.Controls.Add(this.label2); - this.DockAreas = ((WeifenLuo.WinFormsUI.Docking.DockAreas)(((((WeifenLuo.WinFormsUI.Docking.DockAreas.Float | WeifenLuo.WinFormsUI.Docking.DockAreas.DockLeft) - | WeifenLuo.WinFormsUI.Docking.DockAreas.DockRight) - | WeifenLuo.WinFormsUI.Docking.DockAreas.DockTop) - | WeifenLuo.WinFormsUI.Docking.DockAreas.DockBottom))); - this.HideOnClose = true; - this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); - this.Name = "DummyToolbox"; - this.Padding = new System.Windows.Forms.Padding(0, 2, 0, 2); - this.ShowHint = WeifenLuo.WinFormsUI.Docking.DockState.DockLeftAutoHide; - this.TabText = "Toolbox"; - this.Text = "Toolbox"; - this.ResumeLayout(false); - - } - #endregion - - private System.Windows.Forms.Label label2; - private System.Windows.Forms.ImageList imageList; - private System.Windows.Forms.Label label1; - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/DummyToolbox.cs b/src/Libraries/DockPanel_Src/DockSample/DummyToolbox.cs deleted file mode 100644 index 43f40f5c51..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/DummyToolbox.cs +++ /dev/null @@ -1,19 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel; -using System.Data; -using System.Drawing; -using System.Text; -using System.Windows.Forms; -using WeifenLuo.WinFormsUI.Docking; - -namespace DockSample -{ - public partial class DummyToolbox : ToolWindow - { - public DummyToolbox() - { - InitializeComponent(); - } - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/DummyToolbox.resx b/src/Libraries/DockPanel_Src/DockSample/DummyToolbox.resx deleted file mode 100644 index 34411700e9..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/DummyToolbox.resx +++ /dev/null @@ -1,181 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 17, 17 - - - - AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj0yLjAuMC4w - LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0 - ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAACa - BwAAAk1TRnQBSQFMAwEBAAEFAQABBAEAARABAAEQAQAE/wEJAQAI/wFCAU0BNgEEBgABNgEEAgABKAMA - AUADAAEQAwABAQEAAQgGAAEEGAABgAIAAYADAAKAAQABgAMAAYABAAGAAQACgAIAA8ABAAHAAdwBwAEA - AfABygGmAQABMwUAATMBAAEzAQABMwEAAjMCAAMWAQADHAEAAyIBAAMpAQADVQEAA00BAANCAQADOQEA - AYABfAH/AQACUAH/AQABkwEAAdYBAAH/AewBzAEAAcYB1gHvAQAB1gLnAQABkAGpAa0CAAH/ATMDAAFm - AwABmQMAAcwCAAEzAwACMwIAATMBZgIAATMBmQIAATMBzAIAATMB/wIAAWYDAAFmATMCAAJmAgABZgGZ - AgABZgHMAgABZgH/AgABmQMAAZkBMwIAAZkBZgIAApkCAAGZAcwCAAGZAf8CAAHMAwABzAEzAgABzAFm - AgABzAGZAgACzAIAAcwB/wIAAf8BZgIAAf8BmQIAAf8BzAEAATMB/wIAAf8BAAEzAQABMwEAAWYBAA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AAAAAAAAAAAAEAAAABAA - AAAAAAAAAACAAACAAAAAgIAAgAAAAIAAgACAgAAAgICAAMDAwAAAAP8AAP8AAAD//wD/AAAA/wD/AP// - AAD///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA - AAAAAAAAAAAAAAAAEQAAAAAAAACIAAAAAAAAABEAAAAAAAAAiAAAAAAAAAAAEQAAAAAAiAAAAAAAAAAA - ABEAAAAAAIgAAAAAAAAAAAAAEQAAAIgAAAAAAAAAAAAAABEAAACIAAAAAAAAAAAAAAAAEQCIAAAAAAAA - AAAAAAAAABEAiAAAAAAAAAAAAAAAAAAAiAAAAAAAAAAAAAAAAAAAAIgAAAAAAAAAAAAAAAAAAIgAEQAA - AAAAAAAAAAAAAACIABEAAAAAAAAAAAAAAACIAAAAEQAAAAAzAAAAAAAAiAAAABEAAAAAMwAAAAAAAAAA - AAAAEQAAADMzAAAAAAAAAAAAABEAAAAzMwAAAAAAAAAAAAAAADMzAAAAAAAAAAAAAAAAAAAzMwAAAAAA - AAAAAAAAAAAzMzMAAAAAAAAAAAAAAAAAMzMzAAAAAAAAAAAAAAAAADMzMwAAAAAAAAAAAAAAAAAzMzMA - AAAAAAAAAAAAADMzAAAAAAAAAAAAAAAAAAAzMwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA - AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAD//////////8P/8P/D//D/wP/A/8D/ - wP/wPwP/8D8D//wMD//8DA///wA///8AP///wP///8D///8AP8//AD/PAAwPAwAMDwMAPwAAAD8AADw/ - wAM8P8AD/D/AD/w/wA/wPwAP8D8AD//wAD//8AA///wD///8A////////////w== - - - \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/Images/ArrowDown.bmp b/src/Libraries/DockPanel_Src/DockSample/Images/ArrowDown.bmp deleted file mode 100644 index 42f9c489593a9f91abe272bf4e541ae6bd061e55..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 370 zcmZ?rEn;KJQ409!hZm{qJcd+ve19L{s>S0L5PE+*(a1+~d({w-11jj|**lTpc=jGIh(KKqh!nt;!XXi9|T4-#6i%ZG#@EG zS`_>&snSMG)5z>pNk?+qruw>(zTi%9#NWY}r$TebT9A{3j?nc{F@% z9#QC^OH4$T>vUp!v^wgO15AyYbN2Zi^{@G^SV;4S;ha3zrR|>U|C{+-riI@9Y|Q2dNelifa^W9X(>YL`CnNbsq=r@(8L@qC-AS0xZn>F1xoj>|boZxLDM! oM1Qe)%qi9$vw7w6#m%=V_HHlWEjca)I{$kLSN3yVzv=zJ7q&89kpKVy diff --git a/src/Libraries/DockPanel_Src/DockSample/Images/CSProject.ico b/src/Libraries/DockPanel_Src/DockSample/Images/CSProject.ico deleted file mode 100644 index bee04bd3f43a197f643c075a25a17f9558343804..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 318 zcmZvWu@1s85JMe_olMNA6I(ukr60l+b!5xXA(<*ZE1wiGA$2(H1SAG7wSDg{RSP&C z?>$r(2b`3YCTGgwKnF_qVcLy1#APf?>38I8se)Q7_tqbnsiSx_l6@D`E@Qw10-sa!Sdj(AIq?PmP$x;NHkMGL0N#+_pziF3WP$r&RSi1ZG#C{PpHbROi|m~b4U7}0yoa)lr>Rd4;!nms}4l+=TY Ou8VgV|NNKp{lEQgUT diff --git a/src/Libraries/DockPanel_Src/DockSample/Images/New.ico b/src/Libraries/DockPanel_Src/DockSample/Images/New.ico deleted file mode 100644 index bdaf403b0980306bb6ac6e380178f9718c21ee29..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 318 zcmbu3OA3H63`D0OxNKK$b?GgX6MIgF&m zEXCkSXmf))rWi41V5df?)@r?vr{2j7J1ywVvQ^|CvGKR}8wrv6Ve<~Dt{;&-w;LDt FOE<%eP)`5= diff --git a/src/Libraries/DockPanel_Src/DockSample/Images/Open.ico b/src/Libraries/DockPanel_Src/DockSample/Images/Open.ico deleted file mode 100644 index f269d9edd3ba28ac271fcf5088059a35ba8e3d87..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 318 zcmb7=F%H5o5Cqo>5`_!9qJ@$YiMP@F2l+~V5Pyjhr3kY=T8gYa=kuOVI$27rTC1#k zk}f{M&JB`IM5&D!!L{h{y+yIL@y3x9ntJcl_p!C_&VXgh;h&!9A?3-5RF*LE7Dic@ l(U~_yR#wEBeL0|*gN7>{e2Dm~gSK1U z0$wuXnSHarnX!Qx=BTO?iq|=C$7fjve>DSc7Ql*Q73GmK!xc3kjJ*sYNk$|*sA*CJ z&N&i;|6>@`qVT6fs{V`OK7~QirJ%n{VX#i=4%nph7CFB^zr?wreV@1^cz#Gw+TAl_bt5;{Zo43pZOQRDyI2utzdPUFyD@a3LCVe z%K)7@(Oe-;{EGO+^1DXWv(*la9mUa3Md+tO_Zx&Ghg@{cMUUIzgoojs$NkXGi_kvT z&aWtApF7%@A@Kn0Zw9Cq9isYkpZhd3&pyrjn0~RLY}PiunuTrjyvL;t;hV^JR;%&E p^lSXFuB}$X*Me2x5hsNAE#$^=R7IljF+pf~;dj6_jQ8&;@CmCUW8we+ diff --git a/src/Libraries/DockPanel_Src/DockSample/Images/OutputWindow.ico b/src/Libraries/DockPanel_Src/DockSample/Images/OutputWindow.ico deleted file mode 100644 index d076fed5bd7fc9f24b07c2e4cea3e1df28b9562d..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 766 zcmcIgF%E<<3^VBVV`A=j&$xjS$xI0fh!Aq)_HJuq_r zkb(S?9bU`?pH=AX(xFP+7Gl(iWT?cHQeq`<3pwjVGE`D}9<(tOud1qho(m4OH=Os+ tcANS=*H``a3*5ieSN%4>`?dPKf7(ILJ30NMZQ7fg&t``Oct6S3Zv`vc=coVx diff --git a/src/Libraries/DockPanel_Src/DockSample/Images/PropertyWindow.ico b/src/Libraries/DockPanel_Src/DockSample/Images/PropertyWindow.ico deleted file mode 100644 index 7c2e1e19f6392ec09c9587b1a22b03c95856ca02..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 766 zcmd5)F%H8Z40NiD9XfSp>=>yJXoozEr}+o{M#o55k=#3jBcW!gs!BaL;B0IRLS#To z=_JJSAacfh0TXx!2N^K}@CCTLM$nSIOU_(@Xf$C^Ranfsm~jQ7(Zu0fAW1{b6e@DJ zqiX@!@}{?dAH}zeZuRWw_9`e~_J`>;0s=Gry$+Yp@OSt(-4*8|ULS(@`kbl-pRCAr Xnw-an3TW$XaTZ&QMCMAaoqqHS&g;S4 diff --git a/src/Libraries/DockPanel_Src/DockSample/Images/Reference.ico b/src/Libraries/DockPanel_Src/DockSample/Images/Reference.ico deleted file mode 100644 index 4b025eb1ece8823ebffe59e00bb2a7b1774efccf..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 318 zcma)1F%Ezr5G#oZE0eRM&vRq+MmJWU!?PGnu;p~tLVMixjsOt2Qc4ik0L+S{DhnAf zQ2`t3BF`t3o112%N6I5-`;ii}T|D8;8zkP*J%k@9lfz4IM~DyZ`_I diff --git a/src/Libraries/DockPanel_Src/DockSample/Images/References.ico b/src/Libraries/DockPanel_Src/DockSample/Images/References.ico deleted file mode 100644 index 89e9dedf4ecc693b4254e3cfe2ea532bec4a94ce..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 318 zcmZWlIS#`x3}b)-%9yEh$39P+M+@i!{3So7Pw3`sDrt8pS~{e4P>x|><2sH5!hHj- z+DTPzeyL%m@ zcr&jY&fI<3tDEfS>6Wdv%$bi;95lNAVTA|$LsxjR+&>KN4<%m+#*=)TUg_t|xz#5dzV(&-VH5#VLif4!xu> zNfI0LSORvKQ|P^KG;buJ8))WqVYm%2PoUv1_4Ww?&5iiH$jz*fFYsKnZ}OLqQUa=O z{d5A2KsKsl$@>P{ZlKql&v-zm<7^bSn*DY<^?q}qsMDNwuzQUr1-;${dhOBWkkPDElR~s42GMGz%fj&()$le#= z&iz45#ETekWu#FnrtW+~mDv~OSs6iBiD6k5R?HX7lo5256n?hIYc}({&Ui}RvFj}l zxv=XE4Yz2nthW?zeR`$2Ry2upJ9? diff --git a/src/Libraries/DockPanel_Src/DockSample/Images/ToolboxWindow.ico b/src/Libraries/DockPanel_Src/DockSample/Images/ToolboxWindow.ico deleted file mode 100644 index 5d2ec12680959fb2bf4a9c631aa7dafb3849b037..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 766 zcmbu7F%H5o3`JeSSgEiucVzF16pq%h$BM)OxCUbmP|5u7q@r~vz{yMV?H{L=D$-!| z{YeKy3-S%L!&in=+2v0SuB{uYp6Cla4T+AbIo*MnP3fy^;=Bu6nc<1m?n8fd|I E19fq3$N&HU diff --git a/src/Libraries/DockPanel_Src/DockSample/Images/XmlFile.ico b/src/Libraries/DockPanel_Src/DockSample/Images/XmlFile.ico deleted file mode 100644 index 7c00c79fa822ba74aefddf4655dbb6d2dfad9dac..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 318 zcmb79D-HrN5PeNZMj%>+-mF5w6$lsDtKhJe>$p;n)U4UM;k_0lf|ze%mdrH2qa!3C6FC5u#MAZJk8w?&>B>(^b diff --git a/src/Libraries/DockPanel_Src/DockSample/Images/msenv22.ico b/src/Libraries/DockPanel_Src/DockSample/Images/msenv22.ico deleted file mode 100644 index 32bb0db7e121851dc38db9316bc94084906234fd..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 766 zcmcgqv2Md45PgX%Avu!0b@te?o5$pnDs{+MK85+F`~m(Hwq_!gI%Kd^_Z`?3jv_@J zk_QL(cy}BKfE8QYK0$F@1J9gaXf16=TOn(pb{!UAhqZa)NS9{O_dSI%b&R8WG&Wt* z;h!)}Dgg8SPVBpkEzG&=UIASsK9c?>ZmEmQ@;&q~UPxrRRRi-AV-Trh!YT1e#1)+K zf~!0wXnc@L>MAEB?n34P@s9@=KR1IZdGP))YQ38Av5uQz7@FxkdYs04U-C;`^L0Ol eLQgyIuYN+VUpxj~nEe7bUw2No{AQ1|x$ZAD(H^k? diff --git a/src/Libraries/DockPanel_Src/DockSample/MainForm.Designer.cs b/src/Libraries/DockPanel_Src/DockSample/MainForm.Designer.cs deleted file mode 100644 index b199683b80..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/MainForm.Designer.cs +++ /dev/null @@ -1,614 +0,0 @@ -namespace DockSample -{ - partial class MainForm - { - /// - /// Required designer variable. - /// - private System.ComponentModel.IContainer components = null; - - /// - /// Clean up any resources being used. - /// - /// true if managed resources should be disposed; otherwise, false. - protected override void Dispose(bool disposing) - { - if (disposing && (components != null)) - { - components.Dispose(); - } - base.Dispose(disposing); - } - - #region Windows Form Designer generated code - /// - /// Required method for Designer support - do not modify - /// the contents of this method with the code editor. - /// - private void InitializeComponent() - { - this.components = new System.ComponentModel.Container(); - System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(MainForm)); - this.mainMenu = new System.Windows.Forms.MenuStrip(); - this.menuItemFile = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemNew = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemOpen = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemClose = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemCloseAll = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemCloseAllButThisOne = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItem4 = new System.Windows.Forms.ToolStripSeparator(); - this.menuItemExit = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemView = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemSolutionExplorer = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemPropertyWindow = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemToolbox = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemOutputWindow = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemTaskList = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItem1 = new System.Windows.Forms.ToolStripSeparator(); - this.menuItemToolBar = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemStatusBar = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItem2 = new System.Windows.Forms.ToolStripSeparator(); - this.menuItemLayoutByCode = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemLayoutByXml = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemTools = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemLockLayout = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemShowDocumentIcon = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItem3 = new System.Windows.Forms.ToolStripSeparator(); - this.menuItemSchemaVS2005 = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemSchemaVS2003 = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItem6 = new System.Windows.Forms.ToolStripSeparator(); - this.menuItemDockingMdi = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemDockingSdi = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemDockingWindow = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemSystemMdi = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItem5 = new System.Windows.Forms.ToolStripSeparator(); - this.showRightToLeft = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemWindow = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemNewWindow = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemHelp = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemAbout = new System.Windows.Forms.ToolStripMenuItem(); - this.statusBar = new System.Windows.Forms.StatusStrip(); - this.imageList = new System.Windows.Forms.ImageList(this.components); - this.toolBar = new System.Windows.Forms.ToolStrip(); - this.toolBarButtonNew = new System.Windows.Forms.ToolStripButton(); - this.toolBarButtonOpen = new System.Windows.Forms.ToolStripButton(); - this.toolBarButtonSeparator1 = new System.Windows.Forms.ToolStripSeparator(); - this.toolBarButtonSolutionExplorer = new System.Windows.Forms.ToolStripButton(); - this.toolBarButtonPropertyWindow = new System.Windows.Forms.ToolStripButton(); - this.toolBarButtonToolbox = new System.Windows.Forms.ToolStripButton(); - this.toolBarButtonOutputWindow = new System.Windows.Forms.ToolStripButton(); - this.toolBarButtonTaskList = new System.Windows.Forms.ToolStripButton(); - this.toolBarButtonSeparator2 = new System.Windows.Forms.ToolStripSeparator(); - this.toolBarButtonLayoutByCode = new System.Windows.Forms.ToolStripButton(); - this.toolBarButtonLayoutByXml = new System.Windows.Forms.ToolStripButton(); - this.dockPanel = new WeifenLuo.WinFormsUI.Docking.DockPanel(); - this.exitWithoutSavingLayout = new System.Windows.Forms.ToolStripMenuItem(); - this.mainMenu.SuspendLayout(); - this.toolBar.SuspendLayout(); - this.SuspendLayout(); - // - // mainMenu - // - this.mainMenu.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.menuItemFile, - this.menuItemView, - this.menuItemTools, - this.menuItemWindow, - this.menuItemHelp}); - this.mainMenu.Location = new System.Drawing.Point(0, 0); - this.mainMenu.MdiWindowListItem = this.menuItemWindow; - this.mainMenu.Name = "mainMenu"; - this.mainMenu.Size = new System.Drawing.Size(579, 24); - this.mainMenu.TabIndex = 7; - // - // menuItemFile - // - this.menuItemFile.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.menuItemNew, - this.menuItemOpen, - this.menuItemClose, - this.menuItemCloseAll, - this.menuItemCloseAllButThisOne, - this.menuItem4, - this.menuItemExit, - this.exitWithoutSavingLayout}); - this.menuItemFile.Name = "menuItemFile"; - this.menuItemFile.Size = new System.Drawing.Size(35, 20); - this.menuItemFile.Text = "&File"; - this.menuItemFile.DropDownOpening += new System.EventHandler(this.menuItemFile_Popup); - // - // menuItemNew - // - this.menuItemNew.Name = "menuItemNew"; - this.menuItemNew.Size = new System.Drawing.Size(204, 22); - this.menuItemNew.Text = "&New"; - this.menuItemNew.Click += new System.EventHandler(this.menuItemNew_Click); - // - // menuItemOpen - // - this.menuItemOpen.Name = "menuItemOpen"; - this.menuItemOpen.Size = new System.Drawing.Size(204, 22); - this.menuItemOpen.Text = "&Open..."; - this.menuItemOpen.Click += new System.EventHandler(this.menuItemOpen_Click); - // - // menuItemClose - // - this.menuItemClose.Name = "menuItemClose"; - this.menuItemClose.Size = new System.Drawing.Size(204, 22); - this.menuItemClose.Text = "&Close"; - this.menuItemClose.Click += new System.EventHandler(this.menuItemClose_Click); - // - // menuItemCloseAll - // - this.menuItemCloseAll.Name = "menuItemCloseAll"; - this.menuItemCloseAll.Size = new System.Drawing.Size(204, 22); - this.menuItemCloseAll.Text = "Close &All"; - this.menuItemCloseAll.Click += new System.EventHandler(this.menuItemCloseAll_Click); - // - // menuItemCloseAllButThisOne - // - this.menuItemCloseAllButThisOne.Name = "menuItemCloseAllButThisOne"; - this.menuItemCloseAllButThisOne.Size = new System.Drawing.Size(204, 22); - this.menuItemCloseAllButThisOne.Text = "Close All &But This One"; - this.menuItemCloseAllButThisOne.Click += new System.EventHandler(this.menuItemCloseAllButThisOne_Click); - // - // menuItem4 - // - this.menuItem4.Name = "menuItem4"; - this.menuItem4.Size = new System.Drawing.Size(201, 6); - // - // menuItemExit - // - this.menuItemExit.Name = "menuItemExit"; - this.menuItemExit.Size = new System.Drawing.Size(204, 22); - this.menuItemExit.Text = "&Exit"; - this.menuItemExit.Click += new System.EventHandler(this.menuItemExit_Click); - // - // menuItemView - // - this.menuItemView.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.menuItemSolutionExplorer, - this.menuItemPropertyWindow, - this.menuItemToolbox, - this.menuItemOutputWindow, - this.menuItemTaskList, - this.menuItem1, - this.menuItemToolBar, - this.menuItemStatusBar, - this.menuItem2, - this.menuItemLayoutByCode, - this.menuItemLayoutByXml}); - this.menuItemView.MergeIndex = 1; - this.menuItemView.Name = "menuItemView"; - this.menuItemView.Size = new System.Drawing.Size(41, 20); - this.menuItemView.Text = "&View"; - // - // menuItemSolutionExplorer - // - this.menuItemSolutionExplorer.Name = "menuItemSolutionExplorer"; - this.menuItemSolutionExplorer.Size = new System.Drawing.Size(176, 22); - this.menuItemSolutionExplorer.Text = "&Solution Explorer"; - this.menuItemSolutionExplorer.Click += new System.EventHandler(this.menuItemSolutionExplorer_Click); - // - // menuItemPropertyWindow - // - this.menuItemPropertyWindow.Name = "menuItemPropertyWindow"; - this.menuItemPropertyWindow.ShortcutKeys = System.Windows.Forms.Keys.F4; - this.menuItemPropertyWindow.Size = new System.Drawing.Size(176, 22); - this.menuItemPropertyWindow.Text = "&Property Window"; - this.menuItemPropertyWindow.Click += new System.EventHandler(this.menuItemPropertyWindow_Click); - // - // menuItemToolbox - // - this.menuItemToolbox.Name = "menuItemToolbox"; - this.menuItemToolbox.Size = new System.Drawing.Size(176, 22); - this.menuItemToolbox.Text = "&Toolbox"; - this.menuItemToolbox.Click += new System.EventHandler(this.menuItemToolbox_Click); - // - // menuItemOutputWindow - // - this.menuItemOutputWindow.Name = "menuItemOutputWindow"; - this.menuItemOutputWindow.Size = new System.Drawing.Size(176, 22); - this.menuItemOutputWindow.Text = "&Output Window"; - this.menuItemOutputWindow.Click += new System.EventHandler(this.menuItemOutputWindow_Click); - // - // menuItemTaskList - // - this.menuItemTaskList.Name = "menuItemTaskList"; - this.menuItemTaskList.Size = new System.Drawing.Size(176, 22); - this.menuItemTaskList.Text = "Task &List"; - this.menuItemTaskList.Click += new System.EventHandler(this.menuItemTaskList_Click); - // - // menuItem1 - // - this.menuItem1.Name = "menuItem1"; - this.menuItem1.Size = new System.Drawing.Size(173, 6); - // - // menuItemToolBar - // - this.menuItemToolBar.Checked = true; - this.menuItemToolBar.CheckState = System.Windows.Forms.CheckState.Checked; - this.menuItemToolBar.Name = "menuItemToolBar"; - this.menuItemToolBar.Size = new System.Drawing.Size(176, 22); - this.menuItemToolBar.Text = "Tool &Bar"; - this.menuItemToolBar.Click += new System.EventHandler(this.menuItemToolBar_Click); - // - // menuItemStatusBar - // - this.menuItemStatusBar.Checked = true; - this.menuItemStatusBar.CheckState = System.Windows.Forms.CheckState.Checked; - this.menuItemStatusBar.Name = "menuItemStatusBar"; - this.menuItemStatusBar.Size = new System.Drawing.Size(176, 22); - this.menuItemStatusBar.Text = "Status B&ar"; - this.menuItemStatusBar.Click += new System.EventHandler(this.menuItemStatusBar_Click); - // - // menuItem2 - // - this.menuItem2.Name = "menuItem2"; - this.menuItem2.Size = new System.Drawing.Size(173, 6); - // - // menuItemLayoutByCode - // - this.menuItemLayoutByCode.Name = "menuItemLayoutByCode"; - this.menuItemLayoutByCode.Size = new System.Drawing.Size(176, 22); - this.menuItemLayoutByCode.Text = "Layout By &Code"; - this.menuItemLayoutByCode.Click += new System.EventHandler(this.menuItemLayoutByCode_Click); - // - // menuItemLayoutByXml - // - this.menuItemLayoutByXml.Name = "menuItemLayoutByXml"; - this.menuItemLayoutByXml.Size = new System.Drawing.Size(176, 22); - this.menuItemLayoutByXml.Text = "Layout By &XML"; - this.menuItemLayoutByXml.Click += new System.EventHandler(this.menuItemLayoutByXml_Click); - // - // menuItemTools - // - this.menuItemTools.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.menuItemLockLayout, - this.menuItemShowDocumentIcon, - this.menuItem3, - this.menuItemSchemaVS2005, - this.menuItemSchemaVS2003, - this.menuItem6, - this.menuItemDockingMdi, - this.menuItemDockingSdi, - this.menuItemDockingWindow, - this.menuItemSystemMdi, - this.menuItem5, - this.showRightToLeft}); - this.menuItemTools.MergeIndex = 2; - this.menuItemTools.Name = "menuItemTools"; - this.menuItemTools.Size = new System.Drawing.Size(44, 20); - this.menuItemTools.Text = "&Tools"; - this.menuItemTools.DropDownOpening += new System.EventHandler(this.menuItemTools_Popup); - // - // menuItemLockLayout - // - this.menuItemLockLayout.Name = "menuItemLockLayout"; - this.menuItemLockLayout.Size = new System.Drawing.Size(234, 22); - this.menuItemLockLayout.Text = "&Lock Layout"; - this.menuItemLockLayout.Click += new System.EventHandler(this.menuItemLockLayout_Click); - // - // menuItemShowDocumentIcon - // - this.menuItemShowDocumentIcon.Name = "menuItemShowDocumentIcon"; - this.menuItemShowDocumentIcon.Size = new System.Drawing.Size(234, 22); - this.menuItemShowDocumentIcon.Text = "&Show Document Icon"; - this.menuItemShowDocumentIcon.Click += new System.EventHandler(this.menuItemShowDocumentIcon_Click); - // - // menuItem3 - // - this.menuItem3.Name = "menuItem3"; - this.menuItem3.Size = new System.Drawing.Size(231, 6); - // - // menuItemSchemaVS2005 - // - this.menuItemSchemaVS2005.Checked = true; - this.menuItemSchemaVS2005.CheckState = System.Windows.Forms.CheckState.Checked; - this.menuItemSchemaVS2005.Name = "menuItemSchemaVS2005"; - this.menuItemSchemaVS2005.Size = new System.Drawing.Size(234, 22); - this.menuItemSchemaVS2005.Text = "Schema: VS200&5"; - this.menuItemSchemaVS2005.Click += new System.EventHandler(this.SetSchema); - // - // menuItemSchemaVS2003 - // - this.menuItemSchemaVS2003.Name = "menuItemSchemaVS2003"; - this.menuItemSchemaVS2003.Size = new System.Drawing.Size(234, 22); - this.menuItemSchemaVS2003.Text = "Schema: VS200&3"; - this.menuItemSchemaVS2003.Click += new System.EventHandler(this.SetSchema); - // - // menuItem6 - // - this.menuItem6.Name = "menuItem6"; - this.menuItem6.Size = new System.Drawing.Size(231, 6); - // - // menuItemDockingMdi - // - this.menuItemDockingMdi.Checked = true; - this.menuItemDockingMdi.CheckState = System.Windows.Forms.CheckState.Checked; - this.menuItemDockingMdi.Name = "menuItemDockingMdi"; - this.menuItemDockingMdi.Size = new System.Drawing.Size(234, 22); - this.menuItemDockingMdi.Text = "Document Style: Docking &MDI"; - this.menuItemDockingMdi.Click += new System.EventHandler(this.SetDocumentStyle); - // - // menuItemDockingSdi - // - this.menuItemDockingSdi.Name = "menuItemDockingSdi"; - this.menuItemDockingSdi.Size = new System.Drawing.Size(234, 22); - this.menuItemDockingSdi.Text = "Document Style: Docking &SDI"; - this.menuItemDockingSdi.Click += new System.EventHandler(this.SetDocumentStyle); - // - // menuItemDockingWindow - // - this.menuItemDockingWindow.Name = "menuItemDockingWindow"; - this.menuItemDockingWindow.Size = new System.Drawing.Size(234, 22); - this.menuItemDockingWindow.Text = "Document Style: Docking &Window"; - this.menuItemDockingWindow.Click += new System.EventHandler(this.SetDocumentStyle); - // - // menuItemSystemMdi - // - this.menuItemSystemMdi.Name = "menuItemSystemMdi"; - this.menuItemSystemMdi.Size = new System.Drawing.Size(234, 22); - this.menuItemSystemMdi.Text = "Document Style: S&ystem MDI"; - this.menuItemSystemMdi.Click += new System.EventHandler(this.SetDocumentStyle); - // - // menuItem5 - // - this.menuItem5.Name = "menuItem5"; - this.menuItem5.Size = new System.Drawing.Size(231, 6); - // - // showRightToLeft - // - this.showRightToLeft.Name = "showRightToLeft"; - this.showRightToLeft.Size = new System.Drawing.Size(234, 22); - this.showRightToLeft.Text = "Show &Right-To-Left"; - this.showRightToLeft.Click += new System.EventHandler(this.showRightToLeft_Click); - // - // menuItemWindow - // - this.menuItemWindow.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.menuItemNewWindow}); - this.menuItemWindow.MergeIndex = 2; - this.menuItemWindow.Name = "menuItemWindow"; - this.menuItemWindow.Size = new System.Drawing.Size(57, 20); - this.menuItemWindow.Text = "&Window"; - // - // menuItemNewWindow - // - this.menuItemNewWindow.Name = "menuItemNewWindow"; - this.menuItemNewWindow.Size = new System.Drawing.Size(136, 22); - this.menuItemNewWindow.Text = "&New Window"; - this.menuItemNewWindow.Click += new System.EventHandler(this.menuItemNewWindow_Click); - // - // menuItemHelp - // - this.menuItemHelp.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.menuItemAbout}); - this.menuItemHelp.MergeIndex = 3; - this.menuItemHelp.Name = "menuItemHelp"; - this.menuItemHelp.Size = new System.Drawing.Size(40, 20); - this.menuItemHelp.Text = "&Help"; - // - // menuItemAbout - // - this.menuItemAbout.Name = "menuItemAbout"; - this.menuItemAbout.Size = new System.Drawing.Size(175, 22); - this.menuItemAbout.Text = "&About DockSample..."; - this.menuItemAbout.Click += new System.EventHandler(this.menuItemAbout_Click); - // - // statusBar - // - this.statusBar.Location = new System.Drawing.Point(0, 387); - this.statusBar.Name = "statusBar"; - this.statusBar.Size = new System.Drawing.Size(579, 22); - this.statusBar.TabIndex = 4; - // - // imageList - // - this.imageList.ImageStream = ((System.Windows.Forms.ImageListStreamer)(resources.GetObject("imageList.ImageStream"))); - this.imageList.TransparentColor = System.Drawing.Color.Transparent; - this.imageList.Images.SetKeyName(0, ""); - this.imageList.Images.SetKeyName(1, ""); - this.imageList.Images.SetKeyName(2, ""); - this.imageList.Images.SetKeyName(3, ""); - this.imageList.Images.SetKeyName(4, ""); - this.imageList.Images.SetKeyName(5, ""); - this.imageList.Images.SetKeyName(6, ""); - this.imageList.Images.SetKeyName(7, ""); - this.imageList.Images.SetKeyName(8, ""); - // - // toolBar - // - this.toolBar.ImageList = this.imageList; - this.toolBar.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.toolBarButtonNew, - this.toolBarButtonOpen, - this.toolBarButtonSeparator1, - this.toolBarButtonSolutionExplorer, - this.toolBarButtonPropertyWindow, - this.toolBarButtonToolbox, - this.toolBarButtonOutputWindow, - this.toolBarButtonTaskList, - this.toolBarButtonSeparator2, - this.toolBarButtonLayoutByCode, - this.toolBarButtonLayoutByXml}); - this.toolBar.Location = new System.Drawing.Point(0, 24); - this.toolBar.Name = "toolBar"; - this.toolBar.Size = new System.Drawing.Size(579, 25); - this.toolBar.TabIndex = 6; - this.toolBar.ItemClicked += new System.Windows.Forms.ToolStripItemClickedEventHandler(this.toolBar_ButtonClick); - // - // toolBarButtonNew - // - this.toolBarButtonNew.ImageIndex = 0; - this.toolBarButtonNew.Name = "toolBarButtonNew"; - this.toolBarButtonNew.Size = new System.Drawing.Size(23, 22); - this.toolBarButtonNew.ToolTipText = "Show Layout From XML"; - // - // toolBarButtonOpen - // - this.toolBarButtonOpen.ImageIndex = 1; - this.toolBarButtonOpen.Name = "toolBarButtonOpen"; - this.toolBarButtonOpen.Size = new System.Drawing.Size(23, 22); - this.toolBarButtonOpen.ToolTipText = "Open"; - // - // toolBarButtonSeparator1 - // - this.toolBarButtonSeparator1.Name = "toolBarButtonSeparator1"; - this.toolBarButtonSeparator1.Size = new System.Drawing.Size(6, 25); - // - // toolBarButtonSolutionExplorer - // - this.toolBarButtonSolutionExplorer.ImageIndex = 2; - this.toolBarButtonSolutionExplorer.Name = "toolBarButtonSolutionExplorer"; - this.toolBarButtonSolutionExplorer.Size = new System.Drawing.Size(23, 22); - this.toolBarButtonSolutionExplorer.ToolTipText = "Solution Explorer"; - // - // toolBarButtonPropertyWindow - // - this.toolBarButtonPropertyWindow.ImageIndex = 3; - this.toolBarButtonPropertyWindow.Name = "toolBarButtonPropertyWindow"; - this.toolBarButtonPropertyWindow.Size = new System.Drawing.Size(23, 22); - this.toolBarButtonPropertyWindow.ToolTipText = "Property Window"; - // - // toolBarButtonToolbox - // - this.toolBarButtonToolbox.ImageIndex = 4; - this.toolBarButtonToolbox.Name = "toolBarButtonToolbox"; - this.toolBarButtonToolbox.Size = new System.Drawing.Size(23, 22); - this.toolBarButtonToolbox.ToolTipText = "Tool Box"; - // - // toolBarButtonOutputWindow - // - this.toolBarButtonOutputWindow.ImageIndex = 5; - this.toolBarButtonOutputWindow.Name = "toolBarButtonOutputWindow"; - this.toolBarButtonOutputWindow.Size = new System.Drawing.Size(23, 22); - this.toolBarButtonOutputWindow.ToolTipText = "Output Window"; - // - // toolBarButtonTaskList - // - this.toolBarButtonTaskList.ImageIndex = 6; - this.toolBarButtonTaskList.Name = "toolBarButtonTaskList"; - this.toolBarButtonTaskList.Size = new System.Drawing.Size(23, 22); - this.toolBarButtonTaskList.ToolTipText = "Task List"; - // - // toolBarButtonSeparator2 - // - this.toolBarButtonSeparator2.Name = "toolBarButtonSeparator2"; - this.toolBarButtonSeparator2.Size = new System.Drawing.Size(6, 25); - // - // toolBarButtonLayoutByCode - // - this.toolBarButtonLayoutByCode.ImageIndex = 7; - this.toolBarButtonLayoutByCode.Name = "toolBarButtonLayoutByCode"; - this.toolBarButtonLayoutByCode.Size = new System.Drawing.Size(23, 22); - this.toolBarButtonLayoutByCode.ToolTipText = "Show Layout By Code"; - // - // toolBarButtonLayoutByXml - // - this.toolBarButtonLayoutByXml.ImageIndex = 8; - this.toolBarButtonLayoutByXml.Name = "toolBarButtonLayoutByXml"; - this.toolBarButtonLayoutByXml.Size = new System.Drawing.Size(23, 22); - this.toolBarButtonLayoutByXml.ToolTipText = "Show layout by predefined XML file"; - // - // dockPanel - // - this.dockPanel.Dock = System.Windows.Forms.DockStyle.Fill; - this.dockPanel.DockBottomPortion = 150; - this.dockPanel.DockLeftPortion = 200; - this.dockPanel.DockRightPortion = 200; - this.dockPanel.DockTopPortion = 150; - this.dockPanel.Font = new System.Drawing.Font("Tahoma", 11F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.World, ((byte)(0))); - this.dockPanel.Location = new System.Drawing.Point(0, 49); - this.dockPanel.Name = "dockPanel"; - this.dockPanel.RightToLeftLayout = true; - this.dockPanel.Size = new System.Drawing.Size(579, 338); - this.dockPanel.TabIndex = 0; - // - // exitWithoutSavingLayout - // - this.exitWithoutSavingLayout.Name = "exitWithoutSavingLayout"; - this.exitWithoutSavingLayout.Size = new System.Drawing.Size(204, 22); - this.exitWithoutSavingLayout.Text = "Exit &Without Saving Layout"; - this.exitWithoutSavingLayout.Click += new System.EventHandler(this.exitWithoutSavingLayout_Click); - // - // MainForm - // - this.ClientSize = new System.Drawing.Size(579, 409); - this.Controls.Add(this.dockPanel); - this.Controls.Add(this.toolBar); - this.Controls.Add(this.mainMenu); - this.Controls.Add(this.statusBar); - this.IsMdiContainer = true; - this.MainMenuStrip = this.mainMenu; - this.Name = "MainForm"; - this.Text = "DockSample"; - this.WindowState = System.Windows.Forms.FormWindowState.Maximized; - this.Closing += new System.ComponentModel.CancelEventHandler(this.MainForm_Closing); - this.Load += new System.EventHandler(this.MainForm_Load); - this.mainMenu.ResumeLayout(false); - this.mainMenu.PerformLayout(); - this.toolBar.ResumeLayout(false); - this.toolBar.PerformLayout(); - this.ResumeLayout(false); - this.PerformLayout(); - - } - #endregion - - private WeifenLuo.WinFormsUI.Docking.DockPanel dockPanel; - private System.Windows.Forms.ImageList imageList; - private System.Windows.Forms.ToolStrip toolBar; - private System.Windows.Forms.ToolStripButton toolBarButtonNew; - private System.Windows.Forms.ToolStripButton toolBarButtonOpen; - private System.Windows.Forms.ToolStripSeparator toolBarButtonSeparator1; - private System.Windows.Forms.ToolStripButton toolBarButtonSolutionExplorer; - private System.Windows.Forms.ToolStripButton toolBarButtonPropertyWindow; - private System.Windows.Forms.ToolStripButton toolBarButtonToolbox; - private System.Windows.Forms.ToolStripButton toolBarButtonOutputWindow; - private System.Windows.Forms.ToolStripButton toolBarButtonTaskList; - private System.Windows.Forms.ToolStripSeparator toolBarButtonSeparator2; - private System.Windows.Forms.ToolStripButton toolBarButtonLayoutByCode; - private System.Windows.Forms.ToolStripButton toolBarButtonLayoutByXml; - private System.Windows.Forms.MenuStrip mainMenu; - private System.Windows.Forms.ToolStripMenuItem menuItemFile; - private System.Windows.Forms.ToolStripMenuItem menuItemNew; - private System.Windows.Forms.ToolStripMenuItem menuItemOpen; - private System.Windows.Forms.ToolStripMenuItem menuItemClose; - private System.Windows.Forms.ToolStripMenuItem menuItemCloseAll; - private System.Windows.Forms.ToolStripMenuItem menuItemCloseAllButThisOne; - private System.Windows.Forms.ToolStripSeparator menuItem4; - private System.Windows.Forms.ToolStripMenuItem menuItemExit; - private System.Windows.Forms.ToolStripMenuItem menuItemView; - private System.Windows.Forms.ToolStripMenuItem menuItemSolutionExplorer; - private System.Windows.Forms.ToolStripMenuItem menuItemPropertyWindow; - private System.Windows.Forms.ToolStripMenuItem menuItemToolbox; - private System.Windows.Forms.ToolStripMenuItem menuItemOutputWindow; - private System.Windows.Forms.ToolStripMenuItem menuItemTaskList; - private System.Windows.Forms.ToolStripSeparator menuItem1; - private System.Windows.Forms.ToolStripMenuItem menuItemToolBar; - private System.Windows.Forms.ToolStripMenuItem menuItemStatusBar; - private System.Windows.Forms.ToolStripSeparator menuItem2; - private System.Windows.Forms.ToolStripMenuItem menuItemLayoutByCode; - private System.Windows.Forms.ToolStripMenuItem menuItemLayoutByXml; - private System.Windows.Forms.ToolStripMenuItem menuItemTools; - private System.Windows.Forms.ToolStripMenuItem menuItemLockLayout; - private System.Windows.Forms.ToolStripSeparator menuItem3; - private System.Windows.Forms.ToolStripMenuItem menuItemSchemaVS2005; - private System.Windows.Forms.ToolStripMenuItem menuItemSchemaVS2003; - private System.Windows.Forms.ToolStripSeparator menuItem6; - private System.Windows.Forms.ToolStripMenuItem menuItemDockingMdi; - private System.Windows.Forms.ToolStripMenuItem menuItemDockingSdi; - private System.Windows.Forms.ToolStripMenuItem menuItemDockingWindow; - private System.Windows.Forms.ToolStripMenuItem menuItemSystemMdi; - private System.Windows.Forms.ToolStripSeparator menuItem5; - private System.Windows.Forms.ToolStripMenuItem menuItemShowDocumentIcon; - private System.Windows.Forms.ToolStripMenuItem menuItemWindow; - private System.Windows.Forms.ToolStripMenuItem menuItemNewWindow; - private System.Windows.Forms.ToolStripMenuItem menuItemHelp; - private System.Windows.Forms.ToolStripMenuItem menuItemAbout; - private System.Windows.Forms.StatusStrip statusBar; - private System.Windows.Forms.ToolStripMenuItem showRightToLeft; - private System.Windows.Forms.ToolStripMenuItem exitWithoutSavingLayout; - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/MainForm.cs b/src/Libraries/DockPanel_Src/DockSample/MainForm.cs deleted file mode 100644 index f9d0f3fd98..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/MainForm.cs +++ /dev/null @@ -1,443 +0,0 @@ -using System; -using System.Drawing; -using System.Collections; -using System.ComponentModel; -using System.Reflection; -using System.Windows.Forms; -using System.IO; -using WeifenLuo.WinFormsUI.Docking; -using DockSample.Customization; - -namespace DockSample -{ - public partial class MainForm : Form - { - private bool m_bSaveLayout = true; - private DeserializeDockContent m_deserializeDockContent; - private DummySolutionExplorer m_solutionExplorer = new DummySolutionExplorer(); - private DummyPropertyWindow m_propertyWindow = new DummyPropertyWindow(); - private DummyToolbox m_toolbox = new DummyToolbox(); - private DummyOutputWindow m_outputWindow = new DummyOutputWindow(); - private DummyTaskList m_taskList = new DummyTaskList(); - - public MainForm() - { - InitializeComponent(); - showRightToLeft.Checked = (RightToLeft == RightToLeft.Yes); - RightToLeftLayout = showRightToLeft.Checked; - m_solutionExplorer = new DummySolutionExplorer(); - m_solutionExplorer.RightToLeftLayout = RightToLeftLayout; - m_deserializeDockContent = new DeserializeDockContent(GetContentFromPersistString); - } - - private void menuItemExit_Click(object sender, System.EventArgs e) - { - Close(); - } - - private void menuItemSolutionExplorer_Click(object sender, System.EventArgs e) - { - m_solutionExplorer.Show(dockPanel); - } - - private void menuItemPropertyWindow_Click(object sender, System.EventArgs e) - { - m_propertyWindow.Show(dockPanel); - } - - private void menuItemToolbox_Click(object sender, System.EventArgs e) - { - m_toolbox.Show(dockPanel); - } - - private void menuItemOutputWindow_Click(object sender, System.EventArgs e) - { - m_outputWindow.Show(dockPanel); - } - - private void menuItemTaskList_Click(object sender, System.EventArgs e) - { - m_taskList.Show(dockPanel); - } - - private void menuItemAbout_Click(object sender, System.EventArgs e) - { - AboutDialog aboutDialog = new AboutDialog(); - aboutDialog.ShowDialog(this); - } - - private IDockContent FindDocument(string text) - { - if (dockPanel.DocumentStyle == DocumentStyle.SystemMdi) - { - foreach (Form form in MdiChildren) - if (form.Text == text) - return form as IDockContent; - - return null; - } - else - { - foreach (IDockContent content in dockPanel.Documents) - if (content.DockHandler.TabText == text) - return content; - - return null; - } - } - - private void menuItemNew_Click(object sender, System.EventArgs e) - { - DummyDoc dummyDoc = CreateNewDocument(); - if (dockPanel.DocumentStyle == DocumentStyle.SystemMdi) - { - dummyDoc.MdiParent = this; - dummyDoc.Show(); - } - else - dummyDoc.Show(dockPanel); - } - - private DummyDoc CreateNewDocument() - { - DummyDoc dummyDoc = new DummyDoc(); - - int count = 1; - //string text = "C:\\MADFDKAJ\\ADAKFJASD\\ADFKDSAKFJASD\\ASDFKASDFJASDF\\ASDFIJADSFJ\\ASDFKDFDA" + count.ToString(); - string text = "Document" + count.ToString(); - while (FindDocument(text) != null) - { - count ++; - //text = "C:\\MADFDKAJ\\ADAKFJASD\\ADFKDSAKFJASD\\ASDFKASDFJASDF\\ASDFIJADSFJ\\ASDFKDFDA" + count.ToString(); - text = "Document" + count.ToString(); - } - dummyDoc.Text = text; - return dummyDoc; - } - - private DummyDoc CreateNewDocument(string text) - { - DummyDoc dummyDoc = new DummyDoc(); - dummyDoc.Text = text; - return dummyDoc; - } - - private void menuItemOpen_Click(object sender, System.EventArgs e) - { - OpenFileDialog openFile = new OpenFileDialog(); - - openFile.InitialDirectory = Application.ExecutablePath; - openFile.Filter = "rtf files (*.rtf)|*.rtf|txt files (*.txt)|*.txt|All files (*.*)|*.*" ; - openFile.FilterIndex = 1; - openFile.RestoreDirectory = true ; - - if(openFile.ShowDialog() == DialogResult.OK) - { - string fullName = openFile.FileName; - string fileName = Path.GetFileName(fullName); - - if (FindDocument(fileName) != null) - { - MessageBox.Show("The document: " + fileName + " has already opened!"); - return; - } - - DummyDoc dummyDoc = new DummyDoc(); - dummyDoc.Text = fileName; - dummyDoc.Show(dockPanel); - try - { - dummyDoc.FileName = fullName; - } - catch (Exception exception) - { - dummyDoc.Close(); - MessageBox.Show(exception.Message); - } - - } - } - - private void menuItemFile_Popup(object sender, System.EventArgs e) - { - if (dockPanel.DocumentStyle == DocumentStyle.SystemMdi) - { - menuItemClose.Enabled = menuItemCloseAll.Enabled = (ActiveMdiChild != null); - } - else - { - menuItemClose.Enabled = (dockPanel.ActiveDocument != null); - menuItemCloseAll.Enabled = (dockPanel.DocumentsCount > 0); - } - } - - private void menuItemClose_Click(object sender, System.EventArgs e) - { - if (dockPanel.DocumentStyle == DocumentStyle.SystemMdi) - ActiveMdiChild.Close(); - else if (dockPanel.ActiveDocument != null) - dockPanel.ActiveDocument.DockHandler.Close(); - } - - private void menuItemCloseAll_Click(object sender, System.EventArgs e) - { - CloseAllDocuments(); - } - - private void CloseAllDocuments() - { - if (dockPanel.DocumentStyle == DocumentStyle.SystemMdi) - { - foreach (Form form in MdiChildren) - form.Close(); - } - else - { - IDockContent[] documents = dockPanel.DocumentsToArray(); - foreach (IDockContent content in documents) - content.DockHandler.Close(); - } - } - - private IDockContent GetContentFromPersistString(string persistString) - { - if (persistString == typeof(DummySolutionExplorer).ToString()) - return m_solutionExplorer; - else if (persistString == typeof(DummyPropertyWindow).ToString()) - return m_propertyWindow; - else if (persistString == typeof(DummyToolbox).ToString()) - return m_toolbox; - else if (persistString == typeof(DummyOutputWindow).ToString()) - return m_outputWindow; - else if (persistString == typeof(DummyTaskList).ToString()) - return m_taskList; - else - { - string[] parsedStrings = persistString.Split(new char[] { ',' }); - if (parsedStrings.Length != 3) - return null; - - if (parsedStrings[0] != typeof(DummyDoc).ToString()) - return null; - - DummyDoc dummyDoc = new DummyDoc(); - if (parsedStrings[1] != string.Empty) - dummyDoc.FileName = parsedStrings[1]; - if (parsedStrings[2] != string.Empty) - dummyDoc.Text = parsedStrings[2]; - - return dummyDoc; - } - } - - private void MainForm_Load(object sender, System.EventArgs e) - { - string configFile = Path.Combine(Path.GetDirectoryName(Application.ExecutablePath), "DockPanel.config"); - - if (File.Exists(configFile)) - dockPanel.LoadFromXml(configFile, m_deserializeDockContent); - } - - private void MainForm_Closing(object sender, System.ComponentModel.CancelEventArgs e) - { - string configFile = Path.Combine(Path.GetDirectoryName(Application.ExecutablePath), "DockPanel.config"); - if (m_bSaveLayout) - dockPanel.SaveAsXml(configFile); - else if (File.Exists(configFile)) - File.Delete(configFile); - } - - private void menuItemToolBar_Click(object sender, System.EventArgs e) - { - toolBar.Visible = menuItemToolBar.Checked = !menuItemToolBar.Checked; - } - - private void menuItemStatusBar_Click(object sender, System.EventArgs e) - { - statusBar.Visible = menuItemStatusBar.Checked = !menuItemStatusBar.Checked; - } - - private void toolBar_ButtonClick(object sender, System.Windows.Forms.ToolStripItemClickedEventArgs e) - { - if (e.ClickedItem == toolBarButtonNew) - menuItemNew_Click(null, null); - else if (e.ClickedItem == toolBarButtonOpen) - menuItemOpen_Click(null, null); - else if (e.ClickedItem == toolBarButtonSolutionExplorer) - menuItemSolutionExplorer_Click(null, null); - else if (e.ClickedItem == toolBarButtonPropertyWindow) - menuItemPropertyWindow_Click(null, null); - else if (e.ClickedItem == toolBarButtonToolbox) - menuItemToolbox_Click(null, null); - else if (e.ClickedItem == toolBarButtonOutputWindow) - menuItemOutputWindow_Click(null, null); - else if (e.ClickedItem == toolBarButtonTaskList) - menuItemTaskList_Click(null, null); - else if (e.ClickedItem == toolBarButtonLayoutByCode) - menuItemLayoutByCode_Click(null, null); - else if (e.ClickedItem == toolBarButtonLayoutByXml) - menuItemLayoutByXml_Click(null, null); - } - - private void menuItemNewWindow_Click(object sender, System.EventArgs e) - { - MainForm newWindow = new MainForm(); - newWindow.Text = newWindow.Text + " - New"; - newWindow.Show(); - } - - private void menuItemTools_Popup(object sender, System.EventArgs e) - { - menuItemLockLayout.Checked = !this.dockPanel.AllowEndUserDocking; - } - - private void menuItemLockLayout_Click(object sender, System.EventArgs e) - { - dockPanel.AllowEndUserDocking = !dockPanel.AllowEndUserDocking; - } - - private void menuItemLayoutByCode_Click(object sender, System.EventArgs e) - { - dockPanel.SuspendLayout(true); - - m_solutionExplorer.Show(dockPanel, DockState.DockRight); - m_propertyWindow.Show(m_solutionExplorer.Pane, m_solutionExplorer); - m_toolbox.Show(dockPanel, new Rectangle(98, 133, 200, 383)); - m_outputWindow.Show(m_solutionExplorer.Pane, DockAlignment.Bottom, 0.35); - m_taskList.Show(m_toolbox.Pane, DockAlignment.Left, 0.4); - - CloseAllDocuments(); - DummyDoc doc1 = CreateNewDocument("Document1"); - DummyDoc doc2 = CreateNewDocument("Document2"); - DummyDoc doc3 = CreateNewDocument("Document3"); - DummyDoc doc4 = CreateNewDocument("Document4"); - doc1.Show(dockPanel, DockState.Document); - doc2.Show(doc1.Pane, null); - doc3.Show(doc1.Pane, DockAlignment.Bottom, 0.5); - doc4.Show(doc3.Pane, DockAlignment.Right, 0.5); - - dockPanel.ResumeLayout(true, true); - } - - private void menuItemLayoutByXml_Click(object sender, System.EventArgs e) - { - dockPanel.SuspendLayout(true); - - // In order to load layout from XML, we need to close all the DockContents - CloseAllContents(); - - Assembly assembly = Assembly.GetAssembly(typeof(MainForm)); - Stream xmlStream = assembly.GetManifestResourceStream("DockSample.Resources.DockPanel.xml"); - dockPanel.LoadFromXml(xmlStream, m_deserializeDockContent); - xmlStream.Close(); - - dockPanel.ResumeLayout(true, true); - } - - private void CloseAllContents() - { - // we don't want to create another instance of tool window, set DockPanel to null - m_solutionExplorer.DockPanel = null; - m_propertyWindow.DockPanel = null; - m_toolbox.DockPanel = null; - m_outputWindow.DockPanel = null; - m_taskList.DockPanel = null; - - // Close all other document windows - CloseAllDocuments(); - } - - private void SetSchema(object sender, System.EventArgs e) - { - CloseAllContents(); - - if (sender == menuItemSchemaVS2005) - Extender.SetSchema(dockPanel, Extender.Schema.VS2005); - else if (sender == menuItemSchemaVS2003) - Extender.SetSchema(dockPanel, Extender.Schema.VS2003); - - menuItemSchemaVS2005.Checked = (sender == menuItemSchemaVS2005); - menuItemSchemaVS2003.Checked = (sender == menuItemSchemaVS2003); - } - - private void SetDocumentStyle(object sender, System.EventArgs e) - { - DocumentStyle oldStyle = dockPanel.DocumentStyle; - DocumentStyle newStyle; - if (sender == menuItemDockingMdi) - newStyle = DocumentStyle.DockingMdi; - else if (sender == menuItemDockingWindow) - newStyle = DocumentStyle.DockingWindow; - else if (sender == menuItemDockingSdi) - newStyle = DocumentStyle.DockingSdi; - else - newStyle = DocumentStyle.SystemMdi; - - if (oldStyle == newStyle) - return; - - if (oldStyle == DocumentStyle.SystemMdi || newStyle == DocumentStyle.SystemMdi) - CloseAllDocuments(); - - dockPanel.DocumentStyle = newStyle; - menuItemDockingMdi.Checked = (newStyle == DocumentStyle.DockingMdi); - menuItemDockingWindow.Checked = (newStyle == DocumentStyle.DockingWindow); - menuItemDockingSdi.Checked = (newStyle == DocumentStyle.DockingSdi); - menuItemSystemMdi.Checked = (newStyle == DocumentStyle.SystemMdi); - menuItemLayoutByCode.Enabled = (newStyle != DocumentStyle.SystemMdi); - menuItemLayoutByXml.Enabled = (newStyle != DocumentStyle.SystemMdi); - toolBarButtonLayoutByCode.Enabled = (newStyle != DocumentStyle.SystemMdi); - toolBarButtonLayoutByXml.Enabled = (newStyle != DocumentStyle.SystemMdi); - } - - private void menuItemCloseAllButThisOne_Click(object sender, System.EventArgs e) - { - if (dockPanel.DocumentStyle == DocumentStyle.SystemMdi) - { - Form activeMdi = ActiveMdiChild; - foreach (Form form in MdiChildren) - { - if (form != activeMdi) - form.Close(); - } - } - else - { - foreach (IDockContent document in dockPanel.DocumentsToArray()) - { - if (!document.DockHandler.IsActivated) - document.DockHandler.Close(); - } - } - } - - private void menuItemShowDocumentIcon_Click(object sender, System.EventArgs e) - { - dockPanel.ShowDocumentIcon = menuItemShowDocumentIcon.Checked= !menuItemShowDocumentIcon.Checked; - } - - private void showRightToLeft_Click(object sender, EventArgs e) - { - CloseAllContents(); - if (showRightToLeft.Checked) - { - this.RightToLeft = RightToLeft.No; - this.RightToLeftLayout = false; - } - else - { - this.RightToLeft = RightToLeft.Yes; - this.RightToLeftLayout = true; - } - m_solutionExplorer.RightToLeftLayout = this.RightToLeftLayout; - showRightToLeft.Checked = !showRightToLeft.Checked; - } - - private void exitWithoutSavingLayout_Click(object sender, EventArgs e) - { - m_bSaveLayout = false; - Close(); - m_bSaveLayout = true; - } - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/MainForm.resx b/src/Libraries/DockPanel_Src/DockSample/MainForm.resx deleted file mode 100644 index ad5859d12b..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/MainForm.resx +++ /dev/null @@ -1,194 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 296, 8 - - - 16, 2 - - - 114, 5 - - - - AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj0yLjAuMC4w - LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0 - ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAADY - DAAAAk1TRnQBSQFMAgEBCQEAAQ4BAAEEAQABEAEAARABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo - AwABQAMAATADAAEBAQABCAYAAQwYAAGAAgABgAMAAoABAAGAAwABgAEAAYABAAKAAgADwAEAAcAB3AHA - AQAB8AHKAaYBAAEzBQABMwEAATMBAAEzAQACMwIAAxYBAAMcAQADIgEAAykBAANVAQADTQEAA0IBAAM5 - AQABgAF8Af8BAAJQAf8BAAGTAQAB1gEAAf8B7AHMAQABxgHWAe8BAAHWAucBAAGQAakBrQIAAf8BMwMA - AWYDAAGZAwABzAIAATMDAAIzAgABMwFmAgABMwGZAgABMwHMAgABMwH/AgABZgMAAWYBMwIAAmYCAAFm - AZkCAAFmAcwCAAFmAf8CAAGZAwABmQEzAgABmQFmAgACmQIAAZkBzAIAAZkB/wIAAcwDAAHMATMCAAHM - AWYCAAHMAZkCAALMAgABzAH/AgAB/wFmAgAB/wGZAgAB/wHMAQABMwH/AgAB/wEAAT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AAGAAQEGAAGAAQEGAAGAAQEGAAGAAQEGAAGAAQEGAAGAAQEGAAGAAQEGAAGA - AQEGAAGAAQEGAAGAAQEGAAGAAQsGAAGAAQcGAAGAAQ8GAAL/BgAG/wHAAQEBnwHPAv8B4AEHAcABAQKP - AcABAwHAAQMBwAEBAccBHwHAAQMBwAEDAcABAQHiAT8BwAEDAcABAwHAAQEB8AF/AcABAwHAAQMBwAEB - AfgB/wHAAQMBwAEDAcABAQHwAXsBwAEDAcABAwHAAQEBAgExAcABAwHAAQMBwAEBAQcBAAHAAQMBwAED - AcABAQFnAYEBwAEDAcABAwHAAQEB5wGDAcABAwHAAQMBwAEBAccBAwHAAQMBwAEDAcABCwH8AQcBwAED - AeABBwHAAQcB/gEfAv8B/AE/AcABDxT/AfwBYwEAAQ8BwAEHAQABHwH4AQEBAAEPAcABBwEAAQ8BgAIA - AQ8BwAEHAQABBwGAAgABDwHAAQcBAAEDAYACAAEPAcABBwEAAQEBgAIAAQ8BwAEHAgABgAEBAQABDwHA - AQcBAAEfAYABAwEIAY4BwAEHAQABHwGAAQMBBQFEAcABBwEAAR8BgAEDAQIBuAHAAQcBjwHxAYABAwH9 - AXwBwAEPAf8B+QGAAQMB/gH8AcABHwH/AXUBgAEDAf8BAAHAAT8B/wGPAYABAwH/AfwI/ws= - - - - 211, 5 - - \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/MainForm2.Designer.cs b/src/Libraries/DockPanel_Src/DockSample/MainForm2.Designer.cs deleted file mode 100644 index 073f668207..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/MainForm2.Designer.cs +++ /dev/null @@ -1,635 +0,0 @@ -namespace DockSample -{ - partial class MainForm2 - { - /// - /// Required designer variable. - /// - private System.ComponentModel.IContainer components = null; - - /// - /// Clean up any resources being used. - /// - /// true if managed resources should be disposed; otherwise, false. - protected override void Dispose(bool disposing) - { - if (disposing && (components != null)) - { - components.Dispose(); - } - base.Dispose(disposing); - } - - #region Windows Form Designer generated code - /// - /// Required method for Designer support - do not modify - /// the contents of this method with the code editor. - /// - private void InitializeComponent() - { - this.components = new System.ComponentModel.Container(); - System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(MainForm2)); - this.mainMenu = new System.Windows.Forms.MenuStrip(); - this.menuItemFile = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemNew = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemOpen = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemClose = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemCloseAll = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemCloseAllButThisOne = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItem4 = new System.Windows.Forms.ToolStripSeparator(); - this.menuItemExit = new System.Windows.Forms.ToolStripMenuItem(); - this.exitWithoutSavingLayout = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemView = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemSolutionExplorer = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemPropertyWindow = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemToolbox = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemOutputWindow = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemTaskList = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItem1 = new System.Windows.Forms.ToolStripSeparator(); - this.menuItemToolBar = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemStatusBar = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItem2 = new System.Windows.Forms.ToolStripSeparator(); - this.menuItemLayoutByCode = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemLayoutByXml = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemTools = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemLockLayout = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemShowDocumentIcon = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItem3 = new System.Windows.Forms.ToolStripSeparator(); - this.menuItemSchemaVS2005 = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemSchemaVS2003 = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItem6 = new System.Windows.Forms.ToolStripSeparator(); - this.menuItemDockingMdi = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemDockingSdi = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemDockingWindow = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemSystemMdi = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItem5 = new System.Windows.Forms.ToolStripSeparator(); - this.showRightToLeft = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemWindow = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemNewWindow = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemHelp = new System.Windows.Forms.ToolStripMenuItem(); - this.menuItemAbout = new System.Windows.Forms.ToolStripMenuItem(); - this.imageList = new System.Windows.Forms.ImageList(this.components); - this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel(); - this.toolBar = new System.Windows.Forms.ToolStrip(); - this.toolBarButtonNew = new System.Windows.Forms.ToolStripButton(); - this.toolBarButtonOpen = new System.Windows.Forms.ToolStripButton(); - this.toolBarButtonSeparator1 = new System.Windows.Forms.ToolStripSeparator(); - this.toolBarButtonSolutionExplorer = new System.Windows.Forms.ToolStripButton(); - this.toolBarButtonPropertyWindow = new System.Windows.Forms.ToolStripButton(); - this.toolBarButtonToolbox = new System.Windows.Forms.ToolStripButton(); - this.toolBarButtonOutputWindow = new System.Windows.Forms.ToolStripButton(); - this.toolBarButtonTaskList = new System.Windows.Forms.ToolStripButton(); - this.toolBarButtonSeparator2 = new System.Windows.Forms.ToolStripSeparator(); - this.toolBarButtonLayoutByCode = new System.Windows.Forms.ToolStripButton(); - this.toolBarButtonLayoutByXml = new System.Windows.Forms.ToolStripButton(); - this.dockPanel = new WeifenLuo.WinFormsUI.Docking.DockPanel(); - this.statusBar = new System.Windows.Forms.StatusStrip(); - this.mainMenu.SuspendLayout(); - this.tableLayoutPanel1.SuspendLayout(); - this.toolBar.SuspendLayout(); - this.SuspendLayout(); - // - // mainMenu - // - this.mainMenu.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.menuItemFile, - this.menuItemView, - this.menuItemTools, - this.menuItemWindow, - this.menuItemHelp}); - this.mainMenu.Location = new System.Drawing.Point(0, 0); - this.mainMenu.MdiWindowListItem = this.menuItemWindow; - this.mainMenu.Name = "mainMenu"; - this.mainMenu.Size = new System.Drawing.Size(579, 24); - this.mainMenu.TabIndex = 7; - // - // menuItemFile - // - this.menuItemFile.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.menuItemNew, - this.menuItemOpen, - this.menuItemClose, - this.menuItemCloseAll, - this.menuItemCloseAllButThisOne, - this.menuItem4, - this.menuItemExit, - this.exitWithoutSavingLayout}); - this.menuItemFile.Name = "menuItemFile"; - this.menuItemFile.Size = new System.Drawing.Size(35, 20); - this.menuItemFile.Text = "&File"; - this.menuItemFile.DropDownOpening += new System.EventHandler(this.menuItemFile_Popup); - // - // menuItemNew - // - this.menuItemNew.Name = "menuItemNew"; - this.menuItemNew.Size = new System.Drawing.Size(204, 22); - this.menuItemNew.Text = "&New"; - this.menuItemNew.Click += new System.EventHandler(this.menuItemNew_Click); - // - // menuItemOpen - // - this.menuItemOpen.Name = "menuItemOpen"; - this.menuItemOpen.Size = new System.Drawing.Size(204, 22); - this.menuItemOpen.Text = "&Open..."; - this.menuItemOpen.Click += new System.EventHandler(this.menuItemOpen_Click); - // - // menuItemClose - // - this.menuItemClose.Name = "menuItemClose"; - this.menuItemClose.Size = new System.Drawing.Size(204, 22); - this.menuItemClose.Text = "&Close"; - this.menuItemClose.Click += new System.EventHandler(this.menuItemClose_Click); - // - // menuItemCloseAll - // - this.menuItemCloseAll.Name = "menuItemCloseAll"; - this.menuItemCloseAll.Size = new System.Drawing.Size(204, 22); - this.menuItemCloseAll.Text = "Close &All"; - this.menuItemCloseAll.Click += new System.EventHandler(this.menuItemCloseAll_Click); - // - // menuItemCloseAllButThisOne - // - this.menuItemCloseAllButThisOne.Name = "menuItemCloseAllButThisOne"; - this.menuItemCloseAllButThisOne.Size = new System.Drawing.Size(204, 22); - this.menuItemCloseAllButThisOne.Text = "Close All &But This One"; - this.menuItemCloseAllButThisOne.Click += new System.EventHandler(this.menuItemCloseAllButThisOne_Click); - // - // menuItem4 - // - this.menuItem4.Name = "menuItem4"; - this.menuItem4.Size = new System.Drawing.Size(201, 6); - // - // menuItemExit - // - this.menuItemExit.Name = "menuItemExit"; - this.menuItemExit.Size = new System.Drawing.Size(204, 22); - this.menuItemExit.Text = "&Exit"; - this.menuItemExit.Click += new System.EventHandler(this.menuItemExit_Click); - // - // exitWithoutSavingLayout - // - this.exitWithoutSavingLayout.Name = "exitWithoutSavingLayout"; - this.exitWithoutSavingLayout.Size = new System.Drawing.Size(204, 22); - this.exitWithoutSavingLayout.Text = "Exit &Without Saving Layout"; - this.exitWithoutSavingLayout.Click += new System.EventHandler(this.exitWithoutSavingLayout_Click); - // - // menuItemView - // - this.menuItemView.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.menuItemSolutionExplorer, - this.menuItemPropertyWindow, - this.menuItemToolbox, - this.menuItemOutputWindow, - this.menuItemTaskList, - this.menuItem1, - this.menuItemToolBar, - this.menuItemStatusBar, - this.menuItem2, - this.menuItemLayoutByCode, - this.menuItemLayoutByXml}); - this.menuItemView.MergeIndex = 1; - this.menuItemView.Name = "menuItemView"; - this.menuItemView.Size = new System.Drawing.Size(41, 20); - this.menuItemView.Text = "&View"; - // - // menuItemSolutionExplorer - // - this.menuItemSolutionExplorer.Name = "menuItemSolutionExplorer"; - this.menuItemSolutionExplorer.Size = new System.Drawing.Size(176, 22); - this.menuItemSolutionExplorer.Text = "&Solution Explorer"; - this.menuItemSolutionExplorer.Click += new System.EventHandler(this.menuItemSolutionExplorer_Click); - // - // menuItemPropertyWindow - // - this.menuItemPropertyWindow.Name = "menuItemPropertyWindow"; - this.menuItemPropertyWindow.ShortcutKeys = System.Windows.Forms.Keys.F4; - this.menuItemPropertyWindow.Size = new System.Drawing.Size(176, 22); - this.menuItemPropertyWindow.Text = "&Property Window"; - this.menuItemPropertyWindow.Click += new System.EventHandler(this.menuItemPropertyWindow_Click); - // - // menuItemToolbox - // - this.menuItemToolbox.Name = "menuItemToolbox"; - this.menuItemToolbox.Size = new System.Drawing.Size(176, 22); - this.menuItemToolbox.Text = "&Toolbox"; - this.menuItemToolbox.Click += new System.EventHandler(this.menuItemToolbox_Click); - // - // menuItemOutputWindow - // - this.menuItemOutputWindow.Name = "menuItemOutputWindow"; - this.menuItemOutputWindow.Size = new System.Drawing.Size(176, 22); - this.menuItemOutputWindow.Text = "&Output Window"; - this.menuItemOutputWindow.Click += new System.EventHandler(this.menuItemOutputWindow_Click); - // - // menuItemTaskList - // - this.menuItemTaskList.Name = "menuItemTaskList"; - this.menuItemTaskList.Size = new System.Drawing.Size(176, 22); - this.menuItemTaskList.Text = "Task &List"; - this.menuItemTaskList.Click += new System.EventHandler(this.menuItemTaskList_Click); - // - // menuItem1 - // - this.menuItem1.Name = "menuItem1"; - this.menuItem1.Size = new System.Drawing.Size(173, 6); - // - // menuItemToolBar - // - this.menuItemToolBar.Checked = true; - this.menuItemToolBar.CheckState = System.Windows.Forms.CheckState.Checked; - this.menuItemToolBar.Name = "menuItemToolBar"; - this.menuItemToolBar.Size = new System.Drawing.Size(176, 22); - this.menuItemToolBar.Text = "Tool &Bar"; - this.menuItemToolBar.Click += new System.EventHandler(this.menuItemToolBar_Click); - // - // menuItemStatusBar - // - this.menuItemStatusBar.Checked = true; - this.menuItemStatusBar.CheckState = System.Windows.Forms.CheckState.Checked; - this.menuItemStatusBar.Name = "menuItemStatusBar"; - this.menuItemStatusBar.Size = new System.Drawing.Size(176, 22); - this.menuItemStatusBar.Text = "Status B&ar"; - this.menuItemStatusBar.Click += new System.EventHandler(this.menuItemStatusBar_Click); - // - // menuItem2 - // - this.menuItem2.Name = "menuItem2"; - this.menuItem2.Size = new System.Drawing.Size(173, 6); - // - // menuItemLayoutByCode - // - this.menuItemLayoutByCode.Name = "menuItemLayoutByCode"; - this.menuItemLayoutByCode.Size = new System.Drawing.Size(176, 22); - this.menuItemLayoutByCode.Text = "Layout By &Code"; - this.menuItemLayoutByCode.Click += new System.EventHandler(this.menuItemLayoutByCode_Click); - // - // menuItemLayoutByXml - // - this.menuItemLayoutByXml.Name = "menuItemLayoutByXml"; - this.menuItemLayoutByXml.Size = new System.Drawing.Size(176, 22); - this.menuItemLayoutByXml.Text = "Layout By &XML"; - this.menuItemLayoutByXml.Click += new System.EventHandler(this.menuItemLayoutByXml_Click); - // - // menuItemTools - // - this.menuItemTools.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.menuItemLockLayout, - this.menuItemShowDocumentIcon, - this.menuItem3, - this.menuItemSchemaVS2005, - this.menuItemSchemaVS2003, - this.menuItem6, - this.menuItemDockingMdi, - this.menuItemDockingSdi, - this.menuItemDockingWindow, - this.menuItemSystemMdi, - this.menuItem5, - this.showRightToLeft}); - this.menuItemTools.MergeIndex = 2; - this.menuItemTools.Name = "menuItemTools"; - this.menuItemTools.Size = new System.Drawing.Size(44, 20); - this.menuItemTools.Text = "&Tools"; - this.menuItemTools.DropDownOpening += new System.EventHandler(this.menuItemTools_Popup); - // - // menuItemLockLayout - // - this.menuItemLockLayout.Name = "menuItemLockLayout"; - this.menuItemLockLayout.Size = new System.Drawing.Size(234, 22); - this.menuItemLockLayout.Text = "&Lock Layout"; - this.menuItemLockLayout.Click += new System.EventHandler(this.menuItemLockLayout_Click); - // - // menuItemShowDocumentIcon - // - this.menuItemShowDocumentIcon.Name = "menuItemShowDocumentIcon"; - this.menuItemShowDocumentIcon.Size = new System.Drawing.Size(234, 22); - this.menuItemShowDocumentIcon.Text = "&Show Document Icon"; - this.menuItemShowDocumentIcon.Click += new System.EventHandler(this.menuItemShowDocumentIcon_Click); - // - // menuItem3 - // - this.menuItem3.Name = "menuItem3"; - this.menuItem3.Size = new System.Drawing.Size(231, 6); - // - // menuItemSchemaVS2005 - // - this.menuItemSchemaVS2005.Checked = true; - this.menuItemSchemaVS2005.CheckState = System.Windows.Forms.CheckState.Checked; - this.menuItemSchemaVS2005.Name = "menuItemSchemaVS2005"; - this.menuItemSchemaVS2005.Size = new System.Drawing.Size(234, 22); - this.menuItemSchemaVS2005.Text = "Schema: VS200&5"; - this.menuItemSchemaVS2005.Click += new System.EventHandler(this.SetSchema); - // - // menuItemSchemaVS2003 - // - this.menuItemSchemaVS2003.Name = "menuItemSchemaVS2003"; - this.menuItemSchemaVS2003.Size = new System.Drawing.Size(234, 22); - this.menuItemSchemaVS2003.Text = "Schema: VS200&3"; - this.menuItemSchemaVS2003.Click += new System.EventHandler(this.SetSchema); - // - // menuItem6 - // - this.menuItem6.Name = "menuItem6"; - this.menuItem6.Size = new System.Drawing.Size(231, 6); - // - // menuItemDockingMdi - // - this.menuItemDockingMdi.Checked = true; - this.menuItemDockingMdi.CheckState = System.Windows.Forms.CheckState.Checked; - this.menuItemDockingMdi.Name = "menuItemDockingMdi"; - this.menuItemDockingMdi.Size = new System.Drawing.Size(234, 22); - this.menuItemDockingMdi.Text = "Document Style: Docking &MDI"; - this.menuItemDockingMdi.Click += new System.EventHandler(this.SetDocumentStyle); - // - // menuItemDockingSdi - // - this.menuItemDockingSdi.Name = "menuItemDockingSdi"; - this.menuItemDockingSdi.Size = new System.Drawing.Size(234, 22); - this.menuItemDockingSdi.Text = "Document Style: Docking &SDI"; - this.menuItemDockingSdi.Click += new System.EventHandler(this.SetDocumentStyle); - // - // menuItemDockingWindow - // - this.menuItemDockingWindow.Name = "menuItemDockingWindow"; - this.menuItemDockingWindow.Size = new System.Drawing.Size(234, 22); - this.menuItemDockingWindow.Text = "Document Style: Docking &Window"; - this.menuItemDockingWindow.Click += new System.EventHandler(this.SetDocumentStyle); - // - // menuItemSystemMdi - // - this.menuItemSystemMdi.Name = "menuItemSystemMdi"; - this.menuItemSystemMdi.Size = new System.Drawing.Size(234, 22); - this.menuItemSystemMdi.Text = "Document Style: S&ystem MDI"; - this.menuItemSystemMdi.Click += new System.EventHandler(this.SetDocumentStyle); - // - // menuItem5 - // - this.menuItem5.Name = "menuItem5"; - this.menuItem5.Size = new System.Drawing.Size(231, 6); - // - // showRightToLeft - // - this.showRightToLeft.Name = "showRightToLeft"; - this.showRightToLeft.Size = new System.Drawing.Size(234, 22); - this.showRightToLeft.Text = "Show &Right-To-Left"; - this.showRightToLeft.Click += new System.EventHandler(this.showRightToLeft_Click); - // - // menuItemWindow - // - this.menuItemWindow.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.menuItemNewWindow}); - this.menuItemWindow.MergeIndex = 2; - this.menuItemWindow.Name = "menuItemWindow"; - this.menuItemWindow.Size = new System.Drawing.Size(57, 20); - this.menuItemWindow.Text = "&Window"; - // - // menuItemNewWindow - // - this.menuItemNewWindow.Name = "menuItemNewWindow"; - this.menuItemNewWindow.Size = new System.Drawing.Size(136, 22); - this.menuItemNewWindow.Text = "&New Window"; - this.menuItemNewWindow.Click += new System.EventHandler(this.menuItemNewWindow_Click); - // - // menuItemHelp - // - this.menuItemHelp.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.menuItemAbout}); - this.menuItemHelp.MergeIndex = 3; - this.menuItemHelp.Name = "menuItemHelp"; - this.menuItemHelp.Size = new System.Drawing.Size(40, 20); - this.menuItemHelp.Text = "&Help"; - // - // menuItemAbout - // - this.menuItemAbout.Name = "menuItemAbout"; - this.menuItemAbout.Size = new System.Drawing.Size(175, 22); - this.menuItemAbout.Text = "&About DockSample..."; - this.menuItemAbout.Click += new System.EventHandler(this.menuItemAbout_Click); - // - // imageList - // - this.imageList.ImageStream = ((System.Windows.Forms.ImageListStreamer)(resources.GetObject("imageList.ImageStream"))); - this.imageList.TransparentColor = System.Drawing.Color.Transparent; - this.imageList.Images.SetKeyName(0, ""); - this.imageList.Images.SetKeyName(1, ""); - this.imageList.Images.SetKeyName(2, ""); - this.imageList.Images.SetKeyName(3, ""); - this.imageList.Images.SetKeyName(4, ""); - this.imageList.Images.SetKeyName(5, ""); - this.imageList.Images.SetKeyName(6, ""); - this.imageList.Images.SetKeyName(7, ""); - this.imageList.Images.SetKeyName(8, ""); - // - // tableLayoutPanel1 - // - this.tableLayoutPanel1.ColumnCount = 1; - this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F)); - this.tableLayoutPanel1.Controls.Add(this.toolBar, 0, 0); - this.tableLayoutPanel1.Controls.Add(this.dockPanel, 0, 1); - this.tableLayoutPanel1.Controls.Add(this.statusBar, 0, 2); - this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill; - this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 24); - this.tableLayoutPanel1.Name = "tableLayoutPanel1"; - this.tableLayoutPanel1.RowCount = 2; - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle()); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F)); - this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle()); - this.tableLayoutPanel1.Size = new System.Drawing.Size(579, 385); - this.tableLayoutPanel1.TabIndex = 9; - // - // toolBar - // - this.toolBar.ImageList = this.imageList; - this.toolBar.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.toolBarButtonNew, - this.toolBarButtonOpen, - this.toolBarButtonSeparator1, - this.toolBarButtonSolutionExplorer, - this.toolBarButtonPropertyWindow, - this.toolBarButtonToolbox, - this.toolBarButtonOutputWindow, - this.toolBarButtonTaskList, - this.toolBarButtonSeparator2, - this.toolBarButtonLayoutByCode, - this.toolBarButtonLayoutByXml}); - this.toolBar.Location = new System.Drawing.Point(0, 0); - this.toolBar.Name = "toolBar"; - this.toolBar.Size = new System.Drawing.Size(579, 25); - this.toolBar.TabIndex = 7; - // - // toolBarButtonNew - // - this.toolBarButtonNew.ImageIndex = 0; - this.toolBarButtonNew.Name = "toolBarButtonNew"; - this.toolBarButtonNew.Size = new System.Drawing.Size(23, 22); - this.toolBarButtonNew.ToolTipText = "Show Layout From XML"; - // - // toolBarButtonOpen - // - this.toolBarButtonOpen.ImageIndex = 1; - this.toolBarButtonOpen.Name = "toolBarButtonOpen"; - this.toolBarButtonOpen.Size = new System.Drawing.Size(23, 22); - this.toolBarButtonOpen.ToolTipText = "Open"; - // - // toolBarButtonSeparator1 - // - this.toolBarButtonSeparator1.Name = "toolBarButtonSeparator1"; - this.toolBarButtonSeparator1.Size = new System.Drawing.Size(6, 25); - // - // toolBarButtonSolutionExplorer - // - this.toolBarButtonSolutionExplorer.ImageIndex = 2; - this.toolBarButtonSolutionExplorer.Name = "toolBarButtonSolutionExplorer"; - this.toolBarButtonSolutionExplorer.Size = new System.Drawing.Size(23, 22); - this.toolBarButtonSolutionExplorer.ToolTipText = "Solution Explorer"; - // - // toolBarButtonPropertyWindow - // - this.toolBarButtonPropertyWindow.ImageIndex = 3; - this.toolBarButtonPropertyWindow.Name = "toolBarButtonPropertyWindow"; - this.toolBarButtonPropertyWindow.Size = new System.Drawing.Size(23, 22); - this.toolBarButtonPropertyWindow.ToolTipText = "Property Window"; - // - // toolBarButtonToolbox - // - this.toolBarButtonToolbox.ImageIndex = 4; - this.toolBarButtonToolbox.Name = "toolBarButtonToolbox"; - this.toolBarButtonToolbox.Size = new System.Drawing.Size(23, 22); - this.toolBarButtonToolbox.ToolTipText = "Tool Box"; - // - // toolBarButtonOutputWindow - // - this.toolBarButtonOutputWindow.ImageIndex = 5; - this.toolBarButtonOutputWindow.Name = "toolBarButtonOutputWindow"; - this.toolBarButtonOutputWindow.Size = new System.Drawing.Size(23, 22); - this.toolBarButtonOutputWindow.ToolTipText = "Output Window"; - // - // toolBarButtonTaskList - // - this.toolBarButtonTaskList.ImageIndex = 6; - this.toolBarButtonTaskList.Name = "toolBarButtonTaskList"; - this.toolBarButtonTaskList.Size = new System.Drawing.Size(23, 22); - this.toolBarButtonTaskList.ToolTipText = "Task List"; - // - // toolBarButtonSeparator2 - // - this.toolBarButtonSeparator2.Name = "toolBarButtonSeparator2"; - this.toolBarButtonSeparator2.Size = new System.Drawing.Size(6, 25); - // - // toolBarButtonLayoutByCode - // - this.toolBarButtonLayoutByCode.ImageIndex = 7; - this.toolBarButtonLayoutByCode.Name = "toolBarButtonLayoutByCode"; - this.toolBarButtonLayoutByCode.Size = new System.Drawing.Size(23, 22); - this.toolBarButtonLayoutByCode.ToolTipText = "Show Layout By Code"; - // - // toolBarButtonLayoutByXml - // - this.toolBarButtonLayoutByXml.ImageIndex = 8; - this.toolBarButtonLayoutByXml.Name = "toolBarButtonLayoutByXml"; - this.toolBarButtonLayoutByXml.Size = new System.Drawing.Size(23, 22); - this.toolBarButtonLayoutByXml.ToolTipText = "Show layout by predefined XML file"; - // - // dockPanel - // - this.dockPanel.ActiveAutoHideContent = null; - this.dockPanel.Dock = System.Windows.Forms.DockStyle.Fill; - this.dockPanel.DockBottomPortion = 150; - this.dockPanel.DockLeftPortion = 200; - this.dockPanel.DockRightPortion = 200; - this.dockPanel.DockTopPortion = 150; - this.dockPanel.DocumentStyle = WeifenLuo.WinFormsUI.Docking.DocumentStyle.DockingWindow; - this.dockPanel.Font = new System.Drawing.Font("Tahoma", 11F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.World, ((byte)(0))); - this.dockPanel.Location = new System.Drawing.Point(3, 28); - this.dockPanel.Name = "dockPanel"; - this.dockPanel.RightToLeftLayout = true; - this.dockPanel.Size = new System.Drawing.Size(573, 332); - this.dockPanel.TabIndex = 10; - // - // statusBar - // - this.statusBar.Location = new System.Drawing.Point(0, 363); - this.statusBar.Name = "statusBar"; - this.statusBar.Size = new System.Drawing.Size(579, 22); - this.statusBar.TabIndex = 8; - // - // MainForm2 - // - this.ClientSize = new System.Drawing.Size(579, 409); - this.Controls.Add(this.tableLayoutPanel1); - this.Controls.Add(this.mainMenu); - this.IsMdiContainer = true; - this.MainMenuStrip = this.mainMenu; - this.Name = "MainForm2"; - this.Text = "DockSample"; - this.WindowState = System.Windows.Forms.FormWindowState.Maximized; - this.Closing += new System.ComponentModel.CancelEventHandler(this.MainForm_Closing); - this.Load += new System.EventHandler(this.MainForm_Load); - this.mainMenu.ResumeLayout(false); - this.mainMenu.PerformLayout(); - this.tableLayoutPanel1.ResumeLayout(false); - this.tableLayoutPanel1.PerformLayout(); - this.toolBar.ResumeLayout(false); - this.toolBar.PerformLayout(); - this.ResumeLayout(false); - this.PerformLayout(); - - } - #endregion - - private System.Windows.Forms.ImageList imageList; - private System.Windows.Forms.MenuStrip mainMenu; - private System.Windows.Forms.ToolStripMenuItem menuItemFile; - private System.Windows.Forms.ToolStripMenuItem menuItemNew; - private System.Windows.Forms.ToolStripMenuItem menuItemOpen; - private System.Windows.Forms.ToolStripMenuItem menuItemClose; - private System.Windows.Forms.ToolStripMenuItem menuItemCloseAll; - private System.Windows.Forms.ToolStripMenuItem menuItemCloseAllButThisOne; - private System.Windows.Forms.ToolStripSeparator menuItem4; - private System.Windows.Forms.ToolStripMenuItem menuItemExit; - private System.Windows.Forms.ToolStripMenuItem menuItemView; - private System.Windows.Forms.ToolStripMenuItem menuItemSolutionExplorer; - private System.Windows.Forms.ToolStripMenuItem menuItemPropertyWindow; - private System.Windows.Forms.ToolStripMenuItem menuItemToolbox; - private System.Windows.Forms.ToolStripMenuItem menuItemOutputWindow; - private System.Windows.Forms.ToolStripMenuItem menuItemTaskList; - private System.Windows.Forms.ToolStripSeparator menuItem1; - private System.Windows.Forms.ToolStripMenuItem menuItemToolBar; - private System.Windows.Forms.ToolStripMenuItem menuItemStatusBar; - private System.Windows.Forms.ToolStripSeparator menuItem2; - private System.Windows.Forms.ToolStripMenuItem menuItemLayoutByCode; - private System.Windows.Forms.ToolStripMenuItem menuItemLayoutByXml; - private System.Windows.Forms.ToolStripMenuItem menuItemTools; - private System.Windows.Forms.ToolStripMenuItem menuItemLockLayout; - private System.Windows.Forms.ToolStripSeparator menuItem3; - private System.Windows.Forms.ToolStripMenuItem menuItemSchemaVS2005; - private System.Windows.Forms.ToolStripMenuItem menuItemSchemaVS2003; - private System.Windows.Forms.ToolStripSeparator menuItem6; - private System.Windows.Forms.ToolStripMenuItem menuItemDockingMdi; - private System.Windows.Forms.ToolStripMenuItem menuItemDockingSdi; - private System.Windows.Forms.ToolStripMenuItem menuItemDockingWindow; - private System.Windows.Forms.ToolStripMenuItem menuItemSystemMdi; - private System.Windows.Forms.ToolStripSeparator menuItem5; - private System.Windows.Forms.ToolStripMenuItem menuItemShowDocumentIcon; - private System.Windows.Forms.ToolStripMenuItem menuItemWindow; - private System.Windows.Forms.ToolStripMenuItem menuItemNewWindow; - private System.Windows.Forms.ToolStripMenuItem menuItemHelp; - private System.Windows.Forms.ToolStripMenuItem menuItemAbout; - private System.Windows.Forms.ToolStripMenuItem showRightToLeft; - private System.Windows.Forms.ToolStripMenuItem exitWithoutSavingLayout; - private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1; - private WeifenLuo.WinFormsUI.Docking.DockPanel dockPanel; - private System.Windows.Forms.StatusStrip statusBar; - private System.Windows.Forms.ToolStrip toolBar; - private System.Windows.Forms.ToolStripButton toolBarButtonNew; - private System.Windows.Forms.ToolStripButton toolBarButtonOpen; - private System.Windows.Forms.ToolStripSeparator toolBarButtonSeparator1; - private System.Windows.Forms.ToolStripButton toolBarButtonSolutionExplorer; - private System.Windows.Forms.ToolStripButton toolBarButtonPropertyWindow; - private System.Windows.Forms.ToolStripButton toolBarButtonToolbox; - private System.Windows.Forms.ToolStripButton toolBarButtonOutputWindow; - private System.Windows.Forms.ToolStripButton toolBarButtonTaskList; - private System.Windows.Forms.ToolStripSeparator toolBarButtonSeparator2; - private System.Windows.Forms.ToolStripButton toolBarButtonLayoutByCode; - private System.Windows.Forms.ToolStripButton toolBarButtonLayoutByXml; - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/MainForm2.cs b/src/Libraries/DockPanel_Src/DockSample/MainForm2.cs deleted file mode 100644 index dfe83880cb..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/MainForm2.cs +++ /dev/null @@ -1,443 +0,0 @@ -using System; -using System.Drawing; -using System.Collections; -using System.ComponentModel; -using System.Reflection; -using System.Windows.Forms; -using System.IO; -using WeifenLuo.WinFormsUI.Docking; -using DockSample.Customization; - -namespace DockSample -{ - public partial class MainForm2 : Form - { - private bool m_bSaveLayout = true; - private DeserializeDockContent m_deserializeDockContent; - private DummySolutionExplorer m_solutionExplorer = new DummySolutionExplorer(); - private DummyPropertyWindow m_propertyWindow = new DummyPropertyWindow(); - private DummyToolbox m_toolbox = new DummyToolbox(); - private DummyOutputWindow m_outputWindow = new DummyOutputWindow(); - private DummyTaskList m_taskList = new DummyTaskList(); - - public MainForm2() - { - InitializeComponent(); - showRightToLeft.Checked = (RightToLeft == RightToLeft.Yes); - RightToLeftLayout = showRightToLeft.Checked; - m_solutionExplorer = new DummySolutionExplorer(); - m_solutionExplorer.RightToLeftLayout = RightToLeftLayout; - m_deserializeDockContent = new DeserializeDockContent(GetContentFromPersistString); - } - - private void menuItemExit_Click(object sender, System.EventArgs e) - { - Close(); - } - - private void menuItemSolutionExplorer_Click(object sender, System.EventArgs e) - { - m_solutionExplorer.Show(dockPanel); - } - - private void menuItemPropertyWindow_Click(object sender, System.EventArgs e) - { - m_propertyWindow.Show(dockPanel); - } - - private void menuItemToolbox_Click(object sender, System.EventArgs e) - { - m_toolbox.Show(dockPanel); - } - - private void menuItemOutputWindow_Click(object sender, System.EventArgs e) - { - m_outputWindow.Show(dockPanel); - } - - private void menuItemTaskList_Click(object sender, System.EventArgs e) - { - m_taskList.Show(dockPanel); - } - - private void menuItemAbout_Click(object sender, System.EventArgs e) - { - AboutDialog aboutDialog = new AboutDialog(); - aboutDialog.ShowDialog(this); - } - - private IDockContent FindDocument(string text) - { - if (dockPanel.DocumentStyle == DocumentStyle.SystemMdi) - { - foreach (Form form in MdiChildren) - if (form.Text == text) - return form as IDockContent; - - return null; - } - else - { - foreach (IDockContent content in dockPanel.Documents) - if (content.DockHandler.TabText == text) - return content; - - return null; - } - } - - private void menuItemNew_Click(object sender, System.EventArgs e) - { - DummyDoc dummyDoc = CreateNewDocument(); - if (dockPanel.DocumentStyle == DocumentStyle.SystemMdi) - { - dummyDoc.MdiParent = this; - dummyDoc.Show(); - } - else - dummyDoc.Show(dockPanel); - } - - private DummyDoc CreateNewDocument() - { - DummyDoc dummyDoc = new DummyDoc(); - - int count = 1; - //string text = "C:\\MADFDKAJ\\ADAKFJASD\\ADFKDSAKFJASD\\ASDFKASDFJASDF\\ASDFIJADSFJ\\ASDFKDFDA" + count.ToString(); - string text = "Document" + count.ToString(); - while (FindDocument(text) != null) - { - count ++; - //text = "C:\\MADFDKAJ\\ADAKFJASD\\ADFKDSAKFJASD\\ASDFKASDFJASDF\\ASDFIJADSFJ\\ASDFKDFDA" + count.ToString(); - text = "Document" + count.ToString(); - } - dummyDoc.Text = text; - return dummyDoc; - } - - private DummyDoc CreateNewDocument(string text) - { - DummyDoc dummyDoc = new DummyDoc(); - dummyDoc.Text = text; - return dummyDoc; - } - - private void menuItemOpen_Click(object sender, System.EventArgs e) - { - OpenFileDialog openFile = new OpenFileDialog(); - - openFile.InitialDirectory = Application.ExecutablePath; - openFile.Filter = "rtf files (*.rtf)|*.rtf|txt files (*.txt)|*.txt|All files (*.*)|*.*" ; - openFile.FilterIndex = 1; - openFile.RestoreDirectory = true ; - - if(openFile.ShowDialog() == DialogResult.OK) - { - string fullName = openFile.FileName; - string fileName = Path.GetFileName(fullName); - - if (FindDocument(fileName) != null) - { - MessageBox.Show("The document: " + fileName + " has already opened!"); - return; - } - - DummyDoc dummyDoc = new DummyDoc(); - dummyDoc.Text = fileName; - dummyDoc.Show(dockPanel); - try - { - dummyDoc.FileName = fullName; - } - catch (Exception exception) - { - dummyDoc.Close(); - MessageBox.Show(exception.Message); - } - - } - } - - private void menuItemFile_Popup(object sender, System.EventArgs e) - { - if (dockPanel.DocumentStyle == DocumentStyle.SystemMdi) - { - menuItemClose.Enabled = menuItemCloseAll.Enabled = (ActiveMdiChild != null); - } - else - { - menuItemClose.Enabled = (dockPanel.ActiveDocument != null); - menuItemCloseAll.Enabled = (dockPanel.DocumentsCount > 0); - } - } - - private void menuItemClose_Click(object sender, System.EventArgs e) - { - if (dockPanel.DocumentStyle == DocumentStyle.SystemMdi) - ActiveMdiChild.Close(); - else if (dockPanel.ActiveDocument != null) - dockPanel.ActiveDocument.DockHandler.Close(); - } - - private void menuItemCloseAll_Click(object sender, System.EventArgs e) - { - CloseAllDocuments(); - } - - private void CloseAllDocuments() - { - if (dockPanel.DocumentStyle == DocumentStyle.SystemMdi) - { - foreach (Form form in MdiChildren) - form.Close(); - } - else - { - IDockContent[] documents = dockPanel.DocumentsToArray(); - foreach (IDockContent content in documents) - content.DockHandler.Close(); - } - } - - private IDockContent GetContentFromPersistString(string persistString) - { - if (persistString == typeof(DummySolutionExplorer).ToString()) - return m_solutionExplorer; - else if (persistString == typeof(DummyPropertyWindow).ToString()) - return m_propertyWindow; - else if (persistString == typeof(DummyToolbox).ToString()) - return m_toolbox; - else if (persistString == typeof(DummyOutputWindow).ToString()) - return m_outputWindow; - else if (persistString == typeof(DummyTaskList).ToString()) - return m_taskList; - else - { - string[] parsedStrings = persistString.Split(new char[] { ',' }); - if (parsedStrings.Length != 3) - return null; - - if (parsedStrings[0] != typeof(DummyDoc).ToString()) - return null; - - DummyDoc dummyDoc = new DummyDoc(); - if (parsedStrings[1] != string.Empty) - dummyDoc.FileName = parsedStrings[1]; - if (parsedStrings[2] != string.Empty) - dummyDoc.Text = parsedStrings[2]; - - return dummyDoc; - } - } - - private void MainForm_Load(object sender, System.EventArgs e) - { - string configFile = Path.Combine(Path.GetDirectoryName(Application.ExecutablePath), "DockPanel.config"); - - if (File.Exists(configFile)) - dockPanel.LoadFromXml(configFile, m_deserializeDockContent); - } - - private void MainForm_Closing(object sender, System.ComponentModel.CancelEventArgs e) - { - string configFile = Path.Combine(Path.GetDirectoryName(Application.ExecutablePath), "DockPanel.config"); - if (m_bSaveLayout) - dockPanel.SaveAsXml(configFile); - else if (File.Exists(configFile)) - File.Delete(configFile); - } - - private void menuItemToolBar_Click(object sender, System.EventArgs e) - { - toolBar.Visible = menuItemToolBar.Checked = !menuItemToolBar.Checked; - } - - private void menuItemStatusBar_Click(object sender, System.EventArgs e) - { - statusBar.Visible = menuItemStatusBar.Checked = !menuItemStatusBar.Checked; - } - - private void toolBar_ButtonClick(object sender, System.Windows.Forms.ToolStripItemClickedEventArgs e) - { - if (e.ClickedItem == toolBarButtonNew) - menuItemNew_Click(null, null); - else if (e.ClickedItem == toolBarButtonOpen) - menuItemOpen_Click(null, null); - else if (e.ClickedItem == toolBarButtonSolutionExplorer) - menuItemSolutionExplorer_Click(null, null); - else if (e.ClickedItem == toolBarButtonPropertyWindow) - menuItemPropertyWindow_Click(null, null); - else if (e.ClickedItem == toolBarButtonToolbox) - menuItemToolbox_Click(null, null); - else if (e.ClickedItem == toolBarButtonOutputWindow) - menuItemOutputWindow_Click(null, null); - else if (e.ClickedItem == toolBarButtonTaskList) - menuItemTaskList_Click(null, null); - else if (e.ClickedItem == toolBarButtonLayoutByCode) - menuItemLayoutByCode_Click(null, null); - else if (e.ClickedItem == toolBarButtonLayoutByXml) - menuItemLayoutByXml_Click(null, null); - } - - private void menuItemNewWindow_Click(object sender, System.EventArgs e) - { - MainForm newWindow = new MainForm(); - newWindow.Text = newWindow.Text + " - New"; - newWindow.Show(); - } - - private void menuItemTools_Popup(object sender, System.EventArgs e) - { - menuItemLockLayout.Checked = !this.dockPanel.AllowEndUserDocking; - } - - private void menuItemLockLayout_Click(object sender, System.EventArgs e) - { - dockPanel.AllowEndUserDocking = !dockPanel.AllowEndUserDocking; - } - - private void menuItemLayoutByCode_Click(object sender, System.EventArgs e) - { - dockPanel.SuspendLayout(true); - - m_solutionExplorer.Show(dockPanel, DockState.DockRight); - m_propertyWindow.Show(m_solutionExplorer.Pane, m_solutionExplorer); - m_toolbox.Show(dockPanel, new Rectangle(98, 133, 200, 383)); - m_outputWindow.Show(m_solutionExplorer.Pane, DockAlignment.Bottom, 0.35); - m_taskList.Show(m_toolbox.Pane, DockAlignment.Left, 0.4); - - CloseAllDocuments(); - DummyDoc doc1 = CreateNewDocument("Document1"); - DummyDoc doc2 = CreateNewDocument("Document2"); - DummyDoc doc3 = CreateNewDocument("Document3"); - DummyDoc doc4 = CreateNewDocument("Document4"); - doc1.Show(dockPanel, DockState.Document); - doc2.Show(doc1.Pane, null); - doc3.Show(doc1.Pane, DockAlignment.Bottom, 0.5); - doc4.Show(doc3.Pane, DockAlignment.Right, 0.5); - - dockPanel.ResumeLayout(true, true); - } - - private void menuItemLayoutByXml_Click(object sender, System.EventArgs e) - { - dockPanel.SuspendLayout(true); - - // In order to load layout from XML, we need to close all the DockContents - CloseAllContents(); - - Assembly assembly = Assembly.GetAssembly(typeof(MainForm)); - Stream xmlStream = assembly.GetManifestResourceStream("DockSample.Resources.DockPanel.xml"); - dockPanel.LoadFromXml(xmlStream, m_deserializeDockContent); - xmlStream.Close(); - - dockPanel.ResumeLayout(true, true); - } - - private void CloseAllContents() - { - // we don't want to create another instance of tool window, set DockPanel to null - m_solutionExplorer.DockPanel = null; - m_propertyWindow.DockPanel = null; - m_toolbox.DockPanel = null; - m_outputWindow.DockPanel = null; - m_taskList.DockPanel = null; - - // Close all other document windows - CloseAllDocuments(); - } - - private void SetSchema(object sender, System.EventArgs e) - { - CloseAllContents(); - - if (sender == menuItemSchemaVS2005) - Extender.SetSchema(dockPanel, Extender.Schema.VS2005); - else if (sender == menuItemSchemaVS2003) - Extender.SetSchema(dockPanel, Extender.Schema.VS2003); - - menuItemSchemaVS2005.Checked = (sender == menuItemSchemaVS2005); - menuItemSchemaVS2003.Checked = (sender == menuItemSchemaVS2003); - } - - private void SetDocumentStyle(object sender, System.EventArgs e) - { - DocumentStyle oldStyle = dockPanel.DocumentStyle; - DocumentStyle newStyle; - if (sender == menuItemDockingMdi) - newStyle = DocumentStyle.DockingMdi; - else if (sender == menuItemDockingWindow) - newStyle = DocumentStyle.DockingWindow; - else if (sender == menuItemDockingSdi) - newStyle = DocumentStyle.DockingSdi; - else - newStyle = DocumentStyle.SystemMdi; - - if (oldStyle == newStyle) - return; - - if (oldStyle == DocumentStyle.SystemMdi || newStyle == DocumentStyle.SystemMdi) - CloseAllDocuments(); - - dockPanel.DocumentStyle = newStyle; - menuItemDockingMdi.Checked = (newStyle == DocumentStyle.DockingMdi); - menuItemDockingWindow.Checked = (newStyle == DocumentStyle.DockingWindow); - menuItemDockingSdi.Checked = (newStyle == DocumentStyle.DockingSdi); - menuItemSystemMdi.Checked = (newStyle == DocumentStyle.SystemMdi); - menuItemLayoutByCode.Enabled = (newStyle != DocumentStyle.SystemMdi); - menuItemLayoutByXml.Enabled = (newStyle != DocumentStyle.SystemMdi); - toolBarButtonLayoutByCode.Enabled = (newStyle != DocumentStyle.SystemMdi); - toolBarButtonLayoutByXml.Enabled = (newStyle != DocumentStyle.SystemMdi); - } - - private void menuItemCloseAllButThisOne_Click(object sender, System.EventArgs e) - { - if (dockPanel.DocumentStyle == DocumentStyle.SystemMdi) - { - Form activeMdi = ActiveMdiChild; - foreach (Form form in MdiChildren) - { - if (form != activeMdi) - form.Close(); - } - } - else - { - foreach (IDockContent document in dockPanel.DocumentsToArray()) - { - if (!document.DockHandler.IsActivated) - document.DockHandler.Close(); - } - } - } - - private void menuItemShowDocumentIcon_Click(object sender, System.EventArgs e) - { - dockPanel.ShowDocumentIcon = menuItemShowDocumentIcon.Checked= !menuItemShowDocumentIcon.Checked; - } - - private void showRightToLeft_Click(object sender, EventArgs e) - { - CloseAllContents(); - if (showRightToLeft.Checked) - { - this.RightToLeft = RightToLeft.No; - this.RightToLeftLayout = false; - } - else - { - this.RightToLeft = RightToLeft.Yes; - this.RightToLeftLayout = true; - } - m_solutionExplorer.RightToLeftLayout = this.RightToLeftLayout; - showRightToLeft.Checked = !showRightToLeft.Checked; - } - - private void exitWithoutSavingLayout_Click(object sender, EventArgs e) - { - m_bSaveLayout = false; - Close(); - m_bSaveLayout = true; - } - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/MainForm2.resx b/src/Libraries/DockPanel_Src/DockSample/MainForm2.resx deleted file mode 100644 index b34fbc3c84..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/MainForm2.resx +++ /dev/null @@ -1,194 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 120, 12 - - - 24, 9 - - - - AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj0yLjAuMC4w - LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0 - ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAADY - DAAAAk1TRnQBSQFMAgEBCQEAAQ4BAAEEAQABEAEAARABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo - AwABQAMAATADAAEBAQABCAYAAQwYAAGAAgABgAMAAoABAAGAAwABgAEAAYABAAKAAgADwAEAAcAB3AHA - AQAB8AHKAaYBAAEzBQABMwEAATMBAAEzAQACMwIAAxYBAAMcAQADIgEAAykBAANVAQADTQEAA0IBAAM5 - AQABgAF8Af8BAAJQAf8BAAGTAQAB1gEAAf8B7AHMAQABxgHWAe8B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D/wEBBAAC/wMAAf8DAAH/BAABBAMACf8FAAH/AfsB/wH7Af8B+wH/AfsB/wcADP8BBwMA - A/8KAAIEAwAJ/wUAAfsB/wH7DQAM/wEHEAACBAMABv8YAAz/AQcQAAIEAwAG/wEAAf8WAAz/AQcQAAIE - AwAG/xgADQQQAAIEIQANBBAAAgRAAAFCAU0BPgcAAT4DAAEoAwABQAMAATADAAEBAQABAQUAAYABARYA - A/8BAAGAAQEGAAGAAQEGAAGAAQEGAAGAAQEGAAGAAQEGAAGAAQEGAAGAAQEGAAGAAQEGAAGAAQEGAAGA - AQEGAAGAAQEGAAGAAQEGAAGAAQsGAAGAAQcGAAGAAQ8GAAL/BgAG/wHAAQEBnwHPAv8B4AEHAcABAQKP - AcABAwHAAQMBwAEBAccBHwHAAQMBwAEDAcABAQHiAT8BwAEDAcABAwHAAQEB8AF/AcABAwHAAQMBwAEB - AfgB/wHAAQMBwAEDAcABAQHwAXsBwAEDAcABAwHAAQEBAgExAcABAwHAAQMBwAEBAQcBAAHAAQMBwAED - AcABAQFnAYEBwAEDAcABAwHAAQEB5wGDAcABAwHAAQMBwAEBAccBAwHAAQMBwAEDAcABCwH8AQcBwAED - AeABBwHAAQcB/gEfAv8B/AE/AcABDxT/AfwBYwEAAQ8BwAEHAQABHwH4AQEBAAEPAcABBwEAAQ8BgAIA - AQ8BwAEHAQABBwGAAgABDwHAAQcBAAEDAYACAAEPAcABBwEAAQEBgAIAAQ8BwAEHAgABgAEBAQABDwHA - AQcBAAEfAYABAwEIAY4BwAEHAQABHwGAAQMBBQFEAcABBwEAAR8BgAEDAQIBuAHAAQcBjwHxAYABAwH9 - AXwBwAEPAf8B+QGAAQMB/gH8AcABHwH/AXUBgAEDAf8BAAHAAT8B/wGPAYABAwH/AfwI/ws= - - - - 226, 12 - - - 310, 13 - - \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/Program.cs b/src/Libraries/DockPanel_Src/DockSample/Program.cs deleted file mode 100644 index 1f61876738..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/Program.cs +++ /dev/null @@ -1,20 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Windows.Forms; - -namespace DockSample -{ - static class Program - { - /// - /// The main entry point for the application. - /// - [STAThread] - static void Main() - { - Application.EnableVisualStyles(); - Application.SetCompatibleTextRenderingDefault(false); - Application.Run(new MainForm()); - } - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/Properties/AssemblyInfo.cs b/src/Libraries/DockPanel_Src/DockSample/Properties/AssemblyInfo.cs deleted file mode 100644 index ca0d0b139e..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/Properties/AssemblyInfo.cs +++ /dev/null @@ -1,33 +0,0 @@ -using System.Reflection; -using System.Runtime.CompilerServices; -using System.Runtime.InteropServices; - -// General Information about an assembly is controlled through the following -// set of attributes. Change these attribute values to modify the information -// associated with an assembly. -[assembly: AssemblyTitle("DockSample")] -[assembly: AssemblyDescription("")] -[assembly: AssemblyConfiguration("")] -[assembly: AssemblyCompany("Weifen Luo")] -[assembly: AssemblyProduct("DockSample")] -[assembly: AssemblyCopyright("Copyright © Weifen Luo 2007")] -[assembly: AssemblyTrademark("")] -[assembly: AssemblyCulture("")] - -// Setting ComVisible to false makes the types in this assembly not visible -// to COM components. If you need to access a type in this assembly from -// COM, set the ComVisible attribute to true on that type. -[assembly: ComVisible(false)] - -// The following GUID is for the ID of the typelib if this project is exposed to COM -[assembly: Guid("f881c535-4ab4-4ef8-93c2-785db20a791e")] - -// Version information for an assembly consists of the following four values: -// -// Major Version -// Minor Version -// Build Number -// Revision -// -[assembly: AssemblyVersion("2.0.*")] -//[assembly: AssemblyFileVersion("2.0.0.0")] diff --git a/src/Libraries/DockPanel_Src/DockSample/Properties/Resources.Designer.cs b/src/Libraries/DockPanel_Src/DockSample/Properties/Resources.Designer.cs deleted file mode 100644 index f454f9f083..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/Properties/Resources.Designer.cs +++ /dev/null @@ -1,63 +0,0 @@ -//------------------------------------------------------------------------------ -// -// This code was generated by a tool. -// Runtime Version:2.0.50727.42 -// -// Changes to this file may cause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -namespace DockSample.Properties { - using System; - - - /// - /// A strongly-typed resource class, for looking up localized strings, etc. - /// - // This class was auto-generated by the StronglyTypedResourceBuilder - // class via a tool like ResGen or Visual Studio. - // To add or remove a member, edit your .ResX file then rerun ResGen - // with the /str option, or rebuild your VS project. - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "2.0.0.0")] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] - internal class Resources { - - private static global::System.Resources.ResourceManager resourceMan; - - private static global::System.Globalization.CultureInfo resourceCulture; - - [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] - internal Resources() { - } - - /// - /// Returns the cached ResourceManager instance used by this class. - /// - [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] - internal static global::System.Resources.ResourceManager ResourceManager { - get { - if (object.ReferenceEquals(resourceMan, null)) { - global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("DockSample.Properties.Resources", typeof(Resources).Assembly); - resourceMan = temp; - } - return resourceMan; - } - } - - /// - /// Overrides the current thread's CurrentUICulture property for all - /// resource lookups using this strongly typed resource class. - /// - [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] - internal static global::System.Globalization.CultureInfo Culture { - get { - return resourceCulture; - } - set { - resourceCulture = value; - } - } - } -} diff --git a/src/Libraries/DockPanel_Src/DockSample/Properties/Resources.resx b/src/Libraries/DockPanel_Src/DockSample/Properties/Resources.resx deleted file mode 100644 index af7dbebbac..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/Properties/Resources.resx +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/Properties/Settings.Designer.cs b/src/Libraries/DockPanel_Src/DockSample/Properties/Settings.Designer.cs deleted file mode 100644 index dbfe78b492..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/Properties/Settings.Designer.cs +++ /dev/null @@ -1,26 +0,0 @@ -//------------------------------------------------------------------------------ -// -// This code was generated by a tool. -// Runtime Version:2.0.50727.42 -// -// Changes to this file may cause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -namespace DockSample.Properties { - - - [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "8.0.0.0")] - internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase { - - private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); - - public static Settings Default { - get { - return defaultInstance; - } - } - } -} diff --git a/src/Libraries/DockPanel_Src/DockSample/Properties/Settings.settings b/src/Libraries/DockPanel_Src/DockSample/Properties/Settings.settings deleted file mode 100644 index 39645652af..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/Properties/Settings.settings +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/src/Libraries/DockPanel_Src/DockSample/Resources/DockPanel.xml b/src/Libraries/DockPanel_Src/DockSample/Resources/DockPanel.xml deleted file mode 100644 index a40333b9b42c670bb37f7d50e336608e4fb35025..0000000000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PUXaH1@f-rbn6FU^2>U@-#$Le@pW$oUJBN zet!L{h&H0^vxDim6|+%Mkse;hns`<;#@;)v_c&@Zt7xP45y{5iW8P7xTu<@>Pftqw m9MzsHHOHFjGpl1+qp06340Re3wU+rZR?X6CXC662=Kl{2e{)g* diff --git a/src/Libraries/DockPanel_Src/DockSample/ToolWindow.Designer.cs b/src/Libraries/DockPanel_Src/DockSample/ToolWindow.Designer.cs deleted file mode 100644 index 2b098e248a..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/ToolWindow.Designer.cs +++ /dev/null @@ -1,91 +0,0 @@ -namespace DockSample -{ - partial class ToolWindow - { - /// - /// Required designer variable. - /// - private System.ComponentModel.IContainer components = null; - - /// - /// Clean up any resources being used. - /// - /// true if managed resources should be disposed; otherwise, false. - protected override void Dispose(bool disposing) - { - if (disposing && (components != null)) - { - components.Dispose(); - } - base.Dispose(disposing); - } - - #region Windows Form Designer generated code - - /// - /// Required method for Designer support - do not modify - /// the contents of this method with the code editor. - /// - private void InitializeComponent() - { - this.components = new System.ComponentModel.Container(); - this.contextMenuStrip1 = new System.Windows.Forms.ContextMenuStrip(this.components); - this.option1ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); - this.option2ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); - this.option3ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); - this.contextMenuStrip1.SuspendLayout(); - this.SuspendLayout(); - // - // contextMenuStrip1 - // - this.contextMenuStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { - this.option1ToolStripMenuItem, - this.option2ToolStripMenuItem, - this.option3ToolStripMenuItem}); - this.contextMenuStrip1.Name = "contextMenuStrip1"; - this.contextMenuStrip1.Size = new System.Drawing.Size(113, 70); - // - // option1ToolStripMenuItem - // - this.option1ToolStripMenuItem.Name = "option1ToolStripMenuItem"; - this.option1ToolStripMenuItem.Size = new System.Drawing.Size(152, 22); - this.option1ToolStripMenuItem.Text = "Option&1"; - // - // option2ToolStripMenuItem - // - this.option2ToolStripMenuItem.Name = "option2ToolStripMenuItem"; - this.option2ToolStripMenuItem.Size = new System.Drawing.Size(152, 22); - this.option2ToolStripMenuItem.Text = "Option&2"; - // - // option3ToolStripMenuItem - // - this.option3ToolStripMenuItem.Name = "option3ToolStripMenuItem"; - this.option3ToolStripMenuItem.Size = new System.Drawing.Size(152, 22); - this.option3ToolStripMenuItem.Text = "Option&3"; - // - // ToolWindow - // - this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); - this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.ClientSize = new System.Drawing.Size(292, 266); - this.DockAreas = ((WeifenLuo.WinFormsUI.Docking.DockAreas)(((((WeifenLuo.WinFormsUI.Docking.DockAreas.Float | WeifenLuo.WinFormsUI.Docking.DockAreas.DockLeft) - | WeifenLuo.WinFormsUI.Docking.DockAreas.DockRight) - | WeifenLuo.WinFormsUI.Docking.DockAreas.DockTop) - | WeifenLuo.WinFormsUI.Docking.DockAreas.DockBottom))); - this.Name = "ToolWindow"; - this.TabPageContextMenuStrip = this.contextMenuStrip1; - this.TabText = "ToolWindow"; - this.Text = "ToolWindow"; - this.contextMenuStrip1.ResumeLayout(false); - this.ResumeLayout(false); - - } - - #endregion - - private System.Windows.Forms.ContextMenuStrip contextMenuStrip1; - private System.Windows.Forms.ToolStripMenuItem option1ToolStripMenuItem; - private System.Windows.Forms.ToolStripMenuItem option2ToolStripMenuItem; - private System.Windows.Forms.ToolStripMenuItem option3ToolStripMenuItem; - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/ToolWindow.cs b/src/Libraries/DockPanel_Src/DockSample/ToolWindow.cs deleted file mode 100644 index eefee4378a..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/ToolWindow.cs +++ /dev/null @@ -1,19 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel; -using System.Data; -using System.Drawing; -using System.Text; -using System.Windows.Forms; -using WeifenLuo.WinFormsUI.Docking; - -namespace DockSample -{ - public partial class ToolWindow : DockContent - { - public ToolWindow() - { - InitializeComponent(); - } - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/ToolWindow.resx b/src/Libraries/DockPanel_Src/DockSample/ToolWindow.resx deleted file mode 100644 index 6fab886155..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/ToolWindow.resx +++ /dev/null @@ -1,123 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - 17, 17 - - \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/DockSample/license.txt b/src/Libraries/DockPanel_Src/DockSample/license.txt deleted file mode 100644 index 96f3fa5ce9..0000000000 --- a/src/Libraries/DockPanel_Src/DockSample/license.txt +++ /dev/null @@ -1,9 +0,0 @@ -The MIT License - -Copyright (c) 2007 Weifen Luo (email: weifenluo@yahoo.com) - -Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/src/Libraries/DockPanel_Src/WinFormsUI.Docking.sln b/src/Libraries/DockPanel_Src/WinFormsUI.Docking.sln deleted file mode 100644 index 10268f1600..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI.Docking.sln +++ /dev/null @@ -1,25 +0,0 @@ -Microsoft Visual Studio Solution File, Format Version 9.00 -# Visual C# Express 2005 -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WinFormsUI", "WinFormsUI\WinFormsUI.csproj", "{C75532C4-765B-418E-B09B-46D36B2ABDB1}" -EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DockSample", "DockSample\DockSample.csproj", "{40793A27-478B-4357-B4C3-FC8943131F3D}" -EndProject -Global - GlobalSection(SolutionConfigurationPlatforms) = preSolution - Debug|Any CPU = Debug|Any CPU - Release|Any CPU = Release|Any CPU - EndGlobalSection - GlobalSection(ProjectConfigurationPlatforms) = postSolution - {C75532C4-765B-418E-B09B-46D36B2ABDB1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {C75532C4-765B-418E-B09B-46D36B2ABDB1}.Debug|Any CPU.Build.0 = Debug|Any CPU - {C75532C4-765B-418E-B09B-46D36B2ABDB1}.Release|Any CPU.ActiveCfg = Release|Any CPU - {C75532C4-765B-418E-B09B-46D36B2ABDB1}.Release|Any CPU.Build.0 = Release|Any CPU - {40793A27-478B-4357-B4C3-FC8943131F3D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {40793A27-478B-4357-B4C3-FC8943131F3D}.Debug|Any CPU.Build.0 = Debug|Any CPU - {40793A27-478B-4357-B4C3-FC8943131F3D}.Release|Any CPU.ActiveCfg = Release|Any CPU - {40793A27-478B-4357-B4C3-FC8943131F3D}.Release|Any CPU.Build.0 = Release|Any CPU - EndGlobalSection - GlobalSection(SolutionProperties) = preSolution - HideSolutionNode = FALSE - EndGlobalSection -EndGlobal diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/AutoHideStripBase.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/AutoHideStripBase.cs deleted file mode 100644 index 7c0cb3c478..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/AutoHideStripBase.cs +++ /dev/null @@ -1,508 +0,0 @@ -using System; -using System.Collections; -using System.Windows.Forms; -using System.Drawing; -using System.Drawing.Drawing2D; -using System.Collections.Generic; -using System.Diagnostics.CodeAnalysis; - -namespace WeifenLuo.WinFormsUI.Docking -{ - public abstract partial class AutoHideStripBase : Control - { - [SuppressMessage("Microsoft.Design", "CA1034:NestedTypesShouldNotBeVisible")] - protected class Tab : IDisposable - { - private IDockContent m_content; - - protected internal Tab(IDockContent content) - { - m_content = content; - } - - public IDockContent Content - { - get { return m_content; } - } - - public virtual void Dispose() - { - } - } - - [SuppressMessage("Microsoft.Design", "CA1034:NestedTypesShouldNotBeVisible")] - protected sealed class TabCollection : IEnumerable - { - #region IEnumerable Members - IEnumerator IEnumerable.GetEnumerator() - { - for (int i = 0; i < Count; i++) - yield return this[i]; - } - - IEnumerator IEnumerable.GetEnumerator() - { - for (int i = 0; i < Count; i++) - yield return this[i]; - } - #endregion - - internal TabCollection(DockPane pane) - { - m_dockPane = pane; - } - - private DockPane m_dockPane = null; - public DockPane DockPane - { - get { return m_dockPane; } - } - - public DockPanel DockPanel - { - get { return DockPane.DockPanel; } - } - - public int Count - { - get { return DockPane.DisplayingContents.Count; } - } - - public Tab this[int index] - { - get - { - IDockContent content = DockPane.DisplayingContents[index]; - if (content == null) - throw (new ArgumentOutOfRangeException("index")); - if (content.DockHandler.AutoHideTab == null) - content.DockHandler.AutoHideTab = (DockPanel.AutoHideStripControl.CreateTab(content)); - return content.DockHandler.AutoHideTab as Tab; - } - } - - public bool Contains(Tab tab) - { - return (IndexOf(tab) != -1); - } - - public bool Contains(IDockContent content) - { - return (IndexOf(content) != -1); - } - - public int IndexOf(Tab tab) - { - if (tab == null) - return -1; - - return IndexOf(tab.Content); - } - - public int IndexOf(IDockContent content) - { - return DockPane.DisplayingContents.IndexOf(content); - } - } - - [SuppressMessage("Microsoft.Design", "CA1034:NestedTypesShouldNotBeVisible")] - protected class Pane : IDisposable - { - private DockPane m_dockPane; - - protected internal Pane(DockPane dockPane) - { - m_dockPane = dockPane; - } - - public DockPane DockPane - { - get { return m_dockPane; } - } - - public TabCollection AutoHideTabs - { - get - { - if (DockPane.AutoHideTabs == null) - DockPane.AutoHideTabs = new TabCollection(DockPane); - return DockPane.AutoHideTabs as TabCollection; - } - } - - public virtual void Dispose() - { - } - } - - [SuppressMessage("Microsoft.Design", "CA1034:NestedTypesShouldNotBeVisible")] - protected sealed class PaneCollection : IEnumerable - { - private class AutoHideState - { - public DockState m_dockState; - public bool m_selected = false; - - public AutoHideState(DockState dockState) - { - m_dockState = dockState; - } - - public DockState DockState - { - get { return m_dockState; } - } - - public bool Selected - { - get { return m_selected; } - set { m_selected = value; } - } - } - - private class AutoHideStateCollection - { - private AutoHideState[] m_states; - - public AutoHideStateCollection() - { - m_states = new AutoHideState[] { - new AutoHideState(DockState.DockTopAutoHide), - new AutoHideState(DockState.DockBottomAutoHide), - new AutoHideState(DockState.DockLeftAutoHide), - new AutoHideState(DockState.DockRightAutoHide) - }; - } - - public AutoHideState this[DockState dockState] - { - get - { - for (int i = 0; i < m_states.Length; i++) - { - if (m_states[i].DockState == dockState) - return m_states[i]; - } - throw new ArgumentOutOfRangeException("dockState"); - } - } - - public bool ContainsPane(DockPane pane) - { - if (pane.IsHidden) - return false; - - for (int i = 0; i < m_states.Length; i++) - { - if (m_states[i].DockState == pane.DockState && m_states[i].Selected) - return true; - } - return false; - } - } - - internal PaneCollection(DockPanel panel, DockState dockState) - { - m_dockPanel = panel; - m_states = new AutoHideStateCollection(); - States[DockState.DockTopAutoHide].Selected = (dockState == DockState.DockTopAutoHide); - States[DockState.DockBottomAutoHide].Selected = (dockState == DockState.DockBottomAutoHide); - States[DockState.DockLeftAutoHide].Selected = (dockState == DockState.DockLeftAutoHide); - States[DockState.DockRightAutoHide].Selected = (dockState == DockState.DockRightAutoHide); - } - - private DockPanel m_dockPanel; - public DockPanel DockPanel - { - get { return m_dockPanel; } - } - - private AutoHideStateCollection m_states; - private AutoHideStateCollection States - { - get { return m_states; } - } - - public int Count - { - get - { - int count = 0; - foreach (DockPane pane in DockPanel.Panes) - { - if (States.ContainsPane(pane)) - count++; - } - - return count; - } - } - - public Pane this[int index] - { - get - { - int count = 0; - foreach (DockPane pane in DockPanel.Panes) - { - if (!States.ContainsPane(pane)) - continue; - - if (count == index) - { - if (pane.AutoHidePane == null) - pane.AutoHidePane = DockPanel.AutoHideStripControl.CreatePane(pane); - return pane.AutoHidePane as Pane; - } - - count++; - } - throw new ArgumentOutOfRangeException("index"); - } - } - - public bool Contains(Pane pane) - { - return (IndexOf(pane) != -1); - } - - public int IndexOf(Pane pane) - { - if (pane == null) - return -1; - - int index = 0; - foreach (DockPane dockPane in DockPanel.Panes) - { - if (!States.ContainsPane(pane.DockPane)) - continue; - - if (pane == dockPane.AutoHidePane) - return index; - - index++; - } - return -1; - } - - #region IEnumerable Members - - IEnumerator IEnumerable.GetEnumerator() - { - for (int i = 0; i < Count; i++) - yield return this[i]; - } - - IEnumerator IEnumerable.GetEnumerator() - { - for (int i = 0; i < Count; i++) - yield return this[i]; - } - - #endregion - } - - protected AutoHideStripBase(DockPanel panel) - { - m_dockPanel = panel; - m_panesTop = new PaneCollection(panel, DockState.DockTopAutoHide); - m_panesBottom = new PaneCollection(panel, DockState.DockBottomAutoHide); - m_panesLeft = new PaneCollection(panel, DockState.DockLeftAutoHide); - m_panesRight = new PaneCollection(panel, DockState.DockRightAutoHide); - - SetStyle(ControlStyles.OptimizedDoubleBuffer, true); - SetStyle(ControlStyles.Selectable, false); - } - - private DockPanel m_dockPanel; - protected DockPanel DockPanel - { - get { return m_dockPanel; } - } - - private PaneCollection m_panesTop; - protected PaneCollection PanesTop - { - get { return m_panesTop; } - } - - private PaneCollection m_panesBottom; - protected PaneCollection PanesBottom - { - get { return m_panesBottom; } - } - - private PaneCollection m_panesLeft; - protected PaneCollection PanesLeft - { - get { return m_panesLeft; } - } - - private PaneCollection m_panesRight; - protected PaneCollection PanesRight - { - get { return m_panesRight; } - } - - protected PaneCollection GetPanes(DockState dockState) - { - if (dockState == DockState.DockTopAutoHide) - return PanesTop; - else if (dockState == DockState.DockBottomAutoHide) - return PanesBottom; - else if (dockState == DockState.DockLeftAutoHide) - return PanesLeft; - else if (dockState == DockState.DockRightAutoHide) - return PanesRight; - else - throw new ArgumentOutOfRangeException("dockState"); - } - - internal int GetNumberOfPanes(DockState dockState) - { - return GetPanes(dockState).Count; - } - - protected Rectangle RectangleTopLeft - { - get - { - int height = MeasureHeight(); - return PanesTop.Count > 0 && PanesLeft.Count > 0 ? new Rectangle(0, 0, height, height) : Rectangle.Empty; - } - } - - protected Rectangle RectangleTopRight - { - get - { - int height = MeasureHeight(); - return PanesTop.Count > 0 && PanesRight.Count > 0 ? new Rectangle(Width - height, 0, height, height) : Rectangle.Empty; - } - } - - protected Rectangle RectangleBottomLeft - { - get - { - int height = MeasureHeight(); - return PanesBottom.Count > 0 && PanesLeft.Count > 0 ? new Rectangle(0, Height - height, height, height) : Rectangle.Empty; - } - } - - protected Rectangle RectangleBottomRight - { - get - { - int height = MeasureHeight(); - return PanesBottom.Count > 0 && PanesRight.Count > 0 ? new Rectangle(Width - height, Height - height, height, height) : Rectangle.Empty; - } - } - - protected internal Rectangle GetTabStripRectangle(DockState dockState) - { - int height = MeasureHeight(); - if (dockState == DockState.DockTopAutoHide && PanesTop.Count > 0) - return new Rectangle(RectangleTopLeft.Width, 0, Width - RectangleTopLeft.Width - RectangleTopRight.Width, height); - else if (dockState == DockState.DockBottomAutoHide && PanesBottom.Count > 0) - return new Rectangle(RectangleBottomLeft.Width, Height - height, Width - RectangleBottomLeft.Width - RectangleBottomRight.Width, height); - else if (dockState == DockState.DockLeftAutoHide && PanesLeft.Count > 0) - return new Rectangle(0, RectangleTopLeft.Width, height, Height - RectangleTopLeft.Height - RectangleBottomLeft.Height); - else if (dockState == DockState.DockRightAutoHide && PanesRight.Count > 0) - return new Rectangle(Width - height, RectangleTopRight.Width, height, Height - RectangleTopRight.Height - RectangleBottomRight.Height); - else - return Rectangle.Empty; - } - - private GraphicsPath m_displayingArea = null; - private GraphicsPath DisplayingArea - { - get - { - if (m_displayingArea == null) - m_displayingArea = new GraphicsPath(); - - return m_displayingArea; - } - } - - private void SetRegion() - { - DisplayingArea.Reset(); - DisplayingArea.AddRectangle(RectangleTopLeft); - DisplayingArea.AddRectangle(RectangleTopRight); - DisplayingArea.AddRectangle(RectangleBottomLeft); - DisplayingArea.AddRectangle(RectangleBottomRight); - DisplayingArea.AddRectangle(GetTabStripRectangle(DockState.DockTopAutoHide)); - DisplayingArea.AddRectangle(GetTabStripRectangle(DockState.DockBottomAutoHide)); - DisplayingArea.AddRectangle(GetTabStripRectangle(DockState.DockLeftAutoHide)); - DisplayingArea.AddRectangle(GetTabStripRectangle(DockState.DockRightAutoHide)); - Region = new Region(DisplayingArea); - } - - protected override void OnMouseDown(MouseEventArgs e) - { - base.OnMouseDown(e); - - if (e.Button != MouseButtons.Left) - return; - - IDockContent content = HitTest(); - if (content == null) - return; - - content.DockHandler.Activate(); - } - - protected override void OnMouseHover(EventArgs e) - { - base.OnMouseHover(e); - - IDockContent content = HitTest(); - if (content != null && DockPanel.ActiveAutoHideContent != content) - DockPanel.ActiveAutoHideContent = content; - - // requires further tracking of mouse hover behavior, - ResetMouseEventArgs(); - } - - protected override void OnLayout(LayoutEventArgs levent) - { - RefreshChanges(); - base.OnLayout (levent); - } - - internal void RefreshChanges() - { - if (IsDisposed) - return; - - SetRegion(); - OnRefreshChanges(); - } - - protected virtual void OnRefreshChanges() - { - } - - protected internal abstract int MeasureHeight(); - - private IDockContent HitTest() - { - Point ptMouse = PointToClient(Control.MousePosition); - return HitTest(ptMouse); - } - - protected virtual Tab CreateTab(IDockContent content) - { - return new Tab(content); - } - - protected virtual Pane CreatePane(DockPane dockPane) - { - return new Pane(dockPane); - } - - protected abstract IDockContent HitTest(Point point); - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockAreasEditor.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockAreasEditor.cs deleted file mode 100644 index 5ec674461a..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockAreasEditor.cs +++ /dev/null @@ -1,142 +0,0 @@ -using System; -using System.ComponentModel; -using System.Drawing; -using System.Drawing.Design; -using System.Windows.Forms; -using System.Windows.Forms.Design; - -namespace WeifenLuo.WinFormsUI.Docking -{ - internal class DockAreasEditor : UITypeEditor - { - private class DockAreasEditorControl : System.Windows.Forms.UserControl - { - private CheckBox checkBoxFloat; - private CheckBox checkBoxDockLeft; - private CheckBox checkBoxDockRight; - private CheckBox checkBoxDockTop; - private CheckBox checkBoxDockBottom; - private CheckBox checkBoxDockFill; - private DockAreas m_oldDockAreas; - - public DockAreas DockAreas - { - get - { - DockAreas dockAreas = 0; - if (checkBoxFloat.Checked) - dockAreas |= DockAreas.Float; - if (checkBoxDockLeft.Checked) - dockAreas |= DockAreas.DockLeft; - if (checkBoxDockRight.Checked) - dockAreas |= DockAreas.DockRight; - if (checkBoxDockTop.Checked) - dockAreas |= DockAreas.DockTop; - if (checkBoxDockBottom.Checked) - dockAreas |= DockAreas.DockBottom; - if (checkBoxDockFill.Checked) - dockAreas |= DockAreas.Document; - - if (dockAreas == 0) - return m_oldDockAreas; - else - return dockAreas; - } - } - - public DockAreasEditorControl() - { - checkBoxFloat = new CheckBox(); - checkBoxDockLeft = new CheckBox(); - checkBoxDockRight = new CheckBox(); - checkBoxDockTop = new CheckBox(); - checkBoxDockBottom = new CheckBox(); - checkBoxDockFill = new CheckBox(); - - SuspendLayout(); - - checkBoxFloat.Appearance = Appearance.Button; - checkBoxFloat.Dock = DockStyle.Top; - checkBoxFloat.Height = 24; - checkBoxFloat.Text = Strings.DockAreaEditor_FloatCheckBoxText; - checkBoxFloat.TextAlign = ContentAlignment.MiddleCenter; - checkBoxFloat.FlatStyle = FlatStyle.System; - - checkBoxDockLeft.Appearance = System.Windows.Forms.Appearance.Button; - checkBoxDockLeft.Dock = System.Windows.Forms.DockStyle.Left; - checkBoxDockLeft.Width = 24; - checkBoxDockLeft.FlatStyle = FlatStyle.System; - - checkBoxDockRight.Appearance = System.Windows.Forms.Appearance.Button; - checkBoxDockRight.Dock = System.Windows.Forms.DockStyle.Right; - checkBoxDockRight.Width = 24; - checkBoxDockRight.FlatStyle = FlatStyle.System; - - checkBoxDockTop.Appearance = System.Windows.Forms.Appearance.Button; - checkBoxDockTop.Dock = System.Windows.Forms.DockStyle.Top; - checkBoxDockTop.Height = 24; - checkBoxDockTop.FlatStyle = FlatStyle.System; - - checkBoxDockBottom.Appearance = System.Windows.Forms.Appearance.Button; - checkBoxDockBottom.Dock = System.Windows.Forms.DockStyle.Bottom; - checkBoxDockBottom.Height = 24; - checkBoxDockBottom.FlatStyle = FlatStyle.System; - - checkBoxDockFill.Appearance = System.Windows.Forms.Appearance.Button; - checkBoxDockFill.Dock = System.Windows.Forms.DockStyle.Fill; - checkBoxDockFill.FlatStyle = FlatStyle.System; - - this.Controls.AddRange(new Control[] { - checkBoxDockFill, - checkBoxDockBottom, - checkBoxDockTop, - checkBoxDockRight, - checkBoxDockLeft, - checkBoxFloat}); - - Size = new System.Drawing.Size(160, 144); - BackColor = SystemColors.Control; - ResumeLayout(); - } - - public void SetStates(DockAreas dockAreas) - { - m_oldDockAreas = dockAreas; - if ((dockAreas & DockAreas.DockLeft) != 0) - checkBoxDockLeft.Checked = true; - if ((dockAreas & DockAreas.DockRight) != 0) - checkBoxDockRight.Checked = true; - if ((dockAreas & DockAreas.DockTop) != 0) - checkBoxDockTop.Checked = true; - if ((dockAreas & DockAreas.DockTop) != 0) - checkBoxDockTop.Checked = true; - if ((dockAreas & DockAreas.DockBottom) != 0) - checkBoxDockBottom.Checked = true; - if ((dockAreas & DockAreas.Document) != 0) - checkBoxDockFill.Checked = true; - if ((dockAreas & DockAreas.Float) != 0) - checkBoxFloat.Checked = true; - } - } - - private DockAreasEditor.DockAreasEditorControl m_ui = null; - - public override UITypeEditorEditStyle GetEditStyle(ITypeDescriptorContext context) - { - return UITypeEditorEditStyle.DropDown; - } - - public override object EditValue(ITypeDescriptorContext context, IServiceProvider sp, object value) - { - if (m_ui == null) - m_ui = new DockAreasEditor.DockAreasEditorControl(); - - m_ui.SetStates((DockAreas)value); - - IWindowsFormsEditorService edSvc = (IWindowsFormsEditorService)sp.GetService(typeof(IWindowsFormsEditorService)); - edSvc.DropDownControl(m_ui); - - return m_ui.DockAreas; - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockContent.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockContent.cs deleted file mode 100644 index 4ea43a176e..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockContent.cs +++ /dev/null @@ -1,273 +0,0 @@ -using System; -using System.ComponentModel; -using System.Drawing; -using System.Windows.Forms; -using System.Runtime.InteropServices; -using System.Diagnostics.CodeAnalysis; - -namespace WeifenLuo.WinFormsUI.Docking -{ - public class DockContent : Form, IDockContent - { - public DockContent() - { - m_dockHandler = new DockContentHandler(this, new GetPersistStringCallback(GetPersistString)); - m_dockHandler.DockStateChanged += new EventHandler(DockHandler_DockStateChanged); - } - - private DockContentHandler m_dockHandler = null; - [Browsable(false)] - public DockContentHandler DockHandler - { - get { return m_dockHandler; } - } - - [LocalizedCategory("Category_Docking")] - [LocalizedDescription("DockContent_AllowEndUserDocking_Description")] - [DefaultValue(true)] - public bool AllowEndUserDocking - { - get { return DockHandler.AllowEndUserDocking; } - set { DockHandler.AllowEndUserDocking = value; } - } - - [LocalizedCategory("Category_Docking")] - [LocalizedDescription("DockContent_DockAreas_Description")] - [DefaultValue(DockAreas.DockLeft|DockAreas.DockRight|DockAreas.DockTop|DockAreas.DockBottom|DockAreas.Document|DockAreas.Float)] - public DockAreas DockAreas - { - get { return DockHandler.DockAreas; } - set { DockHandler.DockAreas = value; } - } - - [LocalizedCategory("Category_Docking")] - [LocalizedDescription("DockContent_AutoHidePortion_Description")] - [DefaultValue(0.25)] - public double AutoHidePortion - { - get { return DockHandler.AutoHidePortion; } - set { DockHandler.AutoHidePortion = value; } - } - - [Localizable(true)] - [LocalizedCategory("Category_Docking")] - [LocalizedDescription("DockContent_TabText_Description")] - [DefaultValue(null)] - public string TabText - { - get { return DockHandler.TabText; } - set { DockHandler.TabText = value; } - } - private bool ShouldSerializeTabText() - { - return (DockHandler.TabText != null); - } - - [LocalizedCategory("Category_Docking")] - [LocalizedDescription("DockContent_CloseButton_Description")] - [DefaultValue(true)] - public bool CloseButton - { - get { return DockHandler.CloseButton; } - set { DockHandler.CloseButton = value; } - } - - [Browsable(false)] - public DockPanel DockPanel - { - get { return DockHandler.DockPanel; } - set { DockHandler.DockPanel = value; } - } - - [Browsable(false)] - public DockState DockState - { - get { return DockHandler.DockState; } - set { DockHandler.DockState = value; } - } - - [Browsable(false)] - public DockPane Pane - { - get { return DockHandler.Pane; } - set { DockHandler.Pane = value; } - } - - [Browsable(false)] - public bool IsHidden - { - get { return DockHandler.IsHidden; } - set { DockHandler.IsHidden = value; } - } - - [Browsable(false)] - public DockState VisibleState - { - get { return DockHandler.VisibleState; } - set { DockHandler.VisibleState = value; } - } - - [Browsable(false)] - public bool IsFloat - { - get { return DockHandler.IsFloat; } - set { DockHandler.IsFloat = value; } - } - - [Browsable(false)] - public DockPane PanelPane - { - get { return DockHandler.PanelPane; } - set { DockHandler.PanelPane = value; } - } - - [Browsable(false)] - public DockPane FloatPane - { - get { return DockHandler.FloatPane; } - set { DockHandler.FloatPane = value; } - } - - [SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate")] - protected virtual string GetPersistString() - { - return GetType().ToString(); - } - - [LocalizedCategory("Category_Docking")] - [LocalizedDescription("DockContent_HideOnClose_Description")] - [DefaultValue(false)] - public bool HideOnClose - { - get { return DockHandler.HideOnClose; } - set { DockHandler.HideOnClose = value; } - } - - [LocalizedCategory("Category_Docking")] - [LocalizedDescription("DockContent_ShowHint_Description")] - [DefaultValue(DockState.Unknown)] - public DockState ShowHint - { - get { return DockHandler.ShowHint; } - set { DockHandler.ShowHint = value; } - } - - [Browsable(false)] - public bool IsActivated - { - get { return DockHandler.IsActivated; } - } - - public bool IsDockStateValid(DockState dockState) - { - return DockHandler.IsDockStateValid(dockState); - } - - [LocalizedCategory("Category_Docking")] - [LocalizedDescription("DockContent_TabPageContextMenu_Description")] - [DefaultValue(null)] - public ContextMenu TabPageContextMenu - { - get { return DockHandler.TabPageContextMenu; } - set { DockHandler.TabPageContextMenu = value; } - } - - [LocalizedCategory("Category_Docking")] - [LocalizedDescription("DockContent_TabPageContextMenuStrip_Description")] - [DefaultValue(null)] - public ContextMenuStrip TabPageContextMenuStrip - { - get { return DockHandler.TabPageContextMenuStrip; } - set { DockHandler.TabPageContextMenuStrip = value; } - } - - [Localizable(true)] - [Category("Appearance")] - [LocalizedDescription("DockContent_ToolTipText_Description")] - [DefaultValue(null)] - public string ToolTipText - { - get { return DockHandler.ToolTipText; } - set { DockHandler.ToolTipText = value; } - } - - public new void Activate() - { - DockHandler.Activate(); - } - - public new void Hide() - { - DockHandler.Hide(); - } - - public new void Show() - { - DockHandler.Show(); - } - - public void Show(DockPanel dockPanel) - { - DockHandler.Show(dockPanel); - } - - public void Show(DockPanel dockPanel, DockState dockState) - { - DockHandler.Show(dockPanel, dockState); - } - - [SuppressMessage("Microsoft.Naming", "CA1720:AvoidTypeNamesInParameters")] - public void Show(DockPanel dockPanel, Rectangle floatWindowBounds) - { - DockHandler.Show(dockPanel, floatWindowBounds); - } - - public void Show(DockPane pane, IDockContent beforeContent) - { - DockHandler.Show(pane, beforeContent); - } - - public void Show(DockPane previousPane, DockAlignment alignment, double proportion) - { - DockHandler.Show(previousPane, alignment, proportion); - } - - [SuppressMessage("Microsoft.Naming", "CA1720:AvoidTypeNamesInParameters")] - public void FloatAt(Rectangle floatWindowBounds) - { - DockHandler.FloatAt(floatWindowBounds); - } - - public void DockTo(DockPane paneTo, DockStyle dockStyle, int contentIndex) - { - DockHandler.DockTo(paneTo, dockStyle, contentIndex); - } - - public void DockTo(DockPanel panel, DockStyle dockStyle) - { - DockHandler.DockTo(panel, dockStyle); - } - - #region Events - private void DockHandler_DockStateChanged(object sender, EventArgs e) - { - OnDockStateChanged(e); - } - - private static readonly object DockStateChangedEvent = new object(); - [LocalizedCategory("Category_PropertyChanged")] - [LocalizedDescription("Pane_DockStateChanged_Description")] - public event EventHandler DockStateChanged - { - add { Events.AddHandler(DockStateChangedEvent, value); } - remove { Events.RemoveHandler(DockStateChangedEvent, value); } - } - protected virtual void OnDockStateChanged(EventArgs e) - { - EventHandler handler = (EventHandler)Events[DockStateChangedEvent]; - if (handler != null) - handler(this, e); - } - #endregion - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockContentCollection.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockContentCollection.cs deleted file mode 100644 index 141615f477..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockContentCollection.cs +++ /dev/null @@ -1,175 +0,0 @@ -using System; -using System.Collections; -using System.Collections.Generic; -using System.Collections.ObjectModel; - -namespace WeifenLuo.WinFormsUI.Docking -{ - public class DockContentCollection : ReadOnlyCollection - { - private static List _emptyList = new List(0); - - internal DockContentCollection() - : base(new List()) - { - } - - internal DockContentCollection(DockPane pane) - : base(_emptyList) - { - m_dockPane = pane; - } - - private DockPane m_dockPane = null; - private DockPane DockPane - { - get { return m_dockPane; } - } - - public new IDockContent this[int index] - { - get - { - if (DockPane == null) - return Items[index] as IDockContent; - else - return GetVisibleContent(index); - } - } - - internal int Add(IDockContent content) - { -#if DEBUG - if (DockPane != null) - throw new InvalidOperationException(); -#endif - - if (Contains(content)) - return IndexOf(content); - - Items.Add(content); - return Count - 1; - } - - internal void AddAt(IDockContent content, int index) - { -#if DEBUG - if (DockPane != null) - throw new InvalidOperationException(); -#endif - - if (index < 0 || index > Items.Count - 1) - return; - - if (Contains(content)) - return; - - Items.Insert(index, content); - } - - public new bool Contains(IDockContent content) - { - if (DockPane == null) - return Items.Contains(content); - else - return (GetIndexOfVisibleContents(content) != -1); - } - - public new int Count - { - get - { - if (DockPane == null) - return base.Count; - else - return CountOfVisibleContents; - } - } - - public new int IndexOf(IDockContent content) - { - if (DockPane == null) - { - if (!Contains(content)) - return -1; - else - return Items.IndexOf(content); - } - else - return GetIndexOfVisibleContents(content); - } - - internal void Remove(IDockContent content) - { - if (DockPane != null) - throw new InvalidOperationException(); - - if (!Contains(content)) - return; - - Items.Remove(content); - } - - private int CountOfVisibleContents - { - get - { -#if DEBUG - if (DockPane == null) - throw new InvalidOperationException(); -#endif - - int count = 0; - foreach (IDockContent content in DockPane.Contents) - { - if (content.DockHandler.DockState == DockPane.DockState) - count++; - } - return count; - } - } - - private IDockContent GetVisibleContent(int index) - { -#if DEBUG - if (DockPane == null) - throw new InvalidOperationException(); -#endif - - int currentIndex = -1; - foreach (IDockContent content in DockPane.Contents) - { - if (content.DockHandler.DockState == DockPane.DockState) - currentIndex++; - - if (currentIndex == index) - return content; - } - throw (new ArgumentOutOfRangeException()); - } - - private int GetIndexOfVisibleContents(IDockContent content) - { -#if DEBUG - if (DockPane == null) - throw new InvalidOperationException(); -#endif - - if (content == null) - return -1; - - int index = -1; - foreach (IDockContent c in DockPane.Contents) - { - if (c.DockHandler.DockState == DockPane.DockState) - { - index++; - - if (c == content) - return index; - } - } - return -1; - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockContentEventArgs.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockContentEventArgs.cs deleted file mode 100644 index 49d9caff4a..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockContentEventArgs.cs +++ /dev/null @@ -1,19 +0,0 @@ -using System; - -namespace WeifenLuo.WinFormsUI.Docking -{ - public class DockContentEventArgs : EventArgs - { - private IDockContent m_content; - - public DockContentEventArgs(IDockContent content) - { - m_content = content; - } - - public IDockContent Content - { - get { return m_content; } - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockContentHandler.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockContentHandler.cs deleted file mode 100644 index 1599837e17..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockContentHandler.cs +++ /dev/null @@ -1,1069 +0,0 @@ -using System; -using System.Windows.Forms; -using System.Drawing; -using System.ComponentModel; -using System.Diagnostics.CodeAnalysis; - -namespace WeifenLuo.WinFormsUI.Docking -{ - public delegate string GetPersistStringCallback(); - - public class DockContentHandler : IDisposable, IDockDragSource - { - public DockContentHandler(Form form) : this(form, null) - { - } - - public DockContentHandler(Form form, GetPersistStringCallback getPersistStringCallback) - { - if (!(form is IDockContent)) - throw new ArgumentException(Strings.DockContent_Constructor_InvalidForm, "form"); - - m_form = form; - m_getPersistStringCallback = getPersistStringCallback; - - m_events = new EventHandlerList(); - Form.Disposed +=new EventHandler(Form_Disposed); - Form.TextChanged += new EventHandler(Form_TextChanged); - } - - public void Dispose() - { - Dispose(true); - GC.SuppressFinalize(this); - } - - protected virtual void Dispose(bool disposing) - { - if(disposing) - { - lock(this) - { - DockPanel = null; - if (m_autoHideTab != null) - m_autoHideTab.Dispose(); - if (m_tab != null) - m_tab.Dispose(); - - Form.Disposed -= new EventHandler(Form_Disposed); - Form.TextChanged -= new EventHandler(Form_TextChanged); - m_events.Dispose(); - } - } - } - - private Form m_form; - public Form Form - { - get { return m_form; } - } - - public IDockContent Content - { - get { return Form as IDockContent; } - } - - private IDockContent m_previousActive = null; - public IDockContent PreviousActive - { - get { return m_previousActive; } - internal set { m_previousActive = value; } - } - - private IDockContent m_nextActive = null; - public IDockContent NextActive - { - get { return m_nextActive; } - internal set { m_nextActive = value; } - } - - private EventHandlerList m_events; - private EventHandlerList Events - { - get { return m_events; } - } - - private bool m_allowEndUserDocking = true; - public bool AllowEndUserDocking - { - get { return m_allowEndUserDocking; } - set { m_allowEndUserDocking = value; } - } - - private double m_autoHidePortion = 0.25; - public double AutoHidePortion - { - get { return m_autoHidePortion; } - set - { - if (value <= 0) - throw(new ArgumentOutOfRangeException(Strings.DockContentHandler_AutoHidePortion_OutOfRange)); - - if (m_autoHidePortion == value) - return; - - m_autoHidePortion = value; - - if (DockPanel == null) - return; - - if (DockPanel.ActiveAutoHideContent == Content) - DockPanel.PerformLayout(); - } - } - - private bool m_closeButton = true; - public bool CloseButton - { - get { return m_closeButton; } - set - { - if (m_closeButton == value) - return; - - m_closeButton = value; - if (Pane != null) - if (Pane.ActiveContent.DockHandler == this) - Pane.RefreshChanges(); - } - } - - private DockState DefaultDockState - { - get - { - if (ShowHint != DockState.Unknown && ShowHint != DockState.Hidden) - return ShowHint; - - if ((DockAreas & DockAreas.Document) != 0) - return DockState.Document; - if ((DockAreas & DockAreas.DockRight) != 0) - return DockState.DockRight; - if ((DockAreas & DockAreas.DockLeft) != 0) - return DockState.DockLeft; - if ((DockAreas & DockAreas.DockBottom) != 0) - return DockState.DockBottom; - if ((DockAreas & DockAreas.DockTop) != 0) - return DockState.DockTop; - - return DockState.Unknown; - } - } - - private DockState DefaultShowState - { - get - { - if (ShowHint != DockState.Unknown) - return ShowHint; - - if ((DockAreas & DockAreas.Document) != 0) - return DockState.Document; - if ((DockAreas & DockAreas.DockRight) != 0) - return DockState.DockRight; - if ((DockAreas & DockAreas.DockLeft) != 0) - return DockState.DockLeft; - if ((DockAreas & DockAreas.DockBottom) != 0) - return DockState.DockBottom; - if ((DockAreas & DockAreas.DockTop) != 0) - return DockState.DockTop; - if ((DockAreas & DockAreas.Float) != 0) - return DockState.Float; - - return DockState.Unknown; - } - } - - private DockAreas m_allowedAreas = DockAreas.DockLeft | DockAreas.DockRight | DockAreas.DockTop | DockAreas.DockBottom | DockAreas.Document | DockAreas.Float; - public DockAreas DockAreas - { - get { return m_allowedAreas; } - set - { - if (m_allowedAreas == value) - return; - - if (!DockHelper.IsDockStateValid(DockState, value)) - throw(new InvalidOperationException(Strings.DockContentHandler_DockAreas_InvalidValue)); - - m_allowedAreas = value; - - if (!DockHelper.IsDockStateValid(ShowHint, m_allowedAreas)) - ShowHint = DockState.Unknown; - } - } - - private DockState m_dockState = DockState.Unknown; - public DockState DockState - { - get { return m_dockState; } - set - { - if (m_dockState == value) - return; - - DockPanel.SuspendLayout(true); - - if (value == DockState.Hidden) - IsHidden = true; - else - SetDockState(false, value, Pane); - - DockPanel.ResumeLayout(true, true); - } - } - - private DockPanel m_dockPanel = null; - public DockPanel DockPanel - { - get { return m_dockPanel; } - set - { - if (m_dockPanel == value) - return; - - Pane = null; - - if (m_dockPanel != null) - m_dockPanel.RemoveContent(Content); - - if (m_tab != null) - { - m_tab.Dispose(); - m_tab = null; - } - - if (m_autoHideTab != null) - { - m_autoHideTab.Dispose(); - m_autoHideTab = null; - } - - m_dockPanel = value; - - if (m_dockPanel != null) - { - m_dockPanel.AddContent(Content); - Form.TopLevel = false; - Form.FormBorderStyle = FormBorderStyle.None; - Form.ShowInTaskbar = false; - Form.WindowState = FormWindowState.Normal; - NativeMethods.SetWindowPos(Form.Handle, IntPtr.Zero, 0, 0, 0, 0, - Win32.FlagsSetWindowPos.SWP_NOACTIVATE | - Win32.FlagsSetWindowPos.SWP_NOMOVE | - Win32.FlagsSetWindowPos.SWP_NOSIZE | - Win32.FlagsSetWindowPos.SWP_NOZORDER | - Win32.FlagsSetWindowPos.SWP_NOOWNERZORDER | - Win32.FlagsSetWindowPos.SWP_FRAMECHANGED); - } - } - } - - public Icon Icon - { - get { return Form.Icon; } - } - - public DockPane Pane - { - get { return IsFloat ? FloatPane : PanelPane; } - set - { - if (Pane == value) - return; - - DockPanel.SuspendLayout(true); - - DockPane oldPane = Pane; - - SuspendSetDockState(); - FloatPane = (value == null ? null : (value.IsFloat ? value : FloatPane)); - PanelPane = (value == null ? null : (value.IsFloat ? PanelPane : value)); - ResumeSetDockState(IsHidden, value != null ? value.DockState : DockState.Unknown, oldPane); - - DockPanel.ResumeLayout(true, true); - } - } - - private bool m_isHidden = true; - public bool IsHidden - { - get { return m_isHidden; } - set - { - if (m_isHidden == value) - return; - - SetDockState(value, VisibleState, Pane); - } - } - - private string m_tabText = null; - public string TabText - { - get { return m_tabText==null ? Form.Text : m_tabText; } - set - { - if (m_tabText == value) - return; - - m_tabText = value; - if (Pane != null) - Pane.RefreshChanges(); - } - } - - private DockState m_visibleState = DockState.Unknown; - public DockState VisibleState - { - get { return m_visibleState; } - set - { - if (m_visibleState == value) - return; - - SetDockState(IsHidden, value, Pane); - } - } - - private bool m_isFloat = false; - public bool IsFloat - { - get { return m_isFloat; } - set - { - if (m_isFloat == value) - return; - - DockState visibleState = CheckDockState(value); - - if (visibleState == DockState.Unknown) - throw new InvalidOperationException(Strings.DockContentHandler_IsFloat_InvalidValue); - - SetDockState(IsHidden, visibleState, Pane); - } - } - - [SuppressMessage("Microsoft.Naming", "CA1720:AvoidTypeNamesInParameters")] - public DockState CheckDockState(bool isFloat) - { - DockState dockState; - - if (isFloat) - { - if (!IsDockStateValid(DockState.Float)) - dockState = DockState.Unknown; - else - dockState = DockState.Float; - } - else - { - dockState = (PanelPane != null) ? PanelPane.DockState : DefaultDockState; - if (dockState != DockState.Unknown && !IsDockStateValid(dockState)) - dockState = DockState.Unknown; - } - - return dockState; - } - - private DockPane m_panelPane = null; - public DockPane PanelPane - { - get { return m_panelPane; } - set - { - if (m_panelPane == value) - return; - - if (value != null) - { - if (value.IsFloat || value.DockPanel != DockPanel) - throw new InvalidOperationException(Strings.DockContentHandler_DockPane_InvalidValue); - } - - DockPane oldPane = Pane; - - if (m_panelPane != null) - RemoveFromPane(m_panelPane); - m_panelPane = value; - if (m_panelPane != null) - { - m_panelPane.AddContent(Content); - SetDockState(IsHidden, IsFloat ? DockState.Float : m_panelPane.DockState, oldPane); - } - else - SetDockState(IsHidden, DockState.Unknown, oldPane); - } - } - - private void RemoveFromPane(DockPane pane) - { - pane.RemoveContent(Content); - SetPane(null); - if (pane.Contents.Count == 0) - pane.Dispose(); - } - - private DockPane m_floatPane = null; - public DockPane FloatPane - { - get { return m_floatPane; } - set - { - if (m_floatPane == value) - return; - - if (value != null) - { - if (!value.IsFloat || value.DockPanel != DockPanel) - throw new InvalidOperationException(Strings.DockContentHandler_FloatPane_InvalidValue); - } - - DockPane oldPane = Pane; - - if (m_floatPane != null) - RemoveFromPane(m_floatPane); - m_floatPane = value; - if (m_floatPane != null) - { - m_floatPane.AddContent(Content); - SetDockState(IsHidden, IsFloat ? DockState.Float : VisibleState, oldPane); - } - else - SetDockState(IsHidden, DockState.Unknown, oldPane); - } - } - - private int m_countSetDockState = 0; - private void SuspendSetDockState() - { - m_countSetDockState ++; - } - - private void ResumeSetDockState() - { - m_countSetDockState --; - if (m_countSetDockState < 0) - m_countSetDockState = 0; - } - - internal bool IsSuspendSetDockState - { - get { return m_countSetDockState != 0; } - } - - private void ResumeSetDockState(bool isHidden, DockState visibleState, DockPane oldPane) - { - ResumeSetDockState(); - SetDockState(isHidden, visibleState, oldPane); - } - - internal void SetDockState(bool isHidden, DockState visibleState, DockPane oldPane) - { - if (IsSuspendSetDockState) - return; - - if (DockPanel == null && visibleState != DockState.Unknown) - throw new InvalidOperationException(Strings.DockContentHandler_SetDockState_NullPanel); - - if (visibleState == DockState.Hidden || (visibleState != DockState.Unknown && !IsDockStateValid(visibleState))) - throw new InvalidOperationException(Strings.DockContentHandler_SetDockState_InvalidState); - - DockPanel dockPanel = DockPanel; - if (dockPanel != null) - dockPanel.SuspendLayout(true); - - SuspendSetDockState(); - - DockState oldDockState = DockState; - - if (m_isHidden != isHidden || oldDockState == DockState.Unknown) - { - m_isHidden = isHidden; - } - m_visibleState = visibleState; - m_dockState = isHidden ? DockState.Hidden : visibleState; - - if (visibleState == DockState.Unknown) - Pane = null; - else - { - m_isFloat = (m_visibleState == DockState.Float); - - if (Pane == null) - Pane = DockPanel.DockPaneFactory.CreateDockPane(Content, visibleState, true); - else if (Pane.DockState != visibleState) - { - if (Pane.Contents.Count == 1) - Pane.SetDockState(visibleState); - else - Pane = DockPanel.DockPaneFactory.CreateDockPane(Content, visibleState, true); - } - } - - if (Form.ContainsFocus) - if (DockState == DockState.Hidden || DockState == DockState.Unknown) - DockPanel.ContentFocusManager.GiveUpFocus(Content); - - SetPaneAndVisible(Pane); - - if (oldPane != null && !oldPane.IsDisposed && oldDockState == oldPane.DockState) - RefreshDockPane(oldPane); - - if (Pane != null && DockState == Pane.DockState) - { - if ((Pane != oldPane) || - (Pane == oldPane && oldDockState != oldPane.DockState)) - RefreshDockPane(Pane); - } - - if (oldDockState != DockState) - { - if (DockState == DockState.Hidden || DockState == DockState.Unknown || - DockHelper.IsDockStateAutoHide(DockState)) - DockPanel.ContentFocusManager.RemoveFromList(Content); - else - DockPanel.ContentFocusManager.AddToList(Content); - - OnDockStateChanged(EventArgs.Empty); - } - ResumeSetDockState(); - - if (dockPanel != null) - dockPanel.ResumeLayout(true, true); - } - - private static void RefreshDockPane(DockPane pane) - { - pane.RefreshChanges(); - pane.ValidateActiveContent(); - } - - internal string PersistString - { - get { return GetPersistStringCallback == null ? Form.GetType().ToString() : GetPersistStringCallback(); } - } - - private GetPersistStringCallback m_getPersistStringCallback = null; - public GetPersistStringCallback GetPersistStringCallback - { - get { return m_getPersistStringCallback; } - set { m_getPersistStringCallback = value; } - } - - - private bool m_hideOnClose = false; - public bool HideOnClose - { - get { return m_hideOnClose; } - set { m_hideOnClose = value; } - } - - private DockState m_showHint = DockState.Unknown; - public DockState ShowHint - { - get { return m_showHint; } - set - { - if (!DockHelper.IsDockStateValid(value, DockAreas)) - throw (new InvalidOperationException(Strings.DockContentHandler_ShowHint_InvalidValue)); - - if (m_showHint == value) - return; - - m_showHint = value; - } - } - - private bool m_isActivated = false; - public bool IsActivated - { - get { return m_isActivated; } - internal set - { - if (m_isActivated == value) - return; - - m_isActivated = value; - } - } - - public bool IsDockStateValid(DockState dockState) - { - if (DockPanel != null && dockState == DockState.Document && DockPanel.DocumentStyle == DocumentStyle.SystemMdi) - return false; - else - return DockHelper.IsDockStateValid(dockState, DockAreas); - } - - private ContextMenu m_tabPageContextMenu = null; - public ContextMenu TabPageContextMenu - { - get { return m_tabPageContextMenu; } - set { m_tabPageContextMenu = value; } - } - - private string m_toolTipText = null; - public string ToolTipText - { - get { return m_toolTipText; } - set { m_toolTipText = value; } - } - - public void Activate() - { - if (DockPanel == null) - Form.Activate(); - else if (Pane == null) - Show(DockPanel); - else - { - IsHidden = false; - Pane.ActiveContent = Content; - if (DockState == DockState.Document && DockPanel.DocumentStyle == DocumentStyle.SystemMdi) - { - Form.Activate(); - return; - } - else if (DockHelper.IsDockStateAutoHide(DockState)) - DockPanel.ActiveAutoHideContent = Content; - - if (!Form.ContainsFocus) - DockPanel.ContentFocusManager.Activate(Content); - } - } - - public void GiveUpFocus() - { - DockPanel.ContentFocusManager.GiveUpFocus(Content); - } - - private IntPtr m_activeWindowHandle = IntPtr.Zero; - internal IntPtr ActiveWindowHandle - { - get { return m_activeWindowHandle; } - set { m_activeWindowHandle = value; } - } - - public void Hide() - { - IsHidden = true; - } - - internal void SetPaneAndVisible(DockPane pane) - { - SetPane(pane); - SetVisible(); - } - - private void SetPane(DockPane pane) - { - if (pane != null && pane.DockState == DockState.Document && DockPanel.DocumentStyle == DocumentStyle.DockingMdi) - { - if (Form.Parent is DockPane) - SetParent(null); - if (Form.MdiParent != DockPanel.ParentForm) - { - FlagClipWindow = true; - Form.MdiParent = DockPanel.ParentForm; - } - } - else - { - FlagClipWindow = true; - if (Form.MdiParent != null) - Form.MdiParent = null; - if (Form.TopLevel) - Form.TopLevel = false; - SetParent(pane); - } - } - - internal void SetVisible() - { - bool visible; - - if (IsHidden) - visible = false; - else if (Pane != null && Pane.DockState == DockState.Document && DockPanel.DocumentStyle == DocumentStyle.DockingMdi) - visible = true; - else if (Pane != null && Pane.ActiveContent == Content) - visible = true; - else if (Pane != null && Pane.ActiveContent != Content) - visible = false; - else - visible = Form.Visible; - - // when Form.Parent.Visible==false, Form.Visible cannot be read correctly (but returns always false), - // so we have to always assign the new visibility in those cases - if (Form.Visible != visible || (Form.Parent != null && !Form.Parent.Visible)) - Form.Visible = visible; - } - - private void SetParent(Control value) - { - if (Form.Parent == value) - return; - - //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! - // Workaround of .Net Framework bug: - // Change the parent of a control with focus may result in the first - // MDI child form get activated. - //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -// bool bRestoreFocus = false; -// if (Form.ContainsFocus) -// { -// if (value == null) -// DockPanel.ContentFocusManager.GiveUpFocus(this.Content); -// else -// { -// DockPanel.SaveFocus(); -// bRestoreFocus = true; -// } -// } - //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! - - Form.Parent = value; - - //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! - // Workaround of .Net Framework bug: - // Change the parent of a control with focus may result in the first - // MDI child form get activated. - //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -/* Workaround disabled: in SharpDevelop, the Activate() call causes an exception on layout changes - iff no document is open and a pad has the focus. - I don't think we need this workaround because we don't use MDI. - -System.InvalidOperationException: Invalid Content: ActiveContent must be one ofthe visible contents, or null if there is no visible content. - at WeifenLuo.WinFormsUI.Docking.DockPane.set_ActiveContent(IDockContent value) in d:\SD\3.0\SharpDevelop\src\Libraries\DockPanel_Src\WinFormsUI\Docking\DockPane.cs:line 162 - at WeifenLuo.WinFormsUI.Docking.DockContentHandler.Activate() in d:\SD\3.0\SharpDevelop\src\Libraries\DockPanel_Src\WinFormsUI\Docking\DockContentHandler.cs:line 618 - at WeifenLuo.WinFormsUI.Docking.DockContentHandler.SetParent(Control value) in d:\SD\3.0\SharpDevelop\src\Libraries\DockPanel_Src\WinFormsUI\Docking\DockContentHandler.cs:line 728 - at WeifenLuo.WinFormsUI.Docking.DockContentHandler.SetPane(DockPane pane) in d:\SD\3.0\SharpDevelop\src\Libraries\DockPanel_Src\WinFormsUI\Docking\DockContentHandler.cs:line 674 - at WeifenLuo.WinFormsUI.Docking.DockContentHandler.SetPaneAndVisible(DockPane pane) in d:\SD\3.0\SharpDevelop\src\Libraries\DockPanel_Src\WinFormsUI\Docking\DockContentHandler.cs:line 651 - at WeifenLuo.WinFormsUI.Docking.DockContentHandler.SetDockState(Boolean isHidden, DockState visibleState, DockPane oldPane) in d:\SD\3.0\SharpDevelop\src\Libraries\DockPanel_Src\WinFormsUI\Docking\DockContentHandler.cs:line 504 - at WeifenLuo.WinFormsUI.Docking.DockContentHandler.set_PanelPane(DockPane value) in d:\SD\3.0\SharpDevelop\src\Libraries\DockPanel_Src\WinFormsUI\Docking\DockContentHandler.cs:line 388 - at WeifenLuo.WinFormsUI.Docking.DockPanel.Persistor.LoadFromXml(DockPanel dockPanel, Stream stream, DeserializeDockContent deserializeContent, Boolean closeStream) in d:\SD\3.0\SharpDevelop\src\Libraries\DockPanel_Src\WinFormsUI\Docking\DockPanel.Persistor.cs:line 614 - at WeifenLuo.WinFormsUI.Docking.DockPanel.Persistor.LoadFromXml(DockPanel dockPanel, Stream stream, DeserializeDockContent deserializeContent) in d:\SD\3.0\SharpDevelop\src\Libraries\DockPanel_Src\WinFormsUI\Docking\DockPanel.Persistor.cs:line 378 - at WeifenLuo.WinFormsUI.Docking.DockPanel.LoadFromXml(Stream stream, DeserializeDockContent deserializeContent) in d:\SD\3.0\SharpDevelop\src\Libraries\DockPanel_Src\WinFormsUI\Docking\DockPanel.Persistor.cs:line 772 - at ICSharpCode.SharpDevelop.Gui.SdiWorkbenchLayout.LoadDockPanelLayout(String fileName) in d:\SD\3.0\SharpDevelop\src\Main\Base\Project\Src\Gui\Workbench\Layouts\SdiWorkspaceLayout.cs:line 213 - at ICSharpCode.SharpDevelop.Gui.SdiWorkbenchLayout.LoadLayoutConfiguration()in d:\SD\3.0\SharpDevelop\src\Main\Base\Project\Src\Gui\Workbench\Layouts\SdiWorkspaceLayout.cs:line 190 - - if (bRestoreFocus) - Activate(); - */ - //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! - } - - public void Show() - { - if (DockPanel == null) - Form.Show(); - else - Show(DockPanel); - } - - public void Show(DockPanel dockPanel) - { - if (dockPanel == null) - throw(new ArgumentNullException(Strings.DockContentHandler_Show_NullDockPanel)); - - if (DockState == DockState.Unknown) - Show(dockPanel, DefaultShowState); - else if (Pane == null) - Show(dockPanel, DockState == DockState.Hidden ? DefaultShowState : DockState); - else - Activate(); - } - - public void Show(DockPanel dockPanel, DockState dockState) - { - if (dockPanel == null) - throw(new ArgumentNullException(Strings.DockContentHandler_Show_NullDockPanel)); - - if (dockState == DockState.Unknown || dockState == DockState.Hidden) - throw(new ArgumentException(Strings.DockContentHandler_Show_InvalidDockState)); - - dockPanel.SuspendLayout(true); - - DockPanel = dockPanel; - - if (dockState == DockState.Float && FloatPane == null) - Pane = DockPanel.DockPaneFactory.CreateDockPane(Content, DockState.Float, true); - else if (PanelPane == null) - { - DockPane paneExisting = null; - foreach (DockPane pane in DockPanel.Panes) - if (pane.DockState == dockState) - { - paneExisting = pane; - break; - } - - if (paneExisting == null) - Pane = DockPanel.DockPaneFactory.CreateDockPane(Content, dockState, true); - else - Pane = paneExisting; - } - - DockState = dockState; - Activate(); - - dockPanel.ResumeLayout(true, true); - } - - [SuppressMessage("Microsoft.Naming", "CA1720:AvoidTypeNamesInParameters")] - public void Show(DockPanel dockPanel, Rectangle floatWindowBounds) - { - if (dockPanel == null) - throw(new ArgumentNullException(Strings.DockContentHandler_Show_NullDockPanel)); - - dockPanel.SuspendLayout(true); - - DockPanel = dockPanel; - if (FloatPane == null) - { - IsHidden = true; // to reduce the screen flicker - FloatPane = DockPanel.DockPaneFactory.CreateDockPane(Content, DockState.Float, false); - FloatPane.FloatWindow.StartPosition = FormStartPosition.Manual; - } - - FloatPane.FloatWindow.Bounds = floatWindowBounds; - - Show(dockPanel, DockState.Float); - Activate(); - - dockPanel.ResumeLayout(true, true); - } - - public void Show(DockPane pane, IDockContent beforeContent) - { - if (pane == null) - throw(new ArgumentNullException(Strings.DockContentHandler_Show_NullPane)); - - if (beforeContent != null && pane.Contents.IndexOf(beforeContent) == -1) - throw(new ArgumentException(Strings.DockContentHandler_Show_InvalidBeforeContent)); - - pane.DockPanel.SuspendLayout(true); - - DockPanel = pane.DockPanel; - Pane = pane; - pane.SetContentIndex(Content, pane.Contents.IndexOf(beforeContent)); - Show(); - - pane.DockPanel.ResumeLayout(true, true); - } - - public void Show(DockPane previousPane, DockAlignment alignment, double proportion) - { - if (previousPane == null) - throw(new ArgumentException(Strings.DockContentHandler_Show_InvalidPrevPane)); - - if (DockHelper.IsDockStateAutoHide(previousPane.DockState)) - throw(new ArgumentException(Strings.DockContentHandler_Show_InvalidPrevPane)); - - previousPane.DockPanel.SuspendLayout(true); - - DockPanel = previousPane.DockPanel; - DockPanel.DockPaneFactory.CreateDockPane(Content, previousPane, alignment, proportion, true); - Show(); - - previousPane.DockPanel.ResumeLayout(true, true); - } - - public void Close() - { - DockPanel dockPanel = DockPanel; - if (dockPanel != null) - dockPanel.SuspendLayout(true); - Form.Close(); - if (dockPanel != null) - dockPanel.ResumeLayout(true, true); - - } - - private DockPaneStripBase.Tab m_tab = null; - internal DockPaneStripBase.Tab GetTab(DockPaneStripBase dockPaneStrip) - { - if (m_tab == null) - m_tab = dockPaneStrip.CreateTab(Content); - - return m_tab; - } - - private IDisposable m_autoHideTab = null; - internal IDisposable AutoHideTab - { - get { return m_autoHideTab; } - set { m_autoHideTab = value; } - } - - #region Events - private static readonly object DockStateChangedEvent = new object(); - public event EventHandler DockStateChanged - { - add { Events.AddHandler(DockStateChangedEvent, value); } - remove { Events.RemoveHandler(DockStateChangedEvent, value); } - } - protected virtual void OnDockStateChanged(EventArgs e) - { - EventHandler handler = (EventHandler)Events[DockStateChangedEvent]; - if (handler != null) - handler(this, e); - } - #endregion - - private void Form_Disposed(object sender, EventArgs e) - { - Dispose(); - } - - private void Form_TextChanged(object sender, EventArgs e) - { - if (DockHelper.IsDockStateAutoHide(DockState)) - DockPanel.RefreshAutoHideStrip(); - else if (Pane != null) - { - if (Pane.FloatWindow != null) - Pane.FloatWindow.SetText(); - Pane.RefreshChanges(); - } - } - - private bool m_flagClipWindow = false; - internal bool FlagClipWindow - { - get { return m_flagClipWindow; } - set - { - if (m_flagClipWindow == value) - return; - - m_flagClipWindow = value; - if (m_flagClipWindow) - Form.Region = new Region(Rectangle.Empty); - else - Form.Region = null; - } - } - - private ContextMenuStrip m_tabPageContextMenuStrip = null; - public ContextMenuStrip TabPageContextMenuStrip - { - get { return m_tabPageContextMenuStrip; } - set { m_tabPageContextMenuStrip = value; } - } - - #region IDockDragSource Members - - Control IDragSource.DragControl - { - get { return Form; } - } - - bool IDockDragSource.CanDockTo(DockPane pane) - { - if (!IsDockStateValid(pane.DockState)) - return false; - - if (Pane == pane && pane.DisplayingContents.Count == 1) - return false; - - return true; - } - - Rectangle IDockDragSource.BeginDrag(Point ptMouse) - { - Size size; - DockPane floatPane = this.FloatPane; - if (DockState == DockState.Float || floatPane == null || floatPane.FloatWindow.NestedPanes.Count != 1) - size = DockPanel.DefaultFloatWindowSize; - else - size = floatPane.FloatWindow.Size; - - Point location; - Rectangle rectPane = Pane.ClientRectangle; - if (DockState == DockState.Document) - location = new Point(rectPane.Left, rectPane.Top); - else - { - location = new Point(rectPane.Left, rectPane.Bottom); - location.Y -= size.Height; - } - location = Pane.PointToScreen(location); - - if (ptMouse.X > location.X + size.Width) - location.X += ptMouse.X - (location.X + size.Width) + Measures.SplitterSize; - - return new Rectangle(location, size); - } - - public void FloatAt(Rectangle floatWindowBounds) - { - DockPane pane = DockPanel.DockPaneFactory.CreateDockPane(Content, floatWindowBounds, true); - } - - public void DockTo(DockPane pane, DockStyle dockStyle, int contentIndex) - { - if (dockStyle == DockStyle.Fill) - { - bool samePane = (Pane == pane); - if (!samePane) - Pane = pane; - - if (contentIndex == -1 || !samePane) - pane.SetContentIndex(Content, contentIndex); - else - { - DockContentCollection contents = pane.Contents; - int oldIndex = contents.IndexOf(Content); - int newIndex = contentIndex; - if (oldIndex < newIndex) - { - newIndex += 1; - if (newIndex > contents.Count -1) - newIndex = -1; - } - pane.SetContentIndex(Content, newIndex); - } - } - else - { - DockPane paneFrom = DockPanel.DockPaneFactory.CreateDockPane(Content, pane.DockState, true); - INestedPanesContainer container = pane.NestedPanesContainer; - if (dockStyle == DockStyle.Left) - paneFrom.DockTo(container, pane, DockAlignment.Left, 0.5); - else if (dockStyle == DockStyle.Right) - paneFrom.DockTo(container, pane, DockAlignment.Right, 0.5); - else if (dockStyle == DockStyle.Top) - paneFrom.DockTo(container, pane, DockAlignment.Top, 0.5); - else if (dockStyle == DockStyle.Bottom) - paneFrom.DockTo(container, pane, DockAlignment.Bottom, 0.5); - - paneFrom.DockState = pane.DockState; - } - } - - public void DockTo(DockPanel panel, DockStyle dockStyle) - { - if (panel != DockPanel) - throw new ArgumentException(Strings.IDockDragSource_DockTo_InvalidPanel, "panel"); - - DockPane pane; - - if (dockStyle == DockStyle.Top) - pane = DockPanel.DockPaneFactory.CreateDockPane(Content, DockState.DockTop, true); - else if (dockStyle == DockStyle.Bottom) - pane = DockPanel.DockPaneFactory.CreateDockPane(Content, DockState.DockBottom, true); - else if (dockStyle == DockStyle.Left) - pane = DockPanel.DockPaneFactory.CreateDockPane(Content, DockState.DockLeft, true); - else if (dockStyle == DockStyle.Right) - pane = DockPanel.DockPaneFactory.CreateDockPane(Content, DockState.DockRight, true); - else if (dockStyle == DockStyle.Fill) - pane = DockPanel.DockPaneFactory.CreateDockPane(Content, DockState.Document, true); - else - return; - } - - #endregion - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockOutlineBase.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockOutlineBase.cs deleted file mode 100644 index 6d24175fc3..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockOutlineBase.cs +++ /dev/null @@ -1,161 +0,0 @@ -using System; -using System.Drawing; -using System.Windows.Forms; - -namespace WeifenLuo.WinFormsUI.Docking -{ - internal abstract class DockOutlineBase - { - public DockOutlineBase() - { - Init(); - } - - private void Init() - { - SetValues(Rectangle.Empty, null, DockStyle.None, -1); - SaveOldValues(); - } - - private Rectangle m_oldFloatWindowBounds; - protected Rectangle OldFloatWindowBounds - { - get { return m_oldFloatWindowBounds; } - } - - private Control m_oldDockTo; - protected Control OldDockTo - { - get { return m_oldDockTo; } - } - - private DockStyle m_oldDock; - protected DockStyle OldDock - { - get { return m_oldDock; } - } - - private int m_oldContentIndex; - protected int OldContentIndex - { - get { return m_oldContentIndex; } - } - - protected bool SameAsOldValue - { - get - { - return FloatWindowBounds == OldFloatWindowBounds && - DockTo == OldDockTo && - Dock == OldDock && - ContentIndex == OldContentIndex; - } - } - - private Rectangle m_floatWindowBounds; - public Rectangle FloatWindowBounds - { - get { return m_floatWindowBounds; } - } - - private Control m_dockTo; - public Control DockTo - { - get { return m_dockTo; } - } - - private DockStyle m_dock; - public DockStyle Dock - { - get { return m_dock; } - } - - private int m_contentIndex; - public int ContentIndex - { - get { return m_contentIndex; } - } - - public bool FlagFullEdge - { - get { return m_contentIndex != 0; } - } - - private bool m_flagTestDrop = false; - public bool FlagTestDrop - { - get { return m_flagTestDrop; } - set { m_flagTestDrop = value; } - } - - private void SaveOldValues() - { - m_oldDockTo = m_dockTo; - m_oldDock = m_dock; - m_oldContentIndex = m_contentIndex; - m_oldFloatWindowBounds = m_floatWindowBounds; - } - - protected abstract void OnShow(); - - protected abstract void OnClose(); - - private void SetValues(Rectangle floatWindowBounds, Control dockTo, DockStyle dock, int contentIndex) - { - m_floatWindowBounds = floatWindowBounds; - m_dockTo = dockTo; - m_dock = dock; - m_contentIndex = contentIndex; - FlagTestDrop = true; - } - - private void TestChange() - { - if (m_floatWindowBounds != m_oldFloatWindowBounds || - m_dockTo != m_oldDockTo || - m_dock != m_oldDock || - m_contentIndex != m_oldContentIndex) - OnShow(); - } - - public void Show() - { - SaveOldValues(); - SetValues(Rectangle.Empty, null, DockStyle.None, -1); - TestChange(); - } - - public void Show(DockPane pane, DockStyle dock) - { - SaveOldValues(); - SetValues(Rectangle.Empty, pane, dock, -1); - TestChange(); - } - - public void Show(DockPane pane, int contentIndex) - { - SaveOldValues(); - SetValues(Rectangle.Empty, pane, DockStyle.Fill, contentIndex); - TestChange(); - } - - public void Show(DockPanel dockPanel, DockStyle dock, bool fullPanelEdge) - { - SaveOldValues(); - SetValues(Rectangle.Empty, dockPanel, dock, fullPanelEdge ? -1 : 0); - TestChange(); - } - - public void Show(Rectangle floatWindowBounds) - { - SaveOldValues(); - SetValues(floatWindowBounds, null, DockStyle.None, -1); - TestChange(); - } - - public void Close() - { - OnClose(); - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPane.SplitterControl.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPane.SplitterControl.cs deleted file mode 100644 index dc69fb944f..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPane.SplitterControl.cs +++ /dev/null @@ -1,157 +0,0 @@ -using System; -using System.Collections; -using System.ComponentModel; -using System.Drawing; -using System.Windows.Forms; - -namespace WeifenLuo.WinFormsUI.Docking -{ - partial class DockPane - { - private class SplitterControl : Control, ISplitterDragSource - { - DockPane m_pane; - - public SplitterControl(DockPane pane) - { - SetStyle(ControlStyles.Selectable, false); - m_pane = pane; - } - - public DockPane DockPane - { - get { return m_pane; } - } - - private DockAlignment m_alignment; - public DockAlignment Alignment - { - get { return m_alignment; } - set - { - m_alignment = value; - if (m_alignment == DockAlignment.Left || m_alignment == DockAlignment.Right) - Cursor = Cursors.VSplit; - else if (m_alignment == DockAlignment.Top || m_alignment == DockAlignment.Bottom) - Cursor = Cursors.HSplit; - else - Cursor = Cursors.Default; - - if (DockPane.DockState == DockState.Document) - Invalidate(); - } - } - - protected override void OnPaint(PaintEventArgs e) - { - base.OnPaint(e); - - if (DockPane.DockState != DockState.Document) - return; - - Graphics g = e.Graphics; - Rectangle rect = ClientRectangle; - if (Alignment == DockAlignment.Top || Alignment == DockAlignment.Bottom) - g.DrawLine(SystemPens.ControlDark, rect.Left, rect.Bottom - 1, rect.Right, rect.Bottom - 1); - else if (Alignment == DockAlignment.Left || Alignment == DockAlignment.Right) - g.DrawLine(SystemPens.ControlDarkDark, rect.Right - 1, rect.Top, rect.Right - 1, rect.Bottom); - } - - protected override void OnMouseDown(MouseEventArgs e) - { - base.OnMouseDown(e); - - if (e.Button != MouseButtons.Left) - return; - - DockPane.DockPanel.BeginDrag(this, Parent.RectangleToScreen(Bounds)); - } - - #region ISplitterDragSource Members - - void ISplitterDragSource.BeginDrag(Rectangle rectSplitter) - { - } - - void ISplitterDragSource.EndDrag() - { - } - - bool ISplitterDragSource.IsVertical - { - get - { - NestedDockingStatus status = DockPane.NestedDockingStatus; - return (status.DisplayingAlignment == DockAlignment.Left || - status.DisplayingAlignment == DockAlignment.Right); - } - } - - Rectangle ISplitterDragSource.DragLimitBounds - { - get - { - NestedDockingStatus status = DockPane.NestedDockingStatus; - Rectangle rectLimit = Parent.RectangleToScreen(status.LogicalBounds); - if (((ISplitterDragSource)this).IsVertical) - { - rectLimit.X += MeasurePane.MinSize; - rectLimit.Width -= 2 * MeasurePane.MinSize; - } - else - { - rectLimit.Y += MeasurePane.MinSize; - rectLimit.Height -= 2 * MeasurePane.MinSize; - } - - return rectLimit; - } - } - - void ISplitterDragSource.MoveSplitter(int offset) - { - NestedDockingStatus status = DockPane.NestedDockingStatus; - double proportion = status.Proportion; - if (status.LogicalBounds.Width <= 0 || status.LogicalBounds.Height <= 0) - return; - else if (status.DisplayingAlignment == DockAlignment.Left) - proportion += ((double)offset) / (double)status.LogicalBounds.Width; - else if (status.DisplayingAlignment == DockAlignment.Right) - proportion -= ((double)offset) / (double)status.LogicalBounds.Width; - else if (status.DisplayingAlignment == DockAlignment.Top) - proportion += ((double)offset) / (double)status.LogicalBounds.Height; - else - proportion -= ((double)offset) / (double)status.LogicalBounds.Height; - - DockPane.SetNestedDockingProportion(proportion); - } - - #region IDragSource Members - - Control IDragSource.DragControl - { - get { return this; } - } - - #endregion - - #endregion - } - - private SplitterControl m_splitter; - private SplitterControl Splitter - { - get { return m_splitter; } - } - - internal Rectangle SplitterBounds - { - set { Splitter.Bounds = value; } - } - - internal DockAlignment SplitterAlignment - { - set { Splitter.Alignment = value; } - } - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPane.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPane.cs deleted file mode 100644 index 98685cfa77..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPane.cs +++ /dev/null @@ -1,1277 +0,0 @@ -using System; -using System.ComponentModel; -using System.Drawing; -using System.Drawing.Drawing2D; -using System.Windows.Forms; -using System.Runtime.InteropServices; -using System.Security.Permissions; -using System.Diagnostics.CodeAnalysis; - -namespace WeifenLuo.WinFormsUI.Docking -{ - [ToolboxItem(false)] - public partial class DockPane : UserControl, IDockDragSource - { - public enum AppearanceStyle - { - ToolWindow, - Document - } - - private enum HitTestArea - { - Caption, - TabStrip, - Content, - None - } - - private struct HitTestResult - { - public HitTestArea HitArea; - public int Index; - - public HitTestResult(HitTestArea hitTestArea, int index) - { - HitArea = hitTestArea; - Index = index; - } - } - - private DockPaneCaptionBase m_captionControl; - private DockPaneCaptionBase CaptionControl - { - get { return m_captionControl; } - } - - private DockPaneStripBase m_tabStripControl; - internal DockPaneStripBase TabStripControl - { - get { return m_tabStripControl; } - } - - internal protected DockPane(IDockContent content, DockState visibleState, bool show) - { - InternalConstruct(content, visibleState, false, Rectangle.Empty, null, DockAlignment.Right, 0.5, show); - } - - [SuppressMessage("Microsoft.Naming", "CA1720:AvoidTypeNamesInParameters", MessageId = "1#")] - internal protected DockPane(IDockContent content, FloatWindow floatWindow, bool show) - { - if (floatWindow == null) - throw new ArgumentNullException("floatWindow"); - - InternalConstruct(content, DockState.Float, false, Rectangle.Empty, floatWindow.NestedPanes.GetDefaultPreviousPane(this), DockAlignment.Right, 0.5, show); - } - - internal protected DockPane(IDockContent content, DockPane previousPane, DockAlignment alignment, double proportion, bool show) - { - if (previousPane == null) - throw(new ArgumentNullException("previousPane")); - InternalConstruct(content, previousPane.DockState, false, Rectangle.Empty, previousPane, alignment, proportion, show); - } - - [SuppressMessage("Microsoft.Naming", "CA1720:AvoidTypeNamesInParameters", MessageId = "1#")] - internal protected DockPane(IDockContent content, Rectangle floatWindowBounds, bool show) - { - InternalConstruct(content, DockState.Float, true, floatWindowBounds, null, DockAlignment.Right, 0.5, show); - } - - private void InternalConstruct(IDockContent content, DockState dockState, bool flagBounds, Rectangle floatWindowBounds, DockPane prevPane, DockAlignment alignment, double proportion, bool show) - { - if (dockState == DockState.Hidden || dockState == DockState.Unknown) - throw new ArgumentException(Strings.DockPane_SetDockState_InvalidState); - - if (content == null) - throw new ArgumentNullException(Strings.DockPane_Constructor_NullContent); - - if (content.DockHandler.DockPanel == null) - throw new ArgumentException(Strings.DockPane_Constructor_NullDockPanel); - - - SuspendLayout(); - SetStyle(ControlStyles.Selectable, false); - - m_isFloat = (dockState == DockState.Float); - - m_contents = new DockContentCollection(); - m_displayingContents = new DockContentCollection(this); - m_dockPanel = content.DockHandler.DockPanel; - m_dockPanel.AddPane(this); - - m_splitter = new SplitterControl(this); - - m_nestedDockingStatus = new NestedDockingStatus(this); - - m_captionControl = DockPanel.DockPaneCaptionFactory.CreateDockPaneCaption(this); - m_tabStripControl = DockPanel.DockPaneStripFactory.CreateDockPaneStrip(this); - Controls.AddRange(new Control[] { m_captionControl, m_tabStripControl }); - - DockPanel.SuspendLayout(true); - if (flagBounds) - FloatWindow = DockPanel.FloatWindowFactory.CreateFloatWindow(DockPanel, this, floatWindowBounds); - else if (prevPane != null) - DockTo(prevPane.NestedPanesContainer, prevPane, alignment, proportion); - - SetDockState(dockState); - if (show) - content.DockHandler.Pane = this; - else if (this.IsFloat) - content.DockHandler.FloatPane = this; - else - content.DockHandler.PanelPane = this; - - ResumeLayout(); - DockPanel.ResumeLayout(true, true); - } - - protected override void Dispose(bool disposing) - { - if (disposing) - { - m_dockState = DockState.Unknown; - - if (NestedPanesContainer != null) - NestedPanesContainer.NestedPanes.Remove(this); - - if (DockPanel != null) - { - DockPanel.RemovePane(this); - m_dockPanel = null; - } - - Splitter.Dispose(); - if (m_autoHidePane != null) - m_autoHidePane.Dispose(); - } - base.Dispose(disposing); - } - - private IDockContent m_activeContent = null; - public virtual IDockContent ActiveContent - { - get { return m_activeContent; } - set - { - if (ActiveContent == value) - return; - - if (value != null) - { - if (!DisplayingContents.Contains(value)) - throw(new InvalidOperationException(Strings.DockPane_ActiveContent_InvalidValue)); - } - else - { - if (DisplayingContents.Count != 0) - throw(new InvalidOperationException(Strings.DockPane_ActiveContent_InvalidValue)); - } - - IDockContent oldValue = m_activeContent; - - if (DockPanel.ActiveAutoHideContent == oldValue) - DockPanel.ActiveAutoHideContent = null; - - m_activeContent = value; - - if (DockPanel.DocumentStyle == DocumentStyle.DockingMdi && DockState == DockState.Document) - { - if (m_activeContent != null) - m_activeContent.DockHandler.Form.BringToFront(); - } - else - { - if (m_activeContent != null) - m_activeContent.DockHandler.SetVisible(); - if (oldValue != null && DisplayingContents.Contains(oldValue)) - oldValue.DockHandler.SetVisible(); - if (IsActivated && m_activeContent != null) - m_activeContent.DockHandler.Activate(); - } - - if (FloatWindow != null) - FloatWindow.SetText(); - - if (DockPanel.DocumentStyle == DocumentStyle.DockingMdi && - DockState == DockState.Document) - RefreshChanges(false); // delayed layout to reduce screen flicker - else - RefreshChanges(); - - if (m_activeContent != null) - TabStripControl.EnsureTabVisible(m_activeContent); - } - } - - private bool m_allowDockDragAndDrop = true; - public virtual bool AllowDockDragAndDrop - { - get { return m_allowDockDragAndDrop; } - set { m_allowDockDragAndDrop = value; } - } - - private IDisposable m_autoHidePane = null; - internal IDisposable AutoHidePane - { - get { return m_autoHidePane; } - set { m_autoHidePane = value; } - } - - private object m_autoHideTabs = null; - internal object AutoHideTabs - { - get { return m_autoHideTabs; } - set { m_autoHideTabs = value; } - } - - private object TabPageContextMenu - { - get - { - IDockContent content = ActiveContent; - - if (content == null) - return null; - - if (content.DockHandler.TabPageContextMenuStrip != null) - return content.DockHandler.TabPageContextMenuStrip; - else if (content.DockHandler.TabPageContextMenu != null) - return content.DockHandler.TabPageContextMenu; - else - return null; - } - } - - internal bool HasTabPageContextMenu - { - get { return TabPageContextMenu != null; } - } - - internal void ShowTabPageContextMenu(Control control, Point position) - { - object menu = TabPageContextMenu; - - if (menu == null) - return; - - ContextMenuStrip contextMenuStrip = menu as ContextMenuStrip; - if (contextMenuStrip != null) - { - contextMenuStrip.Show(control, position); - return; - } - - ContextMenu contextMenu = menu as ContextMenu; - if (contextMenu != null) - contextMenu.Show(this, position); - } - - private Rectangle CaptionRectangle - { - get - { - if (!HasCaption) - return Rectangle.Empty; - - Rectangle rectWindow = DisplayingRectangle; - int x, y, width; - x = rectWindow.X; - y = rectWindow.Y; - width = rectWindow.Width; - int height = CaptionControl.MeasureHeight(); - - return new Rectangle(x, y, width, height); - } - } - - internal Rectangle ContentRectangle - { - get - { - Rectangle rectWindow = DisplayingRectangle; - Rectangle rectCaption = CaptionRectangle; - Rectangle rectTabStrip = TabStripRectangle; - - int x = rectWindow.X; - int y = rectWindow.Y + (rectCaption.IsEmpty ? 0 : rectCaption.Height) + - (DockState == DockState.Document ? rectTabStrip.Height : 0); - int width = rectWindow.Width; - int height = rectWindow.Height - rectCaption.Height - rectTabStrip.Height; - - return new Rectangle(x, y, width, height); - } - } - - internal Rectangle TabStripRectangle - { - get - { - if (Appearance == AppearanceStyle.ToolWindow) - return TabStripRectangle_ToolWindow; - else - return TabStripRectangle_Document; - } - } - - private Rectangle TabStripRectangle_ToolWindow - { - get - { - if (DisplayingContents.Count <= 1 || IsAutoHide) - return Rectangle.Empty; - - Rectangle rectWindow = DisplayingRectangle; - - int width = rectWindow.Width; - int height = TabStripControl.MeasureHeight(); - int x = rectWindow.X; - int y = rectWindow.Bottom - height; - Rectangle rectCaption = CaptionRectangle; - if (rectCaption.Contains(x, y)) - y = rectCaption.Y + rectCaption.Height; - - return new Rectangle(x, y, width, height); - } - } - - private Rectangle TabStripRectangle_Document - { - get - { - if (DisplayingContents.Count == 0) - return Rectangle.Empty; - - if (DisplayingContents.Count == 1 && DockPanel.DocumentStyle == DocumentStyle.DockingSdi) - return Rectangle.Empty; - - Rectangle rectWindow = DisplayingRectangle; - int x = rectWindow.X; - int y = rectWindow.Y; - int width = rectWindow.Width; - int height = TabStripControl.MeasureHeight(); - - return new Rectangle(x, y, width, height); - } - } - - public virtual string CaptionText - { - get { return ActiveContent == null ? string.Empty : ActiveContent.DockHandler.TabText; } - } - - private DockContentCollection m_contents; - public DockContentCollection Contents - { - get { return m_contents; } - } - - private DockContentCollection m_displayingContents; - public DockContentCollection DisplayingContents - { - get { return m_displayingContents; } - } - - private DockPanel m_dockPanel; - public DockPanel DockPanel - { - get { return m_dockPanel; } - } - - private bool HasCaption - { - get - { - if (DockState == DockState.Document || - DockState == DockState.Hidden || - DockState == DockState.Unknown || - (DockState == DockState.Float && FloatWindow.VisibleNestedPanes.Count <= 1)) - return false; - else - return true; - } - } - - private bool m_isActivated = false; - public bool IsActivated - { - get { return m_isActivated; } - } - internal void SetIsActivated(bool value) - { - if (m_isActivated == value) - return; - - m_isActivated = value; - if (DockState != DockState.Document) - RefreshChanges(false); - OnIsActivatedChanged(EventArgs.Empty); - } - - private bool m_isActiveDocumentPane = false; - public bool IsActiveDocumentPane - { - get { return m_isActiveDocumentPane; } - } - internal void SetIsActiveDocumentPane(bool value) - { - if (m_isActiveDocumentPane == value) - return; - - m_isActiveDocumentPane = value; - if (DockState == DockState.Document) - RefreshChanges(); - OnIsActiveDocumentPaneChanged(EventArgs.Empty); - } - - public bool IsDockStateValid(DockState dockState) - { - foreach (IDockContent content in Contents) - if (!content.DockHandler.IsDockStateValid(dockState)) - return false; - - return true; - } - - public bool IsAutoHide - { - get { return DockHelper.IsDockStateAutoHide(DockState); } - } - - public AppearanceStyle Appearance - { - get { return (DockState == DockState.Document) ? AppearanceStyle.Document : AppearanceStyle.ToolWindow; } - } - - internal Rectangle DisplayingRectangle - { - get { return ClientRectangle; } - } - - public void Activate() - { - if (DockHelper.IsDockStateAutoHide(DockState) && DockPanel.ActiveAutoHideContent != ActiveContent) - DockPanel.ActiveAutoHideContent = ActiveContent; - else if (!IsActivated && ActiveContent != null) - ActiveContent.DockHandler.Activate(); - } - - internal void AddContent(IDockContent content) - { - if (Contents.Contains(content)) - return; - - Contents.Add(content); - } - - internal void Close() - { - Dispose(); - } - - public void CloseActiveContent() - { - CloseContent(ActiveContent); - } - - internal void CloseContent(IDockContent content) - { - DockPanel dockPanel = DockPanel; - dockPanel.SuspendLayout(true); - - if (content == null) - return; - - if (!content.DockHandler.CloseButton) - return; - - if (content.DockHandler.HideOnClose) - content.DockHandler.Hide(); - else - content.DockHandler.Close(); - - dockPanel.ResumeLayout(true, true); - } - - private HitTestResult GetHitTest(Point ptMouse) - { - Point ptMouseClient = PointToClient(ptMouse); - - Rectangle rectCaption = CaptionRectangle; - if (rectCaption.Contains(ptMouseClient)) - return new HitTestResult(HitTestArea.Caption, -1); - - Rectangle rectContent = ContentRectangle; - if (rectContent.Contains(ptMouseClient)) - return new HitTestResult(HitTestArea.Content, -1); - - Rectangle rectTabStrip = TabStripRectangle; - if (rectTabStrip.Contains(ptMouseClient)) - return new HitTestResult(HitTestArea.TabStrip, TabStripControl.HitTest(TabStripControl.PointToClient(ptMouse))); - - return new HitTestResult(HitTestArea.None, -1); - } - - private bool m_isHidden = true; - public bool IsHidden - { - get { return m_isHidden; } - } - private void SetIsHidden(bool value) - { - if (m_isHidden == value) - return; - - m_isHidden = value; - if (DockHelper.IsDockStateAutoHide(DockState)) - { - DockPanel.RefreshAutoHideStrip(); - DockPanel.PerformLayout(); - } - else if (NestedPanesContainer != null) - ((Control)NestedPanesContainer).PerformLayout(); - } - - protected override void OnLayout(LayoutEventArgs levent) - { - SetIsHidden(DisplayingContents.Count == 0); - if (!IsHidden) - { - CaptionControl.Bounds = CaptionRectangle; - TabStripControl.Bounds = TabStripRectangle; - - SetContentBounds(); - - foreach (IDockContent content in Contents) - { - if (DisplayingContents.Contains(content)) - if (content.DockHandler.FlagClipWindow && content.DockHandler.Form.Visible) - content.DockHandler.FlagClipWindow = false; - } - } - - base.OnLayout(levent); - } - - internal void SetContentBounds() - { - Rectangle rectContent = ContentRectangle; - if (DockState == DockState.Document && DockPanel.DocumentStyle == DocumentStyle.DockingMdi) - rectContent = DockPanel.RectangleToMdiClient(RectangleToScreen(rectContent)); - - Rectangle rectInactive = new Rectangle(-rectContent.Width, rectContent.Y, rectContent.Width, rectContent.Height); - foreach (IDockContent content in Contents) - if (content.DockHandler.Pane == this) - { - if (content == ActiveContent) - content.DockHandler.Form.Bounds = rectContent; - else - content.DockHandler.Form.Bounds = rectInactive; - } - } - - internal void RefreshChanges() - { - RefreshChanges(true); - } - - private void RefreshChanges(bool performLayout) - { - if (IsDisposed) - return; - - CaptionControl.RefreshChanges(); - TabStripControl.RefreshChanges(); - if (DockState == DockState.Float) - FloatWindow.RefreshChanges(); - if (DockHelper.IsDockStateAutoHide(DockState) && DockPanel != null) - { - DockPanel.RefreshAutoHideStrip(); - DockPanel.PerformLayout(); - } - - if (performLayout) - PerformLayout(); - } - - internal void RemoveContent(IDockContent content) - { - if (!Contents.Contains(content)) - return; - - Contents.Remove(content); - } - - public void SetContentIndex(IDockContent content, int index) - { - int oldIndex = Contents.IndexOf(content); - if (oldIndex == -1) - throw(new ArgumentException(Strings.DockPane_SetContentIndex_InvalidContent)); - - if (index < 0 || index > Contents.Count - 1) - if (index != -1) - throw(new ArgumentOutOfRangeException(Strings.DockPane_SetContentIndex_InvalidIndex)); - - if (oldIndex == index) - return; - if (oldIndex == Contents.Count - 1 && index == -1) - return; - - Contents.Remove(content); - if (index == -1) - Contents.Add(content); - else if (oldIndex < index) - Contents.AddAt(content, index - 1); - else - Contents.AddAt(content, index); - - RefreshChanges(); - } - - private void SetParent() - { - if (DockState == DockState.Unknown || DockState == DockState.Hidden) - { - SetParent(null); - Splitter.Parent = null; - } - else if (DockState == DockState.Float) - { - SetParent(FloatWindow); - Splitter.Parent = FloatWindow; - } - else if (DockHelper.IsDockStateAutoHide(DockState)) - { - SetParent(DockPanel.AutoHideControl); - Splitter.Parent = null; - } - else - { - SetParent(DockPanel.DockWindows[DockState]); - Splitter.Parent = Parent; - } - } - - private void SetParent(Control value) - { - if (Parent == value) - return; - - //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! - // Workaround of .Net Framework bug: - // Change the parent of a control with focus may result in the first - // MDI child form get activated. - //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! - IDockContent contentFocused = GetFocusedContent(); - if (contentFocused != null) - DockPanel.SaveFocus(); - - //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! - - Parent = value; - - //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! - // Workaround of .Net Framework bug: - // Change the parent of a control with focus may result in the first - // MDI child form get activated. - //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! - if (contentFocused != null) - contentFocused.DockHandler.Activate(); - //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! - } - - public new void Show() - { - Activate(); - } - - internal void TestDrop(IDockDragSource dragSource, DockOutlineBase dockOutline) - { - if (!dragSource.CanDockTo(this)) - return; - - Point ptMouse = Control.MousePosition; - - HitTestResult hitTestResult = GetHitTest(ptMouse); - if (hitTestResult.HitArea == HitTestArea.Caption) - dockOutline.Show(this, -1); - else if (hitTestResult.HitArea == HitTestArea.TabStrip && hitTestResult.Index != -1) - dockOutline.Show(this, hitTestResult.Index); - } - - internal void ValidateActiveContent() - { - if (ActiveContent == null) - { - if (DisplayingContents.Count != 0) - ActiveContent = DisplayingContents[0]; - return; - } - - if (DisplayingContents.IndexOf(ActiveContent) >= 0) - return; - - IDockContent prevVisible = null; - for (int i=Contents.IndexOf(ActiveContent)-1; i>=0; i--) - if (Contents[i].DockHandler.DockState == DockState) - { - prevVisible = Contents[i]; - break; - } - - IDockContent nextVisible = null; - for (int i=Contents.IndexOf(ActiveContent)+1; i= 0); - DockPanel.ResumeLayout(true, true); - } - - private bool IsRefreshStateChangeSuspended - { - get { return m_countRefreshStateChange != 0; } - } - - private void ResumeRefreshStateChange(INestedPanesContainer oldContainer, DockState oldDockState) - { - ResumeRefreshStateChange(); - RefreshStateChange(oldContainer, oldDockState); - } - - private void RefreshStateChange(INestedPanesContainer oldContainer, DockState oldDockState) - { - lock (this) - { - if (IsRefreshStateChangeSuspended) - return; - - SuspendRefreshStateChange(); - } - - DockPanel.SuspendLayout(true); - - IDockContent contentFocused = GetFocusedContent(); - if (contentFocused != null) - DockPanel.SaveFocus(); - SetParent(); - - if (ActiveContent != null) - ActiveContent.DockHandler.SetDockState(ActiveContent.DockHandler.IsHidden, DockState, ActiveContent.DockHandler.Pane); - foreach (IDockContent content in Contents) - { - if (content.DockHandler.Pane == this) - content.DockHandler.SetDockState(content.DockHandler.IsHidden, DockState, content.DockHandler.Pane); - } - - if (oldContainer != null) - { - Control oldContainerControl = (Control)oldContainer; - if (oldContainer.DockState == oldDockState && !oldContainerControl.IsDisposed) - oldContainerControl.PerformLayout(); - } - if (DockHelper.IsDockStateAutoHide(oldDockState)) - DockPanel.RefreshActiveAutoHideContent(); - - if (NestedPanesContainer.DockState == DockState) - ((Control)NestedPanesContainer).PerformLayout(); - if (DockHelper.IsDockStateAutoHide(DockState)) - DockPanel.RefreshActiveAutoHideContent(); - - if (DockHelper.IsDockStateAutoHide(oldDockState) || - DockHelper.IsDockStateAutoHide(DockState)) - { - DockPanel.RefreshAutoHideStrip(); - DockPanel.PerformLayout(); - } - - ResumeRefreshStateChange(); - - if (contentFocused != null) - contentFocused.DockHandler.Activate(); - - DockPanel.ResumeLayout(true, true); - - if (oldDockState != DockState) - OnDockStateChanged(EventArgs.Empty); - } - - private IDockContent GetFocusedContent() - { - IDockContent contentFocused = null; - foreach (IDockContent content in Contents) - { - if (content.DockHandler.Form.ContainsFocus) - { - contentFocused = content; - break; - } - } - - return contentFocused; - } - - public DockPane DockTo(INestedPanesContainer container) - { - if (container == null) - throw new InvalidOperationException(Strings.DockPane_DockTo_NullContainer); - - DockAlignment alignment; - if (container.DockState == DockState.DockLeft || container.DockState == DockState.DockRight) - alignment = DockAlignment.Bottom; - else - alignment = DockAlignment.Right; - - return DockTo(container, container.NestedPanes.GetDefaultPreviousPane(this), alignment, 0.5); - } - - public DockPane DockTo(INestedPanesContainer container, DockPane previousPane, DockAlignment alignment, double proportion) - { - if (container == null) - throw new InvalidOperationException(Strings.DockPane_DockTo_NullContainer); - - if (container.IsFloat == this.IsFloat) - { - InternalAddToDockList(container, previousPane, alignment, proportion); - return this; - } - - IDockContent firstContent = GetFirstContent(container.DockState); - if (firstContent == null) - return null; - - DockPane pane; - DockPanel.DummyContent.DockPanel = DockPanel; - if (container.IsFloat) - pane = DockPanel.DockPaneFactory.CreateDockPane(DockPanel.DummyContent, (FloatWindow)container, true); - else - pane = DockPanel.DockPaneFactory.CreateDockPane(DockPanel.DummyContent, container.DockState, true); - - pane.DockTo(container, previousPane, alignment, proportion); - SetVisibleContentsToPane(pane); - DockPanel.DummyContent.DockPanel = null; - - return pane; - } - - private void SetVisibleContentsToPane(DockPane pane) - { - SetVisibleContentsToPane(pane, ActiveContent); - } - - private void SetVisibleContentsToPane(DockPane pane, IDockContent activeContent) - { - for (int i=0; i 0) - throw new InvalidOperationException(Strings.DockPane_DockTo_NullPrevPane); - - if (prevPane != null && !container.NestedPanes.Contains(prevPane)) - throw new InvalidOperationException(Strings.DockPane_DockTo_NoPrevPane); - - if (prevPane == this) - throw new InvalidOperationException(Strings.DockPane_DockTo_SelfPrevPane); - - INestedPanesContainer oldContainer = NestedPanesContainer; - DockState oldDockState = DockState; - container.NestedPanes.Add(this); - NestedDockingStatus.SetStatus(container.NestedPanes, prevPane, alignment, proportion); - - if (DockHelper.IsDockWindowState(DockState)) - m_dockState = container.DockState; - - RefreshStateChange(oldContainer, oldDockState); - } - - public void SetNestedDockingProportion(double proportion) - { - NestedDockingStatus.SetStatus(NestedDockingStatus.NestedPanes, NestedDockingStatus.PreviousPane, NestedDockingStatus.Alignment, proportion); - if (NestedPanesContainer != null) - ((Control)NestedPanesContainer).PerformLayout(); - } - - public DockPane Float() - { - DockPanel.SuspendLayout(true); - - IDockContent activeContent = ActiveContent; - - DockPane floatPane = GetFloatPaneFromContents(); - if (floatPane == null) - { - IDockContent firstContent = GetFirstContent(DockState.Float); - if (firstContent == null) - { - DockPanel.ResumeLayout(true, true); - return null; - } - floatPane = DockPanel.DockPaneFactory.CreateDockPane(firstContent,DockState.Float, true); - } - SetVisibleContentsToPane(floatPane, activeContent); - - DockPanel.ResumeLayout(true, true); - return floatPane; - } - - private DockPane GetFloatPaneFromContents() - { - DockPane floatPane = null; - for (int i=0; i=0; i--) - { - IDockContent content = DisplayingContents[i]; - if (content.DockHandler.CheckDockState(false) != DockState.Unknown) - content.DockHandler.IsFloat = false; - } - - DockPanel.ResumeLayout(true, true); - } - - [SecurityPermission(SecurityAction.LinkDemand, Flags = SecurityPermissionFlag.UnmanagedCode)] - protected override void WndProc(ref Message m) - { - if (m.Msg == (int)Win32.Msgs.WM_MOUSEACTIVATE) - Activate(); - - base.WndProc(ref m); - } - - #region IDockDragSource Members - - #region IDragSource Members - - Control IDragSource.DragControl - { - get { return this; } - } - - #endregion - - bool IDockDragSource.IsDockStateValid(DockState dockState) - { - return IsDockStateValid(dockState); - } - - bool IDockDragSource.CanDockTo(DockPane pane) - { - if (!IsDockStateValid(pane.DockState)) - return false; - - if (pane == this) - return false; - - return true; - } - - Rectangle IDockDragSource.BeginDrag(Point ptMouse) - { - Point location = PointToScreen(new Point(0, 0)); - Size size; - - DockPane floatPane = ActiveContent.DockHandler.FloatPane; - if (DockState == DockState.Float || floatPane == null || floatPane.FloatWindow.NestedPanes.Count != 1) - size = DockPanel.DefaultFloatWindowSize; - else - size = floatPane.FloatWindow.Size; - - if (ptMouse.X > location.X + size.Width) - location.X += ptMouse.X - (location.X + size.Width) + Measures.SplitterSize; - - return new Rectangle(location, size); - } - - public void FloatAt(Rectangle floatWindowBounds) - { - if (FloatWindow == null || FloatWindow.NestedPanes.Count != 1) - FloatWindow = DockPanel.FloatWindowFactory.CreateFloatWindow(DockPanel, this, floatWindowBounds); - else - FloatWindow.Bounds = floatWindowBounds; - - DockState = DockState.Float; - } - - public void DockTo(DockPane pane, DockStyle dockStyle, int contentIndex) - { - if (dockStyle == DockStyle.Fill) - { - IDockContent activeContent = ActiveContent; - for (int i = Contents.Count - 1; i >= 0; i--) - { - IDockContent c = Contents[i]; - c.DockHandler.Pane = pane; - if (contentIndex != -1) - pane.SetContentIndex(c, contentIndex); - } - pane.ActiveContent = activeContent; - } - else - { - if (dockStyle == DockStyle.Left) - DockTo(pane.NestedPanesContainer, pane, DockAlignment.Left, 0.5); - else if (dockStyle == DockStyle.Right) - DockTo(pane.NestedPanesContainer, pane, DockAlignment.Right, 0.5); - else if (dockStyle == DockStyle.Top) - DockTo(pane.NestedPanesContainer, pane, DockAlignment.Top, 0.5); - else if (dockStyle == DockStyle.Bottom) - DockTo(pane.NestedPanesContainer, pane, DockAlignment.Bottom, 0.5); - - DockState = pane.DockState; - } - } - - public void DockTo(DockPanel panel, DockStyle dockStyle) - { - if (panel != DockPanel) - throw new ArgumentException(Strings.IDockDragSource_DockTo_InvalidPanel, "panel"); - - if (dockStyle == DockStyle.Top) - DockState = DockState.DockTop; - else if (dockStyle == DockStyle.Bottom) - DockState = DockState.DockBottom; - else if (dockStyle == DockStyle.Left) - DockState = DockState.DockLeft; - else if (dockStyle == DockStyle.Right) - DockState = DockState.DockRight; - else if (dockStyle == DockStyle.Fill) - DockState = DockState.Document; - } - - #endregion - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPaneCaptionBase.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPaneCaptionBase.cs deleted file mode 100644 index 3daf9f7039..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPaneCaptionBase.cs +++ /dev/null @@ -1,100 +0,0 @@ -using System; -using System.Windows.Forms; -using System.Drawing; -using System.Runtime.InteropServices; -using System.Security.Permissions; - -namespace WeifenLuo.WinFormsUI.Docking -{ - public abstract class DockPaneCaptionBase : Control - { - protected internal DockPaneCaptionBase(DockPane pane) - { - m_dockPane = pane; - - SetStyle(ControlStyles.OptimizedDoubleBuffer | - ControlStyles.ResizeRedraw | - ControlStyles.UserPaint | - ControlStyles.AllPaintingInWmPaint, true); - SetStyle(ControlStyles.Selectable, false); - } - - private DockPane m_dockPane; - protected DockPane DockPane - { - get { return m_dockPane; } - } - - protected DockPane.AppearanceStyle Appearance - { - get { return DockPane.Appearance; } - } - - protected bool HasTabPageContextMenu - { - get { return DockPane.HasTabPageContextMenu; } - } - - protected void ShowTabPageContextMenu(Point position) - { - DockPane.ShowTabPageContextMenu(this, position); - } - - protected override void OnMouseUp(MouseEventArgs e) - { - base.OnMouseUp(e); - - if (e.Button == MouseButtons.Right) - ShowTabPageContextMenu(new Point(e.X, e.Y)); - } - - protected override void OnMouseDown(MouseEventArgs e) - { - base.OnMouseDown(e); - - if (e.Button == MouseButtons.Left && - DockPane.DockPanel.AllowEndUserDocking && - DockPane.AllowDockDragAndDrop && - !DockHelper.IsDockStateAutoHide(DockPane.DockState) && - DockPane.ActiveContent != null) - DockPane.DockPanel.BeginDrag(DockPane); - } - - [SecurityPermission(SecurityAction.LinkDemand, Flags = SecurityPermissionFlag.UnmanagedCode)] - protected override void WndProc(ref Message m) - { - if (m.Msg == (int)Win32.Msgs.WM_LBUTTONDBLCLK) - { - if (DockHelper.IsDockStateAutoHide(DockPane.DockState)) - { - DockPane.DockPanel.ActiveAutoHideContent = null; - return; - } - - if (DockPane.IsFloat) - DockPane.RestoreToPanel(); - else - DockPane.Float(); - } - base.WndProc(ref m); - } - - internal void RefreshChanges() - { - if (IsDisposed) - return; - - OnRefreshChanges(); - } - - protected virtual void OnRightToLeftLayoutChanged() - { - } - - protected virtual void OnRefreshChanges() - { - } - - protected internal abstract int MeasureHeight(); - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPaneCollection.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPaneCollection.cs deleted file mode 100644 index 43f0e90b29..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPaneCollection.cs +++ /dev/null @@ -1,47 +0,0 @@ -using System; -using System.Collections.ObjectModel; -using System.Collections.Generic; -using System.Drawing; -using System.Windows.Forms; - -namespace WeifenLuo.WinFormsUI.Docking -{ - public class DockPaneCollection : ReadOnlyCollection - { - internal DockPaneCollection() - : base(new List()) - { - } - - internal int Add(DockPane pane) - { - if (Items.Contains(pane)) - return Items.IndexOf(pane); - - Items.Add(pane); - return Count - 1; - } - - internal void AddAt(DockPane pane, int index) - { - if (index < 0 || index > Items.Count - 1) - return; - - if (Contains(pane)) - return; - - Items.Insert(index, pane); - } - - internal void Dispose() - { - for (int i=Count - 1; i>=0; i--) - this[i].Close(); - } - - internal void Remove(DockPane pane) - { - Items.Remove(pane); - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPaneStripBase.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPaneStripBase.cs deleted file mode 100644 index 1f4b8ddd4e..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPaneStripBase.cs +++ /dev/null @@ -1,248 +0,0 @@ -using System; -using System.Windows.Forms; -using System.Drawing; -using System.Drawing.Drawing2D; -using System.Collections; -using System.Collections.Generic; -using System.Security.Permissions; -using System.Diagnostics.CodeAnalysis; - -namespace WeifenLuo.WinFormsUI.Docking -{ - public abstract class DockPaneStripBase : Control - { - [SuppressMessage("Microsoft.Design", "CA1034:NestedTypesShouldNotBeVisible")] - protected internal class Tab : IDisposable - { - private IDockContent m_content; - - public Tab(IDockContent content) - { - m_content = content; - } - - public IDockContent Content - { - get { return m_content; } - } - - public Form ContentForm - { - get { return m_content as Form; } - } - - public virtual void Dispose() - { - } - } - - [SuppressMessage("Microsoft.Design", "CA1034:NestedTypesShouldNotBeVisible")] - protected sealed class TabCollection : IEnumerable - { - #region IEnumerable Members - IEnumerator IEnumerable.GetEnumerator() - { - for (int i = 0; i < Count; i++) - yield return this[i]; - } - - IEnumerator IEnumerable.GetEnumerator() - { - for (int i = 0; i < Count; i++) - yield return this[i]; - } - #endregion - - internal TabCollection(DockPane pane) - { - m_dockPane = pane; - } - - private DockPane m_dockPane; - public DockPane DockPane - { - get { return m_dockPane; } - } - - public int Count - { - get { return DockPane.DisplayingContents.Count; } - } - - public Tab this[int index] - { - get - { - IDockContent content = DockPane.DisplayingContents[index]; - if (content == null) - throw (new ArgumentOutOfRangeException("index")); - return content.DockHandler.GetTab(DockPane.TabStripControl); - } - } - - public bool Contains(Tab tab) - { - return (IndexOf(tab) != -1); - } - - public bool Contains(IDockContent content) - { - return (IndexOf(content) != -1); - } - - public int IndexOf(Tab tab) - { - if (tab == null) - return -1; - - return DockPane.DisplayingContents.IndexOf(tab.Content); - } - - public int IndexOf(IDockContent content) - { - return DockPane.DisplayingContents.IndexOf(content); - } - } - - protected DockPaneStripBase(DockPane pane) - { - m_dockPane = pane; - - SetStyle(ControlStyles.OptimizedDoubleBuffer, true); - SetStyle(ControlStyles.Selectable, false); - AllowDrop = true; - } - - private DockPane m_dockPane; - protected DockPane DockPane - { - get { return m_dockPane; } - } - - protected DockPane.AppearanceStyle Appearance - { - get { return DockPane.Appearance; } - } - - private TabCollection m_tabs = null; - protected TabCollection Tabs - { - get - { - if (m_tabs == null) - m_tabs = new TabCollection(DockPane); - - return m_tabs; - } - } - - internal void RefreshChanges() - { - if (IsDisposed) - return; - - OnRefreshChanges(); - } - - protected virtual void OnRefreshChanges() - { - } - - protected internal abstract int MeasureHeight(); - - protected internal abstract void EnsureTabVisible(IDockContent content); - - protected int HitTest() - { - return HitTest(PointToClient(Control.MousePosition)); - } - - protected internal abstract int HitTest(Point point); - - protected internal abstract GraphicsPath GetOutline(int index); - - protected internal virtual Tab CreateTab(IDockContent content) - { - return new Tab(content); - } - - protected override void OnMouseDown(MouseEventArgs e) - { - base.OnMouseDown(e); - - int index = HitTest(); - if (index != -1) - { - IDockContent content = Tabs[index].Content; - if (DockPane.ActiveContent != content) - DockPane.ActiveContent = content; - } - - if (e.Button == MouseButtons.Left) - { - if (DockPane.DockPanel.AllowEndUserDocking && DockPane.AllowDockDragAndDrop && DockPane.ActiveContent.DockHandler.AllowEndUserDocking) - DockPane.DockPanel.BeginDrag(DockPane.ActiveContent.DockHandler); - } - } - - protected bool HasTabPageContextMenu - { - get { return DockPane.HasTabPageContextMenu; } - } - - protected void ShowTabPageContextMenu(Point position) - { - DockPane.ShowTabPageContextMenu(this, position); - } - - protected override void OnMouseUp(MouseEventArgs e) - { - base.OnMouseUp(e); - - if (e.Button == MouseButtons.Right) - ShowTabPageContextMenu(new Point(e.X, e.Y)); - } - - [SecurityPermission(SecurityAction.LinkDemand, Flags = SecurityPermissionFlag.UnmanagedCode)] - protected override void WndProc(ref Message m) - { - if (m.Msg == (int)Win32.Msgs.WM_LBUTTONDBLCLK) - { - base.WndProc(ref m); - - int index = HitTest(); - if (DockPane.DockPanel.AllowEndUserDocking && index != -1) - { - IDockContent content = Tabs[index].Content; - if (content.DockHandler.CheckDockState(!content.DockHandler.IsFloat) != DockState.Unknown) - content.DockHandler.IsFloat = !content.DockHandler.IsFloat; - } - - return; - } else if (m.Msg == (int)Win32.Msgs.WM_MBUTTONUP) { - base.WndProc(ref m); - int index = HitTest(); - if (index != -1) { - DockPane.CloseContent(Tabs[index].Content); - } - return; - } - - base.WndProc(ref m); - return; - } - - protected override void OnDragOver(DragEventArgs drgevent) - { - base.OnDragOver(drgevent); - - int index = HitTest(); - if (index != -1) - { - IDockContent content = Tabs[index].Content; - if (DockPane.ActiveContent != content) - DockPane.ActiveContent = content; - } - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.AutoHideWindow.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.AutoHideWindow.cs deleted file mode 100644 index 99866addef..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.AutoHideWindow.cs +++ /dev/null @@ -1,612 +0,0 @@ -using System; -using System.Windows.Forms; -using System.Drawing; -using System.Runtime.InteropServices; - -namespace WeifenLuo.WinFormsUI.Docking -{ - partial class DockPanel - { - private class AutoHideWindowControl : Panel, ISplitterDragSource - { - private class SplitterControl : SplitterBase - { - public SplitterControl(AutoHideWindowControl autoHideWindow) - { - m_autoHideWindow = autoHideWindow; - } - - private AutoHideWindowControl m_autoHideWindow; - private AutoHideWindowControl AutoHideWindow - { - get { return m_autoHideWindow; } - } - - protected override int SplitterSize - { - get { return Measures.SplitterSize; } - } - - protected override void StartDrag() - { - AutoHideWindow.DockPanel.BeginDrag(AutoHideWindow, AutoHideWindow.RectangleToScreen(Bounds)); - } - } - - #region consts - private const int ANIMATE_TIME = 100; // in mini-seconds - #endregion - - private Timer m_timerMouseTrack; - private SplitterControl m_splitter; - - public AutoHideWindowControl(DockPanel dockPanel) - { - m_dockPanel = dockPanel; - - m_timerMouseTrack = new Timer(); - m_timerMouseTrack.Tick += new EventHandler(TimerMouseTrack_Tick); - - Visible = false; - m_splitter = new SplitterControl(this); - Controls.Add(m_splitter); - } - - protected override void Dispose(bool disposing) - { - if (disposing) - { - m_timerMouseTrack.Dispose(); - } - base.Dispose(disposing); - } - - private DockPanel m_dockPanel = null; - public DockPanel DockPanel - { - get { return m_dockPanel; } - } - - private DockPane m_activePane = null; - public DockPane ActivePane - { - get { return m_activePane; } - } - private void SetActivePane() - { - DockPane value = (ActiveContent == null ? null : ActiveContent.DockHandler.Pane); - - if (value == m_activePane) - return; - - m_activePane = value; - } - - private IDockContent m_activeContent = null; - public IDockContent ActiveContent - { - get { return m_activeContent; } - set - { - if (value == m_activeContent) - return; - - if (value != null) - { - if (!DockHelper.IsDockStateAutoHide(value.DockHandler.DockState) || value.DockHandler.DockPanel != DockPanel) - throw (new InvalidOperationException(Strings.DockPanel_ActiveAutoHideContent_InvalidValue)); - } - - DockPanel.SuspendLayout(); - - if (m_activeContent != null) - { - if (m_activeContent.DockHandler.Form.ContainsFocus) - DockPanel.ContentFocusManager.GiveUpFocus(m_activeContent); - AnimateWindow(false); - } - - m_activeContent = value; - SetActivePane(); - if (ActivePane != null) - ActivePane.ActiveContent = m_activeContent; - - if (m_activeContent != null) - AnimateWindow(true); - - DockPanel.ResumeLayout(); - DockPanel.RefreshAutoHideStrip(); - - SetTimerMouseTrack(); - } - } - - public DockState DockState - { - get { return ActiveContent == null ? DockState.Unknown : ActiveContent.DockHandler.DockState; } - } - - private bool m_flagAnimate = true; - private bool FlagAnimate - { - get { return m_flagAnimate; } - set { m_flagAnimate = value; } - } - - private bool m_flagDragging = false; - internal bool FlagDragging - { - get { return m_flagDragging; } - set - { - if (m_flagDragging == value) - return; - - m_flagDragging = value; - SetTimerMouseTrack(); - } - } - - private void AnimateWindow(bool show) - { - if (!FlagAnimate && Visible != show) - { - Visible = show; - return; - } - - Parent.SuspendLayout(); - - Rectangle rectSource = GetRectangle(!show); - Rectangle rectTarget = GetRectangle(show); - int dxLoc, dyLoc; - int dWidth, dHeight; - dxLoc = dyLoc = dWidth = dHeight = 0; - if (DockState == DockState.DockTopAutoHide) - dHeight = show ? 1 : -1; - else if (DockState == DockState.DockLeftAutoHide) - dWidth = show ? 1 : -1; - else if (DockState == DockState.DockRightAutoHide) - { - dxLoc = show ? -1 : 1; - dWidth = show ? 1 : -1; - } - else if (DockState == DockState.DockBottomAutoHide) - { - dyLoc = (show ? -1 : 1); - dHeight = (show ? 1 : -1); - } - - if (show) - { - Bounds = DockPanel.GetAutoHideWindowBounds(new Rectangle(-rectTarget.Width, -rectTarget.Height, rectTarget.Width, rectTarget.Height)); - if (Visible == false) - Visible = true; - PerformLayout(); - } - - SuspendLayout(); - - LayoutAnimateWindow(rectSource); - if (Visible == false) - Visible = true; - - int speedFactor = 1; - int totalPixels = (rectSource.Width != rectTarget.Width) ? - Math.Abs(rectSource.Width - rectTarget.Width) : - Math.Abs(rectSource.Height - rectTarget.Height); - int remainPixels = totalPixels; - DateTime startingTime = DateTime.Now; - while (rectSource != rectTarget) - { - DateTime startPerMove = DateTime.Now; - - rectSource.X += dxLoc * speedFactor; - rectSource.Y += dyLoc * speedFactor; - rectSource.Width += dWidth * speedFactor; - rectSource.Height += dHeight * speedFactor; - if (Math.Sign(rectTarget.X - rectSource.X) != Math.Sign(dxLoc)) - rectSource.X = rectTarget.X; - if (Math.Sign(rectTarget.Y - rectSource.Y) != Math.Sign(dyLoc)) - rectSource.Y = rectTarget.Y; - if (Math.Sign(rectTarget.Width - rectSource.Width) != Math.Sign(dWidth)) - rectSource.Width = rectTarget.Width; - if (Math.Sign(rectTarget.Height - rectSource.Height) != Math.Sign(dHeight)) - rectSource.Height = rectTarget.Height; - - LayoutAnimateWindow(rectSource); - if (Parent != null) - Parent.Update(); - - remainPixels -= speedFactor; - - while (true) - { - TimeSpan time = new TimeSpan(0, 0, 0, 0, ANIMATE_TIME); - TimeSpan elapsedPerMove = DateTime.Now - startPerMove; - TimeSpan elapsedTime = DateTime.Now - startingTime; - if (((int)((time - elapsedTime).TotalMilliseconds)) <= 0) - { - speedFactor = remainPixels; - break; - } - else - speedFactor = remainPixels * (int)elapsedPerMove.TotalMilliseconds / (int)((time - elapsedTime).TotalMilliseconds); - if (speedFactor >= 1) - break; - } - } - ResumeLayout(); - Parent.ResumeLayout(); - } - - private void LayoutAnimateWindow(Rectangle rect) - { - Bounds = DockPanel.GetAutoHideWindowBounds(rect); - - Rectangle rectClient = ClientRectangle; - - if (DockState == DockState.DockLeftAutoHide) - ActivePane.Location = new Point(rectClient.Right - 2 - Measures.SplitterSize - ActivePane.Width, ActivePane.Location.Y); - else if (DockState == DockState.DockTopAutoHide) - ActivePane.Location = new Point(ActivePane.Location.X, rectClient.Bottom - 2 - Measures.SplitterSize - ActivePane.Height); - } - - private Rectangle GetRectangle(bool show) - { - if (DockState == DockState.Unknown) - return Rectangle.Empty; - - Rectangle rect = DockPanel.AutoHideWindowRectangle; - - if (show) - return rect; - - if (DockState == DockState.DockLeftAutoHide) - rect.Width = 0; - else if (DockState == DockState.DockRightAutoHide) - { - rect.X += rect.Width; - rect.Width = 0; - } - else if (DockState == DockState.DockTopAutoHide) - rect.Height = 0; - else - { - rect.Y += rect.Height; - rect.Height = 0; - } - - return rect; - } - - private void SetTimerMouseTrack() - { - if (ActivePane == null || ActivePane.IsActivated || FlagDragging) - { - m_timerMouseTrack.Enabled = false; - return; - } - - // start the timer - int hovertime = SystemInformation.MouseHoverTime ; - - // assign a default value 400 in case of setting Timer.Interval invalid value exception - if (hovertime <= 0) - hovertime = 400; - - m_timerMouseTrack.Interval = 2 * (int)hovertime; - m_timerMouseTrack.Enabled = true; - } - - protected virtual Rectangle DisplayingRectangle - { - get - { - Rectangle rect = ClientRectangle; - - // exclude the border and the splitter - if (DockState == DockState.DockBottomAutoHide) - { - rect.Y += 2 + Measures.SplitterSize; - rect.Height -= 2 + Measures.SplitterSize; - } - else if (DockState == DockState.DockRightAutoHide) - { - rect.X += 2 + Measures.SplitterSize; - rect.Width -= 2 + Measures.SplitterSize; - } - else if (DockState == DockState.DockTopAutoHide) - rect.Height -= 2 + Measures.SplitterSize; - else if (DockState == DockState.DockLeftAutoHide) - rect.Width -= 2 + Measures.SplitterSize; - - return rect; - } - } - - protected override void OnLayout(LayoutEventArgs levent) - { - DockPadding.All = 0; - if (DockState == DockState.DockLeftAutoHide) - { - DockPadding.Right = 2; - m_splitter.Dock = DockStyle.Right; - } - else if (DockState == DockState.DockRightAutoHide) - { - DockPadding.Left = 2; - m_splitter.Dock = DockStyle.Left; - } - else if (DockState == DockState.DockTopAutoHide) - { - DockPadding.Bottom = 2; - m_splitter.Dock = DockStyle.Bottom; - } - else if (DockState == DockState.DockBottomAutoHide) - { - DockPadding.Top = 2; - m_splitter.Dock = DockStyle.Top; - } - - Rectangle rectDisplaying = DisplayingRectangle; - Rectangle rectHidden = new Rectangle(-rectDisplaying.Width, rectDisplaying.Y, rectDisplaying.Width, rectDisplaying.Height); - foreach (Control c in Controls) - { - DockPane pane = c as DockPane; - if (pane == null) - continue; - - - if (pane == ActivePane) - pane.Bounds = rectDisplaying; - else - pane.Bounds = rectHidden; - } - - base.OnLayout(levent); - } - - protected override void OnPaint(PaintEventArgs e) - { - // Draw the border - Graphics g = e.Graphics; - - if (DockState == DockState.DockBottomAutoHide) - g.DrawLine(SystemPens.ControlLightLight, 0, 1, ClientRectangle.Right, 1); - else if (DockState == DockState.DockRightAutoHide) - g.DrawLine(SystemPens.ControlLightLight, 1, 0, 1, ClientRectangle.Bottom); - else if (DockState == DockState.DockTopAutoHide) - { - g.DrawLine(SystemPens.ControlDark, 0, ClientRectangle.Height - 2, ClientRectangle.Right, ClientRectangle.Height - 2); - g.DrawLine(SystemPens.ControlDarkDark, 0, ClientRectangle.Height - 1, ClientRectangle.Right, ClientRectangle.Height - 1); - } - else if (DockState == DockState.DockLeftAutoHide) - { - g.DrawLine(SystemPens.ControlDark, ClientRectangle.Width - 2, 0, ClientRectangle.Width - 2, ClientRectangle.Bottom); - g.DrawLine(SystemPens.ControlDarkDark, ClientRectangle.Width - 1, 0, ClientRectangle.Width - 1, ClientRectangle.Bottom); - } - - base.OnPaint(e); - } - - public void RefreshActiveContent() - { - if (ActiveContent == null) - return; - - if (!DockHelper.IsDockStateAutoHide(ActiveContent.DockHandler.DockState)) - { - FlagAnimate = false; - ActiveContent = null; - FlagAnimate = true; - } - } - - public void RefreshActivePane() - { - SetTimerMouseTrack(); - } - - private void TimerMouseTrack_Tick(object sender, EventArgs e) - { - if (IsDisposed) - return; - - if (ActivePane == null || ActivePane.IsActivated) - { - m_timerMouseTrack.Enabled = false; - return; - } - - DockPane pane = ActivePane; - Point ptMouseInAutoHideWindow = PointToClient(Control.MousePosition); - Point ptMouseInDockPanel = DockPanel.PointToClient(Control.MousePosition); - - Rectangle rectTabStrip = DockPanel.GetTabStripRectangle(pane.DockState); - - if (!ClientRectangle.Contains(ptMouseInAutoHideWindow) && !rectTabStrip.Contains(ptMouseInDockPanel)) - { - ActiveContent = null; - m_timerMouseTrack.Enabled = false; - } - } - - #region ISplitterDragSource Members - - void ISplitterDragSource.BeginDrag(Rectangle rectSplitter) - { - FlagDragging = true; - } - - void ISplitterDragSource.EndDrag() - { - FlagDragging = false; - } - - bool ISplitterDragSource.IsVertical - { - get { return (DockState == DockState.DockLeftAutoHide || DockState == DockState.DockRightAutoHide); } - } - - Rectangle ISplitterDragSource.DragLimitBounds - { - get - { - Rectangle rectLimit = DockPanel.DockArea; - - if ((this as ISplitterDragSource).IsVertical) - { - rectLimit.X += MeasurePane.MinSize; - rectLimit.Width -= 2 * MeasurePane.MinSize; - } - else - { - rectLimit.Y += MeasurePane.MinSize; - rectLimit.Height -= 2 * MeasurePane.MinSize; - } - - return DockPanel.RectangleToScreen(rectLimit); - } - } - - void ISplitterDragSource.MoveSplitter(int offset) - { - Rectangle rectDockArea = DockPanel.DockArea; - IDockContent content = ActiveContent; - if (DockState == DockState.DockLeftAutoHide && rectDockArea.Width > 0) - { - if (content.DockHandler.AutoHidePortion < 1) - content.DockHandler.AutoHidePortion += ((double)offset) / (double)rectDockArea.Width; - else - content.DockHandler.AutoHidePortion = Width + offset; - } - else if (DockState == DockState.DockRightAutoHide && rectDockArea.Width > 0) - { - if (content.DockHandler.AutoHidePortion < 1) - content.DockHandler.AutoHidePortion -= ((double)offset) / (double)rectDockArea.Width; - else - content.DockHandler.AutoHidePortion = Width - offset; - } - else if (DockState == DockState.DockBottomAutoHide && rectDockArea.Height > 0) - { - if (content.DockHandler.AutoHidePortion < 1) - content.DockHandler.AutoHidePortion -= ((double)offset) / (double)rectDockArea.Height; - else - content.DockHandler.AutoHidePortion = Height - offset; - } - else if (DockState == DockState.DockTopAutoHide && rectDockArea.Height > 0) - { - if (content.DockHandler.AutoHidePortion < 1) - content.DockHandler.AutoHidePortion += ((double)offset) / (double)rectDockArea.Height; - else - content.DockHandler.AutoHidePortion = Height + offset; - } - } - - #region IDragSource Members - - Control IDragSource.DragControl - { - get { return this; } - } - - #endregion - - #endregion - } - - private AutoHideWindowControl AutoHideWindow - { - get { return m_autoHideWindow; } - } - - internal Control AutoHideControl - { - get { return m_autoHideWindow; } - } - - internal void RefreshActiveAutoHideContent() - { - AutoHideWindow.RefreshActiveContent(); - } - - internal Rectangle AutoHideWindowRectangle - { - get - { - DockState state = AutoHideWindow.DockState; - Rectangle rectDockArea = DockArea; - if (ActiveAutoHideContent == null) - return Rectangle.Empty; - - if (Parent == null) - return Rectangle.Empty; - - Rectangle rect = Rectangle.Empty; - double autoHideSize = ActiveAutoHideContent.DockHandler.AutoHidePortion; - if (state == DockState.DockLeftAutoHide) - { - if (autoHideSize < 1) - autoHideSize = rectDockArea.Width * autoHideSize; - if (autoHideSize > rectDockArea.Width - MeasurePane.MinSize) - autoHideSize = rectDockArea.Width - MeasurePane.MinSize; - rect.X = rectDockArea.X; - rect.Y = rectDockArea.Y; - rect.Width = (int)autoHideSize; - rect.Height = rectDockArea.Height; - } - else if (state == DockState.DockRightAutoHide) - { - if (autoHideSize < 1) - autoHideSize = rectDockArea.Width * autoHideSize; - if (autoHideSize > rectDockArea.Width - MeasurePane.MinSize) - autoHideSize = rectDockArea.Width - MeasurePane.MinSize; - rect.X = rectDockArea.X + rectDockArea.Width - (int)autoHideSize; - rect.Y = rectDockArea.Y; - rect.Width = (int)autoHideSize; - rect.Height = rectDockArea.Height; - } - else if (state == DockState.DockTopAutoHide) - { - if (autoHideSize < 1) - autoHideSize = rectDockArea.Height * autoHideSize; - if (autoHideSize > rectDockArea.Height - MeasurePane.MinSize) - autoHideSize = rectDockArea.Height - MeasurePane.MinSize; - rect.X = rectDockArea.X; - rect.Y = rectDockArea.Y; - rect.Width = rectDockArea.Width; - rect.Height = (int)autoHideSize; - } - else if (state == DockState.DockBottomAutoHide) - { - if (autoHideSize < 1) - autoHideSize = rectDockArea.Height * autoHideSize; - if (autoHideSize > rectDockArea.Height - MeasurePane.MinSize) - autoHideSize = rectDockArea.Height - MeasurePane.MinSize; - rect.X = rectDockArea.X; - rect.Y = rectDockArea.Y + rectDockArea.Height - (int)autoHideSize; - rect.Width = rectDockArea.Width; - rect.Height = (int)autoHideSize; - } - - return rect; - } - } - - internal Rectangle GetAutoHideWindowBounds(Rectangle rectAutoHideWindow) - { - if (DocumentStyle == DocumentStyle.SystemMdi || - DocumentStyle == DocumentStyle.DockingMdi) - return (Parent == null) ? Rectangle.Empty : Parent.RectangleToClient(RectangleToScreen(rectAutoHideWindow)); - else - return rectAutoHideWindow; - } - - internal void RefreshAutoHideStrip() - { - AutoHideStripControl.RefreshChanges(); - } - - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.DockDragHandler.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.DockDragHandler.cs deleted file mode 100644 index dc3c15f1c7..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.DockDragHandler.cs +++ /dev/null @@ -1,811 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Text; -using System.Windows.Forms; -using System.Drawing; -using System.Drawing.Drawing2D; -using System.ComponentModel; - -namespace WeifenLuo.WinFormsUI.Docking -{ - partial class DockPanel - { - private sealed class DockDragHandler : DragHandler - { - private class DockIndicator : DragForm - { - #region IHitTest - private interface IHitTest - { - DockStyle HitTest(Point pt); - DockStyle Status { get; set; } - } - #endregion - - #region PanelIndicator - private class PanelIndicator : PictureBox, IHitTest - { - private static Image _imagePanelLeft = Resources.DockIndicator_PanelLeft; - private static Image _imagePanelRight = Resources.DockIndicator_PanelRight; - private static Image _imagePanelTop = Resources.DockIndicator_PanelTop; - private static Image _imagePanelBottom = Resources.DockIndicator_PanelBottom; - private static Image _imagePanelFill = Resources.DockIndicator_PanelFill; - private static Image _imagePanelLeftActive = Resources.DockIndicator_PanelLeft_Active; - private static Image _imagePanelRightActive = Resources.DockIndicator_PanelRight_Active; - private static Image _imagePanelTopActive = Resources.DockIndicator_PanelTop_Active; - private static Image _imagePanelBottomActive = Resources.DockIndicator_PanelBottom_Active; - private static Image _imagePanelFillActive = Resources.DockIndicator_PanelFill_Active; - - public PanelIndicator(DockStyle dockStyle) - { - m_dockStyle = dockStyle; - SizeMode = PictureBoxSizeMode.AutoSize; - Image = ImageInactive; - } - - private DockStyle m_dockStyle; - private DockStyle DockStyle - { - get { return m_dockStyle; } - } - - private DockStyle m_status; - public DockStyle Status - { - get { return m_status; } - set - { - if (value != DockStyle && value != DockStyle.None) - throw new InvalidEnumArgumentException(); - - if (m_status == value) - return; - - m_status = value; - IsActivated = (m_status != DockStyle.None); - } - } - - private Image ImageInactive - { - get - { - if (DockStyle == DockStyle.Left) - return _imagePanelLeft; - else if (DockStyle == DockStyle.Right) - return _imagePanelRight; - else if (DockStyle == DockStyle.Top) - return _imagePanelTop; - else if (DockStyle == DockStyle.Bottom) - return _imagePanelBottom; - else if (DockStyle == DockStyle.Fill) - return _imagePanelFill; - else - return null; - } - } - - private Image ImageActive - { - get - { - if (DockStyle == DockStyle.Left) - return _imagePanelLeftActive; - else if (DockStyle == DockStyle.Right) - return _imagePanelRightActive; - else if (DockStyle == DockStyle.Top) - return _imagePanelTopActive; - else if (DockStyle == DockStyle.Bottom) - return _imagePanelBottomActive; - else if (DockStyle == DockStyle.Fill) - return _imagePanelFillActive; - else - return null; - } - } - - private bool m_isActivated = false; - private bool IsActivated - { - get { return m_isActivated; } - set - { - m_isActivated = value; - Image = IsActivated ? ImageActive : ImageInactive; - } - } - - public DockStyle HitTest(Point pt) - { - return this.Visible && ClientRectangle.Contains(PointToClient(pt)) ? DockStyle : DockStyle.None; - } - } - #endregion PanelIndicator - - #region PaneIndicator - private class PaneIndicator : PictureBox, IHitTest - { - private struct HotSpotIndex - { - public HotSpotIndex(int x, int y, DockStyle dockStyle) - { - m_x = x; - m_y = y; - m_dockStyle = dockStyle; - } - - private int m_x; - public int X - { - get { return m_x; } - } - - private int m_y; - public int Y - { - get { return m_y; } - } - - private DockStyle m_dockStyle; - public DockStyle DockStyle - { - get { return m_dockStyle; } - } - } - - private static Bitmap _bitmapPaneDiamond = Resources.DockIndicator_PaneDiamond; - private static Bitmap _bitmapPaneDiamondLeft = Resources.DockIndicator_PaneDiamond_Left; - private static Bitmap _bitmapPaneDiamondRight = Resources.DockIndicator_PaneDiamond_Right; - private static Bitmap _bitmapPaneDiamondTop = Resources.DockIndicator_PaneDiamond_Top; - private static Bitmap _bitmapPaneDiamondBottom = Resources.DockIndicator_PaneDiamond_Bottom; - private static Bitmap _bitmapPaneDiamondFill = Resources.DockIndicator_PaneDiamond_Fill; - private static Bitmap _bitmapPaneDiamondHotSpot = Resources.DockIndicator_PaneDiamond_HotSpot; - private static Bitmap _bitmapPaneDiamondHotSpotIndex = Resources.DockIndicator_PaneDiamond_HotSpotIndex; - private static HotSpotIndex[] _hotSpots = new HotSpotIndex[] - { - new HotSpotIndex(1, 0, DockStyle.Top), - new HotSpotIndex(0, 1, DockStyle.Left), - new HotSpotIndex(1, 1, DockStyle.Fill), - new HotSpotIndex(2, 1, DockStyle.Right), - new HotSpotIndex(1, 2, DockStyle.Bottom) - }; - private static GraphicsPath _displayingGraphicsPath = DrawHelper.CalculateGraphicsPathFromBitmap(_bitmapPaneDiamond); - - public PaneIndicator() - { - SizeMode = PictureBoxSizeMode.AutoSize; - Image = _bitmapPaneDiamond; - Region = new Region(DisplayingGraphicsPath); - } - - public static GraphicsPath DisplayingGraphicsPath - { - get { return _displayingGraphicsPath; } - } - - public DockStyle HitTest(Point pt) - { - if (!Visible) - return DockStyle.None; - - pt = PointToClient(pt); - if (!ClientRectangle.Contains(pt)) - return DockStyle.None; - - for (int i = _hotSpots.GetLowerBound(0); i <= _hotSpots.GetUpperBound(0); i++) - { - if (_bitmapPaneDiamondHotSpot.GetPixel(pt.X, pt.Y) == _bitmapPaneDiamondHotSpotIndex.GetPixel(_hotSpots[i].X, _hotSpots[i].Y)) - return _hotSpots[i].DockStyle; - } - - return DockStyle.None; - } - - private DockStyle m_status = DockStyle.None; - public DockStyle Status - { - get { return m_status; } - set - { - m_status = value; - if (m_status == DockStyle.None) - Image = _bitmapPaneDiamond; - else if (m_status == DockStyle.Left) - Image = _bitmapPaneDiamondLeft; - else if (m_status == DockStyle.Right) - Image = _bitmapPaneDiamondRight; - else if (m_status == DockStyle.Top) - Image = _bitmapPaneDiamondTop; - else if (m_status == DockStyle.Bottom) - Image = _bitmapPaneDiamondBottom; - else if (m_status == DockStyle.Fill) - Image = _bitmapPaneDiamondFill; - } - } - } - #endregion PaneIndicator - - #region consts - private int _PanelIndicatorMargin = 10; - #endregion - - private DockDragHandler m_dragHandler; - - public DockIndicator(DockDragHandler dragHandler) - { - m_dragHandler = dragHandler; - Controls.AddRange(new Control[] { - PaneDiamond, - PanelLeft, - PanelRight, - PanelTop, - PanelBottom, - PanelFill - }); - Region = new Region(Rectangle.Empty); - } - - private PaneIndicator m_paneDiamond = null; - private PaneIndicator PaneDiamond - { - get - { - if (m_paneDiamond == null) - m_paneDiamond = new PaneIndicator(); - - return m_paneDiamond; - } - } - - private PanelIndicator m_panelLeft = null; - private PanelIndicator PanelLeft - { - get - { - if (m_panelLeft == null) - m_panelLeft = new PanelIndicator(DockStyle.Left); - - return m_panelLeft; - } - } - - private PanelIndicator m_panelRight = null; - private PanelIndicator PanelRight - { - get - { - if (m_panelRight == null) - m_panelRight = new PanelIndicator(DockStyle.Right); - - return m_panelRight; - } - } - - private PanelIndicator m_panelTop = null; - private PanelIndicator PanelTop - { - get - { - if (m_panelTop == null) - m_panelTop = new PanelIndicator(DockStyle.Top); - - return m_panelTop; - } - } - - private PanelIndicator m_panelBottom = null; - private PanelIndicator PanelBottom - { - get - { - if (m_panelBottom == null) - m_panelBottom = new PanelIndicator(DockStyle.Bottom); - - return m_panelBottom; - } - } - - private PanelIndicator m_panelFill = null; - private PanelIndicator PanelFill - { - get - { - if (m_panelFill == null) - m_panelFill = new PanelIndicator(DockStyle.Fill); - - return m_panelFill; - } - } - - private bool m_fullPanelEdge = false; - public bool FullPanelEdge - { - get { return m_fullPanelEdge; } - set - { - if (m_fullPanelEdge == value) - return; - - m_fullPanelEdge = value; - RefreshChanges(); - } - } - - public DockDragHandler DragHandler - { - get { return m_dragHandler; } - } - - public DockPanel DockPanel - { - get { return DragHandler.DockPanel; } - } - - private DockPane m_dockPane = null; - public DockPane DockPane - { - get { return m_dockPane; } - internal set - { - if (m_dockPane == value) - return; - - DockPane oldDisplayingPane = DisplayingPane; - m_dockPane = value; - if (oldDisplayingPane != DisplayingPane) - RefreshChanges(); - } - } - - private IHitTest m_hitTest = null; - private IHitTest HitTestResult - { - get { return m_hitTest; } - set - { - if (m_hitTest == value) - return; - - if (m_hitTest != null) - m_hitTest.Status = DockStyle.None; - - m_hitTest = value; - } - } - - private DockPane DisplayingPane - { - get { return ShouldPaneDiamondVisible() ? DockPane : null; } - } - - private void RefreshChanges() - { - Region region = new Region(Rectangle.Empty); - Rectangle rectDockArea = FullPanelEdge ? DockPanel.DockArea : DockPanel.DocumentWindowBounds; - - rectDockArea = RectangleToClient(DockPanel.RectangleToScreen(rectDockArea)); - if (ShouldPanelIndicatorVisible(DockState.DockLeft)) - { - PanelLeft.Location = new Point(rectDockArea.X + _PanelIndicatorMargin, rectDockArea.Y + (rectDockArea.Height - PanelRight.Height) / 2); - PanelLeft.Visible = true; - region.Union(PanelLeft.Bounds); - } - else - PanelLeft.Visible = false; - - if (ShouldPanelIndicatorVisible(DockState.DockRight)) - { - PanelRight.Location = new Point(rectDockArea.X + rectDockArea.Width - PanelRight.Width - _PanelIndicatorMargin, rectDockArea.Y + (rectDockArea.Height - PanelRight.Height) / 2); - PanelRight.Visible = true; - region.Union(PanelRight.Bounds); - } - else - PanelRight.Visible = false; - - if (ShouldPanelIndicatorVisible(DockState.DockTop)) - { - PanelTop.Location = new Point(rectDockArea.X + (rectDockArea.Width - PanelTop.Width) / 2, rectDockArea.Y + _PanelIndicatorMargin); - PanelTop.Visible = true; - region.Union(PanelTop.Bounds); - } - else - PanelTop.Visible = false; - - if (ShouldPanelIndicatorVisible(DockState.DockBottom)) - { - PanelBottom.Location = new Point(rectDockArea.X + (rectDockArea.Width - PanelBottom.Width) / 2, rectDockArea.Y + rectDockArea.Height - PanelBottom.Height - _PanelIndicatorMargin); - PanelBottom.Visible = true; - region.Union(PanelBottom.Bounds); - } - else - PanelBottom.Visible = false; - - if (ShouldPanelIndicatorVisible(DockState.Document)) - { - Rectangle rectDocumentWindow = RectangleToClient(DockPanel.RectangleToScreen(DockPanel.DocumentWindowBounds)); - PanelFill.Location = new Point(rectDocumentWindow.X + (rectDocumentWindow.Width - PanelFill.Width) / 2, rectDocumentWindow.Y + (rectDocumentWindow.Height - PanelFill.Height) / 2); - PanelFill.Visible = true; - region.Union(PanelFill.Bounds); - } - else - PanelFill.Visible = false; - - if (ShouldPaneDiamondVisible()) - { - Rectangle rect = RectangleToClient(DockPane.RectangleToScreen(DockPane.ClientRectangle)); - PaneDiamond.Location = new Point(rect.Left + (rect.Width - PaneDiamond.Width) / 2, rect.Top + (rect.Height - PaneDiamond.Height) / 2); - PaneDiamond.Visible = true; - using (GraphicsPath graphicsPath = PaneIndicator.DisplayingGraphicsPath.Clone() as GraphicsPath) - { - Point[] pts = new Point[] - { - new Point(PaneDiamond.Left, PaneDiamond.Top), - new Point(PaneDiamond.Right, PaneDiamond.Top), - new Point(PaneDiamond.Left, PaneDiamond.Bottom) - }; - using (Matrix matrix = new Matrix(PaneDiamond.ClientRectangle, pts)) - { - graphicsPath.Transform(matrix); - } - region.Union(graphicsPath); - } - } - else - PaneDiamond.Visible = false; - - Region = region; - } - - private bool ShouldPanelIndicatorVisible(DockState dockState) - { - if (!Visible) - return false; - - if (DockPanel.DockWindows[dockState].Visible) - return false; - - return DragHandler.DragSource.IsDockStateValid(dockState); - } - - private bool ShouldPaneDiamondVisible() - { - if (DockPane == null) - return false; - - if (!DockPanel.AllowEndUserNestedDocking) - return false; - - return DragHandler.DragSource.CanDockTo(DockPane); - } - - public override void Show(bool bActivate) - { - base.Show(bActivate); - Bounds = SystemInformation.VirtualScreen; - RefreshChanges(); - } - - public void TestDrop() - { - Point pt = Control.MousePosition; - DockPane = DockHelper.PaneAtPoint(pt, DockPanel); - - if (TestDrop(PanelLeft, pt) != DockStyle.None) - HitTestResult = PanelLeft; - else if (TestDrop(PanelRight, pt) != DockStyle.None) - HitTestResult = PanelRight; - else if (TestDrop(PanelTop, pt) != DockStyle.None) - HitTestResult = PanelTop; - else if (TestDrop(PanelBottom, pt) != DockStyle.None) - HitTestResult = PanelBottom; - else if (TestDrop(PanelFill, pt) != DockStyle.None) - HitTestResult = PanelFill; - else if (TestDrop(PaneDiamond, pt) != DockStyle.None) - HitTestResult = PaneDiamond; - else - HitTestResult = null; - - if (HitTestResult != null) - { - if (HitTestResult is PaneIndicator) - DragHandler.Outline.Show(DockPane, HitTestResult.Status); - else - DragHandler.Outline.Show(DockPanel, HitTestResult.Status, FullPanelEdge); - } - } - - private static DockStyle TestDrop(IHitTest hitTest, Point pt) - { - return hitTest.Status = hitTest.HitTest(pt); - } - } - - private class DockOutline : DockOutlineBase - { - public DockOutline() - { - m_dragForm = new DragForm(); - SetDragForm(Rectangle.Empty); - DragForm.BackColor = SystemColors.ActiveCaption; - DragForm.Opacity = 0.5; - DragForm.Show(false); - } - - DragForm m_dragForm; - private DragForm DragForm - { - get { return m_dragForm; } - } - - protected override void OnShow() - { - CalculateRegion(); - } - - protected override void OnClose() - { - DragForm.Close(); - } - - private void CalculateRegion() - { - if (SameAsOldValue) - return; - - if (!FloatWindowBounds.IsEmpty) - SetOutline(FloatWindowBounds); - else if (DockTo is DockPanel) - SetOutline(DockTo as DockPanel, Dock, (ContentIndex != 0)); - else if (DockTo is DockPane) - SetOutline(DockTo as DockPane, Dock, ContentIndex); - else - SetOutline(); - } - - private void SetOutline() - { - SetDragForm(Rectangle.Empty); - } - - private void SetOutline(Rectangle floatWindowBounds) - { - SetDragForm(floatWindowBounds); - } - - private void SetOutline(DockPanel dockPanel, DockStyle dock, bool fullPanelEdge) - { - Rectangle rect = fullPanelEdge ? dockPanel.DockArea : dockPanel.DocumentWindowBounds; - rect.Location = dockPanel.PointToScreen(rect.Location); - if (dock == DockStyle.Top) - { - int height = dockPanel.GetDockWindowSize(DockState.DockTop); - rect = new Rectangle(rect.X, rect.Y, rect.Width, height); - } - else if (dock == DockStyle.Bottom) - { - int height = dockPanel.GetDockWindowSize(DockState.DockBottom); - rect = new Rectangle(rect.X, rect.Bottom - height, rect.Width, height); - } - else if (dock == DockStyle.Left) - { - int width = dockPanel.GetDockWindowSize(DockState.DockLeft); - rect = new Rectangle(rect.X, rect.Y, width, rect.Height); - } - else if (dock == DockStyle.Right) - { - int width = dockPanel.GetDockWindowSize(DockState.DockRight); - rect = new Rectangle(rect.Right - width, rect.Y, width, rect.Height); - } - else if (dock == DockStyle.Fill) - { - rect = dockPanel.DocumentWindowBounds; - rect.Location = dockPanel.PointToScreen(rect.Location); - } - - SetDragForm(rect); - } - - private void SetOutline(DockPane pane, DockStyle dock, int contentIndex) - { - if (dock != DockStyle.Fill) - { - Rectangle rect = pane.DisplayingRectangle; - if (dock == DockStyle.Right) - rect.X += rect.Width / 2; - if (dock == DockStyle.Bottom) - rect.Y += rect.Height / 2; - if (dock == DockStyle.Left || dock == DockStyle.Right) - rect.Width -= rect.Width / 2; - if (dock == DockStyle.Top || dock == DockStyle.Bottom) - rect.Height -= rect.Height / 2; - rect.Location = pane.PointToScreen(rect.Location); - - SetDragForm(rect); - } - else if (contentIndex == -1) - { - Rectangle rect = pane.DisplayingRectangle; - rect.Location = pane.PointToScreen(rect.Location); - SetDragForm(rect); - } - else - { - using (GraphicsPath path = pane.TabStripControl.GetOutline(contentIndex)) - { - RectangleF rectF = path.GetBounds(); - Rectangle rect = new Rectangle((int)rectF.X, (int)rectF.Y, (int)rectF.Width, (int)rectF.Height); - using (Matrix matrix = new Matrix(rect, new Point[] { new Point(0, 0), new Point(rect.Width, 0), new Point(0, rect.Height) })) - { - path.Transform(matrix); - } - Region region = new Region(path); - SetDragForm(rect, region); - } - } - } - - private void SetDragForm(Rectangle rect) - { - DragForm.Bounds = rect; - if (rect == Rectangle.Empty) - DragForm.Region = new Region(Rectangle.Empty); - else if (DragForm.Region != null) - DragForm.Region = null; - } - - private void SetDragForm(Rectangle rect, Region region) - { - DragForm.Bounds = rect; - DragForm.Region = region; - } - } - - public DockDragHandler(DockPanel panel) - : base(panel) - { - } - - public new IDockDragSource DragSource - { - get { return base.DragSource as IDockDragSource; } - set { base.DragSource = value; } - } - - private DockOutlineBase m_outline; - public DockOutlineBase Outline - { - get { return m_outline; } - private set { m_outline = value; } - } - - private DockIndicator m_indicator; - private DockIndicator Indicator - { - get { return m_indicator; } - set { m_indicator = value; } - } - - private Rectangle m_floatOutlineBounds; - private Rectangle FloatOutlineBounds - { - get { return m_floatOutlineBounds; } - set { m_floatOutlineBounds = value; } - } - - public void BeginDrag(IDockDragSource dragSource) - { - DragSource = dragSource; - - if (!BeginDrag()) - { - DragSource = null; - return; - } - - Outline = new DockOutline(); - Indicator = new DockIndicator(this); - Indicator.Show(false); - - FloatOutlineBounds = DragSource.BeginDrag(StartMousePosition); - } - - protected override void OnDragging() - { - TestDrop(); - } - - protected override void OnEndDrag(bool abort) - { - DockPanel.SuspendLayout(true); - - Outline.Close(); - Indicator.Close(); - - EndDrag(abort); - - DockPanel.ResumeLayout(true, true); - - DragSource = null; - } - - private void TestDrop() - { - Outline.FlagTestDrop = false; - - Indicator.FullPanelEdge = ((Control.ModifierKeys & Keys.Shift) != 0); - - if ((Control.ModifierKeys & Keys.Control) == 0) - { - Indicator.TestDrop(); - - if (!Outline.FlagTestDrop) - { - DockPane pane = DockHelper.PaneAtPoint(Control.MousePosition, DockPanel); - if (pane != null && DragSource.IsDockStateValid(pane.DockState)) - pane.TestDrop(DragSource, Outline); - } - - if (!Outline.FlagTestDrop && DragSource.IsDockStateValid(DockState.Float)) - { - FloatWindow floatWindow = DockHelper.FloatWindowAtPoint(Control.MousePosition, DockPanel); - if (floatWindow != null) - floatWindow.TestDrop(DragSource, Outline); - } - } - else - Indicator.DockPane = DockHelper.PaneAtPoint(Control.MousePosition, DockPanel); - - if (!Outline.FlagTestDrop) - { - if (DragSource.IsDockStateValid(DockState.Float)) - { - Rectangle rect = FloatOutlineBounds; - rect.Offset(Control.MousePosition.X - StartMousePosition.X, Control.MousePosition.Y - StartMousePosition.Y); - Outline.Show(rect); - } - } - - if (!Outline.FlagTestDrop) - { - Cursor.Current = Cursors.No; - Outline.Show(); - } - else - Cursor.Current = DragControl.Cursor; - } - - private void EndDrag(bool abort) - { - if (abort) - return; - - if (!Outline.FloatWindowBounds.IsEmpty) - DragSource.FloatAt(Outline.FloatWindowBounds); - else if (Outline.DockTo is DockPane) - { - DockPane pane = Outline.DockTo as DockPane; - DragSource.DockTo(pane, Outline.Dock, Outline.ContentIndex); - } - else if (Outline.DockTo is DockPanel) - { - DockPanel panel = Outline.DockTo as DockPanel; - panel.UpdateDockWindowZOrder(Outline.Dock, Outline.FlagFullEdge); - DragSource.DockTo(panel, Outline.Dock); - } - } - } - - private DockDragHandler m_dockDragHandler = null; - private DockDragHandler GetDockDragHandler() - { - if (m_dockDragHandler == null) - m_dockDragHandler = new DockDragHandler(this); - return m_dockDragHandler; - } - - internal void BeginDrag(IDockDragSource dragSource) - { - GetDockDragHandler().BeginDrag(dragSource); - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.DragHandler.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.DragHandler.cs deleted file mode 100644 index 46a1e09530..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.DragHandler.cs +++ /dev/null @@ -1,135 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Text; -using System.Windows.Forms; -using System.Drawing; -using System.Drawing.Drawing2D; -using System.ComponentModel; - -namespace WeifenLuo.WinFormsUI.Docking -{ - partial class DockPanel - { - /// - /// DragHandlerBase is the base class for drag handlers. The derived class should: - /// 1. Define its public method BeginDrag. From within this public BeginDrag method, - /// DragHandlerBase.BeginDrag should be called to initialize the mouse capture - /// and message filtering. - /// 2. Override the OnDragging and OnEndDrag methods. - /// - private abstract class DragHandlerBase : NativeWindow, IMessageFilter - { - protected DragHandlerBase() - { - } - - protected abstract Control DragControl - { - get; - } - - private Point m_startMousePosition = Point.Empty; - protected Point StartMousePosition - { - get { return m_startMousePosition; } - private set { m_startMousePosition = value; } - } - - protected bool BeginDrag() - { - // Avoid re-entrance; - lock (this) - { - if (DragControl == null) - return false; - - StartMousePosition = Control.MousePosition; - - if (!NativeMethods.DragDetect(DragControl.Handle, StartMousePosition)) - return false; - - DragControl.FindForm().Capture = true; - AssignHandle(DragControl.FindForm().Handle); - Application.AddMessageFilter(this); - return true; - } - } - - protected abstract void OnDragging(); - - protected abstract void OnEndDrag(bool abort); - - private void EndDrag(bool abort) - { - ReleaseHandle(); - Application.RemoveMessageFilter(this); - DragControl.FindForm().Capture = false; - - OnEndDrag(abort); - } - - bool IMessageFilter.PreFilterMessage(ref Message m) - { - if (m.Msg == (int)Win32.Msgs.WM_MOUSEMOVE) - OnDragging(); - else if (m.Msg == (int)Win32.Msgs.WM_LBUTTONUP) - EndDrag(false); - else if (m.Msg == (int)Win32.Msgs.WM_CAPTURECHANGED) - EndDrag(true); - else if (m.Msg == (int)Win32.Msgs.WM_KEYDOWN && (int)m.WParam == (int)Keys.Escape) - EndDrag(true); - - return OnPreFilterMessage(ref m); - } - - protected virtual bool OnPreFilterMessage(ref Message m) - { - return false; - } - - protected sealed override void WndProc(ref Message m) - { - if (m.Msg == (int)Win32.Msgs.WM_CANCELMODE || m.Msg == (int)Win32.Msgs.WM_CAPTURECHANGED) - EndDrag(true); - - base.WndProc(ref m); - } - } - - private abstract class DragHandler : DragHandlerBase - { - private DockPanel m_dockPanel; - - protected DragHandler(DockPanel dockPanel) - { - m_dockPanel = dockPanel; - } - - public DockPanel DockPanel - { - get { return m_dockPanel; } - } - - private IDragSource m_dragSource; - protected IDragSource DragSource - { - get { return m_dragSource; } - set { m_dragSource = value; } - } - - protected sealed override Control DragControl - { - get { return DragSource == null ? null : DragSource.DragControl; } - } - - protected sealed override bool OnPreFilterMessage(ref Message m) - { - if ((m.Msg == (int)Win32.Msgs.WM_KEYDOWN || m.Msg == (int)Win32.Msgs.WM_KEYUP) && - ((int)m.WParam == (int)Keys.ControlKey || (int)m.WParam == (int)Keys.ShiftKey)) - OnDragging(); - - return base.OnPreFilterMessage(ref m); - } - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.FocusManager.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.FocusManager.cs deleted file mode 100644 index 9621c02037..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.FocusManager.cs +++ /dev/null @@ -1,571 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Text; -using System.ComponentModel; -using System.Runtime.InteropServices; -using System.Windows.Forms; -using System.Diagnostics.CodeAnalysis; - -namespace WeifenLuo.WinFormsUI.Docking -{ - internal interface IContentFocusManager - { - void Activate(IDockContent content); - void GiveUpFocus(IDockContent content); - void AddToList(IDockContent content); - void RemoveFromList(IDockContent content); - } - - partial class DockPanel - { - private interface IFocusManager - { - void SuspendFocusTracking(); - void ResumeFocusTracking(); - bool IsFocusTrackingSuspended { get; } - IDockContent ActiveContent { get; } - DockPane ActivePane { get; } - IDockContent ActiveDocument { get; } - DockPane ActiveDocumentPane { get; } - } - - private class FocusManagerImpl : Component, IContentFocusManager, IFocusManager - { - private class HookEventArgs : EventArgs - { - [SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - public int HookCode; - [SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - public IntPtr wParam; - public IntPtr lParam; - } - - private class LocalWindowsHook : IDisposable - { - // Internal properties - private IntPtr m_hHook = IntPtr.Zero; - private NativeMethods.HookProc m_filterFunc = null; - private Win32.HookType m_hookType; - - // Event delegate - public delegate void HookEventHandler(object sender, HookEventArgs e); - - // Event: HookInvoked - public event HookEventHandler HookInvoked; - protected void OnHookInvoked(HookEventArgs e) - { - if (HookInvoked != null) - HookInvoked(this, e); - } - - public LocalWindowsHook(Win32.HookType hook) - { - m_hookType = hook; - m_filterFunc = new NativeMethods.HookProc(this.CoreHookProc); - } - - // Default filter function - public IntPtr CoreHookProc(int code, IntPtr wParam, IntPtr lParam) - { - if (code < 0) - return NativeMethods.CallNextHookEx(m_hHook, code, wParam, lParam); - - // Let clients determine what to do - HookEventArgs e = new HookEventArgs(); - e.HookCode = code; - e.wParam = wParam; - e.lParam = lParam; - OnHookInvoked(e); - - // Yield to the next hook in the chain - return NativeMethods.CallNextHookEx(m_hHook, code, wParam, lParam); - } - - // Install the hook - public void Install() - { - if (m_hHook != IntPtr.Zero) - Uninstall(); - - int threadId = NativeMethods.GetCurrentThreadId(); - m_hHook = NativeMethods.SetWindowsHookEx(m_hookType, m_filterFunc, IntPtr.Zero, threadId); - } - - // Uninstall the hook - public void Uninstall() - { - if (m_hHook != IntPtr.Zero) - { - NativeMethods.UnhookWindowsHookEx(m_hHook); - m_hHook = IntPtr.Zero; - } - } - - ~LocalWindowsHook() - { - Dispose(false); - } - - public void Dispose() - { - Dispose(true); - GC.SuppressFinalize(this); - } - - protected virtual void Dispose(bool disposing) - { - Uninstall(); - } - } - - private LocalWindowsHook m_localWindowsHook; - private LocalWindowsHook.HookEventHandler m_hookEventHandler; - - public FocusManagerImpl(DockPanel dockPanel) - { - m_dockPanel = dockPanel; - m_localWindowsHook = new LocalWindowsHook(Win32.HookType.WH_CALLWNDPROCRET); - m_hookEventHandler = new LocalWindowsHook.HookEventHandler(HookEventHandler); - m_localWindowsHook.HookInvoked += m_hookEventHandler; - m_localWindowsHook.Install(); - } - - private DockPanel m_dockPanel; - public DockPanel DockPanel - { - get { return m_dockPanel; } - } - - private bool m_disposed = false; - protected override void Dispose(bool disposing) - { - lock (this) - { - if (!m_disposed && disposing) - { - m_localWindowsHook.Dispose(); - m_disposed = true; - } - - base.Dispose(disposing); - } - } - - private IDockContent m_contentActivating = null; - private IDockContent ContentActivating - { - get { return m_contentActivating; } - set { m_contentActivating = value; } - } - - public void Activate(IDockContent content) - { - if (IsFocusTrackingSuspended) - { - ContentActivating = content; - return; - } - - if (content.IsDisposed) - return; - - if (content == null) - return; - DockContentHandler handler = content.DockHandler; - if (handler.Form.IsDisposed) - return; // Should not reach here, but better than throwing an exception - if (ContentContains(content, handler.ActiveWindowHandle)) - NativeMethods.SetFocus(handler.ActiveWindowHandle); - if (!handler.Form.ContainsFocus) - { - if (!handler.Form.SelectNextControl(handler.Form.ActiveControl, true, true, true, true)) - // Since DockContent Form is not selectalbe, use Win32 SetFocus instead - NativeMethods.SetFocus(handler.Form.Handle); - } - } - - private List m_listContent = new List(); - private List ListContent - { - get { return m_listContent; } - } - public void AddToList(IDockContent content) - { - if (ListContent.Contains(content) || IsInActiveList(content)) - return; - - ListContent.Add(content); - } - - public void RemoveFromList(IDockContent content) - { - if (IsInActiveList(content)) - RemoveFromActiveList(content); - if (ListContent.Contains(content)) - ListContent.Remove(content); - } - - private IDockContent m_lastActiveContent = null; - private IDockContent LastActiveContent - { - get { return m_lastActiveContent; } - set { m_lastActiveContent = value; } - } - - private bool IsInActiveList(IDockContent content) - { - return !(content.DockHandler.NextActive == null && LastActiveContent != content); - } - - private void AddLastToActiveList(IDockContent content) - { - IDockContent last = LastActiveContent; - if (last == content) - return; - - DockContentHandler handler = content.DockHandler; - - if (IsInActiveList(content)) - RemoveFromActiveList(content); - - handler.PreviousActive = last; - handler.NextActive = null; - LastActiveContent = content; - if (last != null) - last.DockHandler.NextActive = LastActiveContent; - } - - private void RemoveFromActiveList(IDockContent content) - { - if (LastActiveContent == content) - LastActiveContent = content.DockHandler.PreviousActive; - - IDockContent prev = content.DockHandler.PreviousActive; - IDockContent next = content.DockHandler.NextActive; - if (prev != null) - prev.DockHandler.NextActive = next; - if (next != null) - next.DockHandler.PreviousActive = prev; - - content.DockHandler.PreviousActive = null; - content.DockHandler.NextActive = null; - } - - public void GiveUpFocus(IDockContent content) - { - DockContentHandler handler = content.DockHandler; - if (!handler.Form.ContainsFocus) - return; - - if (IsFocusTrackingSuspended) - DockPanel.DummyControl.Focus(); - - if (LastActiveContent == content) - { - IDockContent prev = handler.PreviousActive; - if (prev != null) - Activate(prev); - else if (ListContent.Count > 0) - Activate(ListContent[ListContent.Count - 1]); - } - else if (LastActiveContent != null) - Activate(LastActiveContent); - else if (ListContent.Count > 0) - Activate(ListContent[ListContent.Count - 1]); - } - - private static bool ContentContains(IDockContent content, IntPtr hWnd) - { - Control control = Control.FromChildHandle(hWnd); - for (Control parent = control; parent != null; parent = parent.Parent) - if (parent == content.DockHandler.Form) - return true; - - return false; - } - - private int m_countSuspendFocusTracking = 0; - public void SuspendFocusTracking() - { - m_countSuspendFocusTracking++; - m_localWindowsHook.HookInvoked -= m_hookEventHandler; - } - - public void ResumeFocusTracking() - { - if (m_countSuspendFocusTracking > 0) - m_countSuspendFocusTracking--; - - if (m_countSuspendFocusTracking == 0) - { - if (ContentActivating != null) - { - Activate(ContentActivating); - ContentActivating = null; - } - m_localWindowsHook.HookInvoked += m_hookEventHandler; - if (!InRefreshActiveWindow) - RefreshActiveWindow(); - } - } - - public bool IsFocusTrackingSuspended - { - get { return m_countSuspendFocusTracking != 0; } - } - - // Windows hook event handler - private void HookEventHandler(object sender, HookEventArgs e) - { - Win32.Msgs msg = (Win32.Msgs)Marshal.ReadInt32(e.lParam, IntPtr.Size * 3); - - if (msg == Win32.Msgs.WM_KILLFOCUS) - { - IntPtr wParam = Marshal.ReadIntPtr(e.lParam, IntPtr.Size * 2); - DockPane pane = GetPaneFromHandle(wParam); - if (pane == null) - RefreshActiveWindow(); - } - else if (msg == Win32.Msgs.WM_SETFOCUS) - RefreshActiveWindow(); - } - - private DockPane GetPaneFromHandle(IntPtr hWnd) - { - Control control = Control.FromChildHandle(hWnd); - - IDockContent content = null; - DockPane pane = null; - for (; control != null; control = control.Parent) - { - content = control as IDockContent; - if (content != null) - content.DockHandler.ActiveWindowHandle = hWnd; - - if (content != null && content.DockHandler.DockPanel == DockPanel) - return content.DockHandler.Pane; - - pane = control as DockPane; - if (pane != null && pane.DockPanel == DockPanel) - break; - } - - return pane; - } - - private bool m_inRefreshActiveWindow = false; - private bool InRefreshActiveWindow - { - get { return m_inRefreshActiveWindow; } - } - - private void RefreshActiveWindow() - { - SuspendFocusTracking(); - m_inRefreshActiveWindow = true; - - DockPane oldActivePane = ActivePane; - IDockContent oldActiveContent = ActiveContent; - IDockContent oldActiveDocument = ActiveDocument; - - SetActivePane(); - SetActiveContent(); - SetActiveDocumentPane(); - SetActiveDocument(); - DockPanel.AutoHideWindow.RefreshActivePane(); - - ResumeFocusTracking(); - m_inRefreshActiveWindow = false; - - if (oldActiveContent != ActiveContent) - DockPanel.OnActiveContentChanged(EventArgs.Empty); - if (oldActiveDocument != ActiveDocument) - DockPanel.OnActiveDocumentChanged(EventArgs.Empty); - if (oldActivePane != ActivePane) - DockPanel.OnActivePaneChanged(EventArgs.Empty); - } - - private DockPane m_activePane = null; - public DockPane ActivePane - { - get { return m_activePane; } - } - - private void SetActivePane() - { - DockPane value = GetPaneFromHandle(NativeMethods.GetFocus()); - if (m_activePane == value) - return; - - if (m_activePane != null) - m_activePane.SetIsActivated(false); - - m_activePane = value; - - if (m_activePane != null) - m_activePane.SetIsActivated(true); - } - - private IDockContent m_activeContent = null; - public IDockContent ActiveContent - { - get { return m_activeContent; } - } - - internal void SetActiveContent() - { - IDockContent value = ActivePane == null ? null : ActivePane.ActiveContent; - - if (m_activeContent == value) - return; - - if (m_activeContent != null) - m_activeContent.DockHandler.IsActivated = false; - - m_activeContent = value; - - if (m_activeContent != null) - { - m_activeContent.DockHandler.IsActivated = true; - if (!DockHelper.IsDockStateAutoHide((m_activeContent.DockHandler.DockState))) - AddLastToActiveList(m_activeContent); - } - } - - private DockPane m_activeDocumentPane = null; - public DockPane ActiveDocumentPane - { - get { return m_activeDocumentPane; } - } - - private void SetActiveDocumentPane() - { - DockPane value = null; - - if (ActivePane != null && ActivePane.DockState == DockState.Document) - value = ActivePane; - - if (value == null && DockPanel.DockWindows != null) - { - if (ActiveDocumentPane == null) - value = DockPanel.DockWindows[DockState.Document].DefaultPane; - else if (ActiveDocumentPane.DockPanel != DockPanel || ActiveDocumentPane.DockState != DockState.Document) - value = DockPanel.DockWindows[DockState.Document].DefaultPane; - else - value = ActiveDocumentPane; - } - - if (m_activeDocumentPane == value) - return; - - if (m_activeDocumentPane != null) - m_activeDocumentPane.SetIsActiveDocumentPane(false); - - m_activeDocumentPane = value; - - if (m_activeDocumentPane != null) - m_activeDocumentPane.SetIsActiveDocumentPane(true); - } - - private IDockContent m_activeDocument = null; - public IDockContent ActiveDocument - { - get { return m_activeDocument; } - } - - private void SetActiveDocument() - { - IDockContent value = ActiveDocumentPane == null ? null : ActiveDocumentPane.ActiveContent; - - if (m_activeDocument == value) - return; - - m_activeDocument = value; - } - } - - private IFocusManager FocusManager - { - get { return m_focusManager; } - } - - internal IContentFocusManager ContentFocusManager - { - get { return m_focusManager; } - } - - internal void SaveFocus() - { - DummyControl.Focus(); - } - - [Browsable(false)] - public IDockContent ActiveContent - { - get { return FocusManager.ActiveContent; } - } - - [Browsable(false)] - public DockPane ActivePane - { - get { return FocusManager.ActivePane; } - } - - [Browsable(false)] - public IDockContent ActiveDocument - { - get { return FocusManager.ActiveDocument; } - } - - [Browsable(false)] - public DockPane ActiveDocumentPane - { - get { return FocusManager.ActiveDocumentPane; } - } - - private static readonly object ActiveDocumentChangedEvent = new object(); - [LocalizedCategory("Category_PropertyChanged")] - [LocalizedDescription("DockPanel_ActiveDocumentChanged_Description")] - public event EventHandler ActiveDocumentChanged - { - add { Events.AddHandler(ActiveDocumentChangedEvent, value); } - remove { Events.RemoveHandler(ActiveDocumentChangedEvent, value); } - } - protected virtual void OnActiveDocumentChanged(EventArgs e) - { - EventHandler handler = (EventHandler)Events[ActiveDocumentChangedEvent]; - if (handler != null) - handler(this, e); - } - - private static readonly object ActiveContentChangedEvent = new object(); - [LocalizedCategory("Category_PropertyChanged")] - [LocalizedDescription("DockPanel_ActiveContentChanged_Description")] - public event EventHandler ActiveContentChanged - { - add { Events.AddHandler(ActiveContentChangedEvent, value); } - remove { Events.RemoveHandler(ActiveContentChangedEvent, value); } - } - protected void OnActiveContentChanged(EventArgs e) - { - EventHandler handler = (EventHandler)Events[ActiveContentChangedEvent]; - if (handler != null) - handler(this, e); - } - - private static readonly object ActivePaneChangedEvent = new object(); - [LocalizedCategory("Category_PropertyChanged")] - [LocalizedDescription("DockPanel_ActivePaneChanged_Description")] - public event EventHandler ActivePaneChanged - { - add { Events.AddHandler(ActivePaneChangedEvent, value); } - remove { Events.RemoveHandler(ActivePaneChangedEvent, value); } - } - protected virtual void OnActivePaneChanged(EventArgs e) - { - EventHandler handler = (EventHandler)Events[ActivePaneChangedEvent]; - if (handler != null) - handler(this, e); - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.MdiClientController.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.MdiClientController.cs deleted file mode 100644 index a167a927d6..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.MdiClientController.cs +++ /dev/null @@ -1,430 +0,0 @@ -using System; -using System.Drawing; -using System.Windows.Forms; -using System.ComponentModel; -using System.ComponentModel.Design; -using System.Runtime.InteropServices; - -namespace WeifenLuo.WinFormsUI.Docking -{ - partial class DockPanel - { - // This class comes from Jacob Slusser's MdiClientController class: - // http://www.codeproject.com/cs/miscctrl/mdiclientcontroller.asp - private class MdiClientController : NativeWindow, IComponent, IDisposable - { - private bool m_autoScroll = true; - private BorderStyle m_borderStyle = BorderStyle.Fixed3D; - private MdiClient m_mdiClient = null; - private Form m_parentForm = null; - private ISite m_site = null; - - public MdiClientController() - { - } - - public void Dispose() - { - Dispose(true); - GC.SuppressFinalize(this); - } - - protected virtual void Dispose(bool disposing) - { - if (disposing) - { - lock (this) - { - if (Site != null && Site.Container != null) - Site.Container.Remove(this); - - if (Disposed != null) - Disposed(this, EventArgs.Empty); - } - } - } - - public bool AutoScroll - { - get { return m_autoScroll; } - set - { - // By default the MdiClient control scrolls. It can appear though that - // there are no scrollbars by turning them off when the non-client - // area is calculated. I decided to expose this method following - // the .NET vernacular of an AutoScroll property. - m_autoScroll = value; - if (MdiClient != null) - UpdateStyles(); - } - } - - public BorderStyle BorderStyle - { - set - { - // Error-check the enum. - if (!Enum.IsDefined(typeof(BorderStyle), value)) - throw new InvalidEnumArgumentException(); - - m_borderStyle = value; - - if (MdiClient == null) - return; - - // This property can actually be visible in design-mode, - // but to keep it consistent with the others, - // prevent this from being show at design-time. - if (Site != null && Site.DesignMode) - return; - - // There is no BorderStyle property exposed by the MdiClient class, - // but this can be controlled by Win32 functions. A Win32 ExStyle - // of WS_EX_CLIENTEDGE is equivalent to a Fixed3D border and a - // Style of WS_BORDER is equivalent to a FixedSingle border. - - // This code is inspired Jason Dori's article: - // "Adding designable borders to user controls". - // http://www.codeproject.com/cs/miscctrl/CsAddingBorders.asp - - // Get styles using Win32 calls - int style = NativeMethods.GetWindowLong(MdiClient.Handle, (int)Win32.GetWindowLongIndex.GWL_STYLE); - int exStyle = NativeMethods.GetWindowLong(MdiClient.Handle, (int)Win32.GetWindowLongIndex.GWL_EXSTYLE); - - // Add or remove style flags as necessary. - switch (m_borderStyle) - { - case BorderStyle.Fixed3D: - exStyle |= (int)Win32.WindowExStyles.WS_EX_CLIENTEDGE; - style &= ~((int)Win32.WindowStyles.WS_BORDER); - break; - - case BorderStyle.FixedSingle: - exStyle &= ~((int)Win32.WindowExStyles.WS_EX_CLIENTEDGE); - style |= (int)Win32.WindowStyles.WS_BORDER; - break; - - case BorderStyle.None: - style &= ~((int)Win32.WindowStyles.WS_BORDER); - exStyle &= ~((int)Win32.WindowExStyles.WS_EX_CLIENTEDGE); - break; - } - - // Set the styles using Win32 calls - NativeMethods.SetWindowLong(MdiClient.Handle, (int)Win32.GetWindowLongIndex.GWL_STYLE, style); - NativeMethods.SetWindowLong(MdiClient.Handle, (int)Win32.GetWindowLongIndex.GWL_EXSTYLE, exStyle); - - // Cause an update of the non-client area. - UpdateStyles(); - } - } - - public MdiClient MdiClient - { - get { return m_mdiClient; } - } - - [Browsable(false)] - public Form ParentForm - { - get { return m_parentForm; } - set - { - // If the ParentForm has previously been set, - // unwire events connected to the old parent. - if (m_parentForm != null) - { - m_parentForm.HandleCreated -= new EventHandler(ParentFormHandleCreated); - m_parentForm.MdiChildActivate -= new EventHandler(ParentFormMdiChildActivate); - } - - m_parentForm = value; - - if (m_parentForm == null) - return; - - // If the parent form has not been created yet, - // wait to initialize the MDI client until it is. - if (m_parentForm.IsHandleCreated) - { - InitializeMdiClient(); - RefreshProperties(); - } - else - m_parentForm.HandleCreated += new EventHandler(ParentFormHandleCreated); - - m_parentForm.MdiChildActivate += new EventHandler(ParentFormMdiChildActivate); - } - } - - public ISite Site - { - get { return m_site; } - set - { - m_site = value; - - if (m_site == null) - return; - - // If the component is dropped onto a form during design-time, - // set the ParentForm property. - IDesignerHost host = (value.GetService(typeof(IDesignerHost)) as IDesignerHost); - if (host != null) - { - Form parent = host.RootComponent as Form; - if (parent != null) - ParentForm = parent; - } - } - } - - public void RenewMdiClient() - { - // Reinitialize the MdiClient and its properties. - InitializeMdiClient(); - RefreshProperties(); - } - - public event EventHandler Disposed; - - public event EventHandler HandleAssigned; - - public event EventHandler MdiChildActivate; - - public event LayoutEventHandler Layout; - - protected virtual void OnHandleAssigned(EventArgs e) - { - // Raise the HandleAssigned event. - if (HandleAssigned != null) - HandleAssigned(this, e); - } - - protected virtual void OnMdiChildActivate(EventArgs e) - { - // Raise the MdiChildActivate event - if (MdiChildActivate != null) - MdiChildActivate(this, e); - } - - protected virtual void OnLayout(LayoutEventArgs e) - { - // Raise the Layout event - if (Layout != null) - Layout(this, e); - } - - public event PaintEventHandler Paint; - - protected virtual void OnPaint(PaintEventArgs e) - { - // Raise the Paint event. - if (Paint != null) - Paint(this, e); - } - - protected override void WndProc(ref Message m) - { - switch (m.Msg) - { - case (int)Win32.Msgs.WM_NCCALCSIZE: - // If AutoScroll is set to false, hide the scrollbars when the control - // calculates its non-client area. - if (!AutoScroll) - NativeMethods.ShowScrollBar(m.HWnd, (int)Win32.ScrollBars.SB_BOTH, 0 /*false*/); - break; - } - - base.WndProc(ref m); - } - - private void ParentFormHandleCreated(object sender, EventArgs e) - { - // The form has been created, unwire the event, and initialize the MdiClient. - this.m_parentForm.HandleCreated -= new EventHandler(ParentFormHandleCreated); - InitializeMdiClient(); - RefreshProperties(); - } - - private void ParentFormMdiChildActivate(object sender, EventArgs e) - { - OnMdiChildActivate(e); - } - - private void MdiClientLayout(object sender, LayoutEventArgs e) - { - OnLayout(e); - } - - private void MdiClientHandleDestroyed(object sender, EventArgs e) - { - // If the MdiClient handle has been released, drop the reference and - // release the handle. - if (m_mdiClient != null) - { - m_mdiClient.HandleDestroyed -= new EventHandler(MdiClientHandleDestroyed); - m_mdiClient = null; - } - - ReleaseHandle(); - } - - private void InitializeMdiClient() - { - // If the mdiClient has previously been set, unwire events connected - // to the old MDI. - if (MdiClient != null) - { - MdiClient.HandleDestroyed -= new EventHandler(MdiClientHandleDestroyed); - MdiClient.Layout -= new LayoutEventHandler(MdiClientLayout); - } - - if (ParentForm == null) - return; - - // Get the MdiClient from the parent form. - foreach (Control control in ParentForm.Controls) - { - // If the form is an MDI container, it will contain an MdiClient control - // just as it would any other control. - - m_mdiClient = control as MdiClient; - if (m_mdiClient == null) - continue; - - // Assign the MdiClient Handle to the NativeWindow. - ReleaseHandle(); - AssignHandle(MdiClient.Handle); - - // Raise the HandleAssigned event. - OnHandleAssigned(EventArgs.Empty); - - // Monitor the MdiClient for when its handle is destroyed. - MdiClient.HandleDestroyed += new EventHandler(MdiClientHandleDestroyed); - MdiClient.Layout += new LayoutEventHandler(MdiClientLayout); - - break; - } - } - - private void RefreshProperties() - { - // Refresh all the properties - BorderStyle = m_borderStyle; - AutoScroll = m_autoScroll; - } - - private void UpdateStyles() - { - // To show style changes, the non-client area must be repainted. Using the - // control's Invalidate method does not affect the non-client area. - // Instead use a Win32 call to signal the style has changed. - NativeMethods.SetWindowPos(MdiClient.Handle, IntPtr.Zero, 0, 0, 0, 0, - Win32.FlagsSetWindowPos.SWP_NOACTIVATE | - Win32.FlagsSetWindowPos.SWP_NOMOVE | - Win32.FlagsSetWindowPos.SWP_NOSIZE | - Win32.FlagsSetWindowPos.SWP_NOZORDER | - Win32.FlagsSetWindowPos.SWP_NOOWNERZORDER | - Win32.FlagsSetWindowPos.SWP_FRAMECHANGED); - } - } - - private MdiClientController m_mdiClientController = null; - private MdiClientController GetMdiClientController() - { - if (m_mdiClientController == null) - { - m_mdiClientController = new MdiClientController(); - m_mdiClientController.HandleAssigned += new EventHandler(MdiClientHandleAssigned); - m_mdiClientController.MdiChildActivate += new EventHandler(ParentFormMdiChildActivate); - m_mdiClientController.Layout += new LayoutEventHandler(MdiClient_Layout); - } - - return m_mdiClientController; - } - - private void ParentFormMdiChildActivate(object sender, EventArgs e) - { - if (GetMdiClientController().ParentForm == null) - return; - - IDockContent content = GetMdiClientController().ParentForm.ActiveMdiChild as IDockContent; - if (content == null) - return; - - if (content.DockHandler.DockPanel == this && content.DockHandler.Pane != null) - content.DockHandler.Pane.ActiveContent = content; - } - - private bool MdiClientExists - { - get { return GetMdiClientController().MdiClient != null; } - } - - private void SetMdiClientBounds(Rectangle bounds) - { - GetMdiClientController().MdiClient.Bounds = bounds; - } - - private void SuspendMdiClientLayout() - { - if (GetMdiClientController().MdiClient != null) - GetMdiClientController().MdiClient.PerformLayout(); - } - - private void ResumeMdiClientLayout(bool perform) - { - if (GetMdiClientController().MdiClient != null) - GetMdiClientController().MdiClient.ResumeLayout(perform); - } - - private void PerformMdiClientLayout() - { - if (GetMdiClientController().MdiClient != null) - GetMdiClientController().MdiClient.PerformLayout(); - } - - // Called when: - // 1. DockPanel.DocumentStyle changed - // 2. DockPanel.Visible changed - // 3. MdiClientController.Handle assigned - private void SetMdiClient() - { - MdiClientController controller = GetMdiClientController(); - - if (this.DocumentStyle == DocumentStyle.DockingMdi) - { - controller.AutoScroll = false; - controller.BorderStyle = BorderStyle.None; - if (MdiClientExists) - controller.MdiClient.Dock = DockStyle.Fill; - } - else if (DocumentStyle == DocumentStyle.DockingSdi || DocumentStyle == DocumentStyle.DockingWindow) - { - controller.AutoScroll = true; - controller.BorderStyle = BorderStyle.Fixed3D; - if (MdiClientExists) - controller.MdiClient.Dock = DockStyle.Fill; - } - else if (this.DocumentStyle == DocumentStyle.SystemMdi) - { - controller.AutoScroll = true; - controller.BorderStyle = BorderStyle.Fixed3D; - if (controller.MdiClient != null) - { - controller.MdiClient.Dock = DockStyle.None; - controller.MdiClient.Bounds = SystemMdiClientBounds; - } - } - } - - internal Rectangle RectangleToMdiClient(Rectangle rect) - { - if (MdiClientExists) - return GetMdiClientController().MdiClient.RectangleToClient(rect); - else - return Rectangle.Empty; - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.Persistor.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.Persistor.cs deleted file mode 100644 index 5ecbc114d7..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.Persistor.cs +++ /dev/null @@ -1,780 +0,0 @@ -using System; -using System.ComponentModel; -using System.Windows.Forms; -using System.Drawing; -using WeifenLuo.WinFormsUI.Docking; -using System.IO; -using System.Text; -using System.Xml; -using System.Globalization; - -namespace WeifenLuo.WinFormsUI.Docking -{ - partial class DockPanel - { - private static class Persistor - { - private const string ConfigFileVersion = "1.0"; - private static string[] CompatibleConfigFileVersions = new string[] { }; - - private class DummyContent : DockContent - { - } - - private struct DockPanelStruct - { - private double m_dockLeftPortion; - public double DockLeftPortion - { - get { return m_dockLeftPortion; } - set { m_dockLeftPortion = value; } - } - - private double m_dockRightPortion; - public double DockRightPortion - { - get { return m_dockRightPortion; } - set { m_dockRightPortion = value; } - } - - private double m_dockTopPortion; - public double DockTopPortion - { - get { return m_dockTopPortion; } - set { m_dockTopPortion = value; } - } - - private double m_dockBottomPortion; - public double DockBottomPortion - { - get { return m_dockBottomPortion; } - set { m_dockBottomPortion = value; } - } - - private int m_indexActiveDocumentPane; - public int IndexActiveDocumentPane - { - get { return m_indexActiveDocumentPane; } - set { m_indexActiveDocumentPane = value; } - } - - private int m_indexActivePane; - public int IndexActivePane - { - get { return m_indexActivePane; } - set { m_indexActivePane = value; } - } - } - - private struct ContentStruct - { - private string m_persistString; - public string PersistString - { - get { return m_persistString; } - set { m_persistString = value; } - } - - private double m_autoHidePortion; - public double AutoHidePortion - { - get { return m_autoHidePortion; } - set { m_autoHidePortion = value; } - } - - private bool m_isHidden; - public bool IsHidden - { - get { return m_isHidden; } - set { m_isHidden = value; } - } - - private bool m_isFloat; - public bool IsFloat - { - get { return m_isFloat; } - set { m_isFloat = value; } - } - } - - private struct PaneStruct - { - private DockState m_dockState; - public DockState DockState - { - get { return m_dockState; } - set { m_dockState = value; } - } - - private int m_indexActiveContent; - public int IndexActiveContent - { - get { return m_indexActiveContent; } - set { m_indexActiveContent = value; } - } - - private int[] m_indexContents; - public int[] IndexContents - { - get { return m_indexContents; } - set { m_indexContents = value; } - } - - private int m_zOrderIndex; - public int ZOrderIndex - { - get { return m_zOrderIndex; } - set { m_zOrderIndex = value; } - } - } - - private struct NestedPane - { - private int m_indexPane; - public int IndexPane - { - get { return m_indexPane; } - set { m_indexPane = value; } - } - - private int m_indexPrevPane; - public int IndexPrevPane - { - get { return m_indexPrevPane; } - set { m_indexPrevPane = value; } - } - - private DockAlignment m_alignment; - public DockAlignment Alignment - { - get { return m_alignment; } - set { m_alignment = value; } - } - - private double m_proportion; - public double Proportion - { - get { return m_proportion; } - set { m_proportion = value; } - } - } - - private struct DockWindowStruct - { - private DockState m_dockState; - public DockState DockState - { - get { return m_dockState; } - set { m_dockState = value; } - } - - private int m_zOrderIndex; - public int ZOrderIndex - { - get { return m_zOrderIndex; } - set { m_zOrderIndex = value; } - } - - private NestedPane[] m_nestedPanes; - public NestedPane[] NestedPanes - { - get { return m_nestedPanes; } - set { m_nestedPanes = value; } - } - } - - private struct FloatWindowStruct - { - private Rectangle m_bounds; - public Rectangle Bounds - { - get { return m_bounds; } - set { m_bounds = value; } - } - - private int m_zOrderIndex; - public int ZOrderIndex - { - get { return m_zOrderIndex; } - set { m_zOrderIndex = value; } - } - - private NestedPane[] m_nestedPanes; - public NestedPane[] NestedPanes - { - get { return m_nestedPanes; } - set { m_nestedPanes = value; } - } - } - - public static void SaveAsXml(DockPanel dockPanel, string fileName) - { - SaveAsXml(dockPanel, fileName, Encoding.Unicode); - } - - public static void SaveAsXml(DockPanel dockPanel, string fileName, Encoding encoding) - { - FileStream fs = new FileStream(fileName, FileMode.Create); - try - { - SaveAsXml(dockPanel, fs, encoding); - } - finally - { - fs.Close(); - } - } - - public static void SaveAsXml(DockPanel dockPanel, Stream stream, Encoding encoding) - { - SaveAsXml(dockPanel, stream, encoding, false); - } - - public static void SaveAsXml(DockPanel dockPanel, Stream stream, Encoding encoding, bool upstream) - { - XmlTextWriter xmlOut = new XmlTextWriter(stream, encoding); - - // Use indenting for readability - xmlOut.Formatting = Formatting.Indented; - - if (!upstream) - xmlOut.WriteStartDocument(); - - // Always begin file with identification and warning - xmlOut.WriteComment(Strings.DockPanel_Persistor_XmlFileComment1); - xmlOut.WriteComment(Strings.DockPanel_Persistor_XmlFileComment2); - - // Associate a version number with the root element so that future version of the code - // will be able to be backwards compatible or at least recognise out of date versions - xmlOut.WriteStartElement("DockPanel"); - xmlOut.WriteAttributeString("FormatVersion", ConfigFileVersion); - xmlOut.WriteAttributeString("DockLeftPortion", dockPanel.DockLeftPortion.ToString(CultureInfo.InvariantCulture)); - xmlOut.WriteAttributeString("DockRightPortion", dockPanel.DockRightPortion.ToString(CultureInfo.InvariantCulture)); - xmlOut.WriteAttributeString("DockTopPortion", dockPanel.DockTopPortion.ToString(CultureInfo.InvariantCulture)); - xmlOut.WriteAttributeString("DockBottomPortion", dockPanel.DockBottomPortion.ToString(CultureInfo.InvariantCulture)); - xmlOut.WriteAttributeString("ActiveDocumentPane", dockPanel.Panes.IndexOf(dockPanel.ActiveDocumentPane).ToString(CultureInfo.InvariantCulture)); - xmlOut.WriteAttributeString("ActivePane", dockPanel.Panes.IndexOf(dockPanel.ActivePane).ToString(CultureInfo.InvariantCulture)); - - // Contents - xmlOut.WriteStartElement("Contents"); - xmlOut.WriteAttributeString("Count", dockPanel.Contents.Count.ToString(CultureInfo.InvariantCulture)); - foreach (IDockContent content in dockPanel.Contents) - { - xmlOut.WriteStartElement("Content"); - xmlOut.WriteAttributeString("ID", dockPanel.Contents.IndexOf(content).ToString(CultureInfo.InvariantCulture)); - xmlOut.WriteAttributeString("PersistString", content.DockHandler.PersistString); - xmlOut.WriteAttributeString("AutoHidePortion", content.DockHandler.AutoHidePortion.ToString(CultureInfo.InvariantCulture)); - xmlOut.WriteAttributeString("IsHidden", content.DockHandler.IsHidden.ToString(CultureInfo.InvariantCulture)); - xmlOut.WriteAttributeString("IsFloat", content.DockHandler.IsFloat.ToString(CultureInfo.InvariantCulture)); - xmlOut.WriteEndElement(); - } - xmlOut.WriteEndElement(); - - // Panes - xmlOut.WriteStartElement("Panes"); - xmlOut.WriteAttributeString("Count", dockPanel.Panes.Count.ToString(CultureInfo.InvariantCulture)); - foreach (DockPane pane in dockPanel.Panes) - { - xmlOut.WriteStartElement("Pane"); - xmlOut.WriteAttributeString("ID", dockPanel.Panes.IndexOf(pane).ToString(CultureInfo.InvariantCulture)); - xmlOut.WriteAttributeString("DockState", pane.DockState.ToString()); - xmlOut.WriteAttributeString("ActiveContent", dockPanel.Contents.IndexOf(pane.ActiveContent).ToString(CultureInfo.InvariantCulture)); - xmlOut.WriteStartElement("Contents"); - xmlOut.WriteAttributeString("Count", pane.Contents.Count.ToString(CultureInfo.InvariantCulture)); - foreach (IDockContent content in pane.Contents) - { - xmlOut.WriteStartElement("Content"); - xmlOut.WriteAttributeString("ID", pane.Contents.IndexOf(content).ToString(CultureInfo.InvariantCulture)); - xmlOut.WriteAttributeString("RefID", dockPanel.Contents.IndexOf(content).ToString(CultureInfo.InvariantCulture)); - xmlOut.WriteEndElement(); - } - xmlOut.WriteEndElement(); - xmlOut.WriteEndElement(); - } - xmlOut.WriteEndElement(); - - // DockWindows - xmlOut.WriteStartElement("DockWindows"); - int dockWindowId = 0; - foreach (DockWindow dw in dockPanel.DockWindows) - { - xmlOut.WriteStartElement("DockWindow"); - xmlOut.WriteAttributeString("ID", dockWindowId.ToString(CultureInfo.InvariantCulture)); - dockWindowId++; - xmlOut.WriteAttributeString("DockState", dw.DockState.ToString()); - xmlOut.WriteAttributeString("ZOrderIndex", dockPanel.Controls.IndexOf(dw).ToString(CultureInfo.InvariantCulture)); - xmlOut.WriteStartElement("NestedPanes"); - xmlOut.WriteAttributeString("Count", dw.NestedPanes.Count.ToString(CultureInfo.InvariantCulture)); - foreach (DockPane pane in dw.NestedPanes) - { - xmlOut.WriteStartElement("Pane"); - xmlOut.WriteAttributeString("ID", dw.NestedPanes.IndexOf(pane).ToString(CultureInfo.InvariantCulture)); - xmlOut.WriteAttributeString("RefID", dockPanel.Panes.IndexOf(pane).ToString(CultureInfo.InvariantCulture)); - NestedDockingStatus status = pane.NestedDockingStatus; - xmlOut.WriteAttributeString("PrevPane", dockPanel.Panes.IndexOf(status.PreviousPane).ToString(CultureInfo.InvariantCulture)); - xmlOut.WriteAttributeString("Alignment", status.Alignment.ToString()); - xmlOut.WriteAttributeString("Proportion", status.Proportion.ToString(CultureInfo.InvariantCulture)); - xmlOut.WriteEndElement(); - } - xmlOut.WriteEndElement(); - xmlOut.WriteEndElement(); - } - xmlOut.WriteEndElement(); - - // FloatWindows - RectangleConverter rectConverter = new RectangleConverter(); - xmlOut.WriteStartElement("FloatWindows"); - xmlOut.WriteAttributeString("Count", dockPanel.FloatWindows.Count.ToString(CultureInfo.InvariantCulture)); - foreach (FloatWindow fw in dockPanel.FloatWindows) - { - xmlOut.WriteStartElement("FloatWindow"); - xmlOut.WriteAttributeString("ID", dockPanel.FloatWindows.IndexOf(fw).ToString(CultureInfo.InvariantCulture)); - xmlOut.WriteAttributeString("Bounds", rectConverter.ConvertToInvariantString(fw.Bounds)); - xmlOut.WriteAttributeString("ZOrderIndex", fw.DockPanel.FloatWindows.IndexOf(fw).ToString(CultureInfo.InvariantCulture)); - xmlOut.WriteStartElement("NestedPanes"); - xmlOut.WriteAttributeString("Count", fw.NestedPanes.Count.ToString(CultureInfo.InvariantCulture)); - foreach (DockPane pane in fw.NestedPanes) - { - xmlOut.WriteStartElement("Pane"); - xmlOut.WriteAttributeString("ID", fw.NestedPanes.IndexOf(pane).ToString(CultureInfo.InvariantCulture)); - xmlOut.WriteAttributeString("RefID", dockPanel.Panes.IndexOf(pane).ToString(CultureInfo.InvariantCulture)); - NestedDockingStatus status = pane.NestedDockingStatus; - xmlOut.WriteAttributeString("PrevPane", dockPanel.Panes.IndexOf(status.PreviousPane).ToString(CultureInfo.InvariantCulture)); - xmlOut.WriteAttributeString("Alignment", status.Alignment.ToString()); - xmlOut.WriteAttributeString("Proportion", status.Proportion.ToString(CultureInfo.InvariantCulture)); - xmlOut.WriteEndElement(); - } - xmlOut.WriteEndElement(); - xmlOut.WriteEndElement(); - } - xmlOut.WriteEndElement(); // - - xmlOut.WriteEndElement(); - - if (!upstream) - { - xmlOut.WriteEndDocument(); - xmlOut.Close(); - } - else - xmlOut.Flush(); - } - - public static void LoadFromXml(DockPanel dockPanel, string fileName, DeserializeDockContent deserializeContent) - { - FileStream fs = new FileStream(fileName, FileMode.Open, FileAccess.Read); - try - { - LoadFromXml(dockPanel, fs, deserializeContent); - } - finally - { - fs.Close(); - } - } - - public static void LoadFromXml(DockPanel dockPanel, Stream stream, DeserializeDockContent deserializeContent) - { - LoadFromXml(dockPanel, stream, deserializeContent, true); - } - - private static ContentStruct[] LoadContents(XmlTextReader xmlIn) - { - int countOfContents = Convert.ToInt32(xmlIn.GetAttribute("Count"), CultureInfo.InvariantCulture); - ContentStruct[] contents = new ContentStruct[countOfContents]; - MoveToNextElement(xmlIn); - for (int i = 0; i < countOfContents; i++) - { - int id = Convert.ToInt32(xmlIn.GetAttribute("ID"), CultureInfo.InvariantCulture); - if (xmlIn.Name != "Content" || id != i) - throw new ArgumentException(Strings.DockPanel_LoadFromXml_InvalidXmlFormat); - - contents[i].PersistString = xmlIn.GetAttribute("PersistString"); - contents[i].AutoHidePortion = Convert.ToDouble(xmlIn.GetAttribute("AutoHidePortion"), CultureInfo.InvariantCulture); - contents[i].IsHidden = Convert.ToBoolean(xmlIn.GetAttribute("IsHidden"), CultureInfo.InvariantCulture); - contents[i].IsFloat = Convert.ToBoolean(xmlIn.GetAttribute("IsFloat"), CultureInfo.InvariantCulture); - MoveToNextElement(xmlIn); - } - - return contents; - } - - private static PaneStruct[] LoadPanes(XmlTextReader xmlIn) - { - EnumConverter dockStateConverter = new EnumConverter(typeof(DockState)); - int countOfPanes = Convert.ToInt32(xmlIn.GetAttribute("Count"), CultureInfo.InvariantCulture); - PaneStruct[] panes = new PaneStruct[countOfPanes]; - MoveToNextElement(xmlIn); - for (int i = 0; i < countOfPanes; i++) - { - int id = Convert.ToInt32(xmlIn.GetAttribute("ID"), CultureInfo.InvariantCulture); - if (xmlIn.Name != "Pane" || id != i) - throw new ArgumentException(Strings.DockPanel_LoadFromXml_InvalidXmlFormat); - - panes[i].DockState = (DockState)dockStateConverter.ConvertFrom(xmlIn.GetAttribute("DockState")); - panes[i].IndexActiveContent = Convert.ToInt32(xmlIn.GetAttribute("ActiveContent"), CultureInfo.InvariantCulture); - panes[i].ZOrderIndex = -1; - - MoveToNextElement(xmlIn); - if (xmlIn.Name != "Contents") - throw new ArgumentException(Strings.DockPanel_LoadFromXml_InvalidXmlFormat); - int countOfPaneContents = Convert.ToInt32(xmlIn.GetAttribute("Count"), CultureInfo.InvariantCulture); - panes[i].IndexContents = new int[countOfPaneContents]; - MoveToNextElement(xmlIn); - for (int j = 0; j < countOfPaneContents; j++) - { - int id2 = Convert.ToInt32(xmlIn.GetAttribute("ID"), CultureInfo.InvariantCulture); - if (xmlIn.Name != "Content" || id2 != j) - throw new ArgumentException(Strings.DockPanel_LoadFromXml_InvalidXmlFormat); - - panes[i].IndexContents[j] = Convert.ToInt32(xmlIn.GetAttribute("RefID"), CultureInfo.InvariantCulture); - MoveToNextElement(xmlIn); - } - } - - return panes; - } - - private static DockWindowStruct[] LoadDockWindows(XmlTextReader xmlIn, DockPanel dockPanel) - { - EnumConverter dockStateConverter = new EnumConverter(typeof(DockState)); - EnumConverter dockAlignmentConverter = new EnumConverter(typeof(DockAlignment)); - int countOfDockWindows = dockPanel.DockWindows.Count; - DockWindowStruct[] dockWindows = new DockWindowStruct[countOfDockWindows]; - MoveToNextElement(xmlIn); - for (int i = 0; i < countOfDockWindows; i++) - { - int id = Convert.ToInt32(xmlIn.GetAttribute("ID"), CultureInfo.InvariantCulture); - if (xmlIn.Name != "DockWindow" || id != i) - throw new ArgumentException(Strings.DockPanel_LoadFromXml_InvalidXmlFormat); - - dockWindows[i].DockState = (DockState)dockStateConverter.ConvertFrom(xmlIn.GetAttribute("DockState")); - dockWindows[i].ZOrderIndex = Convert.ToInt32(xmlIn.GetAttribute("ZOrderIndex"), CultureInfo.InvariantCulture); - MoveToNextElement(xmlIn); - if (xmlIn.Name != "DockList" && xmlIn.Name != "NestedPanes") - throw new ArgumentException(Strings.DockPanel_LoadFromXml_InvalidXmlFormat); - int countOfNestedPanes = Convert.ToInt32(xmlIn.GetAttribute("Count"), CultureInfo.InvariantCulture); - dockWindows[i].NestedPanes = new NestedPane[countOfNestedPanes]; - MoveToNextElement(xmlIn); - for (int j = 0; j < countOfNestedPanes; j++) - { - int id2 = Convert.ToInt32(xmlIn.GetAttribute("ID"), CultureInfo.InvariantCulture); - if (xmlIn.Name != "Pane" || id2 != j) - throw new ArgumentException(Strings.DockPanel_LoadFromXml_InvalidXmlFormat); - dockWindows[i].NestedPanes[j].IndexPane = Convert.ToInt32(xmlIn.GetAttribute("RefID"), CultureInfo.InvariantCulture); - dockWindows[i].NestedPanes[j].IndexPrevPane = Convert.ToInt32(xmlIn.GetAttribute("PrevPane"), CultureInfo.InvariantCulture); - dockWindows[i].NestedPanes[j].Alignment = (DockAlignment)dockAlignmentConverter.ConvertFrom(xmlIn.GetAttribute("Alignment")); - dockWindows[i].NestedPanes[j].Proportion = Convert.ToDouble(xmlIn.GetAttribute("Proportion"), CultureInfo.InvariantCulture); - MoveToNextElement(xmlIn); - } - } - - return dockWindows; - } - - private static FloatWindowStruct[] LoadFloatWindows(XmlTextReader xmlIn) - { - EnumConverter dockAlignmentConverter = new EnumConverter(typeof(DockAlignment)); - RectangleConverter rectConverter = new RectangleConverter(); - int countOfFloatWindows = Convert.ToInt32(xmlIn.GetAttribute("Count"), CultureInfo.InvariantCulture); - FloatWindowStruct[] floatWindows = new FloatWindowStruct[countOfFloatWindows]; - MoveToNextElement(xmlIn); - for (int i = 0; i < countOfFloatWindows; i++) - { - int id = Convert.ToInt32(xmlIn.GetAttribute("ID"), CultureInfo.InvariantCulture); - if (xmlIn.Name != "FloatWindow" || id != i) - throw new ArgumentException(Strings.DockPanel_LoadFromXml_InvalidXmlFormat); - - floatWindows[i].Bounds = (Rectangle)rectConverter.ConvertFromInvariantString(xmlIn.GetAttribute("Bounds")); - floatWindows[i].ZOrderIndex = Convert.ToInt32(xmlIn.GetAttribute("ZOrderIndex"), CultureInfo.InvariantCulture); - MoveToNextElement(xmlIn); - if (xmlIn.Name != "DockList" && xmlIn.Name != "NestedPanes") - throw new ArgumentException(Strings.DockPanel_LoadFromXml_InvalidXmlFormat); - int countOfNestedPanes = Convert.ToInt32(xmlIn.GetAttribute("Count"), CultureInfo.InvariantCulture); - floatWindows[i].NestedPanes = new NestedPane[countOfNestedPanes]; - MoveToNextElement(xmlIn); - for (int j = 0; j < countOfNestedPanes; j++) - { - int id2 = Convert.ToInt32(xmlIn.GetAttribute("ID"), CultureInfo.InvariantCulture); - if (xmlIn.Name != "Pane" || id2 != j) - throw new ArgumentException(Strings.DockPanel_LoadFromXml_InvalidXmlFormat); - floatWindows[i].NestedPanes[j].IndexPane = Convert.ToInt32(xmlIn.GetAttribute("RefID"), CultureInfo.InvariantCulture); - floatWindows[i].NestedPanes[j].IndexPrevPane = Convert.ToInt32(xmlIn.GetAttribute("PrevPane"), CultureInfo.InvariantCulture); - floatWindows[i].NestedPanes[j].Alignment = (DockAlignment)dockAlignmentConverter.ConvertFrom(xmlIn.GetAttribute("Alignment")); - floatWindows[i].NestedPanes[j].Proportion = Convert.ToDouble(xmlIn.GetAttribute("Proportion"), CultureInfo.InvariantCulture); - MoveToNextElement(xmlIn); - } - } - - return floatWindows; - } - - public static void LoadFromXml(DockPanel dockPanel, Stream stream, DeserializeDockContent deserializeContent, bool closeStream) - { - - if (dockPanel.Contents.Count != 0) - throw new InvalidOperationException(Strings.DockPanel_LoadFromXml_AlreadyInitialized); - - XmlTextReader xmlIn = new XmlTextReader(stream); - xmlIn.WhitespaceHandling = WhitespaceHandling.None; - xmlIn.MoveToContent(); - - while (!xmlIn.Name.Equals("DockPanel")) - { - if (!MoveToNextElement(xmlIn)) - throw new ArgumentException(Strings.DockPanel_LoadFromXml_InvalidXmlFormat); - } - - string formatVersion = xmlIn.GetAttribute("FormatVersion"); - if (!IsFormatVersionValid(formatVersion)) - throw new ArgumentException(Strings.DockPanel_LoadFromXml_InvalidFormatVersion); - - DockPanelStruct dockPanelStruct = new DockPanelStruct(); - dockPanelStruct.DockLeftPortion = Convert.ToDouble(xmlIn.GetAttribute("DockLeftPortion"), CultureInfo.InvariantCulture); - dockPanelStruct.DockRightPortion = Convert.ToDouble(xmlIn.GetAttribute("DockRightPortion"), CultureInfo.InvariantCulture); - dockPanelStruct.DockTopPortion = Convert.ToDouble(xmlIn.GetAttribute("DockTopPortion"), CultureInfo.InvariantCulture); - dockPanelStruct.DockBottomPortion = Convert.ToDouble(xmlIn.GetAttribute("DockBottomPortion"), CultureInfo.InvariantCulture); - dockPanelStruct.IndexActiveDocumentPane = Convert.ToInt32(xmlIn.GetAttribute("ActiveDocumentPane"), CultureInfo.InvariantCulture); - dockPanelStruct.IndexActivePane = Convert.ToInt32(xmlIn.GetAttribute("ActivePane"), CultureInfo.InvariantCulture); - - // Load Contents - MoveToNextElement(xmlIn); - if (xmlIn.Name != "Contents") - throw new ArgumentException(Strings.DockPanel_LoadFromXml_InvalidXmlFormat); - ContentStruct[] contents = LoadContents(xmlIn); - - // Load Panes - if (xmlIn.Name != "Panes") - throw new ArgumentException(Strings.DockPanel_LoadFromXml_InvalidXmlFormat); - PaneStruct[] panes = LoadPanes(xmlIn); - - // Load DockWindows - if (xmlIn.Name != "DockWindows") - throw new ArgumentException(Strings.DockPanel_LoadFromXml_InvalidXmlFormat); - DockWindowStruct[] dockWindows = LoadDockWindows(xmlIn, dockPanel); - - // Load FloatWindows - if (xmlIn.Name != "FloatWindows") - throw new ArgumentException(Strings.DockPanel_LoadFromXml_InvalidXmlFormat); - FloatWindowStruct[] floatWindows = LoadFloatWindows(xmlIn); - - if (closeStream) - xmlIn.Close(); - - dockPanel.SuspendLayout(true); - - dockPanel.DockLeftPortion = dockPanelStruct.DockLeftPortion; - dockPanel.DockRightPortion = dockPanelStruct.DockRightPortion; - dockPanel.DockTopPortion = dockPanelStruct.DockTopPortion; - dockPanel.DockBottomPortion = dockPanelStruct.DockBottomPortion; - - // Set DockWindow ZOrders - int prevMaxDockWindowZOrder = int.MaxValue; - for (int i = 0; i < dockWindows.Length; i++) - { - int maxDockWindowZOrder = -1; - int index = -1; - for (int j = 0; j < dockWindows.Length; j++) - { - if (dockWindows[j].ZOrderIndex > maxDockWindowZOrder && dockWindows[j].ZOrderIndex < prevMaxDockWindowZOrder) - { - maxDockWindowZOrder = dockWindows[j].ZOrderIndex; - index = j; - } - } - - dockPanel.DockWindows[dockWindows[index].DockState].BringToFront(); - prevMaxDockWindowZOrder = maxDockWindowZOrder; - } - - // Create Contents - for (int i = 0; i < contents.Length; i++) - { - IDockContent content = deserializeContent(contents[i].PersistString); - if (content == null) - content = new DummyContent(); - content.DockHandler.DockPanel = dockPanel; - content.DockHandler.AutoHidePortion = contents[i].AutoHidePortion; - content.DockHandler.IsHidden = true; - content.DockHandler.IsFloat = contents[i].IsFloat; - } - - // Create panes - for (int i = 0; i < panes.Length; i++) - { - DockPane pane = null; - for (int j = 0; j < panes[i].IndexContents.Length; j++) - { - IDockContent content = dockPanel.Contents[panes[i].IndexContents[j]]; - if (j == 0) - pane = dockPanel.DockPaneFactory.CreateDockPane(content, panes[i].DockState, false); - else if (panes[i].DockState == DockState.Float) - content.DockHandler.FloatPane = pane; - else - content.DockHandler.PanelPane = pane; - } - } - - // Assign Panes to DockWindows - for (int i = 0; i < dockWindows.Length; i++) - { - for (int j = 0; j < dockWindows[i].NestedPanes.Length; j++) - { - DockWindow dw = dockPanel.DockWindows[dockWindows[i].DockState]; - int indexPane = dockWindows[i].NestedPanes[j].IndexPane; - DockPane pane = dockPanel.Panes[indexPane]; - int indexPrevPane = dockWindows[i].NestedPanes[j].IndexPrevPane; - DockPane prevPane = (indexPrevPane == -1) ? dw.NestedPanes.GetDefaultPreviousPane(pane) : dockPanel.Panes[indexPrevPane]; - DockAlignment alignment = dockWindows[i].NestedPanes[j].Alignment; - double proportion = dockWindows[i].NestedPanes[j].Proportion; - pane.DockTo(dw, prevPane, alignment, proportion); - if (panes[indexPane].DockState == dw.DockState) - panes[indexPane].ZOrderIndex = dockWindows[i].ZOrderIndex; - } - } - - // Create float windows - for (int i = 0; i < floatWindows.Length; i++) - { - FloatWindow fw = null; - for (int j = 0; j < floatWindows[i].NestedPanes.Length; j++) - { - int indexPane = floatWindows[i].NestedPanes[j].IndexPane; - DockPane pane = dockPanel.Panes[indexPane]; - if (j == 0) - fw = dockPanel.FloatWindowFactory.CreateFloatWindow(dockPanel, pane, floatWindows[i].Bounds); - else - { - int indexPrevPane = floatWindows[i].NestedPanes[j].IndexPrevPane; - DockPane prevPane = indexPrevPane == -1 ? null : dockPanel.Panes[indexPrevPane]; - DockAlignment alignment = floatWindows[i].NestedPanes[j].Alignment; - double proportion = floatWindows[i].NestedPanes[j].Proportion; - pane.DockTo(fw, prevPane, alignment, proportion); - if (panes[indexPane].DockState == fw.DockState) - panes[indexPane].ZOrderIndex = floatWindows[i].ZOrderIndex; - } - } - } - - // sort IDockContent by its Pane's ZOrder - int[] sortedContents = null; - if (contents.Length > 0) - { - sortedContents = new int[contents.Length]; - for (int i = 0; i < contents.Length; i++) - sortedContents[i] = i; - - int lastDocument = contents.Length; - for (int i = 0; i < contents.Length - 1; i++) - { - for (int j = i + 1; j < contents.Length; j++) - { - DockPane pane1 = dockPanel.Contents[sortedContents[i]].DockHandler.Pane; - int ZOrderIndex1 = pane1 == null ? 0 : panes[dockPanel.Panes.IndexOf(pane1)].ZOrderIndex; - DockPane pane2 = dockPanel.Contents[sortedContents[j]].DockHandler.Pane; - int ZOrderIndex2 = pane2 == null ? 0 : panes[dockPanel.Panes.IndexOf(pane2)].ZOrderIndex; - if (ZOrderIndex1 > ZOrderIndex2) - { - int temp = sortedContents[i]; - sortedContents[i] = sortedContents[j]; - sortedContents[j] = temp; - } - } - } - } - - // show non-document IDockContent first to avoid screen flickers - for (int i = 0; i < contents.Length; i++) - { - IDockContent content = dockPanel.Contents[sortedContents[i]]; - if (content.DockHandler.Pane != null && content.DockHandler.Pane.DockState != DockState.Document) - content.DockHandler.IsHidden = contents[sortedContents[i]].IsHidden; - } - - // after all non-document IDockContent, show document IDockContent - for (int i = 0; i < contents.Length; i++) - { - IDockContent content = dockPanel.Contents[sortedContents[i]]; - if (content.DockHandler.Pane != null && content.DockHandler.Pane.DockState == DockState.Document) - content.DockHandler.IsHidden = contents[sortedContents[i]].IsHidden; - } - - for (int i = 0; i < panes.Length; i++) - dockPanel.Panes[i].ActiveContent = panes[i].IndexActiveContent == -1 ? null : dockPanel.Contents[panes[i].IndexActiveContent]; - - if (dockPanelStruct.IndexActiveDocumentPane != -1) - dockPanel.Panes[dockPanelStruct.IndexActiveDocumentPane].Activate(); - - if (dockPanelStruct.IndexActivePane != -1) - dockPanel.Panes[dockPanelStruct.IndexActivePane].Activate(); - - for (int i = dockPanel.Contents.Count - 1; i >= 0; i--) - if (dockPanel.Contents[i] is DummyContent) - dockPanel.Contents[i].DockHandler.Form.Close(); - - dockPanel.ResumeLayout(true, true); - } - - private static bool MoveToNextElement(XmlTextReader xmlIn) - { - if (!xmlIn.Read()) - return false; - - while (xmlIn.NodeType == XmlNodeType.EndElement) - { - if (!xmlIn.Read()) - return false; - } - - return true; - } - - private static bool IsFormatVersionValid(string formatVersion) - { - if (formatVersion == ConfigFileVersion) - return true; - - foreach (string s in CompatibleConfigFileVersions) - if (s == formatVersion) - return true; - - return false; - } - } - - public void SaveAsXml(string fileName) - { - Persistor.SaveAsXml(this, fileName); - } - - public void SaveAsXml(string fileName, Encoding encoding) - { - Persistor.SaveAsXml(this, fileName, encoding); - } - - public void SaveAsXml(Stream stream, Encoding encoding) - { - Persistor.SaveAsXml(this, stream, encoding); - } - - public void SaveAsXml(Stream stream, Encoding encoding, bool upstream) - { - Persistor.SaveAsXml(this, stream, encoding, upstream); - } - - public void LoadFromXml(string fileName, DeserializeDockContent deserializeContent) - { - Persistor.LoadFromXml(this, fileName, deserializeContent); - } - - public void LoadFromXml(Stream stream, DeserializeDockContent deserializeContent) - { - Persistor.LoadFromXml(this, stream, deserializeContent); - } - - public void LoadFromXml(Stream stream, DeserializeDockContent deserializeContent, bool closeStream) - { - Persistor.LoadFromXml(this, stream, deserializeContent, closeStream); - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.SplitterDragHandler.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.SplitterDragHandler.cs deleted file mode 100644 index 8689e166fd..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.SplitterDragHandler.cs +++ /dev/null @@ -1,165 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Text; -using System.Windows.Forms; -using System.Drawing; -using System.Drawing.Drawing2D; -using System.ComponentModel; - -namespace WeifenLuo.WinFormsUI.Docking -{ - partial class DockPanel - { - private sealed class SplitterDragHandler : DragHandler - { - private class SplitterOutline - { - public SplitterOutline() - { - m_dragForm = new DragForm(); - SetDragForm(Rectangle.Empty); - DragForm.BackColor = Color.Black; - DragForm.Opacity = 0.7; - DragForm.Show(false); - } - - DragForm m_dragForm; - private DragForm DragForm - { - get { return m_dragForm; } - } - - public void Show(Rectangle rect) - { - SetDragForm(rect); - } - - public void Close() - { - DragForm.Close(); - } - - private void SetDragForm(Rectangle rect) - { - DragForm.Bounds = rect; - if (rect == Rectangle.Empty) - DragForm.Region = new Region(Rectangle.Empty); - else if (DragForm.Region != null) - DragForm.Region = null; - } - } - - public SplitterDragHandler(DockPanel dockPanel) - : base(dockPanel) - { - } - - public new ISplitterDragSource DragSource - { - get { return base.DragSource as ISplitterDragSource; } - private set { base.DragSource = value; } - } - - private SplitterOutline m_outline; - private SplitterOutline Outline - { - get { return m_outline; } - set { m_outline = value; } - } - - private Rectangle m_rectSplitter; - private Rectangle RectSplitter - { - get { return m_rectSplitter; } - set { m_rectSplitter = value; } - } - - public void BeginDrag(ISplitterDragSource dragSource, Rectangle rectSplitter) - { - DragSource = dragSource; - RectSplitter = rectSplitter; - - if (!BeginDrag()) - { - DragSource = null; - return; - } - - Outline = new SplitterOutline(); - Outline.Show(rectSplitter); - DragSource.BeginDrag(rectSplitter); - } - - protected override void OnDragging() - { - Outline.Show(GetSplitterOutlineBounds(Control.MousePosition)); - } - - protected override void OnEndDrag(bool abort) - { - DockPanel.SuspendLayout(true); - - Outline.Close(); - - if (!abort) - DragSource.MoveSplitter(GetMovingOffset(Control.MousePosition)); - - DragSource.EndDrag(); - DockPanel.ResumeLayout(true, true); - } - - private int GetMovingOffset(Point ptMouse) - { - Rectangle rect = GetSplitterOutlineBounds(ptMouse); - if (DragSource.IsVertical) - return rect.X - RectSplitter.X; - else - return rect.Y - RectSplitter.Y; - } - - private Rectangle GetSplitterOutlineBounds(Point ptMouse) - { - Rectangle rectLimit = DragSource.DragLimitBounds; - - Rectangle rect = RectSplitter; - if (rectLimit.Width <= 0 || rectLimit.Height <= 0) - return rect; - - if (DragSource.IsVertical) - { - rect.X += ptMouse.X - StartMousePosition.X; - rect.Height = rectLimit.Height; - } - else - { - rect.Y += ptMouse.Y - StartMousePosition.Y; - rect.Width = rectLimit.Width; - } - - if (rect.Left < rectLimit.Left) - rect.X = rectLimit.X; - if (rect.Top < rectLimit.Top) - rect.Y = rectLimit.Y; - if (rect.Right > rectLimit.Right) - rect.X -= rect.Right - rectLimit.Right; - if (rect.Bottom > rectLimit.Bottom) - rect.Y -= rect.Bottom - rectLimit.Bottom; - - return rect; - } - } - - private SplitterDragHandler m_splitterDragHandler = null; - private SplitterDragHandler GetSplitterDragHandler() - { - if (m_splitterDragHandler == null) - m_splitterDragHandler = new SplitterDragHandler(this); - return m_splitterDragHandler; - } - - internal void BeginDrag(ISplitterDragSource dragSource, Rectangle rectSplitter) - { - GetSplitterDragHandler().BeginDrag(dragSource, rectSplitter); - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.bmp b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.bmp deleted file mode 100644 index 10d6858f9490df8c44bc54bb02ab98d05d052484..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 822 zcmbV_(G7qg3~$x7}%dq7e+dr!<0rf4+`axo8$wKBceVOu6aY@k6LOI;(>ATU_|AQ5wMj X8lVvjpaB}em)YQocLrtG_;(y0(ZY@L diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.cs deleted file mode 100644 index 6827c9d801..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanel.cs +++ /dev/null @@ -1,986 +0,0 @@ -using System; -using System.Drawing; -using System.Drawing.Drawing2D; -using System.Windows.Forms; -using System.ComponentModel; -using System.Runtime.InteropServices; -using System.IO; -using System.Text; -using System.Diagnostics.CodeAnalysis; -using System.Collections.Generic; - -// To simplify the process of finding the toolbox bitmap resource: -// #1 Create an internal class called "resfinder" outside of the root namespace. -// #2 Use "resfinder" in the toolbox bitmap attribute instead of the control name. -// #3 use the "." string to locate the resource. -// See: http://www.bobpowell.net/toolboxbitmap.htm -internal class resfinder -{ -} - -namespace WeifenLuo.WinFormsUI.Docking -{ - [SuppressMessage("Microsoft.Naming", "CA1720:AvoidTypeNamesInParameters", MessageId = "0#")] - public delegate IDockContent DeserializeDockContent(string persistString); - - [LocalizedDescription("DockPanel_Description")] - [Designer(typeof(System.Windows.Forms.Design.ControlDesigner))] - [ToolboxBitmap(typeof(resfinder), "WeifenLuo.WinFormsUI.Docking.DockPanel.bmp")] - [DefaultProperty("DocumentStyle")] - [DefaultEvent("ActiveContentChanged")] - public partial class DockPanel : Panel - { - private FocusManagerImpl m_focusManager; - private DockPanelExtender m_extender; - private DockPaneCollection m_panes; - private FloatWindowCollection m_floatWindows; - private AutoHideWindowControl m_autoHideWindow; - private DockWindowCollection m_dockWindows; - private DockContent m_dummyContent; - private Control m_dummyControl; - - public DockPanel() - { - m_focusManager = new FocusManagerImpl(this); - m_extender = new DockPanelExtender(this); - m_panes = new DockPaneCollection(); - m_floatWindows = new FloatWindowCollection(); - - SuspendLayout(); - - m_autoHideWindow = new AutoHideWindowControl(this); - m_autoHideWindow.Visible = false; - SetAutoHideWindowParent(); - - m_dummyControl = new DummyControl(); - m_dummyControl.Bounds = new Rectangle(0, 0, 1, 1); - Controls.Add(m_dummyControl); - - m_dockWindows = new DockWindowCollection(this); - Controls.AddRange(new Control[] { - DockWindows[DockState.Document], - DockWindows[DockState.DockLeft], - DockWindows[DockState.DockRight], - DockWindows[DockState.DockTop], - DockWindows[DockState.DockBottom] - }); - - m_dummyContent = new DockContent(); - ResumeLayout(); - } - - private AutoHideStripBase m_autoHideStripControl = null; - internal AutoHideStripBase AutoHideStripControl - { - get - { - if (m_autoHideStripControl == null) - { - m_autoHideStripControl = AutoHideStripFactory.CreateAutoHideStrip(this); - Controls.Add(m_autoHideStripControl); - } - return m_autoHideStripControl; - } - } - internal void ResetAutoHideStripControl() - { - if (m_autoHideStripControl != null) - m_autoHideStripControl.Dispose(); - - m_autoHideStripControl = null; - } - - private void MdiClientHandleAssigned(object sender, EventArgs e) - { - SetMdiClient(); - PerformLayout(); - } - - private void MdiClient_Layout(object sender, LayoutEventArgs e) - { - if (DocumentStyle != DocumentStyle.DockingMdi) - return; - - foreach (DockPane pane in Panes) - if (pane.DockState == DockState.Document) - pane.SetContentBounds(); - - InvalidateWindowRegion(); - } - - private bool m_disposed = false; - protected override void Dispose(bool disposing) - { - lock (this) - { - if (!m_disposed && disposing) - { - m_focusManager.Dispose(); - if (m_mdiClientController != null) - { - m_mdiClientController.HandleAssigned -= new EventHandler(MdiClientHandleAssigned); - m_mdiClientController.MdiChildActivate -= new EventHandler(ParentFormMdiChildActivate); - m_mdiClientController.Layout -= new LayoutEventHandler(MdiClient_Layout); - m_mdiClientController.Dispose(); - } - FloatWindows.Dispose(); - Panes.Dispose(); - DummyContent.Dispose(); - - m_disposed = true; - } - - base.Dispose(disposing); - } - } - - [Browsable(false)] - public IDockContent ActiveAutoHideContent - { - get { return AutoHideWindow.ActiveContent; } - set { AutoHideWindow.ActiveContent = value; } - } - - private bool m_allowEndUserDocking = true; - [LocalizedCategory("Category_Docking")] - [LocalizedDescription("DockPanel_AllowEndUserDocking_Description")] - [DefaultValue(true)] - public bool AllowEndUserDocking - { - get { return m_allowEndUserDocking; } - set { m_allowEndUserDocking = value; } - } - - private bool m_allowEndUserNestedDocking = true; - [LocalizedCategory("Category_Docking")] - [LocalizedDescription("DockPanel_AllowEndUserNestedDocking_Description")] - [DefaultValue(true)] - public bool AllowEndUserNestedDocking - { - get { return m_allowEndUserNestedDocking; } - set { m_allowEndUserNestedDocking = value; } - } - - private DockContentCollection m_contents = new DockContentCollection(); - [Browsable(false)] - public DockContentCollection Contents - { - get { return m_contents; } - } - - internal DockContent DummyContent - { - get { return m_dummyContent; } - } - - private bool m_rightToLeftLayout = false; - [DefaultValue(false)] - [LocalizedCategory("Appearance")] - [LocalizedDescription("DockPanel_RightToLeftLayout_Description")] - public bool RightToLeftLayout - { - get { return m_rightToLeftLayout; } - set - { - if (m_rightToLeftLayout == value) - return; - - m_rightToLeftLayout = value; - foreach (FloatWindow floatWindow in FloatWindows) - floatWindow.RightToLeftLayout = value; - } - } - - protected override void OnRightToLeftChanged(EventArgs e) - { - base.OnRightToLeftChanged(e); - foreach (FloatWindow floatWindow in FloatWindows) - { - if (floatWindow.RightToLeft != RightToLeft) - floatWindow.RightToLeft = RightToLeft; - } - } - - private bool m_showDocumentIcon = false; - [DefaultValue(false)] - [LocalizedCategory("Category_Docking")] - [LocalizedDescription("DockPanel_ShowDocumentIcon_Description")] - public bool ShowDocumentIcon - { - get { return m_showDocumentIcon; } - set - { - if (m_showDocumentIcon == value) - return; - - m_showDocumentIcon = value; - Refresh(); - } - } - - [Browsable(false)] - public DockPanelExtender Extender - { - get { return m_extender; } - } - - public DockPanelExtender.IDockPaneFactory DockPaneFactory - { - get { return Extender.DockPaneFactory; } - } - - public DockPanelExtender.IFloatWindowFactory FloatWindowFactory - { - get { return Extender.FloatWindowFactory; } - } - - internal DockPanelExtender.IDockPaneCaptionFactory DockPaneCaptionFactory - { - get { return Extender.DockPaneCaptionFactory; } - } - - internal DockPanelExtender.IDockPaneStripFactory DockPaneStripFactory - { - get { return Extender.DockPaneStripFactory; } - } - - internal DockPanelExtender.IAutoHideStripFactory AutoHideStripFactory - { - get { return Extender.AutoHideStripFactory; } - } - - [Browsable(false)] - public DockPaneCollection Panes - { - get { return m_panes; } - } - - internal Rectangle DockArea - { - get - { - return new Rectangle(DockPadding.Left, DockPadding.Top, - ClientRectangle.Width - DockPadding.Left - DockPadding.Right, - ClientRectangle.Height - DockPadding.Top - DockPadding.Bottom); - } - } - - private double m_dockBottomPortion = 0.25; - [LocalizedCategory("Category_Docking")] - [LocalizedDescription("DockPanel_DockBottomPortion_Description")] - [DefaultValue(0.25)] - public double DockBottomPortion - { - get { return m_dockBottomPortion; } - set - { - if (value <= 0) - throw new ArgumentOutOfRangeException("value"); - - if (value == m_dockBottomPortion) - return; - - m_dockBottomPortion = value; - - if (m_dockBottomPortion < 1 && m_dockTopPortion < 1) - { - if (m_dockTopPortion + m_dockBottomPortion > 1) - m_dockTopPortion = 1 - m_dockBottomPortion; - } - - PerformLayout(); - } - } - - private double m_dockLeftPortion = 0.25; - [LocalizedCategory("Category_Docking")] - [LocalizedDescription("DockPanel_DockLeftPortion_Description")] - [DefaultValue(0.25)] - public double DockLeftPortion - { - get { return m_dockLeftPortion; } - set - { - if (value <= 0) - throw new ArgumentOutOfRangeException("value"); - - if (value == m_dockLeftPortion) - return; - - m_dockLeftPortion = value; - - if (m_dockLeftPortion < 1 && m_dockRightPortion < 1) - { - if (m_dockLeftPortion + m_dockRightPortion > 1) - m_dockRightPortion = 1 - m_dockLeftPortion; - } - PerformLayout(); - } - } - - private double m_dockRightPortion = 0.25; - [LocalizedCategory("Category_Docking")] - [LocalizedDescription("DockPanel_DockRightPortion_Description")] - [DefaultValue(0.25)] - public double DockRightPortion - { - get { return m_dockRightPortion; } - set - { - if (value <= 0) - throw new ArgumentOutOfRangeException("value"); - - if (value == m_dockRightPortion) - return; - - m_dockRightPortion = value; - - if (m_dockLeftPortion < 1 && m_dockRightPortion < 1) - { - if (m_dockLeftPortion + m_dockRightPortion > 1) - m_dockLeftPortion = 1 - m_dockRightPortion; - } - PerformLayout(); - } - } - - private double m_dockTopPortion = 0.25; - [LocalizedCategory("Category_Docking")] - [LocalizedDescription("DockPanel_DockTopPortion_Description")] - [DefaultValue(0.25)] - public double DockTopPortion - { - get { return m_dockTopPortion; } - set - { - if (value <= 0) - throw new ArgumentOutOfRangeException("value"); - - if (value == m_dockTopPortion) - return; - - m_dockTopPortion = value; - - if (m_dockTopPortion < 1 && m_dockBottomPortion < 1) - { - if (m_dockTopPortion + m_dockBottomPortion > 1) - m_dockBottomPortion = 1 - m_dockTopPortion; - } - PerformLayout(); - } - } - - [Browsable(false)] - public DockWindowCollection DockWindows - { - get { return m_dockWindows; } - } - - public void UpdateDockWindowZOrder(DockStyle dockStyle, bool fullPanelEdge) - { - if (dockStyle == DockStyle.Left) - { - if (fullPanelEdge) - DockWindows[DockState.DockLeft].SendToBack(); - else - DockWindows[DockState.DockLeft].BringToFront(); - } - else if (dockStyle == DockStyle.Right) - { - if (fullPanelEdge) - DockWindows[DockState.DockRight].SendToBack(); - else - DockWindows[DockState.DockRight].BringToFront(); - } - else if (dockStyle == DockStyle.Top) - { - if (fullPanelEdge) - DockWindows[DockState.DockTop].SendToBack(); - else - DockWindows[DockState.DockTop].BringToFront(); - } - else if (dockStyle == DockStyle.Bottom) - { - if (fullPanelEdge) - DockWindows[DockState.DockBottom].SendToBack(); - else - DockWindows[DockState.DockBottom].BringToFront(); - } - } - - public int DocumentsCount - { - get - { - int count = 0; - foreach (IDockContent content in Documents) - count++; - - return count; - } - } - - public IDockContent[] DocumentsToArray() - { - int count = DocumentsCount; - IDockContent[] documents = new IDockContent[count]; - int i = 0; - foreach (IDockContent content in Documents) - { - documents[i] = content; - i++; - } - - return documents; - } - - public IEnumerable Documents - { - get - { - foreach (IDockContent content in Contents) - { - if (content.DockHandler.DockState == DockState.Document) - yield return content; - } - } - } - - private Rectangle DocumentRectangle - { - get - { - Rectangle rect = DockArea; - if (DockWindows[DockState.DockLeft].VisibleNestedPanes.Count != 0) - { - rect.X += (int)(DockArea.Width * DockLeftPortion); - rect.Width -= (int)(DockArea.Width * DockLeftPortion); - } - if (DockWindows[DockState.DockRight].VisibleNestedPanes.Count != 0) - rect.Width -= (int)(DockArea.Width * DockRightPortion); - if (DockWindows[DockState.DockTop].VisibleNestedPanes.Count != 0) - { - rect.Y += (int)(DockArea.Height * DockTopPortion); - rect.Height -= (int)(DockArea.Height * DockTopPortion); - } - if (DockWindows[DockState.DockBottom].VisibleNestedPanes.Count != 0) - rect.Height -= (int)(DockArea.Height * DockBottomPortion); - - return rect; - } - } - - private Control DummyControl - { - get { return m_dummyControl; } - } - - [Browsable(false)] - public FloatWindowCollection FloatWindows - { - get { return m_floatWindows; } - } - - private Size m_defaultFloatWindowSize = new Size(300, 300); - [Category("Layout")] - [LocalizedDescription("DockPanel_DefaultFloatWindowSize_Description")] - public Size DefaultFloatWindowSize - { - get { return m_defaultFloatWindowSize; } - set { m_defaultFloatWindowSize = value; } - } - private bool ShouldSerializeDefaultFloatWindowSize() - { - return DefaultFloatWindowSize != new Size(300, 300); - } - - private DocumentStyle m_documentStyle = DocumentStyle.DockingMdi; - [LocalizedCategory("Category_Docking")] - [LocalizedDescription("DockPanel_DocumentStyle_Description")] - [DefaultValue(DocumentStyle.DockingMdi)] - public DocumentStyle DocumentStyle - { - get { return m_documentStyle; } - set - { - if (value == m_documentStyle) - return; - - if (!Enum.IsDefined(typeof(DocumentStyle), value)) - throw new InvalidEnumArgumentException(); - - if (value == DocumentStyle.SystemMdi && DockWindows[DockState.Document].VisibleNestedPanes.Count > 0) - throw new InvalidEnumArgumentException(); - - m_documentStyle = value; - - SuspendLayout(true); - - SetAutoHideWindowParent(); - SetMdiClient(); - InvalidateWindowRegion(); - - foreach (IDockContent content in Contents) - { - if (content.DockHandler.DockState == DockState.Document) - content.DockHandler.SetPaneAndVisible(content.DockHandler.Pane); - } - - PerformMdiClientLayout(); - - ResumeLayout(true, true); - } - } - - private int GetDockWindowSize(DockState dockState) - { - if (dockState == DockState.DockLeft || dockState == DockState.DockRight) - { - int width = ClientRectangle.Width - DockPadding.Left - DockPadding.Right; - int dockLeftSize = m_dockLeftPortion >= 1 ? (int)m_dockLeftPortion : (int)(width * m_dockLeftPortion); - int dockRightSize = m_dockRightPortion >= 1 ? (int)m_dockRightPortion : (int)(width * m_dockRightPortion); - - if (dockLeftSize < MeasurePane.MinSize) - dockLeftSize = MeasurePane.MinSize; - if (dockRightSize < MeasurePane.MinSize) - dockRightSize = MeasurePane.MinSize; - - if (dockLeftSize + dockRightSize > width - MeasurePane.MinSize) - { - int adjust = (dockLeftSize + dockRightSize) - (width - MeasurePane.MinSize); - dockLeftSize -= adjust / 2; - dockRightSize -= adjust / 2; - } - - return dockState == DockState.DockLeft ? dockLeftSize : dockRightSize; - } - else if (dockState == DockState.DockTop || dockState == DockState.DockBottom) - { - int height = ClientRectangle.Height - DockPadding.Top - DockPadding.Bottom; - int dockTopSize = m_dockTopPortion >= 1 ? (int)m_dockTopPortion : (int)(height * m_dockTopPortion); - int dockBottomSize = m_dockBottomPortion >= 1 ? (int)m_dockBottomPortion : (int)(height * m_dockBottomPortion); - - if (dockTopSize < MeasurePane.MinSize) - dockTopSize = MeasurePane.MinSize; - if (dockBottomSize < MeasurePane.MinSize) - dockBottomSize = MeasurePane.MinSize; - - if (dockTopSize + dockBottomSize > height - MeasurePane.MinSize) - { - int adjust = (dockTopSize + dockBottomSize) - (height - MeasurePane.MinSize); - dockTopSize -= adjust / 2; - dockBottomSize -= adjust / 2; - } - - return dockState == DockState.DockTop ? dockTopSize : dockBottomSize; - } - else - return 0; - } - - protected override void OnLayout(LayoutEventArgs levent) - { - SuspendLayout(true); - - AutoHideStripControl.Bounds = ClientRectangle; - - CalculateDockPadding(); - - DockWindows[DockState.DockLeft].Width = GetDockWindowSize(DockState.DockLeft); - DockWindows[DockState.DockRight].Width = GetDockWindowSize(DockState.DockRight); - DockWindows[DockState.DockTop].Height = GetDockWindowSize(DockState.DockTop); - DockWindows[DockState.DockBottom].Height = GetDockWindowSize(DockState.DockBottom); - - AutoHideWindow.Bounds = GetAutoHideWindowBounds(AutoHideWindowRectangle); - - DockWindows[DockState.Document].BringToFront(); - AutoHideWindow.BringToFront(); - - base.OnLayout(levent); - - if (DocumentStyle == DocumentStyle.SystemMdi && MdiClientExists) - { - SetMdiClientBounds(SystemMdiClientBounds); - InvalidateWindowRegion(); - } - else if (DocumentStyle == DocumentStyle.DockingMdi) - InvalidateWindowRegion(); - - ResumeLayout(true, true); - } - - internal Rectangle GetTabStripRectangle(DockState dockState) - { - return AutoHideStripControl.GetTabStripRectangle(dockState); - } - - protected override void OnPaint(PaintEventArgs e) - { - base.OnPaint(e); - - Graphics g = e.Graphics; - g.FillRectangle(SystemBrushes.AppWorkspace, ClientRectangle); - } - - internal void AddContent(IDockContent content) - { - if (content == null) - throw(new ArgumentNullException()); - - if (!Contents.Contains(content)) - { - Contents.Add(content); - OnContentAdded(new DockContentEventArgs(content)); - } - } - - internal void AddPane(DockPane pane) - { - if (Panes.Contains(pane)) - return; - - Panes.Add(pane); - } - - internal void AddFloatWindow(FloatWindow floatWindow) - { - if (FloatWindows.Contains(floatWindow)) - return; - - FloatWindows.Add(floatWindow); - } - - private void CalculateDockPadding() - { - DockPadding.All = 0; - - int height = AutoHideStripControl.MeasureHeight(); - - if (AutoHideStripControl.GetNumberOfPanes(DockState.DockLeftAutoHide) > 0) - DockPadding.Left = height; - if (AutoHideStripControl.GetNumberOfPanes(DockState.DockRightAutoHide) > 0) - DockPadding.Right = height; - if (AutoHideStripControl.GetNumberOfPanes(DockState.DockTopAutoHide) > 0) - DockPadding.Top = height; - if (AutoHideStripControl.GetNumberOfPanes(DockState.DockBottomAutoHide) > 0) - DockPadding.Bottom = height; - } - - internal void RemoveContent(IDockContent content) - { - if (content == null) - throw(new ArgumentNullException()); - - if (Contents.Contains(content)) - { - Contents.Remove(content); - OnContentRemoved(new DockContentEventArgs(content)); - } - } - - internal void RemovePane(DockPane pane) - { - if (!Panes.Contains(pane)) - return; - - Panes.Remove(pane); - } - - internal void RemoveFloatWindow(FloatWindow floatWindow) - { - if (!FloatWindows.Contains(floatWindow)) - return; - - FloatWindows.Remove(floatWindow); - } - - public void SetPaneIndex(DockPane pane, int index) - { - int oldIndex = Panes.IndexOf(pane); - if (oldIndex == -1) - throw(new ArgumentException(Strings.DockPanel_SetPaneIndex_InvalidPane)); - - if (index < 0 || index > Panes.Count - 1) - if (index != -1) - throw(new ArgumentOutOfRangeException(Strings.DockPanel_SetPaneIndex_InvalidIndex)); - - if (oldIndex == index) - return; - if (oldIndex == Panes.Count - 1 && index == -1) - return; - - Panes.Remove(pane); - if (index == -1) - Panes.Add(pane); - else if (oldIndex < index) - Panes.AddAt(pane, index - 1); - else - Panes.AddAt(pane, index); - } - - public void SuspendLayout(bool allWindows) - { - FocusManager.SuspendFocusTracking(); - SuspendLayout(); - if (allWindows) - SuspendMdiClientLayout(); - } - - public void ResumeLayout(bool performLayout, bool allWindows) - { - FocusManager.ResumeFocusTracking(); - ResumeLayout(performLayout); - if (allWindows) - ResumeMdiClientLayout(performLayout); - } - - internal Form ParentForm - { - get - { - if (!IsParentFormValid()) - throw new InvalidOperationException(Strings.DockPanel_ParentForm_Invalid); - - return GetMdiClientController().ParentForm; - } - } - - private bool IsParentFormValid() - { - if (DocumentStyle == DocumentStyle.DockingSdi || DocumentStyle == DocumentStyle.DockingWindow) - return true; - - if (!MdiClientExists) - GetMdiClientController().RenewMdiClient(); - - return (MdiClientExists); - } - - protected override void OnParentChanged(EventArgs e) - { - SetAutoHideWindowParent(); - GetMdiClientController().ParentForm = (this.Parent as Form); - base.OnParentChanged (e); - } - - private void SetAutoHideWindowParent() - { - Control parent; - if (DocumentStyle == DocumentStyle.DockingMdi || - DocumentStyle == DocumentStyle.SystemMdi) - parent = this.Parent; - else - parent = this; - if (AutoHideWindow.Parent != parent) - { - AutoHideWindow.Parent = parent; - AutoHideWindow.BringToFront(); - } - } - - protected override void OnVisibleChanged(EventArgs e) - { - base.OnVisibleChanged (e); - - if (Visible) - SetMdiClient(); - } - - private Rectangle SystemMdiClientBounds - { - get - { - if (!IsParentFormValid() || !Visible) - return Rectangle.Empty; - - Rectangle rect = ParentForm.RectangleToClient(RectangleToScreen(DocumentWindowBounds)); - return rect; - } - } - - internal Rectangle DocumentWindowBounds - { - get - { - Rectangle rectDocumentBounds = DisplayRectangle; - if (DockWindows[DockState.DockLeft].Visible) - { - rectDocumentBounds.X += DockWindows[DockState.DockLeft].Width; - rectDocumentBounds.Width -= DockWindows[DockState.DockLeft].Width; - } - if (DockWindows[DockState.DockRight].Visible) - rectDocumentBounds.Width -= DockWindows[DockState.DockRight].Width; - if (DockWindows[DockState.DockTop].Visible) - { - rectDocumentBounds.Y += DockWindows[DockState.DockTop].Height; - rectDocumentBounds.Height -= DockWindows[DockState.DockTop].Height; - } - if (DockWindows[DockState.DockBottom].Visible) - rectDocumentBounds.Height -= DockWindows[DockState.DockBottom].Height; - - return rectDocumentBounds; - - } - } - - private PaintEventHandler m_dummyControlPaintEventHandler = null; - private void InvalidateWindowRegion() - { - if (DesignMode) - return; - - if (m_dummyControlPaintEventHandler == null) - m_dummyControlPaintEventHandler = new PaintEventHandler(DummyControl_Paint); - - DummyControl.Paint += m_dummyControlPaintEventHandler; - DummyControl.Invalidate(); - } - - void DummyControl_Paint(object sender, PaintEventArgs e) - { - DummyControl.Paint -= m_dummyControlPaintEventHandler; - UpdateWindowRegion(); - } - - private void UpdateWindowRegion() - { - if (this.DocumentStyle == DocumentStyle.DockingMdi) - UpdateWindowRegion_ClipContent(); - else if (this.DocumentStyle == DocumentStyle.DockingSdi || - this.DocumentStyle == DocumentStyle.DockingWindow) - UpdateWindowRegion_FullDocumentArea(); - else if (this.DocumentStyle == DocumentStyle.SystemMdi) - UpdateWindowRegion_EmptyDocumentArea(); - } - - private void UpdateWindowRegion_FullDocumentArea() - { - SetRegion(null); - } - - private void UpdateWindowRegion_EmptyDocumentArea() - { - Rectangle rect = DocumentWindowBounds; - SetRegion(new Rectangle[] { rect }); - } - - private void UpdateWindowRegion_ClipContent() - { - int count = 0; - foreach (DockPane pane in this.Panes) - { - if (!pane.Visible || pane.DockState != DockState.Document) - continue; - - count ++; - } - - if (count == 0) - { - SetRegion(null); - return; - } - - Rectangle[] rects = new Rectangle[count]; - int i = 0; - foreach (DockPane pane in this.Panes) - { - if (!pane.Visible || pane.DockState != DockState.Document) - continue; - - rects[i] = RectangleToClient(pane.RectangleToScreen(pane.ContentRectangle)); - i++; - } - - SetRegion(rects); - } - - private Rectangle[] m_clipRects = null; - private void SetRegion(Rectangle[] clipRects) - { - if (!IsClipRectsChanged(clipRects)) - return; - - m_clipRects = clipRects; - - if (m_clipRects == null || m_clipRects.GetLength(0) == 0) - Region = null; - else - { - Region region = new Region(new Rectangle(0, 0, this.Width, this.Height)); - foreach (Rectangle rect in m_clipRects) - region.Exclude(rect); - Region = region; - } - } - - private bool IsClipRectsChanged(Rectangle[] clipRects) - { - if (clipRects == null && m_clipRects == null) - return false; - else if ((clipRects == null) != (m_clipRects == null)) - return true; - - foreach (Rectangle rect in clipRects) - { - bool matched = false; - foreach (Rectangle rect2 in m_clipRects) - { - if (rect == rect2) - { - matched = true; - break; - } - } - if (!matched) - return true; - } - - foreach (Rectangle rect2 in m_clipRects) - { - bool matched = false; - foreach (Rectangle rect in clipRects) - { - if (rect == rect2) - { - matched = true; - break; - } - } - if (!matched) - return true; - } - return false; - } - - private static readonly object ContentAddedEvent = new object(); - [LocalizedCategory("Category_DockingNotification")] - [LocalizedDescription("DockPanel_ContentAdded_Description")] - public event EventHandler ContentAdded - { - add { Events.AddHandler(ContentAddedEvent, value); } - remove { Events.RemoveHandler(ContentAddedEvent, value); } - } - protected virtual void OnContentAdded(DockContentEventArgs e) - { - EventHandler handler = (EventHandler)Events[ContentAddedEvent]; - if (handler != null) - handler(this, e); - } - - private static readonly object ContentRemovedEvent = new object(); - [LocalizedCategory("Category_DockingNotification")] - [LocalizedDescription("DockPanel_ContentRemoved_Description")] - public event EventHandler ContentRemoved - { - add { Events.AddHandler(ContentRemovedEvent, value); } - remove { Events.RemoveHandler(ContentRemovedEvent, value); } - } - protected virtual void OnContentRemoved(DockContentEventArgs e) - { - EventHandler handler = (EventHandler)Events[ContentRemovedEvent]; - if (handler != null) - handler(this, e); - } - } -} \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanelExtender.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanelExtender.cs deleted file mode 100644 index e304ea7551..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockPanelExtender.cs +++ /dev/null @@ -1,225 +0,0 @@ -using System; -using System.Drawing; -using System.Diagnostics.CodeAnalysis; - -namespace WeifenLuo.WinFormsUI.Docking -{ - public sealed class DockPanelExtender - { - [SuppressMessage("Microsoft.Design", "CA1034:NestedTypesShouldNotBeVisible")] - public interface IDockPaneFactory - { - DockPane CreateDockPane(IDockContent content, DockState visibleState, bool show); - [SuppressMessage("Microsoft.Naming", "CA1720:AvoidTypeNamesInParameters", MessageId = "1#")] - DockPane CreateDockPane(IDockContent content, FloatWindow floatWindow, bool show); - DockPane CreateDockPane(IDockContent content, DockPane previousPane, DockAlignment alignment, double proportion, bool show); - [SuppressMessage("Microsoft.Naming", "CA1720:AvoidTypeNamesInParameters", MessageId = "1#")] - DockPane CreateDockPane(IDockContent content, Rectangle floatWindowBounds, bool show); - } - - [SuppressMessage("Microsoft.Design", "CA1034:NestedTypesShouldNotBeVisible")] - public interface IFloatWindowFactory - { - FloatWindow CreateFloatWindow(DockPanel dockPanel, DockPane pane); - FloatWindow CreateFloatWindow(DockPanel dockPanel, DockPane pane, Rectangle bounds); - } - - [SuppressMessage("Microsoft.Design", "CA1034:NestedTypesShouldNotBeVisible")] - public interface IDockPaneCaptionFactory - { - DockPaneCaptionBase CreateDockPaneCaption(DockPane pane); - } - - [SuppressMessage("Microsoft.Design", "CA1034:NestedTypesShouldNotBeVisible")] - public interface IDockPaneStripFactory - { - DockPaneStripBase CreateDockPaneStrip(DockPane pane); - } - - [SuppressMessage("Microsoft.Design", "CA1034:NestedTypesShouldNotBeVisible")] - public interface IAutoHideStripFactory - { - AutoHideStripBase CreateAutoHideStrip(DockPanel panel); - } - - #region DefaultDockPaneFactory - private class DefaultDockPaneFactory : IDockPaneFactory - { - public DockPane CreateDockPane(IDockContent content, DockState visibleState, bool show) - { - return new DockPane(content, visibleState, show); - } - - public DockPane CreateDockPane(IDockContent content, FloatWindow floatWindow, bool show) - { - return new DockPane(content, floatWindow, show); - } - - public DockPane CreateDockPane(IDockContent content, DockPane prevPane, DockAlignment alignment, double proportion, bool show) - { - return new DockPane(content, prevPane, alignment, proportion, show); - } - - public DockPane CreateDockPane(IDockContent content, Rectangle floatWindowBounds, bool show) - { - return new DockPane(content, floatWindowBounds, show); - } - } - #endregion - - #region DefaultFloatWindowFactory - private class DefaultFloatWindowFactory : IFloatWindowFactory - { - public FloatWindow CreateFloatWindow(DockPanel dockPanel, DockPane pane) - { - return new FloatWindow(dockPanel, pane); - } - - public FloatWindow CreateFloatWindow(DockPanel dockPanel, DockPane pane, Rectangle bounds) - { - return new FloatWindow(dockPanel, pane, bounds); - } - } - #endregion - - #region DefaultDockPaneCaptionFactory - private class DefaultDockPaneCaptionFactory : IDockPaneCaptionFactory - { - public DockPaneCaptionBase CreateDockPaneCaption(DockPane pane) - { - return new VS2005DockPaneCaption(pane); - } - } - #endregion - - #region DefaultDockPaneTabStripFactory - private class DefaultDockPaneStripFactory : IDockPaneStripFactory - { - public DockPaneStripBase CreateDockPaneStrip(DockPane pane) - { - return new VS2005DockPaneStrip(pane); - } - } - #endregion - - #region DefaultAutoHideStripFactory - private class DefaultAutoHideStripFactory : IAutoHideStripFactory - { - public AutoHideStripBase CreateAutoHideStrip(DockPanel panel) - { - return new VS2005AutoHideStrip(panel); - } - } - #endregion - - internal DockPanelExtender(DockPanel dockPanel) - { - m_dockPanel = dockPanel; - } - - private DockPanel m_dockPanel; - private DockPanel DockPanel - { - get { return m_dockPanel; } - } - - private IDockPaneFactory m_dockPaneFactory = null; - public IDockPaneFactory DockPaneFactory - { - get - { - if (m_dockPaneFactory == null) - m_dockPaneFactory = new DefaultDockPaneFactory(); - - return m_dockPaneFactory; - } - set - { - if (DockPanel.Panes.Count > 0) - throw new InvalidOperationException(); - - m_dockPaneFactory = value; - } - } - - private IFloatWindowFactory m_floatWindowFactory = null; - public IFloatWindowFactory FloatWindowFactory - { - get - { - if (m_floatWindowFactory == null) - m_floatWindowFactory = new DefaultFloatWindowFactory(); - - return m_floatWindowFactory; - } - set - { - if (DockPanel.FloatWindows.Count > 0) - throw new InvalidOperationException(); - - m_floatWindowFactory = value; - } - } - - private IDockPaneCaptionFactory m_dockPaneCaptionFactory = null; - public IDockPaneCaptionFactory DockPaneCaptionFactory - { - get - { - if (m_dockPaneCaptionFactory == null) - m_dockPaneCaptionFactory = new DefaultDockPaneCaptionFactory(); - - return m_dockPaneCaptionFactory; - } - set - { - if (DockPanel.Panes.Count > 0) - throw new InvalidOperationException(); - - m_dockPaneCaptionFactory = value; - } - } - - private IDockPaneStripFactory m_dockPaneStripFactory = null; - public IDockPaneStripFactory DockPaneStripFactory - { - get - { - if (m_dockPaneStripFactory == null) - m_dockPaneStripFactory = new DefaultDockPaneStripFactory(); - - return m_dockPaneStripFactory; - } - set - { - if (DockPanel.Contents.Count > 0) - throw new InvalidOperationException(); - - m_dockPaneStripFactory = value; - } - } - - private IAutoHideStripFactory m_autoHideStripFactory = null; - public IAutoHideStripFactory AutoHideStripFactory - { - get - { - if (m_autoHideStripFactory == null) - m_autoHideStripFactory = new DefaultAutoHideStripFactory(); - - return m_autoHideStripFactory; - } - set - { - if (DockPanel.Contents.Count > 0) - throw new InvalidOperationException(); - - if (m_autoHideStripFactory == value) - return; - - m_autoHideStripFactory = value; - DockPanel.ResetAutoHideStripControl(); - } - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockWindow.SplitterControl.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockWindow.SplitterControl.cs deleted file mode 100644 index 3eaa653907..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockWindow.SplitterControl.cs +++ /dev/null @@ -1,28 +0,0 @@ -using System; -using System.Collections; -using System.ComponentModel; -using System.Drawing; -using System.Windows.Forms; - -namespace WeifenLuo.WinFormsUI.Docking -{ - public partial class DockWindow - { - private class SplitterControl : SplitterBase - { - protected override int SplitterSize - { - get { return Measures.SplitterSize; } - } - - protected override void StartDrag() - { - DockWindow window = Parent as DockWindow; - if (window == null) - return; - - window.DockPanel.BeginDrag(window, window.RectangleToScreen(Bounds)); - } - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockWindow.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockWindow.cs deleted file mode 100644 index 4bbf423ae0..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockWindow.cs +++ /dev/null @@ -1,243 +0,0 @@ -using System; -using System.Windows.Forms; -using System.Drawing; -using System.Runtime.InteropServices; -using System.ComponentModel; - -namespace WeifenLuo.WinFormsUI.Docking -{ - [ToolboxItem(false)] - public partial class DockWindow : Panel, INestedPanesContainer, ISplitterDragSource - { - private DockPanel m_dockPanel; - private DockState m_dockState; - private SplitterControl m_splitter; - private NestedPaneCollection m_nestedPanes; - - internal DockWindow(DockPanel dockPanel, DockState dockState) - { - m_nestedPanes = new NestedPaneCollection(this); - m_dockPanel = dockPanel; - m_dockState = dockState; - Visible = false; - - SuspendLayout(); - - if (DockState == DockState.DockLeft || DockState == DockState.DockRight || - DockState == DockState.DockTop || DockState == DockState.DockBottom) - { - m_splitter = new SplitterControl(); - Controls.Add(m_splitter); - } - - if (DockState == DockState.DockLeft) - { - Dock = DockStyle.Left; - m_splitter.Dock = DockStyle.Right; - } - else if (DockState == DockState.DockRight) - { - Dock = DockStyle.Right; - m_splitter.Dock = DockStyle.Left; - } - else if (DockState == DockState.DockTop) - { - Dock = DockStyle.Top; - m_splitter.Dock = DockStyle.Bottom; - } - else if (DockState == DockState.DockBottom) - { - Dock = DockStyle.Bottom; - m_splitter.Dock = DockStyle.Top; - } - else if (DockState == DockState.Document) - { - Dock = DockStyle.Fill; - } - - ResumeLayout(); - } - - public VisibleNestedPaneCollection VisibleNestedPanes - { - get { return NestedPanes.VisibleNestedPanes; } - } - - public NestedPaneCollection NestedPanes - { - get { return m_nestedPanes; } - } - - public DockPanel DockPanel - { - get { return m_dockPanel; } - } - - public DockState DockState - { - get { return m_dockState; } - } - - public bool IsFloat - { - get { return DockState == DockState.Float; } - } - - internal DockPane DefaultPane - { - get { return VisibleNestedPanes.Count == 0 ? null : VisibleNestedPanes[0]; } - } - - public virtual Rectangle DisplayingRectangle - { - get - { - Rectangle rect = ClientRectangle; - // if DockWindow is document, exclude the border - if (DockState == DockState.Document) - { - rect.X += 1; - rect.Y += 1; - rect.Width -= 2; - rect.Height -= 2; - } - // exclude the splitter - else if (DockState == DockState.DockLeft) - rect.Width -= Measures.SplitterSize; - else if (DockState == DockState.DockRight) - { - rect.X += Measures.SplitterSize; - rect.Width -= Measures.SplitterSize; - } - else if (DockState == DockState.DockTop) - rect.Height -= Measures.SplitterSize; - else if (DockState == DockState.DockBottom) - { - rect.Y += Measures.SplitterSize; - rect.Height -= Measures.SplitterSize; - } - - return rect; - } - } - - protected override void OnPaint(PaintEventArgs e) - { - // if DockWindow is document, draw the border - if (DockState == DockState.Document) - e.Graphics.DrawRectangle(SystemPens.ControlDark, ClientRectangle.X, ClientRectangle.Y, ClientRectangle.Width - 1, ClientRectangle.Height - 1); - - base.OnPaint(e); - } - - protected override void OnLayout(LayoutEventArgs levent) - { - VisibleNestedPanes.Refresh(); - if (VisibleNestedPanes.Count == 0) - { - if (Visible) - Visible = false; - } - else if (!Visible) - { - Visible = true; - VisibleNestedPanes.Refresh(); - } - - base.OnLayout (levent); - } - - #region ISplitterDragSource Members - - void ISplitterDragSource.BeginDrag(Rectangle rectSplitter) - { - } - - void ISplitterDragSource.EndDrag() - { - } - - bool ISplitterDragSource.IsVertical - { - get { return (DockState == DockState.DockLeft || DockState == DockState.DockRight); } - } - - Rectangle ISplitterDragSource.DragLimitBounds - { - get - { - Rectangle rectLimit = DockPanel.DockArea; - Point location; - if ((Control.ModifierKeys & Keys.Shift) == 0) - location = Location; - else - location = DockPanel.DockArea.Location; - - if (((ISplitterDragSource)this).IsVertical) - { - rectLimit.X += MeasurePane.MinSize; - rectLimit.Width -= 2 * MeasurePane.MinSize; - rectLimit.Y = location.Y; - if ((Control.ModifierKeys & Keys.Shift) == 0) - rectLimit.Height = Height; - } - else - { - rectLimit.Y += MeasurePane.MinSize; - rectLimit.Height -= 2 * MeasurePane.MinSize; - rectLimit.X = location.X; - if ((Control.ModifierKeys & Keys.Shift) == 0) - rectLimit.Width = Width; - } - - return DockPanel.RectangleToScreen(rectLimit); - } - } - - void ISplitterDragSource.MoveSplitter(int offset) - { - if ((Control.ModifierKeys & Keys.Shift) != 0) - SendToBack(); - - Rectangle rectDockArea = DockPanel.DockArea; - if (DockState == DockState.DockLeft && rectDockArea.Width > 0) - { - if (DockPanel.DockLeftPortion > 1) - DockPanel.DockLeftPortion = Width + offset; - else - DockPanel.DockLeftPortion += ((double)offset) / (double)rectDockArea.Width; - } - else if (DockState == DockState.DockRight && rectDockArea.Width > 0) - { - if (DockPanel.DockRightPortion > 1) - DockPanel.DockRightPortion = Width - offset; - else - DockPanel.DockRightPortion -= ((double)offset) / (double)rectDockArea.Width; - } - else if (DockState == DockState.DockBottom && rectDockArea.Height > 0) - { - if (DockPanel.DockBottomPortion > 1) - DockPanel.DockBottomPortion = Height - offset; - else - DockPanel.DockBottomPortion -= ((double)offset) / (double)rectDockArea.Height; - } - else if (DockState == DockState.DockTop && rectDockArea.Height > 0) - { - if (DockPanel.DockTopPortion > 1) - DockPanel.DockTopPortion = Height + offset; - else - DockPanel.DockTopPortion += ((double)offset) / (double)rectDockArea.Height; - } - } - - #region IDragSource Members - - Control IDragSource.DragControl - { - get { return this; } - } - - #endregion - #endregion - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockWindowCollection.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockWindowCollection.cs deleted file mode 100644 index edb114145f..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DockWindowCollection.cs +++ /dev/null @@ -1,38 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Collections.ObjectModel; - -namespace WeifenLuo.WinFormsUI.Docking -{ - public class DockWindowCollection : ReadOnlyCollection - { - internal DockWindowCollection(DockPanel dockPanel) - : base(new List()) - { - Items.Add(new DockWindow(dockPanel, DockState.Document)); - Items.Add(new DockWindow(dockPanel, DockState.DockLeft)); - Items.Add(new DockWindow(dockPanel, DockState.DockRight)); - Items.Add(new DockWindow(dockPanel, DockState.DockTop)); - Items.Add(new DockWindow(dockPanel, DockState.DockBottom)); - } - - public DockWindow this [DockState dockState] - { - get - { - if (dockState == DockState.Document) - return Items[0]; - else if (dockState == DockState.DockLeft || dockState == DockState.DockLeftAutoHide) - return Items[1]; - else if (dockState == DockState.DockRight || dockState == DockState.DockRightAutoHide) - return Items[2]; - else if (dockState == DockState.DockTop || dockState == DockState.DockTopAutoHide) - return Items[3]; - else if (dockState == DockState.DockBottom || dockState == DockState.DockBottomAutoHide) - return Items[4]; - - throw (new ArgumentOutOfRangeException()); - } - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DragForm.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DragForm.cs deleted file mode 100644 index 08187e9d96..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DragForm.cs +++ /dev/null @@ -1,64 +0,0 @@ -using System; -using System.Windows.Forms; - -namespace WeifenLuo.WinFormsUI.Docking -{ - // Inspired by Chris Sano's article: - // http://msdn.microsoft.com/smartclient/default.aspx?pull=/library/en-us/dnwinforms/html/colorpicker.asp - // In Sano's article, the DragForm needs to meet the following criteria: - // (1) it was not to show up in the task bar; - // ShowInTaskBar = false - // (2) it needed to be the top-most window; - // TopMost = true (not necessary here) - // (3) its icon could not show up in the ALT+TAB window if the user pressed ALT+TAB during a drag-and-drop; - // FormBorderStyle = FormBorderStyle.None; - // Create with WS_EX_TOOLWINDOW window style. - // Compares with the solution in the artile by setting FormBorderStyle as FixedToolWindow, - // and then clip the window caption and border, this way is much simplier. - // (4) it was not to steal focus from the application when displayed. - // User Win32 ShowWindow API with SW_SHOWNOACTIVATE - // In addition, this form should only for display and therefore should act as transparent, otherwise - // WindowFromPoint will return this form, instead of the control beneath. Need BOTH of the following to - // achieve this (don't know why, spent hours to try it out :( ): - // 1. Enabled = false; - // 2. WM_NCHITTEST returns HTTRANSPARENT - internal class DragForm : Form - { - public DragForm() - { - FormBorderStyle = FormBorderStyle.None; - ShowInTaskbar = false; - SetStyle(ControlStyles.Selectable, false); - Enabled = false; - } - - protected override CreateParams CreateParams - { - get - { - CreateParams createParams = base.CreateParams; - createParams.ExStyle |= (int)Win32.WindowExStyles.WS_EX_TOOLWINDOW; - return createParams; - } - } - - protected override void WndProc(ref Message m) - { - if (m.Msg == (int)Win32.Msgs.WM_NCHITTEST) - { - m.Result = (IntPtr)Win32.HitTest.HTTRANSPARENT; - return; - } - - base.WndProc (ref m); - } - - public virtual void Show(bool bActivate) - { - if (bActivate) - Show(); - else - NativeMethods.ShowWindow(Handle, (int)Win32.ShowWindowStyles.SW_SHOWNOACTIVATE); - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DummyControl.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DummyControl.cs deleted file mode 100644 index 99832c018d..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/DummyControl.cs +++ /dev/null @@ -1,13 +0,0 @@ -using System; -using System.Windows.Forms; - -namespace WeifenLuo.WinFormsUI.Docking -{ - internal class DummyControl : Control - { - public DummyControl() - { - SetStyle(ControlStyles.Selectable, false); - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Enums.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Enums.cs deleted file mode 100644 index ba7587f1fa..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Enums.cs +++ /dev/null @@ -1,51 +0,0 @@ -using System; -using System.ComponentModel; -using System.Windows.Forms; - -namespace WeifenLuo.WinFormsUI.Docking -{ - [Flags] - [Serializable] - [Editor(typeof(DockAreasEditor), typeof(System.Drawing.Design.UITypeEditor))] - public enum DockAreas - { - Float = 1, - DockLeft = 2, - DockRight = 4, - DockTop = 8, - DockBottom = 16, - Document = 32 - } - - public enum DockState - { - Unknown = 0, - Float = 1, - DockTopAutoHide = 2, - DockLeftAutoHide = 3, - DockBottomAutoHide = 4, - DockRightAutoHide = 5, - Document = 6, - DockTop = 7, - DockLeft = 8, - DockBottom = 9, - DockRight = 10, - Hidden = 11 - } - - public enum DockAlignment - { - Left, - Right, - Top, - Bottom - } - - public enum DocumentStyle - { - DockingMdi, - DockingWindow, - DockingSdi, - SystemMdi, - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/FloatWindow.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/FloatWindow.cs deleted file mode 100644 index ee17428fe7..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/FloatWindow.cs +++ /dev/null @@ -1,436 +0,0 @@ -using System; -using System.Collections; -using System.Drawing; -using System.Windows.Forms; -using System.Runtime.InteropServices; -using System.Security.Permissions; -using System.Diagnostics.CodeAnalysis; - -namespace WeifenLuo.WinFormsUI.Docking -{ - public class FloatWindow : Form, INestedPanesContainer, IDockDragSource - { - private NestedPaneCollection m_nestedPanes; - internal const int WM_CHECKDISPOSE = (int)(Win32.Msgs.WM_USER + 1); - - internal protected FloatWindow(DockPanel dockPanel, DockPane pane) - { - InternalConstruct(dockPanel, pane, false, Rectangle.Empty); - } - - internal protected FloatWindow(DockPanel dockPanel, DockPane pane, Rectangle bounds) - { - InternalConstruct(dockPanel, pane, true, bounds); - } - - private void InternalConstruct(DockPanel dockPanel, DockPane pane, bool boundsSpecified, Rectangle bounds) - { - if (dockPanel == null) - throw(new ArgumentNullException(Strings.FloatWindow_Constructor_NullDockPanel)); - - m_nestedPanes = new NestedPaneCollection(this); - - FormBorderStyle = FormBorderStyle.SizableToolWindow; - ShowInTaskbar = false; - if (dockPanel.RightToLeft != RightToLeft) - RightToLeft = dockPanel.RightToLeft; - if (RightToLeftLayout != dockPanel.RightToLeftLayout) - RightToLeftLayout = dockPanel.RightToLeftLayout; - - SuspendLayout(); - if (boundsSpecified) - { - Bounds = bounds; - StartPosition = FormStartPosition.Manual; - } - else - { - StartPosition = FormStartPosition.WindowsDefaultLocation; - Size = dockPanel.DefaultFloatWindowSize; - } - - m_dockPanel = dockPanel; - Owner = DockPanel.FindForm(); - DockPanel.AddFloatWindow(this); - if (pane != null) - pane.FloatWindow = this; - - ResumeLayout(); - } - - protected override void Dispose(bool disposing) - { - if (disposing) - { - if (DockPanel != null) - DockPanel.RemoveFloatWindow(this); - m_dockPanel = null; - } - base.Dispose(disposing); - } - - private bool m_allowEndUserDocking = true; - public bool AllowEndUserDocking - { - get { return m_allowEndUserDocking; } - set { m_allowEndUserDocking = value; } - } - - public NestedPaneCollection NestedPanes - { - get { return m_nestedPanes; } - } - - public VisibleNestedPaneCollection VisibleNestedPanes - { - get { return NestedPanes.VisibleNestedPanes; } - } - - private DockPanel m_dockPanel; - public DockPanel DockPanel - { - get { return m_dockPanel; } - } - - public DockState DockState - { - get { return DockState.Float; } - } - - public bool IsFloat - { - get { return DockState == DockState.Float; } - } - - internal bool IsDockStateValid(DockState dockState) - { - foreach (DockPane pane in NestedPanes) - foreach (IDockContent content in pane.Contents) - if (!DockHelper.IsDockStateValid(dockState, content.DockHandler.DockAreas)) - return false; - - return true; - } - - protected override void OnActivated(EventArgs e) - { - DockPanel.FloatWindows.BringWindowToFront(this); - base.OnActivated (e); - } - - protected override void OnLayout(LayoutEventArgs levent) - { - VisibleNestedPanes.Refresh(); - RefreshChanges(); - Visible = (VisibleNestedPanes.Count > 0); - SetText(); - - base.OnLayout(levent); - } - - - [SuppressMessage("Microsoft.Globalization", "CA1303:DoNotPassLiteralsAsLocalizedParameters", MessageId = "System.Windows.Forms.Control.set_Text(System.String)")] - internal void SetText() - { - DockPane theOnlyPane = (VisibleNestedPanes.Count == 1) ? VisibleNestedPanes[0] : null; - - if (theOnlyPane == null) - Text = " "; // use " " instead of string.Empty because the whole title bar will disappear when ControlBox is set to false. - else if (theOnlyPane.ActiveContent == null) - Text = " "; - else - Text = theOnlyPane.ActiveContent.DockHandler.TabText; - } - - protected override void SetBoundsCore(int x, int y, int width, int height, BoundsSpecified specified) - { - Rectangle rectWorkArea = SystemInformation.VirtualScreen; - - if (y + height > rectWorkArea.Bottom) - y -= (y + height) - rectWorkArea.Bottom; - - if (y < rectWorkArea.Top) - y += rectWorkArea.Top - y; - - base.SetBoundsCore (x, y, width, height, specified); - } - - [SecurityPermission(SecurityAction.LinkDemand, Flags = SecurityPermissionFlag.UnmanagedCode)] - protected override void WndProc(ref Message m) - { - if (m.Msg == (int)Win32.Msgs.WM_NCLBUTTONDOWN) - { - if (IsDisposed) - return; - - uint result = NativeMethods.SendMessage(this.Handle, (int)Win32.Msgs.WM_NCHITTEST, 0, (uint)m.LParam); - if (result == 2 && DockPanel.AllowEndUserDocking && this.AllowEndUserDocking) // HITTEST_CAPTION - { - Activate(); - m_dockPanel.BeginDrag(this); - } - else - base.WndProc(ref m); - - return; - } - else if (m.Msg == (int)Win32.Msgs.WM_NCRBUTTONDOWN) - { - uint result = NativeMethods.SendMessage(this.Handle, (int)Win32.Msgs.WM_NCHITTEST, 0, (uint)m.LParam); - if (result == 2) // HITTEST_CAPTION - { - DockPane theOnlyPane = (VisibleNestedPanes.Count == 1) ? VisibleNestedPanes[0] : null; - if (theOnlyPane != null && theOnlyPane.ActiveContent != null) - { - theOnlyPane.ShowTabPageContextMenu(this, PointToClient(Control.MousePosition)); - return; - } - } - - base.WndProc(ref m); - return; - } - else if (m.Msg == (int)Win32.Msgs.WM_CLOSE) - { - if (NestedPanes.Count == 0) - { - base.WndProc(ref m); - return; - } - - for (int i = NestedPanes.Count - 1; i >= 0; i--) - { - DockContentCollection contents = NestedPanes[i].Contents; - for (int j = contents.Count - 1; j >= 0; j--) - { - IDockContent content = contents[j]; - if (content.DockHandler.DockState != DockState.Float) - continue; - - if (!content.DockHandler.CloseButton) - continue; - - if (content.DockHandler.HideOnClose) - content.DockHandler.Hide(); - else - content.DockHandler.Close(); - } - } - - return; - } - else if (m.Msg == (int)Win32.Msgs.WM_NCLBUTTONDBLCLK) - { - uint result = NativeMethods.SendMessage(this.Handle, (int)Win32.Msgs.WM_NCHITTEST, 0, (uint)m.LParam); - if (result != 2) // HITTEST_CAPTION - { - base.WndProc(ref m); - return; - } - - DockPanel.SuspendLayout(true); - - // Restore to panel - foreach (DockPane pane in NestedPanes) - { - if (pane.DockState != DockState.Float) - continue; - pane.RestoreToPanel(); - } - - - DockPanel.ResumeLayout(true, true); - return; - } - else if (m.Msg == WM_CHECKDISPOSE) - { - if (NestedPanes.Count == 0) - Dispose(); - - return; - } - - base.WndProc(ref m); - } - - internal void RefreshChanges() - { - if (IsDisposed) - return; - - if (VisibleNestedPanes.Count == 0) - { - ControlBox = true; - return; - } - - for (int i=VisibleNestedPanes.Count - 1; i>=0; i--) - { - DockContentCollection contents = VisibleNestedPanes[i].Contents; - for (int j=contents.Count - 1; j>=0; j--) - { - IDockContent content = contents[j]; - if (content.DockHandler.DockState != DockState.Float) - continue; - - if (content.DockHandler.CloseButton) - { - ControlBox = true; - return; - } - } - } - ControlBox = false; - } - - public virtual Rectangle DisplayingRectangle - { - get { return ClientRectangle; } - } - - internal void TestDrop(IDockDragSource dragSource, DockOutlineBase dockOutline) - { - if (VisibleNestedPanes.Count == 1) - { - DockPane pane = VisibleNestedPanes[0]; - if (!dragSource.CanDockTo(pane)) - return; - - Point ptMouse = Control.MousePosition; - uint lParam = Win32Helper.MakeLong(ptMouse.X, ptMouse.Y); - if (NativeMethods.SendMessage(Handle, (int)Win32.Msgs.WM_NCHITTEST, 0, lParam) == (uint)Win32.HitTest.HTCAPTION) - dockOutline.Show(VisibleNestedPanes[0], -1); - } - } - - #region IDockDragSource Members - - #region IDragSource Members - - Control IDragSource.DragControl - { - get { return this; } - } - - #endregion - - bool IDockDragSource.IsDockStateValid(DockState dockState) - { - return IsDockStateValid(dockState); - } - - bool IDockDragSource.CanDockTo(DockPane pane) - { - if (!IsDockStateValid(pane.DockState)) - return false; - - if (pane.FloatWindow == this) - return false; - - return true; - } - - Rectangle IDockDragSource.BeginDrag(Point ptMouse) - { - return Bounds; - } - - public void FloatAt(Rectangle floatWindowBounds) - { - Bounds = floatWindowBounds; - } - - public void DockTo(DockPane pane, DockStyle dockStyle, int contentIndex) - { - if (dockStyle == DockStyle.Fill) - { - for (int i = NestedPanes.Count - 1; i >= 0; i--) - { - DockPane paneFrom = NestedPanes[i]; - for (int j = paneFrom.Contents.Count - 1; j >= 0; j--) - { - IDockContent c = paneFrom.Contents[j]; - c.DockHandler.Pane = pane; - if (contentIndex != -1) - pane.SetContentIndex(c, contentIndex); - } - } - } - else - { - DockAlignment alignment = DockAlignment.Left; - if (dockStyle == DockStyle.Left) - alignment = DockAlignment.Left; - else if (dockStyle == DockStyle.Right) - alignment = DockAlignment.Right; - else if (dockStyle == DockStyle.Top) - alignment = DockAlignment.Top; - else if (dockStyle == DockStyle.Bottom) - alignment = DockAlignment.Bottom; - - MergeNestedPanes(VisibleNestedPanes, pane.NestedPanesContainer.NestedPanes, pane, alignment, 0.5); - } - } - - public void DockTo(DockPanel panel, DockStyle dockStyle) - { - if (panel != DockPanel) - throw new ArgumentException(Strings.IDockDragSource_DockTo_InvalidPanel, "panel"); - - NestedPaneCollection nestedPanesTo = null; - - if (dockStyle == DockStyle.Top) - nestedPanesTo = DockPanel.DockWindows[DockState.DockTop].NestedPanes; - else if (dockStyle == DockStyle.Bottom) - nestedPanesTo = DockPanel.DockWindows[DockState.DockBottom].NestedPanes; - else if (dockStyle == DockStyle.Left) - nestedPanesTo = DockPanel.DockWindows[DockState.DockLeft].NestedPanes; - else if (dockStyle == DockStyle.Right) - nestedPanesTo = DockPanel.DockWindows[DockState.DockRight].NestedPanes; - else if (dockStyle == DockStyle.Fill) - nestedPanesTo = DockPanel.DockWindows[DockState.Document].NestedPanes; - - DockPane prevPane = null; - for (int i = nestedPanesTo.Count - 1; i >= 0; i--) - if (nestedPanesTo[i] != VisibleNestedPanes[0]) - prevPane = nestedPanesTo[i]; - MergeNestedPanes(VisibleNestedPanes, nestedPanesTo, prevPane, DockAlignment.Left, 0.5); - } - - private static void MergeNestedPanes(VisibleNestedPaneCollection nestedPanesFrom, NestedPaneCollection nestedPanesTo, DockPane prevPane, DockAlignment alignment, double proportion) - { - if (nestedPanesFrom.Count == 0) - return; - - int count = nestedPanesFrom.Count; - DockPane[] panes = new DockPane[count]; - DockPane[] prevPanes = new DockPane[count]; - DockAlignment[] alignments = new DockAlignment[count]; - double[] proportions = new double[count]; - - for (int i = 0; i < count; i++) - { - panes[i] = nestedPanesFrom[i]; - prevPanes[i] = nestedPanesFrom[i].NestedDockingStatus.PreviousPane; - alignments[i] = nestedPanesFrom[i].NestedDockingStatus.Alignment; - proportions[i] = nestedPanesFrom[i].NestedDockingStatus.Proportion; - } - - DockPane pane = panes[0].DockTo(nestedPanesTo.Container, prevPane, alignment, proportion); - panes[0].DockState = nestedPanesTo.DockState; - - for (int i = 1; i < count; i++) - { - for (int j = i; j < count; j++) - { - if (prevPanes[j] == panes[i - 1]) - prevPanes[j] = pane; - } - pane = panes[i].DockTo(nestedPanesTo.Container, prevPanes[i], alignments[i], proportions[i]); - panes[i].DockState = nestedPanesTo.DockState; - } - } - - #endregion - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/FloatWindowCollection.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/FloatWindowCollection.cs deleted file mode 100644 index 03f81b5de8..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/FloatWindowCollection.cs +++ /dev/null @@ -1,42 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Collections.ObjectModel; -using System.Drawing; -using System.Windows.Forms; - -namespace WeifenLuo.WinFormsUI.Docking -{ - public class FloatWindowCollection : ReadOnlyCollection - { - internal FloatWindowCollection() - : base(new List()) - { - } - - internal int Add(FloatWindow fw) - { - if (Items.Contains(fw)) - return Items.IndexOf(fw); - - Items.Add(fw); - return Count - 1; - } - - internal void Dispose() - { - for (int i=Count - 1; i>=0; i--) - this[i].Close(); - } - - internal void Remove(FloatWindow fw) - { - Items.Remove(fw); - } - - internal void BringWindowToFront(FloatWindow fw) - { - Items.Remove(fw); - Items.Add(fw); - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Helpers/DockHelper.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Helpers/DockHelper.cs deleted file mode 100644 index 885dd0f7e6..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Helpers/DockHelper.cs +++ /dev/null @@ -1,103 +0,0 @@ -using System; -using System.Drawing; -using System.Windows.Forms; - -namespace WeifenLuo.WinFormsUI.Docking -{ - internal static class DockHelper - { - public static bool IsDockStateAutoHide(DockState dockState) - { - if (dockState == DockState.DockLeftAutoHide || - dockState == DockState.DockRightAutoHide || - dockState == DockState.DockTopAutoHide || - dockState == DockState.DockBottomAutoHide) - return true; - else - return false; - } - - public static bool IsDockStateValid(DockState dockState, DockAreas dockableAreas) - { - if (((dockableAreas & DockAreas.Float) == 0) && - (dockState == DockState.Float)) - return false; - else if (((dockableAreas & DockAreas.Document) == 0) && - (dockState == DockState.Document)) - return false; - else if (((dockableAreas & DockAreas.DockLeft) == 0) && - (dockState == DockState.DockLeft || dockState == DockState.DockLeftAutoHide)) - return false; - else if (((dockableAreas & DockAreas.DockRight) == 0) && - (dockState == DockState.DockRight || dockState == DockState.DockRightAutoHide)) - return false; - else if (((dockableAreas & DockAreas.DockTop) == 0) && - (dockState == DockState.DockTop || dockState == DockState.DockTopAutoHide)) - return false; - else if (((dockableAreas & DockAreas.DockBottom) == 0) && - (dockState == DockState.DockBottom || dockState == DockState.DockBottomAutoHide)) - return false; - else - return true; - } - - public static bool IsDockWindowState(DockState state) - { - if (state == DockState.DockTop || state == DockState.DockBottom || state == DockState.DockLeft || - state == DockState.DockRight || state == DockState.Document) - return true; - else - return false; - } - - public static DockState ToggleAutoHideState(DockState state) - { - if (state == DockState.DockLeft) - return DockState.DockLeftAutoHide; - else if (state == DockState.DockRight) - return DockState.DockRightAutoHide; - else if (state == DockState.DockTop) - return DockState.DockTopAutoHide; - else if (state == DockState.DockBottom) - return DockState.DockBottomAutoHide; - else if (state == DockState.DockLeftAutoHide) - return DockState.DockLeft; - else if (state == DockState.DockRightAutoHide) - return DockState.DockRight; - else if (state == DockState.DockTopAutoHide) - return DockState.DockTop; - else if (state == DockState.DockBottomAutoHide) - return DockState.DockBottom; - else - return state; - } - - public static DockPane PaneAtPoint(Point pt, DockPanel dockPanel) - { - for (Control control = Win32Helper.ControlAtPoint(pt); control != null; control = control.Parent) - { - IDockContent content = control as IDockContent; - if (content != null && content.DockHandler.DockPanel == dockPanel) - return content.DockHandler.Pane; - - DockPane pane = control as DockPane; - if (pane != null && pane.DockPanel == dockPanel) - return pane; - } - - return null; - } - - public static FloatWindow FloatWindowAtPoint(Point pt, DockPanel dockPanel) - { - for (Control control = Win32Helper.ControlAtPoint(pt); control != null; control = control.Parent) - { - FloatWindow floatWindow = control as FloatWindow; - if (floatWindow != null && floatWindow.DockPanel == dockPanel) - return floatWindow; - } - - return null; - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Helpers/DrawHelper.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Helpers/DrawHelper.cs deleted file mode 100644 index cf8ab98a8e..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Helpers/DrawHelper.cs +++ /dev/null @@ -1,88 +0,0 @@ -using System; -using System.Drawing; -using System.Drawing.Drawing2D; -using System.Drawing.Imaging; -using System.Windows.Forms; - -namespace WeifenLuo.WinFormsUI.Docking -{ - internal static class DrawHelper - { - public static Point RtlTransform(Control control, Point point) - { - if (control.RightToLeft != RightToLeft.Yes) - return point; - else - return new Point(control.Right - point.X, point.Y); - } - - public static Rectangle RtlTransform(Control control, Rectangle rectangle) - { - if (control.RightToLeft != RightToLeft.Yes) - return rectangle; - else - return new Rectangle(control.ClientRectangle.Right - rectangle.Right, rectangle.Y, rectangle.Width, rectangle.Height); - } - - public static GraphicsPath GetRoundedCornerTab(GraphicsPath graphicsPath, Rectangle rect, bool upCorner) - { - if (graphicsPath == null) - graphicsPath = new GraphicsPath(); - else - graphicsPath.Reset(); - - int curveSize = 6; - if (upCorner) - { - graphicsPath.AddLine(rect.Left, rect.Bottom, rect.Left, rect.Top + curveSize / 2); - graphicsPath.AddArc(new Rectangle(rect.Left, rect.Top, curveSize, curveSize), 180, 90); - graphicsPath.AddLine(rect.Left + curveSize / 2, rect.Top, rect.Right - curveSize / 2, rect.Top); - graphicsPath.AddArc(new Rectangle(rect.Right - curveSize, rect.Top, curveSize, curveSize), -90, 90); - graphicsPath.AddLine(rect.Right, rect.Top + curveSize / 2, rect.Right, rect.Bottom); - } - else - { - graphicsPath.AddLine(rect.Right, rect.Top, rect.Right, rect.Bottom - curveSize / 2); - graphicsPath.AddArc(new Rectangle(rect.Right - curveSize, rect.Bottom - curveSize, curveSize, curveSize), 0, 90); - graphicsPath.AddLine(rect.Right - curveSize / 2, rect.Bottom, rect.Left + curveSize / 2, rect.Bottom); - graphicsPath.AddArc(new Rectangle(rect.Left, rect.Bottom - curveSize, curveSize, curveSize), 90, 90); - graphicsPath.AddLine(rect.Left, rect.Bottom - curveSize / 2, rect.Left, rect.Top); - } - - return graphicsPath; - } - - public static GraphicsPath CalculateGraphicsPathFromBitmap(Bitmap bitmap) - { - return CalculateGraphicsPathFromBitmap(bitmap, Color.Empty); - } - - // From http://edu.cnzz.cn/show_3281.html - public static GraphicsPath CalculateGraphicsPathFromBitmap(Bitmap bitmap, Color colorTransparent) - { - GraphicsPath graphicsPath = new GraphicsPath(); - if (colorTransparent == Color.Empty) - colorTransparent = bitmap.GetPixel(0, 0); - - for(int row = 0; row < bitmap.Height; row ++) - { - int colOpaquePixel = 0; - for(int col = 0; col < bitmap.Width; col ++) - { - if(bitmap.GetPixel(col, row) != colorTransparent) - { - colOpaquePixel = col; - int colNext = col; - for(colNext = colOpaquePixel; colNext < bitmap.Width; colNext ++) - if(bitmap.GetPixel(colNext, row) == colorTransparent) - break; - - graphicsPath.AddRectangle(new Rectangle(colOpaquePixel, row, colNext - colOpaquePixel, 1)); - col = colNext; - } - } - } - return graphicsPath; - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Helpers/ResourceHelper.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Helpers/ResourceHelper.cs deleted file mode 100644 index 30f3594423..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Helpers/ResourceHelper.cs +++ /dev/null @@ -1,29 +0,0 @@ -using System; -using System.Drawing; -using System.Reflection; -using System.Resources; -using System.Windows.Forms; - -namespace WeifenLuo.WinFormsUI.Docking -{ - internal static class ResourceHelper - { - private static ResourceManager _resourceManager = null; - - private static ResourceManager ResourceManager - { - get - { - if (_resourceManager == null) - _resourceManager = new ResourceManager("WeifenLuo.WinFormsUI.Docking.Strings", typeof(ResourceHelper).Assembly); - return _resourceManager; - } - - } - - public static string GetString(string name) - { - return ResourceManager.GetString(name); - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Helpers/Win32Helper.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Helpers/Win32Helper.cs deleted file mode 100644 index 473d7c5e61..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Helpers/Win32Helper.cs +++ /dev/null @@ -1,19 +0,0 @@ -using System; -using System.Drawing; -using System.Windows.Forms; - -namespace WeifenLuo.WinFormsUI.Docking -{ - internal static class Win32Helper - { - public static Control ControlAtPoint(Point pt) - { - return Control.FromChildHandle(NativeMethods.WindowFromPoint(pt)); - } - - public static uint MakeLong(int low, int high) - { - return (uint)((high << 16) + low); - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/InertButtonBase.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/InertButtonBase.cs deleted file mode 100644 index 92d5731d71..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/InertButtonBase.cs +++ /dev/null @@ -1,115 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Text; -using System.Windows.Forms; -using System.Drawing; -using System.Drawing.Imaging; - -namespace WeifenLuo.WinFormsUI.Docking -{ - internal abstract class InertButtonBase : Control - { - protected InertButtonBase() - { - SetStyle(ControlStyles.SupportsTransparentBackColor, true); - BackColor = Color.Transparent; - } - - public abstract Bitmap Image - { - get; - } - - private bool m_isMouseOver = false; - protected bool IsMouseOver - { - get { return m_isMouseOver; } - private set - { - if (m_isMouseOver == value) - return; - - m_isMouseOver = value; - Invalidate(); - } - } - - protected override Size DefaultSize - { - get { return Resources.DockPane_Close.Size; } - } - - protected override void OnMouseMove(MouseEventArgs e) - { - base.OnMouseMove(e); - bool over = ClientRectangle.Contains(e.X, e.Y); - if (IsMouseOver != over) - IsMouseOver = over; - } - - protected override void OnMouseEnter(EventArgs e) - { - base.OnMouseEnter(e); - if (!IsMouseOver) - IsMouseOver = true; - } - - protected override void OnMouseLeave(EventArgs e) - { - base.OnMouseLeave(e); - if (IsMouseOver) - IsMouseOver = false; - } - - protected override void OnPaint(PaintEventArgs e) - { - if (IsMouseOver && Enabled) - { - using (Pen pen = new Pen(ForeColor)) - { - e.Graphics.DrawRectangle(pen, Rectangle.Inflate(ClientRectangle, -1, -1)); - } - } - - using (ImageAttributes imageAttributes = new ImageAttributes()) - { - ColorMap[] colorMap = new ColorMap[2]; - colorMap[0] = new ColorMap(); - colorMap[0].OldColor = Color.FromArgb(0, 0, 0); - colorMap[0].NewColor = ForeColor; - colorMap[1] = new ColorMap(); - colorMap[1].OldColor = Image.GetPixel(0, 0); - colorMap[1].NewColor = Color.Transparent; - - imageAttributes.SetRemapTable(colorMap); - - e.Graphics.DrawImage( - Image, - new Rectangle(0, 0, Image.Width, Image.Height), - 0, 0, - Image.Width, - Image.Height, - GraphicsUnit.Pixel, - imageAttributes); - } - - base.OnPaint(e); - } - - public void RefreshChanges() - { - if (IsDisposed) - return; - - bool mouseOver = ClientRectangle.Contains(PointToClient(Control.MousePosition)); - if (mouseOver != IsMouseOver) - IsMouseOver = mouseOver; - - OnRefreshChanges(); - } - - protected virtual void OnRefreshChanges() - { - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Interfaces.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Interfaces.cs deleted file mode 100644 index 32f3914b34..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Interfaces.cs +++ /dev/null @@ -1,45 +0,0 @@ -using System; -using System.Drawing; -using System.Windows.Forms; - -namespace WeifenLuo.WinFormsUI.Docking -{ - public interface IDockContent - { - DockContentHandler DockHandler { get; } - bool IsDisposed { get; } - } - - public interface INestedPanesContainer - { - DockState DockState { get; } - Rectangle DisplayingRectangle { get; } - NestedPaneCollection NestedPanes { get; } - VisibleNestedPaneCollection VisibleNestedPanes { get; } - bool IsFloat { get; } - } - - internal interface IDragSource - { - Control DragControl { get; } - } - - internal interface IDockDragSource : IDragSource - { - Rectangle BeginDrag(Point ptMouse); - bool IsDockStateValid(DockState dockState); - bool CanDockTo(DockPane pane); - void FloatAt(Rectangle floatWindowBounds); - void DockTo(DockPane pane, DockStyle dockStyle, int contentIndex); - void DockTo(DockPanel panel, DockStyle dockStyle); - } - - internal interface ISplitterDragSource : IDragSource - { - void BeginDrag(Rectangle rectSplitter); - void EndDrag(); - bool IsVertical { get; } - Rectangle DragLimitBounds { get; } - void MoveSplitter(int offset); - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Localization.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Localization.cs deleted file mode 100644 index c6f71afa53..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Localization.cs +++ /dev/null @@ -1,46 +0,0 @@ -using System; -using System.ComponentModel; - -namespace WeifenLuo.WinFormsUI.Docking -{ - [AttributeUsage(AttributeTargets.All)] - internal sealed class LocalizedDescriptionAttribute : DescriptionAttribute - { - private bool m_initialized = false; - - public LocalizedDescriptionAttribute(string key) : base(key) - { - } - - public override string Description - { - get - { - if (!m_initialized) - { - string key = base.Description; - DescriptionValue = ResourceHelper.GetString(key); - if (DescriptionValue == null) - DescriptionValue = String.Empty; - - m_initialized = true; - } - - return DescriptionValue; - } - } - } - - [AttributeUsage(AttributeTargets.All)] - internal sealed class LocalizedCategoryAttribute : CategoryAttribute - { - public LocalizedCategoryAttribute(string key) : base(key) - { - } - - protected override string GetLocalizedString(string key) - { - return ResourceHelper.GetString(key); - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Measures.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Measures.cs deleted file mode 100644 index d1c591f394..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Measures.cs +++ /dev/null @@ -1,14 +0,0 @@ -using System; - -namespace WeifenLuo.WinFormsUI.Docking -{ - internal static class Measures - { - public const int SplitterSize = 4; - } - - internal static class MeasurePane - { - public const int MinSize = 24; - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/NestedDockingStatus.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/NestedDockingStatus.cs deleted file mode 100644 index 8d0de44ae5..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/NestedDockingStatus.cs +++ /dev/null @@ -1,108 +0,0 @@ -using System; -using System.Drawing; - -namespace WeifenLuo.WinFormsUI.Docking -{ - public sealed class NestedDockingStatus - { - internal NestedDockingStatus(DockPane pane) - { - m_dockPane = pane; - } - - private DockPane m_dockPane = null; - public DockPane DockPane - { - get { return m_dockPane; } - } - - private NestedPaneCollection m_nestedPanes = null; - public NestedPaneCollection NestedPanes - { - get { return m_nestedPanes; } - } - - private DockPane m_previousPane = null; - public DockPane PreviousPane - { - get { return m_previousPane; } - } - - private DockAlignment m_alignment = DockAlignment.Left; - public DockAlignment Alignment - { - get { return m_alignment; } - } - - private double m_proportion = 0.5; - public double Proportion - { - get { return m_proportion; } - } - - private bool m_isDisplaying = false; - public bool IsDisplaying - { - get { return m_isDisplaying; } - } - - private DockPane m_displayingPreviousPane = null; - public DockPane DisplayingPreviousPane - { - get { return m_displayingPreviousPane; } - } - - private DockAlignment m_displayingAlignment = DockAlignment.Left; - public DockAlignment DisplayingAlignment - { - get { return m_displayingAlignment; } - } - - private double m_displayingProportion = 0.5; - public double DisplayingProportion - { - get { return m_displayingProportion; } - } - - private Rectangle m_logicalBounds = Rectangle.Empty; - public Rectangle LogicalBounds - { - get { return m_logicalBounds; } - } - - private Rectangle m_paneBounds = Rectangle.Empty; - public Rectangle PaneBounds - { - get { return m_paneBounds; } - } - - private Rectangle m_splitterBounds = Rectangle.Empty; - public Rectangle SplitterBounds - { - get { return m_splitterBounds; } - } - - internal void SetStatus(NestedPaneCollection nestedPanes, DockPane previousPane, DockAlignment alignment, double proportion) - { - m_nestedPanes = nestedPanes; - m_previousPane = previousPane; - m_alignment = alignment; - m_proportion = proportion; - } - - internal void SetDisplayingStatus(bool isDisplaying, DockPane displayingPreviousPane, DockAlignment displayingAlignment, double displayingProportion) - { - m_isDisplaying = isDisplaying; - m_displayingPreviousPane = displayingPreviousPane; - m_displayingAlignment = displayingAlignment; - m_displayingProportion = displayingProportion; - } - - internal void SetDisplayingBounds(Rectangle logicalBounds, Rectangle paneBounds, Rectangle splitterBounds) - { - m_logicalBounds = logicalBounds; - m_paneBounds = paneBounds; - m_splitterBounds = splitterBounds; - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/NestedPaneCollection.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/NestedPaneCollection.cs deleted file mode 100644 index 0d0ae708cc..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/NestedPaneCollection.cs +++ /dev/null @@ -1,116 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Collections.ObjectModel; -using System.Drawing; - -namespace WeifenLuo.WinFormsUI.Docking -{ - public sealed class NestedPaneCollection : ReadOnlyCollection - { - private INestedPanesContainer m_container; - private VisibleNestedPaneCollection m_visibleNestedPanes; - - internal NestedPaneCollection(INestedPanesContainer container) - : base(new List()) - { - m_container = container; - m_visibleNestedPanes = new VisibleNestedPaneCollection(this); - } - - public INestedPanesContainer Container - { - get { return m_container; } - } - - public VisibleNestedPaneCollection VisibleNestedPanes - { - get { return m_visibleNestedPanes; } - } - - public DockState DockState - { - get { return Container.DockState; } - } - - public bool IsFloat - { - get { return DockState == DockState.Float; } - } - - internal void Add(DockPane pane) - { - if (pane == null) - return; - - NestedPaneCollection oldNestedPanes = (pane.NestedPanesContainer == null) ? null : pane.NestedPanesContainer.NestedPanes; - if (oldNestedPanes != null) - oldNestedPanes.InternalRemove(pane); - Items.Add(pane); - if (oldNestedPanes != null) - oldNestedPanes.CheckFloatWindowDispose(); - } - - private void CheckFloatWindowDispose() - { - if (Count == 0 && Container.DockState == DockState.Float) - { - FloatWindow floatWindow = (FloatWindow)Container; - if (!floatWindow.Disposing && !floatWindow.IsDisposed) - NativeMethods.PostMessage(((FloatWindow)Container).Handle, FloatWindow.WM_CHECKDISPOSE, 0, 0); - } - } - - internal void Remove(DockPane pane) - { - InternalRemove(pane); - CheckFloatWindowDispose(); - } - - private void InternalRemove(DockPane pane) - { - if (!Contains(pane)) - return; - - NestedDockingStatus statusPane = pane.NestedDockingStatus; - DockPane lastNestedPane = null; - for (int i=Count - 1; i> IndexOf(pane); i--) - { - if (this[i].NestedDockingStatus.PreviousPane == pane) - { - lastNestedPane = this[i]; - break; - } - } - - if (lastNestedPane != null) - { - int indexLastNestedPane = IndexOf(lastNestedPane); - Items.Remove(lastNestedPane); - Items[IndexOf(pane)] = lastNestedPane; - NestedDockingStatus lastNestedDock = lastNestedPane.NestedDockingStatus; - lastNestedDock.SetStatus(this, statusPane.PreviousPane, statusPane.Alignment, statusPane.Proportion); - for (int i=indexLastNestedPane - 1; i>IndexOf(lastNestedPane); i--) - { - NestedDockingStatus status = this[i].NestedDockingStatus; - if (status.PreviousPane == pane) - status.SetStatus(this, lastNestedPane, status.Alignment, status.Proportion); - } - } - else - Items.Remove(pane); - - statusPane.SetStatus(null, null, DockAlignment.Left, 0.5); - statusPane.SetDisplayingStatus(false, null, DockAlignment.Left, 0.5); - statusPane.SetDisplayingBounds(Rectangle.Empty, Rectangle.Empty, Rectangle.Empty); - } - - public DockPane GetDefaultPreviousPane(DockPane pane) - { - for (int i=Count-1; i>=0; i--) - if (this[i] != pane) - return this[i]; - - return null; - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources.Designer.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources.Designer.cs deleted file mode 100644 index 076e5ddf6d..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources.Designer.cs +++ /dev/null @@ -1,224 +0,0 @@ -//------------------------------------------------------------------------------ -// -// This code was generated by a tool. -// Runtime Version:2.0.50727.42 -// -// Changes to this file may cause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -namespace WeifenLuo.WinFormsUI.Docking { - using System; - - - /// - /// A strongly-typed resource class, for looking up localized strings, etc. - /// - // This class was auto-generated by the StronglyTypedResourceBuilder - // class via a tool like ResGen or Visual Studio. - // To add or remove a member, edit your .ResX file then rerun ResGen - // with the /str option, or rebuild your VS project. - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "2.0.0.0")] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] - internal class Resources { - - private static global::System.Resources.ResourceManager resourceMan; - - private static global::System.Globalization.CultureInfo resourceCulture; - - [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] - internal Resources() { - } - - /// - /// Returns the cached ResourceManager instance used by this class. - /// - [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] - internal static global::System.Resources.ResourceManager ResourceManager { - get { - if (object.ReferenceEquals(resourceMan, null)) { - global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("WeifenLuo.WinFormsUI.Docking.Resources", typeof(Resources).Assembly); - resourceMan = temp; - } - return resourceMan; - } - } - - /// - /// Overrides the current thread's CurrentUICulture property for all - /// resource lookups using this strongly typed resource class. - /// - [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] - internal static global::System.Globalization.CultureInfo Culture { - get { - return resourceCulture; - } - set { - resourceCulture = value; - } - } - - internal static System.Drawing.Bitmap DockIndicator_PaneDiamond { - get { - object obj = ResourceManager.GetObject("DockIndicator_PaneDiamond", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockIndicator_PaneDiamond_Bottom { - get { - object obj = ResourceManager.GetObject("DockIndicator_PaneDiamond_Bottom", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockIndicator_PaneDiamond_Fill { - get { - object obj = ResourceManager.GetObject("DockIndicator_PaneDiamond_Fill", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockIndicator_PaneDiamond_HotSpot { - get { - object obj = ResourceManager.GetObject("DockIndicator_PaneDiamond_HotSpot", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockIndicator_PaneDiamond_HotSpotIndex { - get { - object obj = ResourceManager.GetObject("DockIndicator_PaneDiamond_HotSpotIndex", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockIndicator_PaneDiamond_Left { - get { - object obj = ResourceManager.GetObject("DockIndicator_PaneDiamond_Left", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockIndicator_PaneDiamond_Right { - get { - object obj = ResourceManager.GetObject("DockIndicator_PaneDiamond_Right", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockIndicator_PaneDiamond_Top { - get { - object obj = ResourceManager.GetObject("DockIndicator_PaneDiamond_Top", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockIndicator_PanelBottom { - get { - object obj = ResourceManager.GetObject("DockIndicator_PanelBottom", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockIndicator_PanelBottom_Active { - get { - object obj = ResourceManager.GetObject("DockIndicator_PanelBottom_Active", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockIndicator_PanelFill { - get { - object obj = ResourceManager.GetObject("DockIndicator_PanelFill", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockIndicator_PanelFill_Active { - get { - object obj = ResourceManager.GetObject("DockIndicator_PanelFill_Active", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockIndicator_PanelLeft { - get { - object obj = ResourceManager.GetObject("DockIndicator_PanelLeft", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockIndicator_PanelLeft_Active { - get { - object obj = ResourceManager.GetObject("DockIndicator_PanelLeft_Active", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockIndicator_PanelRight { - get { - object obj = ResourceManager.GetObject("DockIndicator_PanelRight", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockIndicator_PanelRight_Active { - get { - object obj = ResourceManager.GetObject("DockIndicator_PanelRight_Active", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockIndicator_PanelTop { - get { - object obj = ResourceManager.GetObject("DockIndicator_PanelTop", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockIndicator_PanelTop_Active { - get { - object obj = ResourceManager.GetObject("DockIndicator_PanelTop_Active", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockPane_AutoHide { - get { - object obj = ResourceManager.GetObject("DockPane_AutoHide", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockPane_Close { - get { - object obj = ResourceManager.GetObject("DockPane_Close", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockPane_Dock { - get { - object obj = ResourceManager.GetObject("DockPane_Dock", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockPane_Option { - get { - object obj = ResourceManager.GetObject("DockPane_Option", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - - internal static System.Drawing.Bitmap DockPane_OptionOverflow { - get { - object obj = ResourceManager.GetObject("DockPane_OptionOverflow", resourceCulture); - return ((System.Drawing.Bitmap)(obj)); - } - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources.resx b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources.resx deleted file mode 100644 index 0f8b146299..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources.resx +++ /dev/null @@ -1,190 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - - Resources\DockIndicator_PaneDiamond.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockIndicator_PaneDiamond_Bottom.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockIndicator_PaneDiamond_Fill.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockIndicator_PaneDiamond_HotSpot.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockIndicator_PaneDiamond_HotSpotIndex.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockIndicator_PaneDiamond_Left.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockIndicator_PaneDiamond_Right.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockIndicator_PaneDiamond_Top.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockIndicator_PanelBottom.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockIndicator_PanelBottom_Active.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockIndicator_PanelFill.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockIndicator_PanelFill_Active.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockIndicator_PanelLeft.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockIndicator_PanelLeft_Active.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockIndicator_PanelRight.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockIndicator_PanelRight_Active.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockIndicator_PanelTop.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockIndicator_PanelTop_Active.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockPane_AutoHide.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockPane_Close.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockPane_Dock.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockPane_Option.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - - Resources\DockPane_OptionOverflow.bmp;System.Drawing.Bitmap, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - - \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PaneDiamond.bmp b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PaneDiamond.bmp deleted file mode 100644 index 70e70e288d70741ca264944ab528dd070fae23f0..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 23286 zcmeI4ZEqFF6@baV=ugNm$d^`0Nfjg_I}T|YP?DxikV6WDmJl$QhCmZAZAhXB0Zj@8 zfk?rhT9ts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sT(zYx86Zd!3W{XtbBI+&lJodz z%;x<<`h{{xJx;>GtgGeyB7D!1O2w9|!id_E1U~}`P3wY9$w5jq>nNEorp$X*1O39z zn{*ez0pKH(M0u^5@N9 zzF?eW9cA7(%krKjl}aKYayNg~*?-?mLnh^VGFBhdpa|Ln^M!ryw(~`U>nO8+7&~Ix zgK|iiFMJ(hIiQlDkO@?jO!D>pf>h)m$xzw)MY|H=Y~Qnj@qun`-!~7XdG8j}8#Xu$ zaJg9GsD-OuhHxy0eD(DEg_z#3!C`>Q#S%v?ROej4N_)sxPvtN=I*NsQ=bfD&^sdM4 zdE;gAcW++%-m5RX-Lvv{>sD-EvwYjCCtrW|v5m_gdgY1x*FDy;=AmWculmtF&vh0_5$i;``@#Dvb zhK76;O`4x*x2`cu@M=rQMR_vGFp>F5$S1w z?KQHJ_Rw+=cox^?KpZw#L)Y#bV&s9k{i3KGsHx7UQfuG8NjL}!zxpb>g+E3)U~NGh#|$7v1=^Nqj7B2#q}SgMf{u@`7>TkP>z! z999(x1b($F67vlN^8p0woX;Z^i~~k7Qh;?eN0hM=Vp+p?oc(eRlJILeL4@F^xm&RIzyU4m z%-4`OQGoq@J`jE@3Au6hGfEgDB|^bCU_i%lTp0_pxKMJ<*R=GO1`5U@m;c`^!1#b= zvw7oY>v9nD@t!SNtj4j{*w}Z{#Vq960HQlx@2T(L`K2`&6 Oi*i8i+^>Zj3cdw(sg<(; diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PaneDiamond_Hotspot.bmp b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PaneDiamond_Hotspot.bmp deleted file mode 100644 index e801d382d77400616c5ba7c40646e5a387b0c992..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 23286 zcmeI3J#K?Q5Joq*$Psda93XxAD5uG#(nm4{9VHC{|D7SN^Vv(#CtA-)Sb8Ijur1Gy zp5IJi)^G2>pXC;>I=|@gF+ZNl^X>JY`Tg6I`E<#N@0`dfHZiL(TuO;Ot~nnq;84FY zIKaVs7a#BeADjR_I1T0lKH!5Bzz3(ne82~Ma02+?G?)+gfDcXpADjmB0Uz+e3Ful) z(f57qkM_!TKA*4c_8?IqjN_QW;Zaa55RS)V5{K=ha0se4kHeNxtRQ4_*d_`=7=~e* zCbfeqtdZ(NT|( z!T}E6SNMPr_}~Qa!D%ob@Bts306sVk<^w+9gA>39r@?%{2Yhe>_~0~{5BPu&P5>XA z2J-1+PLZMj^&O!StwAG}}gg}#%QdKK7 zF2XrztBH2qD1TDr;b~Q>BAi1_8(wW{!Xyri03VzN^8p|5!3p4l(_lW}!^#IK5gxuo?DZdhY962f diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PaneDiamond_HotspotIndex.bmp b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PaneDiamond_HotspotIndex.bmp deleted file mode 100644 index e5ef472c56cb9258fdaa5b45bf9df1d5adbcd38c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 90 tcmZ?rjbeZRGa#h_#LQ64$RGihPyv&u#D5@QU;q<93MkhAk%tL`gaEYn5c~iD diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PaneDiamond_Left.bmp b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PaneDiamond_Left.bmp deleted file mode 100644 index 1fbda61c089c95635644e4f5d01905477db17842..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 23286 zcmeI4?Qc~@8o=?t@K5kB@QX$ljU0zJhW0!*1gKW}b7N4(H|e+;h*>-UBDo$=v6hnR(_n zuV{&Ae-^yx`rpKRoZ(#$2B^=4yIDPswG`>!IDamH%Fg7+;C=@6~x{J7=pg|G6F_qT9RMA=c z#XEnvbNl?eQah5ODdmI1`{aIeckn>YI7|a0!is7^AouVi!%}lmrGYU7!f~k3O;B3;wlGT6?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~YEk(9KDrh`De%*ugh*j)8pOV|)2mFxD4ymFwVI-g3Z!~PY*K~RK? zuaYZ=gBCe5aFv5#xym7z9N0CbX4Cn3nm1+lIEA0Heu144Qv$o_#;=UwV{t=h|-j=83zt2VOPRoRgr+_my04X-#{=QK(NmFJVMSmU=%aX`M`wVg~mNk6G*)QiH@xPYiJ>dN` zcXQSrIG|;n`5F=@3b4P=1pIF$Avex`MhQctJdiUE7|?MXSH^-Y&X-*FH7&iRft+#3 zsy{T7|wg=g=uG4(%nr@qy W11Rb@AFBbkNjac)=2zoJg8u`JR+iHM diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PaneDiamond_Right.bmp b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PaneDiamond_Right.bmp deleted file mode 100644 index 1de97a098639b0bb45e11c38ba76ebd8e103e8cf..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 23286 zcmeI4Yi||R8i4U%_!ImEe$l9CB*C<&-Zkp+Mk*?ZB4V*9!ciz5@thc2_o7kM^N@5$nq)3{;dkQl#coEJd@#IzA|#^KaR;nc`J=e%iX3nl7#J8C8DUc{l0&%4k&+y6pfQY(kC)5kcdL$sk=0jW4mbc| zVq&6FsZbZKSFM4j=D=t6&Lx}+Nl2e_+bcW zPF;R4Y{mW7v*p*%-~Rctjpsgo?Z@t}@3yZ#_1<$+Z!IftTzq^(`{Azp#UK0E-J`2+ zFLkyJceIdJ_w6l)CO{Dh0ll}s(uv!)ZpHgAE#Lg&(oN4lv9aT^|14|&_mYR!K7QZo z_PbU-cx%Uf|5$d{P2w-Pecs}muYa`l+V-2ShJ)I1lmmfT+bZH9xXNc6o`on-iFE=~ zB(p=dm93szhA7A?lM7?+~|AgBQ@E5mf4vSdpik2Lcl4_JXC zB@I$c^@OC$A)r#E=1GL^$VL@PrBY8%Ph_h@-rL*j-i?%ygNvdH*d*#{9Mv)&`{A-C{%Zdi{5-;s170S@`-<0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KQ$X&q2hp>kJ`gx+ zLZK9m0_ij-m2vzaV+wz=8h${xFI< z%}=yj*O(=EwIxu6Y+Q<&ER+O{0S;~lp(6E|pIqx$00QNPborYF0TgblV5qFek+WLI z-0m<7A;>duQD_Ir@Z2DW3bZ@SS_lCYj1`Ps*`6cid<9hLakCtPi$dmNdPm&3;)LCp z4n?h{Uocv-PG|}UiUMt!$e5ZLBr`l$+(Zx*MRg8rrm?Tc-ln>^?KN!=O$PxKN!kOO ztG;Uq8)Af~+b{CUftu=kDzyYPSJ5w5;UE*=hA<;cJ#4ua(phg@=C*OVul&d<}l zDZ9rh{G9a*?2MQa*hM#fWegvS8$u)ZeJ^06sXS*KIHZJK35Qih0-j$kio|>a!F&M0 zI_L8UIpcs)%sA%*7bbknd;!CJ2gCpBg%`*9Vn)t5aQpz1G1f8Tn}GdHihd47gzC?H zK_zeBMd64tRzfUm_>Qw*&OzdTEys)C{WN!T)*d*ZWu5sN5+@3~1zDUgIqz#)dP@U2#?9vCAm-z(YtvYb!`9d) s<&cT_nC(rynv{cVS=VVkc1^d<%K;Sin~&9i+oT*&JM$}Y&ngq)pNSxqvj6}9 diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PaneDiamond_Top.bmp b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PaneDiamond_Top.bmp deleted file mode 100644 index 95122a0f31b83e03b34977ac7fdea926907d9a83..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 23286 zcmeI4?Q<2?8Nk#3qJKjFf_`a7iyfK4NgB0Q9ktfVM64h!A_hZ6s6uGPb~=nwEmTGZ z3;EPe5vG;QTn3U!Ow7F`hVVAIF`A zo|u?8bLPy&ix(I2xX81G8n-5Em&1h%7ohQR)=NpYJBR7%=~AggEwWvt1qBU?5BPjo&C9ZHmCKR%CgXL+1c4ztwvq6UX2FYngcVPLSSDpFAnXsMHzu09Im|6cX@B`r9B%K-g>U~ z=Gu$9R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?{UR72hRDRs z7m4kmGfjK&=ZmC@yKabs+o|IC@M*&xDsY?b3l7xaH z8TuSzm67B;J{q%mzmR^R98!;ya4_p?dA|tXv!qh7<*G2Ewj{yNfI`!{U{i9C63seF z=8GBgp4C9Vu=6IJh^3dEFYNn8xUQxyTHmAq3b<-ZT{1wBB$N`#FeL{`&N4XQ;I1F+ z8p+KTg}MBBGng+JCs{|C_sz1rXGx`!2#DOxUv>81H`9^4g*{+mN;tRs+S=g%OPJq{eB^)H*9bi;Bv9VQ47^M7qHSE^3_v0jE|3F zq27IG_q+WYar<6b??%mIHFI&}lhi{34gX)|MSmB_yLIUq@+qie@^Xc_`s`HMOE55-?1pCr#(X;z4 z9M~A-?8>QAr$E70aJGx{Kd~k)IH=C~nm7T%g#`^e8bzZ(HqA*T98R1#!IS|CS_S`U znC;^93#WkGV-KQdOMM`4)PzDQ8U?axPAcU93R(p;nza6=}x&2@Wg=s0W{}M5T=5qj9c=_5c+edk z^*OMa#=atZo9dFb*R(yrA!RFCLeXx<0ae*t4PB>ih>^Ou{i3KGsHx7UNl)+=;UFlI zAjsXq_lr8!*ITzvd(bM!25xf@ECu7ht|>Lj<`-#vklo`9e!i9AwM7N%OI5 bx@}($plIHFtOndRAe1M3Ss(A#J zSb@8oUU^0+~+#2UDs_Vo=6tmGS@k%nXQrYkOrA%bj#dkgly(N;QIakcs!0zDb6B$ z#y?5QyoXRIluRZmw=`)kPM8*LBZcwdg$IWB*5ldxhtszQQ#bYrqk9vU-TcL#s98&W z_{`4G=^cUL?Qc$Yfa`L(>b}Q3&!P=;{IuPepF?#=asU7T diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PanelBottom_Active.bmp b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PanelBottom_Active.bmp deleted file mode 100644 index 212fb0d366643c01ddb73ad88d5caac25db236fc..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2782 zcmds(+iTNc7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;&82hd3#ZrQPA<>vD^BgoOKi=G zX-EyPP6#TG@hcAZf{=M3ZaD!?8NT+ZUN%7UZ``PoPCKLcsPd0CV;=cmMzZ diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PanelLeft.bmp b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PanelLeft.bmp deleted file mode 100644 index 551fd88624747761b970c653d7449ec33dbddc13..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2838 zcmZ?r72{?A12Z700mSk^EDOYp3=%++f#Crcm_i}8(h>k|0vdnf#EHw7FW`yRCc zn)yI0u3o(gw2MLjGz8*WH1mPtM~@!eOECZ%0yGL37-;6taSWmg0y+>F0$9y|cybF6 zJwCnt>ABr6E**Sz?bzGfr{CYd@bS@=&rhxc(SJe!=t3gRe}3t}t7}I==HI*U=^@B` zpk6}8|0l-$N2j+vJ-6ot(ERI1-`)b5{}F6HwcP&*96nI@-#Y!_K2_a+VhhmxC+Bt} zhtJ1HSE(5OAorgKn|~b~zj(ucZ;~5wq!0-I6NvN!az8BmKjBC}tNeZUCX-@5EPaB* z2bMm8@e4K|E&TwwK=b#ImuYzYodo zKe6TU8F2c!49Z_X^Fiq!NBFNKHGI(G7o2}T0MidP_d}8mY3TKr|6z&4-Vm_6^|LL64Co_wl&n<_L5bmRCc@HLM-|J7i-JNu^Bldbr)YXR2OSJ(P zt9&8kxiZhQC9bE7oKF=v;t&7dd*^=NIrGnf1rQR#{knDXrwzUDSGB)h+VFf{<>MK} z_b2Dv=}EoO9tR<>Hbq>n3%O9`f3DmIXg;3$cWGx85G`)2fROW>OXt)VPOr(GT%Ori zoZ6L_*qRm7kQ!c{5L6!HR~+sIA@f4qasr$(eC<=cY=GvYwI7ZhJ9hEn#p~Cv0~;08 s1(5c`kt0XWoH+xug2HAGrgn(=2M!znS^@M0upviX05P9-El{BO02Xyfj{pDw diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PanelLeft_Active.bmp b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PanelLeft_Active.bmp deleted file mode 100644 index 5182318ed3d451f969799e09333f85e60ede5ad8..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2838 zcmZ?r72{?A12Z700mSk^EDOYp3=%++f#Crcm_i}`GceE&0c`>re&WQ5%a1 zwE>#>Kr60Zy$ZC8LI5-b;#xHGf#OGx9^FeZ02%@`3K$q@=Ff2qq6z{!5Euej&3|}u z3lKd%z5VIA-7hX3e0A;E+uNt#-@owj(Us3nt^?73LICJOBF%q(>A>?#=LOLG>qp<-0-662Y(BNz{|FpDQ1{W(EKOo zb|Z(+$46JG82%vlp9h%m^^aFA~Ec`#=NI$FmefK7lVm>T= zg2M-vK7sKIHXkkh0J%W(_mJd%u=$AaxpwRgDE*(uO#eW`$u=L9zo6lN^bI8a;B>za z$?iX~tEhk_~C;2NwP)=^vQCaJU~i zWkT4%NFiAMK=K!;e1Mccu<{M47t=sA5n|1U#4pf%VEDtz2Wpi+(DVb0Uts_F-&$A`2r;D6V6*%G#|KEG(e&0Fs&w&LH62kqub@HbTz3*4Gzh2t#d|u__ z8O8S}=iKQ@z0n>AA+I(?T&@ebQ00HF+y`hrp89ubXB7}FZmWQh^P5ZO)E7>#$(>xD z*;ky}m6zC>71NL!UY!tB9^+RW?gb(9Lfmo!oHBgvQ@w0}=A*SAjvYI8@#4kn*RKN` s71RZg_QR1QN6wr%1GIv|W)G%zi1`N&8~|DY^aZdXM_m9hpQi0k0Kv25U;qFB diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PanelRight.bmp b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PanelRight.bmp deleted file mode 100644 index 003cbb02a6df99653e66cf887fff26d684f97f09..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2838 zcmZ?r72{?A12Z700mSk^EDOYp3=%++f#Crcm_i}8(h>k|0vdnf#EHw7FW`yRCc zn)yI0fZ*!Yt3c~00YDRg<^UawWA;h7yC0w4{_x}$AOgCO67zxDf#!dLn1B29 ztLsOfUpn~o-0nwIG9Tgod*|Om%|Gz;+#YI~4{`s;hgaUi&A)u$>3OP!55)bSfaXKP z9~eFdo}4EqeD)@}Va7Jp{qXR=cJu`}e#r=*JxOjW{e97_fVv;ad`S8s&-_*XK0pT} zTLDi$AMRZM#qTvx_yE%nG<}{RA$bIN<{zYD`G812 zK=Xm&4+$T#;ukGsAY5qr0p(wC`ngVi_+T|37XDYE=7ZBGFnmDaPh$GPYChckACSri z>X)C8@BxQEuzUcQpWBEj|DVn&eKND?`P^~{3E@7PmiJ(C_PzeJ+ucbwJ7TZ5L|ttN zy;K`;vC0=ho-6Y_TjF}U$oW)(BhZ6*>X+Yp=YHQg^Ur|=5E8=ux^?oW4ZZJIwZC54 z@O)n7;~B;GC+FPhNxjh?2O+OEMO>~6xlrYQt{haJ;HiI?c2)t=;$$Wa$S%%@!o6lgvGL|{nP diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PanelRight_Active.bmp b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PanelRight_Active.bmp deleted file mode 100644 index dad423551dc270a8fc196ced8f72bf9c9e01ecac..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2838 zcmZ?r72{?A12Z700mSk^EDOYp3=%++f#Crcm_i}`GceE&0d3m4b?b=}CoW&UeEat8 zdsGELXQP=9v;qjOUcCymjuHSg0cZ}U`9Sdt7cLw+bZ9SS;ONn#K%+3tpW_%r6$Er0 z(EC`;|4#^fesUd%K0dng{{Drxw@$yhcI^4315eKFetdfS!;@Qp2EP3IyB|@>e1!Y&oqr28|G?98d#GhT#Qh&1UU?5U|MG#S=cyJx5chuq znhyV72iA?b%a^H=%% z03D2M1w8$HxOV{*zt=$F157{A^m&4W^a*tTDt}*~fyh=MrJoCLKdNHkd1Kv{qt`?;RDLQ!1PH*_!CG!(C`PEe~^mh z10wwZ%?E}*Bz(w4re>$i1$;_hXbITzlg!^b(-h;{6_xjUrcPHKKh`rtt zb+sY%Qfcy!1f^k Dd#2bL diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PanelTop.bmp b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockIndicator_PanelTop.bmp deleted file mode 100644 index f6293fd2bc2b474bdb32322ee92ba986f7fa0233..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2870 zcmZ?rHREOg12Z700mQOEtN_G}3=%*R2%z#14uqV!Vht@2!`7`^PnfA?H~^T^+FtnZZ1&b=+UEl$pt{YKofv|MmKkkV-O_>=pLX)v77s! zTmW>?sJXzvBRL%QCb{iRcH5JLKtK`9SRmP4pb@M5ePPIFrN1wxq2#z1VhTL{VKtO| zb0Io$8A_44cnlqW=6-&19T-LAk@)g4&_wbOf%NFttPCzrz})xuFTB48LLXoZ2>1Q{^AM2_Kv|#^1l>FT9*Dqf0_MKGeHw&rff1a2 z`}7+ix&=Z|1rRk51z!l6P=T$zQQG9=L&Yhmr8|`rr@@iAW<+_jyRsQG7eSqfTtml_@RsqrCwu<@9 zrE}^Fr`P08F3;>MPVLG|Y|V;kNDZ$}2r7^9D-QR9ka;0)IRQ=?zV@kJHb8UH+a<@2 z9lLn(;`Qs-fvpv)0BF19$dMyw&YS@nO{89I?YNv{O`%R=bZb?okz%Rv$w1j zsI|av#8{890b`A@4j#tqY{LA!AOxR0Yp%c)Fk-P-Hk(ydHQyww=K?LuGQPu_VJ+KS zJr{*&G#a*QSPKHKxt<$p?OKhnA6)3-+dg%xvw z7gMkG;0KGsuxl$Gm9!pO!<@!(b$ChO^p*xQq^KL z{uP=e;ti~aHPG0ETbYn56VZwiC7uKljge%5k>^#~Ntz`SZaMR|lo87r5&kccBvF

|x4stI={`G#r?zKA$QraVZ|fKHJqqC~2^(}X)6e+6mrmm2XzMur9nR$VC7dQ7#DpB2ayPTOS?#GU6{iJU#uuQwa2Zy5;&XxQBW9;?C^(?s1Foe_ z$^ZG0>ptl5)lda;5~H5(wZ9nFKIIT3r__-t!i6jyUpsgLB8dq_yD2hO1*Ej$+#W)uqO_%To D=uj!( diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockPane_AutoHide.bmp b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockPane_AutoHide.bmp deleted file mode 100644 index 2f395fc0103c27921866c86c1e18e06eb0437c15..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 774 zcmZ?rWn*Rl12Z700mK48%n!tj3=%++f#CuZm_i}`4+Q{pF-guu@gay7ogS!Nx V9KT|q>@ZLd3m6bh(7yw#0058Bb*TUV diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockPane_Option.bmp b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockPane_Option.bmp deleted file mode 100644 index 0d9927a7ce5d055bfc510269000a26a74b54bb24..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 774 zcmZ?rWn*Rl12Z700mK48%n!tj3=%++f#CuZm_i}`4@Us;A(1{q4i17^kQEcO1yeCW NEd(7fssMio006TLlZyZV diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockPane_OptionOverflow.bmp b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/DockPane_OptionOverflow.bmp deleted file mode 100644 index 02e4bf2905c71009e0a642e171211bf86da659ce..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 774 zcmZ?rWn*Rl12Z700mK48%n!tj3=%++f#CuZm_i}`4@Us;A(1{q4i17^kQEcO1yeCW UEd(8atbkPWNmY+**HB>t0L6i0y8r+H diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/Dockindicator_PaneDiamond_Fill.bmp b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Resources/Dockindicator_PaneDiamond_Fill.bmp deleted file mode 100644 index cbe0a156ab38a1bdd969735c4bb24cc1c9865744..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 23286 zcmeI4?Qa~#8NjdqMgIi;f_`ZQgo;Q(HU>%o0i}h=gp!apgy7(mkQ5RJ2p|+efF>m( z3Qhc}RYRhdSh^^&Wn<&J*f`FceDT?7qVSp^-~&kTn|XF0kN4%gx3{PIHd&2FbI? zQ>RXyKYxBUi;FaysBv?Wb~&6ocMck#q`j16t8WahMrCT(wRE{3JXx zVtg;`KVzRfWbO_h&KZZ<(GM>ecjQ9p!&%&@aY&3`GR}KI13YOT$Qg%=W5tVOM~y#D zpm@prw9fvVyX(v4flFgYbH?HF$$`t0{hmA7f7x}&x$8YZz}_`NBhML!&(92he%5zR z__H&^#>p*}6Y#@1E;ItPOycO1T+o#f4? z^Yb*1N`SM|*EaTd(nri$swR4y97* z^y$-)?V|6IrAHjsw|ps*Fp3;-7#bQH8yjO&E|NpI$dQs9aG)|wPEJ-TmA}>O2_uWI z!W?h_!qn7MwOXYtTCREnt<9lOPzdZRX2pS|ek>H~CHa4Qem(@@aOvIdi@Uon>{>Vb z_LJ2&SD)Xpa_Y55&%XS~>21H8eBu6yO}`y`_Kp+X?c$FJ16)>y=|EvgmNp(~ z=0zT`0!K=kq?qa%;1EzLQu8E2w`ZdW<#M^NuP^e&A@A?+ckf0@NWn!>18frY^cmGN zz@b6Iw3gHz>By_^{k{7(cGL5_ZtsS!|L)zhfB*j8SGK+J#0qZVAK1PP3BDugK>{4o z(bq?~5d(Ty&j5!84bxgol7+dbeYE!RplS+qyX*Ik3IQ zO^{?YqXq+-Y?y;sr7PcxB?Y?!`^HzQpRmh{3lt~(6Wug@bbkN24FciKm7PRa zpNPnL@AxzgqTt6#+ysR~INyLov_)-{#~MOGu$o~#q-at`SI^oUh=@_iaF{Azoi-eZ z8^|vF(@kG>mg0+U;v*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TpN?+K zKd9&67e=>jKPdOe`%KX1MmLrpl&k{x{q!f_Ch|OkIsHw~v)LD)IplfX{zKA``sB}7 zx+9gsJHA===bm7sXRv*@q`z+=^6sXEx#Vlc1~aIe|LYuyw2&PDH-zNF5&o*KYAbXjAkDM>J&J-%-zg){^hWf1?|Np)I zw>tTc?W7YQ_CGL!aR=G|zyd~zkH=(WjG#pB;|Htf%g;6EXKVWYI_ItZNZNwM_1Agn z%k@hq-_IYPoAZA4`m0Z8s9(?ihOH2Pe@?#Vn?=6Uzs^t)VEHDgW>7izd8-JSp;r8$ zv@flkLS`tEZ&{Q*f|Y9TU1Au*hVvF2-@ zp@rI+KU+-53`PD!vcA+xWQJP(&65B6Y$G!i#dpj3QtJ>eb2y?deCo?wkTv306#6Mycf9IL2 zfW!^oCH2c5IbuO>L}V_;Utq>UeC>tN_RIHdG5+$$^YUd|^h;5Vk9*!?`~|U+KE5MH zaBCOiFGwZspREaGOkIq>d|S^m`)mXeu^kuVFJHSl&J5NNeeQYuuf|`HXaw?xxG(MR zAo+=Pi^O3*-QDriT^SK+JU<}q)4drHX}mum?bBUH5NXI-wbY5aeY_I}@>uiUHU&)=!Q@6!GsNLFtj diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/SplitterBase.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/SplitterBase.cs deleted file mode 100644 index 0364d8d03d..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/SplitterBase.cs +++ /dev/null @@ -1,70 +0,0 @@ -using System; -using System.Collections; -using System.ComponentModel; -using System.Drawing; -using System.Windows.Forms; - -namespace WeifenLuo.WinFormsUI.Docking -{ - internal class SplitterBase : Control - { - public SplitterBase() - { - SetStyle(ControlStyles.Selectable, false); - } - - public override DockStyle Dock - { - get { return base.Dock; } - set - { - SuspendLayout(); - base.Dock = value; - - if (Dock == DockStyle.Left || Dock == DockStyle.Right) - Width = SplitterSize; - else if (Dock == DockStyle.Top || Dock == DockStyle.Bottom) - Height = SplitterSize; - else - Bounds = Rectangle.Empty; - - if (Dock == DockStyle.Left || Dock == DockStyle.Right) - Cursor = Cursors.VSplit; - else if (Dock == DockStyle.Top || Dock == DockStyle.Bottom) - Cursor = Cursors.HSplit; - else - Cursor = Cursors.Default; - - ResumeLayout(); - } - } - - protected virtual int SplitterSize - { - get { return 0; } - } - - protected override void OnMouseDown(MouseEventArgs e) - { - base.OnMouseDown(e); - - if (e.Button != MouseButtons.Left) - return; - - StartDrag(); - } - - protected virtual void StartDrag() - { - } - - protected override void WndProc(ref Message m) - { - // eat the WM_MOUSEACTIVATE message - if (m.Msg == (int)Win32.Msgs.WM_MOUSEACTIVATE) - return; - - base.WndProc(ref m); - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Strings.Designer.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Strings.Designer.cs deleted file mode 100644 index 8ca97d176d..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Strings.Designer.cs +++ /dev/null @@ -1,747 +0,0 @@ -//------------------------------------------------------------------------------ -// -// This code was generated by a tool. -// Runtime Version:2.0.50727.42 -// -// Changes to this file may cause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -namespace WeifenLuo.WinFormsUI.Docking { - using System; - - - ///

- /// A strongly-typed resource class, for looking up localized strings, etc. - /// - // This class was auto-generated by the StronglyTypedResourceBuilder - // class via a tool like ResGen or Visual Studio. - // To add or remove a member, edit your .ResX file then rerun ResGen - // with the /str option, or rebuild your VS project. - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "2.0.0.0")] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] - internal class Strings { - - private static global::System.Resources.ResourceManager resourceMan; - - private static global::System.Globalization.CultureInfo resourceCulture; - - [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] - internal Strings() { - } - - /// - /// Returns the cached ResourceManager instance used by this class. - /// - [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] - internal static global::System.Resources.ResourceManager ResourceManager { - get { - if (object.ReferenceEquals(resourceMan, null)) { - global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("WeifenLuo.WinFormsUI.Docking.Strings", typeof(Strings).Assembly); - resourceMan = temp; - } - return resourceMan; - } - } - - /// - /// Overrides the current thread's CurrentUICulture property for all - /// resource lookups using this strongly typed resource class. - /// - [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] - internal static global::System.Globalization.CultureInfo Culture { - get { - return resourceCulture; - } - set { - resourceCulture = value; - } - } - - /// - /// Looks up a localized string similar to Docking. - /// - internal static string Category_Docking { - get { - return ResourceManager.GetString("Category_Docking", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Docking Notification. - /// - internal static string Category_DockingNotification { - get { - return ResourceManager.GetString("Category_DockingNotification", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Property Changed. - /// - internal static string Category_PropertyChanged { - get { - return ResourceManager.GetString("Category_PropertyChanged", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to (Float). - /// - internal static string DockAreaEditor_FloatCheckBoxText { - get { - return ResourceManager.GetString("DockAreaEditor_FloatCheckBoxText", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Determines if end user drag and drop docking is allowed.. - /// - internal static string DockContent_AllowEndUserDocking_Description { - get { - return ResourceManager.GetString("DockContent_AllowEndUserDocking_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to The size to display the content in auto hide mode. Value < 1 to specify the size in portion; value >= 1 to specify the size in pixel.. - /// - internal static string DockContent_AutoHidePortion_Description { - get { - return ResourceManager.GetString("DockContent_AutoHidePortion_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Enable/Disable the close button of the content.. - /// - internal static string DockContent_CloseButton_Description { - get { - return ResourceManager.GetString("DockContent_CloseButton_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to The form must be of type IDockContent.. - /// - internal static string DockContent_Constructor_InvalidForm { - get { - return ResourceManager.GetString("DockContent_Constructor_InvalidForm", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Gets or sets a value indicating in which area of the DockPanel the content allowed to show.. - /// - internal static string DockContent_DockAreas_Description { - get { - return ResourceManager.GetString("DockContent_DockAreas_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Occurs when the value of DockState property changed.. - /// - internal static string DockContent_DockStateChanged_Description { - get { - return ResourceManager.GetString("DockContent_DockStateChanged_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Indicates the content will be hidden instead of being closed.. - /// - internal static string DockContent_HideOnClose_Description { - get { - return ResourceManager.GetString("DockContent_HideOnClose_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to The desired docking state when first showing.. - /// - internal static string DockContent_ShowHint_Description { - get { - return ResourceManager.GetString("DockContent_ShowHint_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Context menu displayed for the dock pane tab strip.. - /// - internal static string DockContent_TabPageContextMenu_Description { - get { - return ResourceManager.GetString("DockContent_TabPageContextMenu_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to The tab text displayed in the dock pane. If not set, the Text property will be used.. - /// - internal static string DockContent_TabText_Description { - get { - return ResourceManager.GetString("DockContent_TabText_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to The text displayed when mouse hovers over the tab.. - /// - internal static string DockContent_ToolTipText_Description { - get { - return ResourceManager.GetString("DockContent_ToolTipText_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to The provided value is out of range.. - /// - internal static string DockContentHandler_AutoHidePortion_OutOfRange { - get { - return ResourceManager.GetString("DockContentHandler_AutoHidePortion_OutOfRange", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Invalid Value: The value of DockAreas conflicts with current DockState.. - /// - internal static string DockContentHandler_DockAreas_InvalidValue { - get { - return ResourceManager.GetString("DockContentHandler_DockAreas_InvalidValue", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to The pane is invalid. Check the IsFloat and DockPanel properties of this dock pane.. - /// - internal static string DockContentHandler_DockPane_InvalidValue { - get { - return ResourceManager.GetString("DockContentHandler_DockPane_InvalidValue", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to The pane is invalid. Check the IsFloat and DockPanel properties of this dock pane.. - /// - internal static string DockContentHandler_FloatPane_InvalidValue { - get { - return ResourceManager.GetString("DockContentHandler_FloatPane_InvalidValue", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Invalid value, conflicts with DockableAreas property.. - /// - internal static string DockContentHandler_IsFloat_InvalidValue { - get { - return ResourceManager.GetString("DockContentHandler_IsFloat_InvalidValue", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to The dock state is invalid.. - /// - internal static string DockContentHandler_SetDockState_InvalidState { - get { - return ResourceManager.GetString("DockContentHandler_SetDockState_InvalidState", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to The dock panel is null.. - /// - internal static string DockContentHandler_SetDockState_NullPanel { - get { - return ResourceManager.GetString("DockContentHandler_SetDockState_NullPanel", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Invalid beforeContent, it must be contained by the pane.. - /// - internal static string DockContentHandler_Show_InvalidBeforeContent { - get { - return ResourceManager.GetString("DockContentHandler_Show_InvalidBeforeContent", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Invalid DockState: Content can not be showed as "Unknown" or "Hidden".. - /// - internal static string DockContentHandler_Show_InvalidDockState { - get { - return ResourceManager.GetString("DockContentHandler_Show_InvalidDockState", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to The previous pane is invalid. It can not be null, and its docking state must not be auto-hide.. - /// - internal static string DockContentHandler_Show_InvalidPrevPane { - get { - return ResourceManager.GetString("DockContentHandler_Show_InvalidPrevPane", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to DockPanel can not be null.. - /// - internal static string DockContentHandler_Show_NullDockPanel { - get { - return ResourceManager.GetString("DockContentHandler_Show_NullDockPanel", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to The Pane can not be null.. - /// - internal static string DockContentHandler_Show_NullPane { - get { - return ResourceManager.GetString("DockContentHandler_Show_NullPane", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Invalid value, check DockableAreas property.. - /// - internal static string DockContentHandler_ShowHint_InvalidValue { - get { - return ResourceManager.GetString("DockContentHandler_ShowHint_InvalidValue", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Context menu displayed for the dock pane tab strip.. - /// - internal static string DockHandler_TabPageContextMenuStrip_Description { - get { - return ResourceManager.GetString("DockHandler_TabPageContextMenuStrip_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Press SHIFT for docking to full side.. - /// - internal static string DockIndicator_ToolTipText { - get { - return ResourceManager.GetString("DockIndicator_ToolTipText", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Invalid Content: ActiveContent must be one of the visible contents, or null if there is no visible content.. - /// - internal static string DockPane_ActiveContent_InvalidValue { - get { - return ResourceManager.GetString("DockPane_ActiveContent_InvalidValue", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Invalid argument: Content can not be "null".. - /// - internal static string DockPane_Constructor_NullContent { - get { - return ResourceManager.GetString("DockPane_Constructor_NullContent", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Invalid argument: The content's DockPanel can not be "null".. - /// - internal static string DockPane_Constructor_NullDockPanel { - get { - return ResourceManager.GetString("DockPane_Constructor_NullDockPanel", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to The specified container conflicts with the IsFloat property.. - /// - internal static string DockPane_DockTo_InvalidContainer { - get { - return ResourceManager.GetString("DockPane_DockTo_InvalidContainer", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to The previous pane does not exist in the nested docking pane collection.. - /// - internal static string DockPane_DockTo_NoPrevPane { - get { - return ResourceManager.GetString("DockPane_DockTo_NoPrevPane", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to The container can not be null.. - /// - internal static string DockPane_DockTo_NullContainer { - get { - return ResourceManager.GetString("DockPane_DockTo_NullContainer", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to The previous pane can not be null when the nested docking pane collection is not empty.. - /// - internal static string DockPane_DockTo_NullPrevPane { - get { - return ResourceManager.GetString("DockPane_DockTo_NullPrevPane", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to The previous pane can not be itself.. - /// - internal static string DockPane_DockTo_SelfPrevPane { - get { - return ResourceManager.GetString("DockPane_DockTo_SelfPrevPane", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to FloatWindow property can not be set to "null" when DockState is DockState.Float.. - /// - internal static string DockPane_FloatWindow_InvalidValue { - get { - return ResourceManager.GetString("DockPane_FloatWindow_InvalidValue", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Invalid Content: Content not within the collection.. - /// - internal static string DockPane_SetContentIndex_InvalidContent { - get { - return ResourceManager.GetString("DockPane_SetContentIndex_InvalidContent", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Invalid Index: The index is out of range.. - /// - internal static string DockPane_SetContentIndex_InvalidIndex { - get { - return ResourceManager.GetString("DockPane_SetContentIndex_InvalidIndex", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to The state for the dock pane is invalid.. - /// - internal static string DockPane_SetDockState_InvalidState { - get { - return ResourceManager.GetString("DockPane_SetDockState_InvalidState", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Auto Hide. - /// - internal static string DockPaneCaption_ToolTipAutoHide { - get { - return ResourceManager.GetString("DockPaneCaption_ToolTipAutoHide", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Close. - /// - internal static string DockPaneCaption_ToolTipClose { - get { - return ResourceManager.GetString("DockPaneCaption_ToolTipClose", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Options. - /// - internal static string DockPaneCaption_ToolTipOptions { - get { - return ResourceManager.GetString("DockPaneCaption_ToolTipOptions", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Invalid Content: The content must be auto-hide state and associates with this DockPanel.. - /// - internal static string DockPanel_ActiveAutoHideContent_InvalidValue { - get { - return ResourceManager.GetString("DockPanel_ActiveAutoHideContent_InvalidValue", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Occurs when the value of ActiveContentProperty changed.. - /// - internal static string DockPanel_ActiveContentChanged_Description { - get { - return ResourceManager.GetString("DockPanel_ActiveContentChanged_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Occurs when the value of ActiveDocument property changed.. - /// - internal static string DockPanel_ActiveDocumentChanged_Description { - get { - return ResourceManager.GetString("DockPanel_ActiveDocumentChanged_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Occurs when the value of ActivePane property changed.. - /// - internal static string DockPanel_ActivePaneChanged_Description { - get { - return ResourceManager.GetString("DockPanel_ActivePaneChanged_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Determines if the drag and drop docking is allowed.. - /// - internal static string DockPanel_AllowEndUserDocking_Description { - get { - return ResourceManager.GetString("DockPanel_AllowEndUserDocking_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Determines if the drag and drop nested docking is allowed.. - /// - internal static string DockPanel_AllowEndUserNestedDocking_Description { - get { - return ResourceManager.GetString("DockPanel_AllowEndUserNestedDocking_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Occurs when a content added to the DockPanel.. - /// - internal static string DockPanel_ContentAdded_Description { - get { - return ResourceManager.GetString("DockPanel_ContentAdded_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Occurs when a content removed from the DockPanel.. - /// - internal static string DockPanel_ContentRemoved_Description { - get { - return ResourceManager.GetString("DockPanel_ContentRemoved_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to The default size of float window.. - /// - internal static string DockPanel_DefaultFloatWindowSize_Description { - get { - return ResourceManager.GetString("DockPanel_DefaultFloatWindowSize_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Provides Visual Studio .Net style docking.. - /// - internal static string DockPanel_Description { - get { - return ResourceManager.GetString("DockPanel_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Size of the bottom docking window. Value < 1 to specify the size in portion; value > 1 to specify the size in pixels.. - /// - internal static string DockPanel_DockBottomPortion_Description { - get { - return ResourceManager.GetString("DockPanel_DockBottomPortion_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Size of the left docking window. Value < 1 to specify the size in portion; value > 1 to specify the size in pixels.. - /// - internal static string DockPanel_DockLeftPortion_Description { - get { - return ResourceManager.GetString("DockPanel_DockLeftPortion_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Size of the right docking window. Value < 1 to specify the size in portion; value > 1 to specify the size in pixels.. - /// - internal static string DockPanel_DockRightPortion_Description { - get { - return ResourceManager.GetString("DockPanel_DockRightPortion_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Size of the top docking window. Value < 1 to specify the size in portion; value > 1 to specify the size in pixels.. - /// - internal static string DockPanel_DockTopPortion_Description { - get { - return ResourceManager.GetString("DockPanel_DockTopPortion_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to The style of the document window.. - /// - internal static string DockPanel_DocumentStyle_Description { - get { - return ResourceManager.GetString("DockPanel_DocumentStyle_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to The DockPanel has already been initialized.. - /// - internal static string DockPanel_LoadFromXml_AlreadyInitialized { - get { - return ResourceManager.GetString("DockPanel_LoadFromXml_AlreadyInitialized", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to The configuration file's version is invalid.. - /// - internal static string DockPanel_LoadFromXml_InvalidFormatVersion { - get { - return ResourceManager.GetString("DockPanel_LoadFromXml_InvalidFormatVersion", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to The XML file format is invalid.. - /// - internal static string DockPanel_LoadFromXml_InvalidXmlFormat { - get { - return ResourceManager.GetString("DockPanel_LoadFromXml_InvalidXmlFormat", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Invalid parent form. When using DockingMdi or SystemMdi document style, the DockPanel control must be the child control of the main MDI container form.. - /// - internal static string DockPanel_ParentForm_Invalid { - get { - return ResourceManager.GetString("DockPanel_ParentForm_Invalid", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to DockPanel configuration file. Author: Weifen Luo, all rights reserved.. - /// - internal static string DockPanel_Persistor_XmlFileComment1 { - get { - return ResourceManager.GetString("DockPanel_Persistor_XmlFileComment1", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to !!! AUTOMATICALLY GENERATED FILE. DO NOT MODIFY !!!. - /// - internal static string DockPanel_Persistor_XmlFileComment2 { - get { - return ResourceManager.GetString("DockPanel_Persistor_XmlFileComment2", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Indicates whether the control layout is right-to-left when the RightToLeft property is set to Yes.. - /// - internal static string DockPanel_RightToLeftLayout_Description { - get { - return ResourceManager.GetString("DockPanel_RightToLeftLayout_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Invalid Index: The index is out of range.. - /// - internal static string DockPanel_SetPaneIndex_InvalidIndex { - get { - return ResourceManager.GetString("DockPanel_SetPaneIndex_InvalidIndex", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Invalid Pane: DockPane not within the collection.. - /// - internal static string DockPanel_SetPaneIndex_InvalidPane { - get { - return ResourceManager.GetString("DockPanel_SetPaneIndex_InvalidPane", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Determines if the document icon will be displayed in the tab strip.. - /// - internal static string DockPanel_ShowDocumentIcon_Description { - get { - return ResourceManager.GetString("DockPanel_ShowDocumentIcon_Description", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Close. - /// - internal static string DockPaneStrip_ToolTipClose { - get { - return ResourceManager.GetString("DockPaneStrip_ToolTipClose", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Window List. - /// - internal static string DockPaneStrip_ToolTipWindowList { - get { - return ResourceManager.GetString("DockPaneStrip_ToolTipWindowList", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Invalid argument: DockPanel can not be "null".. - /// - internal static string FloatWindow_Constructor_NullDockPanel { - get { - return ResourceManager.GetString("FloatWindow_Constructor_NullDockPanel", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Invalid Index: The index is out of range.. - /// - internal static string FloatWindow_SetPaneIndex_InvalidIndex { - get { - return ResourceManager.GetString("FloatWindow_SetPaneIndex_InvalidIndex", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Invalid Pane: DockPane not within the collection.. - /// - internal static string FloatWindow_SetPaneIndex_InvalidPane { - get { - return ResourceManager.GetString("FloatWindow_SetPaneIndex_InvalidPane", resourceCulture); - } - } - - /// - /// Looks up a localized string similar to Invalid DockPanel.. - /// - internal static string IDockDragSource_DockTo_InvalidPanel { - get { - return ResourceManager.GetString("IDockDragSource_DockTo_InvalidPanel", resourceCulture); - } - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Strings.resx b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Strings.resx deleted file mode 100644 index 96621ff8a0..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/Strings.resx +++ /dev/null @@ -1,348 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - Docking - - - Docking Notification - - - Property Changed - - - (Float) - - - Determines if end user drag and drop docking is allowed. - - - The size to display the content in auto hide mode. Value < 1 to specify the size in portion; value >= 1 to specify the size in pixel. - - - Enable/Disable the close button of the content. - - - The form must be of type IDockContent. - - - Gets or sets a value indicating in which area of the DockPanel the content allowed to show. - - - Occurs when the value of DockState property changed. - - - Indicates the content will be hidden instead of being closed. - - - The desired docking state when first showing. - - - Context menu displayed for the dock pane tab strip. - - - The tab text displayed in the dock pane. If not set, the Text property will be used. - - - The text displayed when mouse hovers over the tab. - - - The provided value is out of range. - - - Invalid Value: The value of DockAreas conflicts with current DockState. - - - The pane is invalid. Check the IsFloat and DockPanel properties of this dock pane. - - - The pane is invalid. Check the IsFloat and DockPanel properties of this dock pane. - - - Invalid value, conflicts with DockableAreas property. - - - The dock state is invalid. - - - The dock panel is null. - - - Invalid beforeContent, it must be contained by the pane. - - - Invalid DockState: Content can not be showed as "Unknown" or "Hidden". - - - The previous pane is invalid. It can not be null, and its docking state must not be auto-hide. - - - DockPanel can not be null. - - - The Pane can not be null. - - - Invalid value, check DockableAreas property. - - - Context menu displayed for the dock pane tab strip. - - - Press SHIFT for docking to full side. - - - Invalid Content: ActiveContent must be one of the visible contents, or null if there is no visible content. - - - Invalid argument: Content can not be "null". - - - Invalid argument: The content's DockPanel can not be "null". - - - The specified container conflicts with the IsFloat property. - - - The previous pane does not exist in the nested docking pane collection. - - - The container can not be null. - - - The previous pane can not be null when the nested docking pane collection is not empty. - - - The previous pane can not be itself. - - - FloatWindow property can not be set to "null" when DockState is DockState.Float. - - - Invalid Content: Content not within the collection. - - - Invalid Index: The index is out of range. - - - The state for the dock pane is invalid. - - - Auto Hide - - - Close - - - Options - - - Invalid Content: The content must be auto-hide state and associates with this DockPanel. - - - Occurs when the value of ActiveContentProperty changed. - - - Occurs when the value of ActiveDocument property changed. - - - Occurs when the value of ActivePane property changed. - - - Determines if the drag and drop docking is allowed. - - - Determines if the drag and drop nested docking is allowed. - - - Occurs when a content added to the DockPanel. - - - Occurs when a content removed from the DockPanel. - - - The default size of float window. - - - Provides Visual Studio .Net style docking. - - - Size of the bottom docking window. Value < 1 to specify the size in portion; value > 1 to specify the size in pixels. - - - Size of the left docking window. Value < 1 to specify the size in portion; value > 1 to specify the size in pixels. - - - Size of the right docking window. Value < 1 to specify the size in portion; value > 1 to specify the size in pixels. - - - Size of the top docking window. Value < 1 to specify the size in portion; value > 1 to specify the size in pixels. - - - The style of the document window. - - - The DockPanel has already been initialized. - - - The configuration file's version is invalid. - - - The XML file format is invalid. - - - Invalid parent form. When using DockingMdi or SystemMdi document style, the DockPanel control must be the child control of the main MDI container form. - - - DockPanel configuration file. Author: Weifen Luo, all rights reserved. - - - !!! AUTOMATICALLY GENERATED FILE. DO NOT MODIFY !!! - - - Indicates whether the control layout is right-to-left when the RightToLeft property is set to Yes. - - - Invalid Index: The index is out of range. - - - Invalid Pane: DockPane not within the collection. - - - Determines if the document icon will be displayed in the tab strip. - - - Close - - - Window List - - - Invalid argument: DockPanel can not be "null". - - - Invalid Index: The index is out of range. - - - Invalid Pane: DockPane not within the collection. - - - Invalid DockPanel. - - \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/VS2005AutoHideStrip.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/VS2005AutoHideStrip.cs deleted file mode 100644 index 90c0209257..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/VS2005AutoHideStrip.cs +++ /dev/null @@ -1,497 +0,0 @@ -using System; -using System.Drawing; -using System.Windows.Forms; -using System.Drawing.Drawing2D; -using System.ComponentModel; - -namespace WeifenLuo.WinFormsUI.Docking -{ - internal class VS2005AutoHideStrip : AutoHideStripBase - { - private class TabVS2005 : Tab - { - internal TabVS2005(IDockContent content) - : base(content) - { - } - - private int m_tabX = 0; - public int TabX - { - get { return m_tabX; } - set { m_tabX = value; } - } - - private int m_tabWidth = 0; - public int TabWidth - { - get { return m_tabWidth; } - set { m_tabWidth = value; } - } - - } - - private const int _ImageHeight = 16; - private const int _ImageWidth = 16; - private const int _ImageGapTop = 2; - private const int _ImageGapLeft = 4; - private const int _ImageGapRight = 2; - private const int _ImageGapBottom = 2; - private const int _TextGapLeft = 0; - private const int _TextGapRight = 0; - private const int _TabGapTop = 3; - private const int _TabGapLeft = 4; - private const int _TabGapBetween = 10; - - #region Customizable Properties - private static Font TextFont - { - get { return SystemInformation.MenuFont; } - } - - private static StringFormat _stringFormatTabHorizontal; - private StringFormat StringFormatTabHorizontal - { - get - { - if (_stringFormatTabHorizontal == null) - { - _stringFormatTabHorizontal = new StringFormat(); - _stringFormatTabHorizontal.Alignment = StringAlignment.Near; - _stringFormatTabHorizontal.LineAlignment = StringAlignment.Center; - _stringFormatTabHorizontal.FormatFlags = StringFormatFlags.NoWrap; - } - - if (RightToLeft == RightToLeft.Yes) - _stringFormatTabHorizontal.FormatFlags |= StringFormatFlags.DirectionRightToLeft; - else - _stringFormatTabHorizontal.FormatFlags &= ~StringFormatFlags.DirectionRightToLeft; - - return _stringFormatTabHorizontal; - } - } - - private static StringFormat _stringFormatTabVertical; - private StringFormat StringFormatTabVertical - { - get - { - if (_stringFormatTabVertical == null) - { - _stringFormatTabVertical = new StringFormat(); - _stringFormatTabVertical.Alignment = StringAlignment.Near; - _stringFormatTabVertical.LineAlignment = StringAlignment.Center; - _stringFormatTabVertical.FormatFlags = StringFormatFlags.NoWrap | StringFormatFlags.DirectionVertical; - } - if (RightToLeft == RightToLeft.Yes) - _stringFormatTabVertical.FormatFlags |= StringFormatFlags.DirectionRightToLeft; - else - _stringFormatTabVertical.FormatFlags &= ~StringFormatFlags.DirectionRightToLeft; - - return _stringFormatTabVertical; - } - } - - private static int ImageHeight - { - get { return _ImageHeight; } - } - - private static int ImageWidth - { - get { return _ImageWidth; } - } - - private static int ImageGapTop - { - get { return _ImageGapTop; } - } - - private static int ImageGapLeft - { - get { return _ImageGapLeft; } - } - - private static int ImageGapRight - { - get { return _ImageGapRight; } - } - - private static int ImageGapBottom - { - get { return _ImageGapBottom; } - } - - private static int TextGapLeft - { - get { return _TextGapLeft; } - } - - private static int TextGapRight - { - get { return _TextGapRight; } - } - - private static int TabGapTop - { - get { return _TabGapTop; } - } - - private static int TabGapLeft - { - get { return _TabGapLeft; } - } - - private static int TabGapBetween - { - get { return _TabGapBetween; } - } - - private static Brush BrushTabBackground - { - get { return SystemBrushes.Control; } - } - - private static Pen PenTabBorder - { - get { return SystemPens.GrayText; } - } - - private static Brush BrushTabText - { - get { return SystemBrushes.FromSystemColor(SystemColors.ControlDarkDark); } - } - #endregion - - private static Matrix _matrixIdentity = new Matrix(); - private static Matrix MatrixIdentity - { - get { return _matrixIdentity; } - } - - private static DockState[] _dockStates; - private static DockState[] DockStates - { - get - { - if (_dockStates == null) - { - _dockStates = new DockState[4]; - _dockStates[0] = DockState.DockLeftAutoHide; - _dockStates[1] = DockState.DockRightAutoHide; - _dockStates[2] = DockState.DockTopAutoHide; - _dockStates[3] = DockState.DockBottomAutoHide; - } - return _dockStates; - } - } - - private static GraphicsPath _graphicsPath; - internal static GraphicsPath GraphicsPath - { - get - { - if (_graphicsPath == null) - _graphicsPath = new GraphicsPath(); - - return _graphicsPath; - } - } - - public VS2005AutoHideStrip(DockPanel panel) : base(panel) - { - SetStyle(ControlStyles.ResizeRedraw | - ControlStyles.UserPaint | - ControlStyles.AllPaintingInWmPaint | - ControlStyles.OptimizedDoubleBuffer, true); - BackColor = SystemColors.ControlLight; - } - - protected override void OnPaint(PaintEventArgs e) - { - Graphics g = e.Graphics; - DrawTabStrip(g); - } - - protected override void OnLayout(LayoutEventArgs levent) - { - CalculateTabs(); - base.OnLayout (levent); - } - - private void DrawTabStrip(Graphics g) - { - DrawTabStrip(g, DockState.DockTopAutoHide); - DrawTabStrip(g, DockState.DockBottomAutoHide); - DrawTabStrip(g, DockState.DockLeftAutoHide); - DrawTabStrip(g, DockState.DockRightAutoHide); - } - - private void DrawTabStrip(Graphics g, DockState dockState) - { - Rectangle rectTabStrip = GetLogicalTabStripRectangle(dockState); - - if (rectTabStrip.IsEmpty) - return; - - Matrix matrixIdentity = g.Transform; - if (dockState == DockState.DockLeftAutoHide || dockState == DockState.DockRightAutoHide) - { - Matrix matrixRotated = new Matrix(); - matrixRotated.RotateAt(90, new PointF((float)rectTabStrip.X + (float)rectTabStrip.Height / 2, - (float)rectTabStrip.Y + (float)rectTabStrip.Height / 2)); - g.Transform = matrixRotated; - } - - foreach (Pane pane in GetPanes(dockState)) - { - foreach (TabVS2005 tab in pane.AutoHideTabs) - DrawTab(g, tab); - } - g.Transform = matrixIdentity; - } - - private void CalculateTabs() - { - CalculateTabs(DockState.DockTopAutoHide); - CalculateTabs(DockState.DockBottomAutoHide); - CalculateTabs(DockState.DockLeftAutoHide); - CalculateTabs(DockState.DockRightAutoHide); - } - - private void CalculateTabs(DockState dockState) - { - Rectangle rectTabStrip = GetLogicalTabStripRectangle(dockState); - - int imageHeight = rectTabStrip.Height - ImageGapTop - ImageGapBottom; - int imageWidth = ImageWidth; - if (imageHeight > ImageHeight) - imageWidth = ImageWidth * (imageHeight / ImageHeight); - - int x = TabGapLeft + rectTabStrip.X; - foreach (Pane pane in GetPanes(dockState)) - { - foreach (TabVS2005 tab in pane.AutoHideTabs) - { - int width = imageWidth + ImageGapLeft + ImageGapRight + - TextRenderer.MeasureText(tab.Content.DockHandler.TabText, TextFont).Width + - TextGapLeft + TextGapRight; - tab.TabX = x; - tab.TabWidth = width; - x += width; - } - - x += TabGapBetween; - } - } - - private Rectangle RtlTransform(Rectangle rect, DockState dockState) - { - Rectangle rectTransformed; - if (dockState == DockState.DockLeftAutoHide || dockState == DockState.DockRightAutoHide) - rectTransformed = rect; - else - rectTransformed = DrawHelper.RtlTransform(this, rect); - - return rectTransformed; - } - - private GraphicsPath GetTabOutline(TabVS2005 tab, bool transformed, bool rtlTransform) - { - DockState dockState = tab.Content.DockHandler.DockState; - Rectangle rectTab = GetTabRectangle(tab, transformed); - if (rtlTransform) - rectTab = RtlTransform(rectTab, dockState); - bool upTab = (dockState == DockState.DockLeftAutoHide || dockState == DockState.DockBottomAutoHide); - DrawHelper.GetRoundedCornerTab(GraphicsPath, rectTab, upTab); - - return GraphicsPath; - } - - private void DrawTab(Graphics g, TabVS2005 tab) - { - Rectangle rectTabOrigin = GetTabRectangle(tab); - if (rectTabOrigin.IsEmpty) - return; - - DockState dockState = tab.Content.DockHandler.DockState; - IDockContent content = tab.Content; - - GraphicsPath path = GetTabOutline(tab, false, true); - g.FillPath(BrushTabBackground, path); - g.DrawPath(PenTabBorder, path); - - // Set no rotate for drawing icon and text - Matrix matrixRotate = g.Transform; - g.Transform = MatrixIdentity; - - // Draw the icon - Rectangle rectImage = rectTabOrigin; - rectImage.X += ImageGapLeft; - rectImage.Y += ImageGapTop; - int imageHeight = rectTabOrigin.Height - ImageGapTop - ImageGapBottom; - int imageWidth = ImageWidth; - if (imageHeight > ImageHeight) - imageWidth = ImageWidth * (imageHeight/ImageHeight); - rectImage.Height = imageHeight; - rectImage.Width = imageWidth; - rectImage = GetTransformedRectangle(dockState, rectImage); - g.DrawIcon(((Form)content).Icon, RtlTransform(rectImage, dockState)); - - // Draw the text - Rectangle rectText = rectTabOrigin; - rectText.X += ImageGapLeft + imageWidth + ImageGapRight + TextGapLeft; - rectText.Width -= ImageGapLeft + imageWidth + ImageGapRight + TextGapLeft; - rectText = RtlTransform(GetTransformedRectangle(dockState, rectText), dockState); - if (dockState == DockState.DockLeftAutoHide || dockState == DockState.DockRightAutoHide) - g.DrawString(content.DockHandler.TabText, TextFont, BrushTabText, rectText, StringFormatTabVertical); - else - g.DrawString(content.DockHandler.TabText, TextFont, BrushTabText, rectText, StringFormatTabHorizontal); - - // Set rotate back - g.Transform = matrixRotate; - } - - private Rectangle GetLogicalTabStripRectangle(DockState dockState) - { - return GetLogicalTabStripRectangle(dockState, false); - } - - private Rectangle GetLogicalTabStripRectangle(DockState dockState, bool transformed) - { - if (!DockHelper.IsDockStateAutoHide(dockState)) - return Rectangle.Empty; - - int leftPanes = GetPanes(DockState.DockLeftAutoHide).Count; - int rightPanes = GetPanes(DockState.DockRightAutoHide).Count; - int topPanes = GetPanes(DockState.DockTopAutoHide).Count; - int bottomPanes = GetPanes(DockState.DockBottomAutoHide).Count; - - int x, y, width, height; - - height = MeasureHeight(); - if (dockState == DockState.DockLeftAutoHide && leftPanes > 0) - { - x = 0; - y = (topPanes == 0) ? 0 : height; - width = Height - (topPanes == 0 ? 0 : height) - (bottomPanes == 0 ? 0 :height); - } - else if (dockState == DockState.DockRightAutoHide && rightPanes > 0) - { - x = Width - height; - if (leftPanes != 0 && x < height) - x = height; - y = (topPanes == 0) ? 0 : height; - width = Height - (topPanes == 0 ? 0 : height) - (bottomPanes == 0 ? 0 :height); - } - else if (dockState == DockState.DockTopAutoHide && topPanes > 0) - { - x = leftPanes == 0 ? 0 : height; - y = 0; - width = Width - (leftPanes == 0 ? 0 : height) - (rightPanes == 0 ? 0 : height); - } - else if (dockState == DockState.DockBottomAutoHide && bottomPanes > 0) - { - x = leftPanes == 0 ? 0 : height; - y = Height - height; - if (topPanes != 0 && y < height) - y = height; - width = Width - (leftPanes == 0 ? 0 : height) - (rightPanes == 0 ? 0 : height); - } - else - return Rectangle.Empty; - - if (!transformed) - return new Rectangle(x, y, width, height); - else - return GetTransformedRectangle(dockState, new Rectangle(x, y, width, height)); - } - - private Rectangle GetTabRectangle(TabVS2005 tab) - { - return GetTabRectangle(tab, false); - } - - private Rectangle GetTabRectangle(TabVS2005 tab, bool transformed) - { - DockState dockState = tab.Content.DockHandler.DockState; - Rectangle rectTabStrip = GetLogicalTabStripRectangle(dockState); - - if (rectTabStrip.IsEmpty) - return Rectangle.Empty; - - int x = tab.TabX; - int y = rectTabStrip.Y + - (dockState == DockState.DockTopAutoHide || dockState == DockState.DockRightAutoHide ? - 0 : TabGapTop); - int width = tab.TabWidth; - int height = rectTabStrip.Height - TabGapTop; - - if (!transformed) - return new Rectangle(x, y, width, height); - else - return GetTransformedRectangle(dockState, new Rectangle(x, y, width, height)); - } - - private Rectangle GetTransformedRectangle(DockState dockState, Rectangle rect) - { - if (dockState != DockState.DockLeftAutoHide && dockState != DockState.DockRightAutoHide) - return rect; - - PointF[] pts = new PointF[1]; - // the center of the rectangle - pts[0].X = (float)rect.X + (float)rect.Width / 2; - pts[0].Y = (float)rect.Y + (float)rect.Height / 2; - Rectangle rectTabStrip = GetLogicalTabStripRectangle(dockState); - Matrix matrix = new Matrix(); - matrix.RotateAt(90, new PointF((float)rectTabStrip.X + (float)rectTabStrip.Height / 2, - (float)rectTabStrip.Y + (float)rectTabStrip.Height / 2)); - matrix.TransformPoints(pts); - - return new Rectangle((int)(pts[0].X - (float)rect.Height / 2 + .5F), - (int)(pts[0].Y - (float)rect.Width / 2 + .5F), - rect.Height, rect.Width); - } - - protected override IDockContent HitTest(Point ptMouse) - { - foreach(DockState state in DockStates) - { - Rectangle rectTabStrip = GetLogicalTabStripRectangle(state, true); - if (!rectTabStrip.Contains(ptMouse)) - continue; - - foreach(Pane pane in GetPanes(state)) - { - DockState dockState = pane.DockPane.DockState; - foreach(TabVS2005 tab in pane.AutoHideTabs) - { - GraphicsPath path = GetTabOutline(tab, true, true); - if (path.IsVisible(ptMouse)) - return tab.Content; - } - } - } - - return null; - } - - protected internal override int MeasureHeight() - { - return Math.Max(ImageGapBottom + - ImageGapTop + ImageHeight, - TextFont.Height) + TabGapTop; - } - - protected override void OnRefreshChanges() - { - CalculateTabs(); - Invalidate(); - } - - protected override AutoHideStripBase.Tab CreateTab(IDockContent content) - { - return new TabVS2005(content); - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/VS2005DockPaneCaption.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/VS2005DockPaneCaption.cs deleted file mode 100644 index 20a0eec787..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/VS2005DockPaneCaption.cs +++ /dev/null @@ -1,468 +0,0 @@ -using System; -using System.Drawing; -using System.Drawing.Drawing2D; -using System.Windows.Forms; -using System.ComponentModel; -using System.Windows.Forms.VisualStyles; - -namespace WeifenLuo.WinFormsUI.Docking -{ - internal class VS2005DockPaneCaption : DockPaneCaptionBase - { - private sealed class InertButton : InertButtonBase - { - private Bitmap m_image, m_imageAutoHide; - - public InertButton(VS2005DockPaneCaption dockPaneCaption, Bitmap image, Bitmap imageAutoHide) - : base() - { - m_dockPaneCaption = dockPaneCaption; - m_image = image; - m_imageAutoHide = imageAutoHide; - RefreshChanges(); - } - - private VS2005DockPaneCaption m_dockPaneCaption; - private VS2005DockPaneCaption DockPaneCaption - { - get { return m_dockPaneCaption; } - } - - public bool IsAutoHide - { - get { return DockPaneCaption.DockPane.IsAutoHide; } - } - - public override Bitmap Image - { - get { return IsAutoHide ? m_imageAutoHide : m_image; } - } - - protected override void OnRefreshChanges() - { - if (DockPaneCaption.TextColor != ForeColor) - { - ForeColor = DockPaneCaption.TextColor; - Invalidate(); - } - } - } - - #region consts - private const int _TextGapTop = 2; - private const int _TextGapBottom = 0; - private const int _TextGapLeft = 3; - private const int _TextGapRight = 3; - private const int _ButtonGapTop = 2; - private const int _ButtonGapBottom = 1; - private const int _ButtonGapBetween = 1; - private const int _ButtonGapLeft = 1; - private const int _ButtonGapRight = 2; - #endregion - - private static Bitmap _imageButtonClose; - private static Bitmap ImageButtonClose - { - get - { - if (_imageButtonClose == null) - _imageButtonClose = Resources.DockPane_Close; - - return _imageButtonClose; - } - } - - private InertButton m_buttonClose; - private InertButton ButtonClose - { - get - { - if (m_buttonClose == null) - { - m_buttonClose = new InertButton(this, ImageButtonClose, ImageButtonClose); - m_toolTip.SetToolTip(m_buttonClose, ToolTipClose); - m_buttonClose.Click += new EventHandler(Close_Click); - Controls.Add(m_buttonClose); - } - - return m_buttonClose; - } - } - - private static Bitmap _imageButtonAutoHide; - private static Bitmap ImageButtonAutoHide - { - get - { - if (_imageButtonAutoHide == null) - _imageButtonAutoHide = Resources.DockPane_AutoHide; - - return _imageButtonAutoHide; - } - } - - private static Bitmap _imageButtonDock; - private static Bitmap ImageButtonDock - { - get - { - if (_imageButtonDock == null) - _imageButtonDock = Resources.DockPane_Dock; - - return _imageButtonDock; - } - } - - private InertButton m_buttonAutoHide; - private InertButton ButtonAutoHide - { - get - { - if (m_buttonAutoHide == null) - { - m_buttonAutoHide = new InertButton(this, ImageButtonDock, ImageButtonAutoHide); - m_toolTip.SetToolTip(m_buttonAutoHide, ToolTipAutoHide); - m_buttonAutoHide.Click += new EventHandler(AutoHide_Click); - Controls.Add(m_buttonAutoHide); - } - - return m_buttonAutoHide; - } - } - - private static Bitmap _imageButtonOptions; - private static Bitmap ImageButtonOptions - { - get - { - if (_imageButtonOptions == null) - _imageButtonOptions = Resources.DockPane_Option; - - return _imageButtonOptions; - } - } - - private InertButton m_buttonOptions; - private InertButton ButtonOptions - { - get - { - if (m_buttonOptions == null) - { - m_buttonOptions = new InertButton(this, ImageButtonOptions, ImageButtonOptions); - m_toolTip.SetToolTip(m_buttonOptions, ToolTipOptions); - m_buttonOptions.Click += new EventHandler(Options_Click); - Controls.Add(m_buttonOptions); - } - return m_buttonOptions; - } - } - - private IContainer m_components; - private IContainer Components - { - get { return m_components; } - } - - private ToolTip m_toolTip; - - public VS2005DockPaneCaption(DockPane pane) : base(pane) - { - SuspendLayout(); - - m_components = new Container(); - m_toolTip = new ToolTip(Components); - - ResumeLayout(); - } - - protected override void Dispose(bool disposing) - { - if (disposing) - Components.Dispose(); - base.Dispose(disposing); - } - - private static int TextGapTop - { - get { return _TextGapTop; } - } - - private static Font TextFont - { - get { return SystemInformation.MenuFont; } - } - - private static int TextGapBottom - { - get { return _TextGapBottom; } - } - - private static int TextGapLeft - { - get { return _TextGapLeft; } - } - - private static int TextGapRight - { - get { return _TextGapRight; } - } - - private static int ButtonGapTop - { - get { return _ButtonGapTop; } - } - - private static int ButtonGapBottom - { - get { return _ButtonGapBottom; } - } - - private static int ButtonGapLeft - { - get { return _ButtonGapLeft; } - } - - private static int ButtonGapRight - { - get { return _ButtonGapRight; } - } - - private static int ButtonGapBetween - { - get { return _ButtonGapBetween; } - } - - private static string _toolTipClose; - private static string ToolTipClose - { - get - { - if (_toolTipClose == null) - _toolTipClose = Strings.DockPaneCaption_ToolTipClose; - return _toolTipClose; - } - } - - private static string _toolTipOptions; - private static string ToolTipOptions - { - get - { - if (_toolTipOptions == null) - _toolTipOptions = Strings.DockPaneCaption_ToolTipOptions; - - return _toolTipOptions; - } - } - - private static string _toolTipAutoHide; - private static string ToolTipAutoHide - { - get - { - if (_toolTipAutoHide == null) - _toolTipAutoHide = Strings.DockPaneCaption_ToolTipAutoHide; - return _toolTipAutoHide; - } - } - - private static Blend _activeBackColorGradientBlend; - private static Blend ActiveBackColorGradientBlend - { - get - { - if (_activeBackColorGradientBlend == null) - { - Blend blend = new Blend(2); - - blend.Factors = new float[]{0.5F, 1.0F}; - blend.Positions = new float[]{0.0F, 1.0F}; - _activeBackColorGradientBlend = blend; - } - - return _activeBackColorGradientBlend; - } - } - - private static Color ActiveBackColorGradientBegin - { - get { return SystemColors.GradientActiveCaption; } - } - - private static Color ActiveBackColorGradientEnd - { - get { return SystemColors.ActiveCaption; } - } - - private static Color InactiveBackColor - { - get - { - return SystemColors.Control; - } - } - - private static Color ActiveTextColor - { - get { return SystemColors.ActiveCaptionText; } - } - - private static Color InactiveTextColor - { - get { return SystemColors.ControlText; } - } - - private Color TextColor - { - get { return DockPane.IsActivated ? ActiveTextColor : InactiveTextColor; } - } - - private static TextFormatFlags _textFormat = - TextFormatFlags.SingleLine | - TextFormatFlags.EndEllipsis | - TextFormatFlags.VerticalCenter; - private TextFormatFlags TextFormat - { - get - { - if (RightToLeft == RightToLeft.No) - return _textFormat; - else - return _textFormat | TextFormatFlags.RightToLeft | TextFormatFlags.Right; - } - } - - protected internal override int MeasureHeight() - { - int height = TextFont.Height + TextGapTop + TextGapBottom; - - if (height < ButtonClose.Image.Height + ButtonGapTop + ButtonGapBottom) - height = ButtonClose.Image.Height + ButtonGapTop + ButtonGapBottom; - - return height; - } - - protected override void OnPaint(PaintEventArgs e) - { - base.OnPaint (e); - DrawCaption(e.Graphics); - } - - private void DrawCaption(Graphics g) - { - if (ClientRectangle.Width == 0 || ClientRectangle.Height == 0) - return; - - if (DockPane.IsActivated) - { - using (LinearGradientBrush brush = new LinearGradientBrush(ClientRectangle, ActiveBackColorGradientBegin, ActiveBackColorGradientEnd, LinearGradientMode.Vertical)) - { - brush.Blend = ActiveBackColorGradientBlend; - g.FillRectangle(brush, ClientRectangle); - } - } - else - { - using (SolidBrush brush = new SolidBrush(InactiveBackColor)) - { - g.FillRectangle(brush, ClientRectangle); - } - g.DrawRectangle(SystemPens.ControlDark, new Rectangle(0, 0, ClientSize.Width - 1, ClientSize.Height - 1)); - } - - Rectangle rectCaption = ClientRectangle; - - Rectangle rectCaptionText = rectCaption; - rectCaptionText.X += TextGapLeft; - rectCaptionText.Width -= TextGapLeft + TextGapRight; - rectCaptionText.Width -= ButtonGapLeft + ButtonClose.Width + ButtonGapRight; - if (ShouldShowAutoHideButton) - rectCaptionText.Width -= ButtonAutoHide.Width + ButtonGapBetween; - if (HasTabPageContextMenu) - rectCaptionText.Width -= ButtonOptions.Width + ButtonGapBetween; - rectCaptionText.Y += TextGapTop; - rectCaptionText.Height -= TextGapTop + TextGapBottom; - TextRenderer.DrawText(g, DockPane.CaptionText, TextFont, DrawHelper.RtlTransform(this, rectCaptionText), TextColor, TextFormat); - } - - protected override void OnLayout(LayoutEventArgs levent) - { - SetButtonsPosition(); - base.OnLayout (levent); - } - - protected override void OnRefreshChanges() - { - SetButtons(); - Invalidate(); - } - - private bool CloseButtonEnabled - { - get { return (DockPane.ActiveContent != null)? DockPane.ActiveContent.DockHandler.CloseButton : false; } - } - - private bool ShouldShowAutoHideButton - { - get { return !DockPane.IsFloat; } - } - - private void SetButtons() - { - ButtonClose.Enabled = CloseButtonEnabled; - ButtonAutoHide.Visible = ShouldShowAutoHideButton; - ButtonOptions.Visible = HasTabPageContextMenu; - ButtonClose.RefreshChanges(); - ButtonAutoHide.RefreshChanges(); - ButtonOptions.RefreshChanges(); - - SetButtonsPosition(); - } - - private void SetButtonsPosition() - { - // set the size and location for close and auto-hide buttons - Rectangle rectCaption = ClientRectangle; - int buttonWidth = ButtonClose.Image.Width; - int buttonHeight = ButtonClose.Image.Height; - int height = rectCaption.Height - ButtonGapTop - ButtonGapBottom; - if (buttonHeight < height) - { - buttonWidth = buttonWidth * (height / buttonHeight); - buttonHeight = height; - } - Size buttonSize = new Size(buttonWidth, buttonHeight); - int x = rectCaption.X + rectCaption.Width - 1 - ButtonGapRight - m_buttonClose.Width; - int y = rectCaption.Y + ButtonGapTop; - Point point = new Point(x, y); - ButtonClose.Bounds = DrawHelper.RtlTransform(this, new Rectangle(point, buttonSize)); - point.Offset(-(buttonWidth + ButtonGapBetween), 0); - ButtonAutoHide.Bounds = DrawHelper.RtlTransform(this, new Rectangle(point, buttonSize)); - if (ShouldShowAutoHideButton) - point.Offset(-(buttonWidth + ButtonGapBetween), 0); - ButtonOptions.Bounds = DrawHelper.RtlTransform(this, new Rectangle(point, buttonSize)); - } - - private void Close_Click(object sender, EventArgs e) - { - DockPane.CloseActiveContent(); - } - - private void AutoHide_Click(object sender, EventArgs e) - { - DockPane.DockState = DockHelper.ToggleAutoHideState(DockPane.DockState); - } - - private void Options_Click(object sender, EventArgs e) - { - ShowTabPageContextMenu(PointToClient(Control.MousePosition)); - } - - protected override void OnRightToLeftChanged(EventArgs e) - { - base.OnRightToLeftChanged(e); - PerformLayout(); - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/VS2005DockPaneStrip.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/VS2005DockPaneStrip.cs deleted file mode 100644 index c372a1065c..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/VS2005DockPaneStrip.cs +++ /dev/null @@ -1,1301 +0,0 @@ -using System; -using System.Drawing; -using System.Drawing.Drawing2D; -using System.Windows.Forms; -using System.ComponentModel; -using System.Collections; -using System.Collections.Generic; - -namespace WeifenLuo.WinFormsUI.Docking -{ - internal class VS2005DockPaneStrip : DockPaneStripBase - { - private class TabVS2005 : Tab - { - public TabVS2005(IDockContent content) - : base(content) - { - } - - private int m_tabX; - public int TabX - { - get { return m_tabX; } - set { m_tabX = value; } - } - - private int m_tabWidth; - public int TabWidth - { - get { return m_tabWidth; } - set { m_tabWidth = value; } - } - - private int m_maxWidth; - public int MaxWidth - { - get { return m_maxWidth; } - set { m_maxWidth = value; } - } - - private bool m_flag; - protected internal bool Flag - { - get { return m_flag; } - set { m_flag = value; } - } - } - - protected internal override DockPaneStripBase.Tab CreateTab(IDockContent content) - { - return new TabVS2005(content); - } - - private sealed class InertButton : InertButtonBase - { - private Bitmap m_image0, m_image1; - - public InertButton(Bitmap image0, Bitmap image1) - : base() - { - m_image0 = image0; - m_image1 = image1; - } - - private int m_imageCategory = 0; - public int ImageCategory - { - get { return m_imageCategory; } - set - { - if (m_imageCategory == value) - return; - - m_imageCategory = value; - Invalidate(); - } - } - - public override Bitmap Image - { - get { return ImageCategory == 0 ? m_image0 : m_image1; } - } - - protected override void OnRefreshChanges() - { - if (VS2005DockPaneStrip.ColorDocumentActiveText != ForeColor) - { - ForeColor = VS2005DockPaneStrip.ColorDocumentActiveText; - Invalidate(); - } - } - } - - #region consts - private const int _ToolWindowStripGapTop = 0; - private const int _ToolWindowStripGapBottom = 1; - private const int _ToolWindowStripGapLeft = 0; - private const int _ToolWindowStripGapRight = 0; - private const int _ToolWindowImageHeight = 16; - private const int _ToolWindowImageWidth = 16; - private const int _ToolWindowImageGapTop = 3; - private const int _ToolWindowImageGapBottom = 1; - private const int _ToolWindowImageGapLeft = 2; - private const int _ToolWindowImageGapRight = 0; - private const int _ToolWindowTextGapRight = 3; - private const int _ToolWindowTabSeperatorGapTop = 3; - private const int _ToolWindowTabSeperatorGapBottom = 3; - - private const int _DocumentStripGapTop = 0; - private const int _DocumentStripGapBottom = 1; - private const int _DocumentTabMaxWidth = 200; - private const int _DocumentButtonGapTop = 4; - private const int _DocumentButtonGapBottom = 4; - private const int _DocumentButtonGapBetween = 0; - private const int _DocumentButtonGapRight = 3; - private const int _DocumentTabGapTop = 3; - private const int _DocumentTabGapLeft = 3; - private const int _DocumentTabGapRight = 3; - private const int _DocumentIconGapBottom = 2; - private const int _DocumentIconGapLeft = 8; - private const int _DocumentIconGapRight = 0; - private const int _DocumentIconHeight = 16; - private const int _DocumentIconWidth = 16; - private const int _DocumentTextGapRight = 3; - #endregion - - private static Bitmap _imageButtonClose; - private static Bitmap ImageButtonClose - { - get - { - if (_imageButtonClose == null) - _imageButtonClose = Resources.DockPane_Close; - - return _imageButtonClose; - } - } - - private InertButton m_buttonClose; - private InertButton ButtonClose - { - get - { - if (m_buttonClose == null) - { - m_buttonClose = new InertButton(ImageButtonClose, ImageButtonClose); - m_toolTip.SetToolTip(m_buttonClose, ToolTipClose); - m_buttonClose.Click += new EventHandler(Close_Click); - Controls.Add(m_buttonClose); - } - - return m_buttonClose; - } - } - - private static Bitmap _imageButtonWindowList; - private static Bitmap ImageButtonWindowList - { - get - { - if (_imageButtonWindowList == null) - _imageButtonWindowList = Resources.DockPane_Option; - - return _imageButtonWindowList; - } - } - - private static Bitmap _imageButtonWindowListOverflow; - private static Bitmap ImageButtonWindowListOverflow - { - get - { - if (_imageButtonWindowListOverflow == null) - _imageButtonWindowListOverflow = Resources.DockPane_OptionOverflow; - - return _imageButtonWindowListOverflow; - } - } - - private InertButton m_buttonWindowList; - private InertButton ButtonWindowList - { - get - { - if (m_buttonWindowList == null) - { - m_buttonWindowList = new InertButton(ImageButtonWindowList, ImageButtonWindowListOverflow); - m_toolTip.SetToolTip(m_buttonWindowList, ToolTipSelect); - m_buttonWindowList.Click += new EventHandler(WindowList_Click); - Controls.Add(m_buttonWindowList); - } - - return m_buttonWindowList; - } - } - - private static GraphicsPath GraphicsPath - { - get { return VS2005AutoHideStrip.GraphicsPath; } - } - - private IContainer m_components; - private ToolTip m_toolTip; - private IContainer Components - { - get { return m_components; } - } - - #region Customizable Properties - private static int ToolWindowStripGapTop - { - get { return _ToolWindowStripGapTop; } - } - - private static int ToolWindowStripGapBottom - { - get { return _ToolWindowStripGapBottom; } - } - - private static int ToolWindowStripGapLeft - { - get { return _ToolWindowStripGapLeft; } - } - - private static int ToolWindowStripGapRight - { - get { return _ToolWindowStripGapRight; } - } - - private static int ToolWindowImageHeight - { - get { return _ToolWindowImageHeight; } - } - - private static int ToolWindowImageWidth - { - get { return _ToolWindowImageWidth; } - } - - private static int ToolWindowImageGapTop - { - get { return _ToolWindowImageGapTop; } - } - - private static int ToolWindowImageGapBottom - { - get { return _ToolWindowImageGapBottom; } - } - - private static int ToolWindowImageGapLeft - { - get { return _ToolWindowImageGapLeft; } - } - - private static int ToolWindowImageGapRight - { - get { return _ToolWindowImageGapRight; } - } - - private static int ToolWindowTextGapRight - { - get { return _ToolWindowTextGapRight; } - } - - private static int ToolWindowTabSeperatorGapTop - { - get { return _ToolWindowTabSeperatorGapTop; } - } - - private static int ToolWindowTabSeperatorGapBottom - { - get { return _ToolWindowTabSeperatorGapBottom; } - } - - private static string _toolTipClose; - private static string ToolTipClose - { - get - { - if (_toolTipClose == null) - _toolTipClose = Strings.DockPaneStrip_ToolTipClose; - return _toolTipClose; - } - } - - private static string _toolTipSelect; - private static string ToolTipSelect - { - get - { - if (_toolTipSelect == null) - _toolTipSelect = Strings.DockPaneStrip_ToolTipWindowList; - return _toolTipSelect; - } - } - - private TextFormatFlags ToolWindowTextFormat - { - get - { - TextFormatFlags textFormat = TextFormatFlags.EndEllipsis | - TextFormatFlags.HorizontalCenter | - TextFormatFlags.SingleLine | - TextFormatFlags.VerticalCenter; - if (RightToLeft == RightToLeft.Yes) - return textFormat | TextFormatFlags.RightToLeft | TextFormatFlags.Right; - else - return textFormat; - } - } - - private static int DocumentStripGapTop - { - get { return _DocumentStripGapTop; } - } - - private static int DocumentStripGapBottom - { - get { return _DocumentStripGapBottom; } - } - - private TextFormatFlags DocumentTextFormat - { - get - { - TextFormatFlags textFormat = TextFormatFlags.PathEllipsis | - TextFormatFlags.SingleLine | - TextFormatFlags.VerticalCenter | - TextFormatFlags.PreserveGraphicsClipping | - TextFormatFlags.HorizontalCenter; - if (RightToLeft == RightToLeft.Yes) - return textFormat | TextFormatFlags.RightToLeft; - else - return textFormat; - } - } - - private static int DocumentTabMaxWidth - { - get { return _DocumentTabMaxWidth; } - } - - private static int DocumentButtonGapTop - { - get { return _DocumentButtonGapTop; } - } - - private static int DocumentButtonGapBottom - { - get { return _DocumentButtonGapBottom; } - } - - private static int DocumentButtonGapBetween - { - get { return _DocumentButtonGapBetween; } - } - - private static int DocumentButtonGapRight - { - get { return _DocumentButtonGapRight; } - } - - private static int DocumentTabGapTop - { - get { return _DocumentTabGapTop; } - } - - private static int DocumentTabGapLeft - { - get { return _DocumentTabGapLeft; } - } - - private static int DocumentTabGapRight - { - get { return _DocumentTabGapRight; } - } - - private static int DocumentIconGapBottom - { - get { return _DocumentIconGapBottom; } - } - - private static int DocumentIconGapLeft - { - get { return _DocumentIconGapLeft; } - } - - private static int DocumentIconGapRight - { - get { return _DocumentIconGapRight; } - } - - private static int DocumentIconWidth - { - get { return _DocumentIconWidth; } - } - - private static int DocumentIconHeight - { - get { return _DocumentIconHeight; } - } - - private static int DocumentTextGapRight - { - get { return _DocumentTextGapRight; } - } - - private static Pen PenToolWindowTabBorder - { - get { return SystemPens.GrayText; } - } - - private static Pen PenDocumentTabActiveBorder - { - get { return SystemPens.ControlDarkDark; } - } - - private static Pen PenDocumentTabInactiveBorder - { - get { return SystemPens.GrayText; } - } - - private static Brush BrushToolWindowActiveBackground - { - get { return SystemBrushes.ControlLightLight; } - } - - private static Brush BrushDocumentActiveBackground - { - get { return SystemBrushes.ControlLightLight; } - } - - private static Brush BrushDocumentInactiveBackground - { - get { return SystemBrushes.ControlLight; } - } - - private static Color ColorToolWindowActiveText - { - get { return SystemColors.ControlText; } - } - - private static Color ColorDocumentActiveText - { - get { return SystemColors.ControlText; } - } - - private static Color ColorToolWindowInactiveText - { - get { return SystemColors.ControlDarkDark; } - } - - private static Color ColorDocumentInactiveText - { - get { return SystemColors.ControlText; } - } - - #endregion - - public VS2005DockPaneStrip(DockPane pane) : base(pane) - { - SetStyle(ControlStyles.ResizeRedraw | - ControlStyles.UserPaint | - ControlStyles.AllPaintingInWmPaint | - ControlStyles.OptimizedDoubleBuffer, true); - - SuspendLayout(); - - m_components = new Container(); - m_toolTip = new ToolTip(Components); - m_selectMenu = new ContextMenuStrip(Components); - - ResumeLayout(); - } - - protected override void Dispose(bool disposing) - { - if (disposing) - { - Components.Dispose(); - if (m_boldFont != null) - { - m_boldFont.Dispose(); - m_boldFont = null; - } - } - base.Dispose (disposing); - } - - private static Font TextFont - { - get { return SystemInformation.MenuFont; } - } - - private Font m_font; - private Font m_boldFont; - private Font BoldFont - { - get - { - if (IsDisposed) - return null; - - if (m_boldFont == null) - { - m_font = TextFont; - m_boldFont = new Font(TextFont, FontStyle.Bold); - } - else if (m_font != TextFont) - { - m_boldFont.Dispose(); - m_font = TextFont; - m_boldFont = new Font(TextFont, FontStyle.Bold); - } - - return m_boldFont; - } - } - - private int m_startDisplayingTab = 0; - private int StartDisplayingTab - { - get { return m_startDisplayingTab; } - set - { - m_startDisplayingTab = value; - Invalidate(); - } - } - - private int m_endDisplayingTab = 0; - private int EndDisplayingTab - { - get { return m_endDisplayingTab; } - set { m_endDisplayingTab = value; } - } - - private bool m_documentTabsOverflow = false; - private bool DocumentTabsOverflow - { - set - { - if (m_documentTabsOverflow == value) - return; - - m_documentTabsOverflow = value; - if (value) - ButtonWindowList.ImageCategory = 1; - else - ButtonWindowList.ImageCategory = 0; - } - } - - protected internal override int MeasureHeight() - { - if (Appearance == DockPane.AppearanceStyle.ToolWindow) - return MeasureHeight_ToolWindow(); - else - return MeasureHeight_Document(); - } - - private int MeasureHeight_ToolWindow() - { - if (DockPane.IsAutoHide || Tabs.Count <= 1) - return 0; - - int height = Math.Max(TextFont.Height, ToolWindowImageHeight + ToolWindowImageGapTop + ToolWindowImageGapBottom) - + ToolWindowStripGapTop + ToolWindowStripGapBottom; - - return height; - } - - private int MeasureHeight_Document() - { - int height = Math.Max(TextFont.Height + DocumentTabGapTop, - ButtonClose.Height + DocumentButtonGapTop + DocumentButtonGapBottom) - + DocumentStripGapBottom + DocumentStripGapTop; - - return height; - } - - protected override void OnPaint(PaintEventArgs e) - { - if (Appearance == DockPane.AppearanceStyle.Document) - { - if (BackColor != SystemColors.Control) - BackColor = SystemColors.Control; - } - else - { - if (BackColor != SystemColors.ControlLight) - BackColor = SystemColors.ControlLight; - } - base.OnPaint (e); - CalculateTabs(); - if (Appearance == DockPane.AppearanceStyle.Document && DockPane.ActiveContent != null) - { - if (EnsureDocumentTabVisible(DockPane.ActiveContent, false)) - CalculateTabs(); - } - - DrawTabStrip(e.Graphics); - } - - protected override void OnRefreshChanges() - { - SetInertButtons(); - Invalidate(); - } - - protected internal override GraphicsPath GetOutline(int index) - { - - if (Appearance == DockPane.AppearanceStyle.Document) - return GetOutline_Document(index); - else - return GetOutline_ToolWindow(index); - - } - - private GraphicsPath GetOutline_Document(int index) - { - Rectangle rectTab = GetTabRectangle(index); - rectTab.X -= rectTab.Height / 2; - rectTab.Intersect(TabsRectangle); - rectTab = RectangleToScreen(DrawHelper.RtlTransform(this, rectTab)); - int y = rectTab.Top; - Rectangle rectPaneClient = DockPane.RectangleToScreen(DockPane.ClientRectangle); - - GraphicsPath path = new GraphicsPath(); - GraphicsPath pathTab = GetTabOutline_Document(Tabs[index], true, true, true); - path.AddPath(pathTab, true); - path.AddLine(rectTab.Right, rectTab.Bottom, rectPaneClient.Right, rectTab.Bottom); - path.AddLine(rectPaneClient.Right, rectTab.Bottom, rectPaneClient.Right, rectPaneClient.Bottom); - path.AddLine(rectPaneClient.Right, rectPaneClient.Bottom, rectPaneClient.Left, rectPaneClient.Bottom); - path.AddLine(rectPaneClient.Left, rectPaneClient.Bottom, rectPaneClient.Left, rectTab.Bottom); - path.AddLine(rectPaneClient.Left, rectTab.Bottom, rectTab.Right, rectTab.Bottom); - return path; - } - - private GraphicsPath GetOutline_ToolWindow(int index) - { - Rectangle rectTab = GetTabRectangle(index); - rectTab.Intersect(TabsRectangle); - rectTab = RectangleToScreen(DrawHelper.RtlTransform(this, rectTab)); - int y = rectTab.Top; - Rectangle rectPaneClient = DockPane.RectangleToScreen(DockPane.ClientRectangle); - - GraphicsPath path = new GraphicsPath(); - GraphicsPath pathTab = GetTabOutline(Tabs[index], true, true); - path.AddPath(pathTab, true); - path.AddLine(rectTab.Left, rectTab.Top, rectPaneClient.Left, rectTab.Top); - path.AddLine(rectPaneClient.Left, rectTab.Top, rectPaneClient.Left, rectPaneClient.Top); - path.AddLine(rectPaneClient.Left, rectPaneClient.Top, rectPaneClient.Right, rectPaneClient.Top); - path.AddLine(rectPaneClient.Right, rectPaneClient.Top, rectPaneClient.Right, rectTab.Top); - path.AddLine(rectPaneClient.Right, rectTab.Top, rectTab.Right, rectTab.Top); - return path; - } - - private void CalculateTabs() - { - if (Appearance == DockPane.AppearanceStyle.ToolWindow) - CalculateTabs_ToolWindow(); - else - CalculateTabs_Document(); - } - - private void CalculateTabs_ToolWindow() - { - if (Tabs.Count <= 1 || DockPane.IsAutoHide) - return; - - Rectangle rectTabStrip = TabStripRectangle; - - // Calculate tab widths - int countTabs = Tabs.Count; - foreach (TabVS2005 tab in Tabs) - { - tab.MaxWidth = GetMaxTabWidth(Tabs.IndexOf(tab)); - tab.Flag = false; - } - - // Set tab whose max width less than average width - bool anyWidthWithinAverage = true; - int totalWidth = rectTabStrip.Width - ToolWindowStripGapLeft - ToolWindowStripGapRight; - int totalAllocatedWidth = 0; - int averageWidth = totalWidth / countTabs; - int remainedTabs = countTabs; - for (anyWidthWithinAverage=true; anyWidthWithinAverage && remainedTabs>0;) - { - anyWidthWithinAverage = false; - foreach (TabVS2005 tab in Tabs) - { - if (tab.Flag) - continue; - - if (tab.MaxWidth <= averageWidth) - { - tab.Flag = true; - tab.TabWidth = tab.MaxWidth; - totalAllocatedWidth += tab.TabWidth; - anyWidthWithinAverage = true; - remainedTabs--; - } - } - if (remainedTabs != 0) - averageWidth = (totalWidth - totalAllocatedWidth) / remainedTabs; - } - - // If any tab width not set yet, set it to the average width - if (remainedTabs > 0) - { - int roundUpWidth = (totalWidth - totalAllocatedWidth) - (averageWidth * remainedTabs); - foreach (TabVS2005 tab in Tabs) - { - if (tab.Flag) - continue; - - tab.Flag = true; - if (roundUpWidth > 0) - { - tab.TabWidth = averageWidth + 1; - roundUpWidth --; - } - else - tab.TabWidth = averageWidth; - } - } - - // Set the X position of the tabs - int x = rectTabStrip.X + ToolWindowStripGapLeft; - foreach (TabVS2005 tab in Tabs) - { - tab.TabX = x; - x += tab.TabWidth; - } - } - - private bool CalculateDocumentTab(Rectangle rectTabStrip, ref int x, int index) - { - bool overflow = false; - - TabVS2005 tab = Tabs[index] as TabVS2005; - tab.MaxWidth = GetMaxTabWidth(index); - int width = Math.Min(tab.MaxWidth, DocumentTabMaxWidth); - if (x + width < rectTabStrip.Right || index == StartDisplayingTab) - { - tab.TabX = x; - tab.TabWidth = width; - EndDisplayingTab = index; - } - else - { - tab.TabX = 0; - tab.TabWidth = 0; - overflow = true; - } - x += width; - - return overflow; - } - - private void CalculateTabs_Document() - { - if (m_startDisplayingTab >= Tabs.Count) - m_startDisplayingTab = 0; - - Rectangle rectTabStrip = TabsRectangle; - - int x = rectTabStrip.X + rectTabStrip.Height / 2; - - bool overflow = false; - for (int i = StartDisplayingTab; i < Tabs.Count; i++) - overflow = CalculateDocumentTab(rectTabStrip, ref x, i); - - for (int i = 0; i < StartDisplayingTab; i++) - overflow = CalculateDocumentTab(rectTabStrip, ref x, i); - - if (!overflow) - { - m_startDisplayingTab = 0; - x = rectTabStrip.X + rectTabStrip.Height / 2; - foreach (TabVS2005 tab in Tabs) - { - tab.TabX = x; - x += tab.TabWidth; - } - } - DocumentTabsOverflow = overflow; - } - - protected internal override void EnsureTabVisible(IDockContent content) - { - if (Appearance != DockPane.AppearanceStyle.Document || !Tabs.Contains(content)) - return; - - CalculateTabs(); - EnsureDocumentTabVisible(content, true); - } - - private bool EnsureDocumentTabVisible(IDockContent content, bool repaint) - { - int index = Tabs.IndexOf(content); - TabVS2005 tab = Tabs[index] as TabVS2005; - if (tab.TabWidth != 0) - return false; - - StartDisplayingTab = index; - if (repaint) - Invalidate(); - - return true; - } - - private int GetMaxTabWidth(int index) - { - if (Appearance == DockPane.AppearanceStyle.ToolWindow) - return GetMaxTabWidth_ToolWindow(index); - else - return GetMaxTabWidth_Document(index); - } - - private int GetMaxTabWidth_ToolWindow(int index) - { - IDockContent content = Tabs[index].Content; - Size sizeString = TextRenderer.MeasureText(content.DockHandler.TabText, TextFont); - return ToolWindowImageWidth + sizeString.Width + ToolWindowImageGapLeft - + ToolWindowImageGapRight + ToolWindowTextGapRight; - } - - private int GetMaxTabWidth_Document(int index) - { - IDockContent content = Tabs[index].Content; - - int height = GetTabRectangle_Document(index).Height; - - Size sizeText = TextRenderer.MeasureText(content.DockHandler.TabText, BoldFont, new Size(DocumentTabMaxWidth, height), DocumentTextFormat); - - if (DockPane.DockPanel.ShowDocumentIcon) - return sizeText.Width + DocumentIconWidth + DocumentIconGapLeft + DocumentIconGapRight + DocumentTextGapRight; - else - return sizeText.Width + DocumentIconGapLeft + DocumentTextGapRight; - } - - private void DrawTabStrip(Graphics g) - { - if (Appearance == DockPane.AppearanceStyle.Document) - DrawTabStrip_Document(g); - else - DrawTabStrip_ToolWindow(g); - } - - private void DrawTabStrip_Document(Graphics g) - { - int count = Tabs.Count; - if (count == 0) - return; - - Rectangle rectTabStrip = TabStripRectangle; - - // Draw the tabs - Rectangle rectTabOnly = TabsRectangle; - Rectangle rectTab = Rectangle.Empty; - TabVS2005 tabActive = null; - g.SetClip(DrawHelper.RtlTransform(this, rectTabOnly)); - for (int i=0; i tab.TabWidth) - toolTip = tab.Content.DockHandler.TabText; - } - - if (m_toolTip.GetToolTip(this) != toolTip) - { - m_toolTip.Active = false; - m_toolTip.SetToolTip(this, toolTip); - m_toolTip.Active = true; - } - - // requires further tracking of mouse hover behavior, - ResetMouseEventArgs(); - } - - protected override void OnRightToLeftChanged(EventArgs e) - { - base.OnRightToLeftChanged(e); - PerformLayout(); - } - } -} diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/VisibleNestedPaneCollection.cs b/src/Libraries/DockPanel_Src/WinFormsUI/Docking/VisibleNestedPaneCollection.cs deleted file mode 100644 index 46ff1b1fa9..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/Docking/VisibleNestedPaneCollection.cs +++ /dev/null @@ -1,168 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Collections.ObjectModel; -using System.Drawing; -using System.Windows.Forms; - -namespace WeifenLuo.WinFormsUI.Docking -{ - public sealed class VisibleNestedPaneCollection : ReadOnlyCollection - { - private NestedPaneCollection m_nestedPanes; - - internal VisibleNestedPaneCollection(NestedPaneCollection nestedPanes) - : base(new List()) - { - m_nestedPanes = nestedPanes; - } - - public NestedPaneCollection NestedPanes - { - get { return m_nestedPanes; } - } - - public INestedPanesContainer Container - { - get { return NestedPanes.Container; } - } - - public DockState DockState - { - get { return NestedPanes.DockState; } - } - - public bool IsFloat - { - get { return NestedPanes.IsFloat; } - } - - internal void Refresh() - { - Items.Clear(); - for (int i=0; i IndexOf(pane); i--) - { - if (this[i].NestedDockingStatus.PreviousPane == pane) - { - lastNestedPane = this[i]; - break; - } - } - - if (lastNestedPane != null) - { - int indexLastNestedPane = IndexOf(lastNestedPane); - Items.Remove(lastNestedPane); - Items[IndexOf(pane)] = lastNestedPane; - NestedDockingStatus lastNestedDock = lastNestedPane.NestedDockingStatus; - lastNestedDock.SetDisplayingStatus(true, statusPane.DisplayingPreviousPane, statusPane.DisplayingAlignment, statusPane.DisplayingProportion); - for (int i=indexLastNestedPane - 1; i>IndexOf(lastNestedPane); i--) - { - NestedDockingStatus status = this[i].NestedDockingStatus; - if (status.PreviousPane == pane) - status.SetDisplayingStatus(true, lastNestedPane, status.DisplayingAlignment, status.DisplayingProportion); - } - } - else - Items.Remove(pane); - - statusPane.SetDisplayingStatus(false, null, DockAlignment.Left, 0.5); - } - - private void CalculateBounds() - { - if (Count == 0) - return; - - this[0].NestedDockingStatus.SetDisplayingBounds(Container.DisplayingRectangle, Container.DisplayingRectangle, Rectangle.Empty); - - for (int i=1; i - - Debug - AnyCPU - 8.0.50727 - 2.0 - {C75532C4-765B-418E-B09B-46D36B2ABDB1} - Library - Properties - WeifenLuo.WinFormsUI - WeifenLuo.WinFormsUI.Docking - true - ..\..\..\Main\ICSharpCode.SharpDevelop.snk - False - File - ..\..\..\..\bin\ - False - False - false - - - true - full - false - TRACE;DEBUG - prompt - 4 - - - pdbonly - true - TRACE - prompt - 4 - - - - - - - - - - - - Component - - - Component - - - Form - - - Component - - - Component - - - Component - - - Component - - - Component - - - - - Form - - - - - Component - - - - - - UserControl - - - Component - - - Component - - - - Component - - - - Component - - - UserControl - - - Component - - - Component - - - Component - - - - Component - - - Component - - - - - Form - - - - Component - - - - - - Component - - - - - - - - True - True - Resources.resx - - - True - True - Strings.resx - - - - - patchnotes.txt - - - - - Designer - ResXFileCodeGenerator - Resources.Designer.cs - - - Designer - ResXFileCodeGenerator - Strings.Designer.cs - - - - - - - - - - - - - - - - - - - - - - - - - Never - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/src/Libraries/DockPanel_Src/WinFormsUI/license.txt b/src/Libraries/DockPanel_Src/WinFormsUI/license.txt deleted file mode 100644 index 96f3fa5ce9..0000000000 --- a/src/Libraries/DockPanel_Src/WinFormsUI/license.txt +++ /dev/null @@ -1,9 +0,0 @@ -The MIT License - -Copyright (c) 2007 Weifen Luo (email: weifenluo@yahoo.com) - -Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/src/Libraries/DockPanel_Src/license.txt b/src/Libraries/DockPanel_Src/license.txt deleted file mode 100644 index 96f3fa5ce9..0000000000 --- a/src/Libraries/DockPanel_Src/license.txt +++ /dev/null @@ -1,9 +0,0 @@ -The MIT License - -Copyright (c) 2007 Weifen Luo (email: weifenluo@yahoo.com) - -Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/src/Libraries/DockPanel_Src/patchnotes.txt b/src/Libraries/DockPanel_Src/patchnotes.txt deleted file mode 100644 index c78739c786..0000000000 --- a/src/Libraries/DockPanel_Src/patchnotes.txt +++ /dev/null @@ -1,31 +0,0 @@ -List of our custom patches to apply to the DockPanel Suite: - -Patch #0: - Add bool IsDisposed { get; } to IDockContent interface. - -Patch #1: - Close documents with middle click - in DockPaneStripBase.cs - Remove redundant finalizers - in AutoHideStripBase.cs, DockPaneStripBase.cs - Changed background color of inactive pads. - in VS2005DockPaneCaption.cs, VS2005DockPaneStip.cs - Committed in revision 2706. - -Patch #2: - Prevent crash in DockPanel.FocusManager.Activate when active pane was removed (e.g. the pad - that was active when SharpDevelop was closed does not exist anymore after an AddIn was removed - manually or SharpDevelop was updated) - Committed in revision 2732. - -Patch #3: - Disable MDI focus workaround in DockContentHandler.cs - This fixes the System.InvalidOperationException: Invalid Content: ActiveContent must be one ofthe visible contents, or null if there is no visible content. - that occurs on layout changes iff no document is open and a pad has the focus. - Committed in revision 2751. - -Patch #4: - Prevent stack overflow in DockContentHandler.cs when showing a pad in certain layout configurations. - Committed in revision 2970. - -Patch #5: - In DockContentHandler.SetVisible: - Ensure pad visibility is set correctly, even when Windows.Forms is "lying" about Form.Visible. - Committed in revision 3061. diff --git a/src/Libraries/ICSharpCode.TextEditor/Project/Src/Gui/CompletionWindow/AbstractCompletionWindow.cs b/src/Libraries/ICSharpCode.TextEditor/Project/Src/Gui/CompletionWindow/AbstractCompletionWindow.cs index 8c17c5bb9f..286ca19458 100644 --- a/src/Libraries/ICSharpCode.TextEditor/Project/Src/Gui/CompletionWindow/AbstractCompletionWindow.cs +++ b/src/Libraries/ICSharpCode.TextEditor/Project/Src/Gui/CompletionWindow/AbstractCompletionWindow.cs @@ -19,13 +19,15 @@ namespace ICSharpCode.TextEditor.Gui.CompletionWindow protected TextEditorControl control; protected Size drawingSize; Rectangle workingScreen; + IWin32Window parentWindow; Form parentForm; - protected AbstractCompletionWindow(Form parentForm, TextEditorControl control) + protected AbstractCompletionWindow(IWin32Window parentWindow, TextEditorControl control) { - workingScreen = Screen.GetWorkingArea(parentForm); + workingScreen = Screen.GetWorkingArea(control); // SetStyle(ControlStyles.Selectable, false); - this.parentForm = parentForm; + this.parentWindow = parentWindow; + this.parentForm = parentWindow as Form; this.control = control; SetLocation(); @@ -44,7 +46,7 @@ namespace ICSharpCode.TextEditor.Gui.CompletionWindow int xpos = textArea.TextView.GetDrawingXPos(caretPos.Y, caretPos.X); int rulerHeight = textArea.TextEditorProperties.ShowHorizontalRuler ? textArea.TextView.FontHeight : 0; Point pos = new Point(textArea.TextView.DrawingPosition.X + xpos, - textArea.TextView.DrawingPosition.Y + (textArea.Document.GetVisibleLine(caretPos.Y)) * textArea.TextView.FontHeight + textArea.TextView.DrawingPosition.Y + (textArea.Document.GetVisibleLine(caretPos.Y)) * textArea.TextView.FontHeight - textArea.TextView.TextArea.VirtualTop.Y + textArea.TextView.FontHeight + rulerHeight); Point location = control.ActiveTextAreaControl.PointToScreen(pos); @@ -110,9 +112,8 @@ namespace ICSharpCode.TextEditor.Gui.CompletionWindow protected void ShowCompletionWindow() { - Owner = parentForm; Enabled = true; - this.Show(); + this.Show(parentWindow); control.Focus(); @@ -171,7 +172,9 @@ namespace ICSharpCode.TextEditor.Gui.CompletionWindow base.OnClosed(e); // take out the inserted methods - parentForm.LocationChanged -= new EventHandler(ParentFormLocationChanged); + if (parentForm != null) { + parentForm.LocationChanged -= new EventHandler(ParentFormLocationChanged); + } foreach (Control c in Controls) { c.MouseMove -= ControlMouseMove; diff --git a/src/Libraries/ICSharpCode.TextEditor/Project/Src/Gui/CompletionWindow/CodeCompletionWindow.cs b/src/Libraries/ICSharpCode.TextEditor/Project/Src/Gui/CompletionWindow/CodeCompletionWindow.cs index f0730379a2..4edc91510b 100644 --- a/src/Libraries/ICSharpCode.TextEditor/Project/Src/Gui/CompletionWindow/CodeCompletionWindow.cs +++ b/src/Libraries/ICSharpCode.TextEditor/Project/Src/Gui/CompletionWindow/CodeCompletionWindow.cs @@ -30,12 +30,12 @@ namespace ICSharpCode.TextEditor.Gui.CompletionWindow DeclarationViewWindow declarationViewWindow = null; Rectangle workingScreen; - public static CodeCompletionWindow ShowCompletionWindow(Form parent, TextEditorControl control, string fileName, ICompletionDataProvider completionDataProvider, char firstChar) + public static CodeCompletionWindow ShowCompletionWindow(IWin32Window parent, TextEditorControl control, string fileName, ICompletionDataProvider completionDataProvider, char firstChar) { return ShowCompletionWindow(parent, control, fileName, completionDataProvider, firstChar, true, true); } - public static CodeCompletionWindow ShowCompletionWindow(Form parent, TextEditorControl control, string fileName, ICompletionDataProvider completionDataProvider, char firstChar, bool showDeclarationWindow, bool fixedListViewWidth) + public static CodeCompletionWindow ShowCompletionWindow(IWin32Window parent, TextEditorControl control, string fileName, ICompletionDataProvider completionDataProvider, char firstChar, bool showDeclarationWindow, bool fixedListViewWidth) { ICompletionData[] completionData = completionDataProvider.GenerateCompletionData(fileName, control.ActiveTextAreaControl.TextArea, firstChar); if (completionData == null || completionData.Length == 0) { @@ -47,7 +47,7 @@ namespace ICSharpCode.TextEditor.Gui.CompletionWindow return codeCompletionWindow; } - CodeCompletionWindow(ICompletionDataProvider completionDataProvider, ICompletionData[] completionData, Form parentForm, TextEditorControl control, bool showDeclarationWindow, bool fixedListViewWidth) : base(parentForm, control) + CodeCompletionWindow(ICompletionDataProvider completionDataProvider, ICompletionData[] completionData, IWin32Window parentWindow, TextEditorControl control, bool showDeclarationWindow, bool fixedListViewWidth) : base(parentWindow, control) { this.dataProvider = completionDataProvider; this.completionData = completionData; @@ -85,7 +85,7 @@ namespace ICSharpCode.TextEditor.Gui.CompletionWindow SetLocation(); if (declarationViewWindow == null) { - declarationViewWindow = new DeclarationViewWindow(parentForm); + declarationViewWindow = new DeclarationViewWindow(parentWindow); } SetDeclarationViewLocation(); declarationViewWindow.ShowDeclarationViewWindow(); diff --git a/src/Libraries/ICSharpCode.TextEditor/Project/Src/Gui/CompletionWindow/DeclarationViewWindow.cs b/src/Libraries/ICSharpCode.TextEditor/Project/Src/Gui/CompletionWindow/DeclarationViewWindow.cs index ac3c198551..82fdb25d02 100644 --- a/src/Libraries/ICSharpCode.TextEditor/Project/Src/Gui/CompletionWindow/DeclarationViewWindow.cs +++ b/src/Libraries/ICSharpCode.TextEditor/Project/Src/Gui/CompletionWindow/DeclarationViewWindow.cs @@ -43,13 +43,14 @@ namespace ICSharpCode.TextEditor.Gui.CompletionWindow } public bool HideOnClick; + IWin32Window parentWindow; - public DeclarationViewWindow(Form parent) + public DeclarationViewWindow(IWin32Window parent) { SetStyle(ControlStyles.Selectable, false); StartPosition = FormStartPosition.Manual; FormBorderStyle = FormBorderStyle.None; - Owner = parent; + this.parentWindow = parent; ShowInTaskbar = false; Size = new Size(0, 0); base.CreateHandle(); @@ -77,7 +78,7 @@ namespace ICSharpCode.TextEditor.Gui.CompletionWindow public void ShowDeclarationViewWindow() { - Show(); + Show(parentWindow); } public void CloseDeclarationViewWindow() diff --git a/src/Libraries/ICSharpCode.TextEditor/Project/Src/Gui/InsightWindow/InsightWindow.cs b/src/Libraries/ICSharpCode.TextEditor/Project/Src/Gui/InsightWindow/InsightWindow.cs index b6f19aef08..0a6a42078c 100644 --- a/src/Libraries/ICSharpCode.TextEditor/Project/Src/Gui/InsightWindow/InsightWindow.cs +++ b/src/Libraries/ICSharpCode.TextEditor/Project/Src/Gui/InsightWindow/InsightWindow.cs @@ -17,7 +17,7 @@ namespace ICSharpCode.TextEditor.Gui.InsightWindow { public class InsightWindow : AbstractCompletionWindow { - public InsightWindow(Form parentForm, TextEditorControl control) : base(parentForm, control) + public InsightWindow(IWin32Window parentWindow, TextEditorControl control) : base(parentWindow, control) { SetStyle(ControlStyles.UserPaint, true); SetStyle(ControlStyles.OptimizedDoubleBuffer, true); diff --git a/src/Main/Base/Project/ICSharpCode.SharpDevelop.csproj b/src/Main/Base/Project/ICSharpCode.SharpDevelop.csproj index d99fbceec5..bdcb67d662 100644 --- a/src/Main/Base/Project/ICSharpCode.SharpDevelop.csproj +++ b/src/Main/Base/Project/ICSharpCode.SharpDevelop.csproj @@ -40,6 +40,12 @@ False + + 3.0 + + + 3.0 + @@ -52,6 +58,10 @@ False + + 3.0 + + @@ -109,8 +119,10 @@ - + + + @@ -282,13 +294,13 @@ Component - + Form - - - + + + Form - + @@ -719,6 +731,7 @@ + ExtractInterfaceDialog.cs @@ -738,10 +751,6 @@ - - {D3C782BA-178E-4235-A3BA-8C11DEBB6BEE} - WinFormsUI - {2D18BE89-D210-49EB-A9DD-2246FBB3DF6D} ICSharpCode.TextEditor diff --git a/src/Main/Base/Project/Src/Commands/AutostartCommands.cs b/src/Main/Base/Project/Src/Commands/AutostartCommands.cs index 913737d0dd..a90778b90d 100644 --- a/src/Main/Base/Project/Src/Commands/AutostartCommands.cs +++ b/src/Main/Base/Project/Src/Commands/AutostartCommands.cs @@ -21,6 +21,7 @@ namespace ICSharpCode.SharpDevelop.Commands { const string workbenchMemento = "WorkbenchMemento"; + /* class FormKeyHandler : IMessageFilter { const int keyPressedMessage = 0x100; @@ -76,11 +77,10 @@ namespace ICSharpCode.SharpDevelop.Commands return false; } } + */ public void Run(IList fileList) { - //WorkbenchSingleton.MainForm.Show(); - bool didLoadSolutionOrFile = false; NavigationService.SuspendLogging(); @@ -123,8 +123,10 @@ namespace ICSharpCode.SharpDevelop.Commands ParserService.StartParserThread(); // finally run the workbench window ... - Application.AddMessageFilter(new FormKeyHandler()); - Application.Run(WorkbenchSingleton.MainForm); + //Application.AddMessageFilter(new FormKeyHandler()); + //Application.Run(WorkbenchSingleton.MainForm); + var application = new System.Windows.Application(); + application.Run(WorkbenchSingleton.MainWindow); // save the workbench memento in the ide properties try { diff --git a/src/Main/Base/Project/Src/Commands/BuildCommands.cs b/src/Main/Base/Project/Src/Commands/BuildCommands.cs index 5135fa9b02..0574060db7 100644 --- a/src/Main/Base/Project/Src/Commands/BuildCommands.cs +++ b/src/Main/Base/Project/Src/Commands/BuildCommands.cs @@ -336,7 +336,7 @@ namespace ICSharpCode.SharpDevelop.Project.Commands public override void Run() { using (SolutionConfigurationEditor sce = new SolutionConfigurationEditor()) { - sce.ShowDialog(); + sce.ShowDialog(WorkbenchSingleton.MainWin32Window); ProjectService.SaveSolution(); ProjectService.OpenSolution.ApplySolutionConfigurationAndPlatformToProjects(); ProjectBrowserPad.Instance.ProjectBrowserControl.RefreshView(); diff --git a/src/Main/Base/Project/Src/Commands/ChooseLayoutCommand.cs b/src/Main/Base/Project/Src/Commands/ChooseLayoutCommand.cs index 53bd42dc7e..8f4519f146 100644 --- a/src/Main/Base/Project/Src/Commands/ChooseLayoutCommand.cs +++ b/src/Main/Base/Project/Src/Commands/ChooseLayoutCommand.cs @@ -117,7 +117,7 @@ namespace ICSharpCode.SharpDevelop.Commands frm.ClientSize = new System.Drawing.Size(400, 300); frm.StartPosition = FormStartPosition.CenterParent; - if (frm.ShowDialog(WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (frm.ShowDialog(WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { IList oldNames = new List(CustomLayoutNames); IList newNames = ed.GetList(); // add newly added layouts diff --git a/src/Main/Base/Project/Src/Commands/EditCommands.cs b/src/Main/Base/Project/Src/Commands/EditCommands.cs index 8ff4b2906f..45b35ee7ee 100644 --- a/src/Main/Base/Project/Src/Commands/EditCommands.cs +++ b/src/Main/Base/Project/Src/Commands/EditCommands.cs @@ -215,8 +215,7 @@ namespace ICSharpCode.SharpDevelop.Commands public override void Run() { using (WordCountDialog wcd = new WordCountDialog()) { - wcd.Owner = WorkbenchSingleton.MainForm; - wcd.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm); + wcd.ShowDialog(WorkbenchSingleton.MainWin32Window); } } } diff --git a/src/Main/Base/Project/Src/Commands/FileCommands.cs b/src/Main/Base/Project/Src/Commands/FileCommands.cs index cdd65133a6..fee7878c82 100644 --- a/src/Main/Base/Project/Src/Commands/FileCommands.cs +++ b/src/Main/Base/Project/Src/Commands/FileCommands.cs @@ -44,8 +44,7 @@ namespace ICSharpCode.SharpDevelop.Commands } using (NewFileDialog nfd = new NewFileDialog(null)) { - nfd.Owner = WorkbenchSingleton.MainForm; - nfd.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm); + nfd.ShowDialog(WorkbenchSingleton.MainWin32Window); } } } @@ -175,7 +174,7 @@ namespace ICSharpCode.SharpDevelop.Commands } } - if (fdiag.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (fdiag.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { string fileName = fdiag.FileName; if (!FileService.CheckFileName(fileName)) { return; @@ -246,7 +245,7 @@ namespace ICSharpCode.SharpDevelop.Commands fdiag.Multiselect = true; fdiag.CheckFileExists = true; - if (fdiag.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (fdiag.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { foreach (string name in fdiag.FileNames) { FileService.OpenFile(name); } @@ -258,7 +257,8 @@ namespace ICSharpCode.SharpDevelop.Commands { public override void Run() { - WorkbenchSingleton.MainForm.Close(); + throw new NotImplementedException(); + //WorkbenchSingleton.MainForm.Close(); } } @@ -273,7 +273,7 @@ namespace ICSharpCode.SharpDevelop.Commands using (PrintDialog ppd = new PrintDialog()) { ppd.Document = pdoc; ppd.AllowSomePages = true; - if (ppd.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { // fixed by Roger Rubin + if (ppd.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { // fixed by Roger Rubin pdoc.Print(); } } @@ -297,10 +297,9 @@ namespace ICSharpCode.SharpDevelop.Commands using (PrintDocument pdoc = printable.PrintDocument) { if (pdoc != null) { PrintPreviewDialog ppd = new PrintPreviewDialog(); - ppd.Owner = WorkbenchSingleton.MainForm; ppd.TopMost = true; ppd.Document = pdoc; - ppd.Show(); + ppd.Show(WorkbenchSingleton.MainWin32Window); } else { MessageService.ShowError("${res:ICSharpCode.SharpDevelop.Commands.Print.CreatePrintDocumentError}"); } diff --git a/src/Main/Base/Project/Src/Commands/FileMenuCommands.cs b/src/Main/Base/Project/Src/Commands/FileMenuCommands.cs index be1826f3d9..02830d25ac 100644 --- a/src/Main/Base/Project/Src/Commands/FileMenuCommands.cs +++ b/src/Main/Base/Project/Src/Commands/FileMenuCommands.cs @@ -17,11 +17,8 @@ namespace ICSharpCode.SharpDevelop.Project.Commands { public override void Run() { - - using (NewProjectDialog npdlg = new NewProjectDialog(true)) { - npdlg.Owner = WorkbenchSingleton.MainForm; - npdlg.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm); + npdlg.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window); } } } @@ -35,7 +32,7 @@ namespace ICSharpCode.SharpDevelop.Project.Commands fdiag.Filter = ProjectService.GetAllProjectsFilter(this); fdiag.Multiselect = false; fdiag.CheckFileExists = true; - if (fdiag.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (fdiag.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { ProjectService.LoadSolutionOrProject(fdiag.FileName); } } diff --git a/src/Main/Base/Project/Src/Commands/HelpCommands.cs b/src/Main/Base/Project/Src/Commands/HelpCommands.cs index eda93b089f..37872d1592 100644 --- a/src/Main/Base/Project/Src/Commands/HelpCommands.cs +++ b/src/Main/Base/Project/Src/Commands/HelpCommands.cs @@ -63,8 +63,7 @@ namespace ICSharpCode.SharpDevelop.Commands public override void Run() { using (CommonAboutDialog ad = new CommonAboutDialog()) { - ad.Owner = WorkbenchSingleton.MainForm; - ad.ShowDialog(WorkbenchSingleton.MainForm); + ad.ShowDialog(WorkbenchSingleton.MainWin32Window); } } } diff --git a/src/Main/Base/Project/Src/Commands/MenuItemBuilders.cs b/src/Main/Base/Project/Src/Commands/MenuItemBuilders.cs index c2efcecd0b..645e158d05 100644 --- a/src/Main/Base/Project/Src/Commands/MenuItemBuilders.cs +++ b/src/Main/Base/Project/Src/Commands/MenuItemBuilders.cs @@ -261,7 +261,7 @@ namespace ICSharpCode.SharpDevelop.Commands box.Text = tool.MenuCommand; box.Label.Text = ResourceService.GetString("XML.MainMenu.ToolMenu.ExternalTools.EnterArguments"); box.TextBox.Text = args; - if (box.ShowDialog() != DialogResult.OK) + if (box.ShowDialog(WorkbenchSingleton.MainWin32Window) != DialogResult.OK) return; args = box.TextBox.Text; } diff --git a/src/Main/Base/Project/Src/Commands/ToolsCommands.cs b/src/Main/Base/Project/Src/Commands/ToolsCommands.cs index 9319d578c8..1bd45035f3 100644 --- a/src/Main/Base/Project/Src/Commands/ToolsCommands.cs +++ b/src/Main/Base/Project/Src/Commands/ToolsCommands.cs @@ -16,12 +16,12 @@ namespace ICSharpCode.SharpDevelop.Commands { public static void ShowTabbedOptions(string dialogTitle, AddInTreeNode node) { - TabbedOptions o = new TabbedOptions(dialogTitle, node); - o.Width = 450; - o.Height = 425; - o.FormBorderStyle = FormBorderStyle.FixedDialog; - o.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm); - o.Dispose(); + using (TabbedOptions o = new TabbedOptions(dialogTitle, node)) { + o.Width = 450; + o.Height = 425; + o.FormBorderStyle = FormBorderStyle.FixedDialog; + o.ShowDialog(WorkbenchSingleton.MainWin32Window); + } } public override void Run() @@ -29,8 +29,7 @@ namespace ICSharpCode.SharpDevelop.Commands using (TreeViewOptions optionsDialog = new TreeViewOptions(AddInTree.GetTreeNode("/SharpDevelop/Dialogs/OptionsDialog"))) { optionsDialog.FormBorderStyle = FormBorderStyle.FixedDialog; - optionsDialog.Owner = WorkbenchSingleton.MainForm; - optionsDialog.ShowDialog(WorkbenchSingleton.MainForm); + optionsDialog.ShowDialog(WorkbenchSingleton.MainWin32Window); } } } @@ -39,9 +38,8 @@ namespace ICSharpCode.SharpDevelop.Commands { public override void Run() { - ((DefaultWorkbench)WorkbenchSingleton.Workbench).FullScreen = !((DefaultWorkbench)WorkbenchSingleton.Workbench).FullScreen; + throw new NotImplementedException(); +// ((DefaultWorkbench)WorkbenchSingleton.Workbench).FullScreen = !((DefaultWorkbench)WorkbenchSingleton.Workbench).FullScreen; } } - - } diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/ExtractInterfaceDialog.cs b/src/Main/Base/Project/Src/Gui/Dialogs/ExtractInterfaceDialog.cs index bfee3263b0..9bfc8913f9 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/ExtractInterfaceDialog.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/ExtractInterfaceDialog.cs @@ -33,7 +33,6 @@ namespace ICSharpCode.SharpDevelop.Gui // InitializeComponent(); - this.Owner = WorkbenchSingleton.MainForm; this.TopMost = true; this.possibleInterfaceMembers = new List(); this.hasSetFilenameExplicitly = false; @@ -70,7 +69,7 @@ namespace ICSharpCode.SharpDevelop.Gui public ExtractInterfaceOptions ShowDialog(ExtractInterfaceOptions options) { InitializeFields(options); - options.IsCancelled = (base.ShowDialog() == DialogResult.Cancel); + options.IsCancelled = (base.ShowDialog(WorkbenchSingleton.MainWin32Window) == DialogResult.Cancel); return options; } diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/NewFileDialog.cs b/src/Main/Base/Project/Src/Gui/Dialogs/NewFileDialog.cs index 3a033bebea..ee2295ddd1 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/NewFileDialog.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/NewFileDialog.cs @@ -508,7 +508,7 @@ namespace ICSharpCode.SharpDevelop.Gui customizer.Set("Template", item.Template); customizer.Set("Creator", this); WizardDialog wizard = new WizardDialog("File Wizard", customizer, item.Template.WizardPath); - if (wizard.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (wizard.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { DialogResult = DialogResult.OK; } } else { @@ -643,7 +643,6 @@ namespace ICSharpCode.SharpDevelop.Gui tooltip.SetToolTip(ControlDictionary["largeIconsRadioButton"], StringParser.Parse("${res:Global.LargeIconToolTip}")); tooltip.SetToolTip(ControlDictionary["smallIconsRadioButton"], StringParser.Parse("${res:Global.SmallIconToolTip}")); tooltip.Active = true; - Owner = WorkbenchSingleton.MainForm; StartPosition = FormStartPosition.CenterParent; Icon = null; diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/OptionPanels/EditTemplateDialog.cs b/src/Main/Base/Project/Src/Gui/Dialogs/OptionPanels/EditTemplateDialog.cs index 9efc62846c..7c7917aae6 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/OptionPanels/EditTemplateDialog.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/OptionPanels/EditTemplateDialog.cs @@ -45,7 +45,6 @@ namespace ICSharpCode.SharpDevelop.Gui ControlDictionary["okButton"].Click += new EventHandler(AcceptEvent); - Owner = WorkbenchSingleton.MainForm; Icon = null; } } diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/OptionPanels/ExternalToolPanel.cs b/src/Main/Base/Project/Src/Gui/Dialogs/OptionPanels/ExternalToolPanel.cs index c703d1cb1a..c44087c9b5 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/OptionPanels/ExternalToolPanel.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/OptionPanels/ExternalToolPanel.cs @@ -105,7 +105,7 @@ namespace ICSharpCode.SharpDevelop.Gui.OptionPanels fdiag.CheckFileExists = true; fdiag.Filter = StringParser.Parse(ExecutableFilesFilter); - if (fdiag.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (fdiag.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { ControlDictionary["commandTextBox"].Text = fdiag.FileName; } } diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/OptionPanels/ProjectOptions/AbstractBuildOptions.cs b/src/Main/Base/Project/Src/Gui/Dialogs/OptionPanels/ProjectOptions/AbstractBuildOptions.cs index 5fef875377..dfa1574691 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/OptionPanels/ProjectOptions/AbstractBuildOptions.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/OptionPanels/ProjectOptions/AbstractBuildOptions.cs @@ -265,7 +265,7 @@ namespace ICSharpCode.SharpDevelop.Gui.OptionPanels void OnConvertProjectToMSBuild35ButtonClick(object sender, EventArgs e) { using (ConvertToMSBuild35Dialog dlg = new ConvertToMSBuild35Dialog(project.Language + " newversion")) { - if (dlg.ShowDialog() == DialogResult.OK) { + if (dlg.ShowDialog(WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { if (dlg.ConvertAllProjects) { foreach (IProject p in ProjectService.OpenSolution.Projects) { MSBuildBasedProject msbp = p as MSBuildBasedProject; diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/OptionPanels/ProjectOptions/Signing.cs b/src/Main/Base/Project/Src/Gui/Dialogs/OptionPanels/ProjectOptions/Signing.cs index 2cccaddfd5..9cb7fed80d 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/OptionPanels/ProjectOptions/Signing.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/OptionPanels/ProjectOptions/Signing.cs @@ -104,7 +104,7 @@ namespace ICSharpCode.SharpDevelop.Gui.OptionPanels if (File.Exists(CreateKeyForm.StrongNameTool)) { using (CreateKeyForm createKey = new CreateKeyForm(baseDirectory)) { createKey.KeyFile = project.Name; - if (createKey.ShowDialog(WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (createKey.ShowDialog(WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { keyFile.Text = createKey.KeyFile; return; } diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/AddWebReferenceDialog.cs b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/AddWebReferenceDialog.cs index 54dba29c28..b44d99b646 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/AddWebReferenceDialog.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/AddWebReferenceDialog.cs @@ -732,7 +732,7 @@ namespace ICSharpCode.SharpDevelop.Gui StartDiscovery(uri, credential); } else { using (UserCredentialsDialog credentialsForm = new UserCredentialsDialog(uri.ToString(), authenticationType)) { - if (DialogResult.OK == credentialsForm.ShowDialog()) { + if (DialogResult.OK == credentialsForm.ShowDialog(WorkbenchSingleton.MainWin32Window)) { StartDiscovery(uri, credentialsForm.Credential); } } diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/AssemblyReferencePanel.cs b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/AssemblyReferencePanel.cs index c65f28bf2f..929ca7f9fc 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/AssemblyReferencePanel.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/AssemblyReferencePanel.cs @@ -40,7 +40,7 @@ namespace ICSharpCode.SharpDevelop.Gui fdiag.Multiselect = true; fdiag.CheckFileExists = true; - if (fdiag.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (fdiag.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { foreach (string file in fdiag.FileNames) { ReferenceProjectItem assemblyReference = new ReferenceProjectItem(selectDialog.ConfigureProject); assemblyReference.Include = Path.GetFileNameWithoutExtension(file); diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/TabbedOptions.cs b/src/Main/Base/Project/Src/Gui/Dialogs/TabbedOptions.cs index 5cfdde0635..c82b4eb9f3 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/TabbedOptions.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/TabbedOptions.cs @@ -60,7 +60,6 @@ namespace ICSharpCode.SharpDevelop.Gui this.Text = dialogName; ControlDictionary["okButton"].Click += new EventHandler(AcceptEvent); Icon = null; - Owner = WorkbenchSingleton.MainForm; AddOptionPanels(node.BuildChildItems(this)); } diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/TreeViewOptions.cs b/src/Main/Base/Project/Src/Gui/Dialogs/TreeViewOptions.cs index 6bd604e3d4..efc8261c71 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/TreeViewOptions.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/TreeViewOptions.cs @@ -215,8 +215,6 @@ namespace ICSharpCode.SharpDevelop.Gui protected void InitializeComponent() { - Owner = WorkbenchSingleton.MainForm; - SetupFromXmlStream(this.GetType().Assembly.GetManifestResourceStream("Resources.TreeViewOptionsDialog.xfrm")); this.optionsPanelLabel = new GradientHeaderPanel(); diff --git a/src/Main/Base/Project/Src/Gui/Dialogs/WordCountDialog.cs b/src/Main/Base/Project/Src/Gui/Dialogs/WordCountDialog.cs index 5d4f63bc80..3cd509486e 100644 --- a/src/Main/Base/Project/Src/Gui/Dialogs/WordCountDialog.cs +++ b/src/Main/Base/Project/Src/Gui/Dialogs/WordCountDialog.cs @@ -231,7 +231,6 @@ namespace ICSharpCode.SharpDevelop.Gui ((ListView)ControlDictionary["resultListView"]).ColumnClick += new ColumnClickEventHandler(SortEvt); Icon = IconService.GetIcon("Icons.16x16.FindIcon"); - Owner = WorkbenchSingleton.MainForm; ((ComboBox)ControlDictionary["locationComboBox"]).Items.Add(StringParser.Parse("${res:Global.Location.currentfile}")); ((ComboBox)ControlDictionary["locationComboBox"]).Items.Add(StringParser.Parse("${res:Global.Location.allopenfiles}")); diff --git a/src/Main/Base/Project/Src/Gui/FormLocationHelper.cs b/src/Main/Base/Project/Src/Gui/FormLocationHelper.cs index 31270a351c..9e7cc41d76 100644 --- a/src/Main/Base/Project/Src/Gui/FormLocationHelper.cs +++ b/src/Main/Base/Project/Src/Gui/FormLocationHelper.cs @@ -37,7 +37,6 @@ namespace ICSharpCode.SharpDevelop.Gui } }; } - static Rectangle Validate(Rectangle bounds) { // Check if form is outside the screen and get it back if necessary. @@ -66,7 +65,10 @@ namespace ICSharpCode.SharpDevelop.Gui static Point GetDefaultLocation(Form form) { - Rectangle parent = WorkbenchSingleton.MainForm.Bounds; + var mainWindow = WorkbenchSingleton.MainWindow; + Rectangle parent = new Rectangle( + (int)mainWindow.Left, (int)mainWindow.Top, (int)mainWindow.Width, (int)mainWindow.Height + ); Size size = form.Size; return new Point(parent.Left + (parent.Width - size.Width) / 2, parent.Top + (parent.Height - size.Height) / 2); diff --git a/src/Main/Base/Project/Src/Gui/IWorkbench.cs b/src/Main/Base/Project/Src/Gui/IWorkbench.cs index 74591e08b0..0931e5677e 100644 --- a/src/Main/Base/Project/Src/Gui/IWorkbench.cs +++ b/src/Main/Base/Project/Src/Gui/IWorkbench.cs @@ -7,7 +7,10 @@ using System; using System.Collections.Generic; +using System.ComponentModel; +using System.Windows; using System.Windows.Forms; + using ICSharpCode.Core; namespace ICSharpCode.SharpDevelop.Gui @@ -18,11 +21,19 @@ namespace ICSharpCode.SharpDevelop.Gui public interface IWorkbench : IMementoCapable { /// - /// Gets the main form for the work bench. + /// The main window as IWin32Window. /// - Form MainForm { - get; - } + IWin32Window MainWin32Window { get; } + + /// + /// Object for executing methods on the main thread. + /// + ISynchronizeInvoke SynchronizingObject { get; } + + /// + /// The main window. + /// + Window MainWindow { get; } /// /// The title shown in the title bar. diff --git a/src/Main/Base/Project/Src/Gui/Pads/ProjectBrowser/Commands/DefaultFileNodeCommands.cs b/src/Main/Base/Project/Src/Gui/Pads/ProjectBrowser/Commands/DefaultFileNodeCommands.cs index 6ae73ac531..e2554a14e5 100644 --- a/src/Main/Base/Project/Src/Gui/Pads/ProjectBrowser/Commands/DefaultFileNodeCommands.cs +++ b/src/Main/Base/Project/Src/Gui/Pads/ProjectBrowser/Commands/DefaultFileNodeCommands.cs @@ -75,7 +75,7 @@ namespace ICSharpCode.SharpDevelop.Project.Commands var codons = DisplayBindingService.GetCodonsPerFileName(fileName); int defaultCodonIndex = codons.IndexOf(DisplayBindingService.GetDefaultCodonPerFileName(fileName)); using (OpenWithDialog dlg = new OpenWithDialog(codons, defaultCodonIndex, Path.GetExtension(fileName))) { - if (dlg.ShowDialog(WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (dlg.ShowDialog(WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { FileUtility.ObservedLoad(new FileService.LoadFileWrapper(dlg.SelectedBinding.Binding).Invoke, fileName); } } diff --git a/src/Main/Base/Project/Src/Gui/Pads/ProjectBrowser/Commands/FolderNodeCommands.cs b/src/Main/Base/Project/Src/Gui/Pads/ProjectBrowser/Commands/FolderNodeCommands.cs index 09c0dd1b8b..5c6b7e4957 100644 --- a/src/Main/Base/Project/Src/Gui/Pads/ProjectBrowser/Commands/FolderNodeCommands.cs +++ b/src/Main/Base/Project/Src/Gui/Pads/ProjectBrowser/Commands/FolderNodeCommands.cs @@ -183,7 +183,7 @@ namespace ICSharpCode.SharpDevelop.Project.Commands fdiag.CheckFileExists = true; fdiag.Title = StringParser.Parse("${res:ProjectComponent.ContextMenu.AddExistingFiles}"); - if (fdiag.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (fdiag.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { List> fileNames = new List>(fdiag.FileNames.Length); foreach (string fileName in fdiag.FileNames) { fileNames.Add(new KeyValuePair(fileName, "")); @@ -280,7 +280,7 @@ namespace ICSharpCode.SharpDevelop.Project.Commands node.Expanding(); using (NewFileDialog nfd = new NewFileDialog(node.Directory)) { - if (nfd.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (nfd.ShowDialog(WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { bool additionalProperties = false; foreach (KeyValuePair createdFile in nfd.CreatedFiles) { FileProjectItem item = node.AddNewFile(createdFile.Key); diff --git a/src/Main/Base/Project/Src/Gui/Pads/ProjectBrowser/Commands/ReferenceFolderNodeCommands.cs b/src/Main/Base/Project/Src/Gui/Pads/ProjectBrowser/Commands/ReferenceFolderNodeCommands.cs index fd4d8badf9..9e19cb5b11 100644 --- a/src/Main/Base/Project/Src/Gui/Pads/ProjectBrowser/Commands/ReferenceFolderNodeCommands.cs +++ b/src/Main/Base/Project/Src/Gui/Pads/ProjectBrowser/Commands/ReferenceFolderNodeCommands.cs @@ -26,7 +26,7 @@ namespace ICSharpCode.SharpDevelop.Project.Commands } LoggingService.Info("Show add reference dialog for " + project.FileName); using (SelectReferenceDialog selDialog = new SelectReferenceDialog(project)) { - if (selDialog.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (selDialog.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { foreach (ReferenceProjectItem reference in selDialog.ReferenceInformations) { ProjectService.AddProjectItem(project, reference); } @@ -90,7 +90,7 @@ namespace ICSharpCode.SharpDevelop.Project.Commands } catch (WebException ex) { if (protocol.IsAuthenticationRequired) { using (UserCredentialsDialog dialog = new UserCredentialsDialog(url, protocol.GetAuthenticationHeader().AuthenticationType)) { - if (dialog.ShowDialog() == DialogResult.OK) { + if (dialog.ShowDialog(WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { credential = dialog.Credential; } else { retry = false; @@ -113,7 +113,7 @@ namespace ICSharpCode.SharpDevelop.Project.Commands if (node != null && node.Project != null) { using (AddWebReferenceDialog refDialog = new AddWebReferenceDialog(node.Project)) { refDialog.NamespacePrefix = node.Project.RootNamespace; - if (refDialog.ShowDialog() == DialogResult.OK) { + if (refDialog.ShowDialog(WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { // Do not overwrite existing web references. refDialog.WebReference.Name = WebReference.GetReferenceName(refDialog.WebReference.WebReferencesDirectory, refDialog.WebReference.Name); refDialog.WebReference.Save(); diff --git a/src/Main/Base/Project/Src/Gui/Pads/ProjectBrowser/Commands/SolutionNodeCommands.cs b/src/Main/Base/Project/Src/Gui/Pads/ProjectBrowser/Commands/SolutionNodeCommands.cs index 0398687dc2..47507ae5be 100644 --- a/src/Main/Base/Project/Src/Gui/Pads/ProjectBrowser/Commands/SolutionNodeCommands.cs +++ b/src/Main/Base/Project/Src/Gui/Pads/ProjectBrowser/Commands/SolutionNodeCommands.cs @@ -25,7 +25,7 @@ namespace ICSharpCode.SharpDevelop.Project.Commands npdlg.InitialProjectLocationDirectory = GetInitialDirectorySuggestion(solutionFolderNode); // show the dialog to request project type and name - if (npdlg.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (npdlg.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { if (npdlg.NewProjectLocation.Length == 0) { MessageService.ShowError("No project has been created, there is nothing to add."); return; @@ -92,7 +92,7 @@ namespace ICSharpCode.SharpDevelop.Project.Commands fdiag.Multiselect = true; fdiag.CheckFileExists = true; fdiag.InitialDirectory = AddNewProjectToSolution.GetInitialDirectorySuggestion(solutionFolderNode); - if (fdiag.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (fdiag.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { foreach (string fileName in fdiag.FileNames) { AddProject(solutionFolderNode, fileName); } @@ -115,7 +115,7 @@ namespace ICSharpCode.SharpDevelop.Project.Commands fdiag.Filter = StringParser.Parse("${res:SharpDevelop.FileFilter.AllFiles}|*.*"); fdiag.Multiselect = true; fdiag.CheckFileExists = true; - if (fdiag.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (fdiag.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { foreach (string fileName in fdiag.FileNames) { solutionFolderNode.AddItem(fileName); } diff --git a/src/Main/Base/Project/Src/Gui/Workbench/Layouts/AvalonDockLayout.cs b/src/Main/Base/Project/Src/Gui/Workbench/Layouts/AvalonDockLayout.cs new file mode 100644 index 0000000000..144a4fbd87 --- /dev/null +++ b/src/Main/Base/Project/Src/Gui/Workbench/Layouts/AvalonDockLayout.cs @@ -0,0 +1,91 @@ +// +// +// +// +// $Revision$ +// + +using System; + +namespace ICSharpCode.SharpDevelop.Gui +{ + /// + /// Description of AvalonDockLayout. + /// + public class AvalonDockLayout : IWorkbenchLayout + { + public event EventHandler ActiveWorkbenchWindowChanged; + + public IWorkbenchWindow ActiveWorkbenchWindow { + get { + throw new NotImplementedException(); + } + } + + public object ActiveContent { + get { + throw new NotImplementedException(); + } + } + + public void Attach(IWorkbench workbench) + { + throw new NotImplementedException(); + } + + public void Detach() + { + throw new NotImplementedException(); + } + + public void ShowPad(PadDescriptor content) + { + throw new NotImplementedException(); + } + + public void ActivatePad(PadDescriptor content) + { + throw new NotImplementedException(); + } + + public void ActivatePad(string fullyQualifiedTypeName) + { + throw new NotImplementedException(); + } + + public void HidePad(PadDescriptor content) + { + throw new NotImplementedException(); + } + + public void UnloadPad(PadDescriptor content) + { + throw new NotImplementedException(); + } + + public bool IsVisible(PadDescriptor padContent) + { + throw new NotImplementedException(); + } + + public void RedrawAllComponents() + { + throw new NotImplementedException(); + } + + public IWorkbenchWindow ShowView(IViewContent content) + { + throw new NotImplementedException(); + } + + public void LoadConfiguration() + { + throw new NotImplementedException(); + } + + public void StoreConfiguration() + { + throw new NotImplementedException(); + } + } +} diff --git a/src/Main/Base/Project/Src/Gui/Workbench/SingleInstanceHelper.cs b/src/Main/Base/Project/Src/Gui/Workbench/SingleInstanceHelper.cs index b2f248799f..410e89a708 100644 --- a/src/Main/Base/Project/Src/Gui/Workbench/SingleInstanceHelper.cs +++ b/src/Main/Base/Project/Src/Gui/Workbench/SingleInstanceHelper.cs @@ -72,7 +72,7 @@ namespace ICSharpCode.SharpDevelop.Gui m.Result = new IntPtr(RESULT_FILES_HANDLED); try { WorkbenchSingleton.SafeThreadAsyncCall( - delegate { NativeMethods.SetForegroundWindow(WorkbenchSingleton.MainForm.Handle) ; } + delegate { NativeMethods.SetForegroundWindow(WorkbenchSingleton.MainWin32Window.Handle) ; } ); string tempFileName = Path.Combine(Path.GetTempPath(), "sd" + fileNumber + ".tmp"); foreach (string file in File.ReadAllLines(tempFileName)) { diff --git a/src/Main/Base/Project/Src/Gui/Workbench/WpfWorkbench.cs b/src/Main/Base/Project/Src/Gui/Workbench/WpfWorkbench.cs new file mode 100644 index 0000000000..9415494e86 --- /dev/null +++ b/src/Main/Base/Project/Src/Gui/Workbench/WpfWorkbench.cs @@ -0,0 +1,142 @@ +// +// +// +// +// $Revision$ +// + +using System; +using System.Collections.Generic; +using System.Windows; +using ICSharpCode.Core; +using System.ComponentModel; + +namespace ICSharpCode.SharpDevelop.Gui +{ + /// + /// Workbench implementation using WPF and AvalonDock. + /// + sealed class WpfWorkbench : Window, IWorkbench + { + public event EventHandler ActiveWorkbenchWindowChanged; + public event EventHandler ActiveViewContentChanged; + public event EventHandler ActiveContentChanged; + public event ViewContentEventHandler ViewOpened; + public event ViewContentEventHandler ViewClosed; + public event System.Windows.Forms.KeyEventHandler ProcessCommandKey; + + public System.Windows.Forms.IWin32Window MainWin32Window { get; private set; } + public ISynchronizeInvoke SynchronizingObject { get; set; } + public Window MainWindow { get { return this; } } + + public WpfWorkbench() + { + this.SynchronizingObject = new WpfSynchronizeInvoke(this.Dispatcher); + this.MainWin32Window = this.GetWin32Window(); + this.WindowStartupLocation = WindowStartupLocation.Manual; + } + + public ICollection ViewContentCollection { + get { + return new IViewContent[0]; + } + } + + public IList WorkbenchWindowCollection { + get { + return new IWorkbenchWindow[0]; + } + } + + public IList PadContentCollection { + get { + return new PadDescriptor[0]; + } + } + + public IWorkbenchWindow ActiveWorkbenchWindow { + get { + return null; + } + } + + public IViewContent ActiveViewContent { + get { + return null; + } + } + + public object ActiveContent { + get { + return null; + } + } + + public IWorkbenchLayout WorkbenchLayout { get; set; } + + public bool IsActiveWindow { + get { + return IsActive; + } + } + + public void Initialize() + { + } + + public void ShowView(IViewContent content) + { + } + + public void ShowPad(PadDescriptor content) + { + } + + public void UnloadPad(PadDescriptor content) + { + } + + public PadDescriptor GetPad(Type type) + { + return null; + } + + public void CloseContent(IViewContent content) + { + } + + public void CloseAllViews() + { + } + + public void RedrawAllComponents() + { + } + + public void UpdateRenderer() + { + } + + public Properties CreateMemento() + { + Properties prop = new Properties(); + prop.Set("WindowState", this.WindowState); + if (this.WindowState == System.Windows.WindowState.Normal) { + prop.Set("Left", this.Left); + prop.Set("Top", this.Top); + prop.Set("Width", this.Width); + prop.Set("Height", this.Height); + } + return prop; + } + + public void SetMemento(Properties memento) + { + this.Left = memento.Get("Left", 10.0); + this.Top = memento.Get("Top", 10.0); + this.Width = memento.Get("Width", 600.0); + this.Height = memento.Get("Height", 400.0); + this.WindowState = memento.Get("WindowState", System.Windows.WindowState.Maximized); + } + } +} diff --git a/src/Main/Base/Project/Src/Gui/WorkbenchSingleton.cs b/src/Main/Base/Project/Src/Gui/WorkbenchSingleton.cs index 686cc7d97d..bbc0be7660 100644 --- a/src/Main/Base/Project/Src/Gui/WorkbenchSingleton.cs +++ b/src/Main/Base/Project/Src/Gui/WorkbenchSingleton.cs @@ -7,6 +7,7 @@ using System; using System.Diagnostics; +using System.Windows; using System.Windows.Forms; using ICSharpCode.Core; @@ -20,16 +21,27 @@ namespace ICSharpCode.SharpDevelop.Gui const string uiLanguageProperty = "CoreProperties.UILanguage"; const string workbenchMemento = "WorkbenchMemento"; - static STAThreadCaller caller; static IWorkbench workbench; /// /// Gets the main form. Returns null in unit-testing mode. /// - public static Form MainForm { + public static IWin32Window MainWin32Window { get { if (workbench != null) { - return workbench.MainForm; + return workbench.MainWin32Window; + } + return null; + } + } + + /// + /// Gets the main window. Returns null in unit-testing mode. + /// + public static Window MainWindow { + get { + if (workbench != null) { + return workbench.MainWindow; } return null; } @@ -46,6 +58,8 @@ namespace ICSharpCode.SharpDevelop.Gui public static Control ActiveControl { get { + return null; + /* ContainerControl container = WorkbenchSingleton.MainForm; Control ctl; do { @@ -54,7 +68,7 @@ namespace ICSharpCode.SharpDevelop.Gui return container; container = ctl as ContainerControl; } while(container != null); - return ctl; + return ctl;*/ } } @@ -83,10 +97,11 @@ namespace ICSharpCode.SharpDevelop.Gui /// public static void InitializeWorkbench() { - if (Environment.OSVersion.Platform == PlatformID.Unix) - InitializeWorkbench(new DefaultWorkbench(), new SimpleWorkbenchLayout()); - else - InitializeWorkbench(new DefaultWorkbench(), new SdiWorkbenchLayout()); +// if (Environment.OSVersion.Platform == PlatformID.Unix) +// InitializeWorkbench(new DefaultWorkbench(), new SimpleWorkbenchLayout()); +// else +// InitializeWorkbench(new DefaultWorkbench(), new SdiWorkbenchLayout()); + InitializeWorkbench(new WpfWorkbench(), new AvalonDockLayout()); } public static void InitializeWorkbench(IWorkbench workbench, IWorkbenchLayout layout) @@ -103,14 +118,12 @@ namespace ICSharpCode.SharpDevelop.Gui Project.CustomToolsService.Initialize(); Project.BuildModifiedProjectsOnlyService.Initialize(); - WinFormsMessageService.DialogOwner = workbench.MainForm; - WinFormsMessageService.DialogSynchronizeInvoke = workbench.MainForm; + WinFormsMessageService.DialogOwner = workbench.MainWin32Window; + WinFormsMessageService.DialogSynchronizeInvoke = workbench.SynchronizingObject; PropertyService.PropertyChanged += new PropertyChangedEventHandler(TrackPropertyChanges); ResourceService.LanguageChanged += delegate { workbench.RedrawAllComponents(); }; - caller = new STAThreadCaller(workbench.MainForm); - workbench.Initialize(); workbench.SetMemento(PropertyService.Get(workbenchMemento, new Properties())); workbench.WorkbenchLayout = layout; @@ -149,47 +162,12 @@ namespace ICSharpCode.SharpDevelop.Gui } #region Safe Thread Caller - /// - /// Helper class for invoking methods on the main thread. - /// - private sealed class STAThreadCaller - { - Control ctl; - - public STAThreadCaller(Control ctl) - { - if (ctl == null) - throw new ArgumentNullException("ctl"); - this.ctl = ctl; - } - - public object Call(Delegate method, object[] arguments) - { - if (method == null) { - throw new ArgumentNullException("method"); - } - return ctl.Invoke(method, arguments); - } - - public void BeginCall(Delegate method, object[] arguments) - { - if (method == null) { - throw new ArgumentNullException("method"); - } - try { - ctl.BeginInvoke(method, arguments); - } catch (InvalidOperationException ex) { - LoggingService.Warn("Error in SafeThreadAsyncCall", ex); - } - } - } - public static bool InvokeRequired { get { if (workbench == null) return false; // unit test mode, don't crash else - return workbench.MainForm.InvokeRequired; + return workbench.SynchronizingObject.InvokeRequired; } } @@ -222,7 +200,7 @@ namespace ICSharpCode.SharpDevelop.Gui /// public static R SafeThreadFunction(Func method) { - return (R)caller.Call(method, emptyObjectArray); + return (R)workbench.SynchronizingObject.Invoke(method, emptyObjectArray); } /// @@ -232,7 +210,7 @@ namespace ICSharpCode.SharpDevelop.Gui /// public static R SafeThreadFunction(Func method, A arg1) { - return (R)caller.Call(method, new object[] { arg1 }); + return (R)workbench.SynchronizingObject.Invoke(method, new object[] { arg1 }); } /// @@ -242,7 +220,7 @@ namespace ICSharpCode.SharpDevelop.Gui /// public static void SafeThreadCall(Action method) { - caller.Call(method, emptyObjectArray); + workbench.SynchronizingObject.Invoke(method, emptyObjectArray); } /// @@ -252,7 +230,7 @@ namespace ICSharpCode.SharpDevelop.Gui /// public static void SafeThreadCall(Action method, A arg1) { - caller.Call(method, new object[] { arg1 }); + workbench.SynchronizingObject.Invoke(method, new object[] { arg1 }); } /// @@ -262,7 +240,7 @@ namespace ICSharpCode.SharpDevelop.Gui /// public static void SafeThreadCall(Action method, A arg1, B arg2) { - caller.Call(method, new object[] { arg1, arg2 }); + workbench.SynchronizingObject.Invoke(method, new object[] { arg1, arg2 }); } /// @@ -272,7 +250,7 @@ namespace ICSharpCode.SharpDevelop.Gui /// public static void SafeThreadCall(Action method, A arg1, B arg2, C arg3) { - caller.Call(method, new object[] { arg1, arg2, arg3 }); + workbench.SynchronizingObject.Invoke(method, new object[] { arg1, arg2, arg3 }); } /// @@ -280,7 +258,7 @@ namespace ICSharpCode.SharpDevelop.Gui /// public static void SafeThreadAsyncCall(Action method) { - caller.BeginCall(method, new object[0]); + workbench.SynchronizingObject.BeginInvoke(method, emptyObjectArray); } /// @@ -288,7 +266,7 @@ namespace ICSharpCode.SharpDevelop.Gui /// public static void SafeThreadAsyncCall(Action method, A arg1) { - caller.BeginCall(method, new object[] { arg1 }); + workbench.SynchronizingObject.BeginInvoke(method, new object[] { arg1 }); } /// @@ -296,7 +274,7 @@ namespace ICSharpCode.SharpDevelop.Gui /// public static void SafeThreadAsyncCall(Action method, A arg1, B arg2) { - caller.BeginCall(method, new object[] { arg1, arg2 }); + workbench.SynchronizingObject.BeginInvoke(method, new object[] { arg1, arg2 }); } /// @@ -304,7 +282,7 @@ namespace ICSharpCode.SharpDevelop.Gui /// public static void SafeThreadAsyncCall(Action method, A arg1, B arg2, C arg3) { - caller.BeginCall(method, new object[] { arg1, arg2, arg3 }); + workbench.SynchronizingObject.BeginInvoke(method, new object[] { arg1, arg2, arg3 }); } #endregion diff --git a/src/Main/Base/Project/Src/Internal/Templates/Project/ProjectTemplate.cs b/src/Main/Base/Project/Src/Internal/Templates/Project/ProjectTemplate.cs index faf60ec663..929501098a 100644 --- a/src/Main/Base/Project/Src/Internal/Templates/Project/ProjectTemplate.cs +++ b/src/Main/Base/Project/Src/Internal/Templates/Project/ProjectTemplate.cs @@ -376,7 +376,7 @@ namespace ICSharpCode.SharpDevelop.Internal.Templates customizer.Set("ProjectCreateInformation", projectCreateInformation); customizer.Set("ProjectTemplate", this); WizardDialog wizard = new WizardDialog("Project Wizard", customizer, wizardpath); - if (wizard.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) != DialogResult.OK) { + if (wizard.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) != DialogResult.OK) { return null; } } diff --git a/src/Main/Base/Project/Src/Project/BuildEngine.cs b/src/Main/Base/Project/Src/Project/BuildEngine.cs index 1300390cd3..6788de8acc 100644 --- a/src/Main/Base/Project/Src/Project/BuildEngine.cs +++ b/src/Main/Base/Project/Src/Project/BuildEngine.cs @@ -524,7 +524,7 @@ namespace ICSharpCode.SharpDevelop.Project combinedBuildFeedbackSink.Done(results.Result == BuildResultCode.Success); } if (options.Callback != null) { - Gui.WorkbenchSingleton.MainForm.BeginInvoke(options.Callback, results); + Gui.WorkbenchSingleton.SafeThreadAsyncCall(delegate { options.Callback(results); }); } } #endregion diff --git a/src/Main/Base/Project/Src/Services/AmbienceService/AmbienceService.cs b/src/Main/Base/Project/Src/Services/AmbienceService/AmbienceService.cs index 736f3b930c..f3362bb3f7 100644 --- a/src/Main/Base/Project/Src/Services/AmbienceService/AmbienceService.cs +++ b/src/Main/Base/Project/Src/Services/AmbienceService/AmbienceService.cs @@ -101,7 +101,7 @@ namespace ICSharpCode.SharpDevelop } catch (TreePathNotFoundException) { ambience = null; } - if (ambience == null && Gui.WorkbenchSingleton.MainForm != null) { + if (ambience == null && Gui.WorkbenchSingleton.MainWin32Window != null) { MessageService.ShowError("${res:ICSharpCode.SharpDevelop.Services.AmbienceService.AmbienceNotFoundError}"); } defaultAmbience = ambience ?? new NetAmbience(); diff --git a/src/Main/Base/Project/Src/Services/Debugger/DebuggerGridControl.cs b/src/Main/Base/Project/Src/Services/Debugger/DebuggerGridControl.cs index b421656b6b..07316f8436 100644 --- a/src/Main/Base/Project/Src/Services/Debugger/DebuggerGridControl.cs +++ b/src/Main/Base/Project/Src/Services/Debugger/DebuggerGridControl.cs @@ -78,9 +78,10 @@ namespace ICSharpCode.SharpDevelop.Debugging return true; } else { Console.WriteLine("Handling " + keyData); - var i = FindItemByShortcut(Gui.WorkbenchSingleton.MainForm.MainMenuStrip.Items, keyData); - if (i != null) - i.PerformClick(); + throw new NotImplementedException(); + //var i = FindItemByShortcut(Gui.WorkbenchSingleton.MainWin32Window.MainMenuStrip.Items, keyData); + //if (i != null) + // i.PerformClick(); return false; } } diff --git a/src/Main/Base/Project/Src/Services/File/FileChangeWatcher.cs b/src/Main/Base/Project/Src/Services/File/FileChangeWatcher.cs index e8ecd1ea45..d0e590bcf7 100644 --- a/src/Main/Base/Project/Src/Services/File/FileChangeWatcher.cs +++ b/src/Main/Base/Project/Src/Services/File/FileChangeWatcher.cs @@ -50,7 +50,8 @@ namespace ICSharpCode.SharpDevelop if (file == null) throw new ArgumentNullException("file"); this.file = file; - WorkbenchSingleton.MainForm.Activated += MainForm_Activated; + throw new NotImplementedException(); + //WorkbenchSingleton.MainWin32Window.Activated += MainForm_Activated; file.FileNameChanged += file_FileNameChanged; activeWatchers.Add(this); SetWatcher(); @@ -66,7 +67,8 @@ namespace ICSharpCode.SharpDevelop WorkbenchSingleton.AssertMainThread(); activeWatchers.Remove(this); if (file != null) { - WorkbenchSingleton.MainForm.Activated -= MainForm_Activated; + throw new NotImplementedException(); + //WorkbenchSingleton.MainWin32Window.Activated -= MainForm_Activated; file.FileNameChanged -= file_FileNameChanged; file = null; } @@ -80,8 +82,8 @@ namespace ICSharpCode.SharpDevelop public bool Enabled { get { return enabled; } - set { - enabled = value; + set { + enabled = value; SetWatcher(); } } @@ -110,7 +112,8 @@ namespace ICSharpCode.SharpDevelop try { if (watcher == null) { watcher = new FileSystemWatcher(); - watcher.SynchronizingObject = WorkbenchSingleton.MainForm; + if (WorkbenchSingleton.Workbench != null) + watcher.SynchronizingObject = WorkbenchSingleton.Workbench.SynchronizingObject; watcher.Changed += new FileSystemEventHandler(this.OnFileChangedEvent); } watcher.Path = Path.GetDirectoryName(fileName); diff --git a/src/Main/Base/Project/Src/TextEditor/Bookmarks/Pad/BookmarkPadToolbarCommands.cs b/src/Main/Base/Project/Src/TextEditor/Bookmarks/Pad/BookmarkPadToolbarCommands.cs index 67b8c9c99c..5a0649ddf9 100644 --- a/src/Main/Base/Project/Src/TextEditor/Bookmarks/Pad/BookmarkPadToolbarCommands.cs +++ b/src/Main/Base/Project/Src/TextEditor/Bookmarks/Pad/BookmarkPadToolbarCommands.cs @@ -42,7 +42,6 @@ namespace ICSharpCode.SharpDevelop.Bookmarks } else { ICSharpCode.SharpDevelop.Bookmarks.BookmarkManager.RemoveMark(node.Bookmark); } - WorkbenchSingleton.MainForm.Refresh(); } } } diff --git a/src/Main/Base/Project/Src/TextEditor/Commands/FormatCommands.cs b/src/Main/Base/Project/Src/TextEditor/Commands/FormatCommands.cs index 5844419a80..c561e14fbd 100644 --- a/src/Main/Base/Project/Src/TextEditor/Commands/FormatCommands.cs +++ b/src/Main/Base/Project/Src/TextEditor/Commands/FormatCommands.cs @@ -232,8 +232,7 @@ namespace ICSharpCode.SharpDevelop.DefaultEditor.Commands } using (SortOptionsDialog sortOptionsDialog = new SortOptionsDialog()) { - sortOptionsDialog.Owner = WorkbenchSingleton.MainForm; - if (sortOptionsDialog.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (sortOptionsDialog.ShowDialog(WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { TextArea textarea = ((ITextEditorControlProvider)viewContent).TextEditorControl.ActiveTextAreaControl.TextArea; textarea.BeginUpdate(); if (textarea.SelectionManager.HasSomethingSelected) { diff --git a/src/Main/Base/Project/Src/TextEditor/Commands/GenerateCodeCommand.cs b/src/Main/Base/Project/Src/TextEditor/Commands/GenerateCodeCommand.cs index f2be4b853c..572b6a03c7 100644 --- a/src/Main/Base/Project/Src/TextEditor/Commands/GenerateCodeCommand.cs +++ b/src/Main/Base/Project/Src/TextEditor/Commands/GenerateCodeCommand.cs @@ -50,7 +50,7 @@ namespace ICSharpCode.SharpDevelop.DefaultEditor.Commands if (currentClass != null) { var generators = AddInTree.BuildItems("/AddIns/DefaultTextEditor/CodeGenerator", this, true); using (CodeGenerationForm form = new CodeGenerationForm(textEditorControl, generators.ToArray(), currentClass)) { - form.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm); + form.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window); } } } diff --git a/src/Main/Base/Project/Src/TextEditor/Commands/ToolCommands.cs b/src/Main/Base/Project/Src/TextEditor/Commands/ToolCommands.cs index 37eaf7cbb3..b834708eae 100644 --- a/src/Main/Base/Project/Src/TextEditor/Commands/ToolCommands.cs +++ b/src/Main/Base/Project/Src/TextEditor/Commands/ToolCommands.cs @@ -33,7 +33,7 @@ namespace ICSharpCode.SharpDevelop.DefaultEditor.Commands TextEditorControl textarea = ((ITextEditorControlProvider)viewContent).TextEditorControl; using (SharpDevelopColorDialog cd = new SharpDevelopColorDialog()) { - if (cd.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (cd.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { string ext = Path.GetExtension(textarea.FileName).ToLowerInvariant(); string colorstr; if (ext == ".cs" || ext == ".vb" || ext == ".boo") { diff --git a/src/Main/Base/Project/Src/TextEditor/Gui/Dialogs/GotoDialog.cs b/src/Main/Base/Project/Src/TextEditor/Gui/Dialogs/GotoDialog.cs index d1639fcdbb..ab104bc16f 100644 --- a/src/Main/Base/Project/Src/TextEditor/Gui/Dialogs/GotoDialog.cs +++ b/src/Main/Base/Project/Src/TextEditor/Gui/Dialogs/GotoDialog.cs @@ -30,7 +30,7 @@ namespace ICSharpCode.SharpDevelop.Gui { if (Instance == null) { Instance = new GotoDialog(); - Instance.Show(WorkbenchSingleton.MainForm); + Instance.Show(WorkbenchSingleton.MainWin32Window); } else { Instance.Focus(); } @@ -54,7 +54,6 @@ namespace ICSharpCode.SharpDevelop.Gui listView.SizeChanged += ListViewSizeChanged; listView.HideSelection = false; ListViewSizeChanged(null, null); - Owner = WorkbenchSingleton.MainForm; Icon = null; FormLocationHelper.Apply(this, "ICSharpCode.SharpDevelop.Gui.GotoDialog.Bounds", true); } diff --git a/src/Main/Base/Project/Src/TextEditor/Gui/Editor/SharpDevelopTextAreaControl.cs b/src/Main/Base/Project/Src/TextEditor/Gui/Editor/SharpDevelopTextAreaControl.cs index bd077f3fe8..fa3af66a9c 100644 --- a/src/Main/Base/Project/Src/TextEditor/Gui/Editor/SharpDevelopTextAreaControl.cs +++ b/src/Main/Base/Project/Src/TextEditor/Gui/Editor/SharpDevelopTextAreaControl.cs @@ -358,7 +358,7 @@ namespace ICSharpCode.SharpDevelop.DefaultEditor.Gui.Editor public void ShowInsightWindow(IInsightDataProvider insightDataProvider) { if (insightWindow == null || insightWindow.IsDisposed) { - insightWindow = new InsightWindow(WorkbenchSingleton.MainForm, this); + insightWindow = new InsightWindow(WorkbenchSingleton.MainWin32Window, this); insightWindow.Closed += new EventHandler(CloseInsightWindow); } insightWindow.AddInsightDataProvider(insightDataProvider, this.FileName); @@ -373,7 +373,7 @@ namespace ICSharpCode.SharpDevelop.DefaultEditor.Gui.Editor public void ShowCompletionWindow(ICompletionDataProvider completionDataProvider, char ch) { - codeCompletionWindow = CodeCompletionWindow.ShowCompletionWindow(WorkbenchSingleton.MainForm, this, this.FileName, completionDataProvider, ch); + codeCompletionWindow = CodeCompletionWindow.ShowCompletionWindow(WorkbenchSingleton.MainWin32Window, this, this.FileName, completionDataProvider, ch); if (codeCompletionWindow != null) { codeCompletionWindow.Closed += new EventHandler(CloseCodeCompletionWindow); } diff --git a/src/Main/Base/Project/Src/TextEditor/Gui/OptionPanels/CodeTemplatePanel.cs b/src/Main/Base/Project/Src/TextEditor/Gui/OptionPanels/CodeTemplatePanel.cs index fef7e84cea..1bd188e4c4 100644 --- a/src/Main/Base/Project/Src/TextEditor/Gui/OptionPanels/CodeTemplatePanel.cs +++ b/src/Main/Base/Project/Src/TextEditor/Gui/OptionPanels/CodeTemplatePanel.cs @@ -147,7 +147,7 @@ namespace ICSharpCode.SharpDevelop.Gui.OptionPanels { CodeTemplate newTemplate = new CodeTemplate(); using (EditTemplateDialog etd = new EditTemplateDialog(newTemplate)) { - if (etd.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (etd.ShowDialog(WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { CurrentTemplateGroup.Templates.Add(newTemplate); ((ListView)ControlDictionary["templateListView"]).SelectedItems.Clear(); BuildListView(); @@ -165,7 +165,7 @@ namespace ICSharpCode.SharpDevelop.Gui.OptionPanels template = new CodeTemplate(template.Shortcut, template.Description, template.Text); using (EditTemplateDialog etd = new EditTemplateDialog(template)) { - if (etd.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm) == DialogResult.OK) { + if (etd.ShowDialog(WorkbenchSingleton.MainWin32Window) == DialogResult.OK) { item.Tag = template; StoreTemplateGroup(); } diff --git a/src/Main/Base/Project/Src/Util/ExtensionMethods.cs b/src/Main/Base/Project/Src/Util/ExtensionMethods.cs index d120c8f547..ac17b0c14b 100644 --- a/src/Main/Base/Project/Src/Util/ExtensionMethods.cs +++ b/src/Main/Base/Project/Src/Util/ExtensionMethods.cs @@ -59,5 +59,57 @@ namespace ICSharpCode.SharpDevelop } } } + + /// + /// Creates an array containing a part of the array (similar to string.Substring). + /// + public static T[] Splice(this T[] array, int startIndex) + { + if (array == null) + throw new ArgumentNullException("array"); + return Splice(array, startIndex, array.Length - startIndex); + } + + /// + /// Creates an array containing a part of the array (similar to string.Substring). + /// + public static T[] Splice(this T[] array, int startIndex, int length) + { + if (array == null) + throw new ArgumentNullException("array"); + if (startIndex < 0 || startIndex > array.Length) + throw new ArgumentOutOfRangeException("startIndex", startIndex, "Value must be between 0 and " + array.Length); + if (length < 0 || length > array.Length - startIndex) + throw new ArgumentOutOfRangeException("length", length, "Value must be between 0 and " + (array.Length - startIndex)); + T[] result = new T[length]; + Array.Copy(array, startIndex, result, 0, length); + return result; + } + + /// + /// Gets the IWin32Window associated with a WPF window. + /// + public static System.Windows.Forms.IWin32Window GetWin32Window(this System.Windows.Window window) + { + var wnd = System.Windows.PresentationSource.FromVisual(window) as System.Windows.Interop.IWin32Window; + if (wnd != null) + return new Win32WindowAdapter(wnd); + else + return null; + } + + sealed class Win32WindowAdapter : System.Windows.Forms.IWin32Window + { + System.Windows.Interop.IWin32Window window; + + public Win32WindowAdapter(System.Windows.Interop.IWin32Window window) + { + this.window = window; + } + + public IntPtr Handle { + get { return window.Handle; } + } + } } } diff --git a/src/Main/Base/Project/Src/Util/NativeMethods.cs b/src/Main/Base/Project/Src/Util/NativeMethods.cs index dd9dc4fb2d..aaa258d4cf 100644 --- a/src/Main/Base/Project/Src/Util/NativeMethods.cs +++ b/src/Main/Base/Project/Src/Util/NativeMethods.cs @@ -99,7 +99,7 @@ namespace ICSharpCode.SharpDevelop if (!File.Exists(fileName) && !Directory.Exists(fileName)) throw new FileNotFoundException("File not found.", fileName); SHFILEOPSTRUCT info = new SHFILEOPSTRUCT(); - info.hwnd = Gui.WorkbenchSingleton.MainForm.Handle; + info.hwnd = Gui.WorkbenchSingleton.MainWin32Window.Handle; info.wFunc = FO_FUNC.FO_DELETE; info.fFlags = FILEOP_FLAGS.FOF_ALLOWUNDO | FILEOP_FLAGS.FOF_NOCONFIRMATION; info.lpszProgressTitle = "Delete " + Path.GetFileName(fileName); diff --git a/src/Main/Base/Project/Src/Util/WpfSynchronizeInvoke.cs b/src/Main/Base/Project/Src/Util/WpfSynchronizeInvoke.cs new file mode 100644 index 0000000000..a02358f82d --- /dev/null +++ b/src/Main/Base/Project/Src/Util/WpfSynchronizeInvoke.cs @@ -0,0 +1,113 @@ +// +// +// +// +// $Revision$ +// + +using System; +using System.ComponentModel; +using System.Threading; +using System.Windows.Threading; + +namespace ICSharpCode.SharpDevelop +{ + /// + /// Description of WpfSynchronizeInvoke. + /// + sealed class WpfSynchronizeInvoke : ISynchronizeInvoke + { + readonly Dispatcher dispatcher; + + public WpfSynchronizeInvoke(Dispatcher dispatcher) + { + if (dispatcher == null) + throw new ArgumentNullException("dispatcher"); + this.dispatcher = dispatcher; + } + + public bool InvokeRequired { + get { + return !dispatcher.CheckAccess(); + } + } + + public IAsyncResult BeginInvoke(Delegate method, object[] args) + { + DispatcherOperation op; + if (args.Length == 0) + op = dispatcher.BeginInvoke(DispatcherPriority.Normal, method); + else if (args.Length == 1) + op = dispatcher.BeginInvoke(DispatcherPriority.Normal, method, args[0]); + else + op = dispatcher.BeginInvoke(DispatcherPriority.Normal, method, args[0], args.Splice(1)); + return new AsyncResult(op); + } + + sealed class AsyncResult : IAsyncResult + { + internal readonly DispatcherOperation op; + readonly object lockObj = new object(); + ManualResetEvent resetEvent; + + public AsyncResult(DispatcherOperation op) + { + this.op = op; + } + + public bool IsCompleted { + get { + return op.Status == DispatcherOperationStatus.Completed; + } + } + + public WaitHandle AsyncWaitHandle { + get { + lock (lockObj) { + if (resetEvent == null) { + op.Completed += op_Completed; + resetEvent = new ManualResetEvent(false); + if (IsCompleted) + resetEvent.Set(); + } + return resetEvent; + } + } + } + + void op_Completed(object sender, EventArgs e) + { + lock (lockObj) { + resetEvent.Set(); + } + } + + public object AsyncState { + get { return null; } + } + + public bool CompletedSynchronously { + get { return false; } + } + } + + public object EndInvoke(IAsyncResult result) + { + AsyncResult r = result as AsyncResult; + if (r == null) + throw new ArgumentException("result must be the return value of a WpfSynchronizeInvoke.BeginInvoke call!"); + r.op.Wait(); + return r.op.Result; + } + + public object Invoke(Delegate method, object[] args) + { + if (args.Length == 0) + return dispatcher.Invoke(DispatcherPriority.Normal, method); + else if (args.Length == 1) + return dispatcher.Invoke(DispatcherPriority.Normal, method, args[0]); + else + return dispatcher.Invoke(DispatcherPriority.Normal, method, args[0], args.Splice(1)); + } + } +} diff --git a/src/Main/ICSharpCode.SharpDevelop.Sda/ICSharpCode.SharpDevelop.Sda.csproj b/src/Main/ICSharpCode.SharpDevelop.Sda/ICSharpCode.SharpDevelop.Sda.csproj index 6cd3efc476..4b6d7a2712 100644 --- a/src/Main/ICSharpCode.SharpDevelop.Sda/ICSharpCode.SharpDevelop.Sda.csproj +++ b/src/Main/ICSharpCode.SharpDevelop.Sda/ICSharpCode.SharpDevelop.Sda.csproj @@ -49,11 +49,20 @@ ..\..\Libraries\log4net\log4net.dll + + 3.0 + + + 3.0 + + + 3.0 + diff --git a/src/Main/ICSharpCode.SharpDevelop.Sda/Src/CallHelper.cs b/src/Main/ICSharpCode.SharpDevelop.Sda/Src/CallHelper.cs index 0f629a1e56..154c6f18ef 100644 --- a/src/Main/ICSharpCode.SharpDevelop.Sda/Src/CallHelper.cs +++ b/src/Main/ICSharpCode.SharpDevelop.Sda/Src/CallHelper.cs @@ -19,6 +19,7 @@ using ICSharpCode.Core; using ICSharpCode.Core.WinForms; using ICSharpCode.SharpDevelop.Commands; using ICSharpCode.SharpDevelop.Gui; +using System.Windows; namespace ICSharpCode.SharpDevelop.Sda { @@ -233,8 +234,8 @@ namespace ICSharpCode.SharpDevelop.Sda vc.WorkbenchWindow.CloseWindow(true); } } - WorkbenchSingleton.MainForm.Close(); - return WorkbenchSingleton.MainForm.IsDisposed; + WorkbenchSingleton.MainWindow.Close(); + return WorkbenchSingleton.MainWindow == null; } [SuppressMessage("Microsoft.Performance", "CA1822:MarkMembersAsStatic")] @@ -261,11 +262,11 @@ namespace ICSharpCode.SharpDevelop.Sda } bool GetWorkbenchVisibleInternal() { - return WorkbenchSingleton.MainForm.Visible; + return WorkbenchSingleton.MainWindow.Visibility == Visibility.Visible; } void SetWorkbenchVisibleInternal(bool value) { - WorkbenchSingleton.MainForm.Visible = value; + WorkbenchSingleton.MainWindow.Visibility = value ? Visibility.Visible : Visibility.Hidden; } } } diff --git a/src/Main/ICSharpCode.SharpDevelop.Sda/Src/ExceptionBox.cs b/src/Main/ICSharpCode.SharpDevelop.Sda/Src/ExceptionBox.cs index 91284d76a7..83713119ba 100644 --- a/src/Main/ICSharpCode.SharpDevelop.Sda/Src/ExceptionBox.cs +++ b/src/Main/ICSharpCode.SharpDevelop.Sda/Src/ExceptionBox.cs @@ -14,6 +14,7 @@ using System.Windows.Forms; using ICSharpCode.Core; using ICSharpCode.Core.WinForms; +using ICSharpCode.SharpDevelop.Gui; namespace ICSharpCode.SharpDevelop.Sda { @@ -68,7 +69,7 @@ namespace ICSharpCode.SharpDevelop.Sda try { using (ExceptionBox box = new ExceptionBox(exception, message, mustTerminate)) { try { - box.ShowDialog(ICSharpCode.SharpDevelop.Gui.WorkbenchSingleton.MainForm); + box.ShowDialog(WorkbenchSingleton.MainWin32Window); } catch (InvalidOperationException) { box.ShowDialog(); } diff --git a/src/Main/StartUp/Project/Dialogs/SplashScreen.cs b/src/Main/StartUp/Project/Dialogs/SplashScreen.cs index 246b01a0be..eb04ee9c3b 100644 --- a/src/Main/StartUp/Project/Dialogs/SplashScreen.cs +++ b/src/Main/StartUp/Project/Dialogs/SplashScreen.cs @@ -14,7 +14,7 @@ namespace ICSharpCode.SharpDevelop { public class SplashScreenForm : Form { - public const string VersionText = "Montferrer (3.0) build " + RevisionClass.Revision; + public const string VersionText = "SD-WPF build " + RevisionClass.Revision; static SplashScreenForm splashScreen; static List requestedFileList = new List(); diff --git a/src/Main/StartUp/Project/SharpDevelopMain.cs b/src/Main/StartUp/Project/SharpDevelopMain.cs index addb4fd526..152b970dc7 100644 --- a/src/Main/StartUp/Project/SharpDevelopMain.cs +++ b/src/Main/StartUp/Project/SharpDevelopMain.cs @@ -118,7 +118,7 @@ namespace ICSharpCode.SharpDevelop string configDirectory = ConfigurationManager.AppSettings["settingsPath"]; if (String.IsNullOrEmpty(configDirectory)) { startup.ConfigDirectory = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), - "ICSharpCode/SharpDevelop" + RevisionClass.MainVersion); + "ICSharpCode/SharpDevelop" + RevisionClass.MainVersion + "wpf"); } else { startup.ConfigDirectory = Path.Combine(Path.GetDirectoryName(exe.Location), configDirectory); } diff --git a/src/SharpDevelop.sln b/src/SharpDevelop.sln index 575076af92..d77c79dd17 100644 --- a/src/SharpDevelop.sln +++ b/src/SharpDevelop.sln @@ -1,7 +1,7 @@  Microsoft Visual Studio Solution File, Format Version 10.00 # Visual Studio 2008 -# SharpDevelop 3.0.0.3264 +# SharpDevelop 3.0.0.3288 Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "AddIns", "AddIns", "{14A277EE-7DF1-4529-B639-7D1EF334C1C5}" ProjectSection(SolutionItems) = postProject EndProjectSection @@ -90,8 +90,6 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WixBinding", "AddIns\Backen EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "XamlBinding", "AddIns\BackendBindings\XamlBinding\Project\XamlBinding.csproj", "{7C96B65D-28A5-4F28-A35B-8D83CE831EE8}" EndProject -Project("{982E8BC1-ACD7-4dbf-96AB-B2CE67D6A008}") = "FSharpBinding", "AddIns\BackendBindings\FSharp\FSharpBinding\Project\FSharpBinding.fsproj", "{99BAE3A2-C40D-40D2-A7B4-EBB4798F36E4}" -EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Display Bindings", "Display Bindings", "{4EA396ED-64AD-4AD0-A67A-AB363F3E0C79}" ProjectSection(SolutionItems) = postProject EndProjectSection @@ -150,8 +148,6 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NRefactory", "Libraries\NRe EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ICSharpCode.TextEditor", "Libraries\ICSharpCode.TextEditor\Project\ICSharpCode.TextEditor.csproj", "{2D18BE89-D210-49EB-A9DD-2246FBB3DF6D}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WinFormsUI", "Libraries\DockPanel_Src\WinFormsUI\WinFormsUI.csproj", "{D3C782BA-178E-4235-A3BA-8C11DEBB6BEE}" -EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ICSharpCode.Build.Tasks", "Libraries\ICSharpCode.Build.Tasks\Project\ICSharpCode.Build.Tasks.csproj", "{4139CCF6-FB49-4A9D-B2CF-331E9EA3198D}" EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Aga.Controls", "Libraries\TreeViewAdv\Aga.Controls\Aga.Controls.csproj", "{E73BB233-D88B-44A7-A98F-D71EE158381D}" @@ -208,10 +204,6 @@ Global {2D18BE89-D210-49EB-A9DD-2246FBB3DF6D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {2D18BE89-D210-49EB-A9DD-2246FBB3DF6D}.Release|Any CPU.Build.0 = Release|Any CPU {2D18BE89-D210-49EB-A9DD-2246FBB3DF6D}.Release|Any CPU.ActiveCfg = Release|Any CPU - {D3C782BA-178E-4235-A3BA-8C11DEBB6BEE}.Debug|Any CPU.Build.0 = Debug|Any CPU - {D3C782BA-178E-4235-A3BA-8C11DEBB6BEE}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {D3C782BA-178E-4235-A3BA-8C11DEBB6BEE}.Release|Any CPU.Build.0 = Release|Any CPU - {D3C782BA-178E-4235-A3BA-8C11DEBB6BEE}.Release|Any CPU.ActiveCfg = Release|Any CPU {4139CCF6-FB49-4A9D-B2CF-331E9EA3198D}.Debug|Any CPU.Build.0 = Debug|Any CPU {4139CCF6-FB49-4A9D-B2CF-331E9EA3198D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {4139CCF6-FB49-4A9D-B2CF-331E9EA3198D}.Release|Any CPU.Build.0 = Release|Any CPU @@ -432,10 +424,6 @@ Global {8CF1EB90-324F-4AA9-BAA2-DEF87392CE86}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {8CF1EB90-324F-4AA9-BAA2-DEF87392CE86}.Release|Any CPU.Build.0 = Release|Any CPU {8CF1EB90-324F-4AA9-BAA2-DEF87392CE86}.Release|Any CPU.ActiveCfg = Release|Any CPU - {99BAE3A2-C40D-40D2-A7B4-EBB4798F36E4}.Debug|Any CPU.Build.0 = Debug|Any CPU - {99BAE3A2-C40D-40D2-A7B4-EBB4798F36E4}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {99BAE3A2-C40D-40D2-A7B4-EBB4798F36E4}.Release|Any CPU.Build.0 = Release|Any CPU - {99BAE3A2-C40D-40D2-A7B4-EBB4798F36E4}.Release|Any CPU.ActiveCfg = Release|Any CPU {E618A9CD-A39F-4925-A538-E8A3FEF24E54}.Debug|Any CPU.Build.0 = Debug|Any CPU {E618A9CD-A39F-4925-A538-E8A3FEF24E54}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {E618A9CD-A39F-4925-A538-E8A3FEF24E54}.Release|Any CPU.Build.0 = Release|Any CPU @@ -482,7 +470,6 @@ Global {E6F4983F-DE41-4AEC-88E7-1FA9AFB4E6FF} = {BDDDCD01-D2FE-4EAD-9425-4B6B91922C7C} {869951D5-A0D6-4DC6-9F1D-E6B9A12AC446} = {BDDDCD01-D2FE-4EAD-9425-4B6B91922C7C} {000E4F64-5D0D-4EB1-B0BF-1A62ADBC6EAD} = {BDDDCD01-D2FE-4EAD-9425-4B6B91922C7C} - {99BAE3A2-C40D-40D2-A7B4-EBB4798F36E4} = {FEB825FA-4AD8-425D-8E4A-B5A18EE1B81C} {7C96B65D-28A5-4F28-A35B-8D83CE831EE8} = {FEB825FA-4AD8-425D-8E4A-B5A18EE1B81C} {e1b288a2-08ee-4318-8bbb-8ab72c69e33e} = {FEB825FA-4AD8-425D-8E4A-B5A18EE1B81C} {DBCF20A1-BA13-4582-BFA9-74DE4D987B73} = {FEB825FA-4AD8-425D-8E4A-B5A18EE1B81C} @@ -517,7 +504,6 @@ Global {9B771930-6F16-4EC7-8CBB-C7B337EF5651} = {9421EDF4-9769-4BE9-B5A6-C87DE221D73C} {E73BB233-D88B-44A7-A98F-D71EE158381D} = {9421EDF4-9769-4BE9-B5A6-C87DE221D73C} {4139CCF6-FB49-4A9D-B2CF-331E9EA3198D} = {9421EDF4-9769-4BE9-B5A6-C87DE221D73C} - {D3C782BA-178E-4235-A3BA-8C11DEBB6BEE} = {9421EDF4-9769-4BE9-B5A6-C87DE221D73C} {2D18BE89-D210-49EB-A9DD-2246FBB3DF6D} = {9421EDF4-9769-4BE9-B5A6-C87DE221D73C} {3A9AE6AA-BC07-4A2F-972C-581E3AE2F195} = {9421EDF4-9769-4BE9-B5A6-C87DE221D73C} {857CA1A3-FC88-4BE0-AB6A-D1EE772AB288} = {5A3EBEBA-0560-41C1-966B-23F7D03A5486}