Author: marek
Date: 2008-01-11 05:52:56 -0500 (Fri, 11 Jan 2008)
New Revision: 92661

Modified:
   trunk/stetic/ChangeLog
   trunk/stetic/libstetic/editor/ActionGroupEditor.cs
   trunk/stetic/libstetic/editor/ActionMenu.cs
   trunk/stetic/libstetic/editor/ActionMenuBar.cs
   trunk/stetic/libstetic/editor/ActionToolbar.cs
   trunk/stetic/libstetic/undo/ActionDiffAdaptor.cs
Log:
2008-01-11  Marek Safar <[EMAIL PROTECTED]> 

        * libstetic/editor/ActionMenu.cs, libstetic/editor/ActionMenuBar.cs,
        libstetic/editor/ActionToolbar.cs, libstetic/undo/ActionDiffAdaptor.cs
        libstetic/editor/ActionGroupEditor.cs: Build with the latest gmcs.
        


Modified: trunk/stetic/ChangeLog
===================================================================
--- trunk/stetic/ChangeLog      2008-01-11 10:35:16 UTC (rev 92660)
+++ trunk/stetic/ChangeLog      2008-01-11 10:52:56 UTC (rev 92661)
@@ -1,5 +1,11 @@
 2008-01-11  Marek Safar <[EMAIL PROTECTED]> 
 
+       * libstetic/editor/ActionMenu.cs, libstetic/editor/ActionMenuBar.cs,
+       libstetic/editor/ActionToolbar.cs, libstetic/undo/ActionDiffAdaptor.cs
+       libstetic/editor/ActionGroupEditor.cs: Build with the latest gmcs.
+
+2008-01-11  Marek Safar <[EMAIL PROTECTED]> 
+
        * libsteticui/ActionGroupToolbar.cs: Build with the latest gmcs.
 
 2008-01-08  Lluis Sanchez Gual <[EMAIL PROTECTED]> 

Modified: trunk/stetic/libstetic/editor/ActionGroupEditor.cs
===================================================================
--- trunk/stetic/libstetic/editor/ActionGroupEditor.cs  2008-01-11 10:35:16 UTC 
(rev 92660)
+++ trunk/stetic/libstetic/editor/ActionGroupEditor.cs  2008-01-11 10:52:56 UTC 
(rev 92661)
@@ -88,7 +88,7 @@
                                        actionGroup.ObjectChanged -= 
OnGroupChanged;
                                        actionGroup.ActionAdded -= 
OnActionAdded;
                                        actionGroup.ActionRemoved -= 
OnActionRemoved;
-                                       foreach (Action a in 
actionGroup.Actions)
+                                       foreach (Wrapper.Action a in 
actionGroup.Actions)
                                                a.ObjectChanged -= changedEvent;
                                }
                                actionGroup = value;
@@ -97,7 +97,7 @@
                                        actionGroup.ObjectChanged += 
OnGroupChanged;
                                        actionGroup.ActionAdded += 
OnActionAdded;
                                        actionGroup.ActionRemoved += 
OnActionRemoved;
-                                       foreach (Action a in 
actionGroup.Actions)
+                                       foreach (Wrapper.Action a in 
actionGroup.Actions)
                                                a.ObjectChanged += changedEvent;
                                }
                                Fill ();
@@ -114,12 +114,12 @@
                        set { modified = value; }
                }
                
