move an attribute in Wonderswan core that was on the constructor on accident, added an AttributeTargets attribute on it that would have caught such an error, add AttributeTargets on some other attributes to help clarify their usage

This commit is contained in:
adelikat 2014-12-13 02:31:31 +00:00
parent 4304aa9d01
commit 45809ab73f
4 changed files with 5 additions and 1 deletions

View File

@ -2,6 +2,7 @@
namespace BizHawk.Client.Common
{
[AttributeUsage(AttributeTargets.Method)]
public class LuaMethodAttributes : Attribute
{
public LuaMethodAttributes(string name, string description)
@ -14,6 +15,7 @@ namespace BizHawk.Client.Common
public string Description { get; set; }
}
[AttributeUsage(AttributeTargets.Class)]
public class LuaLibraryAttributes : Attribute
{
public LuaLibraryAttributes(bool released)

View File

@ -2,6 +2,7 @@
namespace BizHawk.Emulation.Common
{
[AttributeUsage(AttributeTargets.Class)]
public class CoreAttributes : Attribute
{
public CoreAttributes(

View File

@ -22,6 +22,7 @@ namespace BizHawk.Emulation.Common
public FeatureNotImplemented() { }
}
[AttributeUsage(AttributeTargets.Class)]
public class ServiceNotApplicable : Attribute
{
public ServiceNotApplicable(params Type[] types)

View File

@ -12,6 +12,7 @@ using System.Runtime.InteropServices;
namespace BizHawk.Emulation.Cores.WonderSwan
{
[CoreAttributes("Cygne/Mednafen", "Dox", true, true, "0.9.36.5", "http://mednafen.sourceforge.net/")]
[ServiceNotApplicable(typeof(IDriveLight))]
public class WonderSwan : IEmulator, IVideoProvider, ISyncSoundProvider, IMemoryDomains, ISaveRam, IStatable,
IInputPollable, IDebuggable, ISettable<WonderSwan.Settings, WonderSwan.SyncSettings>
{
@ -87,7 +88,6 @@ namespace BizHawk.Emulation.Cores.WonderSwan
#endregion
[CoreConstructor("WSWAN")]
[ServiceNotApplicable(typeof(IDriveLight))]
public WonderSwan(CoreComm comm, byte[] file, bool deterministic, object Settings, object SyncSettings)
{
ServiceProvider = new BasicServiceProvider(this);