[go: up one dir, main page]

CN106844064B - Application message event control method and device and mobile terminal - Google Patents

Application message event control method and device and mobile terminal Download PDF

Info

Publication number
CN106844064B
CN106844064B CN201710025485.3A CN201710025485A CN106844064B CN 106844064 B CN106844064 B CN 106844064B CN 201710025485 A CN201710025485 A CN 201710025485A CN 106844064 B CN106844064 B CN 106844064B
Authority
CN
China
Prior art keywords
message
notification
event
user
mode
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
CN201710025485.3A
Other languages
Chinese (zh)
Other versions
CN106844064A (en
Inventor
李翔
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Anyun Century Technology Co Ltd
Original Assignee
Beijing Anyun Century Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Anyun Century Technology Co Ltd filed Critical Beijing Anyun Century Technology Co Ltd
Priority to CN201710025485.3A priority Critical patent/CN106844064B/en
Publication of CN106844064A publication Critical patent/CN106844064A/en
Application granted granted Critical
Publication of CN106844064B publication Critical patent/CN106844064B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/542Event management; Broadcasting; Multicasting; Notifications
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/546Message passing systems or structures, e.g. queues

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Multimedia (AREA)
  • Telephone Function (AREA)

Abstract

本发明涉及软件领域,具体涉及一种应用消息事件控制方法、装置及移动终端,所述方法包括如下步骤:在监测到预设应用的消息事件时,判断当前系统是否处于以第二用户登录的安全模式,所述预设应用为运行于以第一用户登录的系统普通模式的应用程序;若当前系统处于安全模式下,基于系统进程通信机制将所述消息事件传递给系统安全模式对应的服务进程,以通过所述服务进程在系统安全模式下输出响应所述消息事件后产生的通知消息。在用户使用系统安全模式为其带来安全性的同时,提高系统安全模式的易用性、从而提升用户体验,进而提起用户使用安全模式的兴趣,更好地保证终端系统的安全。

Figure 201710025485

The present invention relates to the field of software, in particular to an application message event control method, device and mobile terminal. The method includes the following steps: when monitoring a message event of a preset application, determining whether the current system is logged in as a second user. Safe mode, the preset application is an application running in the normal mode of the system logged in as the first user; if the current system is in safe mode, the message event is delivered to the service corresponding to the system safe mode based on the system process communication mechanism process, so as to output the notification message generated after responding to the message event through the service process in the system security mode. When the user uses the system security mode to bring security to the user, the usability of the system security mode is improved, thereby improving the user experience, thereby arousing the user's interest in using the security mode, and better ensuring the security of the terminal system.

Figure 201710025485

Description

应用消息事件控制方法、装置及移动终端Application message event control method, device and mobile terminal

【技术领域】【Technical field】

本发明涉及软件领域,具体涉及一种应用消息事件控制方法、装置及移动终端。The present invention relates to the field of software, in particular to an application message event control method, device and mobile terminal.

【背景技术】【Background technique】

一些移动终端出于安全考虑,设置了相应的安全模式,以保护用户在网上交易、网上支付、银行查询等等场合的安全,例如,360手机的财产隔离系统,该系统一方面通过内置安全应用商店的方式来防止盗取木马、仿冒应用的入侵,从源头上保证应用的来源安全,同时,将金融理财等数据进行系统隔离,禁止恶意应用非法读取,从根本上保障了用户支付环境的安全。For security reasons, some mobile terminals have set up corresponding security modes to protect the security of users in online transactions, online payments, bank inquiries, etc. Store method to prevent the stealing of Trojan horses and counterfeit applications, and ensure the security of the application source from the source. At the same time, the financial management and other data are systematically isolated, and malicious applications are prohibited from illegally reading, which fundamentally guarantees the user's payment environment. Safety.

目前安卓系统的安全模式是基于安卓多用户模式创建的,一般地,用户将普通应用安装在系统普通模式下,将安全性较高的应用安装在系统安全模式下,而由于多用户模式下的不同用户间的数据无法直接共享,造成当系统处于安全模式时普通模式下的应用接收到的消息无法在安全模式下展示,例如用户A进入系统安全模式进行转账操作,而此时系统普通模式下的应用“微信”接收到用户B发送过来的转账账号时,此时在系统安全模式不会显示接收到的“微信”消息,为用户带来不便,用户体验较差,无法提起用户使用安全模式的兴趣,导致安全模式的使用率降低,从而导致移动终端的系统安全无法得到保证。At present, the security mode of the Android system is created based on the Android multi-user mode. Generally, users install ordinary applications in the system normal mode, and install applications with higher security in the system security mode. Data between different users cannot be directly shared, so that when the system is in safe mode, messages received by applications in normal mode cannot be displayed in safe mode. When the application "WeChat" of user B receives the transfer account number sent by user B, the received "WeChat" message will not be displayed in the system security mode at this time, which brings inconvenience to the user and the user experience is poor, and the user cannot be reminded to use the security mode. interest, resulting in a decrease in the usage rate of the security mode, and thus the system security of the mobile terminal cannot be guaranteed.

因此,使用系统安全模式为用户带来安全性的同时,如何提高系统安全模式的易用性、提高用户体验,进而提起用户使用安全模式的兴趣,更好地保证终端系统的安全是目前亟需解决的问题。Therefore, while using the system security mode to bring security to the user, how to improve the usability of the system security mode, improve the user experience, and then arouse the user's interest in using the security mode to better ensure the security of the terminal system is an urgent need at present. solved problem.

【发明内容】[Content of the invention]

鉴于上述问题,本发明的首要目的在于提供一种应用消息事件控制方法及装置;In view of the above problems, the primary purpose of the present invention is to provide an application message event control method and device;

本发明的另一目的在于提供一种实现所述应用消息事件控制方法的移动终端。Another object of the present invention is to provide a mobile terminal implementing the application message event control method.

为实现该目的,本发明采用如下技术方案:To achieve this purpose, the present invention adopts the following technical solutions:

第一方面,本发明提供一种应用消息事件控制方法,包括如下步骤:In a first aspect, the present invention provides an application message event control method, comprising the following steps:

在监测到预设应用的消息事件时,判断当前系统是否处于以第二用户登录的安全模式,所述预设应用为运行于以第一用户登录的系统普通模式的应用程序;When monitoring a message event of a preset application, determine whether the current system is in a safe mode logged in with the second user, and the preset application is an application running in the normal mode of the system logged in with the first user;

若当前系统处于安全模式下,基于系统进程通信机制将所述消息事件传递给系统安全模式对应的服务进程,以通过所述服务进程在系统安全模式下输出响应所述消息事件后产生的通知消息。If the current system is in the safe mode, the message event is transmitted to the service process corresponding to the system safe mode based on the system process communication mechanism, so as to output the notification message generated in response to the message event through the service process in the system safe mode .

结合第一方面,本发明的第一种可能的实现方式,所述服务进程为安卓系统的通知管理服务进程,所述消息事件为通知事件,相应的,所述通知消息为系统通知栏消息,所述通知管理服务进程受所述通知事件驱动而在系统通知栏输出相应的通知栏消息。In combination with the first aspect, in a first possible implementation manner of the present invention, the service process is a notification management service process of the Android system, the message event is a notification event, and correspondingly, the notification message is a system notification bar message, The notification management service process is driven by the notification event and outputs the corresponding notification bar message in the system notification bar.

结合第一方面的第一种实现方式,本发明的第二种可能的实现方式,通过安卓系统通知管理服务进程固有的监听器监测预设应用的通知事件。In combination with the first implementation manner of the first aspect, the second possible implementation manner of the present invention monitors notification events of a preset application through a listener inherent in the Android system notification management service process.

结合第一方面,本发明的第三种可能的实现方式,所述服务进程为安卓系统的闹钟管理服务进程,所述消息事件为闹钟事件,相应的,所述通知消息为与闹钟相关的通知消息,所述闹钟管理服务进程受所述闹钟事件驱动输出相应的闹钟消息。In combination with the first aspect, in a third possible implementation manner of the present invention, the service process is an alarm clock management service process of the Android system, the message event is an alarm clock event, and correspondingly, the notification message is a notification related to an alarm clock message, the alarm clock management service process is driven by the alarm clock event to output a corresponding alarm clock message.

结合第一方面的第三种实现方式,本发明的第四种可能的实现方式,通过注册广播监听器监测预设应用的闹钟事件。In combination with the third implementation manner of the first aspect, the fourth possible implementation manner of the present invention is to monitor the alarm clock event of the preset application by registering a broadcast listener.

结合第一方面的第一种实现方式或第三种实现方式,本发明的第五种可能的实现方式,所述输出响应所述消息事件后产生的通知消息,还包括指示灯显示、铃声播放、震动反馈的一种或多种。Combined with the first implementation or the third implementation of the first aspect, and the fifth possible implementation of the present invention, the outputting a notification message generated after responding to the message event also includes indicator light display, ringtone playback , one or more of vibration feedback.

结合第一方面,本发明的第六种可能的实现方式,所述服务进程在系统安全模式下输出响应所述消息事件后产生的通知消息与在系统普通模式下输出响应所述消息事件后产生的通知消息一致。In combination with the first aspect, the sixth possible implementation manner of the present invention, the service process outputs the notification message generated after responding to the message event in the system security mode and the notification message generated in response to the message event in the system normal mode. The notification message is the same.

结合第一方面,本发明的第七种可能的实现方式,当在系统安全模式下输出响应所述消息事件后产生的通知消息时,所述通知消息对应的预设应用所配置的图标与在系统普通模式下的预设应用的初始图标不同。With reference to the first aspect, in the seventh possible implementation manner of the present invention, when a notification message generated after responding to the message event is output in the system security mode, the icon configured in the preset application corresponding to the notification message is the same as the one in the system security mode. The initial icons of the default applications in the system normal mode are different.

结合第一方面的第一种实现方式,本发明的第八种可能的实现方式,还包括步骤:In conjunction with the first implementation manner of the first aspect, the eighth possible implementation manner of the present invention further includes the steps:

响应作用于系统安全模式下的通知栏消息的控制指令,将系统从安全模式切换到普通模式,并打开所述消息事件相对应的预设应用。In response to the control instruction acting on the notification bar message in the system safe mode, the system is switched from the safe mode to the normal mode, and the preset application corresponding to the message event is opened.

结合第一方面的第八种实现方式,本发明的第九种可能的实现方式,所述将系统从安全模式切换到普通模式,具体还包括:In combination with the eighth implementation manner of the first aspect, the ninth possible implementation manner of the present invention, the switching of the system from the safe mode to the normal mode specifically further includes:

将系统从第二用户登录状态切换至第一用户登录状态。Switch the system from the second user login state to the first user login state.

结合第一方面的第九种实现方式,本发明的第十种可能的实现方式,通过调用安卓系统的ActivityManager类中的switchUser()方法将系统从第二用户登录状态切换至第一用户登录状态。In combination with the ninth implementation manner of the first aspect, the tenth possible implementation manner of the present invention switches the system from the second user login state to the first user login state by calling the switchUser() method in the ActivityManager class of the Android system .

相应地,第二方面,本发明提供一种应用消息事件控制装置,该装置具有实现上述第一方面中应用程序安装方法的功能,所述功能可以通过硬件实现,也可以通过硬件执行相应的软件实现,所述硬件或软件包括一个或多个与上述功能相对应的模块,具体包括:Correspondingly, in the second aspect, the present invention provides an application message event control device, the device has the function of implementing the application program installation method in the above-mentioned first aspect, and the function can be realized by hardware, and can also be executed by hardware. Implementation, the hardware or software includes one or more modules corresponding to the above functions, specifically including:

监测模块:用于在监测到预设应用的消息事件时,判断当前系统是否处于以第二用户登录的安全模式,所述预设应用为运行于以第一用户登录的系统普通模式的应用程序;Monitoring module: used to judge whether the current system is in the safe mode of logging in with the second user when the message event of the preset application is monitored, and the preset application is an application running in the normal mode of the system logged in with the first user ;

传递模块:用于若当前系统处于安全模式下,基于系统进程通信机制将所述消息事件传递给系统安全模式对应的服务进程,以通过所述服务进程在系统安全模式下输出响应所述消息事件后产生的通知消息。Delivery module: used to transmit the message event to the service process corresponding to the system security mode based on the system process communication mechanism if the current system is in the security mode, so as to output the response to the message event in the system security mode through the service process The notification message generated later.

结合第二方面,本发明的第一种可能的实现方式,所述服务进程为安卓系统的通知管理服务进程,所述消息事件为通知事件,相应的,所述通知消息为系统通知栏消息,所述通知管理服务进程受所述通知事件驱动而在系统通知栏输出相应的通知栏消息。In combination with the second aspect, in the first possible implementation manner of the present invention, the service process is a notification management service process of the Android system, the message event is a notification event, and correspondingly, the notification message is a system notification bar message, The notification management service process is driven by the notification event and outputs the corresponding notification bar message in the system notification bar.

结合第二方面的第一种实现方式,本发明的第二种可能的实现方式,通过安卓系统通知管理服务进程固有的监听器监测预设应用的通知事件。In combination with the first implementation manner of the second aspect, the second possible implementation manner of the present invention monitors notification events of a preset application through a listener inherent in the Android system notification management service process.

结合第二方面,本发明的第三种可能的实现方式,所述服务进程为安卓系统的闹钟管理服务进程,所述消息事件为闹钟事件,相应的,所述通知消息为与闹钟相关的通知消息,所述闹钟管理服务进程受所述闹钟事件驱动输出相应的闹钟消息。In combination with the second aspect, in a third possible implementation manner of the present invention, the service process is an alarm clock management service process of the Android system, the message event is an alarm clock event, and correspondingly, the notification message is a notification related to an alarm clock message, the alarm clock management service process is driven by the alarm clock event to output a corresponding alarm clock message.

结合第二方面的第三种实现方式,本发明的第四种可能的实现方式,通过注册广播监听器监测预设应用的闹钟事件。In combination with the third implementation manner of the second aspect, the fourth possible implementation manner of the present invention is to monitor the alarm clock event of the preset application by registering a broadcast listener.

结合第二方面的第一种实现方式或第三种实现方式,本发明的第五种可能的实现方式,所述输出响应所述消息事件后产生的通知消息,还包括指示灯显示、铃声播放、震动反馈的一种或多种。Combined with the first implementation or the third implementation of the second aspect, and the fifth possible implementation of the present invention, the outputting a notification message generated after responding to the message event also includes indicator light display, ringtone playing , one or more of vibration feedback.

结合第二方面,本发明的第六种可能的实现方式,所述服务进程在系统安全模式下输出响应所述消息事件后产生的通知消息与在系统普通模式下输出响应所述消息事件后产生的通知消息一致。With reference to the second aspect, a sixth possible implementation manner of the present invention, the service process outputs the notification message generated after responding to the message event in the system security mode, and the service process outputs the notification message generated in response to the message event in the system normal mode. The notification message is the same.

结合第二方面,本发明的第七种可能的实现方式,当在系统安全模式下输出响应所述消息事件后产生的通知消息时,所述通知消息对应的预设应用所配置的图标与在系统普通模式下的预设应用的初始图标不同。With reference to the second aspect, in the seventh possible implementation manner of the present invention, when a notification message generated after responding to the message event is output in the system security mode, the icon configured in the preset application corresponding to the notification message is the same as the one in the system security mode. The initial icons of the default applications in the system normal mode are different.

结合第二方面,本发明的第八种可能的实现方式,还包括:In conjunction with the second aspect, the eighth possible implementation manner of the present invention also includes:

切换模块:用于响应作用于系统安全模式下的通知栏消息的控制指令,将系统从安全模式切换到普通模式,并打开所述消息事件相对应的预设应用。Switching module: In response to the control instruction acting on the notification bar message in the system safe mode, the system is switched from the safe mode to the normal mode, and the preset application corresponding to the message event is opened.

结合第二方面的第八种实现方式,本发明的第九种可能的实现方式,所述切换模块还包括:In combination with the eighth implementation manner of the second aspect, in the ninth possible implementation manner of the present invention, the switching module further includes:

用户切换单元:用于将系统从第二用户登录状态切换至第一用户登录状态。User switching unit: used to switch the system from the second user login state to the first user login state.

结合第二方面的第九种实现方式,本发明的第十种可能的实现方式,所述切换单元通过调用安卓系统的ActivityManager类中的switchUser()方法将系统从第二用户登录状态切换至第一用户登录状态。In combination with the ninth implementation manner of the second aspect and the tenth possible implementation manner of the present invention, the switching unit switches the system from the second user login state to the first by calling the switchUser() method in the ActivityManager class of the Android system. A user login status.

第三方面,本发明还提供一种移动终端,其特征在于,包括:In a third aspect, the present invention also provides a mobile terminal, characterized in that it includes:

触敏显示器:用于显示该方法实现过程中产生的中间信息及结果信息;Touch-sensitive display: used to display the intermediate information and result information generated during the implementation of the method;

存储器:用于存储上述方法实现过程中产生的候选中间数据以及结果数据;Memory: used to store candidate intermediate data and result data generated during the implementation of the above method;

一个或多个处理器:所述处理器被配置为用于执行实现上述方法的步骤。One or more processors: The processors are configured to perform steps implementing the above methods.

与现有技术相比,本发明具备如下优点:Compared with the prior art, the present invention has the following advantages:

本发明通过监测预设应用的消息事件,将系统普通模式下的预设应用的消息事件同步到系统安全模式下,让用户在系统安全模式下仍然能第一时间接收到普通模式下的预设应用发出的消息事件对应的通知消息;By monitoring the message events of the preset applications, the present invention synchronizes the message events of the preset applications in the system normal mode to the system security mode, so that the user can still receive the preset applications in the normal mode for the first time in the system security mode. The notification message corresponding to the message event sent by the application;

同时,所述预设应用为用户常用的具有时间类提醒的应用和通讯类应用,对于该类应用的消息的及时通知,可以增强用户体验,提高用户使用安全模式的兴趣,提高安全模式的使用率,进而保障用户终端的系统安全。At the same time, the preset application is an application with a time type reminder and a communication type application commonly used by users. The timely notification of messages of this type of application can enhance the user experience, increase the user's interest in using the security mode, and improve the use of the security mode. rate, thereby ensuring the system security of the user terminal.

显然,上述有关本发明优点的描述是概括性的,更多的优点描述将体现在后续的实施例揭示中,以及,本领域技术人员也可以本发明所揭示的内容合理地发现本发明的其他诸多优点。Obviously, the above description about the advantages of the present invention is general, and more advantages will be described in the subsequent embodiments disclosed, and those skilled in the art can also reasonably find other aspects of the present invention from the content disclosed in the present invention. many advantages.

本发明附加的方面和优点将在下面的描述中部分给出,这些将从下面的描述中变得明显,或通过本发明的实践了解到。Additional aspects and advantages of the present invention will be set forth in part in the following description, which will be apparent from the following description, or may be learned by practice of the present invention.

【附图说明】【Description of drawings】

图1为本发明应用消息事件控制方法的一实施例流程示意图;FIG. 1 is a schematic flowchart of an embodiment of a method for controlling an application message event according to the present invention;

图2为Binder通信机制的C/S模型示意图;Figure 2 is a schematic diagram of the C/S model of the Binder communication mechanism;

图3为本发明应用消息事件控制装置的一实施例示意图;FIG. 3 is a schematic diagram of an embodiment of an application message event control device according to the present invention;

图4为本发明实施例提供的移动终端部分结构的一实施例示意框图。FIG. 4 is a schematic block diagram of an embodiment of a partial structure of a mobile terminal according to an embodiment of the present invention.

【具体实施方式】【Detailed ways】

下面结合附图和示例性实施例对本发明作进一步地描述,其中附图中相同的标号全部指的是相同的The present invention will be further described below with reference to the accompanying drawings and exemplary embodiments, wherein the same reference numerals in the drawings all refer to the same

本技术领域技术人员可以理解,除非特意声明,这里使用的单数形式“一”、“一个”、“所述”和“该”也可包括复数形式。应该进一步理解的是,本发明的说明书中使用的措辞“包括”是指存在所述特征、整数、步骤、操作、元件和/或组件,但是并不排除存在或添加一个或多个其他特征、整数、步骤、操作、元件、组件和/或它们的组。应该理解,当我们称元件被“连接”或“耦接”到另一元件时,它可以直接连接或耦接到其他元件,或者也可以存在中间元件。此外,这里使用的“连接”或“耦接”可以包括无线连接或无线耦接。这里使用的措辞“和/或”包括一个或更多个相关联的列出项的全部或任一单元和全部组合。It will be understood by those skilled in the art that the singular forms "a", "an", "the" and "the" as used herein can include the plural forms as well, unless expressly stated otherwise. It should be further understood that the word "comprising" used in the description of the present invention refers to the presence of stated features, integers, steps, operations, elements and/or components, but does not exclude the presence or addition of one or more other features, Integers, steps, operations, elements, components and/or groups thereof. It will be understood that when we refer to an element as being "connected" or "coupled" to another element, it can be directly connected or coupled to the other element or intervening elements may also be present. Furthermore, "connected" or "coupled" as used herein may include wirelessly connected or wirelessly coupled. As used herein, the term "and/or" includes all or any element and all combination of one or more of the associated listed items.

本技术领域技术人员可以理解,除非另外定义,这里使用的所有术语(包括技术术语和科学术语),具有与本发明所属领域中的普通技术人员的一般理解相同的意义。还应该理解的是,诸如通用字典中定义的那些术语,应该被理解为具有与现有技术的上下文中的意义一致的意义,并且除非像这里一样被特定定义,否则不会用理想化或过于正式的含义来解释。It will be understood by those skilled in the art that, unless otherwise defined, all terms (including technical and scientific terms) used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs. It should also be understood that terms, such as those defined in a general dictionary, should be understood to have meanings consistent with their meanings in the context of the prior art and, unless specifically defined as herein, should not be interpreted in idealistic or overly formal meaning to explain.

本技术领域技术人员可以理解,这里所使用的“终端”、“终端设备”既包括无线信号接收器的设备,其仅具备无发射能力的无线信号接收器的设备,又包括接收和发射硬件的设备,其具有能够在双向通信链路上,执行双向通信的接收和发射硬件的设备。这种设备可以包括:蜂窝或其他通信设备,其具有单线路显示器或多线路显示器或没有多线路显示器的蜂窝或其他通信设备;PCS(Personal Communications Service,个人通信系统),其可以组合语音、数据处理、传真和/或数据通信能力;PDA(Personal Digital Assistant,个人数字助理),其可以包括射频接收器、寻呼机、互联网/内联网访问、网络浏览器、记事本、日历和/或GPS(Global Positioning System,全球定位系统)接收器;常规膝上型和/或掌上型计算机或其他设备,其具有和/或包括射频接收器的常规膝上型和/或掌上型计算机或其他设备。这里所使用的“终端”、“移动终端”、“终端设备”可以是便携式、可运输、安装在交通工具(航空、海运和/或陆地)中的,或者适合于和/或配置为在本地运行,和/或以分布形式,运行在地球和/或空间的任何其他位置运行。这里所使用的“终端”、“移动终端”、“终端设备”还可以是通信终端、上网终端、音乐/视频播放终端,例如可以是PDA、MID(MobileInternet Device,移动互联网设备)和/或具有音乐/视频播放功能的移动电话,也可以是智能电视、机顶盒等设备。Those skilled in the art can understand that the "terminal" and "terminal device" used here include both a wireless signal receiver device that only has a wireless signal receiver without transmission capability, and a device that includes receiving and transmitting hardware. A device having receive and transmit hardware capable of performing two-way communications over a two-way communication link. Such equipment may include: cellular or other communication equipment, which has a single-line display or a multi-line display or a cellular or other communication device without a multi-line display; PCS (Personal Communications Service), which can combine voice, data Processing, fax and/or data communication capabilities; PDA (Personal Digital Assistant), which may include a radio frequency receiver, pager, Internet/Intranet access, web browser, notepad, calendar and/or GPS (Global Positioning System) receiver; conventional laptop and/or palmtop computer or other device having and/or including a conventional laptop and/or palmtop computer or other device with a radio frequency receiver. As used herein, "terminal", "mobile terminal", "terminal device" may be portable, transportable, mounted in a vehicle (air, marine and/or land), or adapted and/or configured to be locally operate, and/or in distributed form, operate at any other location on Earth and/or space. The "terminal", "mobile terminal" and "terminal device" used here can also be a communication terminal, an Internet terminal, and a music/video playing terminal, such as a PDA, MID (Mobile Internet Device) and/or a A mobile phone with music/video playback function, or a smart TV, a set-top box, and other devices.

本技术领域技术人员可以理解,这里所使用的远端网络设备,其包括但不限于计算机、网络主机、单个网络服务器、多个网络服务器集或多个服务器构成的云。在此,云由基于云计算(Cloud Computing)的大量计算机或网络服务器构成,其中,云计算是分布式计算的一种,由一群松散耦合的计算机集组成的一个超级虚拟计算机。本发明的实施例中,远端网络设备、终端设备与WNS服务器之间可通过任何通信方式实现通信,包括但不限于,基于3GPP、LTE、WIMAX的移动通信、基于TCP/IP、UDP协议的计算机网络通信以及基于蓝牙、红外传输标准的近距无线传输方式。Those skilled in the art can understand that the remote network device used here includes, but is not limited to, a computer, a network host, a single network server, a set of multiple network servers, or a cloud composed of multiple servers. Here, the cloud is composed of a large number of computers or network servers based on cloud computing, wherein cloud computing is a kind of distributed computing, a super virtual computer composed of a group of loosely coupled computer sets. In the embodiment of the present invention, the communication between the remote network device, the terminal device and the WNS server can be implemented by any communication method, including but not limited to, mobile communication based on 3GPP, LTE, and WIMAX, and communication based on TCP/IP and UDP protocols. Computer network communication and short-range wireless transmission based on Bluetooth and infrared transmission standards.

本技术领域技术人员可以理解,本发明所述的用户界面/操作界面泛指能够用于向智能终端发送控制指令的显示界面,例如,可以为Android系统的设置页面中的一个选项(或按键,由所述应用程序添加其中,下同),也可以是从桌面呼出的通知栏或者交互页面中的一个选项,还可以是所述应用程序的一个活动组件所构造的页面中的一个选项。Those skilled in the art can understand that the user interface/operation interface described in the present invention generally refers to a display interface that can be used to send control instructions to an intelligent terminal, for example, it can be an option (or button, It can be added by the application program, the same below), or it can be an option in the notification bar or interactive page called out from the desktop, or it can be an option in a page constructed by an active component of the application program.

本领域技术人员应当理解,本发明所称的“应用”、“应用程序”、“应用软件”以及类似表述的概念,是业内技术人员所公知的相同概念,是指由一系列计算机指令及相关数据资源有机构造的适于电子运行的计算机软件。除非特别指定,这种命名本身不受编程语言种类、级别,也不受其赖以运行的操作系统或平台所限制。理所当然地,此类概念也不受任何形式的终端所限制。Those skilled in the art should understand that the concepts of "application", "application program", "application software" and similar expressions in the present invention are the same concepts known to those skilled in the art, and refer to a series of computer instructions and related concepts. Data resources are organically constructed computer software suitable for electronic execution. Unless otherwise specified, the naming itself is not limited by the type or level of programming language, nor by the operating system or platform on which it runs. Of course, such concepts are also not limited by any form of terminal.

在以下的描述中,系统是移动终端的操作系统,例如安卓系统、iOS移动操作系统等等。在以下的描述中,以安卓系统作为示例性说明。In the following description, a system is an operating system of a mobile terminal, such as an Android system, an iOS mobile operating system, and the like. In the following description, the Android system is used as an example.

步骤S100:在监测到预设应用的消息事件时,判断当前系统是否处于以第二用户登录的安全模式,所述预设应用为运行于以第一用户登录的系统普通模式的应用程序。Step S100 : when a message event of a preset application is monitored, determine whether the current system is in a safe mode logged in with the second user, the preset application being an application running in the normal mode of the system logged in with the first user.

所述消息事件包括通知事件和闹钟事件,安卓系统中,通知(Notification)是一种具有全局效果的事件,通知一般通过NotificationManager服务发送一个Notification对象来完成,NotificationManager是一个系统级服务,应用程序通过它向系统发送全局的通知,本实施例利用NotificationListenerService监测所述通知事件;闹钟事件由安卓系统中的AlarmManager实现,其对应有一个AlarmManagerServie服务程序来提供闹钟服务,一旦有闹钟事件发生,AlarmManagerServie服务程序就会遍历闹钟列表找到相应的注册闹钟并发出广播,系统提供了两个Action用于广播闹钟事件,本实施例通过注册一个广播监听器以监测所述闹钟事件。The message events include notification events and alarm events. In the Android system, notification (Notification) is an event with a global effect. Notification is generally completed by sending a Notification object through the NotificationManager service. NotificationManager is a system-level service. It sends a global notification to the system. In this embodiment, the NotificationListenerService is used to monitor the notification event; the alarm clock event is implemented by the AlarmManager in the Android system, which corresponds to an AlarmManagerServie service program to provide the alarm clock service. Once an alarm clock event occurs, the AlarmManagerServie service program The alarm clock list will be traversed to find the corresponding registered alarm clock and broadcast. The system provides two Actions for broadcasting alarm clock events. In this embodiment, a broadcast listener is registered to monitor the alarm clock events.

可以理解的是,上述监测消息事件的方法为示例性方法,本领域技术人员可以根据本实施例的实现逻辑利用其他方法监测消息事件,不能将其理解为对本方法的限制。It can be understood that the above method for monitoring message events is an exemplary method, and those skilled in the art can use other methods to monitor message events according to the implementation logic of this embodiment, which should not be construed as a limitation on this method.

终端在监测到消息事件后,首先判断发起该消息事件对应的应用是否为预设应用,具体的,通过获取发起该消息事件对应的应用的包名,然后查询该包名是否存在于预设的应用名单中,若存在则确定该消息事件为预设应用的消息事件。After monitoring the message event, the terminal first determines whether the application corresponding to initiating the message event is a preset application. Specifically, it obtains the package name of the application corresponding to initiating the message event, and then queries whether the package name exists in the preset application. In the application list, if it exists, it is determined that the message event is the message event of the preset application.

具体的,所述预设应用为运行于以第一用户登录的系统普通模式的应用程序,本实施例中,所述终端系统基于安卓多用户模式创建了一个新的用户,在创建新用户后,会在/data/system/users/userlist.xml文件中保存新用户的id(uid),然后创建/data/system/users/uid目录,并将用户信息保存至其下的uid.xml文件中,同时每一个用户均分配有独立的存储空间,用于存放各自的应用数据和用户数据。安卓系统的默认用户(即管理员用户)uid为0,默认用户对应于本实施例的第一用户,新创建的第一个用户(即普通用户)uid为10,新创建的用户对应于本实施例的第二用户,安卓多用户模式支持创建多个新用户,若在创建10用户后再创建一个新用户,其uid为11,同样为本实施例所述的第二用户,并且本实施例中定义系统以第一用户登录时为系统普通模式,以第二用户登录时为系统安全模式,由于多用户模式下的数据资源相互独立且无法直接进行读写操作,本实施例中所述系统安全模式配置有用于为安全性要求较高的应用的运行提供运行资源的安全空间,该安全空间在系统普通模式下是不可访问的,同时该安全性要求较高的应用安装在安全模式下对应的第二用户的存储目录下。Specifically, the preset application is an application running in the normal mode of the system logged in as the first user. In this embodiment, the terminal system creates a new user based on the Android multi-user mode. After the new user is created , will save the new user's id (uid) in the /data/system/users/userlist.xml file, then create the /data/system/users/uid directory, and save the user information to the uid.xml file under it , and each user is allocated an independent storage space for storing their own application data and user data. The uid of the default user (that is, the administrator user) of the Android system is 0, the default user corresponds to the first user in this embodiment, the uid of the first newly created user (that is, the ordinary user) is 10, and the newly created user corresponds to this. The second user of the embodiment, the Android multi-user mode supports the creation of multiple new users. If a new user is created after 10 users are created, its uid is 11, which is also the second user described in this embodiment, and this embodiment In the example, the system is defined as the system normal mode when the first user logs in, and the system security mode when the second user logs in. Since the data resources in the multi-user mode are independent of each other and cannot be directly read and written, the description in this embodiment The system safe mode is configured with a safe space for providing running resources for the operation of applications with high security requirements. The safe space is inaccessible in the normal mode of the system, and the applications with high security requirements are installed in the safe mode. Under the storage directory of the corresponding second user.

更具体的,所述预设应用包括系统普通模式下的闹钟、日历表、日程表等具有时间提醒功能的应用,同时还包括如微信、邮箱等通讯类应用,更佳地,所述预设应用允许用户自行添加和删除,例如,用户可以选择添加已安装的应用“顺丰速运”为预设应用,选择添加后系统获取应用“顺丰速运”的包名并将其添加到预设的应用名单中。More specifically, the preset applications include applications with time reminder functions such as alarm clocks, calendars, and schedules in the normal mode of the system, and also include communication applications such as WeChat and mailboxes. Applications allow users to add and delete applications by themselves. For example, users can choose to add the installed application "SF Express" as a default application. After selecting the addition, the system obtains the package name of the application "SF Express" and adds it to the default application. application list.

当确定所述消息事件为预设应用的消息事件后,接着判断当前系统是否处于以第二用户登录的安全模式。After it is determined that the message event is a message event of a preset application, it is then determined whether the current system is in the security mode of logging in with the second user.

步骤S200:若当前系统处于安全模式下,基于系统进程通信机制将所述消息事件传递给系统安全模式对应的服务进程,以通过所述服务进程在系统安全模式下输出响应所述消息事件后产生的通知消息。Step S200: If the current system is in the safe mode, the message event is transmitted to the service process corresponding to the system safe mode based on the system process communication mechanism, so as to generate the message event by outputting the response to the message event in the system safe mode through the service process. notification message.

由上述可知,系统为每一个用户都分配有各自的uid,第一用户的uid为0,若当前系统运行的用户uid不为0,则可以判断当前系统以第二用户登录,在本实施例中以创建的第一个新用户为第二用户进行说明,该第二用户的uid为10,当确定所述消息事件为预设应用的消息事件后,获取系统当前运行的用户的uid,若uid为10则确定当前系统处于以第二用户登录的安全模式,然后基于系统进程通信机制将所述消息事件传递给系统安全模式对应的服务进程,以通过所述服务进程在系统安全模式下输出响应所述消息事件后产生的通知消息。It can be seen from the above that the system allocates its own uid to each user, and the uid of the first user is 0. If the uid of the user currently running the system is not 0, it can be judged that the current system is logged in as the second user. In this embodiment The uid of the second user is 10. After determining that the message event is the message event of the preset application, the uid of the user currently running the system is obtained. If If the uid is 10, it is determined that the current system is in the safe mode of logging in with the second user, and then the message event is transmitted to the service process corresponding to the system safe mode based on the system process communication mechanism, so as to output the output in the system safe mode through the service process A notification message generated in response to the message event.

具体的,所述系统通信机制为安卓系统的Binder通信机制,Binder是安卓系统进程间通信(IPC)方式之一,安卓系统中的大多数Service都是通过Binder来通信的,同时Binder通信机制是通过C/S模型实现的,如图2所示是Binder通信机制的C/S模型示意图,其中,服务管理器、客户端、服务端分别对应安卓系统中的Service Manager、Client及Server,Service Manager是系统中一个独立的进程,它是整个Binder机制的守护进程,用来管理开发者创建的各种Server,并且向Client提供查询Server远程接口的功能;Server为众多服务(Service)的拥有者,当Server向Client提供服务时,先去Service Manager注册自己的服务,注册成功后Service Manager将相应的Service加入到svcList中并告知Server服务注册成功,Server可以向Service Manager注册一个或多个服务;Client为服务的使用者,当它想使用服务时,得向Service Manager申请自己所需要的服务,ServiceManager查找相应的Service后返回给客户端Client,同样的,Client可以申请一个或多个服务,当Client申请服务成功后,Client就可以使用服务了。其中,三者的通信方式均是Binder机制,Server向Service Manager注册服务,使用Binder通信,Client向ServiceManager申请服务,使用的也是Binder通信,Client和Server是存在于用户空间,Client与Server通信的实现,是由Binder驱动在内核空间实现。Specifically, the system communication mechanism is the Binder communication mechanism of the Android system, and the Binder is one of the inter-process communication (IPC) methods of the Android system. Most services in the Android system communicate through the Binder, and the Binder communication mechanism is Realized by the C/S model, as shown in Figure 2 is a schematic diagram of the C/S model of the Binder communication mechanism, in which the service manager, the client, and the server correspond to the Service Manager, Client and Server in the Android system, and the Service Manager It is an independent process in the system. It is the daemon process of the entire Binder mechanism. It is used to manage various Servers created by developers and provide Client with the function of querying the remote interface of Server; Server is the owner of many services. When the Server provides services to the Client, it first goes to the Service Manager to register its own service. After the registration is successful, the Service Manager adds the corresponding Service to the svcList and informs the Server that the service registration is successful. The Server can register one or more services with the Service Manager; Client For the user of the service, when it wants to use the service, it has to apply for the service it needs from the Service Manager. The ServiceManager finds the corresponding Service and returns it to the client Client. Similarly, the Client can apply for one or more services. When the Client After successfully applying for the service, the Client can use the service. Among them, the communication mode of the three is the Binder mechanism, the Server registers the service with the Service Manager, uses the Binder communication, the Client applies for the service to the ServiceManager, and also uses the Binder communication, the Client and the Server exist in the user space, and the realization of the communication between the Client and the Server , is implemented in kernel space by Binder driver.

在本实施例中,当监测到预设应用的消息事件且当前系统处于安全模式下时,将普通模式下的预设应用的消息事件通过Binder传递给安全模式下的服务进程,所述服务进程在接收到所述消息事件后,根据消息事件的指示信息进行响应,在系统安全模式下输出相应的通知消息。In this embodiment, when the message event of the preset application is monitored and the current system is in the safe mode, the message event of the preset application in the normal mode is transmitted to the service process in the safe mode through the binder, and the service process After receiving the message event, it responds according to the indication information of the message event, and outputs a corresponding notification message in the system security mode.

一种实施例中,所述服务进程为安卓系统的通知管理服务进程,所述消息事件则为通知事件,相应地,通知事件所触发的是通知栏消息,即通知管理服务进程受所述通知事件驱动而在系统通知栏输出相应的通知栏消息,例如,在接收到应用“微信”的通知事件时,将“微信”的通知消息展现在系统通知栏中,用户在系统安全模式下仍可以关注到“微信”的消息。In one embodiment, the service process is a notification management service process of the Android system, and the message event is a notification event. Correspondingly, the notification event triggers a notification bar message, that is, the notification management service process is subject to the notification. Event-driven and output the corresponding notification bar message in the system notification bar, for example, when receiving the notification event of the application "WeChat", the "WeChat" notification message is displayed in the system notification bar, the user can still be in the system safe mode. Pay attention to the news of "WeChat".

另外,通知消息的表现形式不止表现为在状态栏中输出,还包括以显示呼吸灯、显示闪光灯、铃声播放的一种/多种形式在系统安全模式下输出,较佳地,该通知消息在系统普通模式下以何种形式输出,在系统安全模式下仍然以相同的形式输出,更符合用户的使用习惯。更佳地,所述在安全模式下输出的通知栏消息对应的应用图标与在普通模式下不同,具体的,可以为安全模式下通知栏消息中的应用图标添加图戳和/或文字以让用户知晓该通知消息为普通模式下的预设应用的通知消息。In addition, the presentation form of the notification message is not only output in the status bar, but also includes output in the system safe mode in one or more forms of displaying breathing light, flashing light, and ringtone playing. Preferably, the notification message is displayed in the system security mode. What form is output in the normal mode of the system, it is still output in the same form in the system safe mode, which is more in line with the user's usage habits. Preferably, the application icon corresponding to the notification bar message output in the safe mode is different from that in the normal mode. Specifically, a stamp and/or text may be added to the application icon in the notification bar message in the safe mode to make The user knows that the notification message is a notification message of a preset application in the normal mode.

另一种实施例中,所述服务进程为安卓系统的闹钟管理服务进程,所述消息事件即为闹钟事件,闹钟管理服务进程接收到所述消息事件后发送Intent启动相应的组件,当闹钟事件被触发时,一般都伴随着铃声、震动等反馈,另外还包括在用户界面上输出所述闹钟通知以让用户选择关闭/延迟闹钟通知。In another embodiment, the service process is an alarm clock management service process of the Android system, and the message event is an alarm event. After receiving the message event, the alarm management service process sends an Intent to start the corresponding component. When triggered, it is generally accompanied by feedback such as ringtone and vibration, and also includes outputting the alarm clock notification on the user interface to allow the user to choose to close/delay the alarm clock notification.

进一步的,当所述消息事件在通知栏中输出后,当用户点击通知栏中的通知消息时,终端响应于所述控制指令,将系统从安全模式切换到普通模式,并且在普通模式下打开相应的预设应用。Further, after the message event is output in the notification bar, when the user clicks the notification message in the notification bar, the terminal switches the system from the safe mode to the normal mode in response to the control instruction, and opens the system in the normal mode. The corresponding preset is applied.

具体的,在系统从安全模式切换到普通模式时,还包括将系统从第二用户登录状态切换至第一用户登录状态,在本实施例中,通过调用安卓系统的ActivityManager类中的switchUser()方法将系统从第二用户登录状态切换至第一用户登录状态。Specifically, when the system switches from the safe mode to the normal mode, it also includes switching the system from the second user login state to the first user login state. In this embodiment, by calling switchUser() in the ActivityManager class of the Android system The method switches the system from the second user login state to the first user login state.

同时,用户可以像在普通模式下操作通知消息一样对安全模式下的通知消息进行操作,例如将通知栏的通知消息向右滑则清除该通知消息,当闹钟事件在用户界面上输出闹钟界面并播放铃声时,点击用户界面上提供的“关闭”选项则关闭闹钟铃声播放。At the same time, the user can operate the notification message in the safe mode just like operating the notification message in the normal mode. For example, swiping the notification message in the notification bar to the right will clear the notification message. When playing a ringtone, tap the "Off" option provided on the user interface to turn off the alarm tone playback.

第二方面,如图3所示是本发明应用消息事件控制装置的一实施例示意图,包括:In the second aspect, as shown in FIG. 3 is a schematic diagram of an embodiment of the application message event control device of the present invention, including:

监测模块100:用于在监测到预设应用的消息事件时,判断当前系统是否处于以第二用户登录的安全模式,所述预设应用为运行于以第一用户登录的系统普通模式的应用程序。Monitoring module 100: for determining whether the current system is in a safe mode logged in with the second user when a message event of a preset application is monitored, where the preset application is an application running in the normal mode of the system logged in with the first user program.

所述消息事件包括通知事件和闹钟事件,安卓系统中,通知(Notification)是一种具有全局效果的事件,通知一般通过NotificationManager服务发送一个Notification对象来完成,NotificationManager是一个系统级服务,应用程序通过它向系统发送全局的通知,本实施例利用NotificationListenerService监测所述通知事件;闹钟事件由安卓系统中的AlarmManager实现,其对应有一个AlarmManagerServie服务程序来提供闹钟服务,一旦有闹钟事件发生,AlarmManagerServie服务程序就会遍历闹钟列表找到相应的注册闹钟并发出广播,系统提供了两个Action用于广播闹钟事件,本实施例通过注册一个广播监听器以监测所述闹钟事件。The message events include notification events and alarm events. In the Android system, notification (Notification) is an event with a global effect. Notification is generally completed by sending a Notification object through the NotificationManager service. NotificationManager is a system-level service. It sends a global notification to the system. In this embodiment, the NotificationListenerService is used to monitor the notification event; the alarm clock event is implemented by the AlarmManager in the Android system, which corresponds to an AlarmManagerServie service program to provide the alarm clock service. Once an alarm clock event occurs, the AlarmManagerServie service program The alarm clock list will be traversed to find the corresponding registered alarm clock and broadcast. The system provides two Actions for broadcasting alarm clock events. In this embodiment, a broadcast listener is registered to monitor the alarm clock events.

监测模块100在监测到消息事件后,首先判断发起该消息事件对应的应用是否为预设应用,具体的,通过获取发起该消息事件对应的应用的包名,然后查询该包名是否存在于预设的应用名单中,若存在则确定该消息事件为预设应用的消息事件。After monitoring the message event, the monitoring module 100 first determines whether the application corresponding to initiating the message event is a preset application, specifically, by acquiring the package name of the application corresponding to initiating the message event, and then querying whether the package name exists in the preset application. If it exists in the preset application list, it is determined that the message event is the message event of the preset application.

具体的,所述预设应用为运行于以第一用户登录的系统普通模式的应用程序,本实施例中,所述终端系统基于安卓多用户模式创建了一个新的用户,在创建新用户后,会在/data/system/users/userlist.xml文件中保存新用户的id(uid),然后创建/data/system/users/uid目录,并将用户信息保存至其下的uid.xml文件中,同时每一个用户均分配有独立的存储空间,用于存放各自的应用数据和用户数据。安卓系统的默认用户(即管理员用户)uid为0,默认用户对应于本实施例的第一用户,新创建的第一个用户(即普通用户)uid为10,新创建的用户对应于本实施例的第二用户,安卓多用户模式支持创建多个新用户,若在创建10用户后再创建一个新用户,其uid为11,同样为本实施例所述的第二用户,并且本实施例中定义系统以第一用户登录时为系统普通模式,以第二用户登录时为系统安全模式,由于多用户模式下的数据资源相互独立且无法直接进行读写操作,本实施例中所述系统安全模式配置有用于为安全性要求较高的应用的运行提供运行资源的安全空间,该安全空间在系统普通模式下是不可访问的,同时该安全性要求较高的应用安装在安全模式下对应的第二用户的存储目录下。Specifically, the preset application is an application running in the normal mode of the system logged in as the first user. In this embodiment, the terminal system creates a new user based on the Android multi-user mode. After the new user is created , will save the new user's id (uid) in the /data/system/users/userlist.xml file, then create the /data/system/users/uid directory, and save the user information to the uid.xml file under it , and each user is allocated an independent storage space for storing their own application data and user data. The uid of the default user (that is, the administrator user) of the Android system is 0, the default user corresponds to the first user in this embodiment, the uid of the first newly created user (that is, the ordinary user) is 10, and the newly created user corresponds to this. The second user of the embodiment, the Android multi-user mode supports the creation of multiple new users. If a new user is created after 10 users are created, its uid is 11, which is also the second user described in this embodiment, and this embodiment In the example, the system is defined as the system normal mode when the first user logs in, and the system security mode when the second user logs in. Since the data resources in the multi-user mode are independent of each other and cannot be directly read and written, the description in this embodiment The system safe mode is configured with a safe space for providing running resources for the operation of applications with high security requirements. The safe space is inaccessible in the normal mode of the system, and the applications with high security requirements are installed in the safe mode. Under the storage directory of the corresponding second user.

更具体的,所述预设应用包括系统普通模式下的闹钟、日历表、日程表等具有时间提醒功能的应用,同时还包括如微信、邮箱等通讯类应用,更佳地,所述预设应用允许用户自行添加和删除,例如,用户可以选择添加已安装的应用“顺丰速运”为预设应用,选择添加后系统获取应用“顺丰速运”的包名并将其添加到预设的应用名单中。More specifically, the preset applications include applications with time reminder functions such as alarm clocks, calendars, and schedules in the normal mode of the system, and also include communication applications such as WeChat and mailboxes. Applications allow users to add and delete applications by themselves. For example, users can choose to add the installed application "SF Express" as a default application. After selecting the addition, the system obtains the package name of the application "SF Express" and adds it to the default application. application list.

当监测模块100确定所述消息事件为预设应用的消息事件后,接着判断当前系统是否处于以第二用户登录的安全模式。After the monitoring module 100 determines that the message event is a message event of a preset application, it then determines whether the current system is in the security mode of logging in with the second user.

传递模块200:用于若当前系统处于安全模式下,基于系统进程通信机制将所述消息事件传递给系统安全模式对应的服务进程,以通过所述服务进程在系统安全模式下输出响应所述消息事件后产生的通知消息。The delivery module 200 is configured to transmit the message event to the service process corresponding to the system security mode based on the system process communication mechanism if the current system is in the security mode, so as to output the response to the message in the system security mode through the service process The notification message generated after the event.

由上述可知,系统为每一个用户都分配有各自的uid,第一用户的uid为0,若当前系统运行的用户uid不为0,则可以判断当前系统以第二用户登录,在本实施例中以创建的第一个新用户为第二用户进行说明,该第二用户的uid为10,当确定所述消息事件为预设应用的消息事件后,获取系统当前运行的用户的uid,若uid为10则确定当前系统处于以第二用户登录的安全模式,然后传递模块200基于系统进程通信机制将所述消息事件传递给系统安全模式对应的服务进程,以通过所述服务进程在系统安全模式下输出响应所述消息事件后产生的通知消息。It can be seen from the above that the system allocates its own uid to each user, and the uid of the first user is 0. If the uid of the user currently running the system is not 0, it can be judged that the current system is logged in as the second user. In this embodiment The uid of the second user is 10. After determining that the message event is the message event of the preset application, the uid of the user currently running the system is obtained. If If the uid is 10, it is determined that the current system is in the security mode of logging in with the second user, and then the delivery module 200 transmits the message event to the service process corresponding to the system security mode based on the system process communication mechanism, so as to use the service process in the system security mode. In the mode, the notification message generated after responding to the message event is output.

在本实施例中,当测模块100监测到预设应用的消息事件且当前系统处于安全模式下时,传递模块200将普通模式下的预设应用的消息事件通过Binder传递给安全模式下的服务进程,所述服务进程在接收到所述消息事件后,根据消息事件的指示信息进行响应,在系统安全模式下输出相应的通知消息。In this embodiment, when the detection module 100 monitors the message event of the preset application and the current system is in the safe mode, the delivery module 200 transmits the message event of the preset application in the normal mode to the service in the safe mode through the binder The service process, after receiving the message event, responds according to the indication information of the message event, and outputs a corresponding notification message in the system security mode.

一种实施例中,所述服务进程为安卓系统的通知管理服务进程,所述消息事件则为通知事件,相应地,通知事件所触发的是通知栏消息,即通知管理服务进程受所述通知事件驱动而在系统通知栏输出相应的通知栏消息,例如,在接收到应用“微信”的通知事件时,将“微信”的通知消息展现在系统通知栏中,用户在系统安全模式下仍可以关注到“微信”的消息。In one embodiment, the service process is a notification management service process of the Android system, and the message event is a notification event. Correspondingly, the notification event triggers a notification bar message, that is, the notification management service process is subject to the notification. Event-driven and output the corresponding notification bar message in the system notification bar, for example, when receiving the notification event of the application "WeChat", the "WeChat" notification message is displayed in the system notification bar, the user can still be in the system safe mode. Pay attention to the news of "WeChat".

另外,通知消息的表现形式不止表现为在状态栏中输出,还包括以显示呼吸灯、显示闪光灯、铃声播放的一种/多种形式在系统安全模式下输出,较佳地,该通知消息在系统普通模式下以何种形式输出,在系统安全模式下仍然以相同的形式输出,更符合用户的使用习惯。更佳地,所述在安全模式下输出的通知栏消息对应的应用图标与在普通模式下不同,具体的,可以为安全模式下通知栏消息中的应用图标添加图戳和/或文字以让用户知晓该通知消息为普通模式下的预设应用的通知消息。In addition, the presentation form of the notification message is not only output in the status bar, but also includes output in the system safe mode in one or more forms of displaying breathing light, flashing light, and ringtone playing. Preferably, the notification message is displayed in the system security mode. What form is output in the normal mode of the system, it is still output in the same form in the system safe mode, which is more in line with the user's usage habits. Preferably, the application icon corresponding to the notification bar message output in the safe mode is different from that in the normal mode. Specifically, a stamp and/or text may be added to the application icon in the notification bar message in the safe mode to make The user knows that the notification message is a notification message of a preset application in the normal mode.

另一种实施例中,所述服务进程为安卓系统的闹钟管理服务进程,所述消息事件即为闹钟事件,闹钟管理服务进程接收到所述消息事件后发送Intent启动相应的组件,当闹钟事件被触发时,一般都伴随着铃声、震动等反馈,另外还包括在用户界面上输出所述闹钟通知以让用户选择关闭/延迟闹钟通知。In another embodiment, the service process is an alarm clock management service process of the Android system, and the message event is an alarm event. After receiving the message event, the alarm management service process sends an Intent to start the corresponding component. When triggered, it is generally accompanied by feedback such as ringtone and vibration, and also includes outputting the alarm clock notification on the user interface to allow the user to choose to close/delay the alarm clock notification.

进一步的,当所述消息事件在通知栏中输出后,当用户点击通知栏中的通知消息时,切换模块响应于所述控制指令,将系统从安全模式切换到普通模式,并且在普通模式下打开相应的预设应用。Further, after the message event is output in the notification bar, when the user clicks the notification message in the notification bar, the switching module switches the system from the safe mode to the normal mode in response to the control instruction, and in the normal mode Open the corresponding preset app.

具体的,在系统从安全模式切换到普通模式时,还包括用户切换单元将系统从第二用户登录状态切换至第一用户登录状态,在本实施例中,用户切换单元通过调用安卓系统的ActivityManager类中的switchUser()方法将系统从第二用户登录状态切换至第一用户登录状态。Specifically, when the system switches from the safe mode to the normal mode, it further includes a user switching unit to switch the system from the second user login state to the first user login state. In this embodiment, the user switching unit calls the ActivityManager of the Android system by calling the ActivityManager of the Android system. The switchUser() method in the class switches the system from the second user login state to the first user login state.

同时,用户可以像在普通模式下操作通知消息一样对安全模式下的通知消息进行操作,例如将通知栏的通知消息向右滑则清除该通知消息,当闹钟事件在用户界面上输出闹钟界面并播放铃声时,点击用户界面上提供的“关闭”选项则关闭闹钟铃声播放。At the same time, the user can operate the notification message in the safe mode just like operating the notification message in the normal mode. For example, swiping the notification message in the notification bar to the right will clear the notification message. When playing a ringtone, tap the "Off" option provided on the user interface to turn off the alarm tone playback.

另外,第三方面,本发明还提供一种移动终端,用于实现应用程序安装方法,如图4所示,为了便于说明,仅示出了与本发明实施例相关的部分,具体技术细节未揭示的,请参照本发明实施例方法部分。该终端可以为包括手机、平板电脑、PDA(Personal DigitalAssistant,个人数字助理)、POS(Point of Sales,销售终端)、车载电脑等任意终端设备,以移动终端为手机为例:In addition, in a third aspect, the present invention also provides a mobile terminal for implementing an application installation method. As shown in FIG. 4 , for the convenience of description, only the part related to the embodiment of the present invention is shown, and the specific technical details are omitted. For disclosure, please refer to the method section of the embodiment of the present invention. The terminal can be any terminal device including a mobile phone, a tablet computer, a PDA (Personal Digital Assistant), a POS (Point of Sales, a sales terminal), a vehicle-mounted computer, etc. Take the mobile terminal as a mobile phone as an example:

图4示出的是与本发明实施例提供的移动终端相关的手机的部分结构的框图。参考图4,手机包括:基带处理模块410、存储器420、输入单元430、显示单元440、传感器450、音频电路460、无线保真(wireless fidelity,WiFi)模块470、处理器480、以及电源490等部件。本领域技术人员可以理解,图4中示出的手机结构并不构成对手机的限定,可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置。FIG. 4 is a block diagram showing a partial structure of a mobile phone related to a mobile terminal provided by an embodiment of the present invention. 4, the mobile phone includes: a baseband processing module 410, a memory 420, an input unit 430, a display unit 440, a sensor 450, an audio circuit 460, a wireless fidelity (WiFi) module 470, a processor 480, and a power supply 490, etc. part. Those skilled in the art can understand that the structure of the mobile phone shown in FIG. 4 does not constitute a limitation on the mobile phone, and may include more or less components than the one shown, or combine some components, or arrange different components.

基带处理模块410可用于合成即将发射的基带信号,或对接收到的基带信号进行解码。具体地说,就是发射时把音频信号编译成用来发射的基带码;接收时,把收到的基带码解译为音频信号。同时,也负责地址信息(手机号、网站地址)、文字信息(短讯文字、网站文字)、图片信息(彩信)的编译。The baseband processing module 410 can be used to synthesize the baseband signal to be transmitted, or to decode the received baseband signal. Specifically, when transmitting, the audio signal is compiled into a baseband code for transmission; when receiving, the received baseband code is decoded into an audio signal. At the same time, it is also responsible for the compilation of address information (mobile phone number, website address), text information (SMS text, website text), and picture information (MMS).

存储器420可用于存储软件程序以及模块,处理器480通过运行存储在存储器420的软件程序以及模块,从而执行手机的各种功能应用以及数据处理。存储器420可主要包括存储程序区和存储数据区,其中,存储程序区可存储操作系统、至少一个功能所需的应用程序(比如声音播放功能、图像播放功能等)等;存储数据区可存储根据手机的使用所创建的数据(比如音频数据、电话本等)等。此外,存储器420可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他易失性固态存储器件。The memory 420 can be used to store software programs and modules, and the processor 480 executes various functional applications and data processing of the mobile phone by running the software programs and modules stored in the memory 420 . The memory 420 may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program (such as a sound playback function, an image playback function, etc.) required for at least one function, and the like; Data created by the use of the mobile phone (such as audio data, phone book, etc.), etc. Additionally, memory 420 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device.

输入单元430可用于接收输入的数字或字符信息,以及产生与手机的用户设置以及功能控制有关的键信号输入。具体地,输入单元430可包括触控面板431以及其他输入设备432。触控面板431,也称为触摸屏,可收集用户在其上或附近的触摸操作(比如用户使用手指、触笔等任何适合的物体或附件在触控面板431上或在触控面板431附近的操作),并根据预先设定的程式驱动相应的连接装置。可选的,触控面板431可包括触摸检测装置和触摸控制器两个部分。其中,触摸检测装置检测用户的触摸方位,并检测触摸操作带来的信号,将信号传送给触摸控制器;触摸控制器从触摸检测装置上接收触摸信息,并将它转换成触点坐标,再送给处理器480,并能接收处理器480发来的命令并加以执行。此外,可以采用电阻式、电容式、红外线以及表面声波等多种类型实现触控面板431。除了触控面板431,输入单元430还可以包括其他输入设备432。具体地,其他输入设备432可以包括但不限于物理键盘、功能键(比如音量控制按键、开关按键等)、轨迹球、鼠标、操作杆等中的一种或多种。The input unit 430 may be used for receiving inputted numerical or character information, and generating key signal input related to user setting and function control of the mobile phone. Specifically, the input unit 430 may include a touch panel 431 and other input devices 432 . The touch panel 431, also referred to as a touch screen, can collect the user's touch operations on or near it (such as the user's finger, stylus, etc., any suitable object or accessory on or near the touch panel 431). operation), and drive the corresponding connection device according to the preset program. Optionally, the touch panel 431 may include two parts, a touch detection device and a touch controller. Among them, the touch detection device detects the user's touch orientation, detects the signal brought by the touch operation, and transmits the signal to the touch controller; the touch controller receives the touch information from the touch detection device, converts it into contact coordinates, and then sends it to the touch controller. To the processor 480, and can receive the command sent by the processor 480 and execute it. In addition, the touch panel 431 can be implemented in various types such as resistive, capacitive, infrared, and surface acoustic waves. Besides the touch panel 431 , the input unit 430 may also include other input devices 432 . Specifically, other input devices 432 may include, but are not limited to, one or more of physical keyboards, function keys (such as volume control keys, switch keys, etc.), trackballs, mice, joysticks, and the like.

