public static String proxyMode = ProxyHelper.NONE;
// Declare the public static variables.
- public static String currentBookmarksFolder;
+ public static String currentBookmarksFolder = "";
public static boolean restartFromBookmarksActivity;
public static WebViewPagerAdapter webViewPagerAdapter;
// Run the default commands.
super.onNewIntent(intent);
- // Replace the intent that started the app with this one.
- setIntent(intent);
-
// Check to see if the app is being restarted from a saved state.
if (savedStateArrayList == null || savedStateArrayList.size() == 0) { // The activity is not being restarted from a saved state.
// Get the information from the intent.
drawerLayout.setDrawerTitle(GravityCompat.START, getString(R.string.navigation_drawer));
drawerLayout.setDrawerTitle(GravityCompat.END, getString(R.string.bookmarks));
- // Initialize `currentBookmarksFolder`. `""` is the home folder in the database.
- currentBookmarksFolder = "";
-
- // Load the home folder, which is `""` in the database.
+ // Load the bookmarks folder.
loadBookmarksFolder();
+ // Handle clicks on bookmarks.
bookmarksListView.setOnItemClickListener((parent, view, position, id) -> {
// Convert the id from long to int to match the format of the bookmarks database.
int databaseId = (int) id;