Hi, in \frameworks\base\core\java\android\view\View.java,
View.setOnLongClickListener will enable long click:
public void setOnLongClickListener(OnLongClickListener l) {
if (!isLongClickable()) {
setLongClickable(true);
}
getListenerInfo().mOnLongClickListener = l;
}
So in your code, you first disable it, then enable it.
From: Crosswalk-help
[mailto:[email protected]] On Behalf Of �v介
Sent: Tuesday, March 24, 2015 1:40 PM
To: [email protected]
Subject: [Crosswalk-help] Cancellation of LongClick is ignored in the latest
Crosswalk
I tried to upgrade CrossWalk which using in my Android project to Ver 11 from
Ver 10. however, when I installed 1.40.277.7, it became impossible to cancel
LongClick event irrespective of the existence of this code.
this.appView.setLongClickable(false);
this.appView.setOnLongClickListener(new OnLongClickListener() {
@Override
public boolean onLongClick(View v) {
return true;
}
});
Is this a buf on CrossWalk 11? Or was the method which canceling the LongClick
event changed?
_______________________________________________
Crosswalk-help mailing list
[email protected]
https://lists.crosswalk-project.org/mailman/listinfo/crosswalk-help