显示单元440可用于显示由用户输入的信息或提供给用户的信息以及手机的各种菜单。显示单元440可包括显示面板441,可选的,可以采用液晶显示器(Liquid CrystalDisplay,LCD)、有机发光二极管(Organic Light-Emitting Diode,OLED)等形式来配置显示面板441。进一步的,触控面板431可覆盖显示面板441,当触控面板431检测到在其上或附近的触摸操作后,传送给处理器480以确定触摸事件的类型,随后处理器480根据触摸事件的类型在显示面板441上提供相应的视觉输出。虽然在图4中,触控面板431与显示面板441是作为两个独立的部件来实现手机的输入和输入功能,但是在某些实施例中,可以将触控面板431与显示面板441集成而实现手机的输入和输出功能。The display unit 440 may be used to display information input by the user or information provided to the user and various menus of the mobile phone. The display unit 440 may include a display panel 441, and optionally, the display panel 441 may be configured in the form of a liquid crystal display (Liquid Crystal Display, LCD), an organic light-emitting diode (Organic Light-Emitting Diode, OLED), or the like. Further, the touch panel 431 may cover the display panel 441. When the touch panel 431 detects a touch operation on or near it, it transmits it to the processor 480 to determine the type of the touch event, and then the processor 480 determines the type of the touch event according to the touch event. Type provides corresponding visual output on display panel 441 . Although in FIG. 4, the touch panel 431 and the display panel 441 are used as two independent components to realize the input and input functions of the mobile phone, in some embodiments, the touch panel 431 and the display panel 441 can be integrated to form Realize the input and output functions of the mobile phone.

