[Monodevelop-patches-list] r998 - in trunk/MonoDevelop: data/resources/glade src/Libraries/MonoDevelop.Gui.Widgets/FileBrowser src/Main/Base/Gui/Dialogs/OptionPanels/IDEOptions src/Main/Base/Gui/Pads
commit-watcher at mono-cvs.ximian.com
commit-watcher at mono-cvs.ximian.com
Mon Feb 23 04:42:12 EST 2004
Author: jba
Date: 2004-02-23 04:42:11 -0500 (Mon, 23 Feb 2004)
New Revision: 998
Modified:
trunk/MonoDevelop/data/resources/glade/Base.glade
trunk/MonoDevelop/src/Libraries/MonoDevelop.Gui.Widgets/FileBrowser/FileBrowser.cs
trunk/MonoDevelop/src/Main/Base/Gui/Dialogs/OptionPanels/IDEOptions/SelectStylePanel.cs
trunk/MonoDevelop/src/Main/Base/Gui/Pads/FileScout.cs
Log:
fixed the IDE option panel, and made sure file scout obeys 'show hidden files' property
Modified: trunk/MonoDevelop/data/resources/glade/Base.glade
===================================================================
--- trunk/MonoDevelop/data/resources/glade/Base.glade 2004-02-23 07:31:37 UTC (rev 997)
+++ trunk/MonoDevelop/data/resources/glade/Base.glade 2004-02-23 09:42:11 UTC (rev 998)
@@ -1408,16 +1408,7 @@
</child>
<child>
- <widget class="GtkOptionMenu" id="option">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="history">-1</property>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
+ <placeholder/>
</child>
</widget>
</child>
Modified: trunk/MonoDevelop/src/Libraries/MonoDevelop.Gui.Widgets/FileBrowser/FileBrowser.cs
===================================================================
--- trunk/MonoDevelop/src/Libraries/MonoDevelop.Gui.Widgets/FileBrowser/FileBrowser.cs 2004-02-23 07:31:37 UTC (rev 997)
+++ trunk/MonoDevelop/src/Libraries/MonoDevelop.Gui.Widgets/FileBrowser/FileBrowser.cs 2004-02-23 09:42:11 UTC (rev 998)
@@ -48,11 +48,24 @@
init = true;
}
- /*public bool IgnoreHidden
+ // jba 23 feb 04 - reneabled this property to make the file browser obey the
+ // ignoreHidden property from the visual style option panel
+ public bool IgnoreHidden
{
get { return ignoreHidden; }
- set { ignoreHidden = value; }
- }*/
+ set {
+ /* for some reasont his code crashes (NullReferenceException on the Populate() call
+ if (ignoreHidden != value) {
+ ignoreHidden = value;
+ // redraw folder list
+ System.Console.WriteLine("before poplate call");
+ Populate ();
+ }
+ */
+
+ ignoreHidden = value;
+ }
+ }
public Gtk.TreeView TreeView
{
Modified: trunk/MonoDevelop/src/Main/Base/Gui/Dialogs/OptionPanels/IDEOptions/SelectStylePanel.cs
===================================================================
--- trunk/MonoDevelop/src/Main/Base/Gui/Dialogs/OptionPanels/IDEOptions/SelectStylePanel.cs 2004-02-23 07:31:37 UTC (rev 997)
+++ trunk/MonoDevelop/src/Main/Base/Gui/Dialogs/OptionPanels/IDEOptions/SelectStylePanel.cs 2004-02-23 09:42:11 UTC (rev 998)
@@ -47,39 +47,45 @@
Hashtable MenuToValue = new Hashtable ();
Hashtable ValueToMenu = new Hashtable ();
public Gtk.Menu ambienceMenu;
+ [Glade.Widget] public Gtk.OptionMenu option;
+
+
[Glade.Widget] public Gtk.CheckButton extensionButton;
[Glade.Widget] public Gtk.CheckButton hiddenButton;
- [Glade.Widget] public Gtk.OptionMenu option;
+
public SelectStylePanelWidget () : base ("Base.glade", "SelectStylePanel")
{
- ambienceMenu = new Gtk.Menu ();
- option.Menu = ambienceMenu;
extensionButton.Active = p.GetProperty("ICSharpCode.SharpDevelop.Gui.ProjectBrowser.ShowExtensions", true);
hiddenButton.Active = p.GetProperty("ICSharpCode.SharpDevelop.Gui.FileScout.ShowHidden", false);
- IAddInTreeNode treeNode = AddInTreeSingleton.AddInTree.GetTreeNode("/SharpDevelop/Workbench/Ambiences");
- string active = p.GetProperty ("SharpDevelop.UI.CurrentAmbience", "CSharp");
+
+// commented out by jba - 23 feb 04, deosn't seem to be used
+// ambienceMenu = new Gtk.Menu ();
+// option.Menu = ambienceMenu;
+// IAddInTreeNode treeNode = AddInTreeSingleton.AddInTree.GetTreeNode("/SharpDevelop/Workbench/Ambiences");
+//
+// string active = p.GetProperty ("SharpDevelop.UI.CurrentAmbience", "CSharp");
+//
+// //FIXME: Yes, I know for is better here
+// uint im = 0;
+// foreach (IAddInTreeNode childNode in treeNode.ChildNodes.Values)
+// {
+// Gtk.MenuItem i = Gtk.MenuItem.NewWithLabel (childNode.Codon.ID);
+// ambienceMenu.Append(i);
+// MenuToValue[i] = childNode.Codon.ID;
+// if (childNode.Codon.ID == active) {
+// option.SetHistory (im);
+// }
+// im++;
+// }
- //FIXME: Yes, I know for is better here
- uint im = 0;
- foreach (IAddInTreeNode childNode in treeNode.ChildNodes.Values)
- {
- Gtk.MenuItem i = Gtk.MenuItem.NewWithLabel (childNode.Codon.ID);
- ambienceMenu.Append(i);
- MenuToValue[i] = childNode.Codon.ID;
- if (childNode.Codon.ID == active) {
- option.SetHistory (im);
- }
- im++;
- }
-
}
public void Store()
{
p.SetProperty("ICSharpCode.SharpDevelop.Gui.ProjectBrowser.ShowExtensions", extensionButton.Active);
p.SetProperty("ICSharpCode.SharpDevelop.Gui.FileScout.ShowHidden", hiddenButton.Active);
- p.SetProperty("SharpDevelop.UI.CurrentAmbience", (string)MenuToValue[ambienceMenu.Active]);
+// p.SetProperty("SharpDevelop.UI.CurrentAmbience", (string)MenuToValue[ambienceMenu.Active]);
}
}
}
Modified: trunk/MonoDevelop/src/Main/Base/Gui/Pads/FileScout.cs
===================================================================
--- trunk/MonoDevelop/src/Main/Base/Gui/Pads/FileScout.cs 2004-02-23 07:31:37 UTC (rev 997)
+++ trunk/MonoDevelop/src/Main/Base/Gui/Pads/FileScout.cs 2004-02-23 09:42:11 UTC (rev 998)
@@ -365,8 +365,9 @@
pathEntry.Text = fb.CurrentDir;
filelister.Clear ();
- IProperties p = (IProperties) PropertyService.GetProperty ("SharpDevelop.UI.SelectStyleOptions", new DefaultProperties ());
+ PropertyService p = (PropertyService)ServiceManager.Services.GetService(typeof(PropertyService));
bool ignoreHidden = !p.GetProperty ("ICSharpCode.SharpDevelop.Gui.FileScout.ShowHidden", false);
+ fb.IgnoreHidden = ignoreHidden;
foreach (string f in fb.Files)
{
More information about the Monodevelop-patches-list
mailing list