@zhongguo168a/yxeditor-common 0.0.32 → 0.0.35
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 +4 -4
- package/dist/index.esm.js +7 -1
- package/dist/index.esm.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -265,7 +265,7 @@ declare class EventItem {
|
|
|
265
265
|
once: boolean;
|
|
266
266
|
}
|
|
267
267
|
|
|
268
|
-
interface
|
|
268
|
+
interface IEventDispatcher {
|
|
269
269
|
has(type: string, caller: any, listener: Function): boolean;
|
|
270
270
|
/**
|
|
271
271
|
* 监听事件
|
|
@@ -298,7 +298,7 @@ interface IEventManager {
|
|
|
298
298
|
/**
|
|
299
299
|
* 事件派发器
|
|
300
300
|
*/
|
|
301
|
-
declare class EventDispatcher implements
|
|
301
|
+
declare class EventDispatcher implements IEventDispatcher {
|
|
302
302
|
constructor();
|
|
303
303
|
dispose(): void;
|
|
304
304
|
/**
|
|
@@ -1107,7 +1107,7 @@ declare class ViewController extends Controller {
|
|
|
1107
1107
|
* 当视图需要通过路由打开时,需要实现此方法
|
|
1108
1108
|
* @param route
|
|
1109
1109
|
*/
|
|
1110
|
-
open(route
|
|
1110
|
+
open(route?: Route): View;
|
|
1111
1111
|
protected onOpening(view: View): void;
|
|
1112
1112
|
protected onOpened(view: View): void;
|
|
1113
1113
|
protected onClosing(view: View): void;
|
|
@@ -2040,4 +2040,4 @@ declare class WidgetUtil {
|
|
|
2040
2040
|
declare var widgetutil: WidgetUtil;
|
|
2041
2041
|
|
|
2042
2042
|
export { ArrayUtil, AssetLoader, AssetURI, BitUtil, CallbackList, CameraUtil, CanvasUtil, Controller, ControllerDict, ControllerRepo, ConvertUtil, DictIterator, DictNode, DictSource, Dictionary, Dispatcher, DocUtil, ErrorUtil, EventDispatcher, EventItem, EventUtil, Factory, FloatUtil, GeometryUtil, IdentUtil, LOGGER_EVENT, LinkError, List, ListIterator, ListNode, ListSource, Listener, LogLevel, LogManager, Logger, MapUtil, MathUtil, Model, NetUtil, PageController, PathUtil, Pool, RandUtil, Route, RouteList, SampleCallbackList, SamplePool, SamplePoolSet, ScaleUtil, SimpleModel, StringUtil, TimeUtil, Timer, TreeIterator, TreeNode, TreeNodePlugin, TreeRoot, TreeRootPlugin, TreeUtil, UIManager, UIObjectDict, UIPoolConfig, UISingleConfig, UIUtil, View, ViewController, ViewDict, ViewEvent, ViewHistory, ViewList, ViewRepo, ViewState, WidgetAlign, WidgetUtil, XAssetManager, XEvent, arrayutil, assetx, bitutil, camerautil, canvasutil, convertutil, ctrlrepo, docutil, errorutil, eventmgr, eventutil, floatutil, formatutil, geoutil, identutil, loadAtlas, logmgr, maputil, mathutil, netutil, parseAtlas, parsePlist, pathutil, randutil, resutil, scaleutil, stringutil, timer, timeutil, treeutil, uidict, uimgr, uiutil, viewhistorys, viewrepo, widgetutil };
|
|
2043
|
-
export type { CreatorFunction, DisposeFunction, IController, IError,
|
|
2043
|
+
export type { CreatorFunction, DisposeFunction, IController, IError, IEventDispatcher, IExtend, IListItem, IModel, IModule, ITreeListItem, RecycleFunction };
|
package/dist/index.esm.js
CHANGED
|
@@ -991,7 +991,7 @@ class EventDispatcher {
|
|
|
991
991
|
eventPool.recycleObject(event);
|
|
992
992
|
}
|
|
993
993
|
toString() {
|
|
994
|
-
return `
|
|
994
|
+
return `EventDispatcher`;
|
|
995
995
|
}
|
|
996
996
|
getOnEventItems(type) {
|
|
997
997
|
let items = this._onEventItems[type];
|
|
@@ -3839,6 +3839,9 @@ class ViewController extends Controller {
|
|
|
3839
3839
|
* @param route
|
|
3840
3840
|
*/
|
|
3841
3841
|
open(route) {
|
|
3842
|
+
if (!route) {
|
|
3843
|
+
route = this.route;
|
|
3844
|
+
}
|
|
3842
3845
|
let oldView = viewrepo.getByRoute(route);
|
|
3843
3846
|
if (oldView) {
|
|
3844
3847
|
this.closeView(oldView);
|
|
@@ -3916,6 +3919,9 @@ class ViewController extends Controller {
|
|
|
3916
3919
|
* @returns
|
|
3917
3920
|
*/
|
|
3918
3921
|
close(route) {
|
|
3922
|
+
if (!route) {
|
|
3923
|
+
route = this.route;
|
|
3924
|
+
}
|
|
3919
3925
|
let view = viewrepo.getByRoute(route);
|
|
3920
3926
|
if (view) {
|
|
3921
3927
|
this.closeView(view);
|