| | |
| | | import com.hdl.linkpm.sdk.core.exception.HDLException; |
| | | import com.hdl.photovoltaic.R; |
| | | import com.hdl.photovoltaic.base.CustomBaseFragment; |
| | | import com.hdl.photovoltaic.config.ConstantManage; |
| | | import com.hdl.photovoltaic.config.UserConfigManage; |
| | | import com.hdl.photovoltaic.databinding.FragmentMeBinding; |
| | | import com.hdl.photovoltaic.listener.CloudCallBeak; |
| | | import com.hdl.photovoltaic.other.HdlAccountLogic; |
| | | import com.hdl.photovoltaic.other.HdlCommonLogic; |
| | | import com.hdl.photovoltaic.other.HdlLogLogic; |
| | | import com.hdl.photovoltaic.other.HdlThreadLogic; |
| | | import com.hdl.photovoltaic.ui.bean.BUserInfo; |
| | | import com.hdl.photovoltaic.ui.bean.CUserInfo; |
| | | import com.hdl.photovoltaic.ui.test.TestMainActivity; |
| | | import com.hdl.photovoltaic.utils.GlideUtils; |
| | | import com.hdl.sdk.link.core.bean.eventbus.BaseEventBus; |
| | | |
| | | /** |
| | | * 我的-界面 |
| | |
| | | HdlAccountLogic.getInstance().getMemberInfo_C(new CloudCallBeak<CUserInfo>() { |
| | | @Override |
| | | public void onSuccess(CUserInfo cUserInfo) { |
| | | if (cUserInfo == null) { |
| | | return; |
| | | } |
| | | mC_UserInfo = cUserInfo; |
| | | UserConfigManage.getInstance().setBingPhone(cUserInfo.getMemberPhone()); |
| | | UserConfigManage.getInstance().setBingEmail(cUserInfo.getMemberEmail()); |
| | | UserConfigManage.getInstance().Save(); |
| | | // hideLoading(); |
| | | //获取用户头像路径 |
| | | if (cUserInfo.getMemberHeadIcon().contains("http")) { |
| | |
| | | startActivity(AsRegardsActivity.class); |
| | | } |
| | | }); |
| | | final int[] count = {0}; |
| | | viewBinding.toolbarTopFragmentMeRl.topTitleTv.setOnClickListener(new View.OnClickListener() { |
| | | @Override |
| | | public void onClick(View v) { |
| | | startActivity(TestMainActivity.class); |
| | | count[0] = count[0] + 1; |
| | | if (count[0] > 3) { |
| | | count[0] = 0; |
| | | startActivity(TestMainActivity.class); |
| | | } |
| | | } |
| | | }); |
| | | |
| | |
| | | |
| | | |
| | | viewBinding.toolbarTopFragmentMeRl.topTitleTv.setText(R.string.me); |
| | | viewBinding.toolbarTopFragmentMeRl.topMoreIv.setVisibility(View.VISIBLE); |
| | | viewBinding.toolbarTopFragmentMeRl.topMoreIv.setImageResource(R.drawable.message); |
| | | // viewBinding.toolbarTopFragmentMeRl.topMoreIv.setVisibility(View.VISIBLE); |
| | | // viewBinding.toolbarTopFragmentMeRl.topMoreIv.setImageResource(R.drawable.message); |
| | | |
| | | viewBinding.fragmentMeLineMessageCenterIl.fragmentMeLineLeftIconIv.setImageResource(R.drawable.message_center); |
| | | viewBinding.fragmentMeLineMessageCenterIl.fragmentMeLineTitleIv.setText(R.string.set_message_center); |
| | |
| | | UserConfigManage.getInstance().Save(); |
| | | |
| | | } |
| | | |
| | | @Override |
| | | public void onEventMessage(BaseEventBus eventBus) { |
| | | super.onEventMessage(eventBus); |
| | | //接收外部点击事件 |
| | | if (eventBus.getTopic().equals(ConstantManage.homepage_title_tab_switch)) { |
| | | if (eventBus.getType().equals(HdlCommonLogic.HomepageTitleTabSwitch.me.toString())) { |
| | | // |
| | | HdlLogLogic.print("正在点击【我的】"); |
| | | } |
| | | } |
| | | } |
| | | } |