Freigeben über


UIKeyCommand.Create Methode

Definition

Überlädt

Create(NSString, UIKeyModifierFlags, Selector)

Factory-Methode, die eine UIKeyCommand-Instanz erstellt.

Create(NSString, UIKeyModifierFlags, Selector, NSString)

Factory-Methode, die eine neue UIKeyCommandinstanziiert.

Create(NSString, UIKeyModifierFlags, Selector)

Factory-Methode, die eine UIKeyCommand-Instanz erstellt.

[Foundation.Export("keyCommandWithInput:modifierFlags:action:")]
public static UIKit.UIKeyCommand Create (Foundation.NSString keyCommandInput, UIKit.UIKeyModifierFlags modifierFlags, ObjCRuntime.Selector action);
static member Create : Foundation.NSString * UIKit.UIKeyModifierFlags * ObjCRuntime.Selector -> UIKit.UIKeyCommand

Parameter

keyCommandInput
NSString
modifierFlags
UIKeyModifierFlags
action
Selector

Gibt zurück

Attribute

Hinweise

       [Export("NewFileAccelerator:")]
        void NewFileAccelerator(UIKeyCommand cmd)
        {
           //etc...
        }

        public override void ViewDidLoad ()
        {
            base.ViewDidLoad ();

            var actionSelector = new Selector("NewFileAccelerator:");
            accelerator = UIKeyCommand.Create((NSString) "N",
UIKeyModifierFlags.Command, actionSelector);

            AddKeyCommand(accelerator);
        }

Gilt für:

Create(NSString, UIKeyModifierFlags, Selector, NSString)

Factory-Methode, die eine neue UIKeyCommandinstanziiert.

[Foundation.Export("keyCommandWithInput:modifierFlags:action:discoverabilityTitle:")]
[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.iOS, 9, 0, ObjCRuntime.PlatformArchitecture.All, null)]
public static UIKit.UIKeyCommand Create (Foundation.NSString keyCommandInput, UIKit.UIKeyModifierFlags modifierFlags, ObjCRuntime.Selector action, Foundation.NSString discoverabilityTitle);
static member Create : Foundation.NSString * UIKit.UIKeyModifierFlags * ObjCRuntime.Selector * Foundation.NSString -> UIKit.UIKeyCommand

Parameter

keyCommandInput
NSString
modifierFlags
UIKeyModifierFlags
action
Selector
discoverabilityTitle
NSString

Gibt zurück

Attribute

Gilt für: