@qooxdoo/framework 7.0.0 → 7.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +10 -2
- package/Manifest.json +22 -22
- package/README.md +2 -4
- package/lib/compiler/compile-info.json +60 -58
- package/lib/compiler/index.js +1973 -1625
- package/lib/resource/qx/tool/cli/templates/loader/loader-browser.tmpl.js +1 -2
- package/lib/resource/qx/tool/schema/compile-1-0-0.json +11 -1
- package/npm-shrinkwrap.json +1738 -788
- package/package.json +10 -8
- package/source/class/qx/Interface.js +13 -15
- package/source/class/qx/dev/unit/MTestLoader.js +25 -33
- package/source/class/qx/dev/unit/TestResult.js +9 -13
- package/source/class/qx/event/handler/Focus.js +1 -1
- package/source/class/qx/html/Element.js +1 -1
- package/source/class/qx/html/Node.js +0 -1
- package/source/class/qx/io/request/AbstractRequest.js +42 -66
- package/source/class/qx/test/Interface.js +70 -6
- package/source/class/qx/test/Mixin.js +20 -17
- package/source/class/qx/test/Promise.js +67 -91
- package/source/class/qx/test/bom/History.js +11 -19
- package/source/class/qx/test/bom/WebWorker.js +7 -15
- package/source/class/qx/test/bom/media/MediaTestCase.js +10 -18
- package/source/class/qx/test/bom/media/Video.js +10 -18
- package/source/class/qx/test/bom/rest/Resource.js +3 -7
- package/source/class/qx/test/bom/rest/ResourceWithRemote.js +40 -56
- package/source/class/qx/test/bom/webfonts/Validator.js +12 -20
- package/source/class/qx/test/core/Object.js +3 -7
- package/source/class/qx/test/data/controller/List.js +18 -22
- package/source/class/qx/test/data/marshal/Json.js +10 -14
- package/source/class/qx/test/data/store/Json.js +337 -428
- package/source/class/qx/test/data/store/Jsonp.js +46 -66
- package/source/class/qx/test/data/store/RestWithRemote.js +10 -18
- package/source/class/qx/test/html/Element.js +4 -8
- package/source/class/qx/test/html/Iframe.js +48 -60
- package/source/class/qx/test/io/jsonrpc/Client.js +1 -1
- package/source/class/qx/test/io/request/JsonpWithRemote.js +6 -10
- package/source/class/qx/test/io/request/MRequest.js +13 -25
- package/source/class/qx/test/io/request/Xhr.js +5 -9
- package/source/class/qx/test/io/request/XhrWithRemote.js +50 -78
- package/source/class/qx/test/io/rest/Resource.js +3 -7
- package/source/class/qx/test/io/rest/ResourceWithRemote.js +41 -57
- package/source/class/qx/test/mobile/basic/Image.js +16 -24
- package/source/class/qx/test/mobile/container/Navigation.js +3 -7
- package/source/class/qx/test/mobile/container/Scroll.js +8 -12
- package/source/class/qx/test/mobile/page/Page.js +24 -44
- package/source/class/qx/test/performance/Property.js +2 -2
- package/source/class/qx/test/ui/basic/Image.js +32 -52
- package/source/class/qx/test/ui/core/Blocker.js +6 -14
- package/source/class/qx/test/ui/embed/Iframe.js +13 -21
- package/source/class/qx/test/ui/form/FileSelectorButton.js +32 -0
- package/source/class/qx/test/ui/form/FormValidator.js +147 -211
- package/source/class/qx/test/ui/form/Label.js +8 -16
- package/source/class/qx/test/ui/root/Inline.js +9 -13
- package/source/class/qx/test/ui/table/Table.js +6 -14
- package/source/class/qx/test/ui/toolbar/OverflowHandling.js +18 -30
- package/source/class/qx/test/ui/virtual/Pane.js +3 -7
- package/source/class/qx/test/util/DynamicScriptLoader.js +23 -42
- package/source/class/qx/theme/iconfont/LoadMaterialIcons.js +4 -4
- package/source/class/qx/theme/iconfont/LoadMaterialIconsOutlined.js +4 -4
- package/source/class/qx/theme/iconfont/LoadMaterialIconsRound.js +4 -4
- package/source/class/qx/theme/iconfont/LoadMaterialIconsSharp.js +4 -4
- package/source/class/qx/theme/iconfont/LoadMaterialIconsTwoTone.js +4 -4
- package/source/class/qx/theme/tangible/Appearance.js +22 -3
- package/source/class/qx/theme/tangible/ColorEngine.js +3 -3
- package/source/class/qx/theme/tangible/Decoration.js +3 -3
- package/source/class/qx/tool/cli/Watch.js +3 -7
- package/source/class/qx/tool/cli/api/AbstractApi.js +4 -1
- package/source/class/qx/tool/cli/api/CompilerApi.js +3 -7
- package/source/class/qx/tool/cli/commands/Compile.js +10 -1
- package/source/class/qx/tool/cli/commands/Lint.js +35 -21
- package/source/class/qx/tool/compiler/ClassFile.js +82 -2
- package/source/class/qx/tool/compiler/Es6ify.js +12 -5
- package/source/class/qx/tool/compiler/TargetError.js +26 -0
- package/source/class/qx/tool/compiler/app/Application.js +14 -0
- package/source/class/qx/tool/compiler/app/WebFont.js +8 -6
- package/source/class/qx/tool/compiler/targets/SourceCodeCopier.js +1 -1
- package/source/class/qx/tool/compiler/targets/Target.js +8 -0
- package/source/class/qx/tool/compiler/targets/meta/AbstractJavascriptMeta.js +2 -2
- package/source/class/qx/tool/compiler/targets/meta/Browserify.js +179 -0
- package/source/class/qx/tool/compiler/targets/meta/Uglify.js +11 -3
- package/source/class/qx/tool/utils/Json.js +1 -1
- package/source/class/qx/tool/utils/Website.js +2 -2
- package/source/class/qx/ui/basic/Label.js +13 -17
- package/source/class/qx/ui/core/MPlacement.js +13 -21
- package/source/class/qx/ui/core/Widget.js +2 -3
- package/source/class/qx/ui/core/scroll/NativeScrollBar.js +3 -7
- package/source/class/qx/ui/core/scroll/ScrollBar.js +3 -7
- package/source/class/qx/ui/embed/Iframe.js +40 -50
- package/source/class/qx/ui/form/AbstractField.js +8 -12
- package/source/class/qx/ui/form/AbstractSelectBox.js +4 -1
- package/source/class/qx/ui/form/ComboBox.js +7 -15
- package/source/class/qx/ui/form/DateField.js +13 -19
- package/source/class/qx/ui/form/FileSelectorButton.js +157 -0
- package/source/class/qx/ui/form/Spinner.js +7 -15
- package/source/class/qx/ui/form/TextArea.js +3 -7
- package/source/class/qx/ui/form/VirtualComboBox.js +8 -16
- package/source/class/qx/ui/form/VirtualSelectBox.js +21 -37
- package/source/class/qx/ui/layout/Canvas.js +2 -2
- package/source/class/qx/ui/mobile/container/MIScroll.js +3 -7
- package/source/class/qx/ui/progressive/headfoot/Progress.js +22 -34
- package/source/class/qx/ui/progressive/renderer/table/Row.js +2 -1
- package/source/class/qx/ui/progressive/renderer/table/cell/Boolean.js +24 -26
- package/source/class/qx/ui/progressive/renderer/table/cell/Icon.js +9 -7
- package/source/class/qx/ui/progressive/renderer/table/cell/Image.js +16 -13
- package/source/class/qx/ui/splitpane/Pane.js +14 -22
- package/source/class/qx/ui/table/MTableContextMenu.js +63 -71
- package/source/class/qx/ui/table/Table.js +3 -8
- package/source/class/qx/ui/table/model/Abstract.js +34 -1
- package/source/class/qx/ui/table/model/Remote.js +1 -0
- package/source/class/qx/ui/table/model/Simple.js +3 -0
- package/source/class/qx/ui/table/pane/Scroller.js +8 -12
- package/source/class/qx/ui/toolbar/FileSelectorButton.js +57 -0
- package/source/class/qx/ui/toolbar/Part.js +3 -7
- package/source/class/qx/ui/tree/VirtualTree.js +5 -9
- package/source/class/qx/ui/treevirtual/MNode.js +62 -5
- package/source/class/qx/ui/treevirtual/SimpleTreeDataModel.js +11 -3
- package/source/class/qx/ui/treevirtual/TreeVirtual.js +3 -7
- package/source/class/qx/ui/virtual/core/Pane.js +30 -42
- package/source/class/qx/util/DynamicScriptLoader.js +31 -43
- package/source/resource/qx/iconfont/MaterialIcons/materialicons-v126.eot +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/{materialicons-v70.ttf → materialicons-v126.ttf} +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialicons-v126.woff +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialicons-v126.woff2 +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconsoutlined-v101.eot +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconsoutlined-v101.otf +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconsoutlined-v101.woff +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconsoutlined-v101.woff2 +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconsround-v100.eot +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconsround-v100.otf +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconsround-v100.woff +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconsround-v100.woff2 +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconssharp-v101.eot +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconssharp-v101.otf +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconssharp-v101.woff +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconssharp-v101.woff2 +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconstwotone-v104.eot +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconstwotone-v104.otf +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconstwotone-v104.woff +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconstwotone-v104.woff2 +0 -0
- package/source/resource/qx/tool/cli/templates/loader/loader-browser.tmpl.js +1 -2
- package/source/resource/qx/tool/schema/compile-1-0-0.json +11 -1
- package/source/resource/qx/iconfont/MaterialIcons/materialicons-v70.eot +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialicons-v70.woff +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialicons-v70.woff2 +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconsoutlined-v38.eot +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconsoutlined-v38.otf +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconsoutlined-v38.woff +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconsoutlined-v38.woff2 +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconsround-v37.eot +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconsround-v37.otf +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconsround-v37.woff +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconsround-v37.woff2 +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconssharp-v38.eot +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconssharp-v38.otf +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconssharp-v38.woff +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconssharp-v38.woff2 +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconstwotone-v36.eot +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconstwotone-v36.otf +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconstwotone-v36.woff +0 -0
- package/source/resource/qx/iconfont/MaterialIcons/materialiconstwotone-v36.woff2 +0 -0
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/* ************************************************************************
|
|
2
|
+
*
|
|
3
|
+
* qooxdoo-compiler - node.js based replacement for the Qooxdoo python
|
|
4
|
+
* toolchain
|
|
5
|
+
*
|
|
6
|
+
* https://github.com/qooxdoo/qooxdoo-compiler
|
|
7
|
+
*
|
|
8
|
+
* Copyright:
|
|
9
|
+
* 3033 Derrell Lipman
|
|
10
|
+
*
|
|
11
|
+
* License:
|
|
12
|
+
* MIT: https://opensource.org/licenses/MIT
|
|
13
|
+
*
|
|
14
|
+
* This software is provided under the same licensing terms as Qooxdoo,
|
|
15
|
+
* please see the LICENSE file in the Qooxdoo project's top-level directory
|
|
16
|
+
* for details.
|
|
17
|
+
*
|
|
18
|
+
* Authors:
|
|
19
|
+
* * Derrell Lipman (@derrell)
|
|
20
|
+
*
|
|
21
|
+
* ************************************************************************/
|
|
22
|
+
|
|
23
|
+
qx.Class.define("qx.tool.compiler.TargetError", {
|
|
24
|
+
// extend : qx.type.BaseError
|
|
25
|
+
extend: Error
|
|
26
|
+
});
|
|
@@ -217,6 +217,20 @@ qx.Class.define("qx.tool.compiler.app.Application", {
|
|
|
217
217
|
writeIndexHtmlToRoot: {
|
|
218
218
|
init: false,
|
|
219
219
|
check: "Boolean"
|
|
220
|
+
},
|
|
221
|
+
|
|
222
|
+
/**
|
|
223
|
+
* Map specifying local modules to include in the build. Local modules are
|
|
224
|
+
* always included in the compiled output, regardless of application type
|
|
225
|
+
* (node, browser, etc.). Each member of the map has a key that is the
|
|
226
|
+
* name of the module to be `require`d in code. The value is the path to
|
|
227
|
+
* the module to be included. The path must begin with "./", and is
|
|
228
|
+
* relative to the directory containing compile.json. The module may be
|
|
229
|
+
* either a CommonJS module or an ES6 module.
|
|
230
|
+
*/
|
|
231
|
+
localModules: {
|
|
232
|
+
init: null,
|
|
233
|
+
check: "Object"
|
|
220
234
|
}
|
|
221
235
|
},
|
|
222
236
|
|
|
@@ -255,12 +255,14 @@ qx.Class.define("qx.tool.compiler.app.WebFont", {
|
|
|
255
255
|
lookupListIndexes.forEach(index => {
|
|
256
256
|
let subTable = lookupList[index].subTables[0];
|
|
257
257
|
let leadingCharacters = [];
|
|
258
|
-
subTable.coverage.rangeRecords
|
|
259
|
-
|
|
260
|
-
let
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
258
|
+
if (subTable.coverage.rangeRecords) {
|
|
259
|
+
subTable.coverage.rangeRecords.forEach(coverage => {
|
|
260
|
+
for (let i = coverage.start; i <= coverage.end; i++) {
|
|
261
|
+
let character = font.stringsForGlyph(i)[0];
|
|
262
|
+
leadingCharacters.push(character);
|
|
263
|
+
}
|
|
264
|
+
});
|
|
265
|
+
}
|
|
264
266
|
let ligatureSets = subTable.ligatureSets.toArray();
|
|
265
267
|
ligatureSets.forEach((ligatureSet, ligatureSetIndex) => {
|
|
266
268
|
let leadingCharacter = leadingCharacters[ligatureSetIndex];
|
|
@@ -24,7 +24,7 @@ const fs = qx.tool.utils.Promisify.fs;
|
|
|
24
24
|
const path = require("upath");
|
|
25
25
|
|
|
26
26
|
const crypto = require("crypto");
|
|
27
|
-
const sourceMap = require("source-map");
|
|
27
|
+
const sourceMap = require("source-map-js");
|
|
28
28
|
|
|
29
29
|
/**
|
|
30
30
|
* Copies multiple javascript source files into a single destination, preserving (merging)
|
|
@@ -432,6 +432,14 @@ qx.Class.define("qx.tool.compiler.targets.Target", {
|
|
|
432
432
|
new qx.tool.compiler.targets.meta.PolyfillJs(appMeta)
|
|
433
433
|
);
|
|
434
434
|
|
|
435
|
+
// Add browserified CommonJS modules, if any. The Browserify
|
|
436
|
+
// class will always bundle local modules specified for an
|
|
437
|
+
// application in compile.json, but will not bundle `require()`d
|
|
438
|
+
// modules that are Node modules.
|
|
439
|
+
bootPackage.addJavascriptMeta(
|
|
440
|
+
new qx.tool.compiler.targets.meta.Browserify(appMeta)
|
|
441
|
+
);
|
|
442
|
+
|
|
435
443
|
/*
|
|
436
444
|
* Assemble the Parts
|
|
437
445
|
*/
|
|
@@ -22,11 +22,11 @@
|
|
|
22
22
|
|
|
23
23
|
const fs = qx.tool.utils.Promisify.fs;
|
|
24
24
|
const path = require("upath");
|
|
25
|
-
const sourceMap = require("source-map");
|
|
25
|
+
const sourceMap = require("source-map-js");
|
|
26
26
|
|
|
27
27
|
/**
|
|
28
28
|
* An AbstractJavascriptMeta provides an abstraction of some source code, and might be
|
|
29
|
-
*
|
|
29
|
+
* comprised of a number of input files which are merged together as required.
|
|
30
30
|
*
|
|
31
31
|
* This object could represent a file which already exists on disk (eg a transpiled
|
|
32
32
|
* source file), or something that is generated on the fly (such as a index.js), or
|
|
@@ -0,0 +1,179 @@
|
|
|
1
|
+
/* ************************************************************************
|
|
2
|
+
*
|
|
3
|
+
* qooxdoo-compiler - node.js based replacement for the Qooxdoo python
|
|
4
|
+
* toolchain
|
|
5
|
+
*
|
|
6
|
+
* https://github.com/qooxdoo/qooxdoo-compiler
|
|
7
|
+
*
|
|
8
|
+
* Copyright:
|
|
9
|
+
* 2022 Derrell Lipman
|
|
10
|
+
*
|
|
11
|
+
* License:
|
|
12
|
+
* MIT: https://opensource.org/licenses/MIT
|
|
13
|
+
*
|
|
14
|
+
* This software is provided under the same licensing terms as Qooxdoo,
|
|
15
|
+
* please see the LICENSE file in the Qooxdoo project's top-level directory
|
|
16
|
+
* for details.
|
|
17
|
+
*
|
|
18
|
+
* Authors:
|
|
19
|
+
* * Derrell Lipman (@derrell)
|
|
20
|
+
*
|
|
21
|
+
* ************************************************************************/
|
|
22
|
+
|
|
23
|
+
const fs = qx.tool.utils.Promisify.fs;
|
|
24
|
+
const path = require("upath");
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
*
|
|
28
|
+
*/
|
|
29
|
+
qx.Class.define("qx.tool.compiler.targets.meta.Browserify", {
|
|
30
|
+
extend: qx.tool.compiler.targets.meta.AbstractJavascriptMeta,
|
|
31
|
+
|
|
32
|
+
construct(appMeta) {
|
|
33
|
+
super(appMeta, `${appMeta.getApplicationRoot()}commonjs-browserify.js`);
|
|
34
|
+
this.__appMeta = appMeta;
|
|
35
|
+
this.setNeedsWriteToDisk(true);
|
|
36
|
+
},
|
|
37
|
+
|
|
38
|
+
members: {
|
|
39
|
+
__appMeta: null,
|
|
40
|
+
|
|
41
|
+
/**
|
|
42
|
+
* @Override
|
|
43
|
+
*/
|
|
44
|
+
async writeSourceCodeToStream(ws) {
|
|
45
|
+
let hasCommonjsModules = false;
|
|
46
|
+
let commonjsModules = new Set();
|
|
47
|
+
let references = {};
|
|
48
|
+
const localModules =
|
|
49
|
+
this.__appMeta.getApplication().getLocalModules() || {};
|
|
50
|
+
const db = this.__appMeta.getAnalyser().getDatabase();
|
|
51
|
+
|
|
52
|
+
// Only include discovered `require()`d Node modules if the
|
|
53
|
+
// target application type is browser.
|
|
54
|
+
if (
|
|
55
|
+
this.__appMeta.getEnvironmentValue("qx.compiler.applicationType") ==
|
|
56
|
+
"browser"
|
|
57
|
+
) {
|
|
58
|
+
// Get a Set of unique `require`d CommonJS module names from
|
|
59
|
+
// all classes
|
|
60
|
+
for (let className in db.classInfo) {
|
|
61
|
+
let classInfo = db.classInfo[className];
|
|
62
|
+
if (classInfo.commonjsModules) {
|
|
63
|
+
Object.keys(classInfo.commonjsModules).forEach(moduleName => {
|
|
64
|
+
// Ignore this found `require()` if its a local modules
|
|
65
|
+
if (moduleName in localModules) {
|
|
66
|
+
return;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
// Add this module name to the set of module names
|
|
70
|
+
commonjsModules.add(moduleName);
|
|
71
|
+
|
|
72
|
+
// Add the list of references from which this module was require()d
|
|
73
|
+
if (!references[moduleName]) {
|
|
74
|
+
references[moduleName] = new Set();
|
|
75
|
+
}
|
|
76
|
+
references[moduleName].add([
|
|
77
|
+
...classInfo.commonjsModules[moduleName]
|
|
78
|
+
]);
|
|
79
|
+
|
|
80
|
+
// There is at least one module
|
|
81
|
+
hasCommonjsModules = true;
|
|
82
|
+
});
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
// If there are any CommonJS modules required to be bundled, or
|
|
88
|
+
// any local modules specified for the application in
|
|
89
|
+
// compile.json, browserify them
|
|
90
|
+
if (hasCommonjsModules || localModules) {
|
|
91
|
+
await this.__browserify(commonjsModules, references, localModules, ws);
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
await new Promise(resolve => {
|
|
95
|
+
ws.write("\n", resolve);
|
|
96
|
+
});
|
|
97
|
+
},
|
|
98
|
+
|
|
99
|
+
async __browserify(commonjsModules, references, localModules, ws) {
|
|
100
|
+
const babelify = require("babelify");
|
|
101
|
+
const preset = require("@babel/preset-env");
|
|
102
|
+
const browserify = require("browserify");
|
|
103
|
+
const builtins = require("browserify/lib/builtins.js");
|
|
104
|
+
|
|
105
|
+
// For some reason, `process` is not require()able, but `_process` is.
|
|
106
|
+
// Make them equivalent.
|
|
107
|
+
builtins.process = builtins._process;
|
|
108
|
+
|
|
109
|
+
// Convert the Set of CommonJS module names to an array
|
|
110
|
+
commonjsModules = [...commonjsModules];
|
|
111
|
+
|
|
112
|
+
return new Promise(resolve => {
|
|
113
|
+
let b = browserify([], {
|
|
114
|
+
builtins: builtins,
|
|
115
|
+
ignoreMissing: true,
|
|
116
|
+
insertGlobals: true,
|
|
117
|
+
detectGlobals: true
|
|
118
|
+
});
|
|
119
|
+
|
|
120
|
+
b._mdeps.on("missing", (id, parent) => {
|
|
121
|
+
let message = [];
|
|
122
|
+
|
|
123
|
+
message.push(`ERROR: could not locate require()d module: "${id}"`);
|
|
124
|
+
message.push(" required from:");
|
|
125
|
+
|
|
126
|
+
try {
|
|
127
|
+
[...references[id]].forEach(refs => {
|
|
128
|
+
refs.forEach(ref => {
|
|
129
|
+
message.push(` ${ref}`);
|
|
130
|
+
});
|
|
131
|
+
});
|
|
132
|
+
} catch (e) {
|
|
133
|
+
message.push(` <compile.json:application.localModules'>`);
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
qx.tool.compiler.Console.error(message.join("\n"));
|
|
137
|
+
});
|
|
138
|
+
|
|
139
|
+
// Include any dynamically determined `require()`d modules
|
|
140
|
+
if (commonjsModules.length > 0) {
|
|
141
|
+
b.require(commonjsModules);
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
// Include any local modules specified for the application
|
|
145
|
+
// in compile.json
|
|
146
|
+
if (localModules) {
|
|
147
|
+
for (let requireName in localModules) {
|
|
148
|
+
b.require(localModules[requireName], { expose: requireName });
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
// Ensure ES6 local modules are converted to CommonJS format
|
|
153
|
+
b.transform(babelify, {
|
|
154
|
+
presets: [preset],
|
|
155
|
+
sourceMaps: false,
|
|
156
|
+
global: true
|
|
157
|
+
});
|
|
158
|
+
|
|
159
|
+
b.bundle((e, output) => {
|
|
160
|
+
if (e) {
|
|
161
|
+
// We've already handled the case of missing module. This is something else.
|
|
162
|
+
qx.tool.compiler.Console.error(`Failed: ${e}`);
|
|
163
|
+
throw e;
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
ws.write(output);
|
|
167
|
+
resolve(null);
|
|
168
|
+
});
|
|
169
|
+
});
|
|
170
|
+
},
|
|
171
|
+
|
|
172
|
+
/**
|
|
173
|
+
* @Override
|
|
174
|
+
*/
|
|
175
|
+
async getSourceMap() {
|
|
176
|
+
return null;
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
});
|
|
@@ -124,10 +124,18 @@ qx.Class.define("qx.tool.compiler.targets.meta.Uglify", {
|
|
|
124
124
|
throw new Error("UglifyJS failed to minimise: " + (err.message || err));
|
|
125
125
|
}
|
|
126
126
|
await fs.writeFileAsync(outJsFilename, result.code, { encoding: "utf8" });
|
|
127
|
-
await fs.writeFileAsync(outJsFilename + ".map", result.map, {
|
|
127
|
+
await fs.writeFileAsync(outJsFilename + ".map", result.map, {
|
|
128
|
+
encoding: "utf8"
|
|
129
|
+
});
|
|
128
130
|
if (this._appMeta.getTarget().isSaveUnminified()) {
|
|
129
|
-
await fs.writeFileAsync(outJsFilename + ".unminified", inSourceCode, {
|
|
130
|
-
|
|
131
|
+
await fs.writeFileAsync(outJsFilename + ".unminified", inSourceCode, {
|
|
132
|
+
encoding: "utf8"
|
|
133
|
+
});
|
|
134
|
+
await fs.writeFileAsync(
|
|
135
|
+
outJsFilename + ".unminified.map",
|
|
136
|
+
JSON.stringify(inSourceMap, null, 2),
|
|
137
|
+
{ encoding: "utf8" }
|
|
138
|
+
);
|
|
131
139
|
}
|
|
132
140
|
|
|
133
141
|
this.fireDataEvent("minifiedApplication", {
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
* *********************************************************************** */
|
|
24
24
|
|
|
25
25
|
const Ajv = require("ajv");
|
|
26
|
-
const betterAjvErrors = require("better-ajv-errors");
|
|
26
|
+
const betterAjvErrors = require("better-ajv-errors").default;
|
|
27
27
|
const fs = qx.tool.utils.Promisify.fs;
|
|
28
28
|
|
|
29
29
|
qx.Class.define("qx.tool.utils.Json", {
|
|
@@ -25,8 +25,8 @@ const rimraf = require("rimraf");
|
|
|
25
25
|
const dot = require("dot");
|
|
26
26
|
require("jstransformer-dot");
|
|
27
27
|
const metalsmith = require("metalsmith");
|
|
28
|
-
const layouts = require("metalsmith
|
|
29
|
-
const markdown = require("metalsmith
|
|
28
|
+
const layouts = require("@metalsmith/layouts");
|
|
29
|
+
const markdown = require("@metalsmith/markdown");
|
|
30
30
|
//const filenames = require("metalsmith-filenames");
|
|
31
31
|
//var permalinks = require("metalsmith-permalinks");
|
|
32
32
|
/**
|
|
@@ -415,23 +415,19 @@ qx.Class.define("qx.ui.basic.Label", {
|
|
|
415
415
|
|
|
416
416
|
if (value != null) {
|
|
417
417
|
value.bind("enabled", this, "enabled");
|
|
418
|
-
this.__tapListenerId = this.addListener(
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
}
|
|
432
|
-
},
|
|
433
|
-
this
|
|
434
|
-
);
|
|
418
|
+
this.__tapListenerId = this.addListener("tap", () => {
|
|
419
|
+
// only focus focusable elements [BUG #3555]
|
|
420
|
+
if (value.isFocusable()) {
|
|
421
|
+
value.focus.apply(value);
|
|
422
|
+
}
|
|
423
|
+
// furthermore toggle if possible [BUG #6881]
|
|
424
|
+
if (
|
|
425
|
+
"toggleValue" in value &&
|
|
426
|
+
typeof value.toggleValue === "function"
|
|
427
|
+
) {
|
|
428
|
+
value.toggleValue();
|
|
429
|
+
}
|
|
430
|
+
});
|
|
435
431
|
}
|
|
436
432
|
},
|
|
437
433
|
|
|
@@ -461,20 +461,16 @@ qx.Mixin.define("qx.ui.core.MPlacement", {
|
|
|
461
461
|
);
|
|
462
462
|
|
|
463
463
|
// Remove the listener when the element disappears.
|
|
464
|
-
this.addListener(
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
}
|
|
475
|
-
},
|
|
476
|
-
this
|
|
477
|
-
);
|
|
464
|
+
this.addListener("disappear", () => {
|
|
465
|
+
if (this.__ptwLiveUpdater) {
|
|
466
|
+
qx.event.Idle.getInstance().removeListener(
|
|
467
|
+
"interval",
|
|
468
|
+
this.__ptwLiveUpdater
|
|
469
|
+
);
|
|
470
|
+
|
|
471
|
+
this.__ptwLiveUpdater = null;
|
|
472
|
+
}
|
|
473
|
+
});
|
|
478
474
|
}
|
|
479
475
|
|
|
480
476
|
this._place(coords);
|
|
@@ -532,13 +528,9 @@ qx.Mixin.define("qx.ui.core.MPlacement", {
|
|
|
532
528
|
}
|
|
533
529
|
|
|
534
530
|
if (size == null) {
|
|
535
|
-
this.addListenerOnce(
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
this.__getPlacementSize(callback);
|
|
539
|
-
},
|
|
540
|
-
this
|
|
541
|
-
);
|
|
531
|
+
this.addListenerOnce("appear", () => {
|
|
532
|
+
this.__getPlacementSize(callback);
|
|
533
|
+
});
|
|
542
534
|
} else {
|
|
543
535
|
callback.call(this, size);
|
|
544
536
|
}
|
|
@@ -2109,13 +2109,12 @@ qx.Class.define("qx.ui.core.Widget", {
|
|
|
2109
2109
|
var manager = qx.locale.Manager.getInstance();
|
|
2110
2110
|
this.__toolTipTextListenerId = manager.addListener(
|
|
2111
2111
|
"changeLocale",
|
|
2112
|
-
|
|
2112
|
+
() => {
|
|
2113
2113
|
var toolTipText = this.getToolTipText();
|
|
2114
2114
|
if (toolTipText && toolTipText.translate) {
|
|
2115
2115
|
this.setToolTipText(toolTipText.translate());
|
|
2116
2116
|
}
|
|
2117
|
-
}
|
|
2118
|
-
this
|
|
2117
|
+
}
|
|
2119
2118
|
);
|
|
2120
2119
|
}
|
|
2121
2120
|
},
|
|
@@ -71,13 +71,9 @@ qx.Class.define("qx.ui.core.scroll.NativeScrollBar", {
|
|
|
71
71
|
}
|
|
72
72
|
|
|
73
73
|
// prevent drag & drop on scrolling
|
|
74
|
-
this.addListener(
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
e.stopPropagation();
|
|
78
|
-
},
|
|
79
|
-
this
|
|
80
|
-
);
|
|
74
|
+
this.addListener("track", e => {
|
|
75
|
+
e.stopPropagation();
|
|
76
|
+
});
|
|
81
77
|
},
|
|
82
78
|
|
|
83
79
|
events: {
|
|
@@ -81,13 +81,9 @@ qx.Class.define("qx.ui.core.scroll.ScrollBar", {
|
|
|
81
81
|
}
|
|
82
82
|
|
|
83
83
|
// prevent drag & drop on scrolling
|
|
84
|
-
this.addListener(
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
e.stopPropagation();
|
|
88
|
-
},
|
|
89
|
-
this
|
|
90
|
-
);
|
|
84
|
+
this.addListener("track", e => {
|
|
85
|
+
e.stopPropagation();
|
|
86
|
+
});
|
|
91
87
|
},
|
|
92
88
|
|
|
93
89
|
events: {
|
|
@@ -92,64 +92,54 @@ qx.Class.define("qx.ui.embed.Iframe", {
|
|
|
92
92
|
this.__blockerElement = this._createBlockerElement();
|
|
93
93
|
|
|
94
94
|
if (qx.core.Environment.get("ecmascript.mutationobserver")) {
|
|
95
|
-
this.addListenerOnce(
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
if (mutationRecord.addedNodes[i] == element) {
|
|
107
|
-
return true;
|
|
108
|
-
}
|
|
95
|
+
this.addListenerOnce("appear", () => {
|
|
96
|
+
var element = this.getContentElement().getDomElement();
|
|
97
|
+
|
|
98
|
+
// Mutation record check callback
|
|
99
|
+
var isDOMNodeInserted = function (mutationRecord) {
|
|
100
|
+
var i;
|
|
101
|
+
// 'our' iframe was either added...
|
|
102
|
+
if (mutationRecord.addedNodes) {
|
|
103
|
+
for (i = mutationRecord.addedNodes.length; i >= 0; --i) {
|
|
104
|
+
if (mutationRecord.addedNodes[i] == element) {
|
|
105
|
+
return true;
|
|
109
106
|
}
|
|
110
107
|
}
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
108
|
+
}
|
|
109
|
+
// ...or removed
|
|
110
|
+
if (mutationRecord.removedNodes) {
|
|
111
|
+
for (i = mutationRecord.removedNodes.length; i >= 0; --i) {
|
|
112
|
+
if (mutationRecord.removedNodes[i] == element) {
|
|
113
|
+
return true;
|
|
117
114
|
}
|
|
118
115
|
}
|
|
119
|
-
|
|
120
|
-
|
|
116
|
+
}
|
|
117
|
+
return false;
|
|
118
|
+
};
|
|
121
119
|
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
observer.observe(parent, { childList: true, subtree: true });
|
|
135
|
-
},
|
|
136
|
-
this
|
|
137
|
-
);
|
|
120
|
+
var observer = new MutationObserver(
|
|
121
|
+
function (mutationRecords) {
|
|
122
|
+
if (mutationRecords.some(isDOMNodeInserted)) {
|
|
123
|
+
this._syncSourceAfterDOMMove();
|
|
124
|
+
}
|
|
125
|
+
}.bind(this)
|
|
126
|
+
);
|
|
127
|
+
|
|
128
|
+
// Observe parent element
|
|
129
|
+
var parent = this.getLayoutParent().getContentElement().getDomElement();
|
|
130
|
+
observer.observe(parent, { childList: true, subtree: true });
|
|
131
|
+
});
|
|
138
132
|
}
|
|
139
133
|
// !qx.core.Environment.get("ecmascript.mutationobserver")
|
|
140
134
|
else {
|
|
141
|
-
this.addListenerOnce(
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
);
|
|
150
|
-
},
|
|
151
|
-
this
|
|
152
|
-
);
|
|
135
|
+
this.addListenerOnce("appear", () => {
|
|
136
|
+
var element = this.getContentElement().getDomElement();
|
|
137
|
+
qx.bom.Event.addNativeListener(
|
|
138
|
+
element,
|
|
139
|
+
"DOMNodeInserted",
|
|
140
|
+
this._onDOMNodeInserted
|
|
141
|
+
);
|
|
142
|
+
});
|
|
153
143
|
|
|
154
144
|
this._onDOMNodeInserted = qx.lang.Function.listener(
|
|
155
145
|
this._syncSourceAfterDOMMove,
|
|
@@ -994,18 +994,14 @@ qx.Class.define("qx.ui.form.AbstractField", {
|
|
|
994
994
|
/* qx Bug #8870: Firefox 35 will not display a text area's
|
|
995
995
|
placeholder text if the attribute is set before the
|
|
996
996
|
element is added to the DOM. This is fixed in FF 36. */
|
|
997
|
-
this.addListenerOnce(
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
.setAttribute("placeholder", value);
|
|
1006
|
-
},
|
|
1007
|
-
this
|
|
1008
|
-
);
|
|
997
|
+
this.addListenerOnce("appear", () => {
|
|
998
|
+
this.getContentElement()
|
|
999
|
+
.getDomElement()
|
|
1000
|
+
.removeAttribute("placeholder");
|
|
1001
|
+
this.getContentElement()
|
|
1002
|
+
.getDomElement()
|
|
1003
|
+
.setAttribute("placeholder", value);
|
|
1004
|
+
});
|
|
1009
1005
|
}
|
|
1010
1006
|
}
|
|
1011
1007
|
}
|
|
@@ -210,7 +210,10 @@ qx.Class.define("qx.ui.form.AbstractSelectBox", {
|
|
|
210
210
|
* Hides the list popup.
|
|
211
211
|
*/
|
|
212
212
|
close() {
|
|
213
|
-
this.getChildControl("popup")
|
|
213
|
+
var popup = this.getChildControl("popup", true);
|
|
214
|
+
if (popup && popup.isVisible()) {
|
|
215
|
+
popup.hide();
|
|
216
|
+
}
|
|
214
217
|
},
|
|
215
218
|
|
|
216
219
|
/**
|
|
@@ -53,21 +53,13 @@ qx.Class.define("qx.ui.form.ComboBox", {
|
|
|
53
53
|
|
|
54
54
|
// forward the focusin and focusout events to the textfield. The textfield
|
|
55
55
|
// is not focusable so the events need to be forwarded manually.
|
|
56
|
-
this.addListener(
|
|
57
|
-
"focusin",
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
);
|
|
63
|
-
|
|
64
|
-
this.addListener(
|
|
65
|
-
"focusout",
|
|
66
|
-
function (e) {
|
|
67
|
-
textField.fireNonBubblingEvent("focusout", qx.event.type.Focus);
|
|
68
|
-
},
|
|
69
|
-
this
|
|
70
|
-
);
|
|
56
|
+
this.addListener("focusin", e => {
|
|
57
|
+
textField.fireNonBubblingEvent("focusin", qx.event.type.Focus);
|
|
58
|
+
});
|
|
59
|
+
|
|
60
|
+
this.addListener("focusout", e => {
|
|
61
|
+
textField.fireNonBubblingEvent("focusout", qx.event.type.Focus);
|
|
62
|
+
});
|
|
71
63
|
},
|
|
72
64
|
|
|
73
65
|
/*
|