I looked all over for help on this. This finally worked for me.
public class MainActivity extends DroidGap {
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
super.loadUrl("file:///android_asset/www/index.html");
super.appView.setOnLongClickListener(new View.OnLongClickListener() {
public boolean onLongClick(View v) {
return true;
}
});
}
}
The setOnClickListener is what does the magic. Make sure you put this AFTER your call to super.loadUrl.
Of course, this will disable text selection for your entire app, but I'm OK with that, and I don't have any other way around it for now.
I'm not sure of the complete implications of this yet, but I do make use of the JqueryMobile event "taphold", and it still works fine. I believe this works by handling the long click on the appView (which hosts your HTML app) and preventing it from bubbling up.