-               public Action SelectedAction {
+               public Wrapper.Action SelectedAction {
                        get {
                                IDesignArea designArea = GetDesignArea ();
                                IObjectSelection sel = designArea.GetSelection 
();
                                if (sel != null)
-                                       return ObjectWrapper.Lookup 
(sel.DataObject) as Action;
+                                       return ObjectWrapper.Lookup 
(sel.DataObject) as Wrapper.Action;
                                else
                                        return null;
                        }
@@ -155,7 +155,7 @@
                        if (designArea == null)
                                return;
 
-                       Action selAction = null;
+                       Wrapper.Action selAction = null;
                        
                        foreach (ActionMenuItem item in items) {
                                if (designArea.IsSelected (item))
@@ -167,11 +167,11 @@
                        items.Clear ();
                        
                        if (actionGroup != null) {
-                               Action[] sortedActions = new Action 
[actionGroup.Actions.Count];
+                               Wrapper.Action[] sortedActions = new 
Wrapper.Action [actionGroup.Actions.Count];
                                actionGroup.Actions.CopyTo (sortedActions, 0);
                                Array.Sort (sortedActions, new ActionComparer 
());
                                for (int n = 0; n < sortedActions.Length; n++) {
-                                       Action action = (Action) sortedActions 
[n];
+                                       Wrapper.Action action = 
(Wrapper.Action) sortedActions [n];
                                        ActionMenuItem item = InsertAction 
(action, n);
                                        if (selAction == action)
                                                item.Select ();
@@ -190,7 +190,7 @@
                        ShowAll ();
                }
                
-               ActionMenuItem InsertAction (Action action, int n)
+               ActionMenuItem InsertAction (Wrapper.Action action, int n)
                {
                        uint row = (uint) n / columns;
                        uint col = (uint) (n % columns) * 3;
@@ -270,7 +270,7 @@
                
                void OnAddClicked (object s, Gtk.ButtonPressEventArgs args)
                {
-                       Action ac = (Action) ObjectWrapper.Create (project, new 
Gtk.Action ("", "", null, null));
+                       Wrapper.Action ac = (Wrapper.Action) 
ObjectWrapper.Create (project, new Gtk.Action ("", "", null, null));
                        ActionMenuItem item = InsertAction (ac, 
actionGroup.Actions.Count);
                        item.EditingDone += OnEditDone;
                        item.Select ();
@@ -451,7 +451,7 @@
                {
                        public int Compare (object x, object y)
                        {
-                               return string.Compare 
(((Action)x).GtkAction.Label, ((Action)y).GtkAction.Label);
+                               return string.Compare 
(((Wrapper.Action)x).GtkAction.Label, ((Wrapper.Action)y).GtkAction.Label);
                        }
                }
        }

Modified: trunk/stetic/libstetic/editor/ActionMenu.cs
===================================================================
--- trunk/stetic/libstetic/editor/ActionMenu.cs 2008-01-11 10:35:16 UTC (rev 
92660)
+++ trunk/stetic/libstetic/editor/ActionMenu.cs 2008-01-11 10:52:56 UTC (rev 
92661)
@@ -200,7 +200,7 @@
                ActionTreeNode InsertAction (int pos)
                {
                        using (wrapper.UndoManager.AtomicChange) {
-                               Action ac = (Action) ObjectWrapper.Create 
(wrapper.Project, new Gtk.Action ("", "", null, null));
+                               Wrapper.Action ac = (Wrapper.Action) 
ObjectWrapper.Create (wrapper.Project, new Gtk.Action ("", "", null, null));
                                ActionTreeNode newNode = new ActionTreeNode 
(Gtk.UIManagerItemType.Menuitem, null, ac);
                                nodes.Insert (pos, newNode);
                                ActionMenuItem item = FindMenuItem (newNode);

Modified: trunk/stetic/libstetic/editor/ActionMenuBar.cs
===================================================================
--- trunk/stetic/libstetic/editor/ActionMenuBar.cs      2008-01-11 10:35:16 UTC 
(rev 92660)
+++ trunk/stetic/libstetic/editor/ActionMenuBar.cs      2008-01-11 10:52:56 UTC 
(rev 92661)
@@ -259,7 +259,7 @@
                {
                        Widget wrapper = Widget.Lookup (this);
                        using (wrapper.UndoManager.AtomicChange) {
-                               Action ac = (Action) ObjectWrapper.Create 
(wrapper.Project, new Gtk.Action ("", "", null, null));
+                               Wrapper.Action ac = (Wrapper.Action) 
ObjectWrapper.Create (wrapper.Project, new Gtk.Action ("", "", null, null));
                                ActionTreeNode node = new ActionTreeNode 
(Gtk.UIManagerItemType.Menu, "", ac);
                                actionTree.Children.Insert (pos, node);
 

Modified: trunk/stetic/libstetic/editor/ActionToolbar.cs
===================================================================
--- trunk/stetic/libstetic/editor/ActionToolbar.cs      2008-01-11 10:35:16 UTC 
(rev 92660)
+++ trunk/stetic/libstetic/editor/ActionToolbar.cs      2008-01-11 10:52:56 UTC 
(rev 92661)
@@ -237,7 +237,7 @@
                {
                        Widget wrapper = Stetic.Wrapper.Widget.Lookup (this);
                        using (wrapper.UndoManager.AtomicChange) {
-                               Action ac = (Action) ObjectWrapper.Create 
(wrapper.Project, new Gtk.Action ("", "", null, null));
+                               Wrapper.Action ac = (Wrapper.Action) 
ObjectWrapper.Create (wrapper.Project, new Gtk.Action ("", "", null, null));
                                ActionTreeNode node = new ActionTreeNode 
(Gtk.UIManagerItemType.Toolitem, "", ac);
                                actionTree.Children.Insert (pos, node);
 

Modified: trunk/stetic/libstetic/undo/ActionDiffAdaptor.cs
===================================================================
--- trunk/stetic/libstetic/undo/ActionDiffAdaptor.cs    2008-01-11 10:35:16 UTC 
(rev 92660)
+++ trunk/stetic/libstetic/undo/ActionDiffAdaptor.cs    2008-01-11 10:52:56 UTC 
(rev 92661)
@@ -17,10 +17,10 @@
                
                public IEnumerable GetChildren (object parent)
                {
-                       if (parent is Action)
+                       if (parent is Wrapper.Action)
                                yield break;
                        else if (parent is ActionGroup) {
-                               foreach (Action ac in 
((ActionGroup)parent).Actions)
+                               foreach (Wrapper.Action ac in 
((ActionGroup)parent).Actions)
                                        if (ac.Name.Length > 0)
                                                yield return ac;
                        }
@@ -36,8 +36,8 @@
                {
                        if (childObject is ActionGroup)
                                return ((ActionGroup)childObject).UndoId;
-                       if (childObject is Action)
-                               return ((Action)childObject).UndoId;
+                       if (childObject is Wrapper.Action)
+                               return ((Wrapper.Action)childObject).UndoId;
 
                        throw new NotImplementedException ();
                }
@@ -46,7 +46,7 @@
                {
                        foreach (object ob in GetChildren (parent))
                                if (GetUndoId (ob) == undoId) {
-                                       if ((ob is Action) && 
((Action)ob).Name.Length == 0)
+                                       if ((ob is Wrapper.Action) && 
((Wrapper.Action)ob).Name.Length == 0)
                                                continue;
                                        return ob;
                                }
@@ -59,7 +59,7 @@
                        if (child == null)
                                return;
                        if (parent is ActionGroup) {
-                               ((ActionGroup)parent).Actions.Remove 
((Action)child);
+                               ((ActionGroup)parent).Actions.Remove 
((Wrapper.Action)child);
                        } else if (parent is ActionGroupCollection) {
                                ((ActionGroupCollection)parent).Remove 
((ActionGroup)child);
                        } else
@@ -72,15 +72,15 @@
                        if (parent is ActionGroup) {
                                ActionGroup group = (ActionGroup) parent;
                                if (insertAfter == null)
-                                       group.Actions.Insert (0, (Action) data);
+                                       group.Actions.Insert (0, 
(Wrapper.Action) data);
                                else {
                                        for (int n=0; n<group.Actions.Count; 
n++) {
                                                if (group.Actions [n].UndoId == 
insertAfter) {
-                                                       group.Actions.Insert 
(n+1, (Action) data);
+                                                       group.Actions.Insert 
(n+1, (Wrapper.Action) data);
                                                        return;
                                                }
                                        }
-                                       group.Actions.Add ((Action) data);
+                                       group.Actions.Add ((Wrapper.Action) 
data);
                                }
                        }
                        if (parent is ActionGroupCollection) {
@@ -101,7 +101,7 @@
                
                public IEnumerable GetProperties (object obj)
                {
-                       Action action = obj as Action;
+                       Wrapper.Action action = obj as Wrapper.Action;
                        if (action != null) {
                                foreach (ItemGroup iset in 
action.ClassDescriptor.ItemGroups) {
                                        foreach (ItemDescriptor it in iset) {
@@ -131,8 +131,8 @@
                        XmlDocument doc = new XmlDocument ();
                        ObjectWriter ow = new ObjectWriter (doc, 
FileFormat.Native);
                        
-                       if (child is Action) {
-                               return ((Action)child).Write (ow);
+                       if (child is Wrapper.Action) {
+                               return ((Wrapper.Action)child).Write (ow);
                        } else if (child is ActionGroup) {
                                return ((ActionGroup)child).Write (ow);
                        }
@@ -143,7 +143,7 @@
                {
                        ObjectReader or = new ObjectReader (project, 
FileFormat.Native);
                        if (data.LocalName == "action") {
-                               Action ac = new Action ();
+                               Wrapper.Action ac = new Wrapper.Action ();
                                ac.Read (or, data);
                                return ac;
                        } else if (data.LocalName == "action-group") {
@@ -161,9 +161,9 @@
                
                public object GetPropertyByName (object obj, string name)
                {
-                       if (obj is Action) {
+                       if (obj is Wrapper.Action) {
                                if (name == "id") name = "Name";
-                               return ((Action)obj).ClassDescriptor [name];
+                               return ((Wrapper.Action)obj).ClassDescriptor 
[name];
                        }
                        else if (obj is ActionGroup) {
                                if (name == "name") return name;
@@ -186,9 +186,9 @@
                
                public string GetPropertyValue (object obj, object property)
                {
-                       if (obj is Action) {
+                       if (obj is Wrapper.Action) {
                                PropertyDescriptor prop = (PropertyDescriptor) 
property;
-                               object val = prop.GetValue 
(((Action)obj).Wrapped);
+                               object val = prop.GetValue 
(((Wrapper.Action)obj).Wrapped);
                                return prop.ValueToString (val);
                        }
                        else if (obj is ActionGroup) {
@@ -200,12 +200,12 @@
                
                public void SetPropertyValue (object obj, string name, string 
value)
                {
-                       if (obj is Action) {
+                       if (obj is Wrapper.Action) {
                                if (name == "id") name = "Name";
                                PropertyDescriptor prop = (PropertyDescriptor) 
GetPropertyByName (obj, name);
                                if (prop == null)
                                        throw new InvalidOperationException 
("Property '" + name + "' not found in object of type: " + obj.GetType ());
-                               prop.SetValue (((Action)obj).Wrapped, 
prop.StringToValue (value));
+                               prop.SetValue (((Wrapper.Action)obj).Wrapped, 
prop.StringToValue (value));
                                return;
                        }
                        else if (obj is ActionGroup) {
@@ -219,17 +219,17 @@
 
                public void ResetPropertyValue (object obj, string name)
                {
-                       if (obj is Action) {
+                       if (obj is Wrapper.Action) {
                                if (name == "id") name = "Name";
                                PropertyDescriptor prop = (PropertyDescriptor) 
GetPropertyByName (obj, name);
-                               prop.ResetValue (((Action)obj).Wrapped);
+                               prop.ResetValue (((Wrapper.Action)obj).Wrapped);
                        }
                }
                
                public IEnumerable GetSignals (object obj)
                {
-                       if (obj is Action) {
-                               foreach (Signal s in ((Action)obj).Signals)
+                       if (obj is Wrapper.Action) {
+                               foreach (Signal s in 
((Wrapper.Action)obj).Signals)
                                        yield return s;
                        }
                        else
@@ -238,7 +238,7 @@
                
                public object GetSignal (object obj, string name, string 
handler)
                {
-                       foreach (Signal s in ((Action)obj).Signals) {
+                       foreach (Signal s in ((Wrapper.Action)obj).Signals) {
                                if (s.SignalDescriptor.Name == name && 
s.Handler == handler)
                                        return s;
                        }
@@ -254,17 +254,17 @@
                
                public void AddSignal (object obj, string name, string handler)
                {
-                       SignalDescriptor sd = (SignalDescriptor) 
((Action)obj).ClassDescriptor.SignalGroups.GetItem (name);
+                       SignalDescriptor sd = (SignalDescriptor) 
((Wrapper.Action)obj).ClassDescriptor.SignalGroups.GetItem (name);
                        Signal sig = new Signal (sd);
                        sig.Handler = handler;
-                       ((Action)obj).Signals.Add (sig);
+                       ((Wrapper.Action)obj).Signals.Add (sig);
                }
                
                public void RemoveSignal (object obj, string name, string 
handler)
                {
-                       foreach (Signal sig in ((Action)obj).Signals) {
+                       foreach (Signal sig in ((Wrapper.Action)obj).Signals) {
                                if (sig.SignalDescriptor.Name == name && 
sig.Handler == handler) {
-                                       ((Action)obj).Signals.Remove (sig);
+                                       ((Wrapper.Action)obj).Signals.Remove 
(sig);
                                        return;
                                }
                        }

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

Reply via email to