手机还可包括至少一种传感器450,比如光传感器、运动传感器以及其他传感器。具体地,光传感器可包括环境光传感器及接近传感器,其中,环境光传感器可根据环境光线的明暗来调节显示面板441的亮度,接近传感器可在手机移动到耳边时,关闭显示面板441和/或背光。作为运动传感器的一种,加速计传感器可检测各个方向上(一般为三轴)加速度的大小,静止时可检测出重力的大小及方向,可用于识别手机姿态的应用(比如横竖屏切换、相关游戏、磁力计姿态校准)、振动识别相关功能(比如计步器、敲击)等;至于手机还可配置的陀螺仪、气压计、湿度计、温度计、红外线传感器等其他传感器,在此不再赘述。The cell phone may also include at least one sensor 450, such as a light sensor, a motion sensor, and other sensors. Specifically, the light sensor may include an ambient light sensor and a proximity sensor, wherein the ambient light sensor may adjust the brightness of the display panel 441 according to the brightness of the ambient light, and the proximity sensor may turn off the display panel 441 and/or when the mobile phone is moved to the ear. or backlight. As a kind of motion sensor, the accelerometer sensor can detect the magnitude of acceleration in all directions (usually three axes), and can detect the magnitude and direction of gravity when it is stationary. games, magnetometer attitude calibration), vibration recognition related functions (such as pedometer, tapping), etc.; as for other sensors such as gyroscope, barometer, hygrometer, thermometer, infrared sensor, etc. Repeat.

