I am just making a simple browser with history management.
Perhaps you could look to an open source project like the Zirco Browser -> https://code.google.com/p/zirco-browser/
Some code like this > https://code.google.com/p/zirco-browser/source/browse/branches/tint-browser-old2/src/org/tint/controllers/BookmarksHistoryController.java
/**
* Get a Cursor the history, e.g. records wich have a visits count > 0. Sorted by last visited date.
* @param currentActivity The parent activity.
* @return A Cursor to history records.
* @see Cursor
*/
public Cursor getHistory(Activity currentActivity) {
String whereClause = Browser.BookmarkColumns.VISITS + " > 0";
String orderClause = Browser.BookmarkColumns.DATE + " DESC";
return currentActivity.managedQuery(android.provider.Browser.BOOKMARKS_URI, Browser.HISTORY_PROJECTION, whereClause, null, orderClause);
}
Perhaps you could copy some code and use it for your project.