public void RemoveObjectForKey(string key) { IntPtr intPtr = ObjC.ToNSString(key); ObjC.MessageSendIntPtr(Handle, Selector.GetHandle("removeObjectForKey:"), intPtr); ObjC.MessageSend(intPtr, Selector.ReleaseHandle); }
public void SetObjectForKey(NSObject obj, string key) { IntPtr intPtr = ObjC.ToNSString(key); ObjC.MessageSendIntPtr(Handle, Selector.GetHandle("setObject:forKey:"), obj.Handle, intPtr); ObjC.MessageSend(intPtr, Selector.ReleaseHandle); }
public UIActivityViewController(string text, UIImage image) { IntPtr textHandle = ObjC.ToNSString(text); IntPtr array = ObjC.ToNSArray(new[] { textHandle, image.Handle }); ObjC.MessageSendIntPtr(Handle, Selector.GetHandle("initWithActivityItems:applicationActivities:"), array, IntPtr.Zero); ObjC.MessageSend(textHandle, Selector.ReleaseHandle); }
public NSObject ObjectForKey(string key) { IntPtr handle = ObjC.ToNSString(key); var value = Runtime.GetNSObject <NSObject>(ObjC.MessageSendIntPtr(Handle, Selector.GetHandle("objectForKey:"), handle)); ObjC.MessageSend(handle, Selector.ReleaseHandle); return(value); }
public static NSDictionary FromObjectAndKey(NSObject obj, string key) { IntPtr handle = ObjC.ToNSString(key); var dictionary = Runtime.GetNSObject <NSDictionary>(ObjC.MessageSendIntPtr(_classHandle, Selector.GetHandle("dictionaryWithObject:forKey:"), obj.Handle, handle)); ObjC.MessageSend(handle, Selector.ReleaseHandle); return(dictionary); }
public new static NSMutableDictionary FromObjectAndKey(NSObject obj, string key) { IntPtr intPtr = ObjC.ToNSString(key); NSMutableDictionary nSObject = Runtime.GetNSObject <NSMutableDictionary>(ObjC.MessageSendIntPtr(_classHandle, Selector.GetHandle("dictionaryWithObject:forKey:"), obj.Handle, intPtr)); ObjC.MessageSend(intPtr, Selector.ReleaseHandle); return(nSObject); }
public NSObject ObjectForKey(string key) { IntPtr intPtr = ObjC.ToNSString(key); NSObject nSObject = Runtime.GetNSObject <NSObject>(ObjC.MessageSendIntPtr(Handle, Selector.GetHandle("objectForKey:"), intPtr)); ObjC.MessageSend(intPtr, Selector.ReleaseHandle); return(nSObject); }
public UIActivityViewController(string text) { IntPtr intPtr = ObjC.ToNSString(text); IntPtr arg = ObjC.ToNSArray(new IntPtr[1] { intPtr }); ObjC.MessageSendIntPtr(Handle, Selector.GetHandle("initWithActivityItems:applicationActivities:"), arg, IntPtr.Zero); ObjC.MessageSend(intPtr, Selector.ReleaseHandle); }
private bool ObjectForKeyBool(string key) { return(ObjC.MessageSendBool(Handle, Selector.GetHandle("objectForKey:"), ObjC.ToNSString(key))); }
private string ObjectForKey(string key) { return(ObjC.FromNSString(ObjC.MessageSendIntPtr(Handle, Selector.GetHandle("objectForKey:"), ObjC.ToNSString(key)))); }