use of com.eros.framework.model.WeexEventBean in project WeexErosFramework by bmfe.
the class TitleModule method setLeftItem.
@JSMethod(uiThread = true)
public void setLeftItem(String json, final JSCallback callback) {
WeexEventBean weexEventBean = new WeexEventBean();
weexEventBean.setKey(WXEventCenter.EVENT_LEFTITEM);
weexEventBean.setContext(mWXSDKInstance.getContext());
weexEventBean.setJscallback(callback);
weexEventBean.setJsParams(json);
weexEventBean.setExpand(mWXSDKInstance.hashCode());
ManagerFactory.getManagerService(DispatchEventManager.class).getBus().post(weexEventBean);
}
use of com.eros.framework.model.WeexEventBean in project WeexErosFramework by bmfe.
the class TitleModule method setRightItem.
@JSMethod(uiThread = true)
public void setRightItem(String json, final JSCallback callback) {
WeexEventBean weexEventBean = new WeexEventBean();
weexEventBean.setKey(WXEventCenter.EVENT_RIGHTITEM);
weexEventBean.setContext(mWXSDKInstance.getContext());
weexEventBean.setJscallback(callback);
weexEventBean.setJsParams(json);
weexEventBean.setExpand(mWXSDKInstance.hashCode());
ManagerFactory.getManagerService(DispatchEventManager.class).getBus().post(weexEventBean);
}
use of com.eros.framework.model.WeexEventBean in project WeexErosFramework by bmfe.
the class TitleModule method setCenterItem.
@JSMethod(uiThread = true)
public void setCenterItem(String json, final JSCallback callback) {
WeexEventBean weexEventBean = new WeexEventBean();
weexEventBean.setKey(WXEventCenter.EVENT_CENTERITEM);
weexEventBean.setContext(mWXSDKInstance.getContext());
weexEventBean.setJscallback(callback);
weexEventBean.setJsParams(json);
weexEventBean.setExpand(mWXSDKInstance.hashCode());
ManagerFactory.getManagerService(DispatchEventManager.class).getBus().post(weexEventBean);
}
use of com.eros.framework.model.WeexEventBean in project WeexErosFramework by bmfe.
the class TitleModule method setNavigationInfo.
@JSMethod(uiThread = true)
public void setNavigationInfo(String json, JSCallback callback) {
WeexEventBean weexEventBean = new WeexEventBean();
weexEventBean.setKey(WXEventCenter.EVENT_NAVIGATIONINFO);
weexEventBean.setContext(mWXSDKInstance.getContext());
weexEventBean.setJscallback(callback);
weexEventBean.setJsParams(json);
weexEventBean.setExpand(mWXSDKInstance.hashCode());
ManagerFactory.getManagerService(DispatchEventManager.class).getBus().post(weexEventBean);
}
use of com.eros.framework.model.WeexEventBean in project WeexErosFramework by bmfe.
the class SplashActivityProxy method toHome.
private void toHome(Activity activity) {
String homePage = BMWXEnvironment.mPlatformConfig.getPage().getHomePage(activity);
String NavigationColor = BMWXEnvironment.mPlatformConfig.getPage().getNavBarColor();
RouterModel router = new RouterModel(homePage, Constant.ACTIVITIES_ANIMATION.ANIMATION_PUSH, null, null, false, null);
DispatchEventManager dispatchEventManager = ManagerFactory.getManagerService(DispatchEventManager.class);
WeexEventBean eventBean = new WeexEventBean();
eventBean.setKey(WXEventCenter.EVENT_OPEN);
eventBean.setJsParams(ManagerFactory.getManagerService(ParseManager.class).toJsonString(router));
eventBean.setContext(activity);
dispatchEventManager.getBus().post(eventBean);
activity.finish();
}
Aggregations