diff options
author | beccabroek <beccabroek@gmail.com> | 2018-09-04 09:34:44 -0500 |
---|---|---|
committer | Gunnar Mills <gmills@us.ibm.com> | 2018-09-10 20:45:53 +0000 |
commit | 75697f909f1d0e1a2e2f575b680040650a0b60d9 (patch) | |
tree | 8e31e6078b785c120a24ebf5dd98cc9ad794e8f6 /app/server-control/controllers/remote-console-window-controller.js | |
parent | 500ad789ff4f01d25b4c5e8d64c957024f704645 (diff) | |
download | phosphor-webui-75697f909f1d0e1a2e2f575b680040650a0b60d9.tar.gz phosphor-webui-75697f909f1d0e1a2e2f575b680040650a0b60d9.zip |
Create SOL console directive
Created serial-console directive in order to avoid
duplicate code between remote-console-controller
and remote-console-window-controller.
Tested: Verified that SOL console functions as
expected after refactor
Change-Id: I8cfc8e78cc2325c813e5bef608886859df6b3ab8
Signed-off-by: beccabroek <beccabroek@gmail.com>
Diffstat (limited to 'app/server-control/controllers/remote-console-window-controller.js')
-rw-r--r-- | app/server-control/controllers/remote-console-window-controller.js | 38 |
1 files changed, 3 insertions, 35 deletions
diff --git a/app/server-control/controllers/remote-console-window-controller.js b/app/server-control/controllers/remote-console-window-controller.js index 8081972..01874d6 100644 --- a/app/server-control/controllers/remote-console-window-controller.js +++ b/app/server-control/controllers/remote-console-window-controller.js @@ -11,45 +11,13 @@ window.angular && (function(angular) { angular.module('app.serverControl') .controller('remoteConsoleWindowController', [ - '$scope', '$window', 'APIUtils', 'dataService', - function($scope, $window, APIUtils, dataService) { + '$scope', '$window', 'dataService', + function($scope, $window, dataService) { $scope.dataService = dataService; dataService.showNavigation = false; - - // See https://github.com/macton/hterm for available hterm options - - // Storage - hterm.defaultStorage = new lib.Storage.Local(); - - var term = new hterm.Terminal('foo'); - term.onTerminalReady = function() { - var io = term.io.push(); - io.onVTKeystroke = function(str) { - console.log(str); - term.io.print(str); - }; - io.sendString = function(str) { - console.log(str); - }; - }; - term.decorate(document.querySelector('#terminal')); - - // Set cursor color - term.prefs_.set('cursor-color', 'rgba(83, 146, 255, .5)'); - - // Set background color - term.prefs_.set('background-color', '#19273c'); - - // Print to console window - term.io.println('OpenBMC ver.00'); - term.io.println('This is not an actual live connection.'); - term.io.print('root@IBM:'); - - // Allows keyboard input - term.installKeyboard(); + dataService.bodyStyle = {'background': 'white'}; $scope.close = function() { - dataService.setRemoteWindowInactive(); $window.close(); }; } |