[Monodevelop-patches-list] r2414 - in trunk/MonoDevelop: . Core/src/MonoDevelop.Base Core/src/MonoDevelop.Base/Commands Core/src/MonoDevelop.Base/Commands/VBConverter Core/src/MonoDevelop.Base/Gui/BrowserDisplayBinding Core/src/MonoDevelop.Base/Gui/Dialogs Core/src/MonoDevelop.Base/Gui/Dialogs/ReferenceDialog Core/src/MonoDevelop.Base/Gui/Dialogs/Wizard Core/src/MonoDevelop.Base/Gui/HtmlControl Core/src/MonoDevelop.Base/Gui/Pads/FileScout Core/src/MonoDevelop.Base/Gui/Pads/HelpBrowser Core/src/MonoDevelop.Base/Gui/Pads/ProjectBrowser/BrowserNode Core/src/MonoDevelop.Base/Gui/Pads/ProjectBrowser/NodeBuilder Core/src/MonoDevelop.Base/Gui/Pads/PropertyPad Core/src/MonoDevelop.Base/Gui/Pads/SolutionPad Core/src/MonoDevelop.Base/Gui/Workbench Core/src/MonoDevelop.Base/Gui/Workbench/Layouts Core/src/MonoDevelop.Base/Internal/ExternalTool Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer Core/src/MonoDevelop.Base/Internal/ProgressMonitoring Core/src/MonoDevelop.Base/Internal/Project/Combin e Core/src/MonoDevelop.Base/Internal/Project/Project Core/src/MonoDevelop.Base/Internal/Templates Core/src/MonoDevelop.Base/Services Core/src/MonoDevelop.Base/Services/DispatchService Core/src/MonoDevelop.Base/Services/DisplayBinding Core/src/MonoDevelop.Base/Services/ParserService Core/src/MonoDevelop.Startup contrib
Christian Hergert <chris@mosaix.net>
chergert at mono-cvs.ximian.com
Fri Apr 1 22:25:52 EST 2005
Author: chergert
Date: 2005-04-01 22:25:51 -0500 (Fri, 01 Apr 2005)
New Revision: 2414
Added:
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/DefaultLoggingService.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ILoggingService.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Startup/app.config
trunk/MonoDevelop/contrib/
trunk/MonoDevelop/contrib/Makefile.am
trunk/MonoDevelop/contrib/log4net.dll
trunk/MonoDevelop/contrib/log4net.license.txt
Modified:
trunk/MonoDevelop/ChangeLog
trunk/MonoDevelop/Core/src/MonoDevelop.Base/ChangeLog
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Commands/AutostartCommands.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Commands/MenuItemBuilders.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Commands/VBConverter/ConvertBuffer.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/BrowserDisplayBinding/HtmlViewPane.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/NewFileDialog.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/ReferenceDialog/AssemblyReferencePanel.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/ReferenceDialog/GacReferencePanel.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/Wizard/AbstractWizardPanel.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/Wizard/WizardDialog.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/WordCountDialog.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/HtmlControl/HtmlControl.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/HtmlControl/MozillaControl.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/FileScout/FileList.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/HelpBrowser/HelpViewer.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/HelpBrowser/MonodocTreePad.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/ProjectBrowser/BrowserNode/DirectoryNode.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/ProjectBrowser/BrowserNode/ProjectBrowserNode.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/ProjectBrowser/NodeBuilder/DefaultDotNetNodeBuilder.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/PropertyPad/PropertyPad.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/SolutionPad/TreeViewPad.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Workbench/DefaultWorkbench.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Workbench/Layouts/SdiWorkspaceLayout.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/ExternalTool/ToolLoader.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyAttribute.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyClass.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyEvent.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyField.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyMethod.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyParameter.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyProperty.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyReturnType.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/ProgressMonitoring/BaseProgressMonitor.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/ProgressMonitoring/ConsoleProgressMonitor.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Project/Combine/Combine.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Project/Project/DotNetProject.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Project/Project/IncludeFilesDialog.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Project/Project/Project.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Templates/CodeTemplateLoader.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Makefile.am
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/DispatchService/DispatchService.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/DisplayBinding/DisplayBindingService.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ParserService/AssemblyCodeCompletionDatabase.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ParserService/AssemblyInformation.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ParserService/CodeCompletionDatabase.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ParserService/DefaultParserService.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ResourceService.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/Runtime.cs
trunk/MonoDevelop/Core/src/MonoDevelop.Startup/ChangeLog
trunk/MonoDevelop/Core/src/MonoDevelop.Startup/Makefile.am
trunk/MonoDevelop/Makefile.am
trunk/MonoDevelop/configure.in
Log:
Add ILoggingService and DefaultLoggingService
New contrib/ folder for external libraries
Add MonoDevelop.exe.config for log4net configuration
Add log4net library and license
MonoDevelop.Base was converted from Console.WriteLine's to the new Logging
framework
Modified: trunk/MonoDevelop/ChangeLog
===================================================================
--- trunk/MonoDevelop/ChangeLog 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/ChangeLog 2005-04-02 03:25:51 UTC (rev 2414)
@@ -1,3 +1,11 @@
+2005-04-01 Christian Hergert <christian.hergert at gmail.com>
+
+ * contrib/: Add folder for external libraries
+ * contrib/log4net.dll: Apache Logging .NET Library
+ * contrib/log4net.license.txt: log4net license
+ * contrib/Makefile.am: Makefile for contrib libraries
+ * configure.in: Add the new Makefile.am files
+
2005-03-13 John Luke <john.luke at gmail.com>
* autogen.sh: remove libtool, autoheader, and aclocal
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/ChangeLog
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/ChangeLog 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/ChangeLog 2005-04-02 03:25:51 UTC (rev 2414)
@@ -1,3 +1,64 @@
+2005-04-01 Christian Hergert <christian.hergert at gmail.com>
+
+ * Commands/VBConverter/ConvertBuffer.cs: Convert to use new Logging
+ framework.
+ * Commands/MenuItemBuilders.cs
+ * Commands/AutostartCommands.cs
+ * Services/DefaultLoggingService.cs
+ * Services/DispatchService/DispatchService.cs
+ * Services/ILoggingService.cs: New logging service to help make debugging
+ and information logging easy.
+ * Services/Runtime.cs: Add logging service to Runtime.
+ * Services/DisplayBinding/DisplayBindingService.cs: Convert to new Logging
+ framework.
+ * Services/ResourceService.cs
+ * Services/ParserService/DefaultParserService.cs
+ * Services/ParserService/AssemblyInformation.cs
+ * Services/ParserService/AssemblyCodeCompletionDatabase.cs
+ * Services/ParserService/CodeCompletionDatabase.cs
+ * Gui/Workbench/Layouts/SdiWorkspaceLayout.cs
+ * Gui/Workbench/DefaultWorkbench.cs
+ * Gui/Dialogs/Wizard/WizardDialog.cs
+ * Gui/Dialogs/Wizard/AbstractWizardPanel.cs
+ * Gui/Dialogs/WordCountDialog.cs
+ * Gui/Dialogs/NewFileDialog.cs
+ * Gui/Dialogs/ReferenceDialog/AssemblyReferencePanel.cs
+ * Gui/Dialogs/ReferenceDialog/GacReferencePanel.cs
+ * Gui/Pads/SolutionPad/TreeViewPad.cs
+ * Gui/Pads/PropertyPad/PropertyPad.cs
+ * Gui/Pads/ProjectBrowser/BrowserNode/ProjectBrowserNode.cs
+ * Gui/Pads/ProjectBrowser/BrowserNode/DirectoryNode.cs
+ * Gui/Pads/ProjectBrowser/NodeBuilder/DefaultDotNetNodeBuilder.cs
+ * Gui/Pads/HelpBrowser/MonodocTreePad.cs
+ * Gui/Pads/HelpBrowser/HelpViewer.cs
+ * Gui/Pads/FileScout/FileList.cs
+ * Gui/BrowserDisplayBinding/HtmlViewPane.cs
+ * Gui/HtmlControl/HtmlControl.cs
+ * Gui/HtmlControl/MozillaControl.cs
+ * Makefile.am: Add new LoggingService files to build files
+ * Internal/ExternalTool/ToolLoader.cs: Update to new Logging Service
+ framework.
+ * Internal/Project/Project/DotNetProject.cs
+ * Internal/Project/Project/IncludeFilesDialog.cs
+ * Internal/Project/Project/Project.cs
+ * Internal/Project/Combine/Combine.cs
+ * Internal/ProgressMonitoring/ConsoleProgressMonitor.cs
+ * Internal/ProgressMonitoring/BaseProgressMonitor.cs
+ * Internal/Parser/SharpAssemblyLayer/SharpAssemblyParameter.cs
+ * Internal/Parser/SharpAssemblyLayer/SharpAssemblyMethod.cs
+ * Internal/Parser/SharpAssemblyLayer/SharpAssemblyReturnType.cs
+ * Internal/Parser/SharpAssemblyLayer/SharpAssemblyEvent.cs
+ * Internal/Parser/SharpAssemblyLayer/SharpAssemblyAttribute.cs
+ * Internal/Parser/SharpAssemblyLayer/SharpAssemblyField.cs
+ * Internal/Parser/SharpAssemblyLayer/SharpAssemblyProperty.cs
+ * Internal/Parser/SharpAssemblyLayer/SharpAssemblyClass.cs
+ * Internal/Templates/CodeTemplateLoader.cs
+
+2005-03-31 Christian Hergert <christian.hergert at gmail.com>
+
+ * MonoDevelopCore.addin.xml: Use proper stock icon names for
+ solution and class pads.
+
2005-03-22 John Luke <john.luke at gmail.com>
* Internal/Project/Project/DotNetProject.cs: Release configuration
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Commands/AutostartCommands.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Commands/AutostartCommands.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Commands/AutostartCommands.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -73,7 +73,7 @@
Runtime.FileService.OpenFile (file);
} catch (Exception e) {
- Console.WriteLine("unable to open file {0} exception was :\n{1}", file, e.ToString());
+ Runtime.LoggingService.InfoFormat("unable to open file {0} exception was :\n{1}", file, e.ToString());
}
}
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Commands/MenuItemBuilders.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Commands/MenuItemBuilders.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Commands/MenuItemBuilders.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -173,8 +173,8 @@
}
// debug command and args
- Console.WriteLine("command : " + command);
- Console.WriteLine("args : " + args);
+ Runtime.LoggingService.Info("command : " + command);
+ Runtime.LoggingService.Info("args : " + args);
// create the process
IProgressMonitor monitor = Runtime.TaskService.GetRunProgressMonitor ();
@@ -190,7 +190,7 @@
p = Runtime.ProcessService.StartProcess (command, args, workingDirectory, null);
p.WaitForOutput ();
- Console.WriteLine ("DONE");
+ Runtime.LoggingService.Info ("DONE");
monitor.Log.WriteLine ();
if (p.ExitCode == 0) {
@@ -278,7 +278,7 @@
public Gtk.MenuItem[] BuildSubmenu(ConditionCollection conditionCollection, object owner)
{
- Console.WriteLine (Environment.StackTrace);
+ Runtime.LoggingService.Info (Environment.StackTrace);
browser = (SolutionPad) owner;
ITreeNavigator nav = browser.GetSelectedNode ();
if (nav == null) return new Gtk.MenuItem[0];
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Commands/VBConverter/ConvertBuffer.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Commands/VBConverter/ConvertBuffer.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Commands/VBConverter/ConvertBuffer.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -49,7 +49,7 @@
VBNetVisitor vbv = new VBNetVisitor();
vbv.Visit(p.compilationUnit, null);
- Console.WriteLine(vbv.SourceText.ToString());
+ Runtime.LoggingService.Info(vbv.SourceText.ToString());
Runtime.FileService.NewFile ("Generated.VB", "VBNET", vbv.SourceText.ToString());
}
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/BrowserDisplayBinding/HtmlViewPane.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/BrowserDisplayBinding/HtmlViewPane.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/BrowserDisplayBinding/HtmlViewPane.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -58,7 +58,7 @@
GLib.Timeout.Add (50, new GLib.TimeoutHandler (checkFocus));
} catch {
- Console.WriteLine ("Gecko# tossed an exception");
+ Runtime.LoggingService.Info ("Gecko# tossed an exception");
}
}
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/NewFileDialog.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/NewFileDialog.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/NewFileDialog.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -68,7 +68,7 @@
imglist.Add(bitmap);
tmp[entry.Key] = ++i;
} else {
- Console.WriteLine(GettextCatalog.GetString ("Can't load bitmap {0} using default"), entry.Key.ToString ());
+ Runtime.LoggingService.InfoFormat(GettextCatalog.GetString ("Can't load bitmap {0} using default"), entry.Key.ToString ());
}
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/ReferenceDialog/AssemblyReferencePanel.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/ReferenceDialog/AssemblyReferencePanel.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/ReferenceDialog/AssemblyReferencePanel.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -66,7 +66,7 @@
public void AddReference(object sender, EventArgs e)
{
- //System.Console.WriteLine("This panel will contain a file browser, but so long use the browse button :)");
+ //System.Runtime.LoggingService.Info("This panel will contain a file browser, but so long use the browse button :)");
}
}
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/ReferenceDialog/GacReferencePanel.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/ReferenceDialog/GacReferencePanel.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/ReferenceDialog/GacReferencePanel.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -118,7 +118,7 @@
#if false
System.Reflection.MethodInfo gac = typeof (System.Environment).GetMethod ("internalGetGacPath", System.Reflection.BindingFlags.Static|System.Reflection.BindingFlags.NonPublic);
if (gac == null) {
- Console.WriteLine (GettextCatalog.GetString ("ERROR: non-mono runtime detected, please use the mono runtime for this piece of MonoDevelop for the time being"));
+ Runtime.LoggingService.Info (GettextCatalog.GetString ("ERROR: non-mono runtime detected, please use the mono runtime for this piece of MonoDevelop for the time being"));
Environment.Exit (1);
}
string gac_path = System.IO.Path.Combine ((string)gac.Invoke (null, null), "");
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/Wizard/AbstractWizardPanel.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/Wizard/AbstractWizardPanel.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/Wizard/AbstractWizardPanel.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -138,7 +138,7 @@
public override bool ReceiveDialogMessage (DialogMessage a)
{
- //Console.WriteLine ("In middle receive dialog message");
+ //Runtime.LoggingService.Info ("In middle receive dialog message");
return true;
}
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/Wizard/WizardDialog.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/Wizard/WizardDialog.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/Wizard/WizardDialog.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -190,7 +190,7 @@
dialogPanel.Remove (dialogPanel.Child);
}
if (CurrentWizardPane.ToString () == "MonoDevelop.Gui.Dialogs.OptionPanels.CompletionDatabaseWizard.CreationFinishedPanel") {
- Console.WriteLine ("This is an ugly hack for an even uglier bug, Restart MD now");
+ Runtime.LoggingService.Info ("This is an ugly hack for an even uglier bug, Restart MD now");
System.Environment.Exit (0);
}
dialogPanel.Add(CurrentWizardPane.Control);
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/WordCountDialog.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/WordCountDialog.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Dialogs/WordCountDialog.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -233,7 +233,7 @@
private SortType ReverseSort (SortType st)
{
- //Console.WriteLine (st);
+ //Runtime.LoggingService.Info (st);
if (st == SortType.Ascending)
return SortType.Descending;
else
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/HtmlControl/HtmlControl.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/HtmlControl/HtmlControl.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/HtmlControl/HtmlControl.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -74,7 +74,7 @@
((MozillaControl) control).LoadUrl (value);
}
else
- Console.WriteLine ("unable to load url");
+ Runtime.LoggingService.Info ("unable to load url");
}
}
@@ -115,7 +115,7 @@
this.control = new MozillaControl ();
((MozillaControl) this.control).Show ();
this.Add ((MozillaControl) this.control);
- Console.WriteLine ("added MozillaControl to HtmlControl");
+ Runtime.LoggingService.Info ("added MozillaControl to HtmlControl");
break;
default:
throw new NotImplementedException (control_type.ToString ());
@@ -155,7 +155,7 @@
if (html.Length > 0) {
ApplyBody(html);
} else {
- Console.WriteLine ("no html to apply");
+ Runtime.LoggingService.Info ("no html to apply");
}
UIActivate();
ApplyCascadingStyleSheet();
@@ -172,15 +172,15 @@
if (control != null) {
if (control_type == ControlType.GtkMozilla)
{
- Console.WriteLine ("rendering");
+ Runtime.LoggingService.Info ("rendering");
((MozillaControl) control).Show ();
((MozillaControl) control).RenderData (val, "file://", "text/html");
- Console.WriteLine ("rendered");
+ Runtime.LoggingService.Info ("rendered");
return;
}
else
{
- Console.WriteLine ("not rendering with mozilla");
+ Runtime.LoggingService.Info ("not rendering with mozilla");
}
IHTMLElement el = null;
@@ -197,17 +197,17 @@
}
else
{
- Console.WriteLine ("IHTMLElement is null");
+ Runtime.LoggingService.Info ("IHTMLElement is null");
}
}
else
{
- Console.WriteLine ("control is null");
+ Runtime.LoggingService.Info ("control is null");
}
}
catch (Exception e)
{
- Console.WriteLine (e.ToString ());
+ Runtime.LoggingService.Info (e.ToString ());
}
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/HtmlControl/MozillaControl.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/HtmlControl/MozillaControl.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/HtmlControl/MozillaControl.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -83,7 +83,7 @@
public void InitializeWithBase (string base_uri)
{
- //Console.WriteLine (base_uri);
+ //Runtime.LoggingService.Info (base_uri);
if (html.Length > 0)
{
this.RenderData (html, base_uri, "text/html");
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/FileScout/FileList.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/FileScout/FileList.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/FileScout/FileList.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -88,7 +88,7 @@
}
void ItemRemoved (FileListItem item) {
- Console.WriteLine ("remove called");
+ Runtime.LoggingService.Info ("remove called");
store.Remove (ref selectedIter);
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/HelpBrowser/HelpViewer.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/HelpBrowser/HelpViewer.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/HelpBrowser/HelpViewer.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -49,7 +49,7 @@
void UrlRequested (object sender, UrlRequestedArgs args)
{
- Console.WriteLine ("Image requested: " + args.Url);
+ Runtime.LoggingService.Info ("Image requested: " + args.Url);
Stream s = Runtime.Documentation.HelpTree.GetImage (args.Url);
if (s != null) {
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/HelpBrowser/MonodocTreePad.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/HelpBrowser/MonodocTreePad.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/HelpBrowser/MonodocTreePad.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -104,7 +104,7 @@
ShowDocs (s, match, url);
return;
}
- Console.WriteLine ("Couldnt find match");
+ Runtime.LoggingService.Info ("Couldnt find match");
}
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/ProjectBrowser/BrowserNode/DirectoryNode.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/ProjectBrowser/BrowserNode/DirectoryNode.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/ProjectBrowser/BrowserNode/DirectoryNode.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -76,7 +76,7 @@
try {
ProjectBrowserView.MoveCopyFile(file, this, effect == DragDropEffects.Move, false);
} catch (Exception ex) {
- Console.WriteLine(ex.ToString());
+ Runtime.LoggingService.Info(ex.ToString());
}
}
} else {
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/ProjectBrowser/BrowserNode/ProjectBrowserNode.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/ProjectBrowser/BrowserNode/ProjectBrowserNode.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/ProjectBrowser/BrowserNode/ProjectBrowserNode.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -58,7 +58,7 @@
try {
ProjectBrowserView.MoveCopyFile(file, this, effect == DragDropEffects.Move, false);
} catch (Exception ex) {
- Console.WriteLine(ex.ToString());
+ Runtime.LoggingService.Info(ex.ToString());
}
}
} else {
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/ProjectBrowser/NodeBuilder/DefaultDotNetNodeBuilder.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/ProjectBrowser/NodeBuilder/DefaultDotNetNodeBuilder.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/ProjectBrowser/NodeBuilder/DefaultDotNetNodeBuilder.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -333,7 +333,7 @@
break;
#endif
default:
- Console.WriteLine ("UNHANDLED TYPE {0}, DefaultDotNetNodeBuilder.cs", projectFile.Subtype);
+ Runtime.LoggingService.Info ("UNHANDLED TYPE {0}, DefaultDotNetNodeBuilder.cs", projectFile.Subtype);
// unknown file type
break;
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/PropertyPad/PropertyPad.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/PropertyPad/PropertyPad.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/PropertyPad/PropertyPad.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -54,7 +54,7 @@
public object GetService(Type serviceType)
{
-// Console.WriteLine("REQUEST SERVICE : " + serviceType);
+// Runtime.LoggingService.Info("REQUEST SERVICE : " + serviceType);
object o = container.GetService(serviceType);
return o;
@@ -68,12 +68,12 @@
protected override object GetService(Type serviceType)
{
-// Console.WriteLine("service {0} requested from IDEContainer", serviceType);
+// Runtime.LoggingService.Info("service {0} requested from IDEContainer", serviceType);
object service = base.GetService(serviceType);
if (service == null) {
service = serviceProvider.GetService(serviceType);
}
-// Console.WriteLine("Returned : " + service);
+// Runtime.LoggingService.Info("Returned : " + service);
return service;
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/SolutionPad/TreeViewPad.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/SolutionPad/TreeViewPad.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Pads/SolutionPad/TreeViewPad.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -229,18 +229,18 @@
{
ITreeNavigator nav = GetSelectedNode ();
dragObject = nav.DataItem;
- Console.WriteLine ("OnDragBegin");
+ Runtime.LoggingService.Info ("OnDragBegin");
}
void OnDragDataGet (object o, Gtk.DragDataGetArgs args)
{
- Console.WriteLine ("OnDragDataGet");
+ Runtime.LoggingService.Info ("OnDragDataGet");
args.SelectionData.Set (args.Context.Targets[0], 0, new byte[0]);
}
void OnDragDataReceived (object o, Gtk.DragDataReceivedArgs args)
{
- Console.WriteLine ("OnDragDataReceived " + args.X + " " + args.Y + " " + args.SelectionData.Length);
+ Runtime.LoggingService.Info ("OnDragDataReceived " + args.X + " " + args.Y + " " + args.SelectionData.Length);
if (dragObject != null) {
bool res = CheckAndDrop (args.X, args.Y, true);
@@ -248,7 +248,7 @@
} else {
if (args.SelectionData.Data.Length > 0) {
string fullData = System.Text.Encoding.UTF8.GetString (args.SelectionData.Data);
- Console.WriteLine ("file:" + fullData);
+ Runtime.LoggingService.Info ("file:" + fullData);
}
Gtk.Drag.Finish (args.Context, false, true, args.Time);
}
@@ -256,18 +256,18 @@
void OnDragDrop (object o, Gtk.DragDropArgs args)
{
- Console.WriteLine ("OnDragDrop " + args.X + " " + args.Y);
+ Runtime.LoggingService.Info ("OnDragDrop " + args.X + " " + args.Y);
}
void OnDragEnd (object o, Gtk.DragEndArgs args)
{
dragObject = null;
- Console.WriteLine ("OnDragEnd");
+ Runtime.LoggingService.Info ("OnDragEnd");
}
void OnDragLeave (object sender, Gtk.DragLeaveArgs args)
{
- Console.WriteLine ("OnDragLeave");
+ Runtime.LoggingService.Info ("OnDragLeave");
}
[GLib.ConnectBefore]
@@ -291,7 +291,7 @@
if (!store.GetIter (out iter, path)) return false;
TreeNodeNavigator nav = new TreeNodeNavigator (this, iter);
- Console.WriteLine ("Trying drop to " + nav.NodeName);
+ Runtime.LoggingService.Info ("Trying drop to " + nav.NodeName);
NodeBuilder[] chain = nav.BuilderChain;
bool foundHandler = false;
@@ -300,7 +300,7 @@
if (nb.CommandHandler.CanDropNode (dragObject, DragOperation.Copy)) {
foundHandler = true;
if (drop) {
- Console.WriteLine ("Droping to " + nb);
+ Runtime.LoggingService.Info ("Droping to " + nb);
nb.CommandHandler.OnNodeDrop (dragObject, DragOperation.Copy);
}
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Workbench/DefaultWorkbench.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Workbench/DefaultWorkbench.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Workbench/DefaultWorkbench.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -134,7 +134,7 @@
public DefaultWorkbench() : base (Gtk.WindowType.Toplevel)
{
Title = "MonoDevelop";
- Console.WriteLine ("Creating DefaultWorkbench");
+ Runtime.LoggingService.Info ("Creating DefaultWorkbench");
windowChangeEventHandler = new EventHandler(OnActiveWindowChanged);
@@ -179,7 +179,7 @@
else
Runtime.FileService.OpenFile (file);
} catch (Exception e) {
- Console.WriteLine("unable to open file {0} exception was :\n{1}", file, e.ToString());
+ Runtime.LoggingService.InfoFormat("unable to open file {0} exception was :\n{1}", file, e.ToString());
}
}
}
@@ -279,7 +279,7 @@
((IMementoCapable)content).SetMemento(memento);
}
} catch (Exception e) {
- Console.WriteLine("Can't get/set memento : " + e.ToString());
+ Runtime.LoggingService.Info("Can't get/set memento : " + e.ToString());
}
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Workbench/Layouts/SdiWorkspaceLayout.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Workbench/Layouts/SdiWorkspaceLayout.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Gui/Workbench/Layouts/SdiWorkspaceLayout.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -276,7 +276,7 @@
}
}
- //Console.WriteLine(" Default Layout created.");
+ //Runtime.LoggingService.Info(" Default Layout created.");
dockLayout = new DockLayout (dock);
if (System.IO.File.Exists (configFile)) {
dockLayout.LoadFromFile (configFile);
@@ -291,7 +291,7 @@
{
workbench.ContextChanged -= contextChangedHandler;
- //Console.WriteLine("Call to SdiWorkSpaceLayout.Detach");
+ //Runtime.LoggingService.Info("Call to SdiWorkSpaceLayout.Detach");
dockLayout.SaveLayout (currentLayout);
dockLayout.SaveToFile (configFile);
rootWidget.Remove(((DefaultWorkbench)workbench).TopMenu);
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/ExternalTool/ToolLoader.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/ExternalTool/ToolLoader.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/ExternalTool/ToolLoader.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -77,7 +77,7 @@
static ToolLoader()
{
if (!LoadToolsFromStream (Runtime.Properties.ConfigDirectory + TOOLFILE)) {
- //Console.WriteLine("Tools: can't load user defaults, reading system defaults");
+ //Runtime.LoggingService.Info("Tools: can't load user defaults, reading system defaults");
if (!LoadToolsFromStream (Runtime.Properties.DataDirectory +
Path.DirectorySeparatorChar + "options" +
Path.DirectorySeparatorChar + TOOLFILE)) {
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyAttribute.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyAttribute.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyAttribute.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -11,6 +11,7 @@
using System.Xml;
using System.IO;
+using MonoDevelop.Services;
using MonoDevelop.SharpAssembly.Metadata.Rows;
using MonoDevelop.SharpAssembly.Metadata;
using MonoDevelop.SharpAssembly.PE;
@@ -43,7 +44,7 @@
int table = assembly.Reader.GetCodedIndexTable(CodedIndex.MemberRefParent, ref trIndex);
if (table != 1) {
- Console.WriteLine("SharpAssemblyAttribute: unsupported MemberRefParent coded index");
+ Runtime.LoggingService.Info("SharpAssemblyAttribute: unsupported MemberRefParent coded index");
return; // unsupported
}
@@ -93,7 +94,7 @@
ushort prolog = binaryReader.ReadUInt16();
if (prolog != 1) {
- Console.WriteLine("SharpAssemblyAttribute: Wrong prolog in argument list");
+ Runtime.LoggingService.Info("SharpAssemblyAttribute: Wrong prolog in argument list");
return;
}
@@ -113,11 +114,11 @@
}
}
- Console.WriteLine("Enum: return type = " + rettypename);
+ Runtime.LoggingService.Info("Enum: return type = " + rettypename);
object argValue = GetFixedArg(argBlob, binaryReader, rettypename);
- Console.WriteLine("Enum: arg value = " + argValue.ToString());
+ Runtime.LoggingService.Info("Enum: arg value = " + argValue.ToString());
foreach (IField field in underlyingClass.Fields) {
if (field is SharpAssemblyField) {
@@ -132,7 +133,7 @@
// if the value cannot be found
positionalArguments.Add(argValue.ToString());
- Console.WriteLine("Enum: no name found");
+ Runtime.LoggingService.Info("Enum: no name found");
namefound: ;
@@ -162,8 +163,8 @@
binaryReader.Close();
} catch (Exception) {
- Console.WriteLine("SharpAssemblyAttribute: Error loading arguments.");
- //Console.WriteLine(e.ToString());
+ Runtime.LoggingService.Info("SharpAssemblyAttribute: Error loading arguments.");
+ //Runtime.LoggingService.Info(e.ToString());
}
}
@@ -231,7 +232,7 @@
try {
ret += (string)de.Key + " = " + (string)de.Value + ", ";
} catch {
- Console.WriteLine("error in namedArguments");
+ Runtime.LoggingService.Info("error in namedArguments");
}
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyClass.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyClass.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyClass.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -10,6 +10,7 @@
using System.Text;
using System.Xml;
+using MonoDevelop.Services;
using MonoDevelop.SharpAssembly.Metadata.Rows;
using MonoDevelop.SharpAssembly.Metadata;
using MonoDevelop.SharpAssembly.PE;
@@ -46,7 +47,7 @@
case 3: // TypeRef -- nested type
return GetNestedName(asm, typeRefTable, val) + "+" + asm.Reader.GetStringFromHeap(typeRefTable[index].Name);
default: // other token - not supported
- Console.WriteLine("GetNestedName: Unsupported resolution scope!");
+ Runtime.LoggingService.Info("GetNestedName: Unsupported resolution scope!");
goto case 3;
}
}
@@ -79,7 +80,7 @@
SharpAssembly_ declaringAssembly = referencingAssembly.GetRefAssemblyFor(index);
if (declaringAssembly == null) {
Console.Write("FromTypeRef failed for: " + name + " declared in assembly " + referencingAssembly.Name);
- Console.WriteLine(": Declaring assembly not found.");
+ Runtime.LoggingService.Info(": Declaring assembly not found.");
return null;
}
@@ -104,7 +105,7 @@
}
Console.Write("FromTypeRef failed for: " + name + " declared in assembly " + referencingAssembly.Name);
- Console.WriteLine(": Matching type not found for nested name: " + nestedName);
+ Runtime.LoggingService.Info(": Matching type not found for nested name: " + nestedName);
return null;
}
@@ -295,7 +296,7 @@
case 1: // TypeRef
return FromTypeRef(assembly, nIndex);
default:
- Console.WriteLine("GetTypeRefOrDefClass: Wrong TypeDefOrRef coded index!");
+ Runtime.LoggingService.Info("GetTypeRefOrDefClass: Wrong TypeDefOrRef coded index!");
return null;
}
}
@@ -431,7 +432,7 @@
IClass newclass = new SharpAssemblyClass(assembly, typeDefTable, i);
classes.Add(newclass);
} catch {
- Console.WriteLine("GetAssemblyTypes: Error loading class " + i);
+ Runtime.LoggingService.Info("GetAssemblyTypes: Error loading class " + i);
}
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyEvent.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyEvent.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyEvent.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -10,6 +10,7 @@
using System.Reflection;
using System.Xml;
+using MonoDevelop.Services;
using MonoDevelop.SharpAssembly.Metadata.Rows;
using MonoDevelop.SharpAssembly.Metadata;
using MonoDevelop.SharpAssembly.PE;
@@ -122,7 +123,7 @@
} else { // TypeSpec
returnType = new SharpAssemblyReturnType("NOT_SUPPORTED");
- Console.WriteLine("SharpAssemblyEvent: TypeSpec -- not supported");
+ Runtime.LoggingService.Info("SharpAssemblyEvent: TypeSpec -- not supported");
}
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyField.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyField.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyField.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -10,6 +10,7 @@
using System.IO;
using System.Xml;
+using MonoDevelop.Services;
using MonoDevelop.SharpAssembly.Metadata.Rows;
using MonoDevelop.SharpAssembly.Metadata;
using MonoDevelop.SharpAssembly.PE;
@@ -132,7 +133,7 @@
}
binReader.Close();
} catch {
- Console.WriteLine("SharpAssemblyField: Error reading constant value");
+ Runtime.LoggingService.Info("SharpAssemblyField: Error reading constant value");
}
}
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyMethod.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyMethod.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyMethod.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -11,6 +11,7 @@
using System.Reflection;
using System.Xml;
+using MonoDevelop.Services;
using MonoDevelop.SharpAssembly.Metadata.Rows;
using MonoDevelop.SharpAssembly.Metadata;
using MonoDevelop.SharpAssembly.PE;
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyParameter.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyParameter.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyParameter.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -10,6 +10,7 @@
using System.Reflection;
using System.Xml;
+using MonoDevelop.Services;
using MonoDevelop.SharpAssembly.Metadata.Rows;
using MonoDevelop.SharpAssembly.Metadata;
using MonoDevelop.SharpAssembly.PE;
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyProperty.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyProperty.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyProperty.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -10,6 +10,7 @@
using System.Reflection;
using System.Xml;
+using MonoDevelop.Services;
using MonoDevelop.SharpAssembly.Metadata.Rows;
using MonoDevelop.SharpAssembly.Metadata;
using MonoDevelop.SharpAssembly.PE;
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyReturnType.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyReturnType.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Parser/SharpAssemblyLayer/SharpAssemblyReturnType.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -10,6 +10,7 @@
using System.Reflection;
using System.Xml;
+using MonoDevelop.Services;
using MonoDevelop.SharpAssembly.Metadata.Rows;
using MonoDevelop.SharpAssembly.Metadata;
using MonoDevelop.SharpAssembly.PE;
@@ -97,7 +98,7 @@
} else {
fullyQualifiedName = assembly.GetStringFromHeap(typeRefTable[index].Nspace) + "." +
assembly.GetStringFromHeap(typeRefTable[index].Name);
- Console.WriteLine("GetDataType: TypeRef not resolved!");
+ Runtime.LoggingService.Info("GetDataType: TypeRef not resolved!");
}
declaredin = asm.GetRefAssemblyFor(index);
} else {
@@ -137,7 +138,7 @@
break;
default:
- Console.WriteLine("NOT supported: " + dt.ToString());
+ Runtime.LoggingService.Info("NOT supported: " + dt.ToString());
fullyQualifiedName += " NOT_SUPPORTED [" + dt.ToString() + "]";
break;
}
@@ -173,7 +174,7 @@
} else {
FullyQualifiedName = assembly.Reader.GetStringFromHeap(typeRefTable[index].Nspace) + "." +
assembly.Reader.GetStringFromHeap(typeRefTable[index].Name);
- Console.WriteLine("SharpAssemblyReturnType from TypeRef: TypeRef not resolved!");
+ Runtime.LoggingService.Info("SharpAssemblyReturnType from TypeRef: TypeRef not resolved!");
}
declaredin = assembly.GetRefAssemblyFor(index);
}
@@ -184,7 +185,7 @@
try {
GetDataType(assembly, ref blobSignatureIndex);
} catch (Exception e) {
- Console.WriteLine("Got exception in ReturnType creation: " + e.ToString());
+ Runtime.LoggingService.Info("Got exception in ReturnType creation: " + e.ToString());
FullyQualifiedName = "GOT_EXCEPTION";
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/ProgressMonitoring/BaseProgressMonitor.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/ProgressMonitoring/BaseProgressMonitor.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/ProgressMonitoring/BaseProgressMonitor.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -112,7 +112,7 @@
else if (message != null && ex != null)
message += ". " + ex.Message;
errorsMessages.Add (message);
- Console.WriteLine (ex);
+ Runtime.LoggingService.Info (ex);
}
[FreeDispatch]
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/ProgressMonitoring/ConsoleProgressMonitor.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/ProgressMonitoring/ConsoleProgressMonitor.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/ProgressMonitoring/ConsoleProgressMonitor.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -35,7 +35,7 @@
{
public override void BeginTask (string name, int totalWork)
{
- Console.WriteLine ("*** " + name);
+ Runtime.LoggingService.Info ("*** " + name);
}
public override TextWriter Log {
@@ -44,18 +44,18 @@
public override void ReportSuccess (string message)
{
- Console.WriteLine (message);
+ Runtime.LoggingService.Info (message);
}
public override void ReportWarning (string message)
{
- Console.WriteLine ("WARNING: " + message);
+ Runtime.LoggingService.Info ("WARNING: " + message);
}
public override void ReportError (string message, Exception ex)
{
- Console.WriteLine ("ERROR: " + message);
- Console.WriteLine (ex);
+ Runtime.LoggingService.Info ("ERROR: " + message);
+ Runtime.LoggingService.Info (ex);
}
}
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Project/Combine/Combine.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Project/Combine/Combine.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Project/Combine/Combine.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -454,7 +454,7 @@
projects.Add ((Project)entry);
}
else
- Console.WriteLine ("Dont know how to generate makefiles for " + entry);
+ Runtime.LoggingService.Info ("Dont know how to generate makefiles for " + entry);
}
string rel_outputdir = Runtime.FileUtilityService.AbsoluteToRelativePath (BaseDirectory, outputdir);
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Project/Project/DotNetProject.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Project/Project/DotNetProject.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Project/Project/DotNetProject.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -178,7 +178,7 @@
public override void GenerateMakefiles (Combine parentCombine)
{
- Console.WriteLine ("Generating makefiles for " + Name);
+ Runtime.LoggingService.Info ("Generating makefiles for " + Name);
languageBinding.GenerateMakefile (this, parentCombine);
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Project/Project/IncludeFilesDialog.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Project/Project/IncludeFilesDialog.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Project/Project/IncludeFilesDialog.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -42,7 +42,7 @@
public IncludeFilesDialog(Project project, StringCollection newFiles)
{
- Console.WriteLine ("*** Include files dialog ***");
+ Runtime.LoggingService.Info ("*** Include files dialog ***");
// we must do it from *here* otherwise, we get this assembly, not the caller
Glade.XML glade = new Glade.XML (null, "Base.glade", "IncludeFilesDialogWidget", null);
glade.Autoconnect (this);
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Project/Project/Project.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Project/Project/Project.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Project/Project/Project.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -260,7 +260,7 @@
File.Copy (referenceFileName + ".mdb", destinationFileName + ".mdb", true);
}
} catch (Exception e) {
- Console.WriteLine("Can't copy reference file from {0} to {1} reason {2}", referenceFileName, destinationFileName, e);
+ Runtime.LoggingService.InfoFormat("Can't copy reference file from {0} to {1} reason {2}", referenceFileName, destinationFileName, e);
}
}
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Templates/CodeTemplateLoader.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Templates/CodeTemplateLoader.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Internal/Templates/CodeTemplateLoader.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -96,7 +96,7 @@
static CodeTemplateLoader()
{
if (!LoadTemplatesFromStream(Path.Combine(Runtime.Properties.ConfigDirectory, TemplateFileName))) {
- Console.WriteLine("Templates: can't load user defaults, reading system defaults");
+ Runtime.LoggingService.Info("Templates: can't load user defaults, reading system defaults");
if (!LoadTemplatesFromStream(Runtime.Properties.DataDirectory +
Path.DirectorySeparatorChar + "options" +
Path.DirectorySeparatorChar + TemplateFileName)) {
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Makefile.am
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Makefile.am 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Makefile.am 2005-04-02 03:25:51 UTC (rev 2414)
@@ -8,6 +8,7 @@
/r:System.Data.dll /r:System.Web.Services.dll \
/r:$(top_builddir)/build/bin/MonoDevelop.Dock.dll \
/r:Mono.Posix.dll \
+ /r:$(top_builddir)/contrib/log4net.dll \
$(GTK_SHARP_LIBS) \
$(GNOME_SHARP_LIBS) \
$(GNOME_VFS_SHARP_LIBS) \
@@ -240,6 +241,8 @@
Services/DispatchService/SyncContextAttribute.cs \
Services/DispatchService/SyncObject.cs \
Services/Runtime.cs \
+Services/ILoggingService.cs \
+Services/DefaultLoggingService.cs \
Internal/Undo/IUndoableOperation.cs \
Internal/Undo/UndoStack.cs \
Internal/Undo/UndoQueue.cs \
Added: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/DefaultLoggingService.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/DefaultLoggingService.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/DefaultLoggingService.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -0,0 +1,187 @@
+
+using System;
+
+using MonoDevelop.Core.Services;
+
+using log4net;
+
+namespace MonoDevelop.Services
+{
+ public class DefaultLoggingService : AbstractService, ILoggingService
+ {
+ public event LogAppendedHandler LogAppended;
+
+ public DefaultLoggingService()
+ {
+ log4net.Config.XmlConfigurator.Configure();
+ }
+
+ public override void InitializeService()
+ {
+ base.InitializeService();
+ }
+
+ ILog GetLogger(System.Type type)
+ {
+ return LogManager.GetLogger(type);
+ }
+
+ ILog GetLogger()
+ {
+ return LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType);
+ }
+
+ System.Reflection.MethodBase GetCallingMethod()
+ {
+ System.Diagnostics.StackTrace
+ trace = new System.Diagnostics.StackTrace(true);
+ return trace.GetFrame(2).GetMethod();
+ }
+
+ public bool IsDebugEnabled {
+ get {
+ return GetLogger(GetCallingMethod().DeclaringType).IsDebugEnabled;
+ }
+ }
+
+ public bool IsInfoEnabled {
+ get {
+ return GetLogger(GetCallingMethod().DeclaringType).IsInfoEnabled;
+ }
+ }
+
+ public bool IsWarnEnabled {
+ get {
+ return GetLogger(GetCallingMethod().DeclaringType).IsWarnEnabled;
+ }
+ }
+
+ public bool IsErrorEnabled {
+ get {
+ return GetLogger(GetCallingMethod().DeclaringType).IsErrorEnabled;
+ }
+ }
+
+ public bool IsFatalEnabled {
+ get {
+ return GetLogger(GetCallingMethod().DeclaringType).IsFatalEnabled;
+ }
+ }
+
+ public void Debug (object message)
+ {
+ System.Type type = GetCallingMethod().DeclaringType;
+ GetLogger(type).Debug (message);
+ OnLogAppended ("Debug", type.ToString(), message.ToString());
+ }
+
+ public void Info (object message)
+ {
+ System.Type type = GetCallingMethod().DeclaringType;
+ GetLogger(type).Info (message);
+ OnLogAppended ("Info", type.ToString(), message.ToString());
+ }
+
+ public void Warn (object message)
+ {
+ GetLogger(GetCallingMethod().DeclaringType).Warn (message);
+ }
+
+ public void Error (object message)
+ {
+ GetLogger(GetCallingMethod().DeclaringType).Error (message);
+ }
+
+ public void Fatal (object message)
+ {
+ GetLogger(GetCallingMethod().DeclaringType).Fatal (message);
+ }
+
+ public void Debug (object message, Exception t)
+ {
+ GetLogger(GetCallingMethod().DeclaringType).Debug (message, t);
+ }
+
+ public void Info (object message, Exception t)
+ {
+ GetLogger(GetCallingMethod().DeclaringType).Info (message, t);
+ }
+
+ public void Warn (object message, Exception t)
+ {
+ GetLogger(GetCallingMethod().DeclaringType).Warn (message, t);
+ }
+
+ public void Error (object message, Exception t)
+ {
+ GetLogger(GetCallingMethod().DeclaringType).Error (message, t);
+ }
+
+ public void Fatal (object message, Exception t)
+ {
+ GetLogger(GetCallingMethod().DeclaringType).Fatal (message, t);
+ }
+
+ public void DebugFormat (string format, params object[] args)
+ {
+ GetLogger(GetCallingMethod().DeclaringType).DebugFormat (format, args);
+ }
+
+ public void InfoFormat (string format, params object[] args)
+ {
+ GetLogger(GetCallingMethod().DeclaringType).InfoFormat (format, args);
+ }
+
+ public void WarnFormat (string format, params object[] args)
+ {
+ GetLogger(GetCallingMethod().DeclaringType).WarnFormat (format, args);
+ }
+
+ public void ErrorFormat (string format, params object[] args)
+ {
+ GetLogger(GetCallingMethod().DeclaringType).ErrorFormat (format, args);
+ }
+
+ public void FatalFormat (string format, params object[] args)
+ {
+ GetLogger(GetCallingMethod().DeclaringType).FatalFormat (format, args);
+ }
+
+ public void DebugFormat(IFormatProvider provider, string format, params object[] args)
+ {
+ GetLogger(GetCallingMethod().DeclaringType).DebugFormat (provider, format, args);
+ }
+
+ public void InfoFormat(IFormatProvider provider, string format, params object[] args)
+ {
+ GetLogger(GetCallingMethod().DeclaringType).InfoFormat (provider, format, args);
+ }
+
+ public void WarnFormat(IFormatProvider provider, string format, params object[] args)
+ {
+ GetLogger(GetCallingMethod().DeclaringType).WarnFormat (provider, format, args);
+ }
+
+ public void ErrorFormat(IFormatProvider provider, string format, params object[] args)
+ {
+ GetLogger(GetCallingMethod().DeclaringType).ErrorFormat (provider, format, args);
+ }
+
+ public void FatalFormat(IFormatProvider provider, string format, params object[] args)
+ {
+ GetLogger(GetCallingMethod().DeclaringType).FatalFormat (provider, format, args);
+ }
+
+ public void OnLogAppended(string level, string category, string message)
+ {
+ if (LogAppended != null) {
+ LogAppendedArgs args = new LogAppendedArgs();
+ args.Level = level;
+ args.Category = category;
+ args.Message = message;
+ args.Timestamp = DateTime.Now;
+ LogAppended(this, args);
+ }
+ }
+ }
+}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/DispatchService/DispatchService.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/DispatchService/DispatchService.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/DispatchService/DispatchService.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -173,14 +173,14 @@
private void HandlerError (GenericMessageContainer msg)
{
- Console.WriteLine (errormsg);
- Console.WriteLine (msg.Exception);
+ Runtime.LoggingService.Info (errormsg);
+ Runtime.LoggingService.Info (msg.Exception);
if (msg.CallerStack != null) {
- Console.WriteLine ("\nCaller stack:");
- Console.WriteLine (msg.CallerStack);
+ Runtime.LoggingService.Info ("\nCaller stack:");
+ Runtime.LoggingService.Info (msg.CallerStack);
}
else
- Console.WriteLine ("\n\nCaller stack not available. Define the environment variable MONODEVELOP_DISPATCH_DEBUG to enable caller stack capture.");
+ Runtime.LoggingService.Info ("\n\nCaller stack not available. Define the environment variable MONODEVELOP_DISPATCH_DEBUG to enable caller stack capture.");
}
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/DisplayBinding/DisplayBindingService.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/DisplayBinding/DisplayBindingService.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/DisplayBinding/DisplayBindingService.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -57,7 +57,7 @@
}
}
}
- Console.WriteLine (String.Format (GettextCatalog.GetString ("Didnt match on mimetype: {0}, trying filename"), mimetype));
+ Runtime.LoggingService.Info (String.Format (GettextCatalog.GetString ("Didnt match on mimetype: {0}, trying filename"), mimetype));
foreach (DisplayBindingCodon binding in bindings) {
if (binding.DisplayBinding != null && binding.DisplayBinding.CanCreateContentForFile(filename)) {
return binding;
Added: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ILoggingService.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ILoggingService.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ILoggingService.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -0,0 +1,53 @@
+
+using System;
+
+namespace MonoDevelop.Services
+{
+ public delegate void LogAppendedHandler(object sender, LogAppendedArgs args);
+
+ public interface ILoggingService
+ {
+ /* Test if a level is enabled for logging */
+ bool IsDebugEnabled { get; }
+ bool IsInfoEnabled { get; }
+ bool IsWarnEnabled { get; }
+ bool IsErrorEnabled { get; }
+ bool IsFatalEnabled { get; }
+
+ /* Log a message object */
+ void Debug(object message);
+ void Info(object message);
+ void Warn(object message);
+ void Error(object message);
+ void Fatal(object message);
+
+ /* Log a message object and exception */
+ void Debug(object message, Exception t);
+ void Info(object message, Exception t);
+ void Warn(object message, Exception t);
+ void Error(object message, Exception t);
+ void Fatal(object message, Exception t);
+
+ /* Log a message string using the System.String.Format syntax */
+ void DebugFormat(string format, params object[] args);
+ void InfoFormat(string format, params object[] args);
+ void WarnFormat(string format, params object[] args);
+ void ErrorFormat(string format, params object[] args);
+ void FatalFormat(string format, params object[] args);
+
+ /* Log a message string using the System.String.Format syntax */
+ void DebugFormat(IFormatProvider provider, string format, params object[] args);
+ void InfoFormat(IFormatProvider provider, string format, params object[] args);
+ void WarnFormat(IFormatProvider provider, string format, params object[] args);
+ void ErrorFormat(IFormatProvider provider, string format, params object[] args);
+ void FatalFormat(IFormatProvider provider, string format, params object[] args);
+
+ event LogAppendedHandler LogAppended;
+ }
+
+ public class LogAppendedArgs
+ {
+ public string Category, Message, Level;
+ public DateTime Timestamp;
+ }
+}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ParserService/AssemblyCodeCompletionDatabase.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ParserService/AssemblyCodeCompletionDatabase.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ParserService/AssemblyCodeCompletionDatabase.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -61,7 +61,7 @@
catch {}
if (asm == null) {
- Console.WriteLine ("Could not load assembly: " + assemblyFile);
+ Runtime.LoggingService.Info ("Could not load assembly: " + assemblyFile);
return;
}
}
@@ -70,7 +70,7 @@
asm = FindAssembly (assemblyName);
if (asm == null) {
- Console.WriteLine ("Could not load assembly: " + assemblyName);
+ Runtime.LoggingService.Info ("Could not load assembly: " + assemblyName);
return;
}
@@ -200,7 +200,7 @@
if (!File.Exists (checkFile) || version != FORMAT_VERSION) {
string dataFile = Path.Combine (baseDir, name + ".pidb");
File.Delete (dataFile);
- Console.WriteLine ("Deleted " + dataFile);
+ Runtime.LoggingService.Info ("Deleted " + dataFile);
}
}
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ParserService/AssemblyInformation.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ParserService/AssemblyInformation.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ParserService/AssemblyInformation.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -53,7 +53,7 @@
byte[] GetBytes(string fileName)
{
- Console.WriteLine (fileName);
+ Runtime.LoggingService.Info (fileName);
FileStream fs = System.IO.File.OpenRead(fileName);
long size = fs.Length;
byte[] outArray = new byte[size];
@@ -70,7 +70,7 @@
// TypeDef[] typeDefTable = (TypeDef[])assembly.MetadataTable.Tables[TypeDef.TABLE_ID];
//
// for (int i = 0; i < typeDefTable.Length; ++i) {
-// Console.WriteLine("ADD " + i);
+// Runtime.LoggingService.Info("ADD " + i);
// classes.Add(new SharpAssemblyClass(assembly, typeDefTable, i));
// }
@@ -114,7 +114,7 @@
} catch {
}
if(asm == null) {
- Console.WriteLine ("Unable to load {0}", fileName);
+ Runtime.LoggingService.InfoFormat ("Unable to load {0}", fileName);
return;
}
foreach (Type type in asm.GetTypes()) {
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ParserService/CodeCompletionDatabase.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ParserService/CodeCompletionDatabase.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ParserService/CodeCompletionDatabase.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -122,7 +122,7 @@
currentGetTime = 0;
CloseReader ();
- Console.WriteLine ("Reading " + dataFile);
+ Runtime.LoggingService.Info ("Reading " + dataFile);
ifile = new FileStream (dataFile, FileMode.Open, FileAccess.Read, FileShare.Read);
BinaryFormatter bf = new BinaryFormatter ();
@@ -150,7 +150,7 @@
catch (Exception ex)
{
if (ifile != null) ifile.Close ();
- Console.WriteLine ("PIDB file '" + dataFile + "' couldn not be loaded: '" + ex.Message + "'. The file will be recreated");
+ Runtime.LoggingService.Info ("PIDB file '" + dataFile + "' couldn not be loaded: '" + ex.Message + "'. The file will be recreated");
rootNamespace = new NamespaceEntry ();
files = new Hashtable ();
references = new ArrayList ();
@@ -177,7 +177,7 @@
modified = false;
headers["Version"] = FORMAT_VERSION;
- Console.WriteLine ("Writing " + dataFile);
+ Runtime.LoggingService.Info ("Writing " + dataFile);
string tmpDataFile = dataFile + ".tmp";
FileStream dfile = new FileStream (tmpDataFile, FileMode.Create, FileAccess.Write, FileShare.Write);
@@ -326,7 +326,7 @@
{
lock (rwlock)
{
-// Console.WriteLine ("GET CLASS " + typeName + " in " + dataFile);
+// Runtime.LoggingService.Info ("GET CLASS " + typeName + " in " + dataFile);
string[] path = typeName.Split ('.');
int len = path.Length - 1;
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ParserService/DefaultParserService.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ParserService/DefaultParserService.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ParserService/DefaultParserService.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -162,7 +162,7 @@
asm = Assembly.LoadWithPartialName (name);
}
if (asm == null) {
- Console.WriteLine ("Could not find: " + name);
+ Runtime.LoggingService.Info ("Could not find: " + name);
return string.Empty;
}
@@ -208,7 +208,7 @@
return;
}
catch (Exception ex) {
- Console.WriteLine (ex);
+ Runtime.LoggingService.Info (ex);
}
}
@@ -686,7 +686,7 @@
}
} catch (Exception e) {
try {
- Console.WriteLine(e.ToString());
+ Runtime.LoggingService.Info(e.ToString());
} catch {}
}
}
@@ -897,7 +897,7 @@
public string SearchNamespace(Project project, IUsing usin, string partitialNamespaceName, bool caseSensitive)
{
-// Console.WriteLine("SearchNamespace : >{0}<", partitialNamespaceName);
+// Runtime.LoggingService.Info("SearchNamespace : >{0}<", partitialNamespaceName);
if (NamespaceExists(project, partitialNamespaceName, caseSensitive)) {
return partitialNamespaceName;
}
@@ -986,7 +986,7 @@
public IClass SearchType(Project project, IUsing iusing, string partitialTypeName, bool caseSensitive)
{
-// Console.WriteLine("Search type : >{0}<", partitialTypeName);
+// Runtime.LoggingService.Info("Search type : >{0}<", partitialTypeName);
IClass c = GetClass(project, partitialTypeName, caseSensitive);
if (c != null) {
return c;
@@ -994,10 +994,10 @@
foreach (string str in iusing.Usings) {
string possibleType = String.Concat(str, ".", partitialTypeName);
-// Console.WriteLine("looking for " + possibleType);
+// Runtime.LoggingService.Info("looking for " + possibleType);
c = GetClass(project, possibleType, caseSensitive);
if (c != null) {
-// Console.WriteLine("Found!");
+// Runtime.LoggingService.Info("Found!");
return c;
}
}
@@ -1007,10 +1007,10 @@
if (declaringNamespace != null) {
while (declaringNamespace.Length > 0) {
string className = String.Concat(declaringNamespace, ".", partitialTypeName);
-// Console.WriteLine("looking for " + className);
+// Runtime.LoggingService.Info("looking for " + className);
c = GetClass(project, className, caseSensitive);
if (c != null) {
-// Console.WriteLine("Found!");
+// Runtime.LoggingService.Info("Found!");
return c;
}
int index = declaringNamespace.IndexOf('.');
@@ -1028,10 +1028,10 @@
string className = null;
if (aliasString.Length > 0) {
className = String.Concat(entry.Value.ToString(), partitialTypeName.Remove(0, aliasString.Length));
-// Console.WriteLine("looking for " + className);
+// Runtime.LoggingService.Info("looking for " + className);
c = GetClass(project, className, caseSensitive);
if (c != null) {
-// Console.WriteLine("Found!");
+// Runtime.LoggingService.Info("Found!");
return c;
}
}
@@ -1240,7 +1240,7 @@
// being thrown and corrupting the textarea control
try {
IParser parser = GetParser(fileName);
- //Console.WriteLine("Parse info : " + GetParseInformation(fileName).MostRecentCompilationUnit.Tag);
+ //Runtime.LoggingService.Info("Parse info : " + GetParseInformation(fileName).MostRecentCompilationUnit.Tag);
if (parser != null) {
return parser.Resolve(this, project, expression, caretLineNumber, caretColumn, fileName, fileContent);
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ResourceService.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ResourceService.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/ResourceService.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -17,6 +17,7 @@
using System.Runtime.InteropServices;
using MonoDevelop.Core.Properties;
+using MonoDevelop.Services;
namespace MonoDevelop.Core.Services
{
@@ -230,7 +231,7 @@
catch (GLib.GException ex) {
// just discard the exception, the icon simply can't be
// loaded
- Console.WriteLine ("Warning: can't load " + filename +
+ Runtime.LoggingService.InfoFormat("Warning: can't load " + filename +
" icon file");
}
}
@@ -252,7 +253,7 @@
if (s != null)
return s;
- Console.WriteLine ("WARNING Could not find stock {0}", filename);
+ Runtime.LoggingService.InfoFormat("WARNING Could not find stock {0}", filename);
return filename;
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/Runtime.cs
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/Runtime.cs 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Base/Services/Runtime.cs 2005-04-02 03:25:51 UTC (rev 2414)
@@ -22,6 +22,7 @@
static LanguageBindingService languageBindingService;
static SystemAssemblyService systemAssemblyService;
static FileUtilityService fileUtilityService;
+ static ILoggingService loggingService;
public static ProcessService ProcessService {
get {
@@ -151,5 +152,14 @@
return guiService;
}
}
+
+ public static ILoggingService LoggingService {
+ get {
+ if (loggingService == null)
+ loggingService = new DefaultLoggingService();
+
+ return loggingService;
+ }
+ }
}
}
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Startup/ChangeLog
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Startup/ChangeLog 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Startup/ChangeLog 2005-04-02 03:25:51 UTC (rev 2414)
@@ -1,3 +1,8 @@
+2005-04-01 Christian Hergert <christian.hergert at gmail.com>
+
+ * app.config: Add MonoDevelop.exe.config configuration file
+ * Makefile.am: Update to include the configuration file
+
2005-03-10 Christian Hergert <christian.hergert at gmail.com>
* MonoDevelopMain.cs: Update the splash screen percentages
Modified: trunk/MonoDevelop/Core/src/MonoDevelop.Startup/Makefile.am
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Startup/Makefile.am 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Startup/Makefile.am 2005-04-02 03:25:51 UTC (rev 2414)
@@ -8,7 +8,7 @@
DLL = $(top_builddir)/build/bin/MonoDevelop.exe
-all: $(DLL)
+all: $(DLL) $(DLL).config
REFS = /r:System.Drawing \
/r:$(top_builddir)/build/bin/MonoDevelop.Core.dll \
@@ -22,8 +22,11 @@
$(CSC) -out:$@ -define:GTK $(REFS) $(build_sources) \
-resource:$(srcdir)/SplashScreen.png,SplashScreen.png
+$(DLL).config: $(DLL)
+ cp $(CONFIG) $(DLL).config
+
assemblydir = $(libdir)/monodevelop/bin
-assembly_DATA = $(DLL)
+assembly_DATA = $(DLL) $(DLL).config
CLEANFILES=$(DLL) $(DLL).mdb
Added: trunk/MonoDevelop/Core/src/MonoDevelop.Startup/app.config
===================================================================
--- trunk/MonoDevelop/Core/src/MonoDevelop.Startup/app.config 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Core/src/MonoDevelop.Startup/app.config 2005-04-02 03:25:51 UTC (rev 2414)
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<configuration>
+ <configSections>
+ <section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler,log4net" />
+ </configSections>
+ <log4net>
+ <appender name="ConsoleAppender" type="log4net.Appender.ConsoleAppender">
+ <layout type="log4net.Layout.PatternLayout">
+ <conversionPattern value="%date [%thread] %-5level %logger [%ndc] - %message%newline" />
+ </layout>
+ </appender>
+ <root>
+ <priority value="ALL" />
+ <appender-ref ref="ConsoleAppender" />
+ </root>
+ </log4net>
+</configuration>
Modified: trunk/MonoDevelop/Makefile.am
===================================================================
--- trunk/MonoDevelop/Makefile.am 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/Makefile.am 2005-04-02 03:25:51 UTC (rev 2414)
@@ -1,4 +1,4 @@
-SUBDIRS = Core build po Extras
+SUBDIRS = contrib Core build po Extras
bin_SCRIPTS = monodevelop
Modified: trunk/MonoDevelop/configure.in
===================================================================
--- trunk/MonoDevelop/configure.in 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/configure.in 2005-04-02 03:25:51 UTC (rev 2414)
@@ -216,6 +216,7 @@
Extras/MonoQuery/MonoQuery.addin.xml
Extras/MonoDeveloperExtensions/Makefile
Extras/JavaBinding/Makefile
+contrib/Makefile
])
echo ""
Added: trunk/MonoDevelop/contrib/Makefile.am
===================================================================
--- trunk/MonoDevelop/contrib/Makefile.am 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/contrib/Makefile.am 2005-04-02 03:25:51 UTC (rev 2414)
@@ -0,0 +1,12 @@
+
+all: $(BINDIR)/$(LOG4NET_DLL)
+
+LOG4NET_DLL=log4net.dll
+BINDIR=$(top_builddir)/build/bin
+
+$(BINDIR)/$(LOG4NET_DLL):
+ mkdir -p $(BINDIR)
+ cp $(LOG4NET_DLL) $(BINDIR)
+
+assemblydir = $(libdir)/monodevelop/bin
+assembly_DATA = $(LOG4NET_DLL)
Added: trunk/MonoDevelop/contrib/log4net.dll
===================================================================
(Binary files differ)
Property changes on: trunk/MonoDevelop/contrib/log4net.dll
___________________________________________________________________
Name: svn:executable
+ *
Name: svn:mime-type
+ application/octet-stream
Added: trunk/MonoDevelop/contrib/log4net.license.txt
===================================================================
--- trunk/MonoDevelop/contrib/log4net.license.txt 2005-04-01 23:21:09 UTC (rev 2413)
+++ trunk/MonoDevelop/contrib/log4net.license.txt 2005-04-02 03:25:51 UTC (rev 2414)
@@ -0,0 +1,48 @@
+/*
+ * ============================================================================
+ * The Apache Software License, Version 1.1
+ * ============================================================================
+ *
+ * Copyright (C) 1999 The Apache Software Foundation. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without modifica-
+ * tion, are permitted provided that the following conditions are met:
+ *
+ * 1. Redistributions of source code must retain the above copyright notice,
+ * this list of conditions and the following disclaimer.
+ *
+ * 2. Redistributions in binary form must reproduce the above copyright notice,
+ * this list of conditions and the following disclaimer in the documentation
+ * and/or other materials provided with the distribution.
+ *
+ * 3. The end-user documentation included with the redistribution, if any, must
+ * include the following acknowledgment: "This product includes software
+ * developed by the Apache Software Foundation (http://www.apache.org/)."
+ * Alternately, this acknowledgment may appear in the software itself, if
+ * and wherever such third-party acknowledgments normally appear.
+ *
+ * 4. The names "log4j" and "Apache Software Foundation" must not be used to
+ * endorse or promote products derived from this software without prior
+ * written permission. For written permission, please contact
+ * apache at apache.org.
+ *
+ * 5. Products derived from this software may not be called "Apache", nor may
+ * "Apache" appear in their name, without prior written permission of the
+ * Apache Software Foundation.
+ *
+ * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
+ * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
+ * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+ * APACHE SOFTWARE FOUNDATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
+ * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLU-
+ * DING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
+ * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
+ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ *
+ * This software consists of voluntary contributions made by many individuals
+ * on behalf of the Apache Software Foundation. For more information on the
+ * Apache Software Foundation, please see <http://www.apache.org/>.
+ *
+ */
More information about the Monodevelop-patches-list
mailing list