コード例 #1
0
 public LanguageListEditor()
 {
     lsbLanguages      = new MetroListBox();
     languageManager   = new EnumsManager <Languages>(lsbLanguages, "");
     lsbLanguages.Size = new System.Drawing.Size(180, 80);
     lsbLanguages.SelectedIndexChanged += LsbLanguages_SelectedIndexChanged;
 }
コード例 #2
0
ファイル: EnumsManager.cs プロジェクト: smfichadiya/ERPStudio
        public void AttachTo(MetroListBox lstBox, bool bAlsoNull = false)
        {
            FillArray(bAlsoNull);

            this.lsbBox               = lstBox;
            this.lsbBox.DataSource    = List;
            this.lsbBox.DisplayMember = "Display";
            this.lsbBox.ValueMember   = "Archive";
        }
コード例 #3
0
 public void AttachTo(MetroListBox cbbBox)
 {
     this.cbbBox = cbbBox;
     if (list != null)
     {
         cbbBox.DataSource    = list;
         cbbBox.DisplayMember = "Display";
         cbbBox.ValueMember   = "Archive";
     }
 }
コード例 #4
0
 public PrinterSizeEditor()
 {
     lsbSize = new MetroListBox
     {
         UseStyleColors = true,
         FontWeight     = MetroFramework.MetroTextBoxWeight.Regular,
         FontSize       = MetroFramework.MetroTextBoxSize.Medium,
         Size           = new System.Drawing.Size(180, 280)
     };
     lsbSize.SelectedIndexChanged += lsbSize_SelectedIndexChanged;
 }
コード例 #5
0
ファイル: EnumsManager.cs プロジェクト: smfichadiya/ERPStudio
        public EnumsManager(MetroListBox lstBox, ResourceManager resource = null, bool bAlsoNull = false, Predicate <T> filter = null)
        {
            myManager = resource == null
                            ? Properties.Resources.ResourceManager
                            : resource;

            Filter = filter;
            if (lstBox != null)
            {
                AttachTo(lstBox, bAlsoNull);
            }
        }
コード例 #6
0
ファイル: EnumsManager.cs プロジェクト: smfichadiya/ERPStudio
        public EnumsManager(MetroListBox lstBox, string resource = "", bool bAlsoNull = false, Predicate <T> filter = null)
        {
            myManager = resource.IsEmpty()
                            ? Properties.Resources.ResourceManager
                            : myManager = new System.Resources.ResourceManager(resource, System.Reflection.Assembly.GetAssembly(typeof(T)));

            Filter = filter;
            if (lstBox != null)
            {
                AttachTo(lstBox, bAlsoNull);
            }
        }
コード例 #7
0
        public PrinterListEditor()
        {
            lsbPrinters = new MetroListBox
            {
                UseStyleColors = true,
                FontWeight     = MetroFramework.MetroTextBoxWeight.Regular,
                FontSize       = MetroFramework.MetroTextBoxSize.Medium,
                Size           = new System.Drawing.Size(180, 280)
            };

            lsbPrinters.SelectedIndexChanged += lsbPrinters_SelectedIndexChanged;

            foreach (String printer in System.Drawing.Printing.PrinterSettings.InstalledPrinters)
            {
                lsbPrinters.Items.Add(printer.ToString());
            }
        }
コード例 #8
0
 public MetroListBoxActionList(IComponent component) : base(component)
 {
     _metroListBox = (MetroListBox)component;
 }
コード例 #9
0
 public MetroListBoxManager(MetroListBox cbbBox)
 {
     AttachTo(cbbBox);
 }