summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAGaliuzov <AGaliuzov@luxoft.com>2016-04-04 23:37:13 +0300
committerAGaliuzov <AGaliuzov@luxoft.com>2016-04-04 23:37:13 +0300
commit323de9a2c953c67de4a89ff434adbc68e5ba9e34 (patch)
tree8dd126d3923aa57ebcccb46e68d49109a5b8f03b
parent5015ddc52bb959a78049a35a1917f3afc5d380fa (diff)
parent73b6b7e37d11c1a92353fb66e88451f12be12827 (diff)
downloadsdl_core-323de9a2c953c67de4a89ff434adbc68e5ba9e34.tar.gz
Merge pull request #449 from okoreniak/hotfix/Fixed_SDL_do_not_send_two_OnHMIStatus_notifications_to_LAUNCHED_App
Fixed SDL to do not send two OnHMIStatus notification to launched app…
-rw-r--r--src/components/application_manager/src/commands/mobile/register_app_interface_request.cc21
1 files changed, 13 insertions, 8 deletions
diff --git a/src/components/application_manager/src/commands/mobile/register_app_interface_request.cc b/src/components/application_manager/src/commands/mobile/register_app_interface_request.cc
index 36b2c27f7f..a3fe1422cf 100644
--- a/src/components/application_manager/src/commands/mobile/register_app_interface_request.cc
+++ b/src/components/application_manager/src/commands/mobile/register_app_interface_request.cc
@@ -513,14 +513,19 @@ void RegisterAppInterfaceRequest::SendRegisterAppInterfaceResponseToMobile(
SendResponse(true, result, add_info.c_str(), &response_params);
- // Default HMI level should be set before any permissions validation, since it
- // relies on HMI level.
- resumer.SetupDefaultHMILevel(application);
-
- if (result != mobile_apis::Result::RESUME_FAILED) {
- resumer.StartResumption(application, hash_id);
- } else {
- resumer.StartResumptionOnlyHMILevel(application);
+ // when application's hmilevel is not defined, we should set
+ // default and try to perform resumption
+ // fix for APPLINK-12311
+ if (mobile_apis::HMILevel::INVALID_ENUM == application->CurrentHmiState()->hmi_level()) {
+ // Default HMI level should be set before any permissions validation, since it
+ // relies on HMI level.
+ resumer.SetupDefaultHMILevel(application);
+
+ if (result != mobile_apis::Result::RESUME_FAILED) {
+ resumer.StartResumption(application, hash_id);
+ } else {
+ resumer.StartResumptionOnlyHMILevel(application);
+ }
}
// By default app subscribed to CUSTOM_BUTTON