feat:add InjectEmpty to ignore too much logout

This commit is contained in:
pengfei.zhou
2019-11-26 13:32:07 +08:00
parent 9a9482eeb5
commit 208c635b8b
6 changed files with 15 additions and 2 deletions

View File

@@ -31,6 +31,8 @@ export function NativeCall(target: Panel, propertyKey: string, descriptor: Prope
type Frame = { width: number, height: number }
declare function nativeEmpty(): void
export abstract class Panel {
context?: any
onCreate() { }
@@ -132,7 +134,7 @@ export abstract class Panel {
private hookAfterNativeCall() {
//Here insert a native call to ensure the promise is resolved done.
log('Check Dirty')
nativeEmpty()
if (this.__root__.isDirty()) {
const model = this.__root__.toModel()
this.nativeRender(model)