5
onTouchListener警告:检测到单击时,onTouch应该调用View#performClick
我创建了一个onTouchListener。不幸的是,onTouch()向throws我发出警告: com/calculator/activitys/Calculator$1#onTouch should call View#performClick when a click is detected 这是什么意思?我尚未找到有关此警告的任何信息。这是完整的代码: LinearLayout llCalculatorContent = (LinearLayout) fragmentView.findViewById(R.id.calculator_content); llCalculatorContent.setOnTouchListener(new View.OnTouchListener() { @Override public boolean onTouch(View v, MotionEvent event) { Tools.hideKeyboard(getActivity(), getView()); getView().clearFocus(); return false; } });