| | |
| | | import com.usermodule.net.IUserDataCallBack; |
| | | import com.usermodule.net.UserNetManager; |
| | | |
| | | import org.greenrobot.eventbus.EventBus; |
| | | import org.greenrobot.eventbus.Subscribe; |
| | | import org.greenrobot.eventbus.ThreadMode; |
| | | |
| | | public class HdlToLcUtils { |
| | | |
| | | private Activity activity; |
| | | private Activity activity; |
| | | private String homeId; |
| | | private String token; |
| | | private String subAccessToken; |
| | | private IAddCamera iAddCamera; |
| | | |
| | | public Activity getActivity() { |
| | | public Activity getActivity() { |
| | | return activity; |
| | | } |
| | | |
| | |
| | | } |
| | | |
| | | public void addCamera(IAddCamera iAddCamera) { |
| | | if(!EventBus.getDefault().isRegistered(this)){ |
| | | EventBus.getDefault().register(this); |
| | | } |
| | | //开启添加页面 |
| | | activity.startActivity(new Intent(activity.getApplication(), DeviceAddActivity.class)); |
| | | |
| | | } |
| | | |
| | | @Subscribe(threadMode = ThreadMode.MAIN) |
| | | public void onGetMessage(String obj) { |
| | | if(obj.equals("backXamarin")){ |
| | | iAddCamera.back(); |
| | | |
| | | if(EventBus.getDefault().isRegistered(this)){ |
| | | EventBus.getDefault().unregister(this); |
| | | } |
| | | } |
| | | } |
| | | |
| | | public void play(String deviceId){ |