DeviceAdminReceiver.OnUserSwitched(Context, Intent, UserHandle) 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
在用户或配置文件切换到时调用。
[Android.Runtime.Register("onUserSwitched", "(Landroid/content/Context;Landroid/content/Intent;Landroid/os/UserHandle;)V", "GetOnUserSwitched_Landroid_content_Context_Landroid_content_Intent_Landroid_os_UserHandle_Handler", ApiSince=28)]
public virtual void OnUserSwitched (Android.Content.Context context, Android.Content.Intent intent, Android.OS.UserHandle switchedUser);
[<Android.Runtime.Register("onUserSwitched", "(Landroid/content/Context;Landroid/content/Intent;Landroid/os/UserHandle;)V", "GetOnUserSwitched_Landroid_content_Context_Landroid_content_Intent_Landroid_os_UserHandle_Handler", ApiSince=28)>]
abstract member OnUserSwitched : Android.Content.Context * Android.Content.Intent * Android.OS.UserHandle -> unit
override this.OnUserSwitched : Android.Content.Context * Android.Content.Intent * Android.OS.UserHandle -> unit
参数
- context
- Context
按以下情况 #onReceive
运行上下文。
- intent
- Intent
接收的意向按 #onReceive
.
- switchedUser
- UserHandle
UserHandle
刚刚切换到的用户。
- 属性
注解
在用户或配置文件切换到时调用。
此回调仅适用于设备所有者。
本页的某些部分是根据 Android 开放源代码项目创建和共享的工作进行的修改,并根据 Creative Commons 2.5 属性许可证中所述的术语使用。