zimjs 18.0.0 → 18.0.2
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/package.json +1 -1
- package/src/zim.js +28 -16
package/package.json
CHANGED
package/src/zim.js
CHANGED
|
@@ -47502,7 +47502,7 @@ added, click, dblclick, mousedown, mouseout, mouseover, pressdown (ZIM), pressmo
|
|
|
47502
47502
|
//-67.45
|
|
47503
47503
|
|
|
47504
47504
|
/*--
|
|
47505
|
-
zim.Carousel3D = function(width, height, items, widthFactor, heightFactor, curve, interactive, continuous, fade, fadeColor, vertical, sensitivity, damp, factor, index, style, group, inherit)
|
|
47505
|
+
zim.Carousel3D = function(width, height, items, widthFactor, heightFactor, curve, interactive, continuous, fade, fadeColor, vertical, sensitivity, damp, factor, index, selectedIndex, style, group, inherit)
|
|
47506
47506
|
|
|
47507
47507
|
Carousel3D
|
|
47508
47508
|
zim class - extends a zim.Container which extends a createjs.Container
|
|
@@ -47669,8 +47669,8 @@ ALSO: see the CreateJS Easel Docs for Container events such as:
|
|
|
47669
47669
|
added, click, dblclick, mousedown, mouseout, mouseover, pressdown (ZIM), pressmove, pressup, removed, rollout, rollover
|
|
47670
47670
|
--*///+67.47
|
|
47671
47671
|
|
|
47672
|
-
zim.Carousel3D = function(width, height, items, widthFactor, heightFactor, curve, interactive, continuous, fade, fadeColor, vertical, sensitivity, damp, factor, index, style, group, inherit) {
|
|
47673
|
-
var sig = "width, height, items, widthFactor, heightFactor, curve, interactive, continuous, fade, fadeColor, vertical, sensitivity, damp, factor, index, style, group, inherit";
|
|
47672
|
+
zim.Carousel3D = function(width, height, items, widthFactor, heightFactor, curve, interactive, continuous, fade, fadeColor, vertical, sensitivity, damp, factor, index, selectedIndex, style, group, inherit) {
|
|
47673
|
+
var sig = "width, height, items, widthFactor, heightFactor, curve, interactive, continuous, fade, fadeColor, vertical, sensitivity, damp, factor, index, selectedIndex, style, group, inherit";
|
|
47674
47674
|
var duo; if (duo = zob(zim.Carousel3D, arguments, sig, this)) return duo;
|
|
47675
47675
|
z_d("67.47");
|
|
47676
47676
|
|
|
@@ -47977,7 +47977,7 @@ zim.Carousel3D = function(width, height, items, widthFactor, heightFactor, curve
|
|
|
47977
47977
|
else if (newItem.clone) newItems.push(newItem.clone());
|
|
47978
47978
|
else newItems.push(zim.copy(that.items[i]));
|
|
47979
47979
|
}
|
|
47980
|
-
return that.cloneProps(new zim.Carousel3D(width, height, newItems, widthFactor, heightFactor, that.curve, interactive, continuous, fade, fadeColor, vertical, sensitivity, damp, factor, index, style, this.group));
|
|
47980
|
+
return that.cloneProps(new zim.Carousel3D(width, height, newItems, widthFactor, heightFactor, that.curve, interactive, continuous, fade, fadeColor, vertical, sensitivity, damp, factor, index, selectedIndex, style, this.group));
|
|
47981
47981
|
};
|
|
47982
47982
|
}
|
|
47983
47983
|
zim.extend(zim.Carousel3D, zim.Container, ["clone", "dispose"], "zimContainer", false);
|
|
@@ -51665,13 +51665,17 @@ RETURNS obj for chaining
|
|
|
51665
51665
|
});
|
|
51666
51666
|
});
|
|
51667
51667
|
} else {
|
|
51668
|
-
obj.zimClickDownEvent = obj.on("mousedown", function (e) {
|
|
51668
|
+
obj.zimClickDownEvent = obj.on("mousedown", function (e) {
|
|
51669
51669
|
if (e.currentTarget.type == "List") {
|
|
51670
51670
|
if (e.target.type == "WindowBacking") return;
|
|
51671
51671
|
var local = e.currentTarget.globalToLocal(e.stageX / zim.scaX, e.stageY / zim.scaY);
|
|
51672
51672
|
if (local.y <= 0) return; // avoid titleBar and organizer
|
|
51673
51673
|
}
|
|
51674
|
-
|
|
51674
|
+
var windowParent = false;
|
|
51675
|
+
var pp = e.target.parent.parent;
|
|
51676
|
+
if (pp && pp.type == "Window") windowParent = true;
|
|
51677
|
+
else if (pp && pp.parent && pp.parent.type == "Window") windowParent = true;
|
|
51678
|
+
if (M && !mobileUp && e.currentTarget.type != "List" && !windowParent) {
|
|
51675
51679
|
if (obj.excludeTap) return;
|
|
51676
51680
|
call(e);
|
|
51677
51681
|
if (once) {
|
|
@@ -87720,14 +87724,19 @@ zim.Frame = function(scaling, width, height, color, outerColor, ready, assets, p
|
|
|
87720
87724
|
var imagesNoCORS = [];
|
|
87721
87725
|
var mainCount = 0;
|
|
87722
87726
|
var firstSoundCheck = true;
|
|
87723
|
-
|
|
87727
|
+
|
|
87728
|
+
// 018 TRYING TO FIX CREATEJS ERROR IF SOUND LOADED AGAIN - BUT BREAKS LAZY LOAD
|
|
87729
|
+
// var emptyAssets = false;
|
|
87724
87730
|
|
|
87725
87731
|
for (i=0; i<assets.length; i++) {
|
|
87726
87732
|
a = assets[i];
|
|
87727
|
-
if (zim.assets[a]) {
|
|
87728
|
-
|
|
87729
|
-
|
|
87730
|
-
|
|
87733
|
+
// if (zim.assets[a]) {
|
|
87734
|
+
// // 018 TRYING TO FIX CREATEJS ERROR IF SOUND LOADED AGAIN - BUT BREAKS LAZY LOAD
|
|
87735
|
+
// // if (assets.length==1) {
|
|
87736
|
+
// // emptyAssets = true;
|
|
87737
|
+
// // continue;
|
|
87738
|
+
// // }
|
|
87739
|
+
// }
|
|
87731
87740
|
if (a.replace) a = a.replace(/gf_/i, "https://fonts.googleapis.com/css?family=");
|
|
87732
87741
|
// split multi into individual ZIM asset objects and make the first of these
|
|
87733
87742
|
if (a.assets) {
|
|
@@ -88125,10 +88134,11 @@ zim.Frame = function(scaling, width, height, color, outerColor, ready, assets, p
|
|
|
88125
88134
|
|
|
88126
88135
|
} // end non font/noCORSonImage
|
|
88127
88136
|
|
|
88128
|
-
//
|
|
88129
|
-
if
|
|
88130
|
-
|
|
88131
|
-
|
|
88137
|
+
// 018 TRYING TO FIX CREATEJS ERROR IF SOUND LOADED AGAIN - BUT BREAKS LAZY LOAD
|
|
88138
|
+
// // if calling an already preloaded asset
|
|
88139
|
+
// if (emptyAssets && queue.loadAssetsCount == 0) {
|
|
88140
|
+
// endAssetLoad();
|
|
88141
|
+
// }
|
|
88132
88142
|
|
|
88133
88143
|
function endAssetLoad() {
|
|
88134
88144
|
// setting a time will force the preload to wait at least this amount of time
|
|
@@ -90236,6 +90246,7 @@ zim.Dat = function(file) {
|
|
|
90236
90246
|
if (asset && asset.type != "AC") {
|
|
90237
90247
|
if (asset.documentElement) asset = asset.documentElement;
|
|
90238
90248
|
that.data = asset;
|
|
90249
|
+
that.file = file;
|
|
90239
90250
|
setTimeout(function() {
|
|
90240
90251
|
that.dispatchEvent("ready");
|
|
90241
90252
|
that.dispatchEvent("complete");
|
|
@@ -90251,6 +90262,7 @@ zim.Dat = function(file) {
|
|
|
90251
90262
|
var asset = zim.asset(file);
|
|
90252
90263
|
if (asset.documentElement) asset = asset.documentElement;
|
|
90253
90264
|
that.data = asset;
|
|
90265
|
+
that.file = file;
|
|
90254
90266
|
that.dispatchEvent("ready");
|
|
90255
90267
|
that.dispatchEvent("complete");
|
|
90256
90268
|
});
|
|
@@ -91504,7 +91516,7 @@ The globals NEVER require the zim namespace and are global in the JavaScript win
|
|
|
91504
91516
|
|
|
91505
91517
|
ZIM has a method called zimplify() that can make all ZIM classes, functions and properties global.
|
|
91506
91518
|
zimplify() loops through all properties on the zim namespace and adds them to the JavaScript window.
|
|
91507
|
-
Examples are Frame(), Button(), center(), STYLE, Emitter(), etc.
|
|
91519
|
+
Examples are Frame(), Button(), center(), STYLE, GLOBALSTYLE, Emitter(), etc.
|
|
91508
91520
|
zimplify() is automatically run when using the CDN ES module or script tags
|
|
91509
91521
|
unless the global variable zns is set to true before importing ZIM.
|
|
91510
91522
|
If zns is set to true, then the zim namespace is required: zim.Frame(), etc.
|