void InitScaleChooser()
        {
            ScaleChooser.RemoveAllItems();

            ScaleChooser.AddItem("Scale");

            ScaleChooser.AddItems(
                Enum.GetValues(typeof(Scale))
                .Cast <Scale>()
                .Select(s => s.GetFriendlyName())
                .ToArray()
                );
        }
예제 #2
0
        void ReleaseDesignerOutlets()
        {
            if (ColorIndicator != null)
            {
                ColorIndicator.Dispose();
                ColorIndicator = null;
            }

            if (ErrorLabel != null)
            {
                ErrorLabel.Dispose();
                ErrorLabel = null;
            }

            if (ImageCell != null)
            {
                ImageCell.Dispose();
                ImageCell = null;
            }

            if (NodeEditorButton != null)
            {
                NodeEditorButton.Dispose();
                NodeEditorButton = null;
            }

            if (PausePlayButton != null)
            {
                PausePlayButton.Dispose();
                PausePlayButton = null;
            }

            if (ProgressIndicator != null)
            {
                ProgressIndicator.Dispose();
                ProgressIndicator = null;
            }

            if (RandomImageButton != null)
            {
                RandomImageButton.Dispose();
                RandomImageButton = null;
            }

            if (RandomImageSpinner != null)
            {
                RandomImageSpinner.Dispose();
                RandomImageSpinner = null;
            }

            if (ScaleChooser != null)
            {
                ScaleChooser.Dispose();
                ScaleChooser = null;
            }

            if (StopButton != null)
            {
                StopButton.Dispose();
                StopButton = null;
            }
        }