summaryrefslogtreecommitdiff
path: root/src/components/HMI
diff options
context:
space:
mode:
authorJustin Dickow <jjdickow@gmail.com>2015-01-26 11:15:48 -0500
committerJustin Dickow <jjdickow@gmail.com>2015-01-26 11:15:48 -0500
commit46ed776c537131e72747538488b213cf45f23e22 (patch)
tree4cad1abf411addfd72ab591c93edeb5d225d9a39 /src/components/HMI
parenta24079cb8de5563376dcf782cdb9fe3cae063841 (diff)
downloadsdl_core-46ed776c537131e72747538488b213cf45f23e22.tar.gz
Latest internal release - last bulk merge before pull request and gitflow!?
Smoke tested on Ubuntu 12.04 Signed-off-by: Justin Dickow <jjdickow@gmail.com>
Diffstat (limited to 'src/components/HMI')
-rw-r--r--src/components/HMI/app/AppViews.js11
-rw-r--r--src/components/HMI/app/SDLApp.js4
-rw-r--r--src/components/HMI/app/controller/sdl/AppController.js6
-rw-r--r--src/components/HMI/app/controller/sdl/Controller.js31
-rw-r--r--src/components/HMI/app/controller/sdl/RPCController.js108
-rw-r--r--src/components/HMI/app/model/media/CDModel.js2
-rw-r--r--src/components/HMI/app/model/sdl/MediaModel.js12
-rw-r--r--src/components/HMI/app/model/sdl/Model.js1
-rw-r--r--src/components/HMI/app/model/sdl/NonMediaModel.js10
-rw-r--r--src/components/HMI/app/view/WarningView.js17
-rw-r--r--src/components/HMI/app/view/home/controlButtons.js5
-rw-r--r--src/components/HMI/app/view/home/statusMediaView.js2
-rw-r--r--src/components/HMI/app/view/infoView.js16
-rw-r--r--src/components/HMI/app/view/media/common/LeftMenuView.js1
-rw-r--r--src/components/HMI/app/view/media/sdl/controllsView.js4
-rw-r--r--src/components/HMI/app/view/media/sdlmediaView.js4
-rw-r--r--src/components/HMI/app/view/mediaView.js2
-rw-r--r--src/components/HMI/app/view/sdl/ExitAppView.js22
-rw-r--r--src/components/HMI/app/view/sdl/TTSPopUp.js34
-rw-r--r--src/components/HMI/app/view/sdl/shared/interactionChoicesView.js14
-rw-r--r--src/components/HMI/css/buttonControls.css10
-rw-r--r--src/components/HMI/css/general.css41
-rw-r--r--src/components/HMI/css/info.css4
-rw-r--r--src/components/HMI/css/media.css43
-rw-r--r--src/components/HMI/css/sdl.css44
-rw-r--r--src/components/HMI/ffw/BasicCommunicationRPC.js22
-rw-r--r--src/components/HMI/ffw/NavigationRPC.js56
-rw-r--r--src/components/HMI/ffw/RPCClient.js49
-rw-r--r--src/components/HMI/ffw/RPCObserver.js235
-rw-r--r--src/components/HMI/ffw/TTSRPC.js64
-rw-r--r--src/components/HMI/ffw/UIRPC.js172
-rw-r--r--src/components/HMI/ffw/VRRPC.js29
32 files changed, 255 insertions, 820 deletions
diff --git a/src/components/HMI/app/AppViews.js b/src/components/HMI/app/AppViews.js
index ec31c13399..19f1b4879a 100644
--- a/src/components/HMI/app/AppViews.js
+++ b/src/components/HMI/app/AppViews.js
@@ -37,15 +37,9 @@ SDL.AppViews = Em.ContainerView.extend( {
elementId: 'app',
childViews: [
- SDL.HomeView,
SDL.MediaView,
- SDL.NavigationAppView,
SDL.InfoView,
- SDL.PhoneView,
- SDL.ClimateView,
- SDL.NavigationView,
SDL.ControlButtons,
- SDL.SettingsView,
SDL.TurnByTurnView,
SDL.TBTTurnList,
SDL.OptionsView,
@@ -54,12 +48,7 @@ SDL.AppViews = Em.ContainerView.extend( {
SDL.VRHelpListView,
SDL.ScrollableMessage,
SDL.SliderView,
- SDL.StatusClimateView,
- SDL.StatusMediaView,
- SDL.StatusNavigationView,
SDL.StatusInfoView,
- SDL.StatusPhoneView,
- SDL.TopControls,
SDL.BottomControls,
SDL.TTSPopUp,
SDL.AlertPopUp,
diff --git a/src/components/HMI/app/SDLApp.js b/src/components/HMI/app/SDLApp.js
index bbe4644008..c1f40ad588 100644
--- a/src/components/HMI/app/SDLApp.js
+++ b/src/components/HMI/app/SDLApp.js
@@ -48,7 +48,7 @@ SDL = Em.Application.create( {
helpMode: false,
// determine home view {string}
- homeView: 'home',
+ homeView: 'info_view',
/** Set language for localization */
localization: 'eng',
@@ -77,4 +77,4 @@ SDL = Em.Application.create( {
/** container for all views */
SDL.views = SDL.AppViews.create().appendTo('body');
}
-}); \ No newline at end of file
+});
diff --git a/src/components/HMI/app/controller/sdl/AppController.js b/src/components/HMI/app/controller/sdl/AppController.js
index 8f37fa51f0..784e7e8d1c 100644
--- a/src/components/HMI/app/controller/sdl/AppController.js
+++ b/src/components/HMI/app/controller/sdl/AppController.js
@@ -107,10 +107,11 @@ SDL.SDLAppController = Em.Object.create({
*/
VRPerformAction: function (element) {
+ SDL.SDLController.vrInteractionResponse(SDL.SDLModel.resultCode["SUCCESS"], element.commandID);
+
if (SDL.SDLModel.VRActive) {
SDL.SDLModel.toggleProperty('VRActive');
}
- SDL.SDLController.vrInteractionResponse(SDL.SDLModel.resultCode["SUCCESS"], element.commandID);
},
/**
@@ -143,9 +144,6 @@ SDL.SDLAppController = Em.Object.create({
*/
onVRCommand: function (element) {
- if (SDL.SDLModel.VRActive) {
- SDL.SDLModel.toggleProperty('VRActive');
- }
FFW.VR.onCommand(element.commandID, element.appID);
},
diff --git a/src/components/HMI/app/controller/sdl/Controller.js b/src/components/HMI/app/controller/sdl/Controller.js
index a6dc92fc0d..76fbb7e059 100644
--- a/src/components/HMI/app/controller/sdl/Controller.js
+++ b/src/components/HMI/app/controller/sdl/Controller.js
@@ -55,7 +55,7 @@ SDL.SDLController = Em.Object
*/
sysContext: function() {
- if (SDL.SDLModel.VRActive) {
+ if (SDL.VRPopUp.VRActive) {
return 'VRSESSION';
}
if (SDL.AlertPopUp.active) {
@@ -78,7 +78,7 @@ SDL.SDLController = Em.Object
}.property('SDL.OptionsView.active',
'SDL.SliderView.active',
'SDL.SDLModel.AudioPassThruState',
- 'SDL.SDLModel.VRActive',
+ 'SDL.VRPopUp.VRActive',
'SDL.AlertPopUp.active',
'SDL.States.info.nonMedia.active',
'SDL.States.media.sdlmedia.active',
@@ -200,9 +200,7 @@ SDL.SDLController = Em.Object
SDL.VRHelpListView.deactivate();
}
}
- } else if (SDL.VRHelpListView.active) {
- SDL.VRHelpListView.deactivate();
- }
+ }
}.observes('SDL.SDLModel.VRActive', 'SDL.SDLModel.interactionData.vrHelp'),
/**
@@ -416,15 +414,6 @@ SDL.SDLController = Em.Object
FFW.BasicCommunication.ExitAllApplications(state);
},
/**
- * OnAwakeSDL from HMI returns SDL to normal operation
- * after OnExitAllApplications(SUSPEND)
- *
- */
- onAwakeSDLNotificationSend: function() {
- FFW.BasicCommunication.OnAwakeSDL();
- },
-
- /**
* Method to sent notification with selected reason of OnSystemRequest
*
* @param {String}
@@ -469,8 +458,6 @@ SDL.SDLController = Em.Object
if (choiceID && SDL.TTSPopUp.active && FFW.TTS.requestId == null) {
SDL.TTSPopUp.DeactivateTTS();
}
-
- SDL.SDLModel.interactionData.helpPrompt = null;
},
/**
* Method to sent notification for Alert
@@ -601,7 +588,7 @@ SDL.SDLController = Em.Object
deviceName: params.deviceName,
appType: params.appType
}));
-
+/*Uncomment to show useless add command buttons
var exitCommand = {
"id": -10,
"params": {
@@ -614,7 +601,7 @@ SDL.SDLController = Em.Object
}
};
- SDL.SDLController.getApplicationModel(params.appID).addCommand(exitCommand);
+ SDL.SDLController.getApplicationModel(params.appID).addCommand(exitCommand);
exitCommand = {
"id": -10,
@@ -629,6 +616,7 @@ SDL.SDLController = Em.Object
};
SDL.SDLController.getApplicationModel(params.appID).addCommand(exitCommand);
+*/
},
/**
* Unregister application
@@ -653,10 +641,6 @@ SDL.SDLController = Em.Object
if (SDL.SDLModel.stateLimited == appID) {
SDL.SDLModel.set('stateLimited', null);
}
-
- if (SDL.VRHelpListView.active) {
- this.showVRHelpItems();
- }
},
/**
* SDL Driver Distraction ON/OFF switcher
@@ -751,9 +735,6 @@ SDL.SDLController = Em.Object
*/
onActivateSDLApp: function(element) {
- if (SDL.SDLModel.VRActive) {
- SDL.SDLModel.toggleProperty('VRActive');
- }
FFW.BasicCommunication.ActivateApp(element.appID);
},
/**
diff --git a/src/components/HMI/app/controller/sdl/RPCController.js b/src/components/HMI/app/controller/sdl/RPCController.js
index 27dd2ec087..d7ab4b2d01 100644
--- a/src/components/HMI/app/controller/sdl/RPCController.js
+++ b/src/components/HMI/app/controller/sdl/RPCController.js
@@ -72,21 +72,41 @@ SDL.RPCController = Em.Object
capabilitiesCheck: function(key, value) {
if (key == "imageType" && value == "STATIC") {
- SDL.RPCController.capabilityCheckResult = {code: SDL.SDLModel.resultCode['UNSUPPORTED_RESOURCE'], type: value};
+ SDL.RPCController.capabilityCheckResult = 'UNSUPPORTED_RESOURCE';
}
if (key == "type" && value == "PRE_RECORDED") {
- SDL.RPCController.capabilityCheckResult = {code: SDL.SDLModel.resultCode['UNSUPPORTED_RESOURCE'], type: value};
+ SDL.RPCController.capabilityCheckResult = 'UNSUPPORTED_RESOURCE';
}
if (key == "type" && value == "SAPI_PHONEMES") {
- SDL.RPCController.capabilityCheckResult = {code: SDL.SDLModel.resultCode['UNSUPPORTED_RESOURCE'], type: value};
+ SDL.RPCController.capabilityCheckResult = 'UNSUPPORTED_RESOURCE';
}
if (key == "type" && value == "LHPLUS_PHONEMES") {
- SDL.RPCController.capabilityCheckResult = {code: SDL.SDLModel.resultCode['UNSUPPORTED_RESOURCE'], type: value};
+ SDL.RPCController.capabilityCheckResult = 'UNSUPPORTED_RESOURCE';
}
if (key == "type" && value == "SILENCE") {
- SDL.RPCController.capabilityCheckResult = {code: SDL.SDLModel.resultCode['UNSUPPORTED_RESOURCE'], type: value};
+ SDL.RPCController.capabilityCheckResult = 'UNSUPPORTED_RESOURCE';
}
- return value;
+ },
+
+ /**
+ * Method to check supported image type in request
+ *
+ * @param {Object}
+ * array
+ */
+ checkImagesArray: function(array) {
+
+ var error = false;
+ if (array instanceof Array) {
+ for ( var i = 0; i < array.length; i++) {
+ if (array[i].image &&
+ ((array[i].image.imageType !== "DYNAMIC") &&
+ (array[i].image.imageType !== "STATIC"))) {
+
+ }
+ }
+ }
+ return error;
},
/**
@@ -1073,6 +1093,17 @@ SDL.RPCController = Em.Object
return this.resultStruct;
}
+ if ("softButtons" in params) {
+ if (SDL.RPCController
+ .checkImagesArray(params.softButtons)) {
+ this.resultStruct = {
+ "resultCode": SDL.SDLModel.resultCode["INVALID_DATA"],
+ "resultMessage": "Unsupported image type!"
+ };
+
+ return this.resultStruct;
+ }
+ }
if ("turnIcon" in params
&& ((params.turnIcon.imageType !== "DYNAMIC") && (params.turnIcon.imageType !== "STATIC"))) {
this.resultStruct = {
@@ -1152,6 +1183,17 @@ SDL.RPCController = Em.Object
return this.resultStruct;
}
+ if ("softButtons" in params) {
+ if (SDL.RPCController
+ .checkImagesArray(params.softButtons)) {
+ this.resultStruct = {
+ "resultCode": SDL.SDLModel.resultCode["INVALID_DATA"],
+ "resultMessage": "Unsupported image type!"
+ };
+
+ return this.resultStruct;
+ }
+ }
if ("turnList" in params) {
for ( var i = 0; i < params.turnList.length; i++) {
@@ -1235,6 +1277,17 @@ SDL.RPCController = Em.Object
return this.resultStruct;
}
+ if ("softButtons" in params) {
+ if (SDL.RPCController
+ .checkImagesArray(params.softButtons)) {
+ this.resultStruct = {
+ "resultCode": SDL.SDLModel.resultCode["INVALID_DATA"],
+ "resultMessage": "Unsupported image type!"
+ };
+
+ return this.resultStruct;
+ }
+ }
if (params.alertStrings == null) {
this.resultStruct = {
@@ -1369,6 +1422,17 @@ SDL.RPCController = Em.Object
return this.resultStruct;
}
+ if ("softButtons" in params) {
+ if (SDL.RPCController
+ .checkImagesArray(params.softButtons)) {
+ this.resultStruct = {
+ "resultCode": SDL.SDLModel.resultCode["INVALID_DATA"],
+ "resultMessage": "Unsupported image type!"
+ };
+
+ return this.resultStruct;
+ }
+ }
if ("graphic" in params
&& ((params.graphic.imageType !== "DYNAMIC") && (params.graphic.imageType !== "STATIC"))) {
this.resultStruct = {
@@ -1870,6 +1934,16 @@ SDL.RPCController = Em.Object
return this.resultStruct;
}
+ if ("vrHelp" in params) {
+ if (SDL.RPCController.checkImagesArray(params.vrHelp)) {
+ this.resultStruct = {
+ "resultCode": SDL.SDLModel.resultCode["INVALID_DATA"],
+ "resultMessage": "Unsupported image type!"
+ };
+
+ return this.resultStruct;
+ }
+ }
if (params.appID == null) {
this.resultStruct = {
@@ -2204,6 +2278,17 @@ SDL.RPCController = Em.Object
return this.resultStruct;
}
+ if ("softButtons" in params) {
+ if (SDL.RPCController
+ .checkImagesArray(params.softButtons)) {
+ this.resultStruct = {
+ "resultCode": SDL.SDLModel.resultCode["INVALID_DATA"],
+ "resultMessage": "Unsupported image type!"
+ };
+
+ return this.resultStruct;
+ }
+ }
if (params.messageText == null) {
this.resultStruct = {
@@ -2349,6 +2434,17 @@ SDL.RPCController = Em.Object
ShowVrHelp: function(params) {
if (params) {
+ if ("vrHelp" in params) {
+ if (SDL.RPCController
+ .checkImagesArray(params.vrHelp)) {
+ this.resultStruct = {
+ "resultCode": SDL.SDLModel.resultCode["INVALID_DATA"],
+ "resultMessage": "Unsupported image type!"
+ };
+
+ return this.resultStruct;
+ }
+ }
if ("appID" in params) {
if (typeof params.appID != 'number') {
diff --git a/src/components/HMI/app/model/media/CDModel.js b/src/components/HMI/app/model/media/CDModel.js
index 9ded512c5d..43836cb6dc 100644
--- a/src/components/HMI/app/model/media/CDModel.js
+++ b/src/components/HMI/app/model/media/CDModel.js
@@ -40,4 +40,4 @@ SDL.CDModel = Em.Object.create( {
this.set('active', true);
}
-}); \ No newline at end of file
+});
diff --git a/src/components/HMI/app/model/sdl/MediaModel.js b/src/components/HMI/app/model/sdl/MediaModel.js
index 0feceb2119..fa8d8e2a83 100644
--- a/src/components/HMI/app/model/sdl/MediaModel.js
+++ b/src/components/HMI/app/model/sdl/MediaModel.js
@@ -333,15 +333,13 @@ SDL.SDLMediaModel = SDL.SDLAppModel.extend({
}
} else {
- this.appInfo.set('alignment', "text-align:center");
+ //this.appInfo.set('alignment', "text-align:center");
}
- if (params.graphic != null) {
- if (params.graphic.value != "") {
- this.appInfo.set('trackIcon', params.graphic.value);
- } else {
- this.appInfo.set('trackIcon', 'images/sdl/audio_icon.jpg');
- }
+ if (params.graphic && params.graphic.value != '') {
+ this.appInfo.set('trackIcon', params.graphic.value);
+ } else {
+ this.appInfo.set('trackIcon', 'images/sdl/audio_icon.jpg');
}
if ("softButtons" in params) {
diff --git a/src/components/HMI/app/model/sdl/Model.js b/src/components/HMI/app/model/sdl/Model.js
index 4d54e20e5a..a902e649ec 100644
--- a/src/components/HMI/app/model/sdl/Model.js
+++ b/src/components/HMI/app/model/sdl/Model.js
@@ -1224,6 +1224,7 @@ SDL.SDLModel = Em.Object.create({
setTimeout(function(){
if (SDL.SDLModel.vrActiveRequests.vrPerformInteraction) {
SDL.SDLModel.onPrompt(message.params.timeoutPrompt);
+ SDL.SDLModel.interactionData.helpPrompt = null;
}
}, message.params.timeout - 2000); //Magic numer is a platform depended HMI behavior: -2 seconds for timeout prompt
diff --git a/src/components/HMI/app/model/sdl/NonMediaModel.js b/src/components/HMI/app/model/sdl/NonMediaModel.js
index 42ac14bc0c..d9a14b32f2 100644
--- a/src/components/HMI/app/model/sdl/NonMediaModel.js
+++ b/src/components/HMI/app/model/sdl/NonMediaModel.js
@@ -198,12 +198,10 @@ SDL.SDLNonMediaModel = SDL.SDLAppModel.extend({
this.appInfo.set('alignment', "text-align:center");
}
- if (params.graphic != null) {
- if (params.graphic.value != "") {
- this.appInfo.set('mainImage', params.graphic.value);
- } else {
- this.appInfo.set('mainImage', 'images/sdl/audio_icon.jpg');
- }
+ if (params.graphic) {
+ this.appInfo.set('mainImage', params.graphic.value);
+ } else {
+ this.appInfo.set('mainImage', 'images/sdl/audio_icon.jpg');
}
// Magic number is a count of Preset Buttons on HMI = 8
diff --git a/src/components/HMI/app/view/WarningView.js b/src/components/HMI/app/view/WarningView.js
index 8fa40b4547..1db0b6f6c0 100644
--- a/src/components/HMI/app/view/WarningView.js
+++ b/src/components/HMI/app/view/WarningView.js
@@ -88,11 +88,7 @@ SDL.warningView = Em.ContainerView
appLoaded: function() {
var self = this;
- /** Show OK Button after 2 second delay */
- setTimeout(function() {
-
- self.set('isReady', true);
- }, 2000);
+ self.set('isReady', true);
var components = Em.ContainerView.create({
@@ -321,15 +317,8 @@ SDL.warningView = Em.ContainerView
var self = this;
- this._parentView.set('fade', this
- .checkForCCS3AnimationSupport());
-
- setTimeout(function() {
-
- self._parentView.set('hide', true);
- }, 1000);
-
+ self._parentView.set('hide', true);
SDL.RPCController.ConnectToSDL();
}
})
- }); \ No newline at end of file
+ });
diff --git a/src/components/HMI/app/view/home/controlButtons.js b/src/components/HMI/app/view/home/controlButtons.js
index 3b32d47368..cb3ff44ed5 100644
--- a/src/components/HMI/app/view/home/controlButtons.js
+++ b/src/components/HMI/app/view/home/controlButtons.js
@@ -52,8 +52,7 @@ SDL.ControlButtons = Em.ContainerView
'appUILanguagesLabel',
'appTTSVRLanguagesLabel',
'appUILang',
- 'appTTSVRLang',
- 'phoneCall'
+ 'appTTSVRLang'
],
/**
@@ -576,4 +575,4 @@ SDL.ControlButtons = Em.ContainerView
templateName: 'text'
})
})
- }); \ No newline at end of file
+ });
diff --git a/src/components/HMI/app/view/home/statusMediaView.js b/src/components/HMI/app/view/home/statusMediaView.js
index bc94c9e22f..4996b4ce1d 100644
--- a/src/components/HMI/app/view/home/statusMediaView.js
+++ b/src/components/HMI/app/view/home/statusMediaView.js
@@ -96,4 +96,4 @@ SDL.StatusMediaView = Em.ContainerView
SDL.States.goToStates(SDL.MediaController.activeState);
}
}
- }); \ No newline at end of file
+ });
diff --git a/src/components/HMI/app/view/infoView.js b/src/components/HMI/app/view/infoView.js
index 397553d9fa..8740bf455b 100644
--- a/src/components/HMI/app/view/infoView.js
+++ b/src/components/HMI/app/view/infoView.js
@@ -47,13 +47,9 @@ SDL.InfoView = Em.ContainerView.create( {
/** Settings components */
childViews:
[
- 'leftMenu',
- SDL.InfoServicesView,
- SDL.InfoTravelLinkView,
- SDL.InfoCalendarView,
SDL.InfoAppsView,
- SDL.InfoNonMedia,
- SDL.DeviceListView
+ SDL.DeviceListView,
+ SDL.InfoNonMedia
],
/** Left menu */
@@ -82,12 +78,8 @@ SDL.InfoView = Em.ContainerView.create( {
childViews:
[
- 'servicesButton',
- 'travelLinkButton',
- 'calendarButton',
'appsButton',
- 'sdlButton',
- 'goToCD'
+ 'sdlButton'
],
servicesButton: SDL.Button.extend( {
@@ -187,4 +179,4 @@ SDL.InfoView = Em.ContainerView.create( {
} )
} )
} )
-} ); \ No newline at end of file
+} );
diff --git a/src/components/HMI/app/view/media/common/LeftMenuView.js b/src/components/HMI/app/view/media/common/LeftMenuView.js
index ba4495681f..ce44d8a85b 100644
--- a/src/components/HMI/app/view/media/common/LeftMenuView.js
+++ b/src/components/HMI/app/view/media/common/LeftMenuView.js
@@ -40,7 +40,6 @@ SDL.LeftMenuView = Em.ContainerView.extend( {
childViews:
[
'border',
- 'cdButton',
'sdlButton'
],
/** Border decoration */
diff --git a/src/components/HMI/app/view/media/sdl/controllsView.js b/src/components/HMI/app/view/media/sdl/controllsView.js
index 8e73f0ba0e..b7b8f59d7f 100644
--- a/src/components/HMI/app/view/media/sdl/controllsView.js
+++ b/src/components/HMI/app/view/media/sdl/controllsView.js
@@ -38,7 +38,7 @@ SDL.SDLMediaControlls = Em.ContainerView.create( {
[
'info',
'Controls',
- 'tuneButtons'
+ 'tuneButtons' // Uncomment to see preset buttons on sdl screen
],
/**
@@ -235,4 +235,4 @@ SDL.SDLMediaControlls = Em.ContainerView.create( {
} )
} )
} )
-} ); \ No newline at end of file
+} );
diff --git a/src/components/HMI/app/view/media/sdlmediaView.js b/src/components/HMI/app/view/media/sdlmediaView.js
index 78371e7ea7..a880de8a3f 100644
--- a/src/components/HMI/app/view/media/sdlmediaView.js
+++ b/src/components/HMI/app/view/media/sdlmediaView.js
@@ -98,7 +98,7 @@ SDL.sdlView = Em.ContainerView
],
optionsButton: SDL.Button.extend( {
- text: 'Options',
+ text: 'Menu',
templateName: 'arrow',
@@ -107,4 +107,4 @@ SDL.sdlView = Em.ContainerView
})
})
})
- }); \ No newline at end of file
+ });
diff --git a/src/components/HMI/app/view/mediaView.js b/src/components/HMI/app/view/mediaView.js
index 647b593065..c647f999f4 100644
--- a/src/components/HMI/app/view/mediaView.js
+++ b/src/components/HMI/app/view/mediaView.js
@@ -46,4 +46,4 @@ SDL.MediaView = Em.ContainerView.create( {
],
/** Left Menu view component */
leftMenu: SDL.LeftMenuView
-} ); \ No newline at end of file
+} );
diff --git a/src/components/HMI/app/view/sdl/ExitAppView.js b/src/components/HMI/app/view/sdl/ExitAppView.js
index 81e9c7ad5f..4f423f06af 100644
--- a/src/components/HMI/app/view/sdl/ExitAppView.js
+++ b/src/components/HMI/app/view/sdl/ExitAppView.js
@@ -47,9 +47,7 @@ SDL.ExitApp = Em.ContainerView.create( {
[
'exitAppViewLabel',
'exitAppViewTitle',
- 'exitAppViewSelect',
- 'onAwakeSDLLabel',
- 'onAwakeSDLButton'
+ 'exitAppViewSelect'
],
/**
@@ -106,24 +104,6 @@ SDL.ExitApp = Em.ContainerView.create( {
}
} ),
- onAwakeSDLLabel: SDL.Label.extend( {
-
- elementId: 'onAwakeSDLLabel',
-
- classNames: 'onAwakeSDLLabel',
-
- content: 'onAwakeSDL notification send'
- } ),
-
- onAwakeSDLButton: SDL.Button.extend( {
- classNames: 'button onAwakeSDLButton',
- text: 'Send onAwakeSDL',
- action: 'onAwakeSDLNotificationSend',
- target: 'SDL.SDLController',
- buttonAction: true,
- onDown: false
- }),
-
/**
* Trigger function that activates and deactivates tbtClientStateView
*/
diff --git a/src/components/HMI/app/view/sdl/TTSPopUp.js b/src/components/HMI/app/view/sdl/TTSPopUp.js
index be5652ff90..4fc0c7669c 100644
--- a/src/components/HMI/app/view/sdl/TTSPopUp.js
+++ b/src/components/HMI/app/view/sdl/TTSPopUp.js
@@ -45,9 +45,7 @@ SDL.TTSPopUp = Em.ContainerView.create( {
'popUp',
'message',
'okButton',
- 'timerText',
- 'checkBoxLabel',
- 'checkBox'
+ 'timerText'
],
requestId: null,
@@ -88,25 +86,6 @@ SDL.TTSPopUp = Em.ContainerView.create( {
disabledBinding: 'parentView.buttons'
}),
- checkBoxLabel: SDL.Label.extend({
-
- elementId: 'checkBoxLabel',
-
- classNames: 'checkBoxLabel',
-
- content: 'Send response'
- }),
-
- checkBox: Em.Checkbox.extend( {
-
- elementId: 'checkBoxTTS',
-
- classNames: 'checkBoxTTS',
-
- checked: true
-
- }),
-
timerText: SDL.Label.extend({
elementId: 'timerText',
@@ -116,8 +95,6 @@ SDL.TTSPopUp = Em.ContainerView.create( {
contentBinding: 'parentView.timerSeconds'
}),
-
-
resetTimeout: function () {
this.set('timerSeconds', 10);
FFW.TTS.OnResetTimeout(this.appID, "TTS.Speak");
@@ -149,12 +126,9 @@ SDL.TTSPopUp = Em.ContainerView.create( {
DeactivateTTS: function() {
clearInterval(this.timer);
this.set('active', false);
- this.set('timerSeconds', 5);
-
- if (this.checkBox.checked) {
- SDL.SDLController.TTSResponseHandler();
- FFW.TTS.Stopped();
- }
+ this.set('timerSeconds', 10);
+ SDL.SDLController.TTSResponseHandler();
+ FFW.TTS.Stopped();
},
/**
diff --git a/src/components/HMI/app/view/sdl/shared/interactionChoicesView.js b/src/components/HMI/app/view/sdl/shared/interactionChoicesView.js
index 288031ab17..d01165dd14 100644
--- a/src/components/HMI/app/view/sdl/shared/interactionChoicesView.js
+++ b/src/components/HMI/app/view/sdl/shared/interactionChoicesView.js
@@ -86,10 +86,8 @@ SDL.InteractionChoicesView = SDL.SDLAbstractView.create({
],
click: function() {
- if (this._parentView.active) {
- SDL.InteractionChoicesView.timerUpdate();
- SDL.SDLController.onResetTimeout(SDL.SDLAppController.model.appID, "UI.PerformInteraction");
- }
+ SDL.InteractionChoicesView.timerUpdate();
+ SDL.SDLController.onResetTimeout(SDL.SDLAppController.model.appID, "UI.PerformInteraction");
},
naviChoises: Em.ContainerView.extend({
@@ -121,10 +119,8 @@ SDL.InteractionChoicesView = SDL.SDLAbstractView.create({
itemsOnPage: 5,
items: [],
click: function() {
- if (this._parentView.active) {
- SDL.InteractionChoicesView.timerUpdate();
- SDL.SDLController.onResetTimeout(SDL.SDLAppController.model.appID, "UI.PerformInteraction");
- }
+ SDL.InteractionChoicesView.timerUpdate();
+ SDL.SDLController.onResetTimeout(SDL.SDLAppController.model.appID, "UI.PerformInteraction");
}
}),
@@ -147,7 +143,7 @@ SDL.InteractionChoicesView = SDL.SDLAbstractView.create({
* Method updates popup timer when data changes through keyboard
*/
timerUpdate: function (){
- if (this.timeout) {
+ if (this.timeout && this.input.value !== null) {
clearTimeout(this.timer);
var self = this;
this.timer = setTimeout(function () {
diff --git a/src/components/HMI/css/buttonControls.css b/src/components/HMI/css/buttonControls.css
index 39ef852853..b9d3146468 100644
--- a/src/components/HMI/css/buttonControls.css
+++ b/src/components/HMI/css/buttonControls.css
@@ -281,9 +281,7 @@
#buttonControls .ContainerControlls {
left: 34px;
- background:
- url(../images/home/controlButtons/backGroundControllButtons.png)
- no-repeat;
+ background: black no-repeat;
width: 200px;
height: 200px;
}
@@ -406,8 +404,8 @@
-webkit-transition: 0.2s;
border-radius: 8px;
background-color: #1D1D1D;
- border: 1px solid #383737;
- box-shadow: inset 5px 5px 10px #383737, inset -3px -3px 10px black;
+/* border: 1px solid #383737;
+ box-shadow: inset 5px 5px 10px #383737, inset -3px -3px 10px black;*/
-webkit-transition: 0.2s;
font-size: 38px;
line-height: 42px;
@@ -543,4 +541,4 @@
#app_controlButtons .phone_call_button.expand{
left: 156px;
-} \ No newline at end of file
+}
diff --git a/src/components/HMI/css/general.css b/src/components/HMI/css/general.css
index 415545deb9..f09c98c0df 100644
--- a/src/components/HMI/css/general.css
+++ b/src/components/HMI/css/general.css
@@ -16,7 +16,7 @@ html, body {
body {
/*FONT FAMILY*/
- font-family: sans-serif;
+ font-family: helvetica-neue;
/*Defaul font size*/
font-size: 16px;
background-color: #000;
@@ -43,7 +43,7 @@ div {
.ffw-button {
cursor: pointer;
- background: url(../images/common/button.png) repeat-x;
+ background: black;
}
.ffw-button.pressed {
@@ -131,7 +131,7 @@ div {
height: 100px;
z-index: 1;
border-radius: 10 PX;
- top: 8px;
+ top: 330px;
-webkit-transition: opacity 1s ease-in-out;
display: none;
}
@@ -162,24 +162,6 @@ div {
font-size: 30px;
}
-#TTSPopUp .checkBoxLabel {
- color: white;
- top: 106px;
- width: 72px;
- height: 35px;
- left: 25px;
- background-color: rgb(90, 90, 90);
- border-radius: 3px;
- border: 1px solid rgb(255,255,255);
- padding: 2px;
-}
-
-#TTSPopUp .checkBoxTTS {
- top: 118px;
- position: absolute;
- left: 8px;
-}
-
#TTSPopUp .okButton {
right: 52px;
width: 113px;
@@ -595,7 +577,6 @@ div {
#media {
width: 800px;
height: 480px;
- background: url(../images/media/bg.png) no-repeat;
}
/****************************** FOR MEDIA VIEW************************************************/
@@ -811,7 +792,7 @@ margin-top: 90px;
/* List item background */
.list-item.notpressed {
- background-image: url(../images/list/list_item_bg.png);
+ background: rgb(29, 6, 6);
}
.list-item .highLighted {
@@ -901,12 +882,12 @@ margin-top: 90px;
/* List item button background */
.list-item.pressed {
- background-image: url(../images/list/list_item_pressed.png);
+ background: DarkGray;
}
/** Background for pressed button */
.button.pressed {
- background-image: url(../images/list/list_item_pressed.png);
+ background: DarkGray;
}
/* Hide function */
@@ -1003,7 +984,7 @@ margin-top: 90px;
}
.button {
- background-image: url(../images/list/list_item_bg.png);
+ background: rgb(29, 6, 6);
cursor: pointer;
}
@@ -1108,7 +1089,7 @@ margin-top: 90px;
width: 800px;
height: 480px;
z-index: 12001;
- background-image: -webkit-gradient(linear, left bottom, left top, color-stop(0, rgb(218, 218, 218)), color-stop(0.3, rgb(0, 0, 0)));
+ background: black;
}
#warning_view.fr .text {
@@ -1130,7 +1111,6 @@ margin-top: 90px;
font-size: 42px;
font-weight: bold;
top: 20px;
- text-shadow: 1px 1px 3px white;
color: #CC2A2A;
}
@@ -1156,6 +1136,7 @@ margin-top: 90px;
}
#warning_view .components{
+ display: none;
margin-top: 20px;
width: 420px;
}
@@ -1307,7 +1288,7 @@ to {
#wo_popup_denypopup_ok_button {
width: 238px;
height: 48px;
- background: url(../images/common/bt_bg.png) repeat-x;
+ background: gray;
cursor: pointer;
position: relative;
float: left;
@@ -1347,7 +1328,7 @@ to {
}
#wo_popup_yes_button.pressed, #wo_popup_no_button.pressed, #wo_popup_denypopup_ok_button.pressed {
- background: url(../images/common/bt_bg_pressed.png) repeat-x !important;
+ background: gray !important;
}
/* END Welcome Orientation View*/
diff --git a/src/components/HMI/css/info.css b/src/components/HMI/css/info.css
index 34776e6cbf..e212142cdb 100644
--- a/src/components/HMI/css/info.css
+++ b/src/components/HMI/css/info.css
@@ -6,7 +6,7 @@
width: 324px;
height: 48px;
cursor: pointer;
- background: url(../images/common/nav-status-bg.png) no-repeat;
+ background: gray;
z-index: 1;
}
@@ -668,4 +668,4 @@
border-radius: 2px;
top: 269px;
left: 303px;
-} \ No newline at end of file
+}
diff --git a/src/components/HMI/css/media.css b/src/components/HMI/css/media.css
index 85688d5e6b..e8d980479b 100644
--- a/src/components/HMI/css/media.css
+++ b/src/components/HMI/css/media.css
@@ -1,7 +1,7 @@
#media_leftmenu {
z-index: 301;
position: absolute;
- top: 90px;
+ top: 0px;
left: 0px;
width: 150px;
height: 300px;
@@ -55,7 +55,7 @@
left: 0px;
width: 153px;
height: 306px;
- background: url(../images/common/ls_border.png) no-repeat;
+ background: black no-repeat;
}
.media-ls-items {
@@ -73,7 +73,7 @@
}
.media-ls-item.active_state {
- background: url(../images/media/ls-item_bg_act.png) no-repeat !important;
+ background: black no-repeat !important;
}
.media-ls-item>.bg {
@@ -124,19 +124,19 @@
.main-preset-buttons-wraper {
position: relative;
- width: 468px;
+ width: 800px;
height: 100px;
float: left;
- left: 165px;
- top: 290px;
+/* left: 165px;*/
+ top: 350px;
z-index: 503;
}
.main-preset-buttons-wraper .preset-items {
position: relative;
- width: 467px;
+/* width: 467px;
height: 99px;
- border: 1px solid #393939;
+ border: 1px solid #393939;*/
-moz-border-radius: 2px;
-webkit-border-radius: 2px;
z-index: 1;
@@ -148,7 +148,8 @@
vertical-align: top;
border-right: 1px solid #393939;
border-bottom: 1px solid #393939;
- width: 92.6px;
+ border-top: 1px solid #393939;
+ width: 79px;
height: 49px;
cursor: pointer;
}
@@ -314,22 +315,20 @@
{
width: 155px;
height: 98px;
- border-right: 1px solid #393939;
cursor: pointer;
- background: url(../images/media/cd-prev-btn.png) no-repeat;
+ background: black no-repeat;
}
.bc-item-big.prevcd.pressed,.bc-item-big.prevusb.pressed,.bc-item-big.prevsd.pressed,.bc-item-big.prevblue.pressed
{
- background: url(../images/media/cd-prev-btn_pressed.png) no-repeat;
+ background: gray no-repeat;
}
.bc-item-big.playcd {
width: 157px;
height: 98px;
- border-right: 1px solid #393939;
cursor: pointer;
- background: url(../images/media/cd_play_btn.png) no-repeat;
+ background: black no-repeat;
}
.playIcon {
@@ -347,7 +346,7 @@
.bc-item-big.playcd.pressed,.bc-item-big.playusb.pressed,.bc-item-big.playsd.pressed,.bc-item-big.playblue.pressed
{
- background: url(../images/media/cd_play_btn_pressed.png) no-repeat;
+ background: DarkGray no-repeat;
}
.bc-item-big.nextcd,.bc-item-big.nextusb,.bc-item-big.nextsd,.bc-item-big.nextblue
@@ -355,12 +354,12 @@
width: 154px;
height: 98px;
cursor: pointer;
- background: url(../images/media/cd-next-btn.png) no-repeat;
+ background: black no-repeat;
}
.bc-item-big.nextcd.pressed,.bc-item-big.nextusb.pressed,.bc-item-big.nextsd.pressed,.bc-item-big.nextblue.pressed
{
- background: url(../images/media/cd-next-btn_pressed.png) no-repeat;
+ background: DarkGray no-repeat;
}
#bt-bg {
@@ -396,14 +395,12 @@
left: 13px;
width: 468px;
height: 99px;
- background: url("../images/media/btn_bg.png") repeat;
- border: 1px solid #393939;
-webkit-border-radius: 3px;
}
#sdl_view_container .track-info {
left: 165px;
- top: 55px;
+/* top: 55px;*/
}
#sdl_view_container .list-content {
@@ -461,6 +458,7 @@
}
.track-info>.device {
+ display: none;
position: absolute;
top: 30px;
left: 10px;
@@ -471,6 +469,7 @@
}
.divider_o {
+ display: none;
position: absolute;
top: 120px;
left: 0px;
@@ -522,7 +521,7 @@
}
#sdl_view_container .ffw_list_menu {
- top: 90px;
+ /*top: 90px;*/
left: 650px;
width: 140px;
-} \ No newline at end of file
+}
diff --git a/src/components/HMI/css/sdl.css b/src/components/HMI/css/sdl.css
index bd7741163d..303ec2b019 100644
--- a/src/components/HMI/css/sdl.css
+++ b/src/components/HMI/css/sdl.css
@@ -4,7 +4,6 @@
.ffw_list_menu {
left: 440px;
width: 158px;
- border: 1px solid #393939;
overflow: hidden;
}
@@ -15,6 +14,7 @@
.ffw_list_menu .ffw-button {
position: relative;
+ z-index: 300;
height: 49px;
border-bottom: 1px solid #393939;
line-height: 50px;
@@ -70,7 +70,7 @@
}
.sdl-window .back-button {
- top: 80px;
+ /*top: 80px;*/
left: 5px;
width: 48px;
height: 48px;
@@ -84,10 +84,10 @@
}
#info_apps_deviceList_view .deviceListLabel,.sdl-window .caption-text {
- top: 80px;
+ /*top: 80px;*/
left: 75px;
width: 620px;
- background: #393939;
+ background: rgb(29, 6, 6);
overflow: hidden;
text-overflow: ellipsis;
line-height: 50px;
@@ -183,7 +183,7 @@
height: 251px;
border-radius: 2px;
left: 75px;
- top: 150px;
+ top: 51px;
}
/*#sdl_view_container .list-content,*/
@@ -228,7 +228,7 @@
left: 10px;
width: 84px;
height: 50px;
- font-size: 20px;
+ font-size: 12px;
line-height: 50px;
overflow: hidden;
text-overflow: ellipsis;
@@ -236,7 +236,7 @@
}
#sdl_view_container .preset-items {
- width: 468px;
+/* width: 468px; */
}
#sdl_view_container .main-preset-buttons-wraper .preset-item.a3,#sdl_view_container .main-preset-buttons-wraper .preset-item.a6
@@ -245,16 +245,17 @@
}
#sdl_view_container .player_controllsV2 {
- top: 241px !important;
+
+ top: 200px !important;
height: 48px;
}
#sdl_view_container .player_controllsV2 .ffw-button {
- height: 48px;
+/* height: 48px;*/
}
#sdl_view_container .player_controllsV2 img {
- margin-top: -26px;
+/* margin-top: -26px; */
}
/* ScrollableMessage */
@@ -480,7 +481,6 @@
position: absolute;
top: 90px;
right: 10px;
- border: 1px solid #393939;
-webkit-border-radius: 2px;
width: 109px;
height: 109px;
@@ -490,7 +490,6 @@
position: absolute;
top: 70px;
right: 10px;
- border: 1px solid #393939;
-webkit-border-radius: 2px;
width: 109px;
height: 109px;
@@ -601,25 +600,6 @@
background: #393939;
}
-#exitAppView .onAwakeSDLLabel{
- top: 200px;
- width: 600px;
- left: 40px;
- height: 20px;
- padding: 10px;
- background: #535353;
-}
-
-#exitAppView .onAwakeSDLButton{
- right: 268px;
- top: 250px;
- width: 150px;
- height: 19px;
- padding: 10px;
- border-radius: 4px;
- border: 1px solid white;
-}
-
#VehicleInfo .odometrTitle{
top: 180px;
width: 290px;
@@ -1235,4 +1215,4 @@
#media_app_options_view .list-content {
width: 578px;
-} \ No newline at end of file
+}
diff --git a/src/components/HMI/ffw/BasicCommunicationRPC.js b/src/components/HMI/ffw/BasicCommunicationRPC.js
index 0bc2b06233..0fd63b0fc1 100644
--- a/src/components/HMI/ffw/BasicCommunicationRPC.js
+++ b/src/components/HMI/ffw/BasicCommunicationRPC.js
@@ -418,10 +418,6 @@ FFW.BasicCommunication = FFW.RPCObserver
}
if (request.method == "BasicCommunication.UpdateAppList") {
- var message = "Was found " + request.params.applications.length + " apps";
-
- SDL.PopUp.create().appendTo('body').popupActivate(message);
-
this.sendBCResult(SDL.SDLModel.resultCode["SUCCESS"],
request.id,
request.method);
@@ -1004,24 +1000,6 @@ FFW.BasicCommunication = FFW.RPCObserver
},
/**
- * OnAwakeSDL from HMI returns SDL to normal operation
- * after OnExitAllApplications(SUSPEND)
- */
- OnAwakeSDL: function() {
-
- Em.Logger.log("FFW.BasicCommunication.OnAwakeSDL");
-
- // send request
- var JSONMessage = {
- "jsonrpc": "2.0",
- "method": "BasicCommunication.OnAwakeSDL"
- };
- this.client.send(JSONMessage);
- },
-
-
-
- /**
* Used by HMI when User chooses to exit application.
*
* @params {Number}
diff --git a/src/components/HMI/ffw/NavigationRPC.js b/src/components/HMI/ffw/NavigationRPC.js
index a3fb289dc6..5f594079a1 100644
--- a/src/components/HMI/ffw/NavigationRPC.js
+++ b/src/components/HMI/ffw/NavigationRPC.js
@@ -172,24 +172,6 @@ FFW.Navigation = FFW.RPCObserver.create( {
}
case "Navigation.AlertManeuver": {
- // Werify if there is an ansupported data in request
- if (this.errorResponsePull[request.id] != null) {
-
- //Check if there is any available data to process the request
- if ("softButtons" in request.params) {
-
- this.errorResponsePull[request.id].code = SDL.SDLModel.resultCode["WARNINGS"];
- } else {
- //If no available data sent error response and stop process current request
-
- this.sendError(this.errorResponsePull[request.id].code, request.id, request.method,
- "Unsupported " + this.errorResponsePull[request.id].type + " type. Request was not processed.");
- this.errorResponsePull[request.id] = null;
-
- return;
- }
- }
-
this.sendNavigationResult(SDL.SDLModel.resultCode["SUCCESS"],
request.id,
request.method);
@@ -198,12 +180,6 @@ FFW.Navigation = FFW.RPCObserver.create( {
}
case "Navigation.ShowConstantTBT": {
- // Werify if there is an ansupported data in request
- if (this.errorResponsePull[request.id] != null) {
-
- this.errorResponsePull[request.id].code = SDL.SDLModel.resultCode["WARNINGS"];
- }
-
SDL.SDLModel.tbtActivate(request.params);
this.sendNavigationResult(SDL.SDLModel.resultCode["SUCCESS"],
request.id,
@@ -213,24 +189,6 @@ FFW.Navigation = FFW.RPCObserver.create( {
}
case "Navigation.UpdateTurnList": {
- // Werify if there is an ansupported data in request
- if (this.errorResponsePull[request.id] != null) {
-
- //Check if there is any available data to process the request
- if ("turnList" in request.params || "softButtons" in request.params) {
-
- this.errorResponsePull[request.id].code = SDL.SDLModel.resultCode["WARNINGS"];
- } else {
- //If no available data sent error response and stop process current request
-
- this.sendError(this.errorResponsePull[request.id].code, request.id, request.method,
- "Unsupported " + this.errorResponsePull[request.id].type + " type. Request was not processed.");
- this.errorResponsePull[request.id] = null;
-
- return;
- }
- }
-
SDL.SDLModel.tbtTurnListUpdate(request.params);
this.sendNavigationResult(SDL.SDLModel.resultCode["SUCCESS"],
request.id,
@@ -280,12 +238,6 @@ FFW.Navigation = FFW.RPCObserver.create( {
}
case "Navigation.SendLocation": {
- // Werify if there is an ansupported data in request
- if (this.errorResponsePull[request.id] != null) {
-
- this.errorResponsePull[request.id].code = SDL.SDLModel.resultCode["WARNINGS"];
- }
-
this.sendNavigationResult(SDL.SDLModel.resultCode["SUCCESS"],
request.id,
request.method);
@@ -340,14 +292,6 @@ FFW.Navigation = FFW.RPCObserver.create( {
*/
sendNavigationResult: function(resultCode, id, method) {
- if (this.errorResponsePull[id]) {
-
- this.sendError(this.errorResponsePull[id].code, id, method,
- "Unsupported " + this.errorResponsePull[id].type + " type. Available data in request was processed.");
- this.errorResponsePull[id] = null;
- return;
- }
-
Em.Logger.log("FFW.UI." + method + "Response");
if (resultCode === SDL.SDLModel.resultCode["SUCCESS"]) {
diff --git a/src/components/HMI/ffw/RPCClient.js b/src/components/HMI/ffw/RPCClient.js
index 5df06334d2..954dfbe17e 100644
--- a/src/components/HMI/ffw/RPCClient.js
+++ b/src/components/HMI/ffw/RPCClient.js
@@ -129,19 +129,34 @@ FFW.RPCClient = Em.Object
Em.Logger.log("Message received: " + evt.data);
- var jsonObj = JSON.parse(evt.data, SDL.RPCController.capabilitiesCheck);
+ var jsonObj = JSON.parse(evt.data);
+
+ JSON.parse(evt.data, SDL.RPCController.capabilitiesCheck);
+
+ if (jsonObj.method == 'UI.Show' && SDL.RPCController.capabilityCheckResult == 'UNSUPPORTED_RESOURCE' && Object.size(jsonObj.params) != 3 && jsonObj.params.showStrings.length != 0) {
+
+ this.observer.errorResponsePull[jsonObj.id] = SDL.SDLModel.resultCode["WARNINGS"];
+
+ Em.Logger.error('Image of STATIC type is not supported on HMI. Other information was successfully displayed');
- if (SDL.RPCController.capabilityCheckResult != null) {
- this.observer.errorResponsePull[jsonObj.id] = SDL.RPCController.capabilityCheckResult;
SDL.RPCController.capabilityCheckResult = null;
- this.observer.checkImage(jsonObj.params);
- this.observer.checkSoftButtons(jsonObj.params);
- this.observer.checkChoice(jsonObj.params);
- this.observer.checkChunk(jsonObj.params);
- this.observer.checkHelpItems(jsonObj.params);
- this.observer.checkTurnList(jsonObj.params);
+ } else {
+
+ switch (SDL.RPCController.capabilityCheckResult) {
+ case 'UNSUPPORTED_RESOURCE': {
+
+ this.observer.errorResponsePull[jsonObj.id] = SDL.SDLModel.resultCode["UNSUPPORTED_RESOURCE"];
+
+ Em.Logger.error('Unsupported incoming resource! In method ' + jsonObj.method);
+
+ SDL.RPCController.capabilityCheckResult = null;
+
+ break;
+ }
+ }
}
+
// handle component registration
if (jsonObj.id == this.registerRequestId && jsonObj.method == null && typeof jsonObj.result == 'number') {
if (jsonObj.error == null) {
@@ -274,6 +289,22 @@ FFW.RPCClient = Em.Object
if (this.socket.readyState == this.socket.OPEN) {
+ if (this.observer.errorResponsePull[obj.id] && this.observer.errorResponsePull[obj.id] !== 0 && obj.result) {
+ var method = obj.result.method;
+
+ delete obj.result;
+
+ obj.error = {
+ "code": this.observer.errorResponsePull[obj.id],
+ "message": this.observer.errorResponsePull[obj.id] == 21 ? "Image of STATIC type is not supported on HMI. Other information was successfully displayed" : "Unsupported incoming resource!",
+ "data": {
+ "method": method
+ }
+ }
+
+ delete this.observer.errorResponsePull[obj.id];
+ }
+
var strJson = JSON.stringify(obj);
Em.Logger.log(strJson);
diff --git a/src/components/HMI/ffw/RPCObserver.js b/src/components/HMI/ffw/RPCObserver.js
index 76b002aa8b..6f598cbeb0 100644
--- a/src/components/HMI/ffw/RPCObserver.js
+++ b/src/components/HMI/ffw/RPCObserver.js
@@ -71,244 +71,11 @@ FFW.RPCObserver = Em.Object
// parse JSON string and set necessary properties
},
- onRPCRequest: function(request, error) {
+ onRPCRequest: function(request) {
// parse JSON string and send back necessary data
},
- /**
- * Check for unsupported image type
- * Return false if unsupported image type was found and delete unsupported resource
- * @param params
- * @returns {boolean}
- */
- checkImage: function(params){
- if ("graphic" in params) {
- if (params.graphic.imageType === "STATIC") {
- delete params.graphic;
- return false;
- }
- }
- if ("secondaryGraphic" in params) {
- if (params.secondaryGraphic.imageType === "STATIC") {
- delete params.secondaryGraphic;
- return false;
- }
- }
- if ("image" in params) {
- if (params.image.imageType === "STATIC") {
- delete params.image;
- return false;
- }
- }
- if ("secondaryImage" in params) {
- if (params.image.imageType === "STATIC") {
- delete params.image;
- return false;
- }
- }
- if ("turnIcon" in params) {
- if (params.turnIcon.imageType === "STATIC") {
- delete params.turnIcon;
- return false;
- }
- }
- if ("nextTurnIcon" in params) {
- if (params.nextTurnIcon.imageType === "STATIC") {
- delete params.nextTurnIcon;
- return false;
- }
- }
- if ("cmdIcon" in params) {
- if (params.cmdIcon.imageType === "STATIC") {
- delete params.cmdIcon;
- return false;
- }
- }
- if ("menuIcon" in params) {
- if (params.menuIcon.imageType === "STATIC") {
- delete params.menuIcon;
- return false;
- }
- }
- if ("syncFileName" in params) {
- if (params.syncFileName.imageType === "STATIC") {
- delete params.syncFileName;
- return false;
- }
- }
- if ("locationImage" in params) {
- if (params.locationImage.imageType === "STATIC") {
- delete params.locationImage;
- return false;
- }
- }
- return true;
- },
-
- /**
- * Check for unsupported image type
- * If unsupported image type was found delete unsupported resource
- * @param params
- */
- checkSoftButtons: function(params){
-
- if ("softButtons" in params) {
- for (var i = params.softButtons.length-1; i >= 0 ; i--) {
- if (!this.checkImage(params.softButtons[i])) {
- if (!("text" in params.softButtons[i])) {
-
- params.softButtons.splice(i, 1);
- }
- }
- }
-
- if (params.softButtons.length == 0) {
- delete params.softButtons;
- }
- }
- },
-
- /**
- * Check for unsupported image type
- * If unsupported image type was found delete unsupported resource
- * @param params
- */
- checkTurnList: function(params){
-
- if ("turnList" in params) {
- for (var i = params.turnList.length-1; i >= 0 ; i--) {
- if (!this.checkImage(params.turnList[i])) {
- if (!("navigationText" in params.turnList[i])) {
-
- params.turnList.splice(i, 1);
- }
- }
- }
-
- if (params.turnList.length == 0) {
- delete params.turnList;
- }
- }
- },
-
- /**
- * Check for unsupported tts type
- * If unsupported tts type was found delete unsupported resource
- * @param params
- */
- checkChunk: function(params){
-
- if ("ttsName" in params) {
- for (var i = params.ttsName.length-1; i >= 0 ; i--) {
- if (params.ttsName[i].type != "TEXT") {
-
- params.ttsName.splice(i, 1);
- }
- }
-
- if (params.ttsName.length == 0) {
- delete params.ttsName;
- }
- }
- if ("helpPrompt" in params) {
- for (var i = params.helpPrompt.length-1; i >= 0 ; i--) {
- if (params.helpPrompt[i].type != "TEXT") {
-
- params.helpPrompt.splice(i, 1);
- }
- }
-
- if (params.helpPrompt.length == 0) {
- delete params.helpPrompt;
- }
- }
- if ("initialPrompt" in params) {
- for (var i = params.initialPrompt.length-1; i >= 0 ; i--) {
- if (params.initialPrompt[i].type != "TEXT") {
-
- params.initialPrompt.splice(i, 1);
- }
- }
-
- if (params.initialPrompt.length == 0) {
- delete params.initialPrompt;
- }
- }
- if ("timeoutPrompt" in params) {
- for (var i = params.timeoutPrompt.length-1; i >= 0 ; i--) {
- if (params.timeoutPrompt[i].type != "TEXT") {
-
- params.timeoutPrompt.splice(i, 1);
- }
- }
-
- if (params.timeoutPrompt.length == 0) {
- delete params.timeoutPrompt;
- }
- }
- if ("ttsChunks" in params) {
- for (var i = params.ttsChunks.length-1; i >= 0 ; i--) {
- if (params.ttsChunks[i].type != "TEXT") {
-
- params.ttsChunks.splice(i, 1);
- }
- }
-
- if (params.ttsChunks.length == 0) {
- delete params.ttsChunks;
- }
- }
- },
-
- /**
- * Check for unsupported choiceSet type
- * If unsupported choiceSet type was found delete unsupported resource
- * @param params
- */
- checkChoice: function(params){
-
- if ("choiceSet" in params) {
- for (var i = params.choiceSet.length-1; i >= 0 ; i--) {
- if (this.checkImage(params.choiceSet[i])) {
- if (!("menuName" in params.choiceSet[i])
- || !("secondaryText" in params.choiceSet[i])
- || !("tertiaryText" in params.choiceSet[i])) {
-
- params.choiceSet.splice(i, 1);
- }
- }
- }
-
- if (params.choiceSet.length == 0) {
- delete params.choiceSet;
- }
- }
- },
-
- /**
- * Check for unsupported vrHelp type
- * If unsupported vrHelp type was found delete unsupported resource
- * @param params
- */
- checkHelpItems: function(params){
-
- if ("vrHelp" in params) {
- for (var i = params.vrHelp.length-1; i >= 0 ; i--) {
- if (this.checkImage(params.vrHelp[i])) {
- if (!("text" in params.vrHelp[i])) {
-
- params.vrHelp.splice(i, 1);
- }
- }
- }
-
- if (params.vrHelp.length == 0) {
- delete params.vrHelp;
- }
- }
- },
-
validationCheck: function(request) {
if (request && request.method) {
diff --git a/src/components/HMI/ffw/TTSRPC.js b/src/components/HMI/ffw/TTSRPC.js
index 0e0b92acd4..6939aa4938 100644
--- a/src/components/HMI/ffw/TTSRPC.js
+++ b/src/components/HMI/ffw/TTSRPC.js
@@ -151,24 +151,6 @@ FFW.TTS = FFW.RPCObserver.create( {
switch (request.method) {
case "TTS.Speak": {
- // Werify if there is an ansupported data in request
- if (this.errorResponsePull[request.id] != null) {
-
- //Check if there is any available data to process the request
- if ("ttsChunks" in request.params) {
-
- this.errorResponsePull[request.id].code = SDL.SDLModel.resultCode["WARNINGS"];
- } else {
- //If no available data sent error response and stop process current request
-
- this.sendError(this.errorResponsePull[request.id].code, request.id, request.method,
- "Unsupported " + this.errorResponsePull[request.id].type + " type. Request was not processed.");
- this.errorResponsePull[request.id] = null;
-
- return;
- }
- }
-
if (SDL.TTSPopUp.active) {
FFW.TTS.sendError(SDL.SDLModel.resultCode["REJECTED"], request.id, "TTS.Speak", "TTS in progress. Rejected.");
} else {
@@ -180,25 +162,6 @@ FFW.TTS = FFW.RPCObserver.create( {
}
case "TTS.SetGlobalProperties": {
- // Werify if there is an ansupported data in request
- if (this.errorResponsePull[request.id] != null) {
-
- //Check if there is any available data to process the request
- if ("helpPrompt" in request.params
- || "timeoutPrompt" in request.params) {
-
- this.errorResponsePull[request.id].code = SDL.SDLModel.resultCode["WARNINGS"];
- } else {
- //If no available data sent error response and stop process current request
-
- this.sendError(this.errorResponsePull[request.id].code, request.id, request.method,
- "Unsupported " + this.errorResponsePull[request.id].type + " type. Request was not processed.");
- this.errorResponsePull[request.id] = null;
-
- return;
- }
- }
-
SDL.SDLModel.setProperties(request.params);
this.sendTTSResult(SDL.SDLModel.resultCode["SUCCESS"],
@@ -285,25 +248,6 @@ FFW.TTS = FFW.RPCObserver.create( {
}
case "TTS.ChangeRegistration": {
- // Werify if there is an ansupported data in request
- if (this.errorResponsePull[request.id] != null) {
-
- //Check if there is any available data to process the request
- if ("ttsName" in request.params
- || "language" in request.params) {
-
- this.errorResponsePull[request.id].code = SDL.SDLModel.resultCode["WARNINGS"];
- } else {
- //If no available data sent error response and stop process current request
-
- this.sendError(this.errorResponsePull[request.id].code, request.id, request.method,
- "Unsupported " + this.errorResponsePull[request.id].type + " type. Request was not processed.");
- this.errorResponsePull[request.id] = null;
-
- return;
- }
- }
-
SDL.SDLModel.changeRegistrationTTSVR(request.params.language, request.params.appID);
this.sendTTSResult(SDL.SDLModel.resultCode["SUCCESS"],
@@ -384,14 +328,6 @@ FFW.TTS = FFW.RPCObserver.create( {
*/
sendTTSResult: function(resultCode, id, method) {
- if (this.errorResponsePull[id]) {
-
- this.sendError(this.errorResponsePull[id].code, id, method,
- "Unsupported " + this.errorResponsePull[id].type + " type. Available data in request was processed.");
- this.errorResponsePull[id] = null;
- return;
- }
-
Em.Logger.log("FFW." + method + "Response");
if (resultCode === SDL.SDLModel.resultCode["SUCCESS"]) {
diff --git a/src/components/HMI/ffw/UIRPC.js b/src/components/HMI/ffw/UIRPC.js
index ff0aa73013..43ee73a850 100644
--- a/src/components/HMI/ffw/UIRPC.js
+++ b/src/components/HMI/ffw/UIRPC.js
@@ -168,25 +168,6 @@ FFW.UI = FFW.RPCObserver.create({
case "UI.Alert":
{
- // Werify if there is an ansupported data in request
- if (this.errorResponsePull[request.id] != null) {
-
- //Check if there is any available data to process the request
- if (request.params.alertStrings.length > 0
- || "softButtons" in request.params) {
-
- this.errorResponsePull[request.id].code = SDL.SDLModel.resultCode["WARNINGS"];
- } else {
- //If no available data sent error response and stop process current request
-
- this.sendError(this.errorResponsePull[request.id].code, request.id, request.method,
- "Unsupported " + this.errorResponsePull[request.id].type + " type. Request was not processed.");
- this.errorResponsePull[request.id] = null;
-
- return;
- }
- }
-
if (SDL.SDLModel.onUIAlert(request.params, request.id)) {
SDL.SDLController.onSystemContextChange(request.params.appID);
}
@@ -196,28 +177,6 @@ FFW.UI = FFW.RPCObserver.create({
case "UI.Show":
{
- // Werify if there is an ansupported data in request
- if (this.errorResponsePull[request.id] != null) {
-
- //Check if there is any available data to process the request
- if (request.params.showStrings.length > 0
- || "graphic" in request.params
- || "secondaryGraphic" in request.params
- || "softButtons" in request.params
- || "customPresets" in request.params) {
-
- this.errorResponsePull[request.id].code = SDL.SDLModel.resultCode["WARNINGS"];
- } else {
- //If no available data sent error response and stop process current request
-
- this.sendError(this.errorResponsePull[request.id].code, request.id, request.method,
- "Unsupported " + this.errorResponsePull[request.id].type + " type. Request was not processed.");
- this.errorResponsePull[request.id] = null;
-
- return;
- }
- }
-
SDL.TurnByTurnView.deactivate();
SDL.SDLController.getApplicationModel(request.params.appID).onSDLUIShow(request.params);
this.sendUIResult(SDL.SDLModel.resultCode["SUCCESS"], request.id, request.method);
@@ -226,55 +185,21 @@ FFW.UI = FFW.RPCObserver.create({
}
case "UI.SetGlobalProperties":
{
-
- // Werify if there is an ansupported data in request
- if (this.errorResponsePull[request.id] != null) {
-
- //Check if there is any available data to process the request
- if ("menuTitle" in request.params
- || "keyboardProperties" in request.params
- || "vrHelp" in request.params
- || "menuIcon" in request.params) {
-
- this.errorResponsePull[request.id].code = SDL.SDLModel.resultCode["WARNINGS"];
- } else {
- //If no available data sent error response and stop process current request
-
- this.sendError(this.errorResponsePull[request.id].code, request.id, request.method,
- "Unsupported " + this.errorResponsePull[request.id].type + " type. Request was not processed.");
- this.errorResponsePull[request.id] = null;
-
- return;
- }
- }
-
SDL.SDLModel.setProperties(request.params);
this.sendUIResult(SDL.SDLModel.resultCode["SUCCESS"], request.id, request.method);
break;
}
- case "UI.AddCommand":
+ case "UI.ResetGlobalProperties":
{
- // Werify if there is an ansupported data in request
- if (this.errorResponsePull[request.id] != null) {
-
- //Check if there is any available data to process the request
- if ("cmdIcon" in request.params
- || "menuParams" in request.params) {
-
- this.errorResponsePull[request.id].code = SDL.SDLModel.resultCode["WARNINGS"];
- } else {
- //If no available data sent error response and stop process current request
-
- this.sendError(this.errorResponsePull[request.id].code, request.id, request.method,
- "Unsupported " + this.errorResponsePull[request.id].type + " type. Request was not processed.");
- this.errorResponsePull[request.id] = null;
+ this.sendUIResult(SDL.SDLModel.resultCode["SUCCESS"], request.id, request.method);
- return;
- }
- }
+ break;
+ }
+ case "UI.AddCommand":
+ {
SDL.SDLController.getApplicationModel(request.params.appID).addCommand(request);
@@ -305,26 +230,6 @@ FFW.UI = FFW.RPCObserver.create({
case "UI.PerformInteraction":
{
- // Werify if there is an ansupported data in request
- if (this.errorResponsePull[request.id] != null) {
-
- //Check if there is any available data to process the request
- if ("choiceSet" in request.params
- && request.params
- && request.params.interactionLayout != "KEYBOARD") {
-
- this.errorResponsePull[request.id].code = SDL.SDLModel.resultCode["WARNINGS"];
- } else {
- //If no available data sent error response and stop process current request
-
- this.sendError(this.errorResponsePull[request.id].code, request.id, request.method,
- "Unsupported " + this.errorResponsePull[request.id].type + " type. Request was not processed.");
- this.errorResponsePull[request.id] = null;
-
- return;
- }
- }
-
if (SDL.SDLModel.uiPerformInteraction(request)) {
SDL.SDLController.onSystemContextChange();
}
@@ -867,20 +772,6 @@ FFW.UI = FFW.RPCObserver.create({
case "UI.SetAppIcon":
{
- // Werify if there is an ansupported data in request
- if (this.errorResponsePull[request.id] != null) {
-
- //Check if there is any available data to process the request
- if (!("syncFileName" in request.params)) {
-
- this.sendError(this.errorResponsePull[request.id].code, request.id, request.method,
- "Unsupported " + this.errorResponsePull[request.id].type + " type. Request was not processed.");
- this.errorResponsePull[request.id] = null;
-
- return;
- }
- }
-
SDL.SDLModel.onSDLSetAppIcon(request.params, request.id, request.method);
break;
@@ -1429,14 +1320,6 @@ FFW.UI = FFW.RPCObserver.create({
*/
sendUIResult: function (resultCode, id, method) {
- if (this.errorResponsePull[id]) {
-
- this.sendError(this.errorResponsePull[id].code, id, method,
- "Unsupported " + this.errorResponsePull[id].type + " type. Available data in request was processed.");
- this.errorResponsePull[id] = null;
- return;
- }
-
Em.Logger.log("FFW." + method + "Response");
if (resultCode === SDL.SDLModel.resultCode["SUCCESS"]) {
@@ -1468,8 +1351,16 @@ FFW.UI = FFW.RPCObserver.create({
switch (resultCode) {
case SDL.SDLModel.resultCode["SUCCESS"]: {
-
- this.sendUIResult(resultCode, id, 'UI.Alert');
+ // send repsonse
+ var JSONMessage = {
+ "jsonrpc": "2.0",
+ "id": id,
+ "result": {
+ "code": resultCode, // type (enum) from SDL protocol
+ "method": 'UI.Alert'
+ }
+ };
+ this.client.send(JSONMessage);
break;
}
@@ -1503,7 +1394,6 @@ FFW.UI = FFW.RPCObserver.create({
if (resultCode === SDL.SDLModel.resultCode["SUCCESS"]) {
- this.sendUIResult(resultCode, id, 'UI.Alert');
// send repsonse
var JSONMessage = {
"jsonrpc": "2.0",
@@ -1640,36 +1530,6 @@ FFW.UI = FFW.RPCObserver.create({
Em.Logger.log("FFW.UI.PerformInteractionResponse");
- if (this.errorResponsePull[requestID]) {
-
- if (resultCode === SDL.SDLModel.resultCode["SUCCESS"]) {
- // send repsonse
- var JSONMessage = {
- "jsonrpc": "2.0",
- "id": requestID,
- "error": {
- "code": this.errorResponsePull[requestID].code,
- "message": "Unsupported " + this.errorResponsePull[requestID].type + " type. Available data in request was processed.",
- "data": {
- "method": "UI.PerformInteraction"
- }
- }
- };
-
- if (commandID) {
- JSONMessage.error.data.choiceID = commandID;
- }
-
- if (manualTextEntry != null) {
- JSONMessage.error.data.manualTextEntry = manualTextEntry;
- }
- }
-
- this.client.send(JSONMessage);
- this.errorResponsePull[requestID] = null;
- return;
- }
-
if (resultCode === SDL.SDLModel.resultCode["SUCCESS"]) {
// send repsonse
var JSONMessage = {
diff --git a/src/components/HMI/ffw/VRRPC.js b/src/components/HMI/ffw/VRRPC.js
index 55a51b68cb..680c9a87dc 100644
--- a/src/components/HMI/ffw/VRRPC.js
+++ b/src/components/HMI/ffw/VRRPC.js
@@ -247,27 +247,6 @@ FFW.VR = FFW.RPCObserver.create( {
case "VR.PerformInteraction":
{
- // Werify if there is an ansupported data in request
- if (this.errorResponsePull[request.id] != null) {
-
- //Check if there is any available data to process the request
- if ("helpPrompt" in request.params
- || "initialPrompt" in request.params
- || "timeoutPrompt" in request.params
- || "grammarID" in request.params) {
-
- this.errorResponsePull[request.id].code = SDL.SDLModel.resultCode["WARNINGS"];
- } else {
- //If no available data sent error response and stop process current request
-
- this.sendError(this.errorResponsePull[request.id].code, request.id, request.method,
- "Unsupported " + this.errorResponsePull[request.id].type + " type. Request was not processed.");
- this.errorResponsePull[request.id] = null;
-
- return;
- }
- }
-
SDL.SDLModel.vrPerformInteraction(request);
break;
@@ -387,14 +366,6 @@ FFW.VR = FFW.RPCObserver.create( {
*/
sendVRResult: function(resultCode, id, method) {
- if (this.errorResponsePull[id]) {
-
- this.sendError(this.errorResponsePull[id].code, id, method,
- "Unsupported " + this.errorResponsePull[id].type + " type. Available data in request was processed.");
- this.errorResponsePull[id] = null;
- return;
- }
-
Em.Logger.log("FFW." + method + "Response");
if (resultCode === SDL.SDLModel.resultCode["SUCCESS"]) {