diff --git a/guacamole/src/main/webapp/app/client/styles/client.css b/guacamole/src/main/webapp/app/client/styles/client.css index e45a41133..ef656c883 100644 --- a/guacamole/src/main/webapp/app/client/styles/client.css +++ b/guacamole/src/main/webapp/app/client/styles/client.css @@ -20,7 +20,7 @@ * THE SOFTWARE. */ -body { +body.client { background: black; font-family: FreeSans, Helvetica, Arial, sans-serif; padding: 0; diff --git a/guacamole/src/main/webapp/app/index/config/indexRouteConfig.js b/guacamole/src/main/webapp/app/index/config/indexRouteConfig.js index 8f2c9c8d7..db16fc1dc 100644 --- a/guacamole/src/main/webapp/app/index/config/indexRouteConfig.js +++ b/guacamole/src/main/webapp/app/index/config/indexRouteConfig.js @@ -32,20 +32,24 @@ angular.module('index').config(['$routeProvider', '$locationProvider', $routeProvider. when('/', { title: 'application.title', + bodyClassName: 'home', templateUrl: 'app/home/templates/home.html', controller: 'homeController' }). when('/manage/', { title: 'application.title', + bodyClassName: 'manage', templateUrl: 'app/manage/templates/manage.html', controller: 'manageController' }). when('/login/', { title: 'application.title', + bodyClassName: 'login', templateUrl: 'app/login/templates/login.html', controller: 'loginController' }). when('/client/:type/:id/:params?', { + bodyClassName: 'client', templateUrl: 'app/client/templates/client.html', controller: 'clientController' }). diff --git a/guacamole/src/main/webapp/app/index/controllers/indexController.js b/guacamole/src/main/webapp/app/index/controllers/indexController.js index 10380deb1..35101d2bf 100644 --- a/guacamole/src/main/webapp/app/index/controllers/indexController.js +++ b/guacamole/src/main/webapp/app/index/controllers/indexController.js @@ -51,7 +51,10 @@ angular.module('index').controller('indexController', ['$scope', '$injector', }; // Put some useful variables in the top level scope - $scope.page = { title: '' }; + $scope.page = { + title: '', + bodyClassName: '' + }; $scope.currentUserID = null; $scope.currentUserIsAdmin = false; $scope.currentUserHasUpdate = false; @@ -106,11 +109,15 @@ angular.module('index').controller('indexController', ['$scope', '$injector', keyboard.reset(); }; - // Update title upon navigation + // Update title and CSS class upon navigation $scope.$on('$routeChangeSuccess', function(event, current, previous) { + var title = current.$$route.title; if (title) $scope.page.title = title; + + $scope.page.bodyClassName = current.$$route.bodyClassName || ''; + }); }]); diff --git a/guacamole/src/main/webapp/index.html b/guacamole/src/main/webapp/index.html index 917928f4c..44d0e5e2f 100644 --- a/guacamole/src/main/webapp/index.html +++ b/guacamole/src/main/webapp/index.html @@ -29,7 +29,7 @@ THE SOFTWARE. - +