diff options
| author | Roy <roy.mail.net@gmail.com> | 2018-02-12 09:40:08 +0200 |
|---|---|---|
| committer | Roy <roy.mail.net@gmail.com> | 2018-02-12 09:40:08 +0200 |
| commit | 2bef1ef7fb1d5cd57e2af3f47a648e512cfcd4f2 (patch) | |
| tree | 53ff9fc86a9e56d5cd54a53ecddf85aa4656dd6a /Software/Visual_Studio/Tango.Editors | |
| parent | a84ca3e4bee123600c08f8897eca5be83b3ffcf8 (diff) | |
| download | Tango-2bef1ef7fb1d5cd57e2af3f47a648e512cfcd4f2.tar.gz Tango-2bef1ef7fb1d5cd57e2af3f47a648e512cfcd4f2.zip | |
Implemented motor group.
Diffstat (limited to 'Software/Visual_Studio/Tango.Editors')
| -rw-r--r-- | Software/Visual_Studio/Tango.Editors/ElementsEditor.xaml.cs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Software/Visual_Studio/Tango.Editors/ElementsEditor.xaml.cs b/Software/Visual_Studio/Tango.Editors/ElementsEditor.xaml.cs index cf602cac7..abd5e5929 100644 --- a/Software/Visual_Studio/Tango.Editors/ElementsEditor.xaml.cs +++ b/Software/Visual_Studio/Tango.Editors/ElementsEditor.xaml.cs @@ -446,7 +446,10 @@ namespace Tango.Editors { if (BringToFrontOnSelect) { - Canvas.SetZIndex(SelectedElement as UIElement, Elements.Max(x => Canvas.GetZIndex(x as UIElement) + 1)); + if (Elements.Count > 0) + { + Canvas.SetZIndex(SelectedElement as UIElement, Elements.Max(x => Canvas.GetZIndex(x as UIElement) + 1)); + } } SetElementSelection(SelectedElement, true); |
