Mini Kabibi Habibi

Current Path : C:/Users/Public/Documents/DXperience 13.1 Demos/WinForms/VB/BarTutorials/
Upload File :
Current File : C:/Users/Public/Documents/DXperience 13.1 Demos/WinForms/VB/BarTutorials/TutorialRegistration.vb

Imports Microsoft.VisualBasic
Imports System
Imports System.Reflection
Imports System.Collections
Imports System.ComponentModel
Imports System.Drawing
Imports System.Windows.Forms
Imports DevExpress.DXperience.Demos
Imports DevExpress.XtraBars.Ribbon

Namespace DevExpress.XtraBars.Demos.Tutorials
	Public Class TutorialsInfo
		Inherits DevExpress.DXperience.Demos.ModulesInfo
        Private Const languageDir As String = "VB\"

		Public Shared Sub CloseCustomizationForm(ByVal control As Control)
			If control Is Nothing Then
			Return
			End If
			For Each obj As Object In control.Controls
				If TypeOf obj Is RibbonControl Then
					CType(obj, RibbonControl).Visible = False
					CType(obj, RibbonControl).Visible = True
				End If
			Next obj
		End Sub

		Public Shared Overloads Function ShowModule(ByVal name As String, ByVal groupControl As DevExpress.XtraEditors.GroupControl, ByVal menu As DevExpress.DXperience.Demos.LookAndFeelMenu, ByVal lookAndFeel As DevExpress.LookAndFeel.DefaultLookAndFeel) As DevExpress.Tutorials.ModuleBase
			Dim item As ModuleInfo = TutorialsInfo.GetItem(name)
			Dim currentCursor As Cursor = Cursor.Current
			Cursor.Current = Cursors.WaitCursor
			groupControl.Parent.SuspendLayout()
			groupControl.SuspendLayout()
			Try
				Dim oldTutorial As Control = Nothing
				If Not Instance.CurrentModuleBase Is Nothing Then
					oldTutorial = Instance.CurrentModuleBase.TModule
				End If

				Dim tutorial As TutorialControl = TryCast(item.TModule, TutorialControl)
				tutorial.Bounds = groupControl.DisplayRectangle
				Instance.CurrentModuleBase = item
				tutorial.Visible = False
				groupControl.Controls.Add(tutorial)
				tutorial.Dock = DockStyle.Fill

				CloseCustomizationForm(oldTutorial)

				If tutorial.ShowLookAndFeel Then
					menu.InitLookAndFeelMenu(lookAndFeel)
				Else
					menu.InitLookAndFeelMenu(Nothing)
				End If

				tutorial.Visible = True
				If Not oldTutorial Is Nothing Then
				oldTutorial.Visible = False
				End If
			Finally
				groupControl.ResumeLayout(True)
				groupControl.Parent.ResumeLayout(True)
				Cursor.Current = currentCursor
			End Try
			RaiseModuleChanged()
			Dim [module] As DevExpress.Tutorials.ModuleBase = TryCast(Instance.CurrentModuleBase.TModule, DevExpress.Tutorials.ModuleBase)
			If Not [module] Is Nothing Then
				[module].TutorialInfo.Description = Instance.CurrentModuleBase.Description
				[module].TutorialInfo.TutorialName = Instance.CurrentModuleBase.Name
				[module].TutorialInfo.WhatsThisCodeFile = Instance.CurrentModuleBase.CodeFile
				[module].TutorialInfo.WhatsThisXMLFile = Instance.CurrentModuleBase.XMLFile
				Dim xmlFile As String = DevExpress.Utils.FilesHelper.FindingFileName(Application.StartupPath, [module].TutorialInfo.WhatsThisXMLFile, False)
				Dim codeFile As String = DevExpress.Utils.FilesHelper.FindingFileName(Application.StartupPath, [module].TutorialInfo.WhatsThisCodeFile, False)
				If xmlFile = "" Then
                    [module].TutorialInfo.WhatsThisXMLFile = DemoHelper.StringComposite([module].TutorialInfo.WhatsThisXMLFile, languageDir)
				End If
				If codeFile = "" Then
                    [module].TutorialInfo.WhatsThisCodeFile = DemoHelper.StringComposite([module].TutorialInfo.WhatsThisCodeFile, languageDir)
				End If
			End If
			Return [module]
		End Function
	End Class
	Friend Class RegisterTutorials
		Friend Shared NewFeaturesString As String = "DevExpress XtraBars v" & AssemblyInfo.VersionShort
		Public Shared Sub Register()
            TutorialsInfo.Add(RegisterTutorials.NewFeaturesString, "DevExpress.XtraBars.Demos.Tutorials.About")
            TutorialsInfo.Add("Add Bar Item Links", "DevExpress.XtraBars.Demos.Tutorials.AddBarItemLinks", "This tutorial shows how to create and delete bar items and links.", Nothing, "BarTutorials\AddBarItemLinks\AddBarItemLinks.vb", "Data\Tutorials\XtraBars\AddBarItemLinks.xml")
            TutorialsInfo.Add("Add New Bar", "DevExpress.XtraBars.Demos.Tutorials.AddNewBar", "This tutorial shows how to create and delete bars.", Nothing, "BarTutorials\AddNewBar\AddNewBar.vb", "Data\Tutorials\XtraBars\AddNewBar.xml")
            TutorialsInfo.Add("Bar Docking", "DevExpress.XtraBars.Demos.Tutorials.BarDocking", "This demo shows how to dock a bar control to various sides of its owning control in code.", Nothing, "BarTutorials\BarDocking\BarDocking.vb", "Data\Tutorials\XtraBars\BarDocking.xml")
            TutorialsInfo.Add("Bar Item Links Info", "DevExpress.XtraBars.Demos.Tutorials.BarItemLinksInfo", "This tutorial shows how to obtain information on items and links. The information is displayed within a separate window.", Nothing, "BarTutorials\BarItemLinksInfo\BarItemLinksInfo.vb", "Data\Tutorials\XtraBars\BarItemLinksInfo.xml")
            TutorialsInfo.Add("Bar Link Container Item", "DevExpress.XtraBars.Demos.Tutorials.BarLinkContainerItem", "This tutorial demonstrates how to dynamically add links to and remove them from the BarLinkContainerItem.", Nothing, "BarTutorials\BarLinkContainerItem\BarLinkContainerItem.vb", "Data\Tutorials\XtraBars\BarLinkContainerItem.xml")
            TutorialsInfo.Add("Dock Panels", "DevExpress.XtraBars.Demos.Tutorials.DockPanels", "This tutorial shows how to create dock panels and dock them to the desired edge of the container control (form). It also demonstrates how to enable the Auto-Hide feature of dock panels.", Nothing, "BarTutorials\DockPanels\DockPanels.vb", "Data\Tutorials\XtraBars\DockPanels.xml")
            TutorialsInfo.Add("Editor Items", "DevExpress.XtraBars.Demos.Tutorials.EditorItems", "This tutorial shows how to use Bar Edit Items. To respond to edit value changing handle the item's EditValueChanged event.", Nothing, "BarTutorials\EditorItems\EditorItems.vb", "")
            TutorialsInfo.Add("Localization German", "DevExpress.XtraBars.Demos.Tutorials.LocalizationGerman", "This demo shows how to translate the XtraBars' UI into German using the BarLocalizer object.", Nothing, "BarTutorials\LocalizationGerman\LocalizationGerman.vb", "Data\Tutorials\XtraBars\LocalizationGerman.xml")
            TutorialsInfo.Add("Paint Menu Bar", "DevExpress.XtraBars.Demos.Tutorials.PaintMenuBar", "Sub-menus and popup menus can display a bar to the left of their content. This demo shows how to custom paint a menu bar by handling the PaintMenuBar event.", Nothing, "BarTutorials\PaintMenuBar\PaintMenuBar.vb", "")
            TutorialsInfo.Add("Popup Control Container", "DevExpress.XtraBars.Demos.Tutorials.PopupControlContainer", "Links that correspond to Bar Button Items can function as a dropdown. This allows the dropdown control to popup when such a link is pressed. In this tutorial, the dropdown control which allows you to specify the label's alignment is shown when the 'Text Alignment' link's dropdown button is pressed.", Nothing, "BarTutorials\PopupControlContainer\PopupControlContainer.vb", "")
            TutorialsInfo.Add("Repeated Button", "DevExpress.XtraBars.Demos.Tutorials.RepeatedButton", "This tutorial shows how to provide a simple navigation through data records. Data records can be scrolled repeatedly when the 'Previous Record' or 'Next Record' link is pressed.", Nothing, "BarTutorials\RepeatedButton\RepeatedButton.vb", "")
            TutorialsInfo.Add("MDI Menu Merging", "DevExpress.XtraBars.Demos.Tutorials.MDIMenuMergingStart", "This tutorial demonstrates the merging mechanism provided by the XtraBars. This functionality allows you to merge bars and menus of parent and child MDI forms. Click the 'Launch Sample' button to run the tutorial. The Merging options allow you to chose the MDI merge style which determines whether and when merge and unmerge mechanisms are invoked.", Nothing, "", "")
            TutorialsInfo.Add("Most Recent Files", "DevExpress.XtraBars.Demos.Tutorials.MostRecentFilesStart", "This tutorial shows how to implement the 'Recent Files' functionality using the XtraBars. Click the 'Launch Sample' button to run the tutorial. Once a new file is opened, the path to this file is automatically added to the 'Recent Files' list. This list is represented by the BarListItem. Its Strings property represents the numerated list of strings which is repopulated after a new file has been opened.", Nothing, "", "")
            TutorialsInfo.Add("Tabbed MDI", "DevExpress.XtraBars.Demos.Tutorials.TabbedMDIStart", "This tutorial demonstrates the tabbed MDI manager which provides centralized control over the MDI child forms that are parented to the form. When using the tabbed MDI manager, child forms are represented by tabbed pages. Click the 'Launch Sample' button to run the tutorial.", Nothing, "", "")
            TutorialsInfo.Add("Ribbon Gallery", "DevExpress.XtraBars.Demos.Tutorials.Gallery", "This tutorial demonstrates how to work with Ribbon Galleries. You will learn how to create and populate Image Galleries, associate actions with Gallery items, customize and display super tips, etc.", Nothing, "BarTutorials\Gallery\Gallery.vb", "Data\Tutorials\XtraBars\Gallery.xml")
            TutorialsInfo.Add("Context Tabs", "DevExpress.XtraBars.Demos.Tutorials.ContextTabs", "This tutorial demonstrates how to work with Ribbon page categories. By default, the Ribbon control displays all Ribbon pages within the default page category, which has no header. The Ribbon control also allows you to add custom categories with pages, which are typically used to implement contextual tabs, as that found in MS Office 2007 applications. Practice adding categories and pages, as well as changing category captions, color and alignment.", Nothing, "BarTutorials\ContextTabs\previewRibbon.vb", "Data\Tutorials\XtraBars\ContextTabs.xml")
            TutorialsInfo.Add("Standalone BarDockControl", "DevExpress.XtraBars.Demos.Tutorials.StandaloneBDControl", "This example demonstrates standalone bar containers represented by the StandaloneBarDockControl class. These allow bars to be displayed at any position within the form. In this example, two StandaloneBarDockControls containing bars are displayed within tab pages. Practice dragging bars to and from bar containers.", Nothing, "BarTutorials\StandaloneBarDockControl\StandaloneBDControl.vb", "Data\Tutorials\XtraBars\StandaloneBarDockControl.xml")
            TutorialsInfo.Add("Alert Control", "DevExpress.XtraBars.Demos.Tutorials.AlertControlTutorial", "This example demonstrates the AlertControl component that allows notification windows to be displayed. Click the 'Show Alert Form' button to display a notification window. It will be displayed at the bottom right corner of the screen. However, you can change the form's position as well as many other options using the controls provided by the demo.", Nothing, "BarTutorials\AlertControl\AlertInfoProperties.vb;BarTutorials\AlertControl\AlertControlProperties.vb;BarTutorials\AlertControl\AlertControlTutorial.vb", "Data\Tutorials\XtraBars\AlertControl.xml")
            TutorialsInfo.Add("Document Manager TabbedView", "DevExpress.XtraBars.Demos.Tutorials.DocumentManagerStart", "This tutorial demonstrates the Tabbed MDI UI implemented via DocumenManager. DocumentManager provides centralized control over MDI child forms that are parented to the main MDI form. Click the 'Launch Sample' button to run the tutorial.", Nothing, "", "")
            TutorialsInfo.Add("Document Manager NativeMdiView", "DevExpress.XtraBars.Demos.Tutorials.DocumentManagerNativeMdiStart", "This tutorial demonstrates the Native MDI UI implemented via DocumenManager. DocumenManager provides centralized control over MDI child forms that are parented to the main MDI form. Note that in this mode, the MDI container is painted using the current skin. Click the 'Launch Sample' button to run the tutorial.", Nothing, "", "")
            TutorialsInfo.Add("Document Manager Docking", "DevExpress.XtraBars.Demos.Tutorials.DocumentManagerDockingStart", "This tutorial demonstrates how to integrate DocumentManager with our Docking library to emulate the document interface found in Microsoft Visual Studio 2010. Click the 'Launch Sample' button to run the tutorial.", Nothing, "", "")
            TutorialsInfo.Add("Custom Header Buttons", "DevExpress.XtraBars.Demos.Tutorials.CustomHeaderButtons", "This demo illustrates how to use different types of custom header buttons within a DockPanel. You can choose a custom button's type (Push or Check) and its icon (a static image or unique glyph for each of the button's states) via the radio group at the top of the DockPanel. The properties grid to the right of the panel provides options for the custom button's detailed tweaking.", Nothing, "BarTutorials\CustomHeaderButtons\CustomHeaderButtons.vb;BarTutorials\CustomHeaderButton\ButtonActions.vb;BarTutorials\CustomHeaderButton\ButtonPropertyGrid.vb")
            TutorialsInfo.Add("NonMdi DocumentManager", "DevExpress.XtraBars.Demos.Tutorials.DocumentManagerNonMdiMode", "In this tutorial, Document Manager is hosted within a container and is not placed onto a form itself. You can use several types of container controls (such as UserControl) and add as many Document Managers to your application as required.", Nothing, "BarTutorials\DocumentManager\DocumentManagerNonMdiMode.vb")
            TutorialsInfo.Add("Deferred Load Documents", "DevExpress.XtraBars.Demos.Tutorials.DocumentManagerDeferredLoadDocuments", "This tutorial demonstrates the process of loading documents in deferred mode. At the application start-up only the first visible document is loaded and displayed. Further documents are loaded on demand - when a corresponding tab header has been clicked.", Nothing, "BarTutorials\DocumentManager\DocumentManagerDeferredLoadDocuments.vb")
            TutorialsInfo.Add("Radial Menu", "DevExpress.XtraBars.Demos.Tutorials.RadialMenu", "This example demonstrates the RadialMenu in action. Use the Ribbon controls above to change various RadialMenu options.", Nothing, "BarTutorials\RadialMenu\RadialMenu.vb")
            TutorialsInfo.Add("Ribbon Mini Toolbar", "DevExpress.XtraBars.Demos.Tutorials.RibbonMiniToolbar", "This tutorial demonstrates how to work with Ribbon Mini Toolbars.", Nothing, "BarTutorials\RibbonMiniToolbar\RibbonMiniToolbar.vb")
        End Sub
	End Class
End Namespace