张钢
2024-09-02 63608b5dca9eebb6fa2cb1a8652b395f1d910c3e
app/src/main/java/com/application/zhangshi_app_android/ui/function/HomeDevicesActivity.java
@@ -76,8 +76,7 @@
        setOnClickListener(
                mOperatePopupWindow.getContentView().findViewById(R.id.tv_add),
                mOperatePopupWindow.getContentView().findViewById(R.id.tv_select),
                mOperatePopupWindow.getContentView().findViewById(R.id.tv_from_new_to_old),
                mOperatePopupWindow.getContentView().findViewById(R.id.tv_from_old_to_new)
                mOperatePopupWindow.getContentView().findViewById(R.id.tv_own_top)
        );
        //点击放大镜按钮显示出搜索框
        binding.ivSearchDefault.setOnClickListener(v -> {
@@ -308,11 +307,8 @@
        }else if (id == R.id.tv_select){
            viewModel.getOperateTypeLiveData().postValue(1);
            mOperatePopupWindow.dismiss();
        }else if (id == R.id.tv_from_new_to_old) {
            viewModel.changeOrder(true);
            mOperatePopupWindow.dismiss();
        } else if (id == R.id.tv_from_old_to_new) {
            viewModel.changeOrder(false);
        }else if (id == R.id.tv_own_top) {
            viewModel.ownTop();
            mOperatePopupWindow.dismiss();
        }
    }