Пример #1
0
        void ReleaseDesignerOutlets()
        {
            if (ProvinceLabel != null)
            {
                ProvinceLabel.Dispose();
                ProvinceLabel = null;
            }

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

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

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

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

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

            if (RegisterButton != null)
            {
                RegisterButton.Dispose();
                RegisterButton = null;
            }
        }
Пример #2
0
        internal string ApplyNamingMask(string NamingMask)
        {
            int iter = 0;

            while (NamingMask.ContainsRenderTag(RenderTags.Track) || NamingMask.ContainsRenderTag(RenderTags.Region) || NamingMask.ContainsRenderTag(RenderTags.Bus))
            {
                iter++;
                NamingMask = NamingMask.Replace(RenderTags.Format(RenderTags.Track), TrackName.StripRenderTags());
                NamingMask = NamingMask.Replace(RenderTags.Format(RenderTags.Region), RegionLabel.StripRenderTags());
                NamingMask = NamingMask.Replace(RenderTags.Format(RenderTags.Bus), BusName.StripRenderTags());
                if (iter > 3)
                {
                    break;
                }
            }

            NamingMask = NamingMask.Replace(RenderTags.Format(RenderTags.Counter), String.Format("{0:d" + RenderParams.GetParam <long>(RenderTags.CounterDigits) + "}", CounterIndex));
            return(NamingMask);
        }
Пример #3
0
 private void RegionComboBox_DropDownClosed(object sender, EventArgs e)
 {
     RegionLabel.Focus();
 }