| | |
| | | package com.okgoincar.slab |
| | | |
| | | import android.content.Context |
| | | import android.content.Intent |
| | | import android.content.IntentFilter |
| | | import android.os.Bundle |
| | |
| | | import com.okgoincar.base.MyApplication |
| | | import com.okgoincar.bean.* |
| | | import com.okgoincar.netUtls.Api |
| | | import com.okgoincar.netUtls.sendAudio |
| | | import com.okgoincar.slab.event.SlabMineEventActivity |
| | | import com.okgoincar.slab.util.DialogUtil |
| | | import com.okgoincar.utils.DateUtil |
| | |
| | | initCall() |
| | | NettyClient.getInstance().startService() |
| | | callPersion() |
| | | showOrder("2221", "2", 100, 2) |
| | | // showOrder("2221", "2", 100, 2) |
| | | callVersion() |
| | | view_mode.isSelected = !getNowTimeBlack() |
| | | } |
| | | |
| | | |
| | |
| | | startActivity<SlabMineEventActivity>() |
| | | } |
| | | |
| | | tv_title_top.clickDelay { |
| | | } |
| | | |
| | | view_mode.clickDelay { |
| | | view_mode.isSelected = !view_mode.isSelected |
| | | if (getNowTimeBlack()){ |
| | | CacheKey.putKeyStr("date_mode",System.currentTimeMillis().toString()) |
| | | CacheKey.putKeyStr("mode_now_time","1")//记录为点击切换的颜色 1 白色 2 黑色 |
| | | setBlackMode(false) |
| | | }else{ |
| | | CacheKey.putKeyStr("date_mode",System.currentTimeMillis().toString()) |
| | | CacheKey.putKeyStr("mode_now_time","2") |
| | | setBlackMode(true) |
| | | } |
| | | |
| | | |
| | | } |
| | | |
| | | tv_car.clickDelay { |
| | | |
| | | // if (homeDataBean?.data?.work == 1) { |
| | | // callNet(true, Api.work2, getMapByAny()) { |
| | | // homeDataBean?.data?.work = 2 |
| | |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | private |
| | | var mBackAppTime: Long = 0 |
| | | |
| | |
| | | .show() |
| | | mBackAppTime = System.currentTimeMillis() |
| | | } else { |
| | | closeAll() |
| | | moveTaskToBack(true) |
| | | } |
| | | } |
| | | |
| | |
| | | var bean = gson.fromJson<VersionBean>(it, VersionBean::class.java) |
| | | if (bean.data.version != "" && bean.data.version != Utils.getAppVersion(this)) { |
| | | if (bean.data.mandatory == 0) { |
| | | var pop = DialogUtil.getSlabDelAndSurePopWindow(this, "有新版本是否更新", {}) { |
| | | var pop = DialogUtil.getSlabDelAndSurePopWindow(this, "确定" ,"取消","有新版本是否更新", {}) { |
| | | DownloadUtil(this).downloadAPK(bean.data.url, "ok出行车载端") |
| | | } |
| | | pop.showCenter(window.decorView) |
| | | } else { |
| | | var pop = DialogUtil.getSlabDelAndSurePopWindow(this, "版本已过时,是否强制升级?", {}) { |
| | | var pop = DialogUtil.getSlabDelAndSurePopWindow(this,"确定" ,"取消","版本已过时,是否强制升级?", {}) { |
| | | DownloadUtil(this).downloadAPK(bean.data.url, "ok出行车载端") |
| | | toast("后台开始下载,请等待") |
| | | } |