コード例 #1
0
ファイル: PackageCreator.cs プロジェクト: MOGwareSupport/MOG
        public PackageCreator()
        {
            InitializeComponent();

            // Make sure we are not in the designer / DesignMode
            //if (GetService(typeof(System.ComponentModel.Design.IDesignerHost)) == null)
            if (System.ComponentModel.LicenseManager.UsageMode != System.ComponentModel.LicenseUsageMode.Designtime)
            {
                MOG_Project project = MOG_ControllerProject.GetProject();
                if (project != null)
                {
                    PlatformCombo.Items.Add("All");
                    PlatformCombo.SelectedIndex = 0;

                    foreach (MOG_Platform platform in project.GetPlatforms())
                    {
                        PlatformCombo.Items.Add(platform.mPlatformName);
                    }

                    PlatformCombo.Items.Add(MOG_ControllerProject.GetAllPlatformsString());

                    ClassificationTreeView.Initialize(DrillToClassification);
                    SyncTargetTreeView.InitializeVirtual(Platform);

                    PlatformCombo.BackColor = Color.PaleGreen;
                }
            }

            IsTextBoxValid(this.PackageNameTextBox);
            IsTextBoxValid(this.SyncTargetTextBox);
            IsTextBoxValid(this.ClassificationTextBox);
        }
コード例 #2
0
        public void LoadFromProject(MOG_Project proj)
        {
            lvPlatforms.Clear();

            // Loop and add 'em
            foreach (MOG_Platform platform in proj.GetPlatforms())
            {
                AddPlatform(platform);
            }
        }