mirror of
https://github.com/gyurix1968/guacamole-client.git
synced 2025-09-06 13:17:41 +00:00
GUAC-1053: Add constants for each input method type.
This commit is contained in:
@@ -192,8 +192,8 @@ angular.module('client').controller('clientController', ['$scope', '$routeParams
|
||||
autoFit : true,
|
||||
|
||||
/**
|
||||
* The currently selected input method. This may be either "none",
|
||||
* "osk", or "text".
|
||||
* The currently selected input method. This may be any of the values
|
||||
* defined within preferenceService.inputMethods.
|
||||
*
|
||||
* @type String
|
||||
*/
|
||||
|
@@ -36,6 +36,43 @@ angular.module('settings').factory('preferenceService', ['$injector',
|
||||
// The parameter name for getting the history from local storage
|
||||
var GUAC_PREFERENCES_STORAGE_KEY = "GUAC_PREFERENCES";
|
||||
|
||||
/**
|
||||
* All valid input method type names.
|
||||
*
|
||||
* @type Object.<String, String>
|
||||
*/
|
||||
service.inputMethods = {
|
||||
|
||||
/**
|
||||
* No input method is used. Keyboard events are generated from a
|
||||
* physical keyboard.
|
||||
*
|
||||
* @constant
|
||||
* @type String
|
||||
*/
|
||||
NONE : 'none',
|
||||
|
||||
/**
|
||||
* Keyboard events will be generated from the Guacamole on-screen
|
||||
* keyboard.
|
||||
*
|
||||
* @constant
|
||||
* @type String
|
||||
*/
|
||||
OSK : 'osk',
|
||||
|
||||
/**
|
||||
* Keyboard events will be generated by inferring the keys necessary to
|
||||
* produce typed text from an IME (Input Method Editor) such as the
|
||||
* native on-screen keyboard of a mobile device.
|
||||
*
|
||||
* @constant
|
||||
* @type String
|
||||
*/
|
||||
TEXT : 'text'
|
||||
|
||||
};
|
||||
|
||||
/**
|
||||
* All currently-set preferences, as name/value pairs. Each property name
|
||||
* corresponds to the name of a preference.
|
||||
@@ -53,12 +90,12 @@ angular.module('settings').factory('preferenceService', ['$injector',
|
||||
emulateAbsoluteMouse : true,
|
||||
|
||||
/**
|
||||
* The default input method. This may be either "none", "osk", or
|
||||
* "text".
|
||||
* The default input method. This may be any of the values defined
|
||||
* within preferenceService.inputMethods.
|
||||
*
|
||||
* @type String
|
||||
*/
|
||||
inputMethod : 'none'
|
||||
inputMethod : service.inputMethods.NONE
|
||||
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user