Inheritance: System.Windows.Forms.Layout.ArrangedElementCollection, IList, ICollection, ICloneable, IEnumerable
Exemple #1
0
 public WorkWithForm(Control.ControlCollection controls, Button btnSave, Button btnClose)
 {
     _controls = controls;
     _btnSave = btnSave;
     _btnClose = btnClose;
     EditModeChanged += DefaulEditModeChanged;
 }
Exemple #2
0
    public void RemoveFingerprintEvent(System.Windows.Forms.Control.ControlCollection Controls)
    {
        Controls.Remove(m_zkFprint);

        m_currentOnCapture       = null;
        m_currentOnImageReceived = null;
        m_currentOnFeatureInfo   = null;
        m_currentOnEnroll        = null;
        m_zkFprint.CancelCapture();
        m_zkFprint.CancelEnroll();
    }
Exemple #3
0
 public void SetupFingerprintEvent(System.Windows.Forms.Control.ControlCollection Controls
                                   , IZKFPEngXEvents_OnFeatureInfoEventHandler OnFeatureInfo,
                                   IZKFPEngXEvents_OnImageReceivedEventHandler OnImageReceived,
                                   IZKFPEngXEvents_OnEnrollEventHandler OnEnroll,
                                   IZKFPEngXEvents_OnCaptureEventHandler OnCapture)
 {
     Controls.Add(m_zkFprint);
     m_currentOnCapture       = OnCapture;
     m_currentOnImageReceived = OnImageReceived;
     m_currentOnFeatureInfo   = OnFeatureInfo;
     m_currentOnEnroll        = OnEnroll;
     m_zkFprint.BeginCapture();
 }
 public WBXMLInspector()
 {
     wbxmlDoc = new WBXMLDocument();
     wbxmlDoc.VersionNumber = 1.3;
     wbxmlDoc.TagCodeSpace = new ActiveSyncCodeSpace();
     wbxmlDoc.AttributeCodeSpace = new ActiveSyncAttributeCodeSpace();
     wbxmlDoc.Encoding = Encoding.UTF8;
     xmlView = new XMLView();
     textView = new RawView(this);
     rawBody = null;
     validHeader = false;
     tagPageControl = null;
 }
        // Public methods.
        /// <summary>
        /// Initializes the control.
        /// </summary>
        /// <param name="crawler">The crawler.</param>
        /// <param name="treeNode">The root tree node.</param>
        /// <param name="controls">The controls collection.</param>
        public void Initialize(Crawler crawler, ImageList imageList, TreeNode treeNode, Control.ControlCollection controls)
        {
            // Set the parameters.
            this.crawler = crawler;
            this.imageList = imageList;
            this.treeNode = treeNode;
            this.controls = controls;

            // Enable the control.
            this.Enabled = true;

            // Set the image list.
            this.listView.SmallImageList = this.imageList;

            // Set the toolbox event handlers.
            this.crawler.Toolbox.ToolAdded += this.OnToolAdded;
            this.crawler.Toolbox.ToolRemoved += this.OnToolRemoved;

            // Load the current tools from the toolset.
            foreach (Tool tool in this.crawler.Toolbox)
            {
                this.OnAddTool(tool);
            }
        }
 public MockMainForm()
 {
     var owner = new Control();
     FormControls = new Control.ControlCollection(owner);
 }
Exemple #7
0
 private ArrayList FindToolStrips(bool searchAllChildren, Control.ControlCollection controlsToLookIn)
 {
     return(FindControls(typeof(ToolStrip), true, form.Controls, new ArrayList()));
 }
Exemple #8
0
 public WinformHelper()
 {
     controls = new Control.ControlCollection(new Control());
 }
        /// <summary>
        /// 暂时无用
        /// </summary>
        /// <param name="owner"></param>
        /// <returns></returns>
        private Control.ControlCollection GetControls(Control owner)
        {
            Control.ControlCollection tempCollection;

            if (0 >= m_Buttons.Count)
            {
                tempCollection = null;
            } // end of if
            else
            {
                tempCollection = new Control.ControlCollection(owner);

                foreach (object o in m_Buttons)
                {
                    tempCollection.Add((ButtonX)o);
                }
            } // end of else

            return tempCollection;
        }
        // Public methods.
        /// <summary>
        /// Initializes the control with a crawler object.
        /// </summary>
        /// <param name="crawler">The crawler object.</param>
        /// <param name="treeNode">The root tree node for the database servers.</param>
        /// <param name="controls">The panel where to add the server control.</param>
        public void Initialize(Crawler crawler, TreeNode treeNode, Control.ControlCollection controls)
        {
            // Save the parameters.
            this.crawler = crawler;

            // Set the slices list event handler.
            this.crawler.PlanetLab.LocalSlices.Updated += this.OnSlicesUpdated;
            this.crawler.PlanetLab.LocalSlices.Cleared += this.OnSlicesCleared;
            this.crawler.PlanetLab.LocalSlices.Added += this.OnSlicesAdded;
            this.crawler.PlanetLab.LocalSlices.Removed += this.OnSlicesRemoved;

            // Get the status handler.
            this.status = this.crawler.Status.GetHandler(this);

            // Set the tree node.
            this.treeNode = treeNode;

            // Set the control collection.
            this.controls = controls;

            // Enable the control.
            this.Enabled = true;

            // Update the list of PlanetLab slices.
            this.OnSlicesUpdated(this, EventArgs.Empty);
        }
