diff options
Diffstat (limited to 'src/components/application_manager/include/application_manager/commands/mobile/register_app_interface_request.h')
-rw-r--r-- | src/components/application_manager/include/application_manager/commands/mobile/register_app_interface_request.h | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/src/components/application_manager/include/application_manager/commands/mobile/register_app_interface_request.h b/src/components/application_manager/include/application_manager/commands/mobile/register_app_interface_request.h index cc3d5b685c..369fd68868 100644 --- a/src/components/application_manager/include/application_manager/commands/mobile/register_app_interface_request.h +++ b/src/components/application_manager/include/application_manager/commands/mobile/register_app_interface_request.h @@ -77,15 +77,17 @@ class RegisterAppInterfaceRequest : public CommandRequestImpl { **/ virtual void Run(); + private: + enum class AppicationType { kNewApplication, kSwitchedApplication }; + /** * @brief Sends RegisterAppInterface response to mobile * *@param application_impl application * **/ - void SendRegisterAppInterfaceResponseToMobile(); + void SendRegisterAppInterfaceResponseToMobile(AppicationType app_type); - private: smart_objects::SmartObjectSPtr GetLockScreenIconUrlNotification( const uint32_t connection_key, ApplicationSharedPtr app); @@ -184,6 +186,15 @@ class RegisterAppInterfaceRequest : public CommandRequestImpl { */ void SendSubscribeCustomButtonNotification(); + /** + * @brief IsApplicationSwitched checks whether application is switched from + * another transport. If application id is found, but not in reconnection + * list, returns 'already registered' code. Otherwise - proceed with + * switching. + * @return True if application is detected as switched, otherwise false. + */ + bool IsApplicationSwitched(); + private: std::string response_info_; mobile_apis::Result::eType result_checking_app_hmi_type_; |