Move input-related files into core/input
This commit moves all the input-related files from `core/` to `core/input/`, and renames a couple as relevant (input.js --> input/devices.js, keyboard.js --> input/util.js).
This commit is contained in:
parent
b4ef49ea36
commit
bd5340c7ee
|
@ -8,8 +8,8 @@ is not limited to):
|
|||
core/base64.js
|
||||
core/des.js
|
||||
core/display.js
|
||||
core/input.js
|
||||
core/keysym.js
|
||||
core/input/devices.js
|
||||
core/input/keysym.js
|
||||
core/logo.js
|
||||
core/playback.js
|
||||
core/rfb.js
|
||||
|
@ -17,7 +17,7 @@ is not limited to):
|
|||
core/util.js
|
||||
core/websock.js
|
||||
app/webutil.js
|
||||
core/xtscancodes.js
|
||||
core/input/xtscancodes.js
|
||||
|
||||
The HTML, CSS, font and images files that included with the noVNC
|
||||
source distibution (or repository) are not considered part of the
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
|
||||
/* [module]
|
||||
* import Util from "../core/util";
|
||||
* import KeyTable from "../core/keysym";
|
||||
* import KeyTable from "../core/input/keysym";
|
||||
* import RFB from "../core/rfb";
|
||||
* import Display from "../core/display";
|
||||
* import WebUtil from "./webutil";
|
||||
|
@ -26,9 +26,9 @@ var UI;
|
|||
/* [begin skip-as-module] */
|
||||
// Load supporting scripts
|
||||
WebUtil.load_scripts(
|
||||
{'core': ["base64.js", "websock.js", "des.js", "keysymdef.js",
|
||||
"xtscancodes.js", "keyboard.js", "input.js", "display.js",
|
||||
"inflator.js", "rfb.js", "keysym.js"]});
|
||||
{'core': ["base64.js", "websock.js", "des.js", "input/keysymdef.js",
|
||||
"input/xtscancodes.js", "input/util.js", "input/devices.js",
|
||||
"display.js", "inflator.js", "rfb.js", "input/keysym.js"]});
|
||||
|
||||
window.onscriptsload = function () { UI.load(); };
|
||||
/* [end skip-as-module] */
|
||||
|
|
|
@ -9,8 +9,8 @@
|
|||
/*global window, Util */
|
||||
|
||||
/* [module]
|
||||
* import Util from "./util";
|
||||
* import KeyboardUtil from "./keyboard";
|
||||
* import Util from "../util";
|
||||
* import KeyboardUtil from "./util";
|
||||
*/
|
||||
|
||||
/* [module] export */ var Keyboard;
|
|
@ -13,12 +13,12 @@
|
|||
/* [module]
|
||||
* import Util from "./util";
|
||||
* import Display from "./display";
|
||||
* import { Keyboard, Mouse } from "./input"
|
||||
* import { Keyboard, Mouse } from "./input/devices"
|
||||
* import Websock from "./websock"
|
||||
* import Base64 from "./base64";
|
||||
* import DES from "./des";
|
||||
* import KeyTable from "./keysym";
|
||||
* import XtScancode from "./xtscancodes";
|
||||
* import KeyTable from "./input/keysym";
|
||||
* import XtScancode from "./input/xtscancodes";
|
||||
* import Inflator from "./inflator.mod";
|
||||
*/
|
||||
/*jslint white: false, browser: true */
|
||||
|
|
|
@ -113,11 +113,11 @@ module.exports = function(config) {
|
|||
'core/util.js', // load first to avoid issues, since methods are called immediately
|
||||
//'../core/*.js',
|
||||
'core/base64.js',
|
||||
'core/keysym.js',
|
||||
'core/keysymdef.js',
|
||||
'core/xtscancodes.js',
|
||||
'core/keyboard.js',
|
||||
'core/input.js',
|
||||
'core/input/keysym.js',
|
||||
'core/input/keysymdef.js',
|
||||
'core/input/xtscancodes.js',
|
||||
'core/input/util.js',
|
||||
'core/input/devices.js',
|
||||
'core/websock.js',
|
||||
'core/rfb.js',
|
||||
'core/des.js',
|
||||
|
|
|
@ -26,11 +26,11 @@
|
|||
<script src="../core/util.js"></script>
|
||||
<script src="../app/webutil.js"></script>
|
||||
<script src="../core/base64.js"></script>
|
||||
<script src="../core/keysym.js"></script>
|
||||
<script src="../core/keysymdef.js"></script>
|
||||
<script src="../core/xtscancodes.js"></script>
|
||||
<script src="../core/keyboard.js"></script>
|
||||
<script src="../core/input.js"></script>
|
||||
<script src="../core/input/keysym.js"></script>
|
||||
<script src="../core/input/keysymdef.js"></script>
|
||||
<script src="../core/input/xtscancodes.js"></script>
|
||||
<script src="../core/input/util.js"></script>
|
||||
<script src="../core/input/devices.js"></script>
|
||||
<script src="../core/display.js"></script>
|
||||
<script>
|
||||
var msg_cnt = 0, iterations,
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
// requires local modules: keysym, keysymdef, keyboard
|
||||
// requires local modules: input/keysym, input/keysymdef, input/util
|
||||
|
||||
var assert = chai.assert;
|
||||
var expect = chai.expect;
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
// requires local modules: input, keyboard, keysymdef, keysym
|
||||
// requires local modules: input/devices, input/util, input/keysymdef, input/keysym
|
||||
var assert = chai.assert;
|
||||
var expect = chai.expect;
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
// requires local modules: util, websock, rfb, keyboard, keysym, keysymdef, input, inflator, des, display
|
||||
// requires local modules: util, websock, rfb, input/util, input/keysym, input/keysymdef, input/devices, inflator, des, display
|
||||
// requires test modules: fake.websocket, assertions
|
||||
/* jshint expr: true */
|
||||
var assert = chai.assert;
|
||||
|
|
|
@ -50,9 +50,9 @@
|
|||
|
||||
// Load supporting scripts
|
||||
WebUtil.load_scripts({
|
||||
'core': ["base64.js", "websock.js", "des.js", "keysym.js",
|
||||
"keysymdef.js", "xtscancodes.js", "keyboard.js",
|
||||
"input.js", "display.js", "rfb.js", "inflator.js"],
|
||||
'core': ["base64.js", "websock.js", "des.js", "input/keysym.js",
|
||||
"input/keysymdef.js", "input/xtscancodes.js", "input/util.js",
|
||||
"input/devices.js", "display.js", "rfb.js", "inflator.js"],
|
||||
'tests': ["playback.js"],
|
||||
'recordings': [fname]});
|
||||
} else {
|
||||
|
|
|
@ -60,9 +60,9 @@
|
|||
message("Loading " + fname);
|
||||
// Load supporting scripts
|
||||
WebUtil.load_scripts({
|
||||
'core': ["base64.js", "websock.js", "des.js", "keysym.js",
|
||||
"keysymdef.js", "xtscancodes.js", "keyboard.js",
|
||||
"input.js", "display.js", "rfb.js", "inflator.js"],
|
||||
'core': ["base64.js", "websock.js", "des.js", "input/keysym.js",
|
||||
"input/keysymdef.js", "input/xtscancodes.js", "input/util.js",
|
||||
"input/devices.js", "display.js", "rfb.js", "inflator.js"],
|
||||
'tests': ["playback.js"],
|
||||
'recordings': [fname]});
|
||||
|
||||
|
|
|
@ -96,7 +96,8 @@ var make_lib_files = function (use_require) {
|
|||
var b = make_browserify(rfb_file, {});
|
||||
b.on('transform', function (tr, file) {
|
||||
if (tr._is_make_module) {
|
||||
var new_path = path.join(lib_dir_base, path.basename(file));
|
||||
var new_path = path.join(lib_dir_base, path.relative(core_path, file));
|
||||
fse.ensureDir(path.dirname(new_path));
|
||||
console.log("Writing " + new_path)
|
||||
var fileStream = fs.createWriteStream(new_path);
|
||||
|
||||
|
|
|
@ -79,9 +79,9 @@
|
|||
|
||||
// Load supporting scripts
|
||||
WebUtil.load_scripts({
|
||||
'core': ["base64.js", "websock.js", "des.js", "keysymdef.js",
|
||||
"xtscancodes.js", "keyboard.js", "input.js", "display.js",
|
||||
"inflator.js", "rfb.js", "keysym.js"],
|
||||
'core': ["base64.js", "websock.js", "des.js", "input/keysymdef.js",
|
||||
"input/xtscancodes.js", "input/util.js", "input/devices.js",
|
||||
"display.js", "inflator.js", "rfb.js", "input/keysym.js"],
|
||||
'app': ["webutil.js"]});
|
||||
|
||||
var rfb;
|
||||
|
|
Loading…
Reference in New Issue