private void AttachMouseDoubleClick(Control nodeControl)
        {
            nodeControl.MouseDoubleClick += new MouseButtonEventHandler(componentControl_MouseDoubleClick);

            //find toogleInfoButton and its command, so that we can execute it on the MouseDoubleClick event
            var infoToggleButton = (ToggleButton)nodeControl.FindName("PART_ToogleInfoButton");

            m_toogleInfoCommand = infoToggleButton.Command;
        }
Exemplo n.º 2
0
 private static System.Windows.Controls.Control smethod_0(System.Windows.Controls.Control dependencyObject_0, string string_0)
 {
     if (dependencyObject_0 == null)
     {
         return(null);
     }
     System.Windows.Controls.Control obj2 = (System.Windows.Controls.Control)dependencyObject_0.FindName(string_0);
     if (obj2 != null)
     {
         return(obj2);
     }
     return(null);
 }
Exemplo n.º 3
0
        public static bool SetupTextBoxBinding(System.Windows.Controls.Control xamlRoot, string controlName, string bindingName, BindingMode bindingMode, object bindingSource, IValueConverter converter = null)
        {
            TextBox box = (TextBox)xamlRoot.FindName(controlName);

            if (box == null)
            {
                return(false);
            }
            Binding binding1 = new Binding(bindingName)
            {
                Mode      = bindingMode,
                Source    = bindingSource,
                Converter = converter
            };

            box.SetBinding(TextBox.TextProperty, binding1);
            return(true);
        }
 private void SetProgress(Control nodeControl)
 {
     m_progress = (TraceLabSDK.IProgress)nodeControl.FindName("PART_Progress");
     ComponentNode.Progress = m_progress;
 }