音频电路460、扬声器461,传声器462可提供用户与手机之间的音频接口。音频电路460可将接收到的音频数据转换后的电信号,传输到扬声器461,由扬声器461转换为声音信号输出;另一方面,传声器462将收集的声音信号转换为电信号,由音频电路460接收后转换为音频数据,再将音频数据输出处理器480处理后,经RF电路410以发送给比如另一手机,或者将音频数据输出至存储器420以便进一步处理。The audio circuit 460, the speaker 461, and the microphone 462 can provide an audio interface between the user and the mobile phone. The audio circuit 460 can convert the received audio data into an electrical signal, and transmit it to the speaker 461, and the speaker 461 converts it into a sound signal for output; on the other hand, the microphone 462 converts the collected sound signal into an electrical signal, which is converted by the audio circuit 460 After receiving, it is converted into audio data, and then the audio data is output to the processor 480 for processing, and then sent to, for example, another mobile phone through the RF circuit 410, or the audio data is output to the memory 420 for further processing.

WiFi属于短距离无线传输技术,手机通过WiFi模块470可以帮助用户收发电子邮件、浏览网页和访问流式媒体等,它为用户提供了无线的宽带互联网访问。虽然图4示出了WiFi模块470,但是可以理解的是,其并不属于手机的必须构成,完全可以根据需要在不改变发明的本质的范围内而省略。WiFi is a short-distance wireless transmission technology. The mobile phone can help users to send and receive emails, browse web pages, and access streaming media through the WiFi module 470. It provides users with wireless broadband Internet access. Although FIG. 4 shows the WiFi module 470, it can be understood that it is not a necessary component of the mobile phone, and can be completely omitted as required within the scope of not changing the essence of the invention.

