summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHrytsevich Anton <ahrytsevich@luxoft.com>2016-10-06 14:03:12 +0300
committerHrytsevich Anton <ahrytsevich@luxoft.com>2016-10-06 14:03:12 +0300
commit9412e70e428e8e93c1926acf974abba3b2b0fc67 (patch)
treee6de15ed08cde0e49cfaa6dfa52cfccb1a976b1d
parent353f0970420eff51d20886d43f4d18888dc3707c (diff)
downloadsdl_core-9412e70e428e8e93c1926acf974abba3b2b0fc67.tar.gz
Delete useless return and fix grammatical mistake
-rw-r--r--src/components/application_manager/include/application_manager/commands/mobile/perform_interaction_request.h6
-rw-r--r--src/components/application_manager/src/commands/mobile/perform_interaction_request.cc21
2 files changed, 12 insertions, 15 deletions
diff --git a/src/components/application_manager/include/application_manager/commands/mobile/perform_interaction_request.h b/src/components/application_manager/include/application_manager/commands/mobile/perform_interaction_request.h
index 4cf40959b4..7990038014 100644
--- a/src/components/application_manager/include/application_manager/commands/mobile/perform_interaction_request.h
+++ b/src/components/application_manager/include/application_manager/commands/mobile/perform_interaction_request.h
@@ -104,7 +104,7 @@ class PerformInteractionRequest : public CommandRequestImpl {
* @return true if send response to mobile application otherwise
* return false.
*/
- bool ProcessUIResponse(const smart_objects::SmartObject& message,
+ void ProcessUIResponse(const smart_objects::SmartObject& message,
smart_objects::SmartObject& msg_params);
/*
@@ -224,8 +224,8 @@ class PerformInteractionRequest : public CommandRequestImpl {
void SendBothModeResponse(const smart_objects::SmartObject& msg_param);
mobile_apis::InteractionMode::eType interaction_mode_;
- bool ui_response_recived_;
- bool vr_response_recived_;
+ bool ui_response_received_;
+ bool vr_response_received_;
bool app_pi_was_active_before_;
static uint32_t pi_requests_count_;
hmi_apis::Common_Result::eType vr_result_code_;
diff --git a/src/components/application_manager/src/commands/mobile/perform_interaction_request.cc b/src/components/application_manager/src/commands/mobile/perform_interaction_request.cc
index 3fd6cf4579..af94e877a8 100644
--- a/src/components/application_manager/src/commands/mobile/perform_interaction_request.cc
+++ b/src/components/application_manager/src/commands/mobile/perform_interaction_request.cc
@@ -57,8 +57,8 @@ PerformInteractionRequest::PerformInteractionRequest(
const MessageSharedPtr& message, ApplicationManager& application_manager)
: CommandRequestImpl(message, application_manager)
, interaction_mode_(mobile_apis::InteractionMode::INVALID_ENUM)
- , ui_response_recived_(false)
- , vr_response_recived_(false)
+ , ui_response_received_(false)
+ , vr_response_received_(false)
, app_pi_was_active_before_(false)
, vr_result_code_(hmi_apis::Common_Result::INVALID_ENUM)
, ui_result_code_(hmi_apis::Common_Result::INVALID_ENUM) {
@@ -226,20 +226,18 @@ void PerformInteractionRequest::on_event(const event_engine::Event& event) {
}
case hmi_apis::FunctionID::UI_PerformInteraction: {
LOG4CXX_DEBUG(logger_, "Received UI_PerformInteraction event");
- ui_response_recived_ = true;
+ ui_response_received_ = true;
unsubscribe_from_event(hmi_apis::FunctionID::UI_PerformInteraction);
ui_result_code_ = static_cast<hmi_apis::Common_Result::eType>(
message[strings::params][hmi_response::code].asUInt());
GetInfo(
HmiInterfaces::HMI_INTERFACE_UI, ui_result_code_, message, ui_info_);
- if (ProcessUIResponse(event.smart_object(), msg_param)) {
- return;
- }
+ ProcessUIResponse(event.smart_object(), msg_param);
break;
}
case hmi_apis::FunctionID::VR_PerformInteraction: {
LOG4CXX_DEBUG(logger_, "Received VR_PerformInteraction");
- vr_response_recived_ = true;
+ vr_response_received_ = true;
unsubscribe_from_event(hmi_apis::FunctionID::VR_PerformInteraction);
vr_result_code_ = static_cast<hmi_apis::Common_Result::eType>(
message[strings::params][hmi_response::code].asUInt());
@@ -268,7 +266,7 @@ void PerformInteractionRequest::onTimeOut() {
switch (interaction_mode_) {
case mobile_apis::InteractionMode::BOTH: {
LOG4CXX_DEBUG(logger_, "Interaction Mode: BOTH");
- if (true == vr_response_recived_) {
+ if (true == vr_response_received_) {
unsubscribe_from_event(hmi_apis::FunctionID::UI_PerformInteraction);
DisablePerformInteraction();
CommandRequestImpl::onTimeOut();
@@ -359,7 +357,7 @@ bool PerformInteractionRequest::ProcessVRResponse(
return false;
}
-bool PerformInteractionRequest::ProcessUIResponse(
+void PerformInteractionRequest::ProcessUIResponse(
const smart_objects::SmartObject& message,
smart_objects::SmartObject& msg_params) {
LOG4CXX_AUTO_TRACE(logger_);
@@ -369,7 +367,7 @@ bool PerformInteractionRequest::ProcessUIResponse(
ApplicationSharedPtr app = application_manager_.application(connection_key());
if (!app) {
LOG4CXX_ERROR(logger_, "NULL pointer");
- return false;
+ return;
}
HmiInterfaces::InterfaceState ui_interface_state =
@@ -424,7 +422,6 @@ bool PerformInteractionRequest::ProcessUIResponse(
}
}
}
- return false;
}
void PerformInteractionRequest::SendUIPerformInteractionRequest(
@@ -922,7 +919,7 @@ bool PerformInteractionRequest::CheckChoiceIDFromRequest(
const bool PerformInteractionRequest::HasHMIResponsesToWait() const {
LOG4CXX_AUTO_TRACE(logger_);
- return !ui_response_recived_ || !vr_response_recived_;
+ return !ui_response_received_ || !vr_response_received_;
}
void PerformInteractionRequest::SendBothModeResponse(