diff options
| author | jpbruyere <jp.bruyere@hotmail.com> | 2016-08-20 17:40:01 +0200 |
|---|---|---|
| committer | jpbruyere <jp.bruyere@hotmail.com> | 2016-09-01 12:44:39 +0200 |
| commit | 417c7100b779d79a3bc71ec7adbf3528f9b05c92 (patch) | |
| tree | 805d42323898f013485ed20adb19b32398600981 /src/GraphicObjects/MenuItem.cs | |
| parent | befffb69eaebf2e607d88cd3ffc956a708d5734e (diff) | |
Can't pop is no submenu on node
modifié : Templates/MenuItem.template
modifié : src/GraphicObjects/MenuItem.cs
add CanPop property
modifié : src/GraphicObjects/Popper.cs
add 'HasChildren' propertyless binding
modifié : src/GraphicObjects/TemplatedGroup.cs
Diffstat (limited to 'src/GraphicObjects/MenuItem.cs')
| -rw-r--r-- | src/GraphicObjects/MenuItem.cs | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/src/GraphicObjects/MenuItem.cs b/src/GraphicObjects/MenuItem.cs index 591be2b0..2734377e 100644 --- a/src/GraphicObjects/MenuItem.cs +++ b/src/GraphicObjects/MenuItem.cs @@ -34,6 +34,18 @@ namespace Crow // public event EventHandler Unpop; string caption; + Command command; + + [XmlAttributeAttribute()][DefaultValue(null)] + public virtual Command Command { + get { return command; } + set { + if (command == value) + return; + command = value; + NotifyValueChanged ("Command", command); + } + } [XmlAttributeAttribute][DefaultValue("MenuItem")] public string Caption { @@ -45,10 +57,6 @@ namespace Crow NotifyValueChanged ("Caption", caption); } } -// [XmlIgnore] -// public virtual Alignment Orientation { -// get { return Parent is Menu ? (Parent as Menu).Orientation : (Parent as MenuItem); } -// } Menu MenuRoot { get { |