处理器480是手机的控制中心,利用各种接口和线路连接整个手机的各个部分,通过运行或执行存储在存储器420内的软件程序和/或模块,以及调用存储在存储器420内的数据,执行手机的各种功能和处理数据,从而对手机进行整体监控。可选的,处理器480可包括一个或多个处理单元;优选的,处理器480可集成应用处理器和调制解调处理器,其中,应用处理器主要处理操作系统、用户界面和应用程序等,调制解调处理器主要处理无线通信。可以理解的是,上述调制解调处理器也可以不集成到处理器480中。The processor 480 is the control center of the mobile phone, using various interfaces and lines to connect various parts of the entire mobile phone, by running or executing the software programs and/or modules stored in the memory 420, and calling the data stored in the memory 420. Various functions of the mobile phone and processing data, so as to monitor the mobile phone as a whole. Optionally, the processor 480 may include one or more processing units; preferably, the processor 480 may integrate an application processor and a modem processor, wherein the application processor mainly processes the operating system, user interface, and application programs, etc. , the modem processor mainly deals with wireless communication. It can be understood that, the above-mentioned modulation and demodulation processor may not be integrated into the processor 480.

手机还包括给各个部件供电的电源490(比如电池),优选的,电源可以通过电源管理系统与处理器480逻辑相连,从而通过电源管理系统实现管理充电、放电、以及功耗管理等功能。The mobile phone also includes a power supply 490 (such as a battery) for supplying power to various components. Preferably, the power supply can be logically connected to the processor 480 through a power management system, so as to manage charging, discharging, and power consumption management functions through the power management system.

