Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
刘韬
/
HZH_Controls
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit 800e772d
由
HZH
编写于
2019-10-10 11:16:44 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
新增穿梭
1 个父辈
a2e5cc9b
显示空白字符变更
内嵌
并排
正在显示
12 个修改的文件
包含
891 行增加
和
2 行删除
HZH_Controls/HZH_Controls/Controls/DataGridView/UCDataGridView.cs
HZH_Controls/HZH_Controls/Controls/DataGridView/UCDataGridViewRow.cs
HZH_Controls/HZH_Controls/Controls/Transfer/TransferEventArgs.cs
HZH_Controls/HZH_Controls/Controls/Transfer/UCTransfer.Designer.cs
HZH_Controls/HZH_Controls/Controls/Transfer/UCTransfer.cs
HZH_Controls/HZH_Controls/Controls/Transfer/UCTransfer.resx
HZH_Controls/HZH_Controls/HZH_Controls.csproj
HZH_Controls/Test/FrmMain.cs
HZH_Controls/Test/Test.csproj
HZH_Controls/Test/UC/UCTestTransfer.Designer.cs
HZH_Controls/Test/UC/UCTestTransfer.cs
HZH_Controls/Test/UC/UCTestTransfer.resx
HZH_Controls/HZH_Controls/Controls/DataGridView/UCDataGridView.cs
查看文件 @
800e772
...
...
@@ -337,6 +337,7 @@ namespace HZH_Controls.Controls
{
Control
c
=
row
as
Control
;
UCDataGridView
grid
=
FindChildGrid
(
c
);
if
(
grid
!=
null
)
lst
.
AddRange
(
grid
.
SelectRows
);
}
}
...
...
@@ -579,7 +580,7 @@ namespace HZH_Controls.Controls
try
{
ControlHelper
.
FreezeControl
(
this
.
panRow
,
true
);
this
.
panRow
.
Controls
.
Clear
();
//
this.panRow.Controls.Clear();
Rows
=
new
List
<
IDataGridViewRow
>();
if
(
m_columns
==
null
||
m_columns
.
Count
<=
0
)
return
;
...
...
HZH_Controls/HZH_Controls/Controls/DataGridView/UCDataGridViewRow.cs
查看文件 @
800e772
...
...
@@ -144,6 +144,8 @@ namespace HZH_Controls.Controls
/// <returns>返回true则表示已处理过,否则将进行默认绑定(通常只针对有Text值的控件)</returns>
public
void
BindingCellData
()
{
if
(
DataSource
!=
null
)
{
for
(
int
i
=
0
;
i
<
Columns
.
Count
;
i
++)
{
DataGridViewColumnEntity
com
=
Columns
[
i
];
...
...
@@ -166,6 +168,7 @@ namespace HZH_Controls.Controls
}
}
}
}
/// <summary>
/// Handles the MouseDown event of the Item control.
...
...
HZH_Controls/HZH_Controls/Controls/Transfer/TransferEventArgs.cs
0 → 100644
查看文件 @
800e772
using
System
;
using
System.Collections.Generic
;
using
System.Linq
;
using
System.Text
;
namespace
HZH_Controls.Controls
{
public
class
TransferEventArgs
:
EventArgs
{
public
object
[]
TransferDataSource
{
get
;
set
;
}
/// <summary>
/// true:right false:left
/// </summary>
/// <value><c>true</c> if [to right or left]; otherwise, <c>false</c>.</value>
public
bool
ToRightOrLeft
{
get
;
set
;
}
}
public
delegate
void
TransferEventHandler
(
object
sender
,
TransferEventArgs
e
);
}
HZH_Controls/HZH_Controls/Controls/Transfer/UCTransfer.Designer.cs
0 → 100644
查看文件 @
800e772
namespace
HZH_Controls.Controls
{
partial
class
UCTransfer
{
/// <summary>
/// 必需的设计器变量。
/// </summary>
private
System
.
ComponentModel
.
IContainer
components
=
null
;
/// <summary>
/// 清理所有正在使用的资源。
/// </summary>
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
protected
override
void
Dispose
(
bool
disposing
)
{
if
(
disposing
&&
(
components
!=
null
))
{
components
.
Dispose
();
}
base
.
Dispose
(
disposing
);
}
#
region
组件设计器生成的代码
/// <summary>
/// 设计器支持所需的方法 - 不要
/// 使用代码编辑器修改此方法的内容。
/// </summary>
private
void
InitializeComponent
()
{
System
.
ComponentModel
.
ComponentResourceManager
resources
=
new
System
.
ComponentModel
.
ComponentResourceManager
(
typeof
(
UCTransfer
));
this
.
tableLayoutPanel1
=
new
System
.
Windows
.
Forms
.
TableLayoutPanel
();
this
.
panel1
=
new
System
.
Windows
.
Forms
.
Panel
();
this
.
ucControlBase2
=
new
HZH_Controls
.
Controls
.
UCControlBase
();
this
.
dgvRight
=
new
HZH_Controls
.
Controls
.
UCDataGridView
();
this
.
btnLeft
=
new
HZH_Controls
.
Controls
.
UCBtnImg
();
this
.
btnRight
=
new
HZH_Controls
.
Controls
.
UCBtnImg
();
this
.
ucControlBase1
=
new
HZH_Controls
.
Controls
.
UCControlBase
();
this
.
dgvLeft
=
new
HZH_Controls
.
Controls
.
UCDataGridView
();
this
.
tableLayoutPanel1
.
SuspendLayout
();
this
.
panel1
.
SuspendLayout
();
this
.
ucControlBase2
.
SuspendLayout
();
this
.
ucControlBase1
.
SuspendLayout
();
this
.
SuspendLayout
();
//
// tableLayoutPanel1
//
this
.
tableLayoutPanel1
.
ColumnCount
=
3
;
this
.
tableLayoutPanel1
.
ColumnStyles
.
Add
(
new
System
.
Windows
.
Forms
.
ColumnStyle
(
System
.
Windows
.
Forms
.
SizeType
.
Percent
,
50F
));
this
.
tableLayoutPanel1
.
ColumnStyles
.
Add
(
new
System
.
Windows
.
Forms
.
ColumnStyle
(
System
.
Windows
.
Forms
.
SizeType
.
Absolute
,
60F
));
this
.
tableLayoutPanel1
.
ColumnStyles
.
Add
(
new
System
.
Windows
.
Forms
.
ColumnStyle
(
System
.
Windows
.
Forms
.
SizeType
.
Percent
,
50F
));
this
.
tableLayoutPanel1
.
Controls
.
Add
(
this
.
ucControlBase2
,
2
,
0
);
this
.
tableLayoutPanel1
.
Controls
.
Add
(
this
.
panel1
,
1
,
0
);
this
.
tableLayoutPanel1
.
Controls
.
Add
(
this
.
ucControlBase1
,
0
,
0
);
this
.
tableLayoutPanel1
.
Dock
=
System
.
Windows
.
Forms
.
DockStyle
.
Fill
;
this
.
tableLayoutPanel1
.
Location
=
new
System
.
Drawing
.
Point
(
0
,
0
);
this
.
tableLayoutPanel1
.
Name
=
"tableLayoutPanel1"
;
this
.
tableLayoutPanel1
.
RowCount
=
1
;
this
.
tableLayoutPanel1
.
RowStyles
.
Add
(
new
System
.
Windows
.
Forms
.
RowStyle
(
System
.
Windows
.
Forms
.
SizeType
.
Percent
,
100F
));
this
.
tableLayoutPanel1
.
Size
=
new
System
.
Drawing
.
Size
(
451
,
397
);
this
.
tableLayoutPanel1
.
TabIndex
=
0
;
//
// panel1
//
this
.
panel1
.
Controls
.
Add
(
this
.
btnLeft
);
this
.
panel1
.
Controls
.
Add
(
this
.
btnRight
);
this
.
panel1
.
Dock
=
System
.
Windows
.
Forms
.
DockStyle
.
Fill
;
this
.
panel1
.
Location
=
new
System
.
Drawing
.
Point
(
198
,
3
);
this
.
panel1
.
Name
=
"panel1"
;
this
.
panel1
.
Size
=
new
System
.
Drawing
.
Size
(
54
,
391
);
this
.
panel1
.
TabIndex
=
0
;
//
// ucControlBase2
//
this
.
ucControlBase2
.
BackColor
=
System
.
Drawing
.
Color
.
Transparent
;
this
.
ucControlBase2
.
ConerRadius
=
5
;
this
.
ucControlBase2
.
Controls
.
Add
(
this
.
dgvRight
);
this
.
ucControlBase2
.
Dock
=
System
.
Windows
.
Forms
.
DockStyle
.
Fill
;
this
.
ucControlBase2
.
FillColor
=
System
.
Drawing
.
Color
.
Transparent
;
this
.
ucControlBase2
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
15F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Pixel
);
this
.
ucControlBase2
.
IsRadius
=
true
;
this
.
ucControlBase2
.
IsShowRect
=
true
;
this
.
ucControlBase2
.
Location
=
new
System
.
Drawing
.
Point
(
255
,
0
);
this
.
ucControlBase2
.
Margin
=
new
System
.
Windows
.
Forms
.
Padding
(
0
);
this
.
ucControlBase2
.
Name
=
"ucControlBase2"
;
this
.
ucControlBase2
.
Padding
=
new
System
.
Windows
.
Forms
.
Padding
(
1
);
this
.
ucControlBase2
.
RectColor
=
System
.
Drawing
.
Color
.
FromArgb
(((
int
)(((
byte
)(
220
)))),
((
int
)(((
byte
)(
220
)))),
((
int
)(((
byte
)(
220
)))));
this
.
ucControlBase2
.
RectWidth
=
1
;
this
.
ucControlBase2
.
Size
=
new
System
.
Drawing
.
Size
(
196
,
397
);
this
.
ucControlBase2
.
TabIndex
=
4
;
//
// dgvRight
//
this
.
dgvRight
.
AutoRowsScroll
=
true
;
this
.
dgvRight
.
BackColor
=
System
.
Drawing
.
Color
.
White
;
this
.
dgvRight
.
Columns
=
null
;
this
.
dgvRight
.
DataSource
=
null
;
this
.
dgvRight
.
Dock
=
System
.
Windows
.
Forms
.
DockStyle
.
Fill
;
this
.
dgvRight
.
HeadFont
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
12F
);
this
.
dgvRight
.
HeadHeight
=
40
;
this
.
dgvRight
.
HeadPadingLeft
=
0
;
this
.
dgvRight
.
HeadTextColor
=
System
.
Drawing
.
Color
.
Black
;
this
.
dgvRight
.
IsCloseAutoHeight
=
false
;
this
.
dgvRight
.
IsShowCheckBox
=
true
;
this
.
dgvRight
.
IsShowHead
=
true
;
this
.
dgvRight
.
Location
=
new
System
.
Drawing
.
Point
(
1
,
1
);
this
.
dgvRight
.
Name
=
"dgvRight"
;
this
.
dgvRight
.
Page
=
null
;
this
.
dgvRight
.
RowHeight
=
40
;
this
.
dgvRight
.
RowType
=
typeof
(
HZH_Controls
.
Controls
.
UCDataGridViewRow
);
this
.
dgvRight
.
Size
=
new
System
.
Drawing
.
Size
(
194
,
395
);
this
.
dgvRight
.
TabIndex
=
2
;
//
// btnLeft
//
this
.
btnLeft
.
Anchor
=
System
.
Windows
.
Forms
.
AnchorStyles
.
None
;
this
.
btnLeft
.
BackColor
=
System
.
Drawing
.
Color
.
White
;
this
.
btnLeft
.
BtnBackColor
=
System
.
Drawing
.
Color
.
White
;
this
.
btnLeft
.
BtnFont
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
17F
);
this
.
btnLeft
.
BtnForeColor
=
System
.
Drawing
.
Color
.
FromArgb
(((
int
)(((
byte
)(
102
)))),
((
int
)(((
byte
)(
102
)))),
((
int
)(((
byte
)(
102
)))));
this
.
btnLeft
.
BtnText
=
""
;
this
.
btnLeft
.
ConerRadius
=
5
;
this
.
btnLeft
.
Cursor
=
System
.
Windows
.
Forms
.
Cursors
.
Hand
;
this
.
btnLeft
.
FillColor
=
System
.
Drawing
.
Color
.
White
;
this
.
btnLeft
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
15F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Pixel
);
this
.
btnLeft
.
ForeColor
=
System
.
Drawing
.
Color
.
FromArgb
(((
int
)(((
byte
)(
102
)))),
((
int
)(((
byte
)(
102
)))),
((
int
)(((
byte
)(
102
)))));
this
.
btnLeft
.
Image
=
((
System
.
Drawing
.
Image
)(
resources
.
GetObject
(
"btnLeft.Image"
)));
this
.
btnLeft
.
ImageAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleCenter
;
this
.
btnLeft
.
ImageFontIcons
=
((
object
)(
resources
.
GetObject
(
"btnLeft.ImageFontIcons"
)));
this
.
btnLeft
.
IsRadius
=
true
;
this
.
btnLeft
.
IsShowRect
=
true
;
this
.
btnLeft
.
IsShowTips
=
false
;
this
.
btnLeft
.
Location
=
new
System
.
Drawing
.
Point
(
5
,
203
);
this
.
btnLeft
.
Margin
=
new
System
.
Windows
.
Forms
.
Padding
(
0
);
this
.
btnLeft
.
Name
=
"btnLeft"
;
this
.
btnLeft
.
RectColor
=
System
.
Drawing
.
Color
.
FromArgb
(((
int
)(((
byte
)(
224
)))),
((
int
)(((
byte
)(
224
)))),
((
int
)(((
byte
)(
224
)))));
this
.
btnLeft
.
RectWidth
=
1
;
this
.
btnLeft
.
Size
=
new
System
.
Drawing
.
Size
(
44
,
31
);
this
.
btnLeft
.
TabIndex
=
0
;
this
.
btnLeft
.
TabStop
=
false
;
this
.
btnLeft
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleCenter
;
this
.
btnLeft
.
TipsColor
=
System
.
Drawing
.
Color
.
FromArgb
(((
int
)(((
byte
)(
232
)))),
((
int
)(((
byte
)(
30
)))),
((
int
)(((
byte
)(
99
)))));
this
.
btnLeft
.
TipsText
=
""
;
this
.
btnLeft
.
BtnClick
+=
new
System
.
EventHandler
(
this
.
btnLeft_BtnClick
);
//
// btnRight
//
this
.
btnRight
.
Anchor
=
System
.
Windows
.
Forms
.
AnchorStyles
.
None
;
this
.
btnRight
.
BackColor
=
System
.
Drawing
.
Color
.
White
;
this
.
btnRight
.
BtnBackColor
=
System
.
Drawing
.
Color
.
White
;
this
.
btnRight
.
BtnFont
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
17F
);
this
.
btnRight
.
BtnForeColor
=
System
.
Drawing
.
Color
.
FromArgb
(((
int
)(((
byte
)(
102
)))),
((
int
)(((
byte
)(
102
)))),
((
int
)(((
byte
)(
102
)))));
this
.
btnRight
.
BtnText
=
""
;
this
.
btnRight
.
ConerRadius
=
5
;
this
.
btnRight
.
Cursor
=
System
.
Windows
.
Forms
.
Cursors
.
Hand
;
this
.
btnRight
.
FillColor
=
System
.
Drawing
.
Color
.
White
;
this
.
btnRight
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
15F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Pixel
);
this
.
btnRight
.
ForeColor
=
System
.
Drawing
.
Color
.
FromArgb
(((
int
)(((
byte
)(
102
)))),
((
int
)(((
byte
)(
102
)))),
((
int
)(((
byte
)(
102
)))));
this
.
btnRight
.
Image
=
((
System
.
Drawing
.
Image
)(
resources
.
GetObject
(
"btnRight.Image"
)));
this
.
btnRight
.
ImageAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleCenter
;
this
.
btnRight
.
ImageFontIcons
=
((
object
)(
resources
.
GetObject
(
"btnRight.ImageFontIcons"
)));
this
.
btnRight
.
IsRadius
=
true
;
this
.
btnRight
.
IsShowRect
=
true
;
this
.
btnRight
.
IsShowTips
=
false
;
this
.
btnRight
.
Location
=
new
System
.
Drawing
.
Point
(
5
,
157
);
this
.
btnRight
.
Margin
=
new
System
.
Windows
.
Forms
.
Padding
(
0
);
this
.
btnRight
.
Name
=
"btnRight"
;
this
.
btnRight
.
RectColor
=
System
.
Drawing
.
Color
.
FromArgb
(((
int
)(((
byte
)(
224
)))),
((
int
)(((
byte
)(
224
)))),
((
int
)(((
byte
)(
224
)))));
this
.
btnRight
.
RectWidth
=
1
;
this
.
btnRight
.
Size
=
new
System
.
Drawing
.
Size
(
44
,
31
);
this
.
btnRight
.
TabIndex
=
0
;
this
.
btnRight
.
TabStop
=
false
;
this
.
btnRight
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleCenter
;
this
.
btnRight
.
TipsColor
=
System
.
Drawing
.
Color
.
FromArgb
(((
int
)(((
byte
)(
232
)))),
((
int
)(((
byte
)(
30
)))),
((
int
)(((
byte
)(
99
)))));
this
.
btnRight
.
TipsText
=
""
;
this
.
btnRight
.
BtnClick
+=
new
System
.
EventHandler
(
this
.
btnRight_BtnClick
);
//
// ucControlBase1
//
this
.
ucControlBase1
.
BackColor
=
System
.
Drawing
.
Color
.
Transparent
;
this
.
ucControlBase1
.
ConerRadius
=
5
;
this
.
ucControlBase1
.
Controls
.
Add
(
this
.
dgvLeft
);
this
.
ucControlBase1
.
Dock
=
System
.
Windows
.
Forms
.
DockStyle
.
Fill
;
this
.
ucControlBase1
.
FillColor
=
System
.
Drawing
.
Color
.
Transparent
;
this
.
ucControlBase1
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
15F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Pixel
);
this
.
ucControlBase1
.
IsRadius
=
true
;
this
.
ucControlBase1
.
IsShowRect
=
true
;
this
.
ucControlBase1
.
Location
=
new
System
.
Drawing
.
Point
(
0
,
0
);
this
.
ucControlBase1
.
Margin
=
new
System
.
Windows
.
Forms
.
Padding
(
0
);
this
.
ucControlBase1
.
Name
=
"ucControlBase1"
;
this
.
ucControlBase1
.
Padding
=
new
System
.
Windows
.
Forms
.
Padding
(
1
);
this
.
ucControlBase1
.
RectColor
=
System
.
Drawing
.
Color
.
FromArgb
(((
int
)(((
byte
)(
220
)))),
((
int
)(((
byte
)(
220
)))),
((
int
)(((
byte
)(
220
)))));
this
.
ucControlBase1
.
RectWidth
=
1
;
this
.
ucControlBase1
.
Size
=
new
System
.
Drawing
.
Size
(
195
,
397
);
this
.
ucControlBase1
.
TabIndex
=
3
;
//
// dgvLeft
//
this
.
dgvLeft
.
AutoRowsScroll
=
true
;
this
.
dgvLeft
.
BackColor
=
System
.
Drawing
.
Color
.
White
;
this
.
dgvLeft
.
Columns
=
null
;
this
.
dgvLeft
.
DataSource
=
null
;
this
.
dgvLeft
.
Dock
=
System
.
Windows
.
Forms
.
DockStyle
.
Fill
;
this
.
dgvLeft
.
HeadFont
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
12F
);
this
.
dgvLeft
.
HeadHeight
=
40
;
this
.
dgvLeft
.
HeadPadingLeft
=
0
;
this
.
dgvLeft
.
HeadTextColor
=
System
.
Drawing
.
Color
.
Black
;
this
.
dgvLeft
.
IsCloseAutoHeight
=
false
;
this
.
dgvLeft
.
IsShowCheckBox
=
true
;
this
.
dgvLeft
.
IsShowHead
=
true
;
this
.
dgvLeft
.
Location
=
new
System
.
Drawing
.
Point
(
1
,
1
);
this
.
dgvLeft
.
Name
=
"dgvLeft"
;
this
.
dgvLeft
.
Page
=
null
;
this
.
dgvLeft
.
RowHeight
=
40
;
this
.
dgvLeft
.
RowType
=
typeof
(
HZH_Controls
.
Controls
.
UCDataGridViewRow
);
this
.
dgvLeft
.
Size
=
new
System
.
Drawing
.
Size
(
193
,
395
);
this
.
dgvLeft
.
TabIndex
=
2
;
//
// UCTransfer
//
this
.
AutoScaleMode
=
System
.
Windows
.
Forms
.
AutoScaleMode
.
None
;
this
.
BackColor
=
System
.
Drawing
.
Color
.
White
;
this
.
Controls
.
Add
(
this
.
tableLayoutPanel1
);
this
.
Name
=
"UCTransfer"
;
this
.
Size
=
new
System
.
Drawing
.
Size
(
451
,
397
);
this
.
tableLayoutPanel1
.
ResumeLayout
(
false
);
this
.
panel1
.
ResumeLayout
(
false
);
this
.
ucControlBase2
.
ResumeLayout
(
false
);
this
.
ucControlBase1
.
ResumeLayout
(
false
);
this
.
ResumeLayout
(
false
);
}
#
endregion
private
System
.
Windows
.
Forms
.
TableLayoutPanel
tableLayoutPanel1
;
private
System
.
Windows
.
Forms
.
Panel
panel1
;
private
UCBtnImg
btnLeft
;
private
UCBtnImg
btnRight
;
private
UCControlBase
ucControlBase1
;
private
UCDataGridView
dgvLeft
;
private
UCControlBase
ucControlBase2
;
private
UCDataGridView
dgvRight
;
}
}
HZH_Controls/HZH_Controls/Controls/Transfer/UCTransfer.cs
0 → 100644
查看文件 @
800e772
// ***********************************************************************
// Assembly : HZH_Controls
// Created : 2019-10-10
//
// ***********************************************************************
// <copyright file="UCTransfer.cs">
// Copyright by Huang Zhenghui(黄正辉) All, QQ group:568015492 QQ:623128629 Email:623128629@qq.com
// </copyright>
//
// Blog: https://www.cnblogs.com/bfyx
// GitHub:https://github.com/kwwwvagaa/NetWinformControl
// gitee:https://gitee.com/kwwwvagaa/net_winform_custom_control.git
//
// If you use this code, please keep this note.
// ***********************************************************************
using
System
;
using
System.Collections.Generic
;
using
System.ComponentModel
;
using
System.Drawing
;
using
System.Data
;
using
System.Linq
;
using
System.Text
;
using
System.Windows.Forms
;
namespace
HZH_Controls.Controls
{
/// <summary>
/// Class UCTransfer.
/// Implements the <see cref="System.Windows.Forms.UserControl" />
/// </summary>
/// <seealso cref="System.Windows.Forms.UserControl" />
[
DefaultEvent
(
"Transfered"
)]
public
partial
class
UCTransfer
:
UserControl
{
/// <summary>
/// 移动数据事件
/// </summary>
[
Description
(
"移动数据事件"
),
Category
(
"自定义"
)]
public
event
TransferEventHandler
Transfered
;
/// <summary>
/// The left columns
/// </summary>
private
DataGridViewColumnEntity
[]
leftColumns
;
/// <summary>
/// Gets or sets the left columns.
/// </summary>
/// <value>The left columns.</value>
[
Description
(
"左侧列表列"
),
Category
(
"自定义"
)]
public
DataGridViewColumnEntity
[]
LeftColumns
{
get
{
return
leftColumns
;
}
set
{
leftColumns
=
value
;
this
.
dgvLeft
.
Columns
=
leftColumns
.
ToList
();
}
}
/// <summary>
/// The right columns
/// </summary>
private
DataGridViewColumnEntity
[]
rightColumns
;
/// <summary>
/// Gets or sets the right columns.
/// </summary>
/// <value>The right columns.</value>
[
Description
(
"右侧列表列"
),
Category
(
"自定义"
)]
public
DataGridViewColumnEntity
[]
RightColumns
{
get
{
return
rightColumns
;
}
set
{
rightColumns
=
value
;
this
.
dgvRight
.
Columns
=
leftColumns
.
ToList
();
}
}
/// <summary>
/// The left data source
/// </summary>
private
object
[]
leftDataSource
;
/// <summary>
/// 左右列表必须设置相同类型的数据源列表,如果为空必须为长度为0的数组
/// </summary>
/// <value>The left data source.</value>
[
Description
(
"左侧列表数据源"
),
Category
(
"自定义"
),
Browsable
(
false
),
EditorBrowsable
(
EditorBrowsableState
.
Never
)]
public
object
[]
LeftDataSource
{
get
{
return
leftDataSource
;
}
set
{
leftDataSource
=
value
;
dgvLeft
.
DataSource
=
value
;
}
}
/// <summary>
/// The right data source
/// </summary>
private
object
[]
rightDataSource
;
/// <summary>
/// 左右列表必须设置相同类型的数据源列表,如果为空必须为长度为0的数组
/// </summary>
/// <value>The left data source.</value>
[
Description
(
"右侧列表数据源"
),
Category
(
"自定义"
),
Browsable
(
false
),
EditorBrowsable
(
EditorBrowsableState
.
Never
)]
public
object
[]
RightDataSource
{
get
{
return
rightDataSource
;
}
set
{
rightDataSource
=
value
;
dgvRight
.
DataSource
=
value
;
}
}
/// <summary>
/// Initializes a new instance of the <see cref="UCTransfer"/> class.
/// </summary>
public
UCTransfer
()
{
InitializeComponent
();
dgvLeft
.
IsCloseAutoHeight
=
true
;
dgvRight
.
IsCloseAutoHeight
=
true
;
LeftColumns
=
new
DataGridViewColumnEntity
[
0
];
RightColumns
=
new
DataGridViewColumnEntity
[
0
];
LeftDataSource
=
new
object
[
0
];
RightDataSource
=
new
object
[
0
];
}
/// <summary>
/// Handles the BtnClick event of the btnRight control.
/// </summary>
/// <param name="sender">The source of the event.</param>
/// <param name="e">The <see cref="EventArgs"/> instance containing the event data.</param>
/// <exception cref="System.Exception">
/// 左右数据源列表不能为空
/// or
/// 左右数据源列表类型不一致,无法进行操作
/// </exception>
private
void
btnRight_BtnClick
(
object
sender
,
EventArgs
e
)
{
if
(
LeftDataSource
==
null
||
RightDataSource
==
null
)
{
throw
new
Exception
(
"左右数据源列表不能为空"
);
}
if
(
LeftDataSource
.
GetType
()
!=
RightDataSource
.
GetType
())
{
throw
new
Exception
(
"左右数据源列表类型不一致,无法进行操作"
);
}
if
(
dgvLeft
.
SelectRows
==
null
||
dgvLeft
.
SelectRows
.
Count
<=
0
)
return
;
List
<
object
>
lst
=
new
List
<
object
>();
dgvLeft
.
SelectRows
.
ForEach
(
p
=>
{
lst
.
Add
(
p
.
DataSource
);
p
.
IsChecked
=
false
;
});
var
lstRight
=
RightDataSource
.
ToList
();
lstRight
.
AddRange
(
lst
);
var
lstLeft
=
LeftDataSource
.
ToList
();
lstLeft
.
RemoveAll
(
p
=>
lst
.
Contains
(
p
));
RightDataSource
=
lstRight
.
ToArray
();
LeftDataSource
=
lstLeft
.
ToArray
();
if
(
Transfered
!=
null
)
{
Transfered
(
this
,
new
TransferEventArgs
()
{
TransferDataSource
=
lst
.
ToArray
(),
ToRightOrLeft
=
true
});
}
}
/// <summary>
/// Handles the BtnClick event of the btnLeft control.
/// </summary>
/// <param name="sender">The source of the event.</param>
/// <param name="e">The <see cref="EventArgs"/> instance containing the event data.</param>
/// <exception cref="System.Exception">
/// 左右数据源列表不能为空
/// or
/// 左右数据源列表类型不一致,无法进行操作
/// </exception>
private
void
btnLeft_BtnClick
(
object
sender
,
EventArgs
e
)
{
if
(
LeftDataSource
==
null
||
RightDataSource
==
null
)
{
throw
new
Exception
(
"左右数据源列表不能为空"
);
}
if
(
LeftDataSource
.
GetType
()
!=
RightDataSource
.
GetType
())
{
throw
new
Exception
(
"左右数据源列表类型不一致,无法进行操作"
);
}
if
(
dgvRight
.
SelectRows
==
null
||
dgvRight
.
SelectRows
.
Count
<=
0
)
return
;
List
<
object
>
lst
=
new
List
<
object
>();
dgvRight
.
SelectRows
.
ForEach
(
p
=>
{
lst
.
Add
(
p
.
DataSource
);
p
.
IsChecked
=
false
;
});
var
lstLeft
=
LeftDataSource
.
ToList
();
lstLeft
.
AddRange
(
lst
);
var
lstRight
=
RightDataSource
.
ToList
();
lstRight
.
RemoveAll
(
p
=>
lst
.
Contains
(
p
));
RightDataSource
=
lstRight
.
ToArray
();
LeftDataSource
=
lstLeft
.
ToArray
();
if
(
Transfered
!=
null
)
{
Transfered
(
this
,
new
TransferEventArgs
()
{
TransferDataSource
=
lst
.
ToArray
(),
ToRightOrLeft
=
false
});
}
}
}
}
HZH_Controls/HZH_Controls/Controls/Transfer/UCTransfer.resx
0 → 100644
查看文件 @
800e772
<?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>
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="btnLeft.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
YQUAAAAJcEhZcwAADr0AAA69AUf7kK0AAAB5SURBVFhH7dXBDYAgDAVQlnEBx3IldqHQLZxGKSkkmtQT
GIz/JYT0X34vBAcA8HkhhJWI9ny8RoWVd1VLYoyH3BqbeVf3Epmf8q5Q/r9yYZW8Ui5ygZciLWtv28qH
wBIVlqimWiLfl0/HyodIKW3MvOjYWDkATMS5E+hGfXDhMAVvAAAAAElFTkSuQmCC
</value>
</data>
<data name="btnLeft.ImageFontIcons" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
YQUAAAAJcEhZcwAADr0AAA69AUf7kK0AAAB5SURBVFhH7dXBDYAgDAVQlnEBx3IldqHQLZxGKSkkmtQT
GIz/JYT0X34vBAcA8HkhhJWI9ny8RoWVd1VLYoyH3BqbeVf3Epmf8q5Q/r9yYZW8Ui5ygZciLWtv28qH
wBIVlqimWiLfl0/HyodIKW3MvOjYWDkATMS5E+hGfXDhMAVvAAAAAElFTkSuQmCC
</value>
</data>
<data name="btnRight.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
YQUAAAAJcEhZcwAADr0AAA69AUf7kK0AAACJSURBVFhH7ZXNCcAgDEZdpgt0rK7UGbqCf1s4TWuKgSLG
U0IRvgcefJenh6gDAIAlyDlvIYRS19nUi+TVSSkdMcab1jcmeRMoMIpJ3gQcgsEhmBq4OEYT0bToVfHe
7zVU2k0LvQkzr0ofof3Mq4L4L3H+dPqI5NXhT6ePSN4Eio1GSvIAgEVw7gENgIbqKKEIVQAAAABJRU5E
rkJggg==
</value>
</data>
<data name="btnRight.ImageFontIcons" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
YQUAAAAJcEhZcwAADr0AAA69AUf7kK0AAACJSURBVFhH7ZXNCcAgDEZdpgt0rK7UGbqCf1s4TWuKgSLG
U0IRvgcefJenh6gDAIAlyDlvIYRS19nUi+TVSSkdMcab1jcmeRMoMIpJ3gQcgsEhmBq4OEYT0bToVfHe
7zVU2k0LvQkzr0ofof3Mq4L4L3H+dPqI5NXhT6ePSN4Eio1GSvIAgEVw7gENgIbqKKEIVQAAAABJRU5E
rkJggg==
</value>
</data>
</root>
\ No newline at end of file
HZH_Controls/HZH_Controls/HZH_Controls.csproj
查看文件 @
800e772
...
...
@@ -113,6 +113,13 @@
<Compile Include="Controls\TimeLine\UCTimeLine.Designer.cs">
<DependentUpon>UCTimeLine.cs</DependentUpon>
</Compile>
<Compile Include="Controls\Transfer\TransferEventArgs.cs" />
<Compile Include="Controls\Transfer\UCTransfer.cs">
<SubType>UserControl</SubType>
</Compile>
<Compile Include="Controls\Transfer\UCTransfer.Designer.cs">
<DependentUpon>UCTransfer.cs</DependentUpon>
</Compile>
<Compile Include="Controls\Verification\VerificationAttribute.cs" />
<Compile Include="Controls\Verification\VerificationComponent.cs">
<SubType>Component</SubType>
...
...
@@ -762,6 +769,9 @@
<EmbeddedResource Include="Controls\TimeLine\UCTimeLine.resx">
<DependentUpon>UCTimeLine.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="Controls\Transfer\UCTransfer.resx">
<DependentUpon>UCTransfer.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="Controls\UCControlBase.resx">
<DependentUpon>UCControlBase.cs</DependentUpon>
</EmbeddedResource>
...
...
HZH_Controls/Test/FrmMain.cs
查看文件 @
800e772
...
...
@@ -67,6 +67,7 @@ namespace Test
tnControl
.
Nodes
.
Add
(
"导航菜单"
);
tnControl
.
Nodes
.
Add
(
"分割线标签"
);
tnControl
.
Nodes
.
Add
(
"时间轴"
);
tnControl
.
Nodes
.
Add
(
"穿梭框"
);
this
.
tvMenu
.
Nodes
.
Add
(
tnControl
);
TreeNode
tnCharts
=
new
TreeNode
(
" 图表"
);
...
...
@@ -258,7 +259,7 @@ namespace Test
AddControl
(
new
UC
.
UCTestVerification
()
{
Dock
=
DockStyle
.
Fill
});
break
;
case
"图片采样控件"
:
AddControl
(
new
UC
.
UCTestSampling
()
);
AddControl
(
new
UC
.
UCTestSampling
());
break
;
case
"倒影"
:
AddControl
(
new
UC
.
UCTestShadow
());
...
...
@@ -275,6 +276,9 @@ namespace Test
case
"时间轴"
:
AddControl
(
new
UC
.
UCTestTimeLine
()
{
Dock
=
DockStyle
.
Fill
});
break
;
case
"穿梭框"
:
AddControl
(
new
UC
.
UCTestTransfer
());
break
;
#
endregion
#
region
图表
English
:
Chart
...
...
HZH_Controls/Test/Test.csproj
查看文件 @
800e772
...
...
@@ -320,6 +320,12 @@
<Compile Include="UC\UCTestTrackbar.Designer.cs">
<DependentUpon>UCTestTrackbar.cs</DependentUpon>
</Compile>
<Compile Include="UC\UCTestTransfer.cs">
<SubType>UserControl</SubType>
</Compile>
<Compile Include="UC\UCTestTransfer.Designer.cs">
<DependentUpon>UCTestTransfer.cs</DependentUpon>
</Compile>
<Compile Include="UC\UCTestTreeGridTable.cs">
<SubType>UserControl</SubType>
</Compile>
...
...
@@ -500,6 +506,9 @@
<EmbeddedResource Include="UC\UCTestTrackbar.resx">
<DependentUpon>UCTestTrackbar.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="UC\UCTestTransfer.resx">
<DependentUpon>UCTestTransfer.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="UC\UCTestTreeGridTable.resx">
<DependentUpon>UCTestTreeGridTable.cs</DependentUpon>
</EmbeddedResource>
...
...
HZH_Controls/Test/UC/UCTestTransfer.Designer.cs
0 → 100644
查看文件 @
800e772
namespace
Test.UC
{
partial
class
UCTestTransfer
{
/// <summary>
/// 必需的设计器变量。
/// </summary>
private
System
.
ComponentModel
.
IContainer
components
=
null
;
/// <summary>
/// 清理所有正在使用的资源。
/// </summary>
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
protected
override
void
Dispose
(
bool
disposing
)
{
if
(
disposing
&&
(
components
!=
null
))
{
components
.
Dispose
();
}
base
.
Dispose
(
disposing
);
}
#
region
组件设计器生成的代码
/// <summary>
/// 设计器支持所需的方法 - 不要
/// 使用代码编辑器修改此方法的内容。
/// </summary>
private
void
InitializeComponent
()
{
this
.
ucTransfer1
=
new
HZH_Controls
.
Controls
.
UCTransfer
();
this
.
SuspendLayout
();
//
// ucTransfer1
//
this
.
ucTransfer1
.
BackColor
=
System
.
Drawing
.
Color
.
White
;
this
.
ucTransfer1
.
LeftColumns
=
new
HZH_Controls
.
Controls
.
DataGridViewColumnEntity
[
0
];
this
.
ucTransfer1
.
LeftDataSource
=
new
object
[
0
];
this
.
ucTransfer1
.
Location
=
new
System
.
Drawing
.
Point
(
22
,
22
);
this
.
ucTransfer1
.
Name
=
"ucTransfer1"
;
this
.
ucTransfer1
.
RightDataSource
=
new
object
[
0
];
this
.
ucTransfer1
.
Size
=
new
System
.
Drawing
.
Size
(
451
,
397
);
this
.
ucTransfer1
.
TabIndex
=
0
;
//
// UCTestTransfer
//
this
.
AutoScaleMode
=
System
.
Windows
.
Forms
.
AutoScaleMode
.
None
;
this
.
BackColor
=
System
.
Drawing
.
Color
.
White
;
this
.
Controls
.
Add
(
this
.
ucTransfer1
);
this
.
Name
=
"UCTestTransfer"
;
this
.
Size
=
new
System
.
Drawing
.
Size
(
619
,
573
);
this
.
Load
+=
new
System
.
EventHandler
(
this
.
UCTestTransfer_Load
);
this
.
ResumeLayout
(
false
);
}
#
endregion
private
HZH_Controls
.
Controls
.
UCTransfer
ucTransfer1
;
}
}
HZH_Controls/Test/UC/UCTestTransfer.cs
0 → 100644
查看文件 @
800e772
using
System
;
using
System.Collections.Generic
;
using
System.ComponentModel
;
using
System.Drawing
;
using
System.Data
;
using
System.Linq
;
using
System.Text
;
using
System.Windows.Forms
;
using
HZH_Controls.Controls
;
namespace
Test.UC
{
[
ToolboxItem
(
false
)]
public
partial
class
UCTestTransfer
:
UserControl
{
public
UCTestTransfer
()
{
InitializeComponent
();
}
private
void
UCTestTransfer_Load
(
object
sender
,
EventArgs
e
)
{
DataGridViewColumnEntity
[]
lstLeftCulumns
=
new
DataGridViewColumnEntity
[
1
];
lstLeftCulumns
[
0
]
=
new
DataGridViewColumnEntity
()
{
DataField
=
"Value"
,
HeadText
=
"列表一"
,
TextAlign
=
ContentAlignment
.
MiddleLeft
};
DataGridViewColumnEntity
[]
lstRightCulumns
=
new
DataGridViewColumnEntity
[
1
];
lstRightCulumns
[
0
]
=
new
DataGridViewColumnEntity
()
{
DataField
=
"Value"
,
HeadText
=
"列表二"
,
TextAlign
=
ContentAlignment
.
MiddleLeft
};
this
.
ucTransfer1
.
LeftColumns
=
lstLeftCulumns
;
this
.
ucTransfer1
.
RightColumns
=
lstRightCulumns
;
var
lstItems
=
new
TestModel
[
5
];
for
(
int
i
=
0
;
i
<
5
;
i
++)
{
lstItems
[
i
]
=
new
TestModel
()
{
Key
=
i
,
Value
=
"选择项"
+
i
};
}
this
.
ucTransfer1
.
LeftDataSource
=
lstItems
;
this
.
ucTransfer1
.
RightDataSource
=
new
TestModel
[
0
];
}
private
class
TestModel
{
public
int
Key
{
get
;
set
;
}
public
string
Value
{
get
;
set
;
}
}
}
}
HZH_Controls/Test/UC/UCTestTransfer.resx
0 → 100644
查看文件 @
800e772
<?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>
\ No newline at end of file
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论