[Monodevelop-patches-list] r1649 - in trunk/MonoDevelop: build/AddIns src/Main/Base src/Main/Base/Gui/Dialogs/ReferenceDialog
commit-watcher at mono-cvs.ximian.com
commit-watcher at mono-cvs.ximian.com
Wed May 26 20:00:08 EDT 2004
Author: tberman
Date: 2004-05-26 20:00:08 -0400 (Wed, 26 May 2004)
New Revision: 1649
Modified:
trunk/MonoDevelop/build/AddIns/SharpDevelopCore.addin.xml
trunk/MonoDevelop/src/Main/Base/ChangeLog
trunk/MonoDevelop/src/Main/Base/Gui/Dialogs/ReferenceDialog/SelectReferenceDialog.cs
Log:
usability fixes from edd, and a string change.
Modified: trunk/MonoDevelop/build/AddIns/SharpDevelopCore.addin.xml
===================================================================
--- trunk/MonoDevelop/build/AddIns/SharpDevelopCore.addin.xml 2004-05-26 23:52:20 UTC (rev 1648)
+++ trunk/MonoDevelop/build/AddIns/SharpDevelopCore.addin.xml 2004-05-27 00:00:08 UTC (rev 1649)
@@ -129,7 +129,7 @@
<Extension path = "/SharpDevelop/Views/ProjectBrowser/ContextMenu/ReferenceFolderNode">
<MenuItem id = "AddReference"
- _label = "Add Reference"
+ _label = "Edit References"
class = "MonoDevelop.Commands.ProjectBrowser.AddReferenceToProject"/>
</Extension>
Modified: trunk/MonoDevelop/src/Main/Base/ChangeLog
===================================================================
--- trunk/MonoDevelop/src/Main/Base/ChangeLog 2004-05-26 23:52:20 UTC (rev 1648)
+++ trunk/MonoDevelop/src/Main/Base/ChangeLog 2004-05-27 00:00:08 UTC (rev 1649)
@@ -1,5 +1,12 @@
2004-05-26 Todd Berman <tberman at sevenl.net>
+ * Gui/Dialogs/ReferenceDialog/SelectReferenceDialog.cs: fix up
+ per edd's suggestions. Now we select a valid node if possible when
+ you remove, and the remove button is only sensitive when an iter is
+ selected.
+
+2004-05-26 Todd Berman <tberman at sevenl.net>
+
* Services/ProjectService/DefaultProjectService.cs: move the call to
GenerateMakefiles when the solution is closed to somewhere that
actually generates a makefile.
Modified: trunk/MonoDevelop/src/Main/Base/Gui/Dialogs/ReferenceDialog/SelectReferenceDialog.cs
===================================================================
--- trunk/MonoDevelop/src/Main/Base/Gui/Dialogs/ReferenceDialog/SelectReferenceDialog.cs 2004-05-26 23:52:20 UTC (rev 1648)
+++ trunk/MonoDevelop/src/Main/Base/Gui/Dialogs/ReferenceDialog/SelectReferenceDialog.cs 2004-05-27 00:00:08 UTC (rev 1649)
@@ -31,7 +31,7 @@
[Glade.Widget] Gtk.TreeView ReferencesTreeView;
[Glade.Widget] Gtk.Button okbutton;
[Glade.Widget] Gtk.Button cancelbutton;
- [Glade.Widget] Gtk.Button RemoveReferencesButton;
+ [Glade.Widget] Gtk.Button RemoveReferenceButton;
[Glade.Widget] Gtk.Notebook mainBook;
GacReferencePanel gacRefPanel;
@@ -95,9 +95,19 @@
mainBook.AppendPage (new ProjectReferencePanel (this), new Gtk.Label (GettextCatalog.GetString ("Projects")));
mainBook.AppendPage (new AssemblyReferencePanel (this), new Gtk.Label (GettextCatalog.GetString (".Net Assembly")));
//comTabPage.Controls.Add(new COMReferencePanel(this));
+ ReferencesTreeView.Selection.Changed += new EventHandler (onChanged);
AddReferenceDialog.ShowAll ();
+ onChanged (null, null);
}
+ void onChanged (object o, EventArgs e)
+ {
+ if (ReferencesTreeView.Selection.CountSelectedRows () > 0)
+ RemoveReferenceButton.Sensitive = true;
+ else
+ RemoveReferenceButton.Sensitive = false;
+ }
+
void AddNonGacReference (ProjectReference refInfo)
{
refTreeStore.AppendValues (System.IO.Path.GetFileName (refInfo.Reference), refInfo.ReferenceType.ToString (), System.IO.Path.GetFullPath (refInfo.GetReferencedFileName (configureProject)), refInfo);
@@ -166,7 +176,19 @@
gacRefPanel.SignalRefChange ((string)refTreeStore.GetValue (iter, 2), false);
break;
}
- refTreeStore.Remove (ref iter);
+ Gtk.TreeIter newIter = iter;
+ if (refTreeStore.IterNext (out newIter)) {
+ ReferencesTreeView.Selection.SelectIter (newIter);
+ refTreeStore.Remove (ref iter);
+ } else {
+ Gtk.TreePath path = refTreeStore.GetPath (iter);
+ if (path.Prev ()) {
+ ReferencesTreeView.Selection.SelectPath (path);
+ refTreeStore.Remove (ref iter);
+ } else {
+ refTreeStore.Remove (ref iter);
+ }
+ }
}
}
}
More information about the Monodevelop-patches-list
mailing list