Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono-tools.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreia Gaita <avidigal@novell.com>2008-07-30 05:16:45 +0400
committerAndreia Gaita <avidigal@novell.com>2008-07-30 05:16:45 +0400
commitec2ad32d7b77ac6141d9ba432638801300d1ffd6 (patch)
treee1b42450c64b9579dcbcbc616f607afff4affa88 /docbrowser
parentee4c07fb2c082d4df9f1c206e864f7660cdb289d (diff)
2008-07-30 Andreia Gaita <avidigal@novell.com>
* browser.cs: Fix loader not to dump an exception when it a backend assembly doesn't exist. Change backend loading order. svn path=/trunk/mono-tools/; revision=109218
Diffstat (limited to 'docbrowser')
-rw-r--r--docbrowser/ChangeLog7
-rw-r--r--docbrowser/browser.cs24
2 files changed, 18 insertions, 13 deletions
diff --git a/docbrowser/ChangeLog b/docbrowser/ChangeLog
index 8a1bc602..7a851fca 100644
--- a/docbrowser/ChangeLog
+++ b/docbrowser/ChangeLog
@@ -1,8 +1,13 @@
+2008-07-30 Andreia Gaita <avidigal@novell.com>
+
+ * browser.cs: Fix loader not to dump an exception when it a backend assembly
+ doesn't exist. Change backend loading order.
+
2008-06-17 Andreia Gaita <avidigal@novell.com>
* browser.cs: Fix alternate engine loading so it tries every available
engine if the first one fails.
-
+
2008-06-15 Andreia Gaita <avidigal@novell.com>
* browser.cs: Uncomment exception message
diff --git a/docbrowser/browser.cs b/docbrowser/browser.cs
index 7d7130a8..81ae4296 100644
--- a/docbrowser/browser.cs
+++ b/docbrowser/browser.cs
@@ -22,7 +22,7 @@ using System.Xml;
namespace Monodoc {
class Driver {
- public static string[] engines = {"WebKit", "MonoWebBrowser", "Gecko", "GtkHtml"};
+ public static string[] engines = {"WebKit", "Gecko", "MonoWebBrowser", "GtkHtml"};
static int Main (string [] args)
{
@@ -2283,6 +2283,9 @@ public class Tab : Notebook {
private static IHtmlRender LoadRenderer (string dll, Browser browser) {
+ if (!System.IO.File.Exists (dll))
+ return null;
+
try {
Assembly ass = Assembly.LoadFile (dll);
System.Type type = ass.GetType ("Monodoc." + ass.GetName ().Name, false, false);
@@ -2312,18 +2315,15 @@ public class Tab : Notebook {
foreach (string backend in Driver.engines) {
if (backend != engine) {
- string dll = System.IO.Path.Combine (AppDomain.CurrentDomain.BaseDirectory, backend + "HtmlRender.dll");
- if (System.IO.File.Exists (dll)) {
- renderer = LoadRenderer (dll, browser);
- if (renderer != null) {
- try {
- if (renderer.Initialize ()) {
- Console.WriteLine ("using " + renderer.Name);
- return renderer;
- }
- } catch (Exception ex) {
- Console.Error.WriteLine (ex);
+ renderer = LoadRenderer (System.IO.Path.Combine (AppDomain.CurrentDomain.BaseDirectory, backend + "HtmlRender.dll"), browser);
+ if (renderer != null) {
+ try {
+ if (renderer.Initialize ()) {
+ Console.WriteLine ("using " + renderer.Name);
+ return renderer;
}
+ } catch (Exception ex) {
+ Console.Error.WriteLine (ex);
}
}
}