| | |
| | | import android.os.SystemClock; |
| | | import android.provider.Settings; |
| | | import android.text.TextUtils; |
| | | import android.util.Log; |
| | | import android.view.View; |
| | | import android.widget.TextView; |
| | | |
| | |
| | | import com.hdl.sdk.link.core.config.HDLLinkConfig; |
| | | import com.hdl.sdk.link.core.connect.HDLUdpConnect; |
| | | import com.hdl.sdk.link.core.utils.mqtt.MqttRecvClient; |
| | | import com.umeng.analytics.MobclickAgent; |
| | | |
| | | import org.greenrobot.eventbus.Subscribe; |
| | | import org.greenrobot.eventbus.ThreadMode; |
| | |
| | | fragmentList.add(mFragmentManager.findFragmentByTag(3 + "")); |
| | | restoreFragment();//恢复fragment页面 |
| | | } else { |
| | | //正常启动时调用 |
| | | fragmentList.add(mHomePageFragment); |
| | | fragmentList.add(mHouseAndDeviceFragment); |
| | | fragmentList.add(mMessageFragment); |
| | | fragmentList.add(mMeFragment); |
| | | showFragment(); |
| | | //正常启动时调用 |
| | | fragmentList.add(mHomePageFragment); |
| | | fragmentList.add(mHouseAndDeviceFragment); |
| | | fragmentList.add(mMessageFragment); |
| | | fragmentList.add(mMeFragment); |
| | | showFragment(); |
| | | } |
| | | |
| | | } |
| | |
| | | } |
| | | } |
| | | ft.commit(); |
| | | |
| | | } |
| | | |
| | | |
| | |
| | | return; |
| | | } |
| | | int index = -1; |
| | | List<GatewayBean> list = HdlDeviceLogic.getInstance().getCurrentHomeGatewayList(UserConfigManage.getInstance().getHomeId()); |
| | | List<GatewayBean> list = HdlDeviceLogic.getInstance().getCurrentHomeGatewayList(UserConfigManage.getInstance().getHomeId(), null); |
| | | for (int i = 0; i < list.size(); i++) { |
| | | GatewayBean gatewayBean = list.get(i); |
| | | if (gatewayBean.getGatewayId().equals(topics[2])) { |
| | |
| | | return; |
| | | } else { |
| | | AppManagerUtils.getAppManager().finishAllActivity(); |
| | | //如果开发者调用kill或者exit之类的方法杀死进程,或者双击back键会杀死进程,请务必在此之前调用MobclickAgent.onKillProcess方法,用来保存统计数据。 |
| | | MobclickAgent.onKillProcess(_mActivity); |
| | | Process.killProcess(Process.myPid()); |
| | | |
| | | } |
| | | } |
| | | super.onBackPressed(); |