Udostępnij za pośrednictwem


LauncherApps.Callback.OnShortcutsChanged Method

Definition

Indicates that one or more shortcuts of any kind (dynamic, pinned, or manifest) have been added, updated or removed.

[Android.Runtime.Register("onShortcutsChanged", "(Ljava/lang/String;Ljava/util/List;Landroid/os/UserHandle;)V", "GetOnShortcutsChanged_Ljava_lang_String_Ljava_util_List_Landroid_os_UserHandle_Handler", ApiSince=25)]
public virtual void OnShortcutsChanged (string packageName, System.Collections.Generic.IList<Android.Content.PM.ShortcutInfo> shortcuts, Android.OS.UserHandle user);
[<Android.Runtime.Register("onShortcutsChanged", "(Ljava/lang/String;Ljava/util/List;Landroid/os/UserHandle;)V", "GetOnShortcutsChanged_Ljava_lang_String_Ljava_util_List_Landroid_os_UserHandle_Handler", ApiSince=25)>]
abstract member OnShortcutsChanged : string * System.Collections.Generic.IList<Android.Content.PM.ShortcutInfo> * Android.OS.UserHandle -> unit
override this.OnShortcutsChanged : string * System.Collections.Generic.IList<Android.Content.PM.ShortcutInfo> * Android.OS.UserHandle -> unit

Parameters

packageName
String

The name of the package that has the shortcuts.

shortcuts
IList<ShortcutInfo>

All shortcuts from the package (dynamic, manifest and/or pinned). Only "key" information will be provided, as defined in ShortcutInfo#hasKeyFieldsOnly().

user
UserHandle

The UserHandle of the profile that generated the change.

Attributes

Remarks

Indicates that one or more shortcuts of any kind (dynamic, pinned, or manifest) have been added, updated or removed.

Only the applications that are allowed to access the shortcut information, as defined in #hasShortcutHostPermission(), will receive it.

Java documentation for android.content.pm.LauncherApps.Callback.onShortcutsChanged(java.lang.String, java.util.List<android.content.pm.ShortcutInfo>, android.os.UserHandle).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to