Exemple #11
0
 public WinformHelper(Control.ControlCollection _controls)
 {
     controls = _controls;
 }
Exemple #12
0
 public static IEnumerable <Control> AsEnumerable(this  Control.ControlCollection c)
 {
     return(Enumerable.Range(0, c.Count).Select(i => c[i]));
 }
 public DesignerControlCollection(Control owner)
     : base(owner)
 {
     this.realCollection = owner.Controls;
 }
Exemple #14
0
		public void ControlCollectionExceptionTest ()
		{
			Form frm = new Form ();
			frm.IsMdiContainer = true;
			Form child = new Form ();
			Control.ControlCollection c = new Control.ControlCollection (frm);
			//child.MdiParent = frm;
			c.Add (child);
			
			child.Dispose ();
			frm.Dispose ();			
		}
 /// <summary>
 /// Create a new FormValidator validating the specified controls.
 /// </summary>
 /// <param name="comToValidate">Components to validate.</param>
 public FormValidator(Control.ControlCollection comToValidate)
 {
     _controls = comToValidate;
 }
 /// <summary>
 /// Create a new FormValidator validating the specified form.
 /// </summary>
 /// <param name="formToValidate">The form which contains components to validate.</param>
 public FormValidator(Form formToValidate)
 {
     _controls = formToValidate.Controls;
 }
 public Validation(Control.ControlCollection collection)
 {
     this.collection = collection;
 }
 ///<summary>
 /// Constructor for <see cref="ControlCollectionWin"/>
 ///</summary>
 ///<param name="col"></param>
 public ControlCollectionWin(Control.ControlCollection col)
 {
     _col = col;
 }
		internal PanderPanelWCollection(PanderPanelListW PanderPanelListW)
        {
            this.m_PanderPanelListW = PanderPanelListW;
			this.m_controlCollection = this.m_PanderPanelListW.Controls;
        }
        /// <summary>
        /// Initializes the control with a crawler instance.
        /// </summary>
        /// <param name="crawler">The crawler instance.</param>
        /// <param name="treeNode">The root tree node for the database servers.</param>
        /// <param name="controls">The panel where to add the server control.</param>
        /// <param name="imageList">The image list.</param>
        public void Initialize(Crawler crawler, TreeNode treeNode, Control.ControlCollection controls, ImageList imageList)
        {
            // Set the crawler.
            this.crawler = crawler;
            // Set the root tree node.
            this.treeNode = treeNode;
            // Set the image list.
            this.listView.SmallImageList = imageList;
            // Set the controls collection.
            this.controls = controls;

            // Set the log event handler for the database servers.
            this.crawler.Database.Sql.EventLogged += this.OnEventLogged;

            // Add all the servers in the configuration.
            foreach (DbServerSql server in this.crawler.Database.Sql)
            {
                this.AddServer(server);
            }

            // Add the event handlers for the servers.
            this.crawler.Database.Sql.ServerAdded += this.OnServerAdded;
            this.crawler.Database.Sql.ServerChanged += this.OnServerChanged;
            this.crawler.Database.Sql.ServerStateChanged += this.OnServerStateChanged;
            this.crawler.Database.Sql.PrimaryServerChanged += this.OnPrimaryServerChanged;
            this.crawler.Database.Sql.ServerRemoved += this.OnServerRemoved;

            // Reload the server configurations.
            this.crawler.Database.Sql.Reload();
        }
 public override void AddToTab(TabPage o)
 {
     o.Text = "WBXML";
     tagPageControl = o.Controls;
 }
			public ControlCollection( Control.ControlCollection source, System.Type typeFilter )
			{
				this.source = source;
				this.typeFilter = typeFilter;
			}
Exemple #23
0
 internal XPanderPanelCollection(XPanderPanelList xpanderPanelList)
 {
     this.m_xpanderPanelList = xpanderPanelList;
     this.m_controlCollection = this.m_xpanderPanelList.Controls;
 }
        // Public methods.
        /// <summary>
        /// Initializes the control with a crawler object.
        /// </summary>
        /// <param name="crawler">The crawler object.</param>
        /// <param name="slice">The slice.</param>
        /// <param name="controls">The controls collection.</param>
        /// <param name="treeNode">The tree node corresponding to this control.</param>
        public void Initialize(Crawler crawler, PlSlice slice, Control.ControlCollection controls, TreeNode treeNode)
        {
            // Save the parameters.
            this.crawler = crawler;

            // Get the status handler.
            this.status = this.crawler.Status.GetHandler(this);

            // Set the slice.
            this.slice = slice;
            this.slice.Changed += this.OnSliceChanged;

            // Set the controls.
            this.controls = controls;

            // Set the tree node.
            this.treeNodeSlice = treeNode;

            // Set the slice configuration.
            this.config = this.crawler.PlanetLab.GetSliceConfiguration(this.slice);

            // Set the title.
            this.panelSlice.Title = "PlanetLab Slice ({0})".FormatWith(this.slice.Name);

            // Enable the control.
            this.Enabled = true;

            // Update the information of the PlanetLab slice.
            this.OnUpdateSlice();

            // Create the run option.
            this.OnCreateRun();

            // Create the log option.
            this.OnCreateLog();
        }