From eb021911301473f90374fe03e0850fd1e51d94e5 Mon Sep 17 00:00:00 2001 From: collin Date: Wed, 11 Aug 2021 17:14:12 -0400 Subject: [PATCH] scrollable reply success on default action and steal focus --- app/controller/sdl/Abstract/Controller.js | 4 ++-- app/model/sdl/Abstract/Model.js | 2 +- app/view/sdl/shared/scrollableMessage.js | 6 ++++-- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/app/controller/sdl/Abstract/Controller.js b/app/controller/sdl/Abstract/Controller.js index 899e1ede4..2e056338d 100644 --- a/app/controller/sdl/Abstract/Controller.js +++ b/app/controller/sdl/Abstract/Controller.js @@ -614,7 +614,7 @@ SDL.SDLController = Em.Object.extend( } case 'ScrollableMessage': { - SDL.ScrollableMessage.deactivate(true); + SDL.ScrollableMessage.deactivate(); break; } } @@ -661,7 +661,7 @@ SDL.SDLController = Em.Object.extend( } case 'ScrollableMessage': { - SDL.ScrollableMessage.deactivate(true); + SDL.ScrollableMessage.deactivate(); this.onActivateSDLApp(element); break; } diff --git a/app/model/sdl/Abstract/Model.js b/app/model/sdl/Abstract/Model.js index b07a69f9b..8cac96e83 100644 --- a/app/model/sdl/Abstract/Model.js +++ b/app/model/sdl/Abstract/Model.js @@ -1053,7 +1053,7 @@ SDL.SDLModel = Em.Object.extend({ ); SDL.ResetTimeoutPopUp.addRpc( request, - () => {SDL.ScrollableMessage.deactivate();}, + () => {SDL.ScrollableMessage.deactivate(false, true);}, SDL.ScrollableMessage.resetTimeoutCallback, request.params.timeout ); diff --git a/app/view/sdl/shared/scrollableMessage.js b/app/view/sdl/shared/scrollableMessage.js index 11fc7c9dc..518bb5686 100644 --- a/app/view/sdl/shared/scrollableMessage.js +++ b/app/view/sdl/shared/scrollableMessage.js @@ -62,14 +62,16 @@ SDL.ScrollableMessage = SDL.SDLAbstractView.create( * @param {Object} ABORTED Parameter to indicate status for * UI.ScrollableMessageResponse */ - deactivate: function(ABORTED) { + deactivate: function(ABORTED, timeout=false) { this.set('endTime', null); this.set('active', false); this.softButtons.set('page', 0); + if (timeout === false) { + SDL.ResetTimeoutPopUp.stopRpcProcessing('UI.ScrollableMessage'); + } let calculate_result_code = function(areAllImagesValid) { if (ABORTED) { - SDL.ResetTimeoutPopUp.stopRpcProcessing('UI.ScrollableMessage'); return SDL.SDLModel.data.resultCode.ABORTED; }