| | |
| | | import com.hdl.photovoltaic.base.CustomBaseFragment; |
| | | import com.hdl.photovoltaic.config.ConstantManage; |
| | | import com.hdl.photovoltaic.databinding.FragmentMessageBinding; |
| | | import com.hdl.photovoltaic.enums.MessageFunctionTabSwitch; |
| | | import com.hdl.photovoltaic.other.HdlCommonLogic; |
| | | import com.hdl.sdk.link.core.bean.eventbus.BaseEventBus; |
| | | |
| | |
| | | viewBinding.line1V.setVisibility(View.GONE); |
| | | viewBinding.line2V.setVisibility(View.VISIBLE); |
| | | viewBinding.line3V.setVisibility(View.GONE); |
| | | postEventBus(HdlCommonLogic.MessageFunctionTabSwitch.nascent); |
| | | postEventBus(MessageFunctionTabSwitch.nascent); |
| | | } else if (this.currentIndex == 1) { |
| | | viewBinding.messageTabAllTitleTv.setTextColor(getResources().getColor(R.color.text80_FFFFFF, null)); |
| | | viewBinding.messageTabNascentTitleTv.setTextColor(getResources().getColor(R.color.text80_FFFFFF, null)); |
| | |
| | | viewBinding.line1V.setVisibility(View.GONE); |
| | | viewBinding.line2V.setVisibility(View.GONE); |
| | | viewBinding.line3V.setVisibility(View.VISIBLE); |
| | | postEventBus(HdlCommonLogic.MessageFunctionTabSwitch.recover); |
| | | postEventBus(MessageFunctionTabSwitch.recover); |
| | | } else if (this.currentIndex == 2) { |
| | | viewBinding.messageTabAllTitleTv.setTextColor(getResources().getColor(R.color.text_FFFFFFFF, null)); |
| | | viewBinding.messageTabNascentTitleTv.setTextColor(getResources().getColor(R.color.text80_FFFFFF, null)); |
| | |
| | | viewBinding.line1V.setVisibility(View.VISIBLE); |
| | | viewBinding.line2V.setVisibility(View.GONE); |
| | | viewBinding.line3V.setVisibility(View.GONE); |
| | | postEventBus(HdlCommonLogic.MessageFunctionTabSwitch.all); |
| | | postEventBus(MessageFunctionTabSwitch.all); |
| | | } |
| | | } |
| | | |
| | |
| | | * |
| | | * @param tabSwitch - |
| | | */ |
| | | private void postEventBus(HdlCommonLogic.MessageFunctionTabSwitch tabSwitch) { |
| | | private void postEventBus(MessageFunctionTabSwitch tabSwitch) { |
| | | BaseEventBus baseEventBus = new BaseEventBus(); |
| | | baseEventBus.setTopic(ConstantManage.message_function_tab_switch); |
| | | baseEventBus.setType(tabSwitch + ""); |