mirror of
https://github.com/gyurix1968/guacamole-client.git
synced 2025-09-06 21:27:40 +00:00
GUACAMOLE-462: Declare variables with "const" where appropriate.
This commit is contained in:
@@ -29,7 +29,7 @@ angular.module('index').filter('resolve', [function resolveFilter() {
|
|||||||
*
|
*
|
||||||
* @type {!string}
|
* @type {!string}
|
||||||
*/
|
*/
|
||||||
var RESOLVED_VALUE_KEY = '_guac_resolveFilter_resolvedValue';
|
const RESOLVED_VALUE_KEY = '_guac_resolveFilter_resolvedValue';
|
||||||
|
|
||||||
return function resolveFilter(promise) {
|
return function resolveFilter(promise) {
|
||||||
|
|
||||||
|
@@ -77,7 +77,7 @@
|
|||||||
*/
|
*/
|
||||||
angular.module('player').directive('guacPlayer', ['$injector', function guacPlayer($injector) {
|
angular.module('player').directive('guacPlayer', ['$injector', function guacPlayer($injector) {
|
||||||
|
|
||||||
var config = {
|
const config = {
|
||||||
restrict : 'E',
|
restrict : 'E',
|
||||||
templateUrl : 'app/player/templates/player.html'
|
templateUrl : 'app/player/templates/player.html'
|
||||||
};
|
};
|
||||||
@@ -172,7 +172,7 @@ angular.module('player').directive('guacPlayer', ['$injector', function guacPlay
|
|||||||
* The decimal string representation of the given value, padded
|
* The decimal string representation of the given value, padded
|
||||||
* with leading zeroes up to a minimum length of two digits.
|
* with leading zeroes up to a minimum length of two digits.
|
||||||
*/
|
*/
|
||||||
var zeroPad = function zeroPad(value) {
|
const zeroPad = function zeroPad(value) {
|
||||||
return value > 9 ? value : '0' + value;
|
return value > 9 ? value : '0' + value;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@@ -50,7 +50,7 @@
|
|||||||
*/
|
*/
|
||||||
angular.module('player').directive('guacPlayerDisplay', [function guacPlayerDisplay() {
|
angular.module('player').directive('guacPlayerDisplay', [function guacPlayerDisplay() {
|
||||||
|
|
||||||
var config = {
|
const config = {
|
||||||
restrict : 'E',
|
restrict : 'E',
|
||||||
templateUrl : 'app/player/templates/playerDisplay.html'
|
templateUrl : 'app/player/templates/playerDisplay.html'
|
||||||
};
|
};
|
||||||
@@ -75,7 +75,7 @@ angular.module('player').directive('guacPlayerDisplay', [function guacPlayerDisp
|
|||||||
*
|
*
|
||||||
* @type {Element}
|
* @type {Element}
|
||||||
*/
|
*/
|
||||||
var element = $element.find('.guac-player-display')[0];
|
const element = $element.find('.guac-player-display')[0];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The element which serves as a container for the root element of the
|
* The element which serves as a container for the root element of the
|
||||||
@@ -83,7 +83,7 @@ angular.module('player').directive('guacPlayerDisplay', [function guacPlayerDisp
|
|||||||
*
|
*
|
||||||
* @type {HTMLDivElement}
|
* @type {HTMLDivElement}
|
||||||
*/
|
*/
|
||||||
var container = $element.find('.guac-player-display-container')[0];
|
const container = $element.find('.guac-player-display-container')[0];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Rescales the Guacamole.Display currently assigned to $scope.display
|
* Rescales the Guacamole.Display currently assigned to $scope.display
|
||||||
|
@@ -50,7 +50,7 @@
|
|||||||
*/
|
*/
|
||||||
angular.module('player').directive('guacPlayerProgressIndicator', [function guacPlayerProgressIndicator() {
|
angular.module('player').directive('guacPlayerProgressIndicator', [function guacPlayerProgressIndicator() {
|
||||||
|
|
||||||
var config = {
|
const config = {
|
||||||
restrict : 'E',
|
restrict : 'E',
|
||||||
templateUrl : 'app/player/templates/progressIndicator.html'
|
templateUrl : 'app/player/templates/progressIndicator.html'
|
||||||
};
|
};
|
||||||
|
@@ -24,8 +24,8 @@ angular.module('manage').controller('connectionHistoryPlayerController', ['$scop
|
|||||||
function connectionHistoryPlayerController($scope, $injector) {
|
function connectionHistoryPlayerController($scope, $injector) {
|
||||||
|
|
||||||
// Required services
|
// Required services
|
||||||
var authenticationService = $injector.get('authenticationService');
|
const authenticationService = $injector.get('authenticationService');
|
||||||
var $routeParams = $injector.get('$routeParams');
|
const $routeParams = $injector.get('$routeParams');
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The URL of the REST API resource exposing the requested session
|
* The URL of the REST API resource exposing the requested session
|
||||||
@@ -33,7 +33,7 @@ angular.module('manage').controller('connectionHistoryPlayerController', ['$scop
|
|||||||
*
|
*
|
||||||
* @type {!string}
|
* @type {!string}
|
||||||
*/
|
*/
|
||||||
var recordingURL = 'api/session/data/' + encodeURIComponent($routeParams.dataSource)
|
const recordingURL = 'api/session/data/' + encodeURIComponent($routeParams.dataSource)
|
||||||
+ '/history/connections/' + encodeURIComponent($routeParams.identifier)
|
+ '/history/connections/' + encodeURIComponent($routeParams.identifier)
|
||||||
+ '/logs/' + encodeURIComponent($routeParams.name);
|
+ '/logs/' + encodeURIComponent($routeParams.name);
|
||||||
|
|
||||||
|
@@ -24,11 +24,11 @@ angular.module('settings').factory('ConnectionHistoryEntryWrapper', ['$injector'
|
|||||||
function defineConnectionHistoryEntryWrapper($injector) {
|
function defineConnectionHistoryEntryWrapper($injector) {
|
||||||
|
|
||||||
// Required types
|
// Required types
|
||||||
var ActivityLog = $injector.get('ActivityLog');
|
const ActivityLog = $injector.get('ActivityLog');
|
||||||
var ConnectionHistoryEntry = $injector.get('ConnectionHistoryEntry');
|
const ConnectionHistoryEntry = $injector.get('ConnectionHistoryEntry');
|
||||||
|
|
||||||
// Required services
|
// Required services
|
||||||
var $translate = $injector.get('$translate');
|
const $translate = $injector.get('$translate');
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Wrapper for ConnectionHistoryEntry which adds display-specific
|
* Wrapper for ConnectionHistoryEntry which adds display-specific
|
||||||
@@ -38,7 +38,7 @@ angular.module('settings').factory('ConnectionHistoryEntryWrapper', ['$injector'
|
|||||||
* @param {ConnectionHistoryEntry} historyEntry
|
* @param {ConnectionHistoryEntry} historyEntry
|
||||||
* The ConnectionHistoryEntry that should be wrapped.
|
* The ConnectionHistoryEntry that should be wrapped.
|
||||||
*/
|
*/
|
||||||
var ConnectionHistoryEntryWrapper = function ConnectionHistoryEntryWrapper(dataSource, historyEntry) {
|
const ConnectionHistoryEntryWrapper = function ConnectionHistoryEntryWrapper(dataSource, historyEntry) {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The wrapped ConnectionHistoryEntry.
|
* The wrapped ConnectionHistoryEntry.
|
||||||
|
Reference in New Issue
Block a user