[Monodevelop-patches-list] r2172 - in trunk/MonoDevelop: . Core/src/AddIns/DisplayBindings/SourceEditor Core/src/AddIns/DisplayBindings/SourceEditor/Gui Core/src/MonoDevelop.Base Core/src/MonoDevelop.Base/Gui/BrowserDisplayBinding Core/src/MonoDevelop.Base/Services/DisplayBinding Core/src/MonoDevelop.Base/Services/File Core/src/MonoDevelop.Gui.Utils Core/src/MonoDevelop.Gui.Widgets Core/src/MonoDevelop.Gui.Widgets/FileBrowser

commit-watcher at mono-cvs.ximian.com commit-watcher at mono-cvs.ximian.com
Wed Jan 26 20:13:34 EST 2005


Author: jluke
Date: 2005-01-26 20:13:34 -0500 (Wed, 26 Jan 2005)
New Revision: 2172

Removed:
   trunk/MonoDevelop/Core/src/MonoDevelop.Gui.Utils/VFS/
Modified:
   trunk/MonoDevelop/ChangeLog
   trunk/MonoDevelop/Core/src/AddIns/DisplayBindings/SourceEditor/ChangeLog
   trunk/MonoDevelop/Core/src/AddIns/DisplayBindings/SourceEditor/Gui/SourceEditorDisplayBinding.cs
   trunk/MonoDevelop/Core/src/AddIns/DisplayBindings/SourceEditor/Makefile.am
   trunk/MonoDevelop/Core/src/MonoDevelop.Base/ChangeLog
   trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/BrowserDisplayBinding/BrowserDisplayBinding.cs
   trunk/MonoDevelop/Core/src/MonoDevelop.Base/Makefile.am
   trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/DisplayBinding/DisplayBindingService.cs
   trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/File/DefaultFileService.cs
   trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/File/RecentOpen.cs
   trunk/MonoDevelop/Core/src/MonoDevelop.Gui.Utils/ChangeLog
   trunk/MonoDevelop/Core/src/MonoDevelop.Gui.Utils/Makefile.am
   trunk/MonoDevelop/Core/src/MonoDevelop.Gui.Widgets/ChangeLog
   trunk/MonoDevelop/Core/src/MonoDevelop.Gui.Widgets/FileBrowser/FileBrowser.cs
   trunk/MonoDevelop/Core/src/MonoDevelop.Gui.Widgets/Makefile.am
   trunk/MonoDevelop/configure.in
Log:
use Gnome.Vfs from Gtk# instead of our internal wrapper


Modified: trunk/MonoDevelop/ChangeLog
===================================================================
--- trunk/MonoDevelop/ChangeLog	2005-01-27 00:33:22 UTC (rev 2171)
+++ trunk/MonoDevelop/ChangeLog	2005-01-27 01:13:34 UTC (rev 2172)
@@ -1,3 +1,7 @@
+2005-01-26  John Luke  <john.luke at gmail.com>
+
+	* configure.in: check for gnome-vfs
+
 2005-01-14  Lluis Sanchez Gual  <lluis at novell.com>
 
 	* configure.in: Removed some obsolete files from build.

Modified: trunk/MonoDevelop/Core/src/AddIns/DisplayBindings/SourceEditor/ChangeLog
===================================================================
--- trunk/MonoDevelop/Core/src/AddIns/DisplayBindings/SourceEditor/ChangeLog	2005-01-27 00:33:22 UTC (rev 2171)
+++ trunk/MonoDevelop/Core/src/AddIns/DisplayBindings/SourceEditor/ChangeLog	2005-01-27 01:13:34 UTC (rev 2172)
@@ -1,3 +1,8 @@
+2005-01-26  John Luke  <john.luke at gmail.com>
+
+	* Makefile.am:
+	* Gui/SourceEditorDisplayBinding.cs: use Gnome.Vfs
+
 2005-01-26  Todd Berman  <tberman at off.net>
 
 	* CodeCompletion/CompletionListWindow.cs:

