[Mono-bugs] [Bug 77814][Nor] New - ToolBar button with
'Enabled=false' cause whole toolbar unusability
bugzilla-daemon at bugzilla.ximian.com
bugzilla-daemon at bugzilla.ximian.com
Fri Mar 17 08:28:11 EST 2006
Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.
Changed by levap at bansky.net.
http://bugzilla.ximian.com/show_bug.cgi?id=77814
--- shadow/77814 2006-03-17 08:28:11.000000000 -0500
+++ shadow/77814.tmp.28032 2006-03-17 08:28:11.000000000 -0500
@@ -0,0 +1,143 @@
+Bug#: 77814
+Product: Mono: Class Libraries
+Version: 1.1
+OS:
+OS Details: XP SP2 Czech Version
+Status: NEW
+Resolution:
+Severity:
+Priority: Normal
+Component: Windows.Forms
+AssignedTo: peter at novonyx.com
+ReportedBy: levap at bansky.net
+QAContact: mono-bugs at ximian.com
+TargetMilestone: ---
+URL:
+Cc:
+Summary: ToolBar button with 'Enabled=false' cause whole toolbar unusability
+
+Description of Problem:
+When toolbar button has Enable property set to false
+(toolBarButton1.Enabled=false) it will makes mash from other buttons.
+
+Steps to reproduce the problem:
+1. Make toolbar with button
+2. In constructor set some button Enabled property to false
+3. run program
+
+Actual Results:
+Mash of button
+
+Expected Results:
+Toolbar buttons set folowed one by one.
+
+How often does this happen?
+Mostly when enabled=false is set from constructor
+
+Additional Information:
+
+http://bansky.net/img/MonoToolBar-Bug.png
+
+
+using System;
+using System.Drawing;
+using System.Windows.Forms;
+
+namespace TestWMF
+{
+
+ public class MainForm : System.Windows.Forms.Form
+ {
+ private System.ComponentModel.IContainer components;
+ private System.Windows.Forms.ToolBar toolBar1;
+ private System.Windows.Forms.ImageList imageList1;
+ private System.Windows.Forms.ToolBarButton toolBarButton3;
+ private System.Windows.Forms.ToolBarButton toolBarButton1;
+
+ public MainForm()
+ {
+ //
+ // The InitializeComponent() call is required for Windows Forms designer
+support.
+ //
+ InitializeComponent();
+
+ //
+ // TODO: Add constructor code after the InitializeComponent() call.
+ //
+ }
+
+ [STAThread]
+ public static void Main(string[] args)
+ {
+ Application.Run(new MainForm());
+ }
+
+ #region Windows Forms Designer generated code
+ /// <summary>
+ /// This method is required for Windows Forms designer support.
+ /// Do not change the method contents inside the source code editor. The
+Forms designer might
+ /// not be able to load this method if it was changed manually.
+ /// </summary>
+ private void InitializeComponent() {
+ this.components = new System.ComponentModel.Container();
+ System.Resources.ResourceManager resources = new
+System.Resources.ResourceManager(typeof(MainForm));
+ this.toolBarButton1 = new System.Windows.Forms.ToolBarButton();
+ this.toolBarButton3 = new System.Windows.Forms.ToolBarButton();
+ this.imageList1 = new System.Windows.Forms.ImageList(this.components);
+ this.toolBar1 = new System.Windows.Forms.ToolBar();
+ this.SuspendLayout();
+ //
+ // toolBarButton1
+ //
+ this.toolBarButton1.ImageIndex = 0;
+ //
+ // toolBarButton3
+ //
+ this.toolBarButton3.ImageIndex = 1;
+ this.toolBarButton3.Style =
+System.Windows.Forms.ToolBarButtonStyle.ToggleButton;
+ //
+ // imageList1
+ //
+ this.imageList1.ImageSize = new System.Drawing.Size(16, 16);
+ this.imageList1.ImageStream =
+((System.Windows.Forms.ImageListStreamer)(resources.GetObject("imageList1.ImageStream")));
+ this.imageList1.TransparentColor = System.Drawing.Color.Transparent;
+ //
+ // toolBar1
+ //
+ this.toolBar1.Buttons.AddRange(new System.Windows.Forms.ToolBarButton[] {
+ this.toolBarButton1,
+ this.toolBarButton3});
+ this.toolBar1.DropDownArrows = true;
+ this.toolBar1.ImageList = this.imageList1;
+ this.toolBar1.Location = new System.Drawing.Point(0, 0);
+ this.toolBar1.Name = "toolBar1";
+ this.toolBar1.ShowToolTips = true;
+ this.toolBar1.Size = new System.Drawing.Size(248, 28);
+ this.toolBar1.TabIndex = 0;
+ //
+ // MainForm
+ //
+ this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);
+ this.ClientSize = new System.Drawing.Size(248, 197);
+ this.Controls.Add(this.toolBar1);
+ this.Name = "MainForm";
+ this.Text = "MainForm";
+ this.Load += new System.EventHandler(this.MainFormLoad);
+ this.ResumeLayout(false);
+ }
+ #endregion
+
+ void MainFormLoad(object sender, System.EventArgs e)
+ {
+ toolBarButton1.Enabled = true;
+ toolBarButton3.Enabled = false;
+
+ }
+
+ }
+}
More information about the mono-bugs
mailing list