Desktop/HStation.Desktop.Xhs.Core/DbFirstHelper.cs
@@ -18,6 +18,7 @@ { new BLL.XhsDbFirstHelper().Initial(); new Yw.BLL.MapDbFirstHelper().Initial(); new Yw.BLL.BasicDbFirstHelper().Initial(); } } } WinFrmUI/HStation.WinFrmUI.Xhs.Core/02-project/01-import/00-core/ImportXhsProjectManager.cs
@@ -3,127 +3,8 @@ /// <summary> /// å¯¼å ¥é¡¹ç®ç®¡ç /// </summary> public class ImportXhsProjectManager : IWizardManager<ImportXhsProjectViewModel> public class ImportXhsProjectManager : WizardManager<ImportXhsProjectViewModel> { /// <summary> /// åå§å管çå¨ /// </summary> /// <param name="pages">æ¥éª¤é¡µé¢æ°ç»</param> public void InitialManager(IWizardPage<ImportXhsProjectViewModel>[] pages) { _pages = pages; if (_pages != null && _pages.Length > 0) { _selectedIndex = 0; this.SelectedPageChangedEvent?.Invoke(this.SelectedPage, this.SelectedIndex); this.SelectedPage.InitialPage(_vm); } } private IWizardPage<ImportXhsProjectViewModel>[] _pages;//æ¥éª¤é¡µé¢æ°ç» private readonly ImportXhsProjectViewModel _vm = new ImportXhsProjectViewModel(); /// <summary> /// 鿩页颿¹åäºä»¶ /// </summary> public event Action<Yw.WinFrmUI.IWizardPage<ImportXhsProjectViewModel>, int> SelectedPageChangedEvent; public event Action<IWizardPage<ImportXhsProjectViewModel>, int> SelectedPageStateChangedEvent; /// <summary> /// éæ©é¡µé¢ /// </summary> public IWizardPage<ImportXhsProjectViewModel> SelectedPage { get { if (_pages == null || _pages.Length < 1) { return default; } return _pages[SelectedIndex]; } } /// <summary> /// éæ©ç´¢å¼ /// </summary> public int SelectedIndex { get { return _selectedIndex; } } private int _selectedIndex; /// <summary> /// ä¸ä¸æ¥ /// </summary> public bool Prev() { if (_pages == null || _pages.Length < 1) { return false; } if (this.SelectedPage.CanPrev()) { --_selectedIndex; this.SelectedPageChangedEvent?.Invoke(this.SelectedPage, this.SelectedIndex); this.SelectedPage.InitialPage(_vm); return true; } return false; } /// <summary> /// ä¸ä¸æ¥ /// </summary> public bool Next() { if (_pages == null || _pages.Length < 1) { return false; } if (this.SelectedPage.CanNext()) { ++_selectedIndex; this.SelectedPageChangedEvent?.Invoke(this.SelectedPage, this.SelectedIndex); this.SelectedPage.InitialPage(_vm); return true; } return false; } /// <summary> /// åæ¶ /// </summary> public bool Cancel() { if (_pages == null || _pages.Length < 1) { return false; } if (this.SelectedPage.CanCancel()) { return true; } return false; } /// <summary> /// 宿 /// </summary> public bool Complete() { if (_pages == null || _pages.Length < 1) { return false; } if (this.SelectedPage.CanComplete()) { return true; } return false; } WinFrmUI/HStation.WinFrmUI.Xhs.Core/02-project/01-import/00-core/ImportXhsProjectViewModel.cs
@@ -63,7 +63,17 @@ #endregion #region ç¬¬åæ¥çæé¡¹ç® #endregion #region ç¬¬äºæ¥é¡¹ç®å®æ #endregion } } WinFrmUI/HStation.WinFrmUI.Xhs.Core/02-project/01-import/01-ModelFile/SelectXhsProjectModelFileWizardPage.cs
@@ -1,5 +1,4 @@  namespace HStation.WinFrmUI namespace HStation.WinFrmUI { /// <summary> /// éæ©é¡¹ç®æ¨¡åæä»¶ @@ -12,7 +11,13 @@ this.layoutControl1.SetupLayoutControl(); } private ImportXhsProjectViewModel _vm = null; /// <summary> /// 页é¢ç¶ææ¹åäºä»¶ /// </summary> public event Action PageStateChangedEvent; private ImportXhsProjectViewModel _vm = null;//æä½å¯¹è±¡ private bool _isInitialize = false;//æ¯å¦åå§å /// <summary> /// åå§å @@ -27,19 +32,9 @@ _isInitialize = true; } /// <summary> /// æ¯å¦åå§å /// </summary> public bool IsInitialize { get { return _isInitialize; } } private bool _isInitialize = false; public event Action PageStateChangedEvent; /// <summary> /// æ¯å¦å 许è¿åä¸ä¸æ¥ /// å 许ä¸ä¸æ¥ /// </summary> public bool AllowPrev { @@ -47,15 +42,18 @@ } /// <summary> /// æ¯å¦å 许è¿å ¥ä¸ä¸æ¥ /// å 许ä¸ä¸æ¥ /// </summary> public bool AllowNext { get { return true; } get { return _isInitialize; } } /// <summary> /// æ¯å¦å è®¸åæ¶ /// å è®¸åæ¶ /// </summary> public bool AllowCancel { @@ -63,7 +61,7 @@ } /// <summary> /// æ¯å¦å è®¸å®æ /// å è®¸å®æ /// </summary> public bool AllowComplete { @@ -71,7 +69,7 @@ } /// <summary> /// è½å¦è¿åä¸ä¸æ¥ /// è½å¦ä¸ä¸æ¥ /// </summary> public bool CanPrev() { @@ -79,16 +77,21 @@ } /// <summary> /// è½å¦è¿å ¥ä¸ä¸æ¥ /// è½å¦ä¸ä¸æ¥ /// </summary> public bool CanNext() { if (!_isInitialize) { return false; } this.dxErrorProvider1.ClearErrors(); if (string.IsNullOrEmpty(this.btnEditSelectModelFile.Text.Trim())) { this.dxErrorProvider1.SetError(this.btnEditSelectModelFile, "å¿ é项"); return false; } _vm.ZipFile = this.btnEditSelectModelFile.Text.Trim(); return true; } @@ -119,7 +122,6 @@ if (dlg.ShowDialog() == DialogResult.OK) { var fileName = dlg.FileName; _vm.ZipFile = fileName; this.btnEditSelectModelFile.EditValue = fileName; } } WinFrmUI/HStation.WinFrmUI.Xhs.Core/02-project/01-import/02-ProjectInfo/InputXhsProjectInfoWizardPage.Designer.cs
@@ -32,7 +32,6 @@ layoutControl1 = new DevExpress.XtraLayout.LayoutControl(); txtDescription = new DevExpress.XtraEditors.MemoEdit(); txtTagNme = new DevExpress.XtraEditors.TextEdit(); txtFlags = new DevExpress.XtraEditors.TextEdit(); txtAddress = new DevExpress.XtraEditors.TextEdit(); txtCustomer = new DevExpress.XtraEditors.TextEdit(); txtName = new DevExpress.XtraEditors.TextEdit(); @@ -42,15 +41,15 @@ layoutControlItem2 = new DevExpress.XtraLayout.LayoutControlItem(); layoutControlItem3 = new DevExpress.XtraLayout.LayoutControlItem(); layoutControlItem4 = new DevExpress.XtraLayout.LayoutControlItem(); layoutControlItem5 = new DevExpress.XtraLayout.LayoutControlItem(); layoutControlItem6 = new DevExpress.XtraLayout.LayoutControlItem(); layoutControlItem7 = new DevExpress.XtraLayout.LayoutControlItem(); dxErrorProvider1 = new DevExpress.XtraEditors.DXErrorProvider.DXErrorProvider(components); setFlagsEditCtrl1 = new SetFlagsEditCtrl(); layoutControlItem5 = new DevExpress.XtraLayout.LayoutControlItem(); ((ISupportInitialize)layoutControl1).BeginInit(); layoutControl1.SuspendLayout(); ((ISupportInitialize)txtDescription.Properties).BeginInit(); ((ISupportInitialize)txtTagNme.Properties).BeginInit(); ((ISupportInitialize)txtFlags.Properties).BeginInit(); ((ISupportInitialize)txtAddress.Properties).BeginInit(); ((ISupportInitialize)txtCustomer.Properties).BeginInit(); ((ISupportInitialize)txtName.Properties).BeginInit(); @@ -60,17 +59,17 @@ ((ISupportInitialize)layoutControlItem2).BeginInit(); ((ISupportInitialize)layoutControlItem3).BeginInit(); ((ISupportInitialize)layoutControlItem4).BeginInit(); ((ISupportInitialize)layoutControlItem5).BeginInit(); ((ISupportInitialize)layoutControlItem6).BeginInit(); ((ISupportInitialize)layoutControlItem7).BeginInit(); ((ISupportInitialize)dxErrorProvider1).BeginInit(); ((ISupportInitialize)layoutControlItem5).BeginInit(); SuspendLayout(); // // layoutControl1 // layoutControl1.Controls.Add(setFlagsEditCtrl1); layoutControl1.Controls.Add(txtDescription); layoutControl1.Controls.Add(txtTagNme); layoutControl1.Controls.Add(txtFlags); layoutControl1.Controls.Add(txtAddress); layoutControl1.Controls.Add(txtCustomer); layoutControl1.Controls.Add(txtName); @@ -78,6 +77,7 @@ layoutControl1.Dock = DockStyle.Fill; layoutControl1.Location = new Point(0, 0); layoutControl1.Name = "layoutControl1"; layoutControl1.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new Rectangle(1200, 175, 650, 400); layoutControl1.Root = Root; layoutControl1.Size = new Size(859, 464); layoutControl1.TabIndex = 0; @@ -85,57 +85,49 @@ // // txtDescription // txtDescription.Location = new Point(84, 84); txtDescription.Location = new Point(67, 84); txtDescription.Name = "txtDescription"; txtDescription.Size = new Size(763, 368); txtDescription.Size = new Size(780, 368); txtDescription.StyleController = layoutControl1; txtDescription.TabIndex = 10; // // txtTagNme // txtTagNme.Location = new Point(503, 60); txtTagNme.Location = new Point(486, 60); txtTagNme.Name = "txtTagNme"; txtTagNme.Size = new Size(344, 20); txtTagNme.Size = new Size(361, 20); txtTagNme.StyleController = layoutControl1; txtTagNme.TabIndex = 9; // // txtFlags // txtFlags.Location = new Point(84, 60); txtFlags.Name = "txtFlags"; txtFlags.Size = new Size(343, 20); txtFlags.StyleController = layoutControl1; txtFlags.TabIndex = 8; // // txtAddress // txtAddress.Location = new Point(503, 36); txtAddress.Location = new Point(486, 36); txtAddress.Name = "txtAddress"; txtAddress.Size = new Size(344, 20); txtAddress.Size = new Size(361, 20); txtAddress.StyleController = layoutControl1; txtAddress.TabIndex = 7; // // txtCustomer // txtCustomer.Location = new Point(84, 36); txtCustomer.Location = new Point(67, 36); txtCustomer.Name = "txtCustomer"; txtCustomer.Size = new Size(343, 20); txtCustomer.Size = new Size(360, 20); txtCustomer.StyleController = layoutControl1; txtCustomer.TabIndex = 6; // // txtName // txtName.Location = new Point(503, 12); txtName.Location = new Point(486, 12); txtName.Name = "txtName"; txtName.Size = new Size(344, 20); txtName.Size = new Size(361, 20); txtName.StyleController = layoutControl1; txtName.TabIndex = 5; // // txtNO // txtNO.Location = new Point(84, 12); txtNO.Location = new Point(67, 12); txtNO.Name = "txtNO"; txtNO.Size = new Size(343, 20); txtNO.Size = new Size(360, 20); txtNO.StyleController = layoutControl1; txtNO.TabIndex = 4; // @@ -145,7 +137,7 @@ Root.AppearanceItemCaption.TextOptions.HAlignment = DevExpress.Utils.HorzAlignment.Far; Root.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.True; Root.GroupBordersVisible = false; Root.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] { layoutControlItem1, layoutControlItem2, layoutControlItem3, layoutControlItem4, layoutControlItem5, layoutControlItem6, layoutControlItem7 }); Root.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] { layoutControlItem1, layoutControlItem2, layoutControlItem3, layoutControlItem4, layoutControlItem6, layoutControlItem7, layoutControlItem5 }); Root.Name = "Root"; Root.Size = new Size(859, 464); Root.TextVisible = false; @@ -157,7 +149,7 @@ layoutControlItem1.Name = "layoutControlItem1"; layoutControlItem1.Size = new Size(419, 24); layoutControlItem1.Text = "ç¼å·ï¼"; layoutControlItem1.TextSize = new Size(60, 14); layoutControlItem1.TextSize = new Size(43, 14); // // layoutControlItem2 // @@ -167,7 +159,7 @@ layoutControlItem2.Name = "layoutControlItem2"; layoutControlItem2.Size = new Size(420, 24); layoutControlItem2.Text = "<color=red>*</color>åç§°ï¼"; layoutControlItem2.TextSize = new Size(60, 14); layoutControlItem2.TextSize = new Size(43, 14); // // layoutControlItem3 // @@ -176,7 +168,7 @@ layoutControlItem3.Name = "layoutControlItem3"; layoutControlItem3.Size = new Size(419, 24); layoutControlItem3.Text = "客æ·ï¼"; layoutControlItem3.TextSize = new Size(60, 14); layoutControlItem3.TextSize = new Size(43, 14); // // layoutControlItem4 // @@ -184,17 +176,8 @@ layoutControlItem4.Location = new Point(419, 24); layoutControlItem4.Name = "layoutControlItem4"; layoutControlItem4.Size = new Size(420, 24); layoutControlItem4.Text = "详ç»å°åï¼"; layoutControlItem4.TextSize = new Size(60, 14); // // layoutControlItem5 // layoutControlItem5.Control = txtFlags; layoutControlItem5.Location = new Point(0, 48); layoutControlItem5.Name = "layoutControlItem5"; layoutControlItem5.Size = new Size(419, 24); layoutControlItem5.Text = "æ ç¾ï¼"; layoutControlItem5.TextSize = new Size(60, 14); layoutControlItem4.Text = "å°åï¼"; layoutControlItem4.TextSize = new Size(43, 14); // // layoutControlItem6 // @@ -203,7 +186,7 @@ layoutControlItem6.Name = "layoutControlItem6"; layoutControlItem6.Size = new Size(420, 24); layoutControlItem6.Text = "æ å¿ï¼"; layoutControlItem6.TextSize = new Size(60, 14); layoutControlItem6.TextSize = new Size(43, 14); // // layoutControlItem7 // @@ -212,11 +195,27 @@ layoutControlItem7.Name = "layoutControlItem7"; layoutControlItem7.Size = new Size(839, 372); layoutControlItem7.Text = "说æ"; layoutControlItem7.TextSize = new Size(60, 14); layoutControlItem7.TextSize = new Size(43, 14); // // dxErrorProvider1 // dxErrorProvider1.ContainerControl = this; // // setFlagsEditCtrl1 // setFlagsEditCtrl1.Location = new Point(67, 60); setFlagsEditCtrl1.Name = "setFlagsEditCtrl1"; setFlagsEditCtrl1.Size = new Size(360, 20); setFlagsEditCtrl1.TabIndex = 11; // // layoutControlItem5 // layoutControlItem5.Control = setFlagsEditCtrl1; layoutControlItem5.Location = new Point(0, 48); layoutControlItem5.Name = "layoutControlItem5"; layoutControlItem5.Size = new Size(419, 24); layoutControlItem5.Text = "æ ç¾ï¼"; layoutControlItem5.TextSize = new Size(43, 14); // // InputXhsProjectInfoWizardPage // @@ -229,7 +228,6 @@ layoutControl1.ResumeLayout(false); ((ISupportInitialize)txtDescription.Properties).EndInit(); ((ISupportInitialize)txtTagNme.Properties).EndInit(); ((ISupportInitialize)txtFlags.Properties).EndInit(); ((ISupportInitialize)txtAddress.Properties).EndInit(); ((ISupportInitialize)txtCustomer.Properties).EndInit(); ((ISupportInitialize)txtName.Properties).EndInit(); @@ -239,10 +237,10 @@ ((ISupportInitialize)layoutControlItem2).EndInit(); ((ISupportInitialize)layoutControlItem3).EndInit(); ((ISupportInitialize)layoutControlItem4).EndInit(); ((ISupportInitialize)layoutControlItem5).EndInit(); ((ISupportInitialize)layoutControlItem6).EndInit(); ((ISupportInitialize)layoutControlItem7).EndInit(); ((ISupportInitialize)dxErrorProvider1).EndInit(); ((ISupportInitialize)layoutControlItem5).EndInit(); ResumeLayout(false); } @@ -258,12 +256,12 @@ private DevExpress.XtraEditors.TextEdit txtCustomer; private DevExpress.XtraLayout.LayoutControlItem layoutControlItem3; private DevExpress.XtraEditors.TextEdit txtTagNme; private DevExpress.XtraEditors.TextEdit txtFlags; private DevExpress.XtraEditors.TextEdit txtAddress; private DevExpress.XtraLayout.LayoutControlItem layoutControlItem4; private DevExpress.XtraLayout.LayoutControlItem layoutControlItem5; private DevExpress.XtraLayout.LayoutControlItem layoutControlItem6; private DevExpress.XtraEditors.MemoEdit txtDescription; private DevExpress.XtraLayout.LayoutControlItem layoutControlItem7; private SetFlagsEditCtrl setFlagsEditCtrl1; private DevExpress.XtraLayout.LayoutControlItem layoutControlItem5; } } WinFrmUI/HStation.WinFrmUI.Xhs.Core/02-project/01-import/02-ProjectInfo/InputXhsProjectInfoWizardPage.cs
@@ -1,5 +1,4 @@  namespace HStation.WinFrmUI namespace HStation.WinFrmUI { public partial class InputXhsProjectInfoWizardPage : DevExpress.XtraEditors.XtraUserControl, Yw.WinFrmUI.IWizardPage<ImportXhsProjectViewModel> { @@ -8,50 +7,55 @@ InitializeComponent(); } private ImportXhsProjectViewModel _vm = null; /// <summary> /// 页é¢ç¶ææ¹åäºä»¶ /// </summary> public event Action PageStateChangedEvent; private ImportXhsProjectViewModel _vm = null;//æä½å¯¹è±¡ private bool _isInitialize = false;//æ¯å¦åå§å private Lazy<HStation.BLL.XhsProject> _bllProject = new(() => new HStation.BLL.XhsProject());//项ç®bll private Lazy<Yw.BLL.SysFlagStd> _bllFlag = new(() => new Yw.BLL.SysFlagStd());//æ ç¾bll /// <summary> /// åå§å /// </summary> public void InitialPage(ImportXhsProjectViewModel t) public async void InitialPage(ImportXhsProjectViewModel t) { if (_isInitialize) { return; } _vm = t; var allFlagList = await _bllFlag.Value.GetFlagListBySysType(HStation.Xhs.DataType.XhsProject); this.setFlagsEditCtrl1.SetBindingData(allFlagList, null); _isInitialize = true; } /// <summary> /// æ¯å¦åå§å /// </summary> public bool IsInitialize { get { return _isInitialize; } } private bool _isInitialize = false; public event Action PageStateChangedEvent; /// <summary> /// æ¯å¦å 许ä¸ä¸æ¥ /// å 许ä¸ä¸æ¥ /// </summary> public bool AllowPrev { get { return true; } get { return true; } } /// <summary> /// æ¯å¦å 许ä¸ä¸æ¥ /// å 许ä¸ä¸æ¥ /// </summary> public bool AllowNext { get { return true; } get { return _isInitialize; } } /// <summary> /// æ¯å¦å è®¸åæ¶ /// å è®¸åæ¶ /// </summary> public bool AllowCancel { @@ -59,7 +63,7 @@ } /// <summary> /// æ¯å¦å è®¸å®æ /// å è®¸å®æ /// </summary> public bool AllowComplete { @@ -67,7 +71,7 @@ } /// <summary> /// è½å¦è¿åä¸ä¸æ¥ /// è½å¦ä¸ä¸æ¥ /// </summary> public bool CanPrev() { @@ -75,22 +79,35 @@ } /// <summary> /// è½å¦è¿å ¥ä¸ä¸æ¥ /// è½å¦ä¸ä¸æ¥ /// </summary> public bool CanNext() { if (!_isInitialize) { return false; } this.dxErrorProvider1.ClearErrors(); if (string.IsNullOrEmpty(this.txtName.Text.Trim())) { this.dxErrorProvider1.SetError(this.txtName, "å¿ å¡«é¡¹"); return false; } var tagName = this.txtTagNme.Text.Trim(); if (!string.IsNullOrEmpty(tagName)) { if (_bllProject.Value.IsExistTagName(tagName).Result) { this.dxErrorProvider1.SetError(this.txtTagNme, "æ è®°å·²åå¨"); return false; } } _vm.NO = this.txtNO.Text.Trim(); _vm.Name = this.txtName.Text.Trim(); _vm.Customer = this.txtCustomer.Text.Trim(); _vm.Address = this.txtAddress.Text.Trim(); _vm.Flags = null; _vm.TagName = this.txtTagNme.Text.Trim(); _vm.TagName = tagName; _vm.Description = this.txtDescription.Text.Trim(); return true; } WinFrmUI/HStation.WinFrmUI.Xhs.Core/HStation.WinFrmUI.Xhs.Core.csproj
@@ -42,6 +42,7 @@ <ItemGroup> <PackageReference Include="DevExpress.Win.Design" Version="23.2.4" /> <PackageReference Include="Yw.BLL.Basic.Core" Version="3.2.0" /> <PackageReference Include="Yw.ZipFile.Core" Version="3.0.0" /> </ItemGroup> WinFrmUI/Yw.WinFrmUI.Core/08-wizard/WizardManager.cs
@@ -43,8 +43,8 @@ }; } _selectedIndex = 0; TriggerSelectedPageChangedEvent(); this.SelectedPage.InitialPage(_vm); TriggerSelectedPageChangedEvent(); } else { @@ -119,8 +119,8 @@ if (this.SelectedPage.CanPrev()) { --_selectedIndex; TriggerSelectedPageChangedEvent(); this.SelectedPage.InitialPage(_vm); TriggerSelectedPageChangedEvent(); return true; } return false; @@ -142,8 +142,8 @@ if (this.SelectedPage.CanNext()) { ++_selectedIndex; TriggerSelectedPageChangedEvent(); this.SelectedPage.InitialPage(_vm); TriggerSelectedPageChangedEvent(); return true; } return false; WinFrmUI/Yw.WinFrmUI.Core/09-common/01-flags/SetFlagsContainerCtrl.Designer.cs
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,174 @@ namespace Yw.WinFrmUI { partial class SetFlagsContainerCtrl { /// <summary> /// Required designer variable. /// </summary> private System.ComponentModel.IContainer components = null; /// <summary> /// Clean up any resources being used. /// </summary> /// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param> protected override void Dispose(bool disposing) { if (disposing && (components != null)) { components.Dispose(); } base.Dispose(disposing); } #region Component Designer generated code /// <summary> /// Required method for Designer support - do not modify /// the contents of this method with the code editor. /// </summary> private void InitializeComponent() { layoutControl1 = new LayoutControl(); stringListCheckedListBoxCtrl1 = new StringListCheckedListBoxCtrl(); Root = new LayoutControlGroup(); layoutControlItem1 = new LayoutControlItem(); btnOk = new SimpleButton(); itemForOk = new LayoutControlItem(); btnCancel = new SimpleButton(); itemForCancel = new LayoutControlItem(); emptySpaceItem1 = new EmptySpaceItem(); ((ISupportInitialize)layoutControl1).BeginInit(); layoutControl1.SuspendLayout(); ((ISupportInitialize)Root).BeginInit(); ((ISupportInitialize)layoutControlItem1).BeginInit(); ((ISupportInitialize)itemForOk).BeginInit(); ((ISupportInitialize)itemForCancel).BeginInit(); ((ISupportInitialize)emptySpaceItem1).BeginInit(); SuspendLayout(); // // layoutControl1 // layoutControl1.Controls.Add(btnCancel); layoutControl1.Controls.Add(btnOk); layoutControl1.Controls.Add(stringListCheckedListBoxCtrl1); layoutControl1.Dock = DockStyle.Fill; layoutControl1.Location = new Point(0, 0); layoutControl1.Name = "layoutControl1"; layoutControl1.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new Rectangle(941, 111, 650, 400); layoutControl1.Root = Root; layoutControl1.Size = new Size(600, 400); layoutControl1.TabIndex = 0; layoutControl1.Text = "layoutControl1"; // // stringListCheckedListBoxCtrl1 // stringListCheckedListBoxCtrl1.Location = new Point(2, 2); stringListCheckedListBoxCtrl1.Name = "stringListCheckedListBoxCtrl1"; stringListCheckedListBoxCtrl1.Size = new Size(596, 370); stringListCheckedListBoxCtrl1.TabIndex = 4; // // Root // Root.EnableIndentsWithoutBorders = DefaultBoolean.True; Root.GroupBordersVisible = false; Root.Items.AddRange(new BaseLayoutItem[] { layoutControlItem1, itemForOk, itemForCancel, emptySpaceItem1 }); Root.Name = "Root"; Root.Padding = new DevExpress.XtraLayout.Utils.Padding(0, 0, 0, 0); Root.Size = new Size(600, 400); Root.TextVisible = false; // // layoutControlItem1 // layoutControlItem1.Control = stringListCheckedListBoxCtrl1; layoutControlItem1.Location = new Point(0, 0); layoutControlItem1.Name = "layoutControlItem1"; layoutControlItem1.Size = new Size(600, 374); layoutControlItem1.TextSize = new Size(0, 0); layoutControlItem1.TextVisible = false; // // btnOk // btnOk.Appearance.BackColor = DevExpress.LookAndFeel.DXSkinColors.FillColors.Primary; btnOk.Appearance.Options.UseBackColor = true; btnOk.Location = new Point(512, 376); btnOk.Name = "btnOk"; btnOk.Size = new Size(86, 22); btnOk.StyleController = layoutControl1; btnOk.TabIndex = 5; btnOk.Text = "ç¡®å®"; btnOk.Click += btnOk_Click; // // itemForOk // itemForOk.Control = btnOk; itemForOk.Location = new Point(510, 374); itemForOk.MaxSize = new Size(90, 26); itemForOk.MinSize = new Size(90, 26); itemForOk.Name = "itemForOk"; itemForOk.Size = new Size(90, 26); itemForOk.SizeConstraintsType = SizeConstraintsType.Custom; itemForOk.TextSize = new Size(0, 0); itemForOk.TextVisible = false; // // btnCancel // btnCancel.Appearance.BackColor = DevExpress.LookAndFeel.DXSkinColors.FillColors.Warning; btnCancel.Appearance.Options.UseBackColor = true; btnCancel.Location = new Point(422, 376); btnCancel.Name = "btnCancel"; btnCancel.Size = new Size(86, 22); btnCancel.StyleController = layoutControl1; btnCancel.TabIndex = 6; btnCancel.Text = "åæ¶"; btnCancel.Click += btnCancel_Click; // // itemForCancel // itemForCancel.Control = btnCancel; itemForCancel.Location = new Point(420, 374); itemForCancel.MaxSize = new Size(90, 26); itemForCancel.MinSize = new Size(90, 26); itemForCancel.Name = "itemForCancel"; itemForCancel.Size = new Size(90, 26); itemForCancel.SizeConstraintsType = SizeConstraintsType.Custom; itemForCancel.TextSize = new Size(0, 0); itemForCancel.TextVisible = false; // // emptySpaceItem1 // emptySpaceItem1.AllowHotTrack = false; emptySpaceItem1.Location = new Point(0, 374); emptySpaceItem1.Name = "emptySpaceItem1"; emptySpaceItem1.Size = new Size(420, 26); emptySpaceItem1.TextSize = new Size(0, 0); // // SetFlagsContainerCtrl // AutoScaleDimensions = new SizeF(7F, 14F); AutoScaleMode = AutoScaleMode.Font; Controls.Add(layoutControl1); Name = "SetFlagsContainerCtrl"; Size = new Size(600, 400); ((ISupportInitialize)layoutControl1).EndInit(); layoutControl1.ResumeLayout(false); ((ISupportInitialize)Root).EndInit(); ((ISupportInitialize)layoutControlItem1).EndInit(); ((ISupportInitialize)itemForOk).EndInit(); ((ISupportInitialize)itemForCancel).EndInit(); ((ISupportInitialize)emptySpaceItem1).EndInit(); ResumeLayout(false); } #endregion private LayoutControl layoutControl1; private LayoutControlGroup Root; private StringListCheckedListBoxCtrl stringListCheckedListBoxCtrl1; private LayoutControlItem layoutControlItem1; private SimpleButton btnCancel; private SimpleButton btnOk; private LayoutControlItem itemForOk; private LayoutControlItem itemForCancel; private EmptySpaceItem emptySpaceItem1; } } WinFrmUI/Yw.WinFrmUI.Core/09-common/01-flags/SetFlagsContainerCtrl.cs
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,50 @@ namespace Yw.WinFrmUI { /// <summary> /// /// </summary> public partial class SetFlagsContainerCtrl : DevExpress.XtraEditors.XtraUserControl { /// <summary> /// /// </summary> public SetFlagsContainerCtrl() { InitializeComponent(); } /// <summary> /// ç¡®å®äºä»¶ /// </summary> public event Action<List<string>> OkEvent; /// <summary> /// åæ¶äºä»¶ /// </summary> public event Action CancelEvent; /// <summary> /// ç»å®æ°æ® /// </summary> /// <param name="allFlagList">æææ ç¾å表</param> /// <param name="selectedFlagList">éæ©çæ ç¾å表</param> public void SetBindingData(List<string> allFlagList, List<string> selectedFlagList) { this.stringListCheckedListBoxCtrl1.Initial(allFlagList); this.stringListCheckedListBoxCtrl1.Select(selectedFlagList); } //ç¡®å® private void btnOk_Click(object sender, EventArgs e) { var selectedFlagList = this.stringListCheckedListBoxCtrl1.Get(); this.OkEvent?.Invoke(selectedFlagList); } //åæ¶ private void btnCancel_Click(object sender, EventArgs e) { this.CancelEvent?.Invoke(); } } } WinFrmUI/Yw.WinFrmUI.Core/09-common/01-flags/SetFlagsContainerCtrl.resx
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,120 @@ <?xml version="1.0" encoding="utf-8"?> <root> <!-- Microsoft ResX Schema Version 2.0 The primary goals of this format is to allow a simple XML format that is mostly human readable. The generation and parsing of the various data types are done through the TypeConverter classes associated with the data types. Example: ... ado.net/XML headers & schema ... <resheader name="resmimetype">text/microsoft-resx</resheader> <resheader name="version">2.0</resheader> <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader> <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader> <data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data> <data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data> <data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64"> <value>[base64 mime encoded serialized .NET Framework object]</value> </data> <data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64"> <value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value> <comment>This is a comment</comment> </data> There are any number of "resheader" rows that contain simple name/value pairs. Each data row contains a name, and value. The row also contains a type or mimetype. Type corresponds to a .NET class that support text/value conversion through the TypeConverter architecture. Classes that don't support this are serialized and stored with the mimetype set. The mimetype is used for serialized objects, and tells the ResXResourceReader how to depersist the object. This is currently not extensible. For a given mimetype the value must be set accordingly: Note - application/x-microsoft.net.object.binary.base64 is the format that the ResXResourceWriter will generate, however the reader can read any of the formats listed below. mimetype: application/x-microsoft.net.object.binary.base64 value : The object must be serialized with : System.Runtime.Serialization.Formatters.Binary.BinaryFormatter : and then encoded with base64 encoding. mimetype: application/x-microsoft.net.object.soap.base64 value : The object must be serialized with : System.Runtime.Serialization.Formatters.Soap.SoapFormatter : and then encoded with base64 encoding. mimetype: application/x-microsoft.net.object.bytearray.base64 value : The object must be serialized into a byte array : using a System.ComponentModel.TypeConverter : and then encoded with base64 encoding. --> <xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata"> <xsd:import namespace="http://www.w3.org/XML/1998/namespace" /> <xsd:element name="root" msdata:IsDataSet="true"> <xsd:complexType> <xsd:choice maxOccurs="unbounded"> <xsd:element name="metadata"> <xsd:complexType> <xsd:sequence> <xsd:element name="value" type="xsd:string" minOccurs="0" /> </xsd:sequence> <xsd:attribute name="name" use="required" type="xsd:string" /> <xsd:attribute name="type" type="xsd:string" /> <xsd:attribute name="mimetype" type="xsd:string" /> <xsd:attribute ref="xml:space" /> </xsd:complexType> </xsd:element> <xsd:element name="assembly"> <xsd:complexType> <xsd:attribute name="alias" type="xsd:string" /> <xsd:attribute name="name" type="xsd:string" /> </xsd:complexType> </xsd:element> <xsd:element name="data"> <xsd:complexType> <xsd:sequence> <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" /> <xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" /> </xsd:sequence> <xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" /> <xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" /> <xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" /> <xsd:attribute ref="xml:space" /> </xsd:complexType> </xsd:element> <xsd:element name="resheader"> <xsd:complexType> <xsd:sequence> <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" /> </xsd:sequence> <xsd:attribute name="name" type="xsd:string" use="required" /> </xsd:complexType> </xsd:element> </xsd:choice> </xsd:complexType> </xsd:element> </xsd:schema> <resheader name="resmimetype"> <value>text/microsoft-resx</value> </resheader> <resheader name="version"> <value>2.0</value> </resheader> <resheader name="reader"> <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> </resheader> <resheader name="writer"> <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> </resheader> </root> WinFrmUI/Yw.WinFrmUI.Core/09-common/01-flags/SetFlagsEditCtrl.Designer.cs
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,62 @@ namespace Yw.WinFrmUI { partial class SetFlagsEditCtrl { /// <summary> /// Required designer variable. /// </summary> private System.ComponentModel.IContainer components = null; /// <summary> /// Clean up any resources being used. /// </summary> /// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param> protected override void Dispose(bool disposing) { if (disposing && (components != null)) { components.Dispose(); } base.Dispose(disposing); } #region Component Designer generated code /// <summary> /// Required method for Designer support - do not modify /// the contents of this method with the code editor. /// </summary> private void InitializeComponent() { popupContainerEdit1 = new PopupContainerEdit(); ((ISupportInitialize)popupContainerEdit1.Properties).BeginInit(); SuspendLayout(); // // popupContainerEdit1 // popupContainerEdit1.Dock = DockStyle.Fill; popupContainerEdit1.Location = new Point(0, 0); popupContainerEdit1.Name = "popupContainerEdit1"; popupContainerEdit1.Properties.AutoHeight = false; popupContainerEdit1.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] { new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo) }); popupContainerEdit1.Properties.ShowPopupCloseButton = false; popupContainerEdit1.Properties.ShowPopupShadow = false; popupContainerEdit1.Size = new Size(299, 27); popupContainerEdit1.TabIndex = 0; // // SetFlagsEditCtrl // AutoScaleDimensions = new SizeF(7F, 14F); AutoScaleMode = AutoScaleMode.Font; Controls.Add(popupContainerEdit1); Name = "SetFlagsEditCtrl"; Size = new Size(299, 27); ((ISupportInitialize)popupContainerEdit1.Properties).EndInit(); ResumeLayout(false); } #endregion private PopupContainerEdit popupContainerEdit1; } } WinFrmUI/Yw.WinFrmUI.Core/09-common/01-flags/SetFlagsEditCtrl.cs
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,57 @@ namespace Yw.WinFrmUI { /// <summary> /// /// </summary> public partial class SetFlagsEditCtrl : DevExpress.XtraEditors.XtraUserControl { /// <summary> /// /// </summary> public SetFlagsEditCtrl() { InitializeComponent(); } private SetFlagsContainerCtrl _container = null;//å®¹å¨ private List<string> _selectedFlagList = null; /// <summary> /// ç»å®æ°æ® /// </summary> public void SetBindingData(List<string> allFlagList, List<string> selectedFlagList) { if (_container == null) { _container = new SetFlagsContainerCtrl(); _container.Dock = DockStyle.Fill; var container = new PopupContainerControl(); container.Controls.Add(_container); this.popupContainerEdit1.Properties.PopupControl = container; _container.OkEvent += (flagList) => { _selectedFlagList = flagList; this.popupContainerEdit1.Text = Yw.Untity.FlagsHelper.ToString(flagList); this.popupContainerEdit1.ClosePopup(); }; _container.CancelEvent += () => { this.popupContainerEdit1.ClosePopup(); }; } _container.SetBindingData(allFlagList, selectedFlagList); _selectedFlagList = selectedFlagList; this.popupContainerEdit1.Text = Yw.Untity.FlagsHelper.ToString(selectedFlagList); } /// <summary> /// éæ©æ ç¾å表 /// </summary> public List<string> SelectedFlagList { get { return _selectedFlagList; } } } } WinFrmUI/Yw.WinFrmUI.Core/09-common/01-flags/SetFlagsEditCtrl.resx
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,120 @@ <?xml version="1.0" encoding="utf-8"?> <root> <!-- Microsoft ResX Schema Version 2.0 The primary goals of this format is to allow a simple XML format that is mostly human readable. The generation and parsing of the various data types are done through the TypeConverter classes associated with the data types. Example: ... ado.net/XML headers & schema ... <resheader name="resmimetype">text/microsoft-resx</resheader> <resheader name="version">2.0</resheader> <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader> <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader> <data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data> <data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data> <data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64"> <value>[base64 mime encoded serialized .NET Framework object]</value> </data> <data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64"> <value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value> <comment>This is a comment</comment> </data> There are any number of "resheader" rows that contain simple name/value pairs. Each data row contains a name, and value. The row also contains a type or mimetype. Type corresponds to a .NET class that support text/value conversion through the TypeConverter architecture. Classes that don't support this are serialized and stored with the mimetype set. The mimetype is used for serialized objects, and tells the ResXResourceReader how to depersist the object. This is currently not extensible. For a given mimetype the value must be set accordingly: Note - application/x-microsoft.net.object.binary.base64 is the format that the ResXResourceWriter will generate, however the reader can read any of the formats listed below. mimetype: application/x-microsoft.net.object.binary.base64 value : The object must be serialized with : System.Runtime.Serialization.Formatters.Binary.BinaryFormatter : and then encoded with base64 encoding. mimetype: application/x-microsoft.net.object.soap.base64 value : The object must be serialized with : System.Runtime.Serialization.Formatters.Soap.SoapFormatter : and then encoded with base64 encoding. mimetype: application/x-microsoft.net.object.bytearray.base64 value : The object must be serialized into a byte array : using a System.ComponentModel.TypeConverter : and then encoded with base64 encoding. --> <xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata"> <xsd:import namespace="http://www.w3.org/XML/1998/namespace" /> <xsd:element name="root" msdata:IsDataSet="true"> <xsd:complexType> <xsd:choice maxOccurs="unbounded"> <xsd:element name="metadata"> <xsd:complexType> <xsd:sequence> <xsd:element name="value" type="xsd:string" minOccurs="0" /> </xsd:sequence> <xsd:attribute name="name" use="required" type="xsd:string" /> <xsd:attribute name="type" type="xsd:string" /> <xsd:attribute name="mimetype" type="xsd:string" /> <xsd:attribute ref="xml:space" /> </xsd:complexType> </xsd:element> <xsd:element name="assembly"> <xsd:complexType> <xsd:attribute name="alias" type="xsd:string" /> <xsd:attribute name="name" type="xsd:string" /> </xsd:complexType> </xsd:element> <xsd:element name="data"> <xsd:complexType> <xsd:sequence> <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" /> <xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" /> </xsd:sequence> <xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" /> <xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" /> <xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" /> <xsd:attribute ref="xml:space" /> </xsd:complexType> </xsd:element> <xsd:element name="resheader"> <xsd:complexType> <xsd:sequence> <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" /> </xsd:sequence> <xsd:attribute name="name" type="xsd:string" use="required" /> </xsd:complexType> </xsd:element> </xsd:choice> </xsd:complexType> </xsd:element> </xsd:schema> <resheader name="resmimetype"> <value>text/microsoft-resx</value> </resheader> <resheader name="version"> <value>2.0</value> </resheader> <resheader name="reader"> <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> </resheader> <resheader name="writer"> <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> </resheader> </root> WinFrmUI/Yw.WinFrmUI.Core/09-common/StringListCheckedListBoxCtrl.Designer.cs
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,61 @@ namespace Yw.WinFrmUI { partial class StringListCheckedListBoxCtrl { /// <summary> /// Required designer variable. /// </summary> private System.ComponentModel.IContainer components = null; /// <summary> /// Clean up any resources being used. /// </summary> /// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param> protected override void Dispose(bool disposing) { if (disposing && (components != null)) { components.Dispose(); } base.Dispose(disposing); } #region Component Designer generated code /// <summary> /// Required method for Designer support - do not modify /// the contents of this method with the code editor. /// </summary> private void InitializeComponent() { ckListBox = new CheckedListBoxControl(); ((ISupportInitialize)ckListBox).BeginInit(); SuspendLayout(); // // ckListBox // ckListBox.Dock = DockStyle.Fill; ckListBox.Location = new Point(0, 0); ckListBox.MultiColumn = true; ckListBox.Name = "ckListBox"; ckListBox.SelectionMode = SelectionMode.None; ckListBox.ShowFocusRect = false; ckListBox.Size = new Size(403, 253); ckListBox.TabIndex = 0; // // StringListCheckedListBoxCtrl // AutoScaleDimensions = new SizeF(7F, 14F); AutoScaleMode = AutoScaleMode.Font; Controls.Add(ckListBox); Name = "StringListCheckedListBoxCtrl"; Size = new Size(403, 253); ((ISupportInitialize)ckListBox).EndInit(); ResumeLayout(false); } #endregion private CheckedListBoxControl ckListBox; } } WinFrmUI/Yw.WinFrmUI.Core/09-common/StringListCheckedListBoxCtrl.cs
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,92 @@ using DevExpress.Xpo.Helpers; using DevExpress.XtraEditors; using DevExpress.XtraEditors.Controls; using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows.Forms; namespace Yw.WinFrmUI { /// <summary> /// /// </summary> public partial class StringListCheckedListBoxCtrl : DevExpress.XtraEditors.XtraUserControl { /// <summary> /// /// </summary> public StringListCheckedListBoxCtrl() { InitializeComponent(); } /// <summary> /// åå§å /// </summary> public void Initial(List<string> strList) { this.ckListBox.BeginUpdate(); this.ckListBox.Items.Clear(); strList?.ForEach(x => CreateItem(x)); this.ckListBox.EndUpdate(); } /// <summary> /// éæ© /// </summary> public void Select(List<string> strList) { foreach (CheckedListBoxItem item in this.ckListBox.Items) { if (strList != null && strList.Count > 0) { if (strList.Contains(item.Value.ToString())) { item.CheckState = CheckState.Checked; } else { item.CheckState = CheckState.Unchecked; } } } } /// <summary> /// è·å /// </summary> public List<string> Get() { var list = new List<string>(); foreach (CheckedListBoxItem item in this.ckListBox.Items) { if (item.CheckState == CheckState.Checked) { var str = item.Value.ToString(); list.Add(str); } } return list; } //å建项 private void CreateItem(string str) { var item = new CheckedListBoxItem(); item.Description = str; item.Value = str; item.Tag = str; item.CheckState = CheckState.Unchecked; this.ckListBox.Items.Add(item); } } } WinFrmUI/Yw.WinFrmUI.Core/09-common/StringListCheckedListBoxCtrl.resx
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,120 @@ <?xml version="1.0" encoding="utf-8"?> <root> <!-- Microsoft ResX Schema Version 2.0 The primary goals of this format is to allow a simple XML format that is mostly human readable. The generation and parsing of the various data types are done through the TypeConverter classes associated with the data types. Example: ... ado.net/XML headers & schema ... <resheader name="resmimetype">text/microsoft-resx</resheader> <resheader name="version">2.0</resheader> <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader> <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader> <data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data> <data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data> <data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64"> <value>[base64 mime encoded serialized .NET Framework object]</value> </data> <data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64"> <value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value> <comment>This is a comment</comment> </data> There are any number of "resheader" rows that contain simple name/value pairs. Each data row contains a name, and value. The row also contains a type or mimetype. Type corresponds to a .NET class that support text/value conversion through the TypeConverter architecture. Classes that don't support this are serialized and stored with the mimetype set. The mimetype is used for serialized objects, and tells the ResXResourceReader how to depersist the object. This is currently not extensible. For a given mimetype the value must be set accordingly: Note - application/x-microsoft.net.object.binary.base64 is the format that the ResXResourceWriter will generate, however the reader can read any of the formats listed below. mimetype: application/x-microsoft.net.object.binary.base64 value : The object must be serialized with : System.Runtime.Serialization.Formatters.Binary.BinaryFormatter : and then encoded with base64 encoding. mimetype: application/x-microsoft.net.object.soap.base64 value : The object must be serialized with : System.Runtime.Serialization.Formatters.Soap.SoapFormatter : and then encoded with base64 encoding. mimetype: application/x-microsoft.net.object.bytearray.base64 value : The object must be serialized into a byte array : using a System.ComponentModel.TypeConverter : and then encoded with base64 encoding. --> <xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata"> <xsd:import namespace="http://www.w3.org/XML/1998/namespace" /> <xsd:element name="root" msdata:IsDataSet="true"> <xsd:complexType> <xsd:choice maxOccurs="unbounded"> <xsd:element name="metadata"> <xsd:complexType> <xsd:sequence> <xsd:element name="value" type="xsd:string" minOccurs="0" /> </xsd:sequence> <xsd:attribute name="name" use="required" type="xsd:string" /> <xsd:attribute name="type" type="xsd:string" /> <xsd:attribute name="mimetype" type="xsd:string" /> <xsd:attribute ref="xml:space" /> </xsd:complexType> </xsd:element> <xsd:element name="assembly"> <xsd:complexType> <xsd:attribute name="alias" type="xsd:string" /> <xsd:attribute name="name" type="xsd:string" /> </xsd:complexType> </xsd:element> <xsd:element name="data"> <xsd:complexType> <xsd:sequence> <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" /> <xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" /> </xsd:sequence> <xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" /> <xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" /> <xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" /> <xsd:attribute ref="xml:space" /> </xsd:complexType> </xsd:element> <xsd:element name="resheader"> <xsd:complexType> <xsd:sequence> <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" /> </xsd:sequence> <xsd:attribute name="name" type="xsd:string" use="required" /> </xsd:complexType> </xsd:element> </xsd:choice> </xsd:complexType> </xsd:element> </xsd:schema> <resheader name="resmimetype"> <value>text/microsoft-resx</value> </resheader> <resheader name="version"> <value>2.0</value> </resheader> <resheader name="reader"> <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> </resheader> <resheader name="writer"> <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> </resheader> </root> WinFrmUI/Yw.WinFrmUI.Core/Yw.WinFrmUI.Core.csproj
@@ -29,6 +29,7 @@ <ItemGroup> <PackageReference Include="DevExpress.Win.Design" Version="23.2.4" /> <PackageReference Include="Yw.Untity.Core" Version="3.0.0" /> </ItemGroup> <ItemGroup> WinFrmUI/Yw.WinFrmUI.Core/Yw.WinFrmUI.Core.csproj.user
@@ -7,5 +7,14 @@ <Compile Update="06-document\DocumentPage.cs"> <SubType>UserControl</SubType> </Compile> <Compile Update="09-common\01-flags\SetFlagsContainerCtrl.cs"> <SubType>UserControl</SubType> </Compile> <Compile Update="09-common\StringListCheckedListBoxCtrl.cs"> <SubType>UserControl</SubType> </Compile> <Compile Update="09-common\01-flags\SetFlagsEditCtrl.cs"> <SubType>UserControl</SubType> </Compile> </ItemGroup> </Project>