use of com.benmu.framework.model.WeexEventBean in project WeexErosFramework by bmfe.
the class AxiosModule method fetch.
@JSMethod(uiThread = false)
public void fetch(String params, final JSCallback jsCallback) {
WeexEventBean eventBean = new WeexEventBean();
eventBean.setContext(mWXSDKInstance.getContext());
eventBean.setKey(WXConstant.WXEventCenter.EVENT_FETCH);
eventBean.setJsParams(params);
eventBean.setJscallback(jsCallback);
ManagerFactory.getManagerService(DispatchEventManager.class).getBus().post(eventBean);
}
use of com.benmu.framework.model.WeexEventBean in project WeexErosFramework by bmfe.
the class BrowserImgModule method open.
@JSMethod(uiThread = true)
public void open(String json) {
WeexEventBean eventBean = new WeexEventBean();
eventBean.setContext(mWXSDKInstance.getContext());
eventBean.setKey(WXConstant.WXEventCenter.EVENT_BROWSERIMG);
eventBean.setJsParams(json);
ManagerFactory.getManagerService(DispatchEventManager.class).getBus().post(eventBean);
}
use of com.benmu.framework.model.WeexEventBean in project WeexErosFramework by bmfe.
the class CameraModule method uploadScreenshot.
@JSMethod(uiThread = true)
public void uploadScreenshot(JSCallback callback) {
WeexEventBean eventBean = new WeexEventBean();
eventBean.setContext(mWXSDKInstance.getContext());
eventBean.setKey(WXConstant.WXEventCenter.EVENT_CAMERA_UPLOADSCREENSHOT);
eventBean.setJscallback(callback);
ManagerFactory.getManagerService(DispatchEventManager.class).getBus().post(eventBean);
}
use of com.benmu.framework.model.WeexEventBean in project WeexErosFramework by bmfe.
the class CameraModule method scan.
@JSMethod(uiThread = true)
public void scan(JSCallback callback) {
WeexEventBean eventBean = new WeexEventBean();
eventBean.setContext(mWXSDKInstance.getContext());
eventBean.setKey(WXConstant.WXEventCenter.EVENT_CAMERA);
eventBean.setJscallback(callback);
ManagerFactory.getManagerService(DispatchEventManager.class).getBus().post(eventBean);
}
use of com.benmu.framework.model.WeexEventBean in project WeexErosFramework by bmfe.
the class CommunicationModule method sms.
@JSMethod
public void sms(String recipients, String params, JSCallback callback) {
WeexEventBean weexEventBean = new WeexEventBean();
weexEventBean.setKey(WXConstant.WXEventCenter.EVENT_COMMUNICATION_SMS);
weexEventBean.setContext(mWXSDKInstance.getContext());
weexEventBean.setJsParams(params);
weexEventBean.setJscallback(callback);
weexEventBean.setExpand(recipients);
ManagerFactory.getManagerService(DispatchEventManager.class).getBus().post(weexEventBean);
}
Aggregations