| | |
| | | import com.hdl.photovoltaic.R; |
| | | import com.hdl.photovoltaic.base.CustomBaseActivity; |
| | | import com.hdl.photovoltaic.config.AppConfigManage; |
| | | import com.hdl.photovoltaic.config.UserConfigManage; |
| | | import com.hdl.photovoltaic.databinding.ActivityAsRegardsBinding; |
| | | import com.hdl.photovoltaic.enums.ShowErrorMode; |
| | | import com.hdl.photovoltaic.listener.CloudCallBeak; |
| | | import com.hdl.photovoltaic.other.HdlAppUpdateLogic; |
| | | import com.hdl.photovoltaic.other.HdlCommonLogic; |
| | | import com.hdl.photovoltaic.other.HdlThreadLogic; |
| | | import com.hdl.photovoltaic.widget.FlashingBoxDialog; |
| | | import com.hdl.photovoltaic.widget.apkwgtupload.ApkDownLoadService; |
| | | import com.hdl.photovoltaic.widget.ConfirmationCancelDialog; |
| | | import com.hdl.photovoltaic.widget.UpdateConfirmationCancelDialog; |
| | |
| | | |
| | | @Override |
| | | public void onBindView(Bundle savedInstanceState) { |
| | | setNotificationBarBackgroundColor(CustomColor.white); |
| | | setStatusBarTextColor(); |
| | | setStatusBarTranslucent(); |
| | | getWindow().setNavigationBarColor(getColor(R.color.text_FF000000)); |
| | | //初始化 |
| | | initView(); |
| | | //初始化界面监听器 |
| | |
| | | if (newVersionBean != null) { |
| | | //todo 发现新版本,改变UI样式 |
| | | viewBinding.asRegardsRlRightContentTv.setText(R.string.app_discover_new_version); |
| | | viewBinding.asRegardsRlRightContentTv.setTextColor(getResources().getColor(R.color.text_245EC3, null)); |
| | | viewBinding.asRegardsRlRightContentTv.setTextColor(getResources().getColor(R.color.text_FFACACAC, null)); |
| | | } |
| | | } |
| | | |
| | |
| | | //测试环境 |
| | | content = "https://developer.hdlcontrol.com/AppDownload/HDLDebugerDownload.html"; |
| | | } |
| | | Bitmap bitmap = HdlCommonLogic.getInstance().createQRCodeBitmap(content, 168, 168, "UTF-8", "H", "1", Color.BLACK, Color.WHITE); |
| | | Bitmap bitmap = HdlCommonLogic.getInstance().createQRCodeBitmap(content, 168, 168, "UTF-8", "H", "0", getColor(R.color.text_00000000), Color.WHITE); |
| | | viewBinding.asRegardsQrCodeIv.setImageBitmap(bitmap); |
| | | |
| | | } |
| | |
| | | } |
| | | |
| | | private void initView() { |
| | | viewBinding.toolbarTopRl.topBarView.setBackgroundColor(getColor(R.color.text_00000000)); |
| | | viewBinding.toolbarTopRl.topTitleTv.setText(R.string.me_regard); |
| | | viewBinding.toolbarTopRl.topTitleTv.setTextColor(getResources().getColor(R.color.text_030D1C, null)); |
| | | viewBinding.toolbarTopRl.topBackLl.setVisibility(View.VISIBLE); |
| | | viewBinding.toolbarTopRl.topLeftIv.setImageResource(R.drawable.back_c); |
| | | viewBinding.toolbarTopRl.topBarView.setBackgroundColor(getResources().getColor(R.color.text_FFECECEC, null)); |
| | | String versionsStr = _mActivity.getResources().getString(R.string.app_version_number) + " " + AppConfigManage.getVersionName(); |
| | | viewBinding.asRegardsIconVersionsTv.setText(versionsStr); |
| | | |
| | |
| | | @Override |
| | | public void run() { |
| | | if (mNewVersionBean == null) { |
| | | HdlThreadLogic.toast(_mActivity, R.string.app_new_version); |
| | | FlashingBoxDialog flashingBoxDialog = new FlashingBoxDialog(_mActivity, 1500); |
| | | flashingBoxDialog.setContent(getString(R.string.app_new_version)); |
| | | flashingBoxDialog.show(); |
| | | return; |
| | | } |
| | | String app_version = getString(R.string.app_version) + ":" + mNewVersionBean.getVersion(); |