@zhongguo168a/yxeditor-common 0.0.89 → 0.0.90
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/dist/index.d.ts +6 -4
- package/dist/index.esm.js +14 -8
- package/dist/index.esm.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -1326,6 +1326,8 @@ declare class ViewModel extends EventDispatcher {
|
|
|
1326
1326
|
closeComplete(): void;
|
|
1327
1327
|
protected _waitOpenComplete: boolean;
|
|
1328
1328
|
protected _waitCloseComplete: boolean;
|
|
1329
|
+
get controller(): RouteController;
|
|
1330
|
+
get route(): Route;
|
|
1329
1331
|
get reason(): LinkError;
|
|
1330
1332
|
node: Node;
|
|
1331
1333
|
datas: MapObject;
|
|
@@ -1352,7 +1354,7 @@ declare class ViewList extends List<ViewModel> {
|
|
|
1352
1354
|
/**
|
|
1353
1355
|
* 路由唯一编号->视图
|
|
1354
1356
|
*/
|
|
1355
|
-
declare class ViewDict extends Dictionary<string,
|
|
1357
|
+
declare class ViewDict extends Dictionary<string, ViewModel> {
|
|
1356
1358
|
/**
|
|
1357
1359
|
* 关闭相斥的视图对象
|
|
1358
1360
|
* 1. 关闭同一层的所有视图对象
|
|
@@ -1385,10 +1387,10 @@ declare class RouteViewDict extends ViewDict {
|
|
|
1385
1387
|
* @param route
|
|
1386
1388
|
*/
|
|
1387
1389
|
refresh(route: Route): void;
|
|
1388
|
-
getByRoute(route: Route):
|
|
1390
|
+
getByRoute(route: Route): ViewModel;
|
|
1389
1391
|
protected getController(name: string): RouteController;
|
|
1390
1392
|
}
|
|
1391
|
-
declare const
|
|
1393
|
+
declare const routeViews: RouteViewDict;
|
|
1392
1394
|
|
|
1393
1395
|
/**
|
|
1394
1396
|
* 事件字符串分隔符
|
|
@@ -2180,5 +2182,5 @@ declare class WidgetUtil {
|
|
|
2180
2182
|
}
|
|
2181
2183
|
declare var widgetutil: WidgetUtil;
|
|
2182
2184
|
|
|
2183
|
-
export { ArrayUtil, AssetLoader, AssetURI, BitUtil, CallbackList, CameraUtil, CanvasUtil, Controller, ControllerDict, ControllerRepo, ConvertUtil, DictIterator, DictNode, DictSource, Dictionary, DirectionMode, Dispatcher, DocUtil, ErrorUtil, EventDispatcher, EventItem, EventUtil, Factory, FloatUtil, GeometryDirection, GeometryUtil, IdentUtil, LOGGER_EVENT, LinkError, List, ListIterator, ListNode, ListSource, Listener, LogLevel, LogManager, Logger, MapObject, MapUtil, MathUtil, Model, NetUtil, PathUtil, Pool, RandUtil, Route, RouteController, RouteList, RouteView, RouteViewDict, SampleCallbackList, SamplePool, SamplePoolSet, ScaleUtil, SimpleModel, StringUtil, TimeUtil, Timer, TreeIterator, TreeNode, TreeNodePlugin, TreeRoot, TreeRootPlugin, TreeUtil, UIManager, UIObjectRepo, UIPoolConfig, UISingleConfig, UIUtil, ViewDict, ViewEvent, ViewHistory, ViewList, ViewModel, ViewState, WidgetAlign, WidgetUtil, XAssetManager, XEvent, arrayutil, assetx, bitutil, camerautil, canvasutil, convertutil, create等距图集, ctrlrepo, docutil, errorutil, eventmgr, eventutil, floatutil, formatutil, geoutil, identutil, loadAtlas, logmgr, maputil, mathutil, netutil, parseAtlas, parsePlist, pathutil, randutil, resutil,
|
|
2185
|
+
export { ArrayUtil, AssetLoader, AssetURI, BitUtil, CallbackList, CameraUtil, CanvasUtil, Controller, ControllerDict, ControllerRepo, ConvertUtil, DictIterator, DictNode, DictSource, Dictionary, DirectionMode, Dispatcher, DocUtil, ErrorUtil, EventDispatcher, EventItem, EventUtil, Factory, FloatUtil, GeometryDirection, GeometryUtil, IdentUtil, LOGGER_EVENT, LinkError, List, ListIterator, ListNode, ListSource, Listener, LogLevel, LogManager, Logger, MapObject, MapUtil, MathUtil, Model, NetUtil, PathUtil, Pool, RandUtil, Route, RouteController, RouteList, RouteView, RouteViewDict, SampleCallbackList, SamplePool, SamplePoolSet, ScaleUtil, SimpleModel, StringUtil, TimeUtil, Timer, TreeIterator, TreeNode, TreeNodePlugin, TreeRoot, TreeRootPlugin, TreeUtil, UIManager, UIObjectRepo, UIPoolConfig, UISingleConfig, UIUtil, ViewDict, ViewEvent, ViewHistory, ViewList, ViewModel, ViewState, WidgetAlign, WidgetUtil, XAssetManager, XEvent, arrayutil, assetx, bitutil, camerautil, canvasutil, convertutil, create等距图集, ctrlrepo, docutil, errorutil, eventmgr, eventutil, floatutil, formatutil, geoutil, identutil, loadAtlas, logmgr, maputil, mathutil, netutil, parseAtlas, parsePlist, pathutil, randutil, resutil, routeViews, scaleutil, stringutil, timer, timeutil, treeutil, uimgr, uirepo, uiutil, viewhistorys, widgetutil };
|
|
2184
2186
|
export type { CreatorFunction, DisposeFunction, IController, IError, IEventDispatcher, IExtend, IListItem, IModel, IModule, ITreeListItem, RecycleFunction };
|
package/dist/index.esm.js
CHANGED
|
@@ -4209,18 +4209,18 @@ class RouteViewDict extends ViewDict {
|
|
|
4209
4209
|
return ctrlrepo.get(name);
|
|
4210
4210
|
}
|
|
4211
4211
|
}
|
|
4212
|
-
const
|
|
4212
|
+
const routeViews = new RouteViewDict();
|
|
4213
4213
|
|
|
4214
4214
|
class ViewHistory extends RouteList {
|
|
4215
4215
|
back() {
|
|
4216
4216
|
if (viewhistorys.length == 0) {
|
|
4217
4217
|
return;
|
|
4218
4218
|
}
|
|
4219
|
-
|
|
4219
|
+
routeViews.close(viewhistorys.shift());
|
|
4220
4220
|
if (viewhistorys.length == 0) {
|
|
4221
4221
|
return;
|
|
4222
4222
|
}
|
|
4223
|
-
|
|
4223
|
+
routeViews.open(viewhistorys.last());
|
|
4224
4224
|
}
|
|
4225
4225
|
}
|
|
4226
4226
|
const viewhistorys = new ViewHistory();
|
|
@@ -4274,10 +4274,10 @@ class ViewModel extends EventDispatcher {
|
|
|
4274
4274
|
}
|
|
4275
4275
|
let route = this._route;
|
|
4276
4276
|
if (route) {
|
|
4277
|
-
if (
|
|
4277
|
+
if (routeViews.get(route.key)) {
|
|
4278
4278
|
throw `视图已存在: route=${route.key}`;
|
|
4279
4279
|
}
|
|
4280
|
-
|
|
4280
|
+
routeViews.set(route.key, this);
|
|
4281
4281
|
}
|
|
4282
4282
|
this.state = ViewState.Opening;
|
|
4283
4283
|
this.dispatch(ViewEvent.Opening);
|
|
@@ -4306,7 +4306,7 @@ class ViewModel extends EventDispatcher {
|
|
|
4306
4306
|
}
|
|
4307
4307
|
let route = this._route;
|
|
4308
4308
|
if (route) {
|
|
4309
|
-
|
|
4309
|
+
routeViews.delete(this._route.key);
|
|
4310
4310
|
}
|
|
4311
4311
|
this.state = ViewState.Closeing;
|
|
4312
4312
|
this.dispatch(ViewEvent.Closeing);
|
|
@@ -4406,12 +4406,18 @@ class ViewModel extends EventDispatcher {
|
|
|
4406
4406
|
if (this.state == ViewState.Closed) {
|
|
4407
4407
|
return;
|
|
4408
4408
|
}
|
|
4409
|
-
|
|
4409
|
+
routeViews.delete(this.getIdent());
|
|
4410
4410
|
this._waitCloseComplete = false;
|
|
4411
4411
|
this.state = ViewState.Closed;
|
|
4412
4412
|
this.dispatch(ViewEvent.Closed);
|
|
4413
4413
|
this.onClosed();
|
|
4414
4414
|
}
|
|
4415
|
+
get controller() {
|
|
4416
|
+
return this._controller;
|
|
4417
|
+
}
|
|
4418
|
+
get route() {
|
|
4419
|
+
return this._route;
|
|
4420
|
+
}
|
|
4415
4421
|
get reason() {
|
|
4416
4422
|
return this._reason;
|
|
4417
4423
|
}
|
|
@@ -6846,5 +6852,5 @@ class WidgetUtil {
|
|
|
6846
6852
|
}
|
|
6847
6853
|
var widgetutil = new WidgetUtil();
|
|
6848
6854
|
|
|
6849
|
-
export { ArrayUtil, AssetLoader, AssetURI, BitUtil, CallbackList, CameraUtil, CanvasUtil, Controller, ControllerDict, ControllerRepo, ConvertUtil, DictIterator, DictNode, DictSource, Dictionary, DirectionMode, Dispatcher, DocUtil, ErrorUtil, EventDispatcher, EventItem, EventUtil, Factory, FloatUtil, GeometryDirection, GeometryUtil, IdentUtil, LOGGER_EVENT, LinkError, List, ListIterator, ListNode, ListSource, Listener, LogLevel, LogManager, Logger, MapObject, MapUtil, MathUtil, Model, NetUtil, PathUtil, Pool, RandUtil, Route, RouteController, RouteList, RouteView, RouteViewDict, SampleCallbackList, SamplePool, SamplePoolSet, ScaleUtil, SimpleModel, StringUtil, TimeUtil, Timer, TreeIterator, TreeNode, TreeNodePlugin, TreeRoot, TreeRootPlugin, TreeUtil, UIManager, UIObjectRepo, UIPoolConfig, UISingleConfig, UIUtil, ViewDict, ViewEvent, ViewHistory, ViewList, ViewModel, ViewState, WidgetAlign, WidgetUtil, XAssetManager, XEvent, arrayutil, assetx, bitutil, camerautil, canvasutil, convertutil, create等距图集, ctrlrepo, docutil, errorutil, eventmgr, eventutil, floatutil, formatutil, geoutil, identutil, loadAtlas, logmgr, maputil, mathutil, netutil, parseAtlas, parsePlist, pathutil, randutil, resutil,
|
|
6855
|
+
export { ArrayUtil, AssetLoader, AssetURI, BitUtil, CallbackList, CameraUtil, CanvasUtil, Controller, ControllerDict, ControllerRepo, ConvertUtil, DictIterator, DictNode, DictSource, Dictionary, DirectionMode, Dispatcher, DocUtil, ErrorUtil, EventDispatcher, EventItem, EventUtil, Factory, FloatUtil, GeometryDirection, GeometryUtil, IdentUtil, LOGGER_EVENT, LinkError, List, ListIterator, ListNode, ListSource, Listener, LogLevel, LogManager, Logger, MapObject, MapUtil, MathUtil, Model, NetUtil, PathUtil, Pool, RandUtil, Route, RouteController, RouteList, RouteView, RouteViewDict, SampleCallbackList, SamplePool, SamplePoolSet, ScaleUtil, SimpleModel, StringUtil, TimeUtil, Timer, TreeIterator, TreeNode, TreeNodePlugin, TreeRoot, TreeRootPlugin, TreeUtil, UIManager, UIObjectRepo, UIPoolConfig, UISingleConfig, UIUtil, ViewDict, ViewEvent, ViewHistory, ViewList, ViewModel, ViewState, WidgetAlign, WidgetUtil, XAssetManager, XEvent, arrayutil, assetx, bitutil, camerautil, canvasutil, convertutil, create等距图集, ctrlrepo, docutil, errorutil, eventmgr, eventutil, floatutil, formatutil, geoutil, identutil, loadAtlas, logmgr, maputil, mathutil, netutil, parseAtlas, parsePlist, pathutil, randutil, resutil, routeViews, scaleutil, stringutil, timer, timeutil, treeutil, uimgr, uirepo, uiutil, viewhistorys, widgetutil };
|
|
6850
6856
|
//# sourceMappingURL=index.esm.js.map
|