[coremidi] Add missing API for macOS (10.15+) (#10878)
The API were already available (iOS) and this helps fixing tests for MacCatalyst (as it's based on our iOS API but expose the same issue as macOS wrt extra ctor/init).
This commit is contained in:
Родитель
bc340502fe
Коммит
079b683a02
|
@ -29,5 +29,17 @@ namespace CoreMidi {
|
|||
}
|
||||
#endif
|
||||
|
||||
#if !MONOMAC && !__MACCATALYST__
|
||||
public partial class MidiNetworkConnection {
|
||||
[Obsolete ("Use static factory method to create an instance.")]
|
||||
public MidiNetworkConnection () => throw new NotSupportedException ();
|
||||
}
|
||||
|
||||
public partial class MidiNetworkHost {
|
||||
[Obsolete ("Use static factory method to create an instance.")]
|
||||
public MidiNetworkHost () => throw new NotSupportedException ();
|
||||
}
|
||||
#endif
|
||||
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -54,11 +54,6 @@ namespace ObjCRuntime {
|
|||
static public class LibC {
|
||||
static public readonly IntPtr Handle = Dlfcn.dlopen (Constants.libcLibrary, 0);
|
||||
}
|
||||
#if MONOMAC
|
||||
static public class CoreMidi {
|
||||
static public readonly IntPtr Handle = Dlfcn.dlopen (Constants.CoreMidiLibrary, 0);
|
||||
}
|
||||
#endif
|
||||
#if HAS_OPENGLES
|
||||
static public class OpenGLES
|
||||
{
|
||||
|
|
|
@ -96,10 +96,10 @@ namespace CoreMidi {
|
|||
}
|
||||
|
||||
|
||||
|
||||
#if !MONOMAC
|
||||
[NoMac][NoTV][NoWatch]
|
||||
[NoTV][NoWatch]
|
||||
[Mac (10,15)]
|
||||
[BaseType (typeof (NSObject), Name="MIDINetworkHost")]
|
||||
[DisableDefaultCtor]
|
||||
interface MidiNetworkHost {
|
||||
[Export ("name", ArgumentSemantic.Retain)]
|
||||
string Name { get; }
|
||||
|
@ -134,7 +134,8 @@ namespace CoreMidi {
|
|||
bool HasSameAddressAs (MidiNetworkHost other);
|
||||
}
|
||||
|
||||
[NoMac][NoTV][NoWatch]
|
||||
[NoTV][NoWatch]
|
||||
[Mac (10,15)]
|
||||
[Static]
|
||||
interface Midi {
|
||||
[Field ("MIDINetworkNotificationContactsDidChange")]
|
||||
|
@ -149,7 +150,9 @@ namespace CoreMidi {
|
|||
NSString NetworkBonjourServiceType { get; }
|
||||
}
|
||||
|
||||
[NoMac][NoTV][NoWatch]
|
||||
[NoTV][NoWatch]
|
||||
[Mac (10,15)]
|
||||
[DisableDefaultCtor]
|
||||
[BaseType (typeof (NSObject), Name="MIDINetworkConnection")]
|
||||
interface MidiNetworkConnection {
|
||||
[Export ("host", ArgumentSemantic.Retain)]
|
||||
|
@ -159,7 +162,8 @@ namespace CoreMidi {
|
|||
MidiNetworkConnection FromHost (MidiNetworkHost host);
|
||||
}
|
||||
|
||||
[NoMac][NoTV][NoWatch]
|
||||
[NoTV][NoWatch]
|
||||
[Mac (10,15)]
|
||||
[BaseType (typeof (NSObject), Name="MIDINetworkSession")]
|
||||
// default 'init' crash the application
|
||||
[DisableDefaultCtor]
|
||||
|
@ -224,7 +228,6 @@ namespace CoreMidi {
|
|||
#endif
|
||||
|
||||
}
|
||||
#endif
|
||||
|
||||
[NoWatch, NoTV, Mac (10,14), iOS (12,0)]
|
||||
[BaseType (typeof(NSObject), Name="MIDICIProfile")]
|
||||
|
|
|
@ -1,33 +0,0 @@
|
|||
!missing-field! MIDINetworkBonjourServiceType not bound
|
||||
!missing-field! MIDINetworkNotificationContactsDidChange not bound
|
||||
!missing-field! MIDINetworkNotificationSessionDidChange not bound
|
||||
!missing-selector! +MIDINetworkConnection::connectionWithHost: not bound
|
||||
!missing-selector! +MIDINetworkHost::hostWithName:address:port: not bound
|
||||
!missing-selector! +MIDINetworkHost::hostWithName:netService: not bound
|
||||
!missing-selector! +MIDINetworkHost::hostWithName:netServiceName:netServiceDomain: not bound
|
||||
!missing-selector! +MIDINetworkSession::defaultSession not bound
|
||||
!missing-selector! MIDINetworkConnection::host not bound
|
||||
!missing-selector! MIDINetworkHost::address not bound
|
||||
!missing-selector! MIDINetworkHost::hasSameAddressAs: not bound
|
||||
!missing-selector! MIDINetworkHost::name not bound
|
||||
!missing-selector! MIDINetworkHost::netServiceDomain not bound
|
||||
!missing-selector! MIDINetworkHost::netServiceName not bound
|
||||
!missing-selector! MIDINetworkHost::port not bound
|
||||
!missing-selector! MIDINetworkSession::addConnection: not bound
|
||||
!missing-selector! MIDINetworkSession::addContact: not bound
|
||||
!missing-selector! MIDINetworkSession::connectionPolicy not bound
|
||||
!missing-selector! MIDINetworkSession::connections not bound
|
||||
!missing-selector! MIDINetworkSession::contacts not bound
|
||||
!missing-selector! MIDINetworkSession::destinationEndpoint not bound
|
||||
!missing-selector! MIDINetworkSession::isEnabled not bound
|
||||
!missing-selector! MIDINetworkSession::localName not bound
|
||||
!missing-selector! MIDINetworkSession::networkName not bound
|
||||
!missing-selector! MIDINetworkSession::networkPort not bound
|
||||
!missing-selector! MIDINetworkSession::removeConnection: not bound
|
||||
!missing-selector! MIDINetworkSession::removeContact: not bound
|
||||
!missing-selector! MIDINetworkSession::setConnectionPolicy: not bound
|
||||
!missing-selector! MIDINetworkSession::setEnabled: not bound
|
||||
!missing-selector! MIDINetworkSession::sourceEndpoint not bound
|
||||
!missing-type! MIDINetworkConnection not bound
|
||||
!missing-type! MIDINetworkHost not bound
|
||||
!missing-type! MIDINetworkSession not bound
|
Загрузка…
Ссылка в новой задаче