Modified: trunk/MonoDevelop/Core/src/AddIns/DisplayBindings/SourceEditor/Gui/SourceEditorDisplayBinding.cs
===================================================================
--- trunk/MonoDevelop/Core/src/AddIns/DisplayBindings/SourceEditor/Gui/SourceEditorDisplayBinding.cs	2005-01-27 00:33:22 UTC (rev 2171)
+++ trunk/MonoDevelop/Core/src/AddIns/DisplayBindings/SourceEditor/Gui/SourceEditorDisplayBinding.cs	2005-01-27 01:13:34 UTC (rev 2172)
@@ -277,7 +277,7 @@
 				warnOverwrite = false;
 				editorBar.Remove (reloadBar);
 			}
-			se.Buffer.LoadFile (fileName, Vfs.GetMimeType (fileName));
+			se.Buffer.LoadFile (fileName, Gnome.Vfs.MimeType.GetMimeTypeForUri (fileName));
 			ContentName = fileName;
 			InitializeFormatter ();
 		}

Modified: trunk/MonoDevelop/Core/src/AddIns/DisplayBindings/SourceEditor/Makefile.am
===================================================================
--- trunk/MonoDevelop/Core/src/AddIns/DisplayBindings/SourceEditor/Makefile.am	2005-01-27 00:33:22 UTC (rev 2171)
+++ trunk/MonoDevelop/Core/src/AddIns/DisplayBindings/SourceEditor/Makefile.am	2005-01-27 01:13:34 UTC (rev 2172)
@@ -82,6 +82,7 @@
 	/r:$(top_builddir)/build/bin/MonoDevelop.Gui.Utils.dll \
 	/r:$(top_builddir)/build/bin/MonoDevelop.Gui.Widgets.dll \
 	$(GTK_SHARP_LIBS) \
+	$(GNOME_VFS_SHARP_LIBS) \
 	$(GLADE_SHARP_LIBS) \
 	$(GCONF_SHARP_LIBS) \
 	$(GTKSOURCEVIEW_SHARP_LIBS)

Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/ChangeLog
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/ChangeLog	2005-01-27 00:33:22 UTC (rev 2171)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/ChangeLog	2005-01-27 01:13:34 UTC (rev 2172)
@@ -1,3 +1,10 @@
+2005-01-27  John Luke  <john.luke at gmail.com>
+
+	* Makefile.am: 
+	* Services/File/RecentOpen.cs:
+	* Services/File/DefaultFileService.cs:
+	* Gui/BrowserDisplayBinding/BrowserDisplayBinding.cs: use Gnome.Vfs
+
 2005-01-27  Lluis Sanchez Gual  <lluis at novell.com>
 
 	* Gui/IWorkbench.cs:

Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/BrowserDisplayBinding/BrowserDisplayBinding.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/BrowserDisplayBinding/BrowserDisplayBinding.cs	2005-01-27 00:33:22 UTC (rev 2171)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/BrowserDisplayBinding/BrowserDisplayBinding.cs	2005-01-27 01:13:34 UTC (rev 2172)
@@ -13,7 +13,6 @@
 using MonoDevelop.Core.Properties;
 using MonoDevelop.Core.AddIns.Codons;
 using MonoDevelop.Gui;
