From 20800390f84f829eec7c50d03efa07aa64cd81e6 Mon Sep 17 00:00:00 2001 From: Collin Date: Wed, 2 Jun 2021 12:21:02 -0400 Subject: [PATCH] remove unnecessary MenuList setMode (#573) * remove unnecessary MenuList setMode * Revert "remove unnecessary MenuList setMode" This reverts commit 2d4363622922be4d37b678c66816bd9e18818d6b. * fix console error with scrollable message change mode and add setMode call to scrollableMessage --- app/controlls/MenuList.js | 7 +------ app/view/sdl/shared/scrollableMessage.js | 3 +++ 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/app/controlls/MenuList.js b/app/controlls/MenuList.js index 0635f936a..79308aa41 100644 --- a/app/controlls/MenuList.js +++ b/app/controlls/MenuList.js @@ -50,12 +50,7 @@ SDL.MenuList = Em.ContainerView.extend({ text: buttons[i].text, icon: buttons[i].image ? buttons[i].image.value : '', groupName: 'AlertPopUp', - classNameBindings: ['isHighlighted:isHighlighted', - 'getCurrentDisplayModeClass'], - getCurrentDisplayModeClass: function() { - return SDL.ControlButtons.getCurrentDisplayModeClass( - SDL.ControlButtons.imageMode.selection); - }.property('SDL.ControlButtons.imageMode.selection'), + classNameBindings: ['isHighlighted:isHighlighted'], isHighlighted: buttons[i].isHighlighted ? true : false, softButtonID: buttons[i].softButtonID, systemAction: buttons[i].systemAction, diff --git a/app/view/sdl/shared/scrollableMessage.js b/app/view/sdl/shared/scrollableMessage.js index 2b938697c..637aa2a9b 100644 --- a/app/view/sdl/shared/scrollableMessage.js +++ b/app/view/sdl/shared/scrollableMessage.js @@ -55,6 +55,9 @@ SDL.ScrollableMessage = SDL.SDLAbstractView.create( childViews: [ 'backButton', 'captionText', 'softButtons', 'listOfCommands' ], + imageModeChanged: function() { + this.get('softButtons').setMode(SDL.SDLModel.data.imageMode); + }.observes('SDL.SDLModel.data.imageMode'), /** * Deactivate View *