Changeset 2438
- Timestamp:
- 3/10/2012 8:48:25 AM (15 months ago)
- Location:
- branches/eraser6/pluginsRewrite/Eraser.Plugins
- Files:
-
- 3 edited
- 1 moved
-
Eraser.Plugins.csproj (modified) (1 diff)
-
Host.cs (modified) (2 diffs)
-
PluginInfo.cs (modified) (2 diffs)
-
PluginLoadingPolicy.cs (moved) (moved from branches/eraser6/pluginsRewrite/Eraser.Plugins/LoadingPolicy.cs) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/eraser6/pluginsRewrite/Eraser.Plugins/Eraser.Plugins.csproj
r2406 r2438 62 62 <Compile Include="IPlugin.cs" /> 63 63 <Compile Include="IRegistrar.cs" /> 64 <Compile Include=" LoadingPolicy.cs" />64 <Compile Include="PluginLoadingPolicy.cs" /> 65 65 <Compile Include="PersistentStore.cs" /> 66 66 <Compile Include="PluginInfo.cs" /> -
branches/eraser6/pluginsRewrite/Eraser.Plugins/Host.cs
r2370 r2438 359 359 360 360 //Load the plugin, depending on type 361 bool result = instance.LoadingPolicy == LoadingPolicy.Core ?361 bool result = instance.LoadingPolicy == PluginLoadingPolicy.Core ? 362 362 LoadCorePlugin(instance) : LoadNonCorePlugin(instance); 363 363 if (result) … … 382 382 if (CorePlugins.Count(x => x == info.Assembly.GetName().Name) == 0) 383 383 { 384 info.LoadingPolicy = LoadingPolicy.None;384 info.LoadingPolicy = PluginLoadingPolicy.None; 385 385 return LoadNonCorePlugin(info); 386 386 } -
branches/eraser6/pluginsRewrite/Eraser.Plugins/PluginInfo.cs
r2379 r2438 117 117 else if (attr.Constructor.DeclaringType == typeof(AssemblyCompanyAttribute)) 118 118 info.Author = (string)attr.ConstructorArguments[0].Value; 119 else if (attr.Constructor.DeclaringType.GUID == typeof( LoadingPolicyAttribute).GUID)120 LoadingPolicy = ( LoadingPolicy)attr.ConstructorArguments[0].Value;119 else if (attr.Constructor.DeclaringType.GUID == typeof(PluginLoadingPolicyAttribute).GUID) 120 LoadingPolicy = (PluginLoadingPolicy)attr.ConstructorArguments[0].Value; 121 121 122 122 this.AssemblyInfo = info; … … 138 138 /// therefore cannot be disabled.) 139 139 /// </summary> 140 public LoadingPolicy LoadingPolicy { get; internal set; }140 public PluginLoadingPolicy LoadingPolicy { get; internal set; } 141 141 142 142 /// <summary> -
branches/eraser6/pluginsRewrite/Eraser.Plugins/PluginLoadingPolicy.cs
r2405 r2438 30 30 /// Loading policies applicable for a given plugin. 31 31 /// </summary> 32 public enum LoadingPolicy32 public enum PluginLoadingPolicy 33 33 { 34 34 /// <summary> … … 51 51 /// </summary> 52 52 /// <remarks>This policy does not have an effect when declared in the 53 /// <see cref=" LoadingPolicyAttribute"/> attribute and will be equivalent53 /// <see cref="PluginLoadingPolicyAttribute"/> attribute and will be equivalent 54 54 /// to <see cref="None"/>.</remarks> 55 55 Core … … 62 62 /// </summary> 63 63 [AttributeUsage(AttributeTargets.Assembly, Inherited = false, AllowMultiple = false)] 64 public sealed class LoadingPolicyAttribute : Attribute64 public sealed class PluginLoadingPolicyAttribute : Attribute 65 65 { 66 66 /// <summary> … … 68 68 /// </summary> 69 69 /// <param name="policy">The policy used for loading the plugin.</param> 70 public LoadingPolicyAttribute(LoadingPolicy policy)70 public PluginLoadingPolicyAttribute(PluginLoadingPolicy policy) 71 71 { 72 72 Policy = policy; … … 76 76 /// The loading policy to be applied to the assembly. 77 77 /// </summary> 78 public LoadingPolicy Policy78 public PluginLoadingPolicy Policy 79 79 { 80 80 get;
Note: See TracChangeset
for help on using the changeset viewer.