-using MonoDevelop.Gui.Utils;
 
 namespace MonoDevelop.BrowserDisplayBinding
 {
@@ -61,7 +60,7 @@
 		public bool CanAttachTo (IViewContent parent)
 		{
 			string filename = parent.ContentName;
-			string mimetype = Vfs.GetMimeType (filename);
+			string mimetype = Gnome.Vfs.MimeType.GetMimeTypeForUri (filename);
 			if (mimetype == "text/html")
 				return true;
 			return false;

Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Makefile.am
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Makefile.am	2005-01-27 00:33:22 UTC (rev 2171)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Makefile.am	2005-01-27 01:13:34 UTC (rev 2172)
@@ -10,6 +10,7 @@
 	/r:Mono.Posix.dll \
 	$(GTK_SHARP_LIBS) \
 	$(GNOME_SHARP_LIBS) \
+	$(GNOME_VFS_SHARP_LIBS) \
 	$(GECKO_SHARP_LIBS) \
 	$(GLADE_SHARP_LIBS) \
 	$(GTKHTML_SHARP_LIBS) \

Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/DisplayBinding/DisplayBindingService.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/DisplayBinding/DisplayBindingService.cs	2005-01-27 00:33:22 UTC (rev 2171)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/DisplayBinding/DisplayBindingService.cs	2005-01-27 01:13:34 UTC (rev 2172)
@@ -13,7 +13,6 @@
 using System.CodeDom.Compiler;
 
 using MonoDevelop.Internal.Project;
-
 using MonoDevelop.Core.Services;
 using MonoDevelop.Core.AddIns;
 using MonoDevelop.Core.AddIns.Codons;
@@ -50,7 +49,7 @@
 		
 		public DisplayBindingCodon GetCodonPerFileName(string filename)
 		{
-			string mimetype = MonoDevelop.Gui.Utils.Vfs.GetMimeType (filename);
+			string mimetype = Gnome.Vfs.MimeType.GetMimeTypeForUri (filename);
 			if (!filename.StartsWith ("http")) {
 				foreach (DisplayBindingCodon binding in bindings) {
 					if (binding.DisplayBinding != null && binding.DisplayBinding.CanCreateContentForMimeType (mimetype)) {

Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/File/DefaultFileService.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/File/DefaultFileService.cs	2005-01-27 00:33:22 UTC (rev 2171)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/File/DefaultFileService.cs	2005-01-27 01:13:34 UTC (rev 2172)
@@ -10,6 +10,7 @@
 using System.Diagnostics;
 using System.IO;
 using System.Xml;
+using Vfs = Gnome.Vfs.Vfs;
 
 using MonoDevelop.Core.AddIns;
 using MonoDevelop.Core.Services;
@@ -181,13 +182,13 @@
 				}
 			} else {
 				try {
-					string mimetype = Vfs.GetMimeType (fileName);
-					Console.WriteLine ("About to MimeApp.Exec on mimetype: " + mimetype);
-					if (mimetype != null) {
-						MimeApplication.Exec (mimetype, fileName);
-					} else {
+					// FIXME: this doesn't seem finished yet in Gtk#
+					//MimeType mimetype = new MimeType (new Uri ("file://" + fileName));
+					//if (mimetype != null) {
+					//	mimetype.DefaultAction.Launch ();
+					//} else {
 						Gnome.Url.Show ("file://" + fileName);
-					}
+					//}
 				} catch {
 					if (Runtime.FileUtilityService.ObservedLoad(new NamedFileOperationDelegate (new LoadFileWrapper (Runtime.Gui.DisplayBindings.LastBinding, null, oFileInfo.BringToFront).Invoke), fileName) == FileOperationResult.OK) {
 						Runtime.FileService.RecentOpen.AddLastFile (fileName, null);

Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/File/RecentOpen.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/File/RecentOpen.cs	2005-01-27 00:33:22 UTC (rev 2171)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/File/RecentOpen.cs	2005-01-27 01:13:34 UTC (rev 2172)
@@ -10,6 +10,8 @@
 using System.Diagnostics;
 using System.Collections;
 using System.IO;
+using Vfs = Gnome.Vfs.Vfs;
+using MimeType = Gnome.Vfs.MimeType;
 
 using MonoDevelop.Core.Properties;
 using MonoDevelop.Gui.Utils;
@@ -73,7 +75,7 @@
 		
 		public void AddLastFile (string name, string project)
 		{
-			RecentItem ri = new RecentItem (new Uri (name), Vfs.GetMimeType (name), "MonoDevelop Files");
+			RecentItem ri = new RecentItem (new Uri (name), MimeType.GetMimeTypeForUri (name), "MonoDevelop Files");
 			if (project == null)
 				ri.Private = Path.GetFileName (name);
 			else
@@ -97,10 +99,9 @@
 			OnRecentProjectChange();
 		}
 		
-		public void AddLastProject (string uri, string projectName)
+		public void AddLastProject (string name, string projectName)
 		{
-			
-			RecentItem ri = new RecentItem (new Uri (uri), Vfs.GetMimeType (uri), "MonoDevelop Projects");
+			RecentItem ri = new RecentItem (new Uri (name), MimeType.GetMimeTypeForUri (name), "MonoDevelop Projects");
 			ri.Private = projectName;
 			recentFiles.AddWithLimit (ri, "MonoDevelop Projects", MAX_LENGTH);
 			UpdateLastProject ();

Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Gui.Utils/ChangeLog
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Gui.Utils/ChangeLog	2005-01-27 00:33:22 UTC (rev 2171)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Gui.Utils/ChangeLog	2005-01-27 01:13:34 UTC (rev 2172)
@@ -1,3 +1,8 @@
+2005-01-26  John Luke  <john.luke at gmail.com>
+
+	* Vfs/Vfs.cs: kill
+	* Makefile.am: remove old vfs stuff in favor of Gtk#
+
 2005-01-12  Todd Berman  <tberman at off.net>
 	
 	* FileIcons/FileIconLoader.cs: Workaround weird return values.

Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Gui.Utils/Makefile.am
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Gui.Utils/Makefile.am	2005-01-27 00:33:22 UTC (rev 2171)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Gui.Utils/Makefile.am	2005-01-27 01:13:34 UTC (rev 2172)
@@ -8,7 +8,6 @@
 FILES = \
 FileIcons/FileIconLoader.cs \
 AssemblyInfo.cs \
-VFS/Vfs.cs \
 ReportingStream/ReportingStream.cs \
 DirectoryArchive/Decompressor.cs \
 DirectoryArchive/TarDecompressor.cs \

Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Gui.Widgets/ChangeLog
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Gui.Widgets/ChangeLog	2005-01-27 00:33:22 UTC (rev 2171)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Gui.Widgets/ChangeLog	2005-01-27 01:13:34 UTC (rev 2172)
@@ -1,3 +1,8 @@
+2005-01-27  John Luke  <john.luke at gmail.com>
+
+	* Makefile.am:
+	* FileBrowser/FileBrowser.cs: use Gnome.Vfs
+
 2005-01-27  Lluis Sanchez Gual  <lluis at novell.com>
 
 	* Tree/TreeNodeCollection.cs: Save some memory.

Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Gui.Widgets/FileBrowser/FileBrowser.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Gui.Widgets/FileBrowser/FileBrowser.cs	2005-01-27 00:33:22 UTC (rev 2171)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Gui.Widgets/FileBrowser/FileBrowser.cs	2005-01-27 01:13:34 UTC (rev 2172)
@@ -11,6 +11,7 @@
 using System.Diagnostics;
 using System.IO;
 using Gtk;
+using Vfs = Gnome.Vfs.Vfs;
 
 using MonoDevelop.Core.Properties;
 using MonoDevelop.Core.Services;
@@ -59,7 +60,7 @@
 		public FileBrowser ()
 		{
 			if (!Vfs.Initialized) {
-				Vfs.Init ();
+				Vfs.Initialize ();
 			}
 
 			messageService = (IMessageService) ServiceManager.GetService (typeof (IMessageService));

Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Gui.Widgets/Makefile.am
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Gui.Widgets/Makefile.am	2005-01-27 00:33:22 UTC (rev 2171)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Gui.Widgets/Makefile.am	2005-01-27 01:13:34 UTC (rev 2172)
@@ -6,7 +6,8 @@
 	/r:$(top_builddir)/build/bin/MonoDevelop.Gui.Utils.dll \
 	$(GTK_SHARP_LIBS) \
 	$(GLADE_SHARP_LIBS) \
-	$(GNOME_SHARP_LIBS)
+	$(GNOME_SHARP_LIBS) \
+	$(GNOME_VFS_SHARP_LIBS)
 
 FILES = \
 Tree/TreeView.cs \

Modified: trunk/MonoDevelop/configure.in
===================================================================
--- trunk/MonoDevelop/configure.in	2005-01-27 00:33:22 UTC (rev 2171)
+++ trunk/MonoDevelop/configure.in	2005-01-27 01:13:34 UTC (rev 2172)
@@ -81,6 +81,8 @@
 AC_SUBST(GTK_SHARP_LIBS)
 PKG_CHECK_MODULES(GNOME_SHARP, gnome-sharp-2.0 >= $GTKSHARP_REQUIRED_VERSION)
 AC_SUBST(GNOME_SHARP_LIBS)
+PKG_CHECK_MODULES(GNOME_VFS_SHARP, gnome-vfs-sharp-2.0 >= $GTKSHARP_REQUIRED_VERSION)
+AC_SUBST(GNOME_VFS_SHARP_LIBS)
 PKG_CHECK_MODULES(GLADE_SHARP, glade-sharp-2.0 >= $GTKSHARP_REQUIRED_VERSION)
 AC_SUBST(GLADE_SHARP_LIBS)
 PKG_CHECK_MODULES(GCONF_SHARP, gconf-sharp-2.0 >= $GTKSHARP_REQUIRED_VERSION)




More information about the Monodevelop-patches-list mailing list