(First, let me state that my area of expertise is HTML5 (and php/coldfusion) and I am a beginner at Java/Android)
Inside my onCreateOptionsMenu I have the following code to handle a query change inside a search action in the android actionbar.
final SearchView.OnQueryTextListener queryTextListener = new SearchView.OnQueryTextListener() {
public boolean onQueryTextChange(String newText) {
//I want to call super.loadUrl from here
return true;
}
};
The problem is that I want to call the loadUrl method of phonegap every time the text changes, however this isn’t possible as super is seemingly referring to something else. I would probably be able to google this if I would even only know what the construction is called above (it seems to be some kind of sub class definition), but as I don’t know even that and super.super isn’t allowed I am at a total loss.
For reference: My class looks like
public class MainActivity extends DroidGap implements ActionBar.OnNavigationListener {
which is where the loadUrl comes from (I have also tried stuff in the direction of DroidGap.loadUrl).
I think your question might be missing some key points. Super refers to the superclass of the current object. In your case, the current object is queryTextListener, and super is a SearchView.OnQueryTextListener
Edits based on comment below:
In your containing method (same scope as final SearchView.OnQueryTextListener queryTextListener…) add a final ref to it, e.g.:
};