尽管未示出,手机还可以包括摄像头、蓝牙模块等,在此不再赘述。Although not shown, the mobile phone may also include a camera, a Bluetooth module, and the like, which will not be repeated here.

在本发明实施例中,该终端所包括的处理器480还具有以下功能:In this embodiment of the present invention, the processor 480 included in the terminal also has the following functions:

在监测到预设应用的消息事件时,判断当前系统是否处于以第二用户登录的安全模式,所述预设应用为运行于以第一用户登录的系统普通模式的应用程序;When monitoring a message event of a preset application, determine whether the current system is in a safe mode logged in with the second user, and the preset application is an application running in the normal mode of the system logged in with the first user;

若当前系统处于安全模式下,基于系统进程通信机制将所述消息事件传递给系统安全模式对应的服务进程,以通过所述服务进程在系统安全模式下输出响应所述消息事件后产生的通知消息。If the current system is in the safe mode, the message event is transmitted to the service process corresponding to the system safe mode based on the system process communication mechanism, so as to output the notification message generated in response to the message event through the service process in the system safe mode .

所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,上述描述的系统,装置和单元的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working process of the system, device and unit described above may refer to the corresponding process in the foregoing method embodiments, which will not be repeated here.

在本申请所提供的几个实施例中,应该理解到,所揭露的系统,装置和方法,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,所述单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性,机械或其它的形式。In the several embodiments provided in this application, it should be understood that the disclosed system, apparatus and method may be implemented in other manners. For example, the apparatus embodiments described above are only illustrative. For example, the division of the units is only a logical function division. In actual implementation, there may be other division methods. For example, multiple units or components may be combined or Can be integrated into another system, or some features can be ignored, or not implemented. On the other hand, the shown or discussed mutual coupling or direct coupling or communication connection may be through some interfaces, indirect coupling or communication connection of devices or units, and may be in electrical, mechanical or other forms.

