Author: lluis
Date: 2007-02-20 15:21:29 -0500 (Tue, 20 Feb 2007)
New Revision: 73214

Modified:
   trunk/stetic/ChangeLog
   trunk/stetic/libstetic/editor/ActionMenu.cs
   trunk/stetic/libstetic/wrapper/Action.cs
   trunk/stetic/libsteticui/ActionGroupEditSession.cs
Log:
* libsteticui/ActionGroupEditSession.cs: Added null check.
* libstetic/wrapper/Action.cs: Don't set the type to Radio unless a
  real group name is provided.
* libstetic/editor/ActionMenu.cs: Set AppPaintable, since we do some
  custom painting in the Expose event. Also call the base
  OnExposeEvent after painting the background. Fixes bug #80864.

Modified: trunk/stetic/ChangeLog
===================================================================
--- trunk/stetic/ChangeLog      2007-02-20 19:33:55 UTC (rev 73213)
+++ trunk/stetic/ChangeLog      2007-02-20 20:21:29 UTC (rev 73214)
@@ -1,5 +1,14 @@
+2007-02-20  Lluis Sanchez Gual <[EMAIL PROTECTED]> 
 
+       * libsteticui/ActionGroupEditSession.cs: Added null check.
+       * libstetic/wrapper/Action.cs: Don't set the type to Radio unless a
+         real group name is provided.
+       * libstetic/editor/ActionMenu.cs: Set AppPaintable, since we do some
+         custom painting in the Expose event. Also call the base
+         OnExposeEvent after painting the background. Fixes bug #80864.
 
+
+
 2007-02-19  Nate Hancock <[EMAIL PROTECTED]>
 
        * libstetic/wrapper/object.xml: Gtk.ToggleButton now has base class 

Modified: trunk/stetic/libstetic/editor/ActionMenu.cs
===================================================================
--- trunk/stetic/libstetic/editor/ActionMenu.cs 2007-02-20 19:33:55 UTC (rev 
73213)
+++ trunk/stetic/libstetic/editor/ActionMenu.cs 2007-02-20 20:21:29 UTC (rev 
73214)
@@ -33,6 +33,7 @@
                        table.ColumnSpacing = 5;
                        table.RowSpacing = 5;
                        table.BorderWidth = 5;
+                       this.AppPaintable = true;
                        
                        Add (table);
                        
@@ -239,12 +240,13 @@
                
                protected override bool OnExposeEvent (Gdk.EventExpose ev)
                {
-                       bool r = base.OnExposeEvent (ev);
                        int w, h;
                        this.GdkWindow.GetSize (out w, out h);
                        Gdk.Rectangle clip = new Gdk.Rectangle (0,0,w,h);
                        Gtk.Style.PaintBox (this.Style, this.GdkWindow, 
Gtk.StateType.Normal, Gtk.ShadowType.Out, clip, this, "menu", 0, 0, w, h);
                        
+                       bool r = base.OnExposeEvent (ev);
+                       
                        if (dropPosition != -1) {
                                GdkWindow.DrawRectangle (this.Style.BlackGC, 
true, 0, dropPosition - 1, w - 2, 3);
                        }

Modified: trunk/stetic/libstetic/wrapper/Action.cs
===================================================================
--- trunk/stetic/libstetic/wrapper/Action.cs    2007-02-20 19:33:55 UTC (rev 
73213)
+++ trunk/stetic/libstetic/wrapper/Action.cs    2007-02-20 20:21:29 UTC (rev 
73214)
@@ -177,7 +177,8 @@
                                return GroupManager.GetGroup (this);
                        }
                        set {
-                               Type = ActionType.Radio;
+                               if (value != null && value.Length > 0)
+                                       Type = ActionType.Radio;
                                GroupManager.SetGroup (this, value);
                                EmitNotify ("Group");
                        }

Modified: trunk/stetic/libsteticui/ActionGroupEditSession.cs
===================================================================
--- trunk/stetic/libsteticui/ActionGroupEditSession.cs  2007-02-20 19:33:55 UTC 
(rev 73213)
+++ trunk/stetic/libsteticui/ActionGroupEditSession.cs  2007-02-20 20:21:29 UTC 
(rev 73214)
@@ -145,11 +145,13 @@
                {
                        // Called when the underlying project has changed. 
Object references need to be updated.
                        if (autoCommitChanges) {
-                               if (groupToEdit != null) {
-                                       groupToolbar.ActiveGroup = 
project.ActionGroups [groupToEdit];
-                               } else {
-                                       Stetic.Wrapper.Container container = 
project.GetTopLevelWrapper (containerName, true);
-                                       groupToolbar.ActionGroups = 
container.LocalActionGroups;
+                               if (designer != null) {
+                                       if (groupToEdit != null) {
+                                               groupToolbar.ActiveGroup = 
project.ActionGroups [groupToEdit];
+                                       } else {
+                                               Stetic.Wrapper.Container 
container = project.GetTopLevelWrapper (containerName, true);
+                                               groupToolbar.ActionGroups = 
container.LocalActionGroups;
+                                       }
                                }
                        } else {
                                // We only need to remap the actions

_______________________________________________
Mono-patches maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches

Reply via email to