I'm having trouble understanding the search dialog in the Android SDK.
The "main action" of my application provides a button. If the user clicks on this button, a search dialog is called up. The search itself is performed in the async task, as it may take some time. So far so good.
The main action also creates a database adapter object, which is used to initialize the database, execute queries, etc. But how can I use this adapter object in a search operation?
Primary activity
// Init database
DatabaseAdapter dba = new DatabaseAdapter();
dba.init();
// open search dialog
if (buttonClick) onSearchRequest();
Search activity
- Get Intent and Get Request from Search Dialog -> OK
- How can I use the database adapter again to execute a query?
? - , [...]?
,