所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。The units described as separate components may or may not be physically separated, and components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution in this embodiment.

另外,在本发明各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically alone, or two or more units may be integrated into one unit. The above-mentioned integrated units may be implemented in the form of hardware, or may be implemented in the form of software functional units.

本领域普通技术人员可以理解上述实施例的各种方法中的全部或部分步骤是可以通过程序来指令相关的硬件来完成,该程序可以存储于一计算机可读存储介质中,存储介质可以包括:只读存储器(ROM,Read Only Memory)、随机存取存储器(RAM,RandomAccess Memory)、磁盘或光盘等。Those of ordinary skill in the art can understand that all or part of the steps in the various methods of the above embodiments can be completed by instructing relevant hardware through a program, and the program can be stored in a computer-readable storage medium, and the storage medium can include: Read Only Memory (ROM, Read Only Memory), Random Access Memory (RAM, Random Access Memory), magnetic disk or optical disk, etc.

本领域普通技术人员可以理解实现上述实施例方法中的全部或部分步骤是可以通过程序来指令相关的硬件完成,所述的程序可以存储于一种计算机可读存储介质中,上述提到的存储介质可以是只读存储器,磁盘或光盘等。Those of ordinary skill in the art can understand that all or part of the steps in the method of the above-mentioned embodiments can be completed by instructing the relevant hardware through a program, and the program can be stored in a computer-readable storage medium. The medium can be read-only memory, magnetic disk or optical disk, etc.

概括地说,本发明提供的技术方案如下:Generally speaking, the technical scheme provided by the present invention is as follows:

A1、一种应用消息事件控制方法,包括如下步骤:A1. An application message event control method, comprising the following steps:

在监测到预设应用的消息事件时,判断当前系统是否处于以第二用户登录的安全模式,所述预设应用为运行于以第一用户登录的系统普通模式的应用程序;When monitoring a message event of a preset application, determine whether the current system is in a safe mode logged in with the second user, and the preset application is an application running in the normal mode of the system logged in with the first user;

若当前系统处于安全模式下,基于系统进程通信机制将所述消息事件传递给系统安全模式对应的服务进程,以通过所述服务进程在系统安全模式下输出响应所述消息事件后产生的通知消息。If the current system is in the safe mode, the message event is transmitted to the service process corresponding to the system safe mode based on the system process communication mechanism, so as to output the notification message generated in response to the message event through the service process in the system safe mode .

A2、根据A1所述的方法,所述服务进程为安卓系统的通知管理服务进程,所述消息事件为通知事件,相应的,所述通知消息为系统通知栏消息,所述通知管理服务进程受所述通知事件驱动而在系统通知栏输出相应的通知栏消息。A2. The method according to A1, wherein the service process is a notification management service process of the Android system, the message event is a notification event, and correspondingly, the notification message is a system notification bar message, and the notification management service process is subject to The notification event is driven to output the corresponding notification bar message in the system notification bar.

A3、根据A2所述的方法,通过安卓系统通知管理服务进程固有的监听器监测预设应用的通知事件。A3. According to the method described in A2, the notification event of the preset application is monitored through a listener inherent in the Android system notification management service process.

A4、根据A1所述的方法,所述服务进程为安卓系统的闹钟管理服务进程,所述消息事件为闹钟事件,相应的,所述通知消息为与闹钟相关的通知消息,所述闹钟管理服务进程受所述闹钟事件驱动输出相应的闹钟消息。A4. The method according to A1, wherein the service process is an alarm clock management service process of the Android system, the message event is an alarm clock event, and correspondingly, the notification message is a notification message related to an alarm clock, and the alarm clock management service The process is driven by the alarm event to output a corresponding alarm message.

A5、根据A4所述的方法,通过注册广播监听器监测预设应用的闹钟事件。A5. According to the method described in A4, an alarm clock event of a preset application is monitored by registering a broadcast listener.

A6、根据A2或A4所述的方法,所述输出响应所述消息事件后产生的通知消息,还包括指示灯显示、铃声播放、震动反馈的一种或多种。A6. The method according to A2 or A4, wherein the outputting a notification message generated in response to the message event further includes one or more of indicator light display, ringtone playing, and vibration feedback.

A7、根据A1所述的方法,所述服务进程在系统安全模式下输出响应所述消息事件后产生的通知消息与在系统普通模式下输出响应所述消息事件后产生的通知消息一致。A7. The method according to A1, wherein the service process outputs the notification message generated in response to the message event in the system safe mode is consistent with the notification message generated in response to the message event in the system normal mode.

A8、根据A1所述的方法,当在系统安全模式下输出响应所述消息事件后产生的通知消息时,所述通知消息对应的预设应用所配置的图标与在系统普通模式下的预设应用的初始图标不同。A8. According to the method of A1, when the notification message generated after responding to the message event is output in the system safe mode, the icon configured by the preset application corresponding to the notification message is the same as the preset icon in the system normal mode. The initial icon of the app is different.

A9、根据A2所述的方法,还包括步骤:A9. The method according to A2, further comprising the steps of:

响应作用于系统安全模式下的通知栏消息的控制指令,将系统从安全模式切换到普通模式,并打开所述消息事件相对应的预设应用。In response to the control instruction acting on the notification bar message in the system safe mode, the system is switched from the safe mode to the normal mode, and the preset application corresponding to the message event is opened.

A10、根据A9所述的方法,所述将系统从安全模式切换到普通模式,具体还包括:A10. The method according to A9, wherein the switching of the system from the safe mode to the normal mode further includes:

将系统从第二用户登录状态切换至第一用户登录状态。Switch the system from the second user login state to the first user login state.

A11、根据A10所述的方法,通过调用安卓系统的ActivityManager类中的switchUser()方法将系统从第二用户登录状态切换至第一用户登录状态。A11. According to the method described in A10, the system is switched from the second user login state to the first user login state by calling the switchUser() method in the ActivityManager class of the Android system.

B12、一种应用消息事件控制装置,包括:B12. An application message event control device, comprising:

监测模块:用于在监测到预设应用的消息事件时,判断当前系统是否处于以第二用户登录的安全模式,所述预设应用为运行于以第一用户登录的系统普通模式的应用程序;Monitoring module: used to judge whether the current system is in the safe mode of logging in with the second user when the message event of the preset application is monitored, and the preset application is an application running in the normal mode of the system logged in with the first user ;

传递模块:用于若当前系统处于安全模式下,基于系统进程通信机制将所述消息事件传递给系统安全模式对应的服务进程,以通过所述服务进程在系统安全模式下输出响应所述消息事件后产生的通知消息。Delivery module: used to transmit the message event to the service process corresponding to the system security mode based on the system process communication mechanism if the current system is in the security mode, so as to output the response to the message event in the system security mode through the service process The notification message generated later.

B13、根据B12所述的装置,所述服务进程为安卓系统的通知管理服务进程,所述消息事件为通知事件,相应的,所述通知消息为系统通知栏消息,所述通知管理服务进程受所述通知事件驱动而在系统通知栏输出相应的通知栏消息。B13. The device according to B12, wherein the service process is a notification management service process of an Android system, the message event is a notification event, and correspondingly, the notification message is a system notification bar message, and the notification management service process is subject to The notification event is driven to output the corresponding notification bar message in the system notification bar.

B14、根据B13所述的装置,通过安卓系统通知管理服务进程固有的监听器监测预设应用的通知事件。B14. According to the device of B13, the notification event of the preset application is monitored by a listener inherent in the Android system notification management service process.

B15、根据B12所述的装置,所述服务进程为安卓系统的闹钟管理服务进程,所述消息事件为闹钟事件,相应的,所述通知消息为与闹钟相关的通知消息,所述闹钟管理服务进程受所述闹钟事件驱动输出相应的闹钟消息。B15. The device according to B12, wherein the service process is an alarm clock management service process of the Android system, the message event is an alarm clock event, and correspondingly, the notification message is a notification message related to an alarm clock, and the alarm clock management service The process is driven by the alarm event to output a corresponding alarm message.

B16、根据B15所述的装置,通过注册广播监听器监测预设应用的闹钟事件。B16. According to the device of B15, the alarm clock event of the preset application is monitored by registering a broadcast listener.

B17、根据B13或B15所述的装置,所述输出响应所述消息事件后产生的通知消息,还包括指示灯显示、铃声播放、震动反馈的一种或多种。B17. The device according to B13 or B15, wherein the outputting a notification message generated in response to the message event further includes one or more of indicator light display, ringtone playing, and vibration feedback.

B18、根据B12所述的装置,所述服务进程在系统安全模式下输出响应所述消息事件后产生的通知消息与在系统普通模式下输出响应所述消息事件后产生的通知消息一致。B18. The apparatus according to B12, wherein the service process outputs the notification message generated after responding to the message event in the system safe mode is consistent with the notification message generated after outputting the message event in the system normal mode.

B19、根据B12所述的装置,当在系统安全模式下输出响应所述消息事件后产生的通知消息时,所述通知消息对应的预设应用所配置的图标与在系统普通模式下的预设应用的初始图标不同。B19. The device according to B12, when the notification message generated after responding to the message event is output in the system safe mode, the icon configured by the preset application corresponding to the notification message is the same as the preset icon in the system normal mode The initial icon of the app is different.

B20、根据B12所述的装置,还包括:B20. The device according to B12, further comprising:

切换模块:用于响应作用于系统安全模式下的通知栏消息的控制指令,将系统从安全模式切换到普通模式,并打开所述消息事件相对应的预设应用。Switching module: In response to the control instruction acting on the notification bar message in the system safe mode, the system is switched from the safe mode to the normal mode, and the preset application corresponding to the message event is opened.

B21、根据B20所述的装置,所述切换模块还包括:B21. The device according to B20, wherein the switching module further comprises:

