Skip to content

Commit

Permalink
Merge 1.5.5 changes back to master.
Browse files Browse the repository at this point in the history
  • Loading branch information
mike-jumper committed Jan 3, 2024
2 parents 212955c + f23b667 commit beb09e6
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -487,6 +487,18 @@ angular.module('client').controller('clientController', ['$scope', '$routeParams

});

// Automatically update connection parameters that have been modified
// for the current focused client
$scope.$on('guacClientArgumentsUpdated', function focusedClientChanged(event, focusedClient) {

// Update available connection parameters, if the updated arguments are
// for the current focused client - otherwise ignore them
if ($scope.focusedClient && $scope.focusedClient === focusedClient)
$scope.menu.connectionParameters = focusedClient ?
ManagedClient.getArgumentModel(focusedClient) : {};

});

// Update page icon when thumbnail changes
$scope.$watch('focusedClient.thumbnail.canvas', function thumbnailChanged(canvas) {
iconService.setIcons(canvas);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,11 @@ angular.module('client').directive('guacTiledClients', [function guacTiledClient
$scope.$emit('guacClientFocused', focusedClient);
});

// Notify whenever arguments of currently-focused client changes
$scope.$watch('getFocusedClient().arguments', function focusedClientParametersChanged() {
$scope.$emit('guacClientArgumentsUpdated', $scope.getFocusedClient());
}, true);

/**
* Returns a callback for guacClick that assigns or updates keyboard
* focus to the given client, allowing that client to receive and
Expand Down

0 comments on commit beb09e6

Please sign in to comment.