[banshee] MediaPanelClient: Also look for extension assembly in the current folder
- From: Bertrand Lorentz <blorentz src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [banshee] MediaPanelClient: Also look for extension assembly in the current folder
- Date: Sun, 20 Oct 2013 14:02:43 +0000 (UTC)
commit bb10e533d0ebf005761052f840eae8af2fa5d036
Author: Bertrand Lorentz <bertrand lorentz gmail com>
Date: Sun Oct 20 15:20:47 2013 +0200
MediaPanelClient: Also look for extension assembly in the current folder
This allow to run the MediaPanel client uninstalled.
.../Banshee.MediaPanel.Client/MediaPanelClient.cs | 10 ++++++++--
1 files changed, 8 insertions(+), 2 deletions(-)
---
diff --git a/src/Clients/MediaPanel/Banshee.MediaPanel.Client/MediaPanelClient.cs
b/src/Clients/MediaPanel/Banshee.MediaPanel.Client/MediaPanelClient.cs
index 079c163..f6bf186 100644
--- a/src/Clients/MediaPanel/Banshee.MediaPanel.Client/MediaPanelClient.cs
+++ b/src/Clients/MediaPanel/Banshee.MediaPanel.Client/MediaPanelClient.cs
@@ -44,8 +44,14 @@ namespace Banshee.MediaPanel.Client
{
// Normally Mono.Addins would load the MediaPanel extension from the
// Extensions directory, so we need to load this reference manually
- Assembly.LoadFile (Paths.Combine (Path.GetDirectoryName (
- Assembly.GetEntryAssembly ().Location), "Extensions", "Banshee.MediaPanel.dll"));
+ var assembly_file = Paths.Combine (Path.GetDirectoryName (
+ Assembly.GetEntryAssembly ().Location), "Extensions", "Banshee.MediaPanel.dll");
+ if (!File.Exists (assembly_file)) {
+ // Also look into the current folder, so that we can run uninstalled
+ assembly_file = Paths.Combine (Path.GetDirectoryName (
+ Assembly.GetEntryAssembly ().Location), "Banshee.MediaPanel.dll");
+ }
+ Assembly.LoadFile (assembly_file);
Startup<MediaPanelClient> (args);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]