用户切换单元:用于将系统从第二用户登录状态切换至第一用户登录状态。User switching unit: used to switch the system from the second user login state to the first user login state.

B22、根据B21所述的装置,所述切换单元通过调用安卓系统的ActivityManager类中的switchUser()方法将系统从第二用户登录状态切换至第一用户登录状态。B22. The device according to B21, wherein the switching unit switches the system from the second user login state to the first user login state by calling the switchUser() method in the ActivityManager class of the Android system.

C23、一种移动终端,其特征在于,包括:C23. A mobile terminal, characterized in that it includes:

触敏显示器;touch sensitive display;

存储器;memory;

一个或多个处理器;one or more processors;

所述一个或多个处理器被配置为用于执行如A1~A11所述任意一项所述方法的步骤。The one or more processors are configured to perform the steps of the method as described in any one of A1-A11.

综上所述,本发明通过监测预设应用的消息事件,将系统普通模式下的预设应用的消息事件同步到系统安全模式下,让用户在系统安全模式下仍然能第一时间接收到普通模式下的预设应用发出的消息事件对应的通知消息;同时,所述预设应用为用户常用的具有时间类提醒的应用和通讯类应用,对于该类应用的消息的及时通知,可以增强用户体验,提高用户使用安全模式的兴趣,提高安全模式的使用率,进而保障用户终端的系统安全。To sum up, the present invention synchronizes the message events of the preset applications in the system normal mode to the system security mode by monitoring the message events of the preset applications, so that the user can still receive the ordinary messages in the system security mode for the first time. The notification message corresponding to the message event sent by the preset application in the mode; at the same time, the preset application is an application with a time type reminder and a communication type application commonly used by users, and the timely notification of messages of this type of application can enhance the user Experience, improve the user's interest in using the security mode, improve the utilization rate of the security mode, and then ensure the system security of the user terminal.

虽然上面已经示出了本发明的一些示例性实施例,但是本领域的技术人员将理解,在不脱离本发明的原理或精神的情况下,可以对这些示例性实施例做出改变,本发明的范围由权利要求及其等同物限定。Although some exemplary embodiments of the present invention have been shown above, those skilled in the art will appreciate that The scope is defined by the claims and their equivalents.

Claims (23)

1. An application message event control method is characterized by comprising the following steps:
when a message event of a preset application is monitored, judging whether the current system is in a safe mode for logging in by a second user or not, wherein the preset application is an application program running in a system common mode for logging in by a first user; the system is an android system, and the message event is a global message event of the system; the system security mode provides a security space for running resources for running of the application with higher security requirement, the security space is inaccessible in the system common mode, and meanwhile the application with higher security requirement is installed in a storage directory of a corresponding second user in the security mode;
if the current system is in the safety mode, the message event of the preset application in the common mode is transmitted to the service process in the safety mode through the Binder based on a Binder communication mechanism, so that the notification message generated after responding to the message event is output in the system safety mode through the service process.
2. The method according to claim 1, wherein the service process is a notification management service process of the android system, the message event is a notification event, and correspondingly, the notification message is a system notification bar message, and the notification management service process is driven by the notification event to output a corresponding notification bar message in a system notification bar.
3. The method according to claim 2, characterized in that the notification event of the pre-set application is monitored by a listener intrinsic to the android system notification service process.
4. The method according to claim 1, wherein the service process is an alarm clock management service process of an android system, the message event is an alarm clock event, correspondingly, the notification message is a notification message related to an alarm clock, and the alarm clock management service process is driven by the alarm clock event to output the corresponding alarm clock message.
5. The method of claim 4, wherein the alarm events of the predetermined application are monitored by registering a broadcast listener.
6. The method of claim 2 or 4, wherein the outputting of the notification message generated in response to the message event further comprises one or more of an indicator light display, a ring tone play, and a vibration feedback.
7. The method of claim 1, wherein the service process outputs the notification message generated in response to the message event in the system security mode in accordance with the notification message generated in response to the message event in the system normal mode.
8. The method according to claim 1, wherein when the notification message generated in response to the message event is output in the system security mode, the preset application corresponding to the notification message is configured with a different icon from an initial icon of the preset application in the system normal mode.
9. The method of claim 2, further comprising the step of:
and responding to a control instruction of the notification bar message acting in the system security mode, switching the system from the security mode to the common mode, and opening a preset application corresponding to the message event.
10. The method according to claim 9, wherein switching the system from the secure mode to the normal mode further comprises:
and switching the system from the second user login state to the first user login state.
11. The method of claim 10, wherein the system is switched from the second user login state to the first user login state by invoking a switchUser () method in the ActivityManager class of the android system.
12. An application message event control apparatus, comprising:
a monitoring module: the system comprises a first user, a second user, a first application and a second application, wherein the first user is a first user login security mode, the second user login security mode is a second user login security mode, and the first user login security mode is a second user login security mode; the system is an android system, and the message event is a global message event of the system; the system security mode provides a security space for running resources for running of the application with higher security requirement, the security space is inaccessible in the system common mode, and meanwhile the application with higher security requirement is installed in a storage directory of a corresponding second user in the security mode;
a transfer module: and if the current system is in the security mode, transmitting the message event of the preset application in the common mode to the service process in the security mode through a Binder based on a Binder communication mechanism, and outputting a notification message generated after responding to the message event in the system security mode through the service process.
13. The apparatus according to claim 12, wherein the service process is a notification management service process of the android system, the message event is a notification event, and accordingly, the notification message is a system notification bar message, and the notification management service process is driven by the notification event to output a corresponding notification bar message in a system notification bar.
14. The apparatus according to claim 13, wherein a listener native to the management service process is notified via the android system to monitor for notification events of the pre-defined application.
15. The apparatus of claim 12, wherein the service process is an alarm clock management service process of an android system, the message event is an alarm clock event, and correspondingly, the notification message is a notification message related to an alarm clock, and the alarm clock management service process is driven by the alarm clock event to output the corresponding alarm clock message.
16. The apparatus of claim 15, wherein the alarm events of the predetermined application are monitored by registering a broadcast listener.
17. The apparatus of claim 13 or 15, wherein the output is a notification message generated in response to the message event, and further comprises one or more of an indicator light display, a ring tone playing, and a vibration feedback.
18. The apparatus of claim 12, wherein the notification message generated after the service process outputs the response to the message event in the system security mode is identical to the notification message generated after the service process outputs the response to the message event in the system normal mode.
19. The apparatus of claim 12, wherein when the notification message generated in response to the message event is output in the system security mode, an icon configured by a preset application corresponding to the notification message is different from an initial icon of the preset application in the system normal mode.
20. The apparatus of claim 12, further comprising:
a switching module: and the control instruction is used for responding to the notification bar message under the system security mode, switching the system from the security mode to the common mode, and opening the preset application corresponding to the message event.
21. The apparatus of claim 20, wherein the switching module further comprises:
a user switching unit: for switching the system from the second user login state to the first user login state.
22. The apparatus of claim 21, wherein the switching unit switches the system from the second user login state to the first user login state by invoking a switchUser () method in an ActivityManager class of the android system.
23. A mobile terminal, comprising:
a touch-sensitive display;
a memory;
one or more processors;
the one or more processors are configured to perform the steps of the method of any one of claims 1 to 11.
CN201710025485.3A 2017-01-13 2017-01-13 Application message event control method and device and mobile terminal Expired - Fee Related CN106844064B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710025485.3A CN106844064B (en) 2017-01-13 2017-01-13 Application message event control method and device and mobile terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710025485.3A CN106844064B (en) 2017-01-13 2017-01-13 Application message event control method and device and mobile terminal

Publications (2)

Publication Number Publication Date
CN106844064A CN106844064A (en) 2017-06-13
CN106844064B true CN106844064B (en) 2020-09-08

Family

ID=59124511

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710025485.3A Expired - Fee Related CN106844064B (en) 2017-01-13 2017-01-13 Application message event control method and device and mobile terminal

Country Status (1)

Country Link
CN (1) CN106844064B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1711524A (en) * 2002-11-18 2005-12-21 Arm有限公司 Switching between secure and non-secure processing modes
CN101950245A (en) * 2010-09-29 2011-01-19 宇龙计算机通信科技(深圳)有限公司 Information display method and system for mobile terminal and mobile terminal
CN103532938A (en) * 2013-09-29 2014-01-22 东莞宇龙通信科技有限公司 Application data protection method and system
CN106201223A (en) * 2016-08-15 2016-12-07 宇龙计算机通信科技(深圳)有限公司 A kind of notification message display packing and device

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1711524A (en) * 2002-11-18 2005-12-21 Arm有限公司 Switching between secure and non-secure processing modes
CN101950245A (en) * 2010-09-29 2011-01-19 宇龙计算机通信科技(深圳)有限公司 Information display method and system for mobile terminal and mobile terminal
CN103532938A (en) * 2013-09-29 2014-01-22 东莞宇龙通信科技有限公司 Application data protection method and system
CN106201223A (en) * 2016-08-15 2016-12-07 宇龙计算机通信科技(深圳)有限公司 A kind of notification message display packing and device

Also Published As

Publication number Publication date
CN106844064A (en) 2017-06-13

Similar Documents

Publication Publication Date Title
CN107203630B (en) Application page collection method, device and corresponding mobile terminal
CN110752980B (en) Message sending method and electronic equipment
US12147661B2 (en) Content sharing method and electronic device
CN107085617B (en) Application page collection method and device and corresponding mobile terminal
CN110837327B (en) A message viewing method and terminal
CN115454286B (en) Application data processing method and device and terminal equipment
WO2018223558A1 (en) Data processing method and electronic device
CN106874037A (en) application program installation method, device and mobile terminal
CN109995933B (en) Method for controlling alarm clock of terminal device and terminal device
CN111427648A (en) Page resource updating method, device, electronic device, server and storage medium
CN106201484A (en) The collocation method of application program, device and terminal unit
CN112148499A (en) Data reporting method, device, computer equipment and medium
CN106168901A (en) Application program font customizing method and control method and related device
WO2015003636A1 (en) Method and device for interception of page elements
CN106156097B (en) Method and device for processing browser input records
CN109491670A (en) A kind of page display method and terminal device
CN109951373A (en) A file sending method and terminal device
CN108804151A (en) A kind of method and terminal of re-launching applications
CN108762799A (en) A kind of method and terminal of update application
US11455139B2 (en) Electronic device and method for independently controlling a plurality of displays
CN106528284A (en) Application configuration method and apparatus, and terminal device
CN106203015A (en) The collocation method of application program, device and terminal unit
CN108366106B (en) Communication information updating method, management method, modification method and related equipment
CN109857300A (en) Multimedia service providing method and device
CN110032416A (en) A kind of terminal remote control method and terminal

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
TA01 Transfer of patent application right
TA01 Transfer of patent application right

Effective date of registration: 20170724

Address after: 100102, 18 floor, building 2, Wangjing street, Beijing, Chaoyang District, 1801

Applicant after: BEIJING ANYUNSHIJI TECHNOLOGY Co.,Ltd.

Address before: 100088 Beijing city Xicheng District xinjiekouwai Street 28, block D room 112 (Desheng Park)

Applicant before: BEIJING QIHOO TECHNOLOGY Co.,Ltd.

GR01 Patent grant
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20200908