diff options
author | dtrunov <dtrunov@luxoft.com> | 2016-10-04 17:44:06 +0300 |
---|---|---|
committer | dtrunov <dtrunov@luxoft.com> | 2016-10-04 17:44:06 +0300 |
commit | 333644a3993bede76609a306757d689164bd24b2 (patch) | |
tree | 5987892cca290ffe4b1e7a0556d4b140db9c99f7 /src/components/application_manager/src/commands/hmi | |
parent | a2cb12e9de3eb64e590f650d2c45aee82cdfe349 (diff) | |
download | sdl_core-333644a3993bede76609a306757d689164bd24b2.tar.gz |
Fix comments after review
Add constructor to structure, and reorder parameter in method
Related issue [APPLINK-25088](https://adc.luxoft.com/jira/browse/APPLINK-25088)
Diffstat (limited to 'src/components/application_manager/src/commands/hmi')
-rw-r--r-- | src/components/application_manager/src/commands/hmi/request_to_hmi.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/components/application_manager/src/commands/hmi/request_to_hmi.cc b/src/components/application_manager/src/commands/hmi/request_to_hmi.cc index 6364cc2fc8..39d549ac72 100644 --- a/src/components/application_manager/src/commands/hmi/request_to_hmi.cc +++ b/src/components/application_manager/src/commands/hmi/request_to_hmi.cc @@ -46,17 +46,17 @@ bool CheckAvailabilityHMIInterfaces(ApplicationManager& application_manager, bool ChangeInterfaceState(ApplicationManager& application_manager, const smart_objects::SmartObject& response_from_hmi, HmiInterfaces::InterfaceID interface) { - bool is_available = false; if (response_from_hmi[strings::msg_params].keyExists(strings::available)) { - is_available = + const bool is_available = response_from_hmi[strings::msg_params][strings::available].asBool(); const HmiInterfaces::InterfaceState interface_state = is_available ? HmiInterfaces::STATE_AVAILABLE : HmiInterfaces::STATE_NOT_AVAILABLE; application_manager.hmi_interfaces().SetInterfaceState(interface, interface_state); + return is_available; } - return is_available; + return false; } RequestToHMI::RequestToHMI(const MessageSharedPtr& message, |