[Monodevelop-patches-list] r1778 - in trunk/MonoDevelop: . data/resources src/AddIns/DebuggerAddIn src/Libraries/MonoDevelop.Gui.Widgets src/Libraries/MonoDevelop.Gui.Widgets/DragNotebook src/Libraries/MonoDevelop.Gui.Widgets/TabLabel src/Main/Base src/Main/Base/Commands src/Main/Base/Gui/Workbench/Layouts
commit-watcher at mono-cvs.ximian.com
commit-watcher at mono-cvs.ximian.com
Fri Jun 18 10:35:16 EDT 2004
Author: tberman
Date: 2004-06-18 10:35:16 -0400 (Fri, 18 Jun 2004)
New Revision: 1778
Modified:
trunk/MonoDevelop/ChangeLog
trunk/MonoDevelop/configure.in
trunk/MonoDevelop/data/resources/Makefile.am
trunk/MonoDevelop/src/AddIns/DebuggerAddIn/ChangeLog
trunk/MonoDevelop/src/AddIns/DebuggerAddIn/Makefile.am
trunk/MonoDevelop/src/Libraries/MonoDevelop.Gui.Widgets/ChangeLog
trunk/MonoDevelop/src/Libraries/MonoDevelop.Gui.Widgets/DragNotebook/DragNotebook.cs
trunk/MonoDevelop/src/Libraries/MonoDevelop.Gui.Widgets/TabLabel/TabLabel.cs
trunk/MonoDevelop/src/Main/Base/ChangeLog
trunk/MonoDevelop/src/Main/Base/Commands/MenuItemBuilders.cs
trunk/MonoDevelop/src/Main/Base/Gui/Workbench/Layouts/SdiWorkspaceLayout.cs
Log:
lots of small fixed, makefile changes.
close bug #60356 as well, and reduce the complexity and extra arraylist crap. much much nicer now
Modified: trunk/MonoDevelop/ChangeLog
===================================================================
--- trunk/MonoDevelop/ChangeLog 2004-06-18 01:56:39 UTC (rev 1777)
+++ trunk/MonoDevelop/ChangeLog 2004-06-18 14:35:16 UTC (rev 1778)
@@ -1,5 +1,12 @@
+2004-06-18 Todd Berman <tberman at off.net>
+
+ * configure.in: change how we reference the debugger stuff, to make
+ it a bit saner. Also cleanup (by making dirtier) the PKG check stuff.
+
2004-06-14 Francisco "Paco" Martinez <paco at mfcon.com>
- * monodevelop.in -- added a missing space before an enclosing square bracket
+
+ * monodevelop.in:
+ added a missing space before an enclosing square bracket
2004-06-14 Peter Johanson <latexer at gentoo.org>
Modified: trunk/MonoDevelop/configure.in
===================================================================
--- trunk/MonoDevelop/configure.in 2004-06-18 01:56:39 UTC (rev 1777)
+++ trunk/MonoDevelop/configure.in 2004-06-18 14:35:16 UTC (rev 1778)
@@ -41,15 +41,8 @@
GECKOSHARP_REQUIRED_VERSION=0.4
MONODOC_REQUIRED_VERSION=0.16
-PKG_CHECK_MODULES(BASE_DEPENDENCIES,
-gtk-sharp >= $GTKSHARP_REQUIRED_VERSION
-glade-sharp >= $GTKSHARP_REQUIRED_VERSION
-gconf-sharp >= $GTKSHARP_REQUIRED_VERSION
-gnome-sharp >= $GTKSHARP_REQUIRED_VERSION
-gtkhtml-sharp >= $GTKSHARP_REQUIRED_VERSION
-gtksourceview-sharp >= $GTKSOURCEVIEWSHARP_REQUIRED_VERSION
-gecko-sharp >= $GECKOSHARP_REQUIRED_VERSION
-monodoc >= $MONODOC_REQUIRED_VERSION)
+PKG_CHECK_MODULES(BASE_DEPENDENCIES, gtk-sharp >= $GTKSHARP_REQUIRED_VERSION glade-sharp >= $GTKSHARP_REQUIRED_VERSION gconf-sharp >= $GTKSHARP_REQUIRED_VERSION
+gnome-sharp >= $GTKSHARP_REQUIRED_VERSION gtkhtml-sharp >= $GTKSHARP_REQUIRED_VERSION gtksourceview-sharp >= $GTKSOURCEVIEWSHARP_REQUIRED_VERSION gecko-sharp >= $GECKOSHARP_REQUIRED_VERSION monodoc >= $MONODOC_REQUIRED_VERSION)
AC_SUBST(BASE_DEPENDENCIES_LIBS)
gtksharp_prefix=`pkg-config --variable=prefix gtk-sharp`
@@ -75,8 +68,7 @@
dnl find mono debugger
MONO_DEBUGGER_REQUIRED_VERSION=0.9
PKG_CHECK_MODULES(MONO_DEBUGGER, mono-debugger >= $MONO_DEBUGGER_REQUIRED_VERSION, enable_debugger=yes, enable_debugger=no)
-debugger_prefix=`pkg-config --variable=prefix mono-debugger`
-AC_SUBST(debugger_prefix)
+AC_SUBST(MONO_DEBUGGER_LIBS)
MOZILLA_HOME="`$PKG_CONFIG --variable=libdir mozilla-gtkmozembed`"
AC_SUBST(MOZILLA_HOME)
Modified: trunk/MonoDevelop/data/resources/Makefile.am
===================================================================
--- trunk/MonoDevelop/data/resources/Makefile.am 2004-06-18 01:56:39 UTC (rev 1777)
+++ trunk/MonoDevelop/data/resources/Makefile.am 2004-06-18 14:35:16 UTC (rev 1778)
@@ -1,25 +1,5 @@
SUBDIRS = glade
EXTRA_DIST = AddIn.xsd \
-StringResources.fr.resources \
-BitmapResources.resources \
-StringResources.goisern.resources \
-StringResources.it.resources \
-StringResources.jp.resources \
SplashScreen.png \
-StringResources.kr.resources \
-StringResources.bg.resources \
-StringResources.nl.resources \
-StringResources.br.resources \
-StringResources.pl.resources \
-StringResources.cn-big.resources \
-StringResources.pt.resources \
-StringResources.cn-gb.resources \
-StringResources.resources \
-StringResources.cz.resources \
-StringResources.ro.resources \
-StringResources.de.resources \
-StringResources.ru.resources \
-StringResources.dk.resources \
-StringResources.se.resources \
-StringResources.es.resources
+StringResources.resources
Modified: trunk/MonoDevelop/src/AddIns/DebuggerAddIn/ChangeLog
===================================================================
--- trunk/MonoDevelop/src/AddIns/DebuggerAddIn/ChangeLog 2004-06-18 01:56:39 UTC (rev 1777)
+++ trunk/MonoDevelop/src/AddIns/DebuggerAddIn/ChangeLog 2004-06-18 14:35:16 UTC (rev 1778)
@@ -1,3 +1,7 @@
+2004-06-18 Todd Berman <tberman at off.net>
+
+ * Makefile.am: use pkg-config properly.
+
2004-06-12 Martin Baulig <martin at ximian.com>
* Makefile.am: enable the debugger again.
Modified: trunk/MonoDevelop/src/AddIns/DebuggerAddIn/Makefile.am
===================================================================
--- trunk/MonoDevelop/src/AddIns/DebuggerAddIn/Makefile.am 2004-06-18 01:56:39 UTC (rev 1777)
+++ trunk/MonoDevelop/src/AddIns/DebuggerAddIn/Makefile.am 2004-06-18 14:35:16 UTC (rev 1778)
@@ -4,7 +4,7 @@
ADDIN = $(srcdir)/MonoDevelopDebugger.addin.xml
DLLS = $(BASE_DEPENDENCIES_LIBS) \
- /r:$(debugger_prefix)/lib/Mono.Debugger.dll \
+ $(MONO_DEBUGGER_LIBS) \
/r:../../../build/bin/MonoDevelop.Base.dll \
/r:../../../build/bin/MonoDevelop.Core.dll
Modified: trunk/MonoDevelop/src/Libraries/MonoDevelop.Gui.Widgets/ChangeLog
===================================================================
--- trunk/MonoDevelop/src/Libraries/MonoDevelop.Gui.Widgets/ChangeLog 2004-06-18 01:56:39 UTC (rev 1777)
+++ trunk/MonoDevelop/src/Libraries/MonoDevelop.Gui.Widgets/ChangeLog 2004-06-18 14:35:16 UTC (rev 1778)
@@ -1,3 +1,9 @@
+2004-06-18 Todd Berman <tberman at sevenl.net>
+
+ * DragNotebook/DragNotebook.cs: add an event that gets fired when
+ a tab is reordered.
+ * TabLabel/TabLabel.cs: try to make this widget unfocusable (untested)
+
2004-06-17 John Luke <jluke at cfl.rr.com>
* FileSelector/FileSelector.cs: a thin wrapper for selecting files
Modified: trunk/MonoDevelop/src/Libraries/MonoDevelop.Gui.Widgets/DragNotebook/DragNotebook.cs
===================================================================
--- trunk/MonoDevelop/src/Libraries/MonoDevelop.Gui.Widgets/DragNotebook/DragNotebook.cs 2004-06-18 01:56:39 UTC (rev 1777)
+++ trunk/MonoDevelop/src/Libraries/MonoDevelop.Gui.Widgets/DragNotebook/DragNotebook.cs 2004-06-18 14:35:16 UTC (rev 1778)
@@ -16,13 +16,16 @@
}*/
namespace MonoDevelop.Gui.Widgets
{
+
+ public delegate void TabsReorderedHandler (Widget widget, int oldPlacement, int newPlacement);
+
public class DragNotebook : Notebook {
protected bool draginprogress = false;
protected int srcpage;
protected double xstart;
protected double ystart;
protected Cursor cursor;
-
+
public DragNotebook ()
{
this.ButtonPressEvent += new ButtonPressEventHandler (ButtonPressCallback);
@@ -76,10 +79,7 @@
return -1;
}
- protected void OnTabsReordered ()
- {
-
- }
+ public event TabsReorderedHandler OnTabsReordered;
[GLib.ConnectBefore]
protected void MotionNotifyCallback (object obj, MotionNotifyEventArgs args)
@@ -114,6 +114,8 @@
curpage = this.GetNthPage (curpagenum);
tab = this.GetTabLabel (curpage);
this.ReorderChild (CurrentPageWidget, destpagenum);
+ if (OnTabsReordered != null)
+ OnTabsReordered (CurrentPageWidget, curpagenum, destpagenum);
}
}
@@ -137,7 +139,7 @@
protected void DragStop ()
{
if (draginprogress) {
- OnTabsReordered();
+ //OnTabsReordered();
}
draginprogress = false;
Modified: trunk/MonoDevelop/src/Libraries/MonoDevelop.Gui.Widgets/TabLabel/TabLabel.cs
===================================================================
--- trunk/MonoDevelop/src/Libraries/MonoDevelop.Gui.Widgets/TabLabel/TabLabel.cs 2004-06-18 01:56:39 UTC (rev 1777)
+++ trunk/MonoDevelop/src/Libraries/MonoDevelop.Gui.Widgets/TabLabel/TabLabel.cs 2004-06-18 14:35:16 UTC (rev 1778)
@@ -17,7 +17,7 @@
private Gtk.Image icon;
private Button btn;
- public TabLabel (Label label, Gtk.Image icon) : base (GType)
+ public TabLabel (Label label, Gtk.Image icon) : base (false, 2)
{
this.icon = icon;
this.PackStart (icon, false, true, 2);
@@ -30,6 +30,7 @@
btn.Relief = ReliefStyle.None;
btn.SetSizeRequest (18, 18);
this.PackStart (btn, false, false, 2);
+ this.ClearFlag (WidgetFlags.CanFocus);
this.ShowAll ();
}
@@ -50,15 +51,5 @@
{
get { return btn; }
}
-
- public static new GLib.GType GType
- {
- get
- {
- if (gtype == GLib.GType.Invalid)
- gtype = RegisterGType (typeof (TabLabel));
- return gtype;
- }
- }
}
}
Modified: trunk/MonoDevelop/src/Main/Base/ChangeLog
===================================================================
--- trunk/MonoDevelop/src/Main/Base/ChangeLog 2004-06-18 01:56:39 UTC (rev 1777)
+++ trunk/MonoDevelop/src/Main/Base/ChangeLog 2004-06-18 14:35:16 UTC (rev 1778)
@@ -1,3 +1,10 @@
+2004-06-18 Todd Berman <tberman at off.net>
+
+ * Commands/MenuItemBuilders.cs: clean up accel path code.
+ * Gui/Workbench/Layouts/SdiWorkspaceLayout.cs: reduce code complexity
+ by removing the extra ArrayList. Also properly use the tab reordering
+ event, closes bug #60356.
+
2004-06-17 John Luke <jluke at cfl.rr.com>
* Commands/ProjectBrowserCommands/ResourceFolderNodeCommands.cs:
Modified: trunk/MonoDevelop/src/Main/Base/Commands/MenuItemBuilders.cs
===================================================================
--- trunk/MonoDevelop/src/Main/Base/Commands/MenuItemBuilders.cs 2004-06-18 01:56:39 UTC (rev 1777)
+++ trunk/MonoDevelop/src/Main/Base/Commands/MenuItemBuilders.cs 2004-06-18 14:35:16 UTC (rev 1778)
@@ -238,14 +238,13 @@
}
item.Description = GettextCatalog.GetString ("Activate this window");
if (i + 1 <= 9) {
- string accel_path = "<MonoDevelop>/MainWindow/" + content.WorkbenchWindow.Title + (i + 1).ToString ();
+ string accel_path = "<MonoDevelop>/MainWindow/OpenContents_" + (i + 1).ToString ();
if (!Gtk.Accel.MapLookupEntry (accel_path, new Gtk.AccelKey ())) {
Gtk.Accel.MapAddEntry (accel_path, Gdk.Keyval.FromName ((i + 1).ToString ()), Gdk.ModifierType.Mod1Mask);
- item.AccelPath = accel_path;
} else {
Gtk.Accel.MapChangeEntry (accel_path, Gdk.Keyval.FromName ((i + 1).ToString()), Gdk.ModifierType.Mod1Mask, true);
- item.AccelPath = accel_path;
}
+ item.AccelPath = accel_path;
}
items[i] = item;
}
Modified: trunk/MonoDevelop/src/Main/Base/Gui/Workbench/Layouts/SdiWorkspaceLayout.cs
===================================================================
--- trunk/MonoDevelop/src/Main/Base/Gui/Workbench/Layouts/SdiWorkspaceLayout.cs 2004-06-18 01:56:39 UTC (rev 1777)
+++ trunk/MonoDevelop/src/Main/Base/Gui/Workbench/Layouts/SdiWorkspaceLayout.cs 2004-06-18 14:35:16 UTC (rev 1778)
@@ -48,8 +48,6 @@
DragNotebook tabControl;
EventHandler contextChangedHandler;
- ArrayList _windows = new ArrayList ();
-
public SdiWorkbenchLayout () {
contextChangedHandler = new EventHandler (onContextChanged);
}
@@ -59,7 +57,7 @@
if (tabControl == null || tabControl.CurrentPage < 0 || tabControl.CurrentPage >= tabControl.NPages) {
return null;
}
- return (IWorkbenchWindow)_windows[tabControl.CurrentPage];
+ return (IWorkbenchWindow)workbench.ViewContentCollection[tabControl.CurrentPage].WorkbenchWindow;
}
}
@@ -98,6 +96,7 @@
tabControl.Scrollable = true;
tabControl.ShowTabs = false;
tabControl.SwitchPage += new SwitchPageHandler (ActiveMdiChanged);
+ tabControl.OnTabsReordered += new TabsReorderedHandler (TabsReordered);
DockItem item = new DockItem ("Documents", "Documents",
DockItemBehavior.Locked);
item.PreferredWidth = -2;
@@ -140,6 +139,16 @@
workbench.ContextChanged += contextChangedHandler;
}
+ void TabsReordered (Widget widget, int oldPlacement, int newPlacement)
+ {
+ lock (workbench.ViewContentCollection) {
+ IViewContent content = workbench.ViewContentCollection[oldPlacement];
+ workbench.ViewContentCollection.RemoveAt (oldPlacement);
+ workbench.ViewContentCollection.Insert (newPlacement, content);
+
+ }
+ }
+
void onContextChanged (object o, EventArgs e)
{
SwitchContext (workbench.Context);
@@ -408,8 +417,6 @@
sdiWorkspaceWindow.CloseEvent += new EventHandler(CloseWindowEvent);
//sdiWorkspaceWindow.SwitchView(tabControl.Children.Length - 1);
- _windows.Add (sdiWorkspaceWindow);
-
tabControl.AppendPage (sdiWorkspaceWindow, tabLabel);
if (tabControl.NPages > 1)
@@ -435,13 +442,12 @@
}
}
if (pageNum != -1) {
- ((SdiWorkspaceWindow)_windows [pageNum]).CloseWindow (false, false, pageNum);
+ workbench.ViewContentCollection [pageNum].WorkbenchWindow.CloseWindow (false, false, pageNum);
}
}
public void RemoveTab (int pageNum) {
tabControl.RemovePage (pageNum);
- _windows.RemoveAt (pageNum);
if (tabControl.NPages == 1)
tabControl.ShowTabs = false;
}
More information about the Monodevelop-patches-list
mailing list