public void PropertyImageTransparentColor() { ToolStripItem tsi = new NullToolStripItem(); EventWatcher ew = new EventWatcher(tsi); tsi.ImageTransparentColor = Color.BurlyWood; Assert.AreEqual(Color.BurlyWood, tsi.ImageTransparentColor, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.ImageTransparentColor = Color.BurlyWood; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertySorted() { ToolStripComboBox tsi = new ToolStripComboBox(); EventWatcher ew = new EventWatcher(tsi); tsi.Sorted = true; Assert.AreEqual(true, tsi.Sorted, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.Sorted = true; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertyChecked() { ToolStripButton tsi = new ToolStripButton(); EventWatcher ew = new EventWatcher(tsi); tsi.Checked = true; Assert.AreEqual(true, tsi.Checked, "B1"); Assert.AreEqual("CheckedChanged;CheckStateChanged", ew.ToString(), "B2"); ew.Clear(); tsi.Checked = true; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertyMaxLength() { ToolStripComboBox tsi = new ToolStripComboBox(); EventWatcher ew = new EventWatcher(tsi); tsi.MaxLength = 42; Assert.AreEqual(42, tsi.MaxLength, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.MaxLength = 42; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertySelectedText() { ToolStripComboBox tsi = new ToolStripComboBox(); EventWatcher ew = new EventWatcher(tsi); tsi.SelectedText = "Hi"; Assert.AreEqual(string.Empty, tsi.SelectedText, "B1"); Assert.AreEqual("TextUpdate", ew.ToString(), "B2"); ew.Clear(); tsi.SelectedText = string.Empty; Assert.AreEqual("TextUpdate", ew.ToString(), "B3"); }
public void PropertyDroppedDown() { ToolStripComboBox tsi = new ToolStripComboBox(); EventWatcher ew = new EventWatcher(tsi); tsi.DroppedDown = true; Assert.AreEqual(true, tsi.DroppedDown, "B1"); Assert.AreEqual("DropDown", ew.ToString(), "B2"); ew.Clear(); tsi.DroppedDown = true; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertyIntegralHeight() { ToolStripComboBox tsi = new ToolStripComboBox(); EventWatcher ew = new EventWatcher(tsi); tsi.IntegralHeight = false; Assert.AreEqual(false, tsi.IntegralHeight, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.IntegralHeight = false; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertyRightToLeftAutoMirrorImage() { ToolStripItem tsi = new NullToolStripItem(); EventWatcher ew = new EventWatcher(tsi); tsi.RightToLeftAutoMirrorImage = true; Assert.AreEqual(true, tsi.RightToLeftAutoMirrorImage, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.RightToLeftAutoMirrorImage = true; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertySize() { ToolStripItem tsi = new NullToolStripItem(); EventWatcher ew = new EventWatcher(tsi); tsi.Size = new Size(42, 42); Assert.AreEqual(new Size(42, 42), tsi.Size, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.Size = new Size(42, 42); Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertyPadding() { ToolStripItem tsi = new NullToolStripItem(); EventWatcher ew = new EventWatcher(tsi); tsi.Padding = new Padding(6); Assert.AreEqual(new Padding(6), tsi.Padding, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.Padding = new Padding(6); Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertyRightToLeft() { ToolStripItem tsi = new NullToolStripItem(); EventWatcher ew = new EventWatcher(tsi); tsi.RightToLeft = RightToLeft.No; Assert.AreEqual(RightToLeft.No, tsi.RightToLeft, "B1"); Assert.AreEqual("RightToLeftChanged", ew.ToString(), "B2"); ew.Clear(); tsi.RightToLeft = RightToLeft.No; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertyOverflow() { ToolStripItem tsi = new NullToolStripItem(); EventWatcher ew = new EventWatcher(tsi); tsi.Overflow = ToolStripItemOverflow.Never; Assert.AreEqual(ToolStripItemOverflow.Never, tsi.Overflow, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.Overflow = ToolStripItemOverflow.Never; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertyName() { ToolStripItem tsi = new NullToolStripItem(); EventWatcher ew = new EventWatcher(tsi); tsi.Name = "MyName"; Assert.AreEqual("MyName", tsi.Name, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.Name = "MyName"; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertyMergeAction() { ToolStripItem tsi = new NullToolStripItem(); EventWatcher ew = new EventWatcher(tsi); tsi.MergeAction = MergeAction.Replace; Assert.AreEqual(MergeAction.Replace, tsi.MergeAction, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.MergeAction = MergeAction.Replace; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertyAutoSize () { Control c = new Control (); EventWatcher ew = new EventWatcher (c); c.AutoSize = true; Assert.AreEqual (true, c.AutoSize, "B1"); Assert.AreEqual ("AutoSizeChanged", ew.ToString (), "B2"); ew.Clear (); c.AutoSize = true; Assert.AreEqual (string.Empty, ew.ToString (), "B3"); }
public void PropertyTag() { ToolStripItem tsi = new NullToolStripItem(); EventWatcher ew = new EventWatcher(tsi); tsi.Tag = "tag"; Assert.AreSame("tag", tsi.Tag, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.Tag = "tag"; Assert.AreSame(string.Empty, ew.ToString(), "B3"); }
public void PropertyDropDownStyle() { ToolStripComboBox tsi = new ToolStripComboBox(); EventWatcher ew = new EventWatcher(tsi); tsi.DropDownStyle = ComboBoxStyle.Simple; Assert.AreEqual(ComboBoxStyle.Simple, tsi.DropDownStyle, "B1"); Assert.AreEqual("DropDownStyleChanged", ew.ToString(), "B2"); ew.Clear(); tsi.DropDownStyle = ComboBoxStyle.Simple; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertyTextAlign() { ToolStripItem tsi = new NullToolStripItem(); EventWatcher ew = new EventWatcher(tsi); tsi.TextAlign = ContentAlignment.TopRight; Assert.AreEqual(ContentAlignment.TopRight, tsi.TextAlign, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.TextAlign = ContentAlignment.TopRight; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertyFlatStyle() { ToolStripComboBox tsi = new ToolStripComboBox(); EventWatcher ew = new EventWatcher(tsi); tsi.FlatStyle = FlatStyle.System; Assert.AreEqual(FlatStyle.System, tsi.FlatStyle, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.FlatStyle = FlatStyle.System; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertyTextImageRelation() { ToolStripItem tsi = new NullToolStripItem(); EventWatcher ew = new EventWatcher(tsi); tsi.TextImageRelation = TextImageRelation.Overlay; Assert.AreEqual(TextImageRelation.Overlay, tsi.TextImageRelation, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.TextImageRelation = TextImageRelation.Overlay; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertyMaxDropDownItems() { ToolStripComboBox tsi = new ToolStripComboBox(); EventWatcher ew = new EventWatcher(tsi); tsi.MaxDropDownItems = 12; Assert.AreEqual(12, tsi.MaxDropDownItems, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.MaxDropDownItems = 12; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertyToolTipText() { ToolStripItem tsi = new NullToolStripItem(); EventWatcher ew = new EventWatcher(tsi); tsi.ToolTipText = "Text"; Assert.AreEqual("Text", tsi.ToolTipText, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.ToolTipText = "Text"; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertySelectedItem2() { ToolStripComboBox tsi = new ToolStripComboBox(); EventWatcher ew = new EventWatcher(tsi); tsi.SelectedItem = "B"; Assert.AreEqual(null, tsi.SelectedItem, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.SelectedItem = "B"; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertyVisible() { ToolStripItem tsi = new NullToolStripItem(); EventWatcher ew = new EventWatcher(tsi); tsi.Visible = true; Assert.AreEqual(false, tsi.Visible, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.Visible = true; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertySelectionStart() { ToolStripComboBox tsi = new ToolStripComboBox(); EventWatcher ew = new EventWatcher(tsi); tsi.SelectionStart = 42; Assert.AreEqual(0, tsi.SelectionStart, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.SelectionStart = 42; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertyWidth() { ToolStripItem tsi = new NullToolStripItem(); EventWatcher ew = new EventWatcher(tsi); tsi.Width = 42; Assert.AreEqual(42, tsi.Width, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.Width = 42; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertyAutoToolTip() { ToolStripButton tsi = new ToolStripButton(); EventWatcher ew = new EventWatcher(tsi); tsi.AutoToolTip = true; Assert.AreEqual(true, tsi.AutoToolTip, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.AutoToolTip = true; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertyBackColor() { ToolStripContentPanel tsp = new ToolStripContentPanel(); EventWatcher ew = new EventWatcher(tsp); tsp.BackColor = Color.Green; Assert.AreEqual(Color.Green, tsp.BackColor, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsp.BackColor = Color.Green; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertyCheckOnClick() { ToolStripButton tsi = new ToolStripButton(); EventWatcher ew = new EventWatcher(tsi); tsi.CheckOnClick = true; Assert.AreEqual(true, tsi.CheckOnClick, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.CheckOnClick = true; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertyDropDownHeight() { ToolStripComboBox tsi = new ToolStripComboBox(); EventWatcher ew = new EventWatcher(tsi); tsi.DropDownHeight = 42; Assert.AreEqual(42, tsi.DropDownHeight, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.DropDownHeight = 42; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertyAnchor () { Control c = new Control (); EventWatcher ew = new EventWatcher (c); c.Anchor = AnchorStyles.Bottom; Assert.AreEqual (AnchorStyles.Bottom, c.Anchor, "B1"); Assert.AreEqual (string.Empty, ew.ToString (), "B2"); ew.Clear (); c.Anchor = AnchorStyles.Bottom; Assert.AreEqual (string.Empty, ew.ToString (), "B3"); }
public void PropertyAllowDrop () { Control c = new Control (); EventWatcher ew = new EventWatcher (c); c.AllowDrop = true; Assert.AreEqual (true, c.AllowDrop, "B1"); Assert.AreEqual (string.Empty, ew.ToString (), "B2"); ew.Clear (); c.AllowDrop = true; Assert.AreEqual (string.Empty, ew.ToString (), "B3"); }
public void PropertyImageScaling() { ToolStripItem tsi = new NullToolStripItem(); EventWatcher ew = new EventWatcher(tsi); tsi.ImageScaling = ToolStripItemImageScaling.None; Assert.AreEqual(ToolStripItemImageScaling.None, tsi.ImageScaling, "B1"); Assert.AreEqual(string.Empty, ew.ToString(), "B2"); ew.Clear(); tsi.ImageScaling = ToolStripItemImageScaling.None; Assert.AreEqual(string.Empty, ew.ToString(), "B3"); }
public void PropertyMarqueeAnimationSpeed () { ToolStripProgressBar tsi = new ToolStripProgressBar (); EventWatcher ew = new EventWatcher (tsi); tsi.MarqueeAnimationSpeed = 200; Assert.AreEqual (200, tsi.MarqueeAnimationSpeed, "B1"); Assert.AreEqual (string.Empty, ew.ToString (), "B2"); ew.Clear (); tsi.MarqueeAnimationSpeed = 200; Assert.AreEqual (string.Empty, ew.ToString (), "B3"); }
public void PropertyBackColor () { ToolStripContentPanel tsp = new ToolStripContentPanel (); EventWatcher ew = new EventWatcher (tsp); tsp.BackColor = Color.Green; Assert.AreEqual (Color.Green, tsp.BackColor, "B1"); Assert.AreEqual (string.Empty, ew.ToString (), "B2"); ew.Clear (); tsp.BackColor = Color.Green; Assert.AreEqual (string.Empty, ew.ToString (), "B3"); }
public void PropertyAutoSize () { ToolStripPanel tsp = new ToolStripPanel (); EventWatcher ew = new EventWatcher (tsp); tsp.AutoSize = false; Assert.AreEqual (false, tsp.AutoSize, "B1"); Assert.AreEqual ("AutoSizeChanged", ew.ToString (), "B2"); ew.Clear (); tsp.AutoSize = false; Assert.AreEqual (string.Empty, ew.ToString (), "B3"); }
public void PropertyBackColor () { Control c = new Control (); EventWatcher ew = new EventWatcher (c); c.BackColor = Color.Aquamarine; Assert.AreEqual (Color.Aquamarine, c.BackColor, "B1"); Assert.AreEqual ("BackColorChanged", ew.ToString (), "B2"); ew.Clear (); c.BackColor = Color.Aquamarine; Assert.AreEqual (string.Empty, ew.ToString (), "B3"); }
public void PropertyCanOverflow () { ToolStrip ts = new ToolStrip (); EventWatcher ew = new EventWatcher (ts); ts.CanOverflow = false; Assert.AreEqual (false, ts.CanOverflow, "B1"); Assert.AreEqual (string.Empty, ew.ToString (), "B2"); }
public void PropertyRenderMode () { ToolStripContentPanel tsp = new ToolStripContentPanel (); EventWatcher ew = new EventWatcher (tsp); tsp.RenderMode = ToolStripRenderMode.ManagerRenderMode; Assert.AreEqual (ToolStripRenderMode.ManagerRenderMode, tsp.RenderMode, "B1"); // I refuse to call the event twice like .Net does. //Assert.AreEqual ("RendererChanged;RendererChanged", ew.ToString (), "B2"); ew.Clear (); tsp.RenderMode = ToolStripRenderMode.ManagerRenderMode; Assert.AreEqual (string.Empty, ew.ToString (), "B3"); }
public void PropertyShowItemToolTips () { ToolStrip ts = new ToolStrip (); EventWatcher ew = new EventWatcher (ts); ts.ShowItemToolTips = false; Assert.AreEqual (false, ts.ShowItemToolTips, "B1"); Assert.AreEqual (string.Empty, ew.ToString (), "B2"); }
public void PropertyTabStop () { ToolStrip ts = new ToolStrip (); EventWatcher ew = new EventWatcher (ts); ts.TabStop = true; Assert.AreEqual (true, ts.TabStop, "B1"); Assert.AreEqual (string.Empty, ew.ToString (), "B2"); }
public void PropertyRowMargin () { ToolStripPanel tsp = new ToolStripPanel (); EventWatcher ew = new EventWatcher (tsp); tsp.RowMargin = new Padding (4); Assert.AreEqual (new Padding (4), tsp.RowMargin, "B1"); Assert.AreEqual (string.Empty, ew.ToString (), "B2"); ew.Clear (); tsp.RowMargin = new Padding (4); Assert.AreEqual (string.Empty, ew.ToString (), "B3"); }
public void PropertyDefaultDropDownDirection () { ToolStrip ts = new ToolStrip (); EventWatcher ew = new EventWatcher (ts); ts.DefaultDropDownDirection = ToolStripDropDownDirection.AboveLeft; Assert.AreEqual (ToolStripDropDownDirection.AboveLeft, ts.DefaultDropDownDirection, "B1"); Assert.AreEqual (string.Empty, ew.ToString (), "B2"); }
public void PropertyImageScalingSize () { ToolStrip ts = new ToolStrip (); EventWatcher ew = new EventWatcher (ts); ts.ImageScalingSize = new Size (32, 32); Assert.AreEqual (new Size (32, 32), ts.ImageScalingSize, "B1"); Assert.AreEqual (string.Empty, ew.ToString (), "B2"); }
public void PropertyCheckState () { ToolStripButton tsi = new ToolStripButton (); EventWatcher ew = new EventWatcher (tsi); tsi.CheckState = CheckState.Checked; Assert.AreEqual (CheckState.Checked, tsi.CheckState, "B1"); Assert.AreEqual ("CheckedChanged;CheckStateChanged", ew.ToString (), "B2"); ew.Clear (); tsi.CheckState = CheckState.Checked; Assert.AreEqual (string.Empty, ew.ToString (), "B3"); }
public void PropertyGripStyle () { ToolStrip ts = new ToolStrip (); EventWatcher ew = new EventWatcher (ts); ts.GripStyle = ToolStripGripStyle.Hidden; Assert.AreEqual (ToolStripGripStyle.Hidden, ts.GripStyle, "B1"); Assert.AreEqual ("LayoutCompleted", ew.ToString (), "B2"); ew.Clear (); ts.GripStyle = ToolStripGripStyle.Hidden; Assert.AreEqual (string.Empty, ew.ToString (), "B3"); }
public void PropertyImageList () { ToolStrip ts = new ToolStrip (); EventWatcher ew = new EventWatcher (ts); ImageList il = new ImageList (); ts.ImageList = il; Assert.AreSame (il, ts.ImageList, "B1"); Assert.AreEqual (string.Empty, ew.ToString (), "B2"); }
public void PropertyGripMargin () { ToolStrip ts = new ToolStrip (); EventWatcher ew = new EventWatcher (ts); ts.GripMargin = new Padding (6); Assert.AreEqual (new Padding (6), ts.GripMargin, "B1"); Assert.AreEqual ("LayoutCompleted", ew.ToString (), "B2"); ew.Clear (); ts.GripMargin = new Padding (6); Assert.AreEqual (string.Empty, ew.ToString (), "B3"); }
public void PropertyForeColor () { ToolStrip ts = new ToolStrip (); EventWatcher ew = new EventWatcher (ts); ts.ForeColor = Color.BurlyWood; Assert.AreEqual (Color.BurlyWood, ts.ForeColor, "B1"); Assert.AreEqual ("ForeColorChanged", ew.ToString (), "B2"); ew.Clear (); ts.ForeColor = Color.BurlyWood; Assert.AreEqual (string.Empty, ew.ToString (), "B3"); }
public void PropertyFont () { ToolStrip ts = new ToolStrip (); EventWatcher ew = new EventWatcher (ts); Font f = new Font ("Arial", 12); ts.Font = f; Assert.AreSame (f, ts.Font, "B1"); Assert.AreEqual ("LayoutCompleted", ew.ToString (), "B2"); ew.Clear (); ts.Font = f; Assert.AreEqual (string.Empty, ew.ToString (), "B3"); }
public void PropertyAutoToolTip () { ToolStripButton tsi = new ToolStripButton (); EventWatcher ew = new EventWatcher (tsi); tsi.AutoToolTip = true; Assert.AreEqual (true, tsi.AutoToolTip, "B1"); Assert.AreEqual (string.Empty, ew.ToString (), "B2"); ew.Clear (); tsi.AutoToolTip = true; Assert.AreEqual (string.Empty, ew.ToString (), "B3"); }
public void PropertyDock () { ToolStripPanel tsp = new ToolStripPanel (); EventWatcher ew = new EventWatcher (tsp); tsp.Dock = DockStyle.Left; Assert.AreEqual (DockStyle.Left, tsp.Dock, "B1"); Assert.AreEqual (string.Empty, ew.ToString (), "B2"); ew.Clear (); tsp.Dock = DockStyle.Left; Assert.AreEqual (string.Empty, ew.ToString (), "B3"); }
public void PropertyCheckOnClick () { ToolStripButton tsi = new ToolStripButton (); EventWatcher ew = new EventWatcher (tsi); tsi.CheckOnClick = true; Assert.AreEqual (true, tsi.CheckOnClick, "B1"); Assert.AreEqual (string.Empty, ew.ToString (), "B2"); ew.Clear (); tsi.CheckOnClick = true; Assert.AreEqual (string.Empty, ew.ToString (), "B3"); }
public void PropertyCausesValidation () { ToolStrip ts = new ToolStrip (); EventWatcher ew = new EventWatcher (ts); ts.CausesValidation = true; Assert.AreEqual (true, ts.CausesValidation, "B1"); Assert.AreEqual ("CausesValidationChanged", ew.ToString (), "B2"); ew.Clear (); ts.CausesValidation = true; Assert.AreEqual (string.Empty, ew.ToString (), "B3"); }
public void PropertyOrientation () { ToolStripPanel tsp = new ToolStripPanel (); EventWatcher ew = new EventWatcher (tsp); tsp.Orientation = Orientation.Vertical; Assert.AreEqual (Orientation.Vertical, tsp.Orientation, "B1"); Assert.AreEqual (string.Empty, ew.ToString (), "B2"); ew.Clear (); tsp.Orientation = Orientation.Vertical; Assert.AreEqual (string.Empty, ew.ToString (), "B3"); }
public void PropertyRenderMode () { ToolStrip ts = new ToolStrip (); EventWatcher ew = new EventWatcher (ts); ts.RenderMode = ToolStripRenderMode.System; Assert.AreEqual (ToolStripRenderMode.System, ts.RenderMode, "B1"); Assert.AreEqual ("LayoutCompleted;RendererChanged", ew.ToString (), "B2"); ew.Clear (); ts.RenderMode = ToolStripRenderMode.System; Assert.AreEqual ("LayoutCompleted;RendererChanged", ew.ToString (), "B3"); }
public void PropertyLayoutStyle () { ToolStrip ts = new ToolStrip (); EventWatcher ew = new EventWatcher (ts); ts.LayoutStyle = ToolStripLayoutStyle.VerticalStackWithOverflow; Assert.AreEqual (ToolStripLayoutStyle.VerticalStackWithOverflow, ts.LayoutStyle, "B1"); Assert.AreEqual ("LayoutCompleted;LayoutStyleChanged", ew.ToString (), "B2"); ew.Clear (); ts.LayoutStyle = ToolStripLayoutStyle.VerticalStackWithOverflow; Assert.AreEqual (string.Empty, ew.ToString (), "B3"); }
public void PropertyCursor () { ToolStrip ts = new ToolStrip (); EventWatcher ew = new EventWatcher (ts); ts.Cursor = Cursors.Cross; Assert.AreEqual (Cursors.Cross, ts.Cursor, "B1"); Assert.AreEqual ("CursorChanged", ew.ToString (), "B2"); ew.Clear (); ts.Cursor = Cursors.Cross; Assert.AreEqual (string.Empty, ew.ToString (), "B3"); }
public void PropertyLocked () { ToolStripPanel tsp = new ToolStripPanel (); EventWatcher ew = new EventWatcher (tsp); tsp.Locked = true; Assert.AreEqual (true, tsp.Locked, "B1"); Assert.AreEqual (string.Empty, ew.ToString (), "B2"); ew.Clear (); tsp.Locked = true; Assert.AreEqual (string.Empty, ew.ToString (), "B3"); }
public void PropertyRenderer () { ToolStrip ts = new ToolStrip (); EventWatcher ew = new EventWatcher (ts); ToolStripProfessionalRenderer pr = new ToolStripProfessionalRenderer (); ts.Renderer = pr; Assert.AreSame (pr, ts.Renderer, "B1"); Assert.AreEqual ("LayoutCompleted;RendererChanged", ew.ToString (), "B2"); Assert.AreEqual (ToolStripRenderMode.Custom, ts.RenderMode, "B4"); ew.Clear (); ts.Renderer = pr; Assert.AreEqual (string.Empty, ew.ToString (), "B3"); }