]> gitweb.stoutner.com Git - PrivacyBrowserAndroid.git/blobdiff - app/src/main/java/com/stoutner/privacybrowser/dialogs/AboutViewSourceDialog.kt
Combine drawable files. https://redmine.stoutner.com/issues/794
[PrivacyBrowserAndroid.git] / app / src / main / java / com / stoutner / privacybrowser / dialogs / AboutViewSourceDialog.kt
index 013b8463e298850131fae2987505e0b664361688..8ac8331352479bf07b89684271dbb1c121e6aab0 100644 (file)
@@ -35,7 +35,7 @@ class AboutViewSourceDialog : DialogFragment() {
         val dialogBuilder = AlertDialog.Builder(requireContext(), R.style.PrivacyBrowserAlertDialog)
 
         // Set the icon according to the theme.
-        dialogBuilder.setIconAttribute(R.attr.aboutBlueIcon)
+        dialogBuilder.setIcon(R.drawable.about_blue)
 
         // Set the title.
         dialogBuilder.setTitle(R.string.about_view_source)
@@ -50,7 +50,7 @@ class AboutViewSourceDialog : DialogFragment() {
         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)