summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIra Lytvynenko (GitHub) <ILytvynenko@luxoft.com>2018-05-31 17:50:05 +0300
committerAlexander <akutsan@luxoft.com>2018-08-16 16:16:59 +0300
commitd13628920cb48507ad98a7e0ef2494f0034b0542 (patch)
tree9a7af5b656c9b9c05a342bd70960ef7c5e3b8274
parenta93f82e48bfd8eb210db25afe02b290144c02577 (diff)
downloadsdl_core-d13628920cb48507ad98a7e0ef2494f0034b0542.tar.gz
Check for projection app
-rw-r--r--src/components/application_manager/rpc_plugins/rc_rpc_plugin/src/commands/mobile/set_interior_vehicle_data_request.cc15
1 files changed, 10 insertions, 5 deletions
diff --git a/src/components/application_manager/rpc_plugins/rc_rpc_plugin/src/commands/mobile/set_interior_vehicle_data_request.cc b/src/components/application_manager/rpc_plugins/rc_rpc_plugin/src/commands/mobile/set_interior_vehicle_data_request.cc
index 020605b64f..8745f5a0b5 100644
--- a/src/components/application_manager/rpc_plugins/rc_rpc_plugin/src/commands/mobile/set_interior_vehicle_data_request.cc
+++ b/src/components/application_manager/rpc_plugins/rc_rpc_plugin/src/commands/mobile/set_interior_vehicle_data_request.cc
@@ -232,9 +232,9 @@ bool CheckControlDataByCapabilities(
auto light_data = control_data[request_parameter].asArray()->begin();
for (; light_data != control_data[request_parameter].asArray()->end();
++light_data) {
- if(!CheckLightNameByCapabilities(
- module_caps[strings::kSupportedLights], *light_data)){
- return false;
+ if (!CheckLightNameByCapabilities(
+ module_caps[strings::kSupportedLights], *light_data)) {
+ return false;
}
}
return true;
@@ -469,8 +469,13 @@ void SetInteriorVehicleDataRequest::CheckAudioSource(
application_manager_.get_current_audio_source()) {
app_mngr::ApplicationSharedPtr app =
application_manager_.application(connection_key());
- application_manager_.ChangeAppsHMILevel(
- app->app_id(), mobile_apis::HMILevel::eType::HMI_BACKGROUND);
+ if (app->mobile_projection_enabled()) {
+ application_manager_.ChangeAppsHMILevel(
+ app->app_id(), mobile_apis::HMILevel::eType::HMI_LIMITED);
+ } else {
+ application_manager_.ChangeAppsHMILevel(
+ app->app_id(), mobile_apis::HMILevel::eType::HMI_BACKGROUND);
+ }
}
}
}