// Set the title.
dialogBuilder.setTitle(R.string.save_url)
- // Set the icon according to the theme.
- dialogBuilder.setIconAttribute(R.attr.copyBlueIcon)
+ // Set the icon.
+ dialogBuilder.setIcon(R.drawable.download)
// Set the view.
dialogBuilder.setView(R.layout.save_dialog)
val alertDialog = dialogBuilder.create()
// Get a handle for the shared preferences.
- val sharedPreferences = PreferenceManager.getDefaultSharedPreferences(context)
+ val sharedPreferences = PreferenceManager.getDefaultSharedPreferences(requireContext())
// Get the screenshot preference.
val allowScreenshots = sharedPreferences.getBoolean(getString(R.string.allow_screenshots_key), false)