remove reInit method
This commit is contained in:
parent
25508b0779
commit
e9197ec173
@ -3,6 +3,7 @@ package pub.doric.devkit;
|
||||
import pub.doric.DoricContext;
|
||||
import pub.doric.DoricContextManager;
|
||||
import pub.doric.DoricNativeDriver;
|
||||
import pub.doric.utils.DoricConstant;
|
||||
|
||||
public class DoricContextDebuggable {
|
||||
private DoricContext doricContext;
|
||||
@ -19,7 +20,10 @@ public class DoricContextDebuggable {
|
||||
@Override
|
||||
public void start() {
|
||||
doricContext.setDriver(doricDebugDriver);
|
||||
doricContext.reInit();
|
||||
|
||||
doricContext.getRootNode().setId("");
|
||||
doricContext.callEntity(DoricConstant.DORIC_ENTITY_INIT, doricContext.getInitParams(), doricContext.getExtra());
|
||||
doricContext.callEntity(DoricConstant.DORIC_ENTITY_CREATE);
|
||||
}
|
||||
});
|
||||
}
|
||||
@ -28,7 +32,10 @@ public class DoricContextDebuggable {
|
||||
isDebugging = false;
|
||||
doricDebugDriver.destroy();
|
||||
doricContext.setDriver(DoricNativeDriver.getInstance());
|
||||
doricContext.reInit();
|
||||
|
||||
doricContext.getRootNode().setId("");
|
||||
doricContext.callEntity(DoricConstant.DORIC_ENTITY_INIT, doricContext.getInitParams(), doricContext.getExtra());
|
||||
doricContext.callEntity(DoricConstant.DORIC_ENTITY_CREATE);
|
||||
}
|
||||
|
||||
public DoricContext getContext() {
|
||||
|
@ -127,12 +127,6 @@ public class DoricContext {
|
||||
callEntity(DoricConstant.DORIC_ENTITY_CREATE);
|
||||
}
|
||||
|
||||
public void reInit() {
|
||||
this.mRootNode.setId("");
|
||||
callEntity(DoricConstant.DORIC_ENTITY_INIT, this.initParams, extra);
|
||||
callEntity(DoricConstant.DORIC_ENTITY_CREATE);
|
||||
}
|
||||
|
||||
public AsyncResult<JSDecoder> callEntity(String methodName, Object... args) {
|
||||
return getDriver().invokeContextEntityMethod(mContextId, methodName, args);
|
||||
}
|
||||
@ -234,4 +228,11 @@ public class DoricContext {
|
||||
return this.animatorSet;
|
||||
}
|
||||
|
||||
public JSONObject getInitParams() {
|
||||
return initParams;
|
||||
}
|
||||
|
||||
public String getExtra() {
|
||||
return extra;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user