]> gitweb.stoutner.com Git - PrivacyBrowserAndroid.git/commitdiff
Add icons to `DomainSettingsFragment`.
authorSoren Stoutner <soren@stoutner.com>
Sat, 11 Mar 2017 22:41:00 +0000 (15:41 -0700)
committerSoren Stoutner <soren@stoutner.com>
Sat, 11 Mar 2017 22:41:00 +0000 (15:41 -0700)
56 files changed:
.idea/dictionaries/soren.xml
app/src/main/AndroidManifest.xml
app/src/main/assets/de/about_licenses.html
app/src/main/assets/en/about_licenses.html
app/src/main/assets/en/images/ic_devices_other.png [new file with mode: 0644]
app/src/main/assets/en/images/ic_text_fields.png [new file with mode: 0644]
app/src/main/assets/es/about_licenses.html
app/src/main/assets/it/about_licenses.html
app/src/main/java/com/stoutner/privacybrowser/activities/DomainSettingsActivity.java
app/src/main/java/com/stoutner/privacybrowser/activities/DomainsActivity.java
app/src/main/java/com/stoutner/privacybrowser/fragments/AboutTabFragment.java
app/src/main/java/com/stoutner/privacybrowser/fragments/DomainSettingsFragment.java
app/src/main/java/com/stoutner/privacybrowser/helpers/DomainsDatabaseHelper.java
app/src/main/res/drawable/about.xml
app/src/main/res/drawable/add.xml
app/src/main/res/drawable/back.xml
app/src/main/res/drawable/bookmarks.xml
app/src/main/res/drawable/close.xml
app/src/main/res/drawable/cookies_disabled.xml
app/src/main/res/drawable/cookies_enabled.xml
app/src/main/res/drawable/create_folder.xml
app/src/main/res/drawable/delete.xml
app/src/main/res/drawable/dom_storage_disabled.xml
app/src/main/res/drawable/dom_storage_enabled.xml
app/src/main/res/drawable/dom_storage_ghosted.xml
app/src/main/res/drawable/domains.xml
app/src/main/res/drawable/downloads.xml
app/src/main/res/drawable/edit.xml
app/src/main/res/drawable/exit.xml
app/src/main/res/drawable/folder_dark_blue.xml
app/src/main/res/drawable/folder_gray.xml
app/src/main/res/drawable/font_size.xml [new file with mode: 0644]
app/src/main/res/drawable/form_data_disabled.xml
app/src/main/res/drawable/form_data_enabled.xml
app/src/main/res/drawable/forward.xml
app/src/main/res/drawable/guide.xml
app/src/main/res/drawable/history.xml
app/src/main/res/drawable/home.xml
app/src/main/res/drawable/javascript_enabled.xml
app/src/main/res/drawable/move_bookmark_down_disabled.xml
app/src/main/res/drawable/move_bookmark_down_enabled.xml
app/src/main/res/drawable/move_bookmark_up_disabled.xml
app/src/main/res/drawable/move_bookmark_up_enabled.xml
app/src/main/res/drawable/move_to_folder.xml
app/src/main/res/drawable/next.xml
app/src/main/res/drawable/previous.xml
app/src/main/res/drawable/privacy_mode.xml
app/src/main/res/drawable/select_all.xml
app/src/main/res/drawable/settings.xml
app/src/main/res/drawable/user_agent.xml [new file with mode: 0644]
app/src/main/res/drawable/warning.xml
app/src/main/res/layout-w900dp/domains_list.xml
app/src/main/res/layout/domain_settings.xml
app/src/main/res/layout/url_app_bar.xml
app/src/main/res/values/strings.xml
app/src/main/res/values/styles.xml

index 84598132016850834f944215305d0c325178cdef..4833f591d15cf82b005e01c3618fc3c8ebfe952c 100644 (file)
@@ -23,6 +23,7 @@
       <w>cname</w>
       <w>commitdiff</w>
       <w>coordinatorlayout</w>
+      <w>customuseragent</w>
       <w>didn</w>
       <w>displayorder</w>
       <w>dname</w>
       <w>dwallach</w>
       <w>eadd</w>
       <w>edittext</w>
+      <w>enabledomstorage</w>
+      <w>enablefirstpartycookies</w>
+      <w>enableformdata</w>
+      <w>enablejavascript</w>
+      <w>enablethirdpartycookies</w>
       <w>exynos</w>
       <w>favoriteicon</w>
       <w>fbee</w>
       <w>fdfilter</w>
       <w>fdid</w>
       <w>firebase</w>
+      <w>fontsize</w>
       <w>framelayout</w>
       <w>gerlach</w>
       <w>intl</w>
@@ -86,6 +93,9 @@
       <w>torproject</w>
       <w>uids</w>
       <w>uname</w>
+      <w>useragent</w>
+      <w>useragentname</w>
+      <w>useragentstring</w>
       <w>webkay</w>
       <w>webkitversion</w>
       <w>whatismyip</w>
index 429fa66e0252980a201e4bb71f3e22499a16fc01..2d572fa7a49d6111e55860f24d6d32ae2bf36965 100644 (file)
 
         <!-- `android:configChanges="orientation|screenSize"` makes the activity not reload when the orientation changes.
             `android:persistableMode="persistNever"` removes Privacy Browser from the recents screen on a device reboot.
-            `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21. -->
+            `tools:ignore="unusedAttribute"` removes the lint warning that `persistableMode` does not apply to API < 21.
+             `android:windowSoftInputMode="stateAlwaysHidden"` removes the keyboard from the screen, which is displayed because `ScrollViews` always focus the first `EditText` despite being told not to. -->
         <activity
             android:name=".activities.DomainSettingsActivity"
             android:label="@string/domain_settings"
             android:parentActivityName=".activities.DomainsActivity"
             android:configChanges="orientation|screenSize"
             android:screenOrientation="fullUser"
+            android:windowSoftInputMode="stateAlwaysHidden"
             android:persistableMode="persistNever"
             tools:ignore="UnusedAttribute" />
 
index ecbb9b5d4a5eb058ee931d07b151e9ce4933c1e5..dab96de5fa5bf4ac47ca12a97c1b84a7d9dd1710 100644 (file)
@@ -65,6 +65,7 @@
         <p><img class="icon" src="../en/images/ic_chrome_reader_mode.png"> ic_chrome_reader_mode.</p>
         <p><img class="icon" src="../en/images/ic_close.png"> ic_close.</p>
         <p><img class="icon" src="../en/images/ic_create_new_folder.png"> ic_create_new_folder.</p>
+        <p><img class="icon" src="../en/images/ic_devices_other.png"> ic_devices_other.</p>
         <p><img class="icon" src="../en/images/ic_delete.png"> ic_download.</p>
         <p><img class="icon" src="../en/images/ic_dns.png"> ic_dns.</p>
         <p><img class="icon" src="../en/images/ic_edit.png"> ic_edit.</p>
@@ -84,6 +85,7 @@
         <p><img class="icon" src="../en/images/ic_select_all.png"> ic_select_all.</p>
         <p><img class="icon" src="../en/images/ic_settings.png"> ic_settings.</p>
         <p><img class="icon" src="../en/images/ic_subtitles.png"> ic_subtitles.</p>
+        <p><img class="icon" src="../en/images/ic_text_fields.png"> ic_text_fields.</p>
         <p><img class="icon" src="../en/images/ic_vertical_align_bottom.png"> ic_vertical_align_bottom.</p>
         <p><img class="icon" src="../en/images/ic_vertical_align_top.png"> ic_vertical_align_top.</p>
         <p><img class="icon" src="../en/images/ic_web.png"> ic_web.</p>
index 45d31095232b8be344c0856476c8775b089459cb..290ef38fc2bf779bae508cdb8503f98131d7c66d 100644 (file)
@@ -63,6 +63,7 @@
         <p><img class="icon" src="images/ic_chrome_reader_mode.png"> ic_chrome_reader_mode.</p>
         <p><img class="icon" src="images/ic_close.png"> ic_close.</p>
         <p><img class="icon" src="images/ic_create_new_folder.png"> ic_create_new_folder.</p>
+        <p><img class="icon" src="images/ic_devices_other.png"> ic_devices_other.</p>
         <p><img class="icon" src="images/ic_delete.png"> ic_download.</p>
         <p><img class="icon" src="images/ic_dns.png"> ic_dns.</p>
         <p><img class="icon" src="images/ic_edit.png"> ic_edit.</p>
@@ -82,6 +83,7 @@
         <p><img class="icon" src="images/ic_select_all.png"> ic_select_all.</p>
         <p><img class="icon" src="images/ic_settings.png"> ic_settings.</p>
         <p><img class="icon" src="images/ic_subtitles.png"> ic_subtitles.</p>
+        <p><img class="icon" src="images/ic_text_fields.png"> ic_text_fields.</p>
         <p><img class="icon" src="images/ic_vertical_align_bottom.png"> ic_vertical_align_bottom.</p>
         <p><img class="icon" src="images/ic_vertical_align_top.png"> ic_vertical_align_top.</p>
         <p><img class="icon" src="images/ic_web.png"> ic_web.</p>
diff --git a/app/src/main/assets/en/images/ic_devices_other.png b/app/src/main/assets/en/images/ic_devices_other.png
new file mode 100644 (file)
index 0000000..dcf7e12
Binary files /dev/null and b/app/src/main/assets/en/images/ic_devices_other.png differ
diff --git a/app/src/main/assets/en/images/ic_text_fields.png b/app/src/main/assets/en/images/ic_text_fields.png
new file mode 100644 (file)
index 0000000..de55836
Binary files /dev/null and b/app/src/main/assets/en/images/ic_text_fields.png differ
index 8cc49e4dc465c19ed757576d23a8b6a22baf4adf..0ffc6ab8adee426169de47c5b2813bccee72f044 100644 (file)
@@ -63,6 +63,7 @@
         <p><img class="icon" src="../en/images/ic_chrome_reader_mode.png"> ic_chrome_reader_mode.</p>
         <p><img class="icon" src="../en/images/ic_close.png"> ic_close.</p>
         <p><img class="icon" src="../en/images/ic_create_new_folder.png"> ic_create_new_folder.</p>
+        <p><img class="icon" src="../en/images/ic_devices_other.png"> ic_devices_other.</p>
         <p><img class="icon" src="../en/images/ic_delete.png"> ic_download.</p>
         <p><img class="icon" src="../en/images/ic_dns.png"> ic_dns.</p>
         <p><img class="icon" src="../en/images/ic_edit.png"> ic_edit.</p>
@@ -82,6 +83,7 @@
         <p><img class="icon" src="../en/images/ic_select_all.png"> ic_select_all.</p>
         <p><img class="icon" src="../en/images/ic_settings.png"> ic_settings.</p>
         <p><img class="icon" src="../en/images/ic_subtitles.png"> ic_subtitles.</p>
+        <p><img class="icon" src="../en/images/ic_text_fields.png"> ic_text_fields.</p>
         <p><img class="icon" src="../en/images/ic_vertical_align_bottom.png"> ic_vertical_align_bottom.</p>
         <p><img class="icon" src="../en/images/ic_vertical_align_top.png"> ic_vertical_align_top.</p>
         <p><img class="icon" src="../en/images/ic_web.png"> ic_web.</p>
index 60b4a6002d6cb500f506f3c6334737baa4191b65..43b9435099f2763379055237fbc2b532f59b149f 100644 (file)
@@ -69,6 +69,7 @@
         <p><img class="icon" src="../en/images/ic_chrome_reader_mode.png"> ic_chrome_reader_mode.</p>
         <p><img class="icon" src="../en/images/ic_close.png"> ic_close.</p>
         <p><img class="icon" src="../en/images/ic_create_new_folder.png"> ic_create_new_folder.</p>
+        <p><img class="icon" src="../en/images/ic_devices_other.png"> ic_devices_other.</p>
         <p><img class="icon" src="../en/images/ic_delete.png"> ic_download.</p>
         <p><img class="icon" src="../en/images/ic_dns.png"> ic_dns.</p>
         <p><img class="icon" src="../en/images/ic_edit.png"> ic_edit.</p>
@@ -88,6 +89,7 @@
         <p><img class="icon" src="../en/images/ic_select_all.png"> ic_select_all.</p>
         <p><img class="icon" src="../en/images/ic_settings.png"> ic_settings.</p>
         <p><img class="icon" src="../en/images/ic_subtitles.png"> ic_subtitles.</p>
+        <p><img class="icon" src="../en/images/ic_text_fields.png"> ic_text_fields.</p>
         <p><img class="icon" src="../en/images/ic_vertical_align_bottom.png"> ic_vertical_align_bottom.</p>
         <p><img class="icon" src="../en/images/ic_vertical_align_top.png"> ic_vertical_align_top.</p>
         <p><img class="icon" src="../en/images/ic_web.png"> ic_web.</p>
index ae3afa968f507e97fc7894aa3a493148697c3aec..eba5f321f663cfa8ba514141006068b32d80c499 100644 (file)
@@ -46,8 +46,8 @@ public class DomainSettingsActivity extends AppCompatActivity {
         // Get the intent that started the activity.
         final Intent launchingIntent = getIntent();
 
-        // Extract the `databaseID`.  The default value is `0`.
-        int databaseId = launchingIntent.getIntExtra(DomainSettingsFragment.DATABASE_ID, 0);
+        // Extract the `databaseID`.  The default value is `1`.
+        int databaseId = launchingIntent.getIntExtra(DomainSettingsFragment.DATABASE_ID, 1);
 
         // Store `databaseId` in `argumentsBundle`.
         Bundle argumentsBundle = new Bundle();
index 0cc4d506d90d9ee237382076ccaaaa43cb804aa2..7cbe8d053b2007279e39259b48f5b2b8fb8816d9 100644 (file)
@@ -67,7 +67,7 @@ public class DomainsActivity extends AppCompatActivity implements AddDomainDialo
         domainsDatabaseHelper = new DomainsDatabaseHelper(this, null, null, 0);
 
         // Determine if we are in two pane mode.  `domains_settings_linearlayout` is only populated if two panes are present.
-        final boolean twoPaneMode = ((findViewById(R.id.domain_settings_linearlayout)) != null);
+        final boolean twoPaneMode = ((findViewById(R.id.domain_settings_scrollview)) != null);
 
         // Initialize `domainsListView`.
         domainsListView = (ListView) findViewById(R.id.domains_listview);
@@ -80,9 +80,6 @@ public class DomainsActivity extends AppCompatActivity implements AddDomainDialo
 
                 // Display the Domain Settings.
                 if (twoPaneMode) {  // Display a fragment in two paned mode.
-                    // Highlight the selected domain.
-                    domainsListView.setItemChecked(position, true);
-
                     // Store `databaseId` in `argumentsBundle`.
                     Bundle argumentsBundle = new Bundle();
                     argumentsBundle.putInt(DomainSettingsFragment.DATABASE_ID, databaseId);
@@ -92,7 +89,7 @@ public class DomainsActivity extends AppCompatActivity implements AddDomainDialo
                     domainSettingsFragment.setArguments(argumentsBundle);
 
                     // Display `domainSettingsFragment`.
-                    getSupportFragmentManager().beginTransaction().replace(R.id.domain_settings_linearlayout, domainSettingsFragment).commit();
+                    getSupportFragmentManager().beginTransaction().replace(R.id.domain_settings_scrollview, domainSettingsFragment).commit();
                 } else { // Load the second activity on smaller screens.
                     // Get a handle for the context.
                     Context context = view.getContext();
index b3e9e5a44fa4c44bbf25cf14401db0351b5ac409..fec8d70c0707c5465212f90053d07f9de689b619 100644 (file)
@@ -37,7 +37,7 @@ import com.stoutner.privacybrowser.R;
 public class AboutTabFragment extends Fragment {
     private int tabNumber;
 
-    // AboutTabFragment.createTab stores the tab number in the bundle arguments so it can be referenced from onCreate().
+    // `AboutTabFragment.createTab` stores the tab number in the bundle arguments so it can be referenced from `onCreate()`.
     public static AboutTabFragment createTab(int tab) {
         Bundle thisTabArguments = new Bundle();
         thisTabArguments.putInt("Tab", tab);
@@ -51,7 +51,7 @@ public class AboutTabFragment extends Fragment {
     public void onCreate(Bundle savedInstanceState) {
         super.onCreate(savedInstanceState);
 
-        // Store the tab number in tabNumber.
+        // Store the tab number in `tabNumber`.
         tabNumber = getArguments().getInt("Tab");
     }
 
index 3e28fc7fbc54124833f07e22476fa2c521ec3784..a621417414f34674dbe6fda6c842de138c82dc16 100644 (file)
@@ -19,6 +19,7 @@
 
 package com.stoutner.privacybrowser.fragments;
 
+import android.content.Context;
 import android.database.Cursor;
 import android.os.Bundle;
 // We have to use `android.support.v4.app.Fragment` until minimum API >= 23.  Otherwise we cannot call `getContext()`.
@@ -26,7 +27,9 @@ import android.support.v4.app.Fragment;
 import android.view.LayoutInflater;
 import android.view.View;
 import android.view.ViewGroup;
+import android.widget.ArrayAdapter;
 import android.widget.EditText;
+import android.widget.Spinner;
 
 import com.stoutner.privacybrowser.R;
 import com.stoutner.privacybrowser.helpers.DomainsDatabaseHelper;
@@ -51,6 +54,14 @@ public class DomainSettingsFragment extends Fragment {
         // Inflate `domain_settings`.  `false` does not attach it to the root `container`.
         View domainSettingsView = inflater.inflate(R.layout.domain_settings, container, false);
 
+        // Get a handle for the `Context`.
+        Context context = getContext();
+
+        // Get handles for the views in the fragment.
+        EditText domainNameEditText = (EditText) domainSettingsView.findViewById(R.id.domain_settings_name_edittext);
+        Spinner userAgentSpinner = (Spinner) domainSettingsView.findViewById(R.id.domain_settings_user_agent_spinner);
+        Spinner fontSizeSpinner = (Spinner) domainSettingsView.findViewById(R.id.domain_settings_font_size_spinner);
+
         // Initialize the database handler.  `this` specifies the context.  The two `nulls` do not specify the database name or a `CursorFactory`.
         // The `0` specifies the database version, but that is ignored and set instead using a constant in `DomainsDatabaseHelper`.
         DomainsDatabaseHelper domainsDatabaseHelper = new DomainsDatabaseHelper(getContext(), null, null, 0);
@@ -59,11 +70,34 @@ public class DomainSettingsFragment extends Fragment {
         Cursor domainCursor = domainsDatabaseHelper.getCursorForId(databaseId);
         domainCursor.moveToFirst();
 
-        // Get handles for the `EditTexts`.
-        EditText domainNameEditText = (EditText) domainSettingsView.findViewById(R.id.domain_settings_name_edittext);
+        // Save the `Cursor` entries as variables.
+        String domainNameString = domainCursor.getString(domainCursor.getColumnIndex(DomainsDatabaseHelper.DOMAIN));
+        int fontSizeInt = domainCursor.getInt(domainCursor.getColumnIndex(DomainsDatabaseHelper.FONT_SIZE));
+
+        // Create `ArrayAdapters` for the `Spinners`and their `entry values`.
+        ArrayAdapter<CharSequence> userAgentArrayAdapter = ArrayAdapter.createFromResource(context, R.array.user_agent_entries, android.R.layout.simple_spinner_item);
+        ArrayAdapter<CharSequence> userAgentEntryValuesArrayAdapter = ArrayAdapter.createFromResource(context, R.array.user_agent_entry_values, android.R.layout.simple_spinner_item);
+        ArrayAdapter<CharSequence> fontSizeArrayAdapter = ArrayAdapter.createFromResource(context, R.array.default_font_size_entries, android.R.layout.simple_spinner_item);
+        ArrayAdapter<CharSequence> fontSizeEntryValuesArrayAdapter = ArrayAdapter.createFromResource(context, R.array.default_font_size_entry_values, android.R.layout.simple_spinner_item);
+
+        // Set the drop down style for the `ArrayAdapters`.
+        userAgentArrayAdapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
+        fontSizeArrayAdapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
+
+        // Set the `ArrayAdapters` for the `Spinners`.
+        userAgentSpinner.setAdapter(userAgentArrayAdapter);
+        fontSizeSpinner.setAdapter(fontSizeArrayAdapter);
+
+        //
+        // int userAgentArrayPosition =
+
+        // Set the selected font size.
+        int fontSizeArrayPosition = fontSizeEntryValuesArrayAdapter.getPosition(String.valueOf(fontSizeInt));
+        fontSizeSpinner.setSelection(fontSizeArrayPosition);
+
 
         // Set the text from the database cursor.
-        domainNameEditText.setText(domainCursor.getString(domainCursor.getColumnIndex(DomainsDatabaseHelper.DOMAIN)));
+        domainNameEditText.setText(domainNameString);
 
         return domainSettingsView;
     }
index 1a5c066b94baecf270ca0aba1a730f1ac936084e..5e7926781ba9aecac3b19e455ce4b1a38c862f3d 100644 (file)
@@ -32,7 +32,16 @@ public class DomainsDatabaseHelper extends SQLiteOpenHelper {
     private static final String _ID = "_id";
 
     public static final String DOMAIN = "domain";
+    public static final String FONT_SIZE = "fontsize";
 
+    private static final String ENABLE_JAVASCRIPT = "enablejavascript";
+    private static final String ENABLE_FIRST_PARTY_COOKIES = "enablefirstpartycookies";
+    private static final String ENABLE_THIRD_PARTY_COOKIES = "enablethirdpartycookies";
+    private static final String ENABLE_DOM_STORAGE = "enabledomstorage";
+    private static final String ENABLE_FORM_DATA = "enableformdata";
+    private static final String USER_AGENT_NAME = "useragentname";
+    private static final String USER_AGENT_STRING = "useragentstring";
+    private static final String CUSTOM_USER_AGENT_STRING = "customuseragent";
 
     // Initialize the database.  The lint warnings for the unused parameters are suppressed.
     public DomainsDatabaseHelper(Context context, @SuppressWarnings("UnusedParameters") String name, SQLiteDatabase.CursorFactory cursorFactory, @SuppressWarnings("UnusedParameters") int version) {
@@ -44,7 +53,16 @@ public class DomainsDatabaseHelper extends SQLiteOpenHelper {
         // Setup the SQL string to create the `domains` table.
         final String CREATE_DOMAINS_TABLE = "CREATE TABLE " + DOMAINS_TABLE + " (" +
                 _ID + " integer primary key, " +
-                DOMAIN + " text);";
+                DOMAIN + " text, " +
+                ENABLE_JAVASCRIPT + " boolean, " +
+                ENABLE_FIRST_PARTY_COOKIES + " boolean, " +
+                ENABLE_THIRD_PARTY_COOKIES + " boolean, " +
+                ENABLE_DOM_STORAGE + " boolean, " +
+                ENABLE_FORM_DATA + " boolean, " +
+                USER_AGENT_NAME + " text, " +
+                USER_AGENT_STRING + " text, " +
+                CUSTOM_USER_AGENT_STRING + " text, " +
+                FONT_SIZE + " integer);";
 
         // Create the `domains` table if it doesn't exist.
         domainsDatabase.execSQL(CREATE_DOMAINS_TABLE);
@@ -83,8 +101,17 @@ public class DomainsDatabaseHelper extends SQLiteOpenHelper {
         // We need to store the domain data in a `ContentValues`.
         ContentValues domainContentValues = new ContentValues();
 
-        // ID is created automatically.
+        // Create entries for each field in the database.  The ID is created automatically.
         domainContentValues.put(DOMAIN, domainName);
+        domainContentValues.put(ENABLE_JAVASCRIPT, false);
+        domainContentValues.put(ENABLE_FIRST_PARTY_COOKIES, false);
+        domainContentValues.put(ENABLE_THIRD_PARTY_COOKIES, false);
+        domainContentValues.put(ENABLE_DOM_STORAGE, false);
+        domainContentValues.put(ENABLE_FORM_DATA, false);
+        domainContentValues.put(USER_AGENT_NAME, "Privacy Browser 1.0");
+        domainContentValues.put(USER_AGENT_STRING, "PrivacyBrowser/1.0");
+        domainContentValues.put(CUSTOM_USER_AGENT_STRING, "PrivacyBrowser/1.0");
+        domainContentValues.put(FONT_SIZE, "100");
 
         // Get a writable database handle.
         SQLiteDatabase domainsDatabase = this.getWritableDatabase();
index 20532efd654cf07cc55228fb012a1a197698eab8..1057e2c43c5a5f0d7b488a1771034292443008ea 100644 (file)
@@ -1,4 +1,4 @@
-<!-- about.xml comes from the Android Material icon set, where it is called ic_info_outline.  It is released under the Apache License 2.0. -->
+<!-- `about.xml` comes from the Android Material icon set, where it is called `ic_info_outline`.  It is released under the Apache License 2.0. -->
 
 <vector
     xmlns:android="http://schemas.android.com/apk/res/android"
index dbcd5efbdbb13c47bbc4409b626152a4ac9e5deb..e49e33548da007d1be471d1fa7ea6fbf7b64cfea 100644 (file)
@@ -1,5 +1,4 @@
-<!-- add.xml comes from the Android Material icon set, where it is called ic_add.
-    It is released under the Apache License 2.0. -->
+<!-- `add.xml` comes from the Android Material icon set, where it is called `ic_add`.  It is released under the Apache License 2.0. -->
 
 <vector
     xmlns:android="http://schemas.android.com/apk/res/android"
index fcba50913955741e0404f49c409074648f56a655..0c007ff5e7ceaabcd1a46cb37545d44960142ebb 100644 (file)
@@ -1,5 +1,4 @@
-<!-- back.xml comes from the Android Material icon set, where it is called ic_arrow_back.
-    It is released under the Apache License 2.0. -->
+<!-- `back.xml` comes from the Android Material icon set, where it is called `ic_arrow_back`.  It is released under the Apache License 2.0. -->
 
 <!-- `tools:ignore="VectorRaster"` removes the lint warning about `android:autoMirrored="true" not applying to API < 21. -->
 <vector
index 40d1c900d9568180f5d67e4d371f53c375cefc85..29b2648d014cfbaa79fadf2ede2e86f6d9e00e9d 100644 (file)
@@ -1,5 +1,4 @@
-<!-- bookmarks.xml comes from the Android Material icon set, where it is called ic_bookmark_border.
-    It is released under the Apache License 2.0. -->
+<!-- `bookmarks.xml` comes from the Android Material icon set, where it is called `ic_bookmark_border`.  It is released under the Apache License 2.0. -->
 
 <vector
     xmlns:android="http://schemas.android.com/apk/res/android"
index 003e13bc3895c22ddf27aeb487cd118e86f5c62c..d6f6fcc86df54588bbe039fb8a042de762d7663d 100644 (file)
@@ -1,5 +1,4 @@
-<!-- close.xml comes from the Android Material icon set, where it is called ic_close.
-    It is released under the Apache License 2.0. -->
+<!-- `close.xml` comes from the Android Material icon set, where it is called `ic_close`.  It is released under the Apache License 2.0. -->
 
 <vector
     xmlns:android="http://schemas.android.com/apk/res/android"
index aa49aa04c02b2fbdf960da9303196f46bf4d49d4..b9b52ea311784e7a29dfa51b7b36bf30dca0780f 100644 (file)
@@ -1,5 +1,4 @@
-<!-- cookies_disabled.xml was created by Google and downloaded from https://materialdesignicons.com/icon/cookie.
-    It is released under the Apache License 2.0. -->
+<!-- `cookies_disabled.xml` was created by Google and downloaded from <https://materialdesignicons.com/icon/cookie>.  It is released under the Apache License 2.0. -->
 
 <!-- `tools:ignore="VectorRaster"` removes the lint warning about `android:autoMirrored="true" not applying to API < 21. -->
 <vector
index 219f936c73dd182a5d78c8b8bb841adc58ffb318..7fef4cdf00f4b49ee3749c0e6ecc65ddeeb037db 100644 (file)
@@ -1,5 +1,4 @@
-<!-- cookies_enabled.xml was created by Google and downloaded from https://materialdesignicons.com/icon/cookie.
-    It is released under the Apache License 2.0. -->
+<!-- `cookies_enabled.xml` was created by Google and downloaded from <https://materialdesignicons.com/icon/cookie>.  It is released under the Apache License 2.0. -->
 
 <!-- `tools:ignore="VectorRaster"` removes the lint warning about `android:autoMirrored="true" not applying to API < 21. -->
 <vector
index 77bed7acde25e0e7cdaa757d7d322d693f01a6f2..957a261cfa977675cdd9601ec24f0c75f53fdbc2 100644 (file)
@@ -1,5 +1,4 @@
-<!-- create_folder.xml comes from the Android Material icon set, where it is called ic_create_new_folder.
-    It is released under the Apache License 2.0. -->
+<!-- `create_folder.xml` comes from the Android Material icon set, where it is called `ic_create_new_folder`.  It is released under the Apache License 2.0. -->
 
 <!-- `tools:ignore="VectorRaster"` removes the lint warning about `android:autoMirrored="true" not applying to API < 21. -->
 <vector
index 2b74311a68ce82d322987e35f0016a31422f72ae..15b276bd323793b47d4ed256e799d50781be4251 100644 (file)
@@ -1,5 +1,4 @@
-<!-- delete.xml comes from the Android Material icon set, where it is called ic_delete.
-    It is released under the Apache License 2.0. -->
+<!-- `delete.xml` comes from the Android Material icon set, where it is called `ic_delete`.  It is released under the Apache License 2.0. -->
 
 <vector
     xmlns:android="http://schemas.android.com/apk/res/android"
index 0c1264cbc7a797c674309b1f58fda2d48a865c29..b6a8d83fe8f3a90aebd989d1d119fea880b74a0b 100644 (file)
@@ -1,5 +1,4 @@
-<!-- dom_storage_disabled.xml comes from the Android Material icon set, where it is called ic_web.
-    It is released under the Apache License 2.0. -->
+<!-- `dom_storage_disabled.xml` comes from the Android Material icon set, where it is called `ic_web`.  It is released under the Apache License 2.0. -->
 
 <!-- `tools:ignore="VectorRaster"` removes the lint warning about `android:autoMirrored="true" not applying to API < 21. -->
 <vector
index 66e3cd6ea18ec39d4f59c82117cb872d100434d8..5d8914e432c4eabba4edee205d1a37374b35d3ea 100644 (file)
@@ -1,5 +1,4 @@
-<!-- dom_storage_enabled.xml comes from the Android Material icon set, where it is called ic_web.
-    It is released under the Apache License 2.0. -->
+<!-- `dom_storage_enabled.xml` comes from the Android Material icon set, where it is called `ic_web`.  It is released under the Apache License 2.0. -->
 
 <!-- `tools:ignore="VectorRaster"` removes the lint warning about `android:autoMirrored="true" not applying to API < 21. -->
 <vector
index 85f411db86da64830670561a3342e1fb6e349550..a0cc7557df5fe2daccb5fa44b86c9b6be69eac28 100644 (file)
@@ -1,5 +1,4 @@
-<!-- dom_storage_ghosted.xml comes from the Android Material icon set, where it is called ic_web.
-    It is released under the Apache License 2.0. -->
+<!-- `dom_storage_ghosted.xml` comes from the Android Material icon set, where it is called `ic_web`.  It is released under the Apache License 2.0. -->
 
 <!-- `tools:ignore="VectorRaster"` removes the lint warning about `android:autoMirrored="true" not applying to API < 21. -->
 <vector
index 01d336cac2cfe3683c6148e7321d7196bf416dcd..5b09eb38bfb4d9b3bc78831d45e40ffde5fa6448 100644 (file)
@@ -1,4 +1,4 @@
-<!-- domains.xml comes from the Android Material icon set, where it is called ic_import_contacts.  It is released under the Apache License 2.0. -->
+<!-- `domains.xml` comes from the Android Material icon set, where it is called `ic_import_contacts`.  It is released under the Apache License 2.0. -->
 
 <!-- `tools:ignore="VectorRaster"` removes the lint warning about `android:autoMirrored="true" not applying to API < 21. -->
 <vector
index 80fed0f3e595cbadbc76692001df8a1c26696950..9e4932510108cbc29f3213986ff4fa6a669efcee 100644 (file)
@@ -1,5 +1,4 @@
-<!-- downloads.xml comes from the Android Material icon set, where it is called ic_file_download.
-    It is released under the Apache License 2.0. -->
+<!-- `downloads.xml` comes from the Android Material icon set, where it is called `ic_file_download`.  It is released under the Apache License 2.0. -->
 
 <vector
     xmlns:android="http://schemas.android.com/apk/res/android"
index 931ff66076c108f6d87fbd45e703d53057b68724..48ebff8038dbed8b62baa3785a317183de887403 100644 (file)
@@ -1,5 +1,4 @@
-<!-- edit.xml comes from the Android Material icon set, where it is called ic_edit.
-    It is released under the Apache License 2.0. -->
+<!-- `edit.xml` comes from the Android Material icon set, where it is called `ic_edit`.  It is released under the Apache License 2.0. -->
 
 <!-- `tools:ignore="VectorRaster"` removes the lint warning about `android:autoMirrored="true" not applying to API < 21. -->
 <vector
index b8d6e6766b6bb0c37d45d67d55aa74fc09b7568f..71516f4175f48415082904c51ad92c0653e4a8c6 100644 (file)
@@ -1,5 +1,4 @@
-<!-- exit.xml comes from the Android Material icon set, where it is called ic_exit_to_app.
-    It is released under the Apache License 2.0. -->
+<!-- `exit.xml` comes from the Android Material icon set, where it is called `ic_exit_to_app`.  It is released under the Apache License 2.0. -->
 
 <!-- `tools:ignore="VectorRaster"` removes the lint warning about `android:autoMirrored="true" not applying to API < 21. -->
 <vector
index 4f2284de90d9c727b78154945e41cb828f1b4c3a..87036016438bc895c6290ff4b899cc07d242bc3b 100644 (file)
@@ -1,5 +1,4 @@
-<!-- folder_dark_blue.xml.xml comes from the Android Material icon set, where it is called ic_folder.
-    It is released under the Apache License 2.0. -->
+<!-- `folder_dark_blue.xml` comes from the Android Material icon set, where it is called `ic_folder`.  It is released under the Apache License 2.0. -->
 
 <vector
     xmlns:android="http://schemas.android.com/apk/res/android"
index 60f059f8eed3e8ea59566edd5639d2c404ae32ca..1df998da3d9561c76897dbe3667bc08dab22d70c 100644 (file)
@@ -1,5 +1,4 @@
-<!-- folder_gray.xml comes from the Android Material icon set, where it is called ic_folder.
-    It is released under the Apache License 2.0. -->
+<!-- `folder_gray.xml` comes from the Android Material icon set, where it is called `ic_folder`.  It is released under the Apache License 2.0. -->
 
 <vector
     xmlns:android="http://schemas.android.com/apk/res/android"
diff --git a/app/src/main/res/drawable/font_size.xml b/app/src/main/res/drawable/font_size.xml
new file mode 100644 (file)
index 0000000..906a0db
--- /dev/null
@@ -0,0 +1,18 @@
+<!-- `font_size.xml` comes from the Android Material icon set, where it is called `ic_text_fields`.  It is released under the Apache License 2.0. -->
+
+<!-- `tools:ignore="VectorRaster"` removes the lint warning about `android:autoMirrored="true" not applying to API < 21. -->
+<vector
+    xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:tools="http://schemas.android.com/tools"
+    android:height="24dp"
+    android:width="24dp"
+    android:viewportHeight="24.0"
+    android:viewportWidth="24.0"
+    android:autoMirrored="true"
+    tools:ignore="VectorRaster" >
+
+    <!-- We have to use a hard coded color code until API >= 21.  Then we can use `@color`. -->
+    <path
+        android:fillColor="#FF000000"
+        android:pathData="M2.5,4v3h5v12h3L10.5,7h5L15.5,4h-13zM21.5,9h-9v3h3v7h3v-7h3L21.5,9z" />
+</vector>
\ No newline at end of file
index b7226db6f859a2736c51b47f84f9c258fe29ed64..7f44621faf4faf5a54c2a74127c0d7bc5079b498 100644 (file)
@@ -1,5 +1,4 @@
-<!-- form_data_disabled.xml comes from the Android Material icon set, where it is called ic_subtitles.
-    It is released under the Apache License 2.0. -->
+<!-- `form_data_disabled.xml` comes from the Android Material icon set, where it is called `ic_subtitles`.  It is released under the Apache License 2.0. -->
 
 <!-- `tools:ignore="VectorRaster"` removes the lint warning about `android:autoMirrored="true" not applying to API < 21. -->
 <vector
index 451425247b545ad1ed7e8de848ff44502aa08480..7518407d8816b504198030456ea72881bcb1ebff 100644 (file)
@@ -1,5 +1,4 @@
-<!-- form_data_enabled.xml comes from the Android Material icon set, where it is called ic_subtitles.
-    It is released under the Apache License 2.0. -->
+<!-- `form_data_enabled.xml` comes from the Android Material icon set, where it is called `ic_subtitles`.  It is released under the Apache License 2.0. -->
 
 <!-- `tools:ignore="VectorRaster"` removes the lint warning about `android:autoMirrored="true" not applying to API < 21. -->
 <vector
index b45f8ac8a4913adb7396e238f0b49f0f2e5ca734..5cdce49e6d359a5c982e6f791b6a341fce90e4ca 100644 (file)
@@ -1,5 +1,4 @@
-<!-- forward.xml comes from the Android Material icon set, where it is called ic_arrow_forward.
-    It is released under the Apache License 2.0. -->
+<!-- `forward.xml` comes from the Android Material icon set, where it is called `ic_arrow_forward`.  It is released under the Apache License 2.0. -->
 
 <!-- `tools:ignore="VectorRaster"` removes the lint warning about `android:autoMirrored="true" not applying to API < 21. -->
 <vector
index ae237d81ff34c9cb2e554f8fa1fc67b2ee86329b..b914018d542a9c17faa93cfd8a3ef281467203a9 100644 (file)
@@ -1,4 +1,4 @@
-<!-- guide.xml comes from the Android Material icon set, where it is called ic_import_contacts.  It is released under the Apache License 2.0. -->
+<!-- `guide.xml` comes from the Android Material icon set, where it is called `ic_import_contacts`.  It is released under the Apache License 2.0. -->
 
 <!-- `tools:ignore="VectorRaster"` removes the lint warning about `android:autoMirrored="true" not applying to API < 21. -->
 <vector
index 83e95cb4c8be15a9682029b39985d8a9470525b5..f7eb1de7bec4c7edba199aab6f967208d90d4096 100644 (file)
@@ -1,5 +1,4 @@
-<!-- history.xml comes from the Android Material icon set, where it is called ic_list.
-    It is released under the Apache License 2.0. -->
+<!-- `history.xml` comes from the Android Material icon set, where it is called `ic_list`.  It is released under the Apache License 2.0. -->
 
 <!-- `tools:ignore="VectorRaster"` removes the lint warning about `android:autoMirrored="true" not applying to API < 21. -->
 <vector
index 300bffcf38a9afcd54787b9011691526ac00fd93..6edf7a1ed818928171d08bb8336c46173b350f5b 100644 (file)
@@ -1,5 +1,4 @@
-<!-- home.xml comes from the Android Material icon set, where it is called ic_home.
-    It is released under the Apache License 2.0. -->
+<!-- `home.xml` comes from the Android Material icon set, where it is called `ic_home`.  It is released under the Apache License 2.0. -->
 
 <vector
     xmlns:android="http://schemas.android.com/apk/res/android"
index e02a932873c42593d74243034b6f3d548d696a7e..3af89ca671ba1c5f1ddd8a0ee9a352af67550da5 100644 (file)
@@ -1,6 +1,5 @@
-<!-- javascript_enabled.xml is derived from ic_security and ic_language, which are part of the Android Material icon set.
-    They are released under the Apache License 2.0.  Modifications were made by Soren Stoutner <soren@stoutner.com> in 2016
-    and are released under the GPLv3+ license. -->
+<!-- `javascript_enabled.xml` is derived from `ic_security` and `ic_language`, which are part of the Android Material icon set.  They are released under the Apache License 2.0.
+    Modifications were made by Soren Stoutner <soren@stoutner.com> in 2016 and are released under the GPLv3+ license. -->
 
 <vector
     xmlns:android="http://schemas.android.com/apk/res/android"
index 4e08350adb6571a6e0e9c696e90a6ccceead50f6..17be869838870d430519b6184d58f934cc8672ce 100644 (file)
@@ -1,5 +1,4 @@
-<!-- move_bookmark_down_disabled.xml comes from the Android Material icon set, where it is called ic_vertical_align_bottom.
-    It is released under the Apache License 2.0. -->
+<!-- `move_bookmark_down_disabled.xml` comes from the Android Material icon set, where it is called `ic_vertical_align_bottom`.  It is released under the Apache License 2.0. -->
 
 <vector
     xmlns:android="http://schemas.android.com/apk/res/android"
index a81994811e3f16e8eefd3cc950bcd13a1150e250..c8cfc24deec8215ace267d67e82e37120986c843 100644 (file)
@@ -1,5 +1,4 @@
-<!-- move_bookmark_down_enabled.xml comes from the Android Material icon set, where it is called ic_vertical_align_bottom.
-    It is released under the Apache License 2.0. -->
+<!-- `move_bookmark_down_enabled.xml` comes from the Android Material icon set, where it is called `ic_vertical_align_bottom`.  It is released under the Apache License 2.0. -->
 
 <vector
     xmlns:android="http://schemas.android.com/apk/res/android"
index fb6a4573f4deb24f981328364f2b9435334b7489..b109d40c7bc6287255a30fdde1639bfcd41e9d2c 100644 (file)
@@ -1,5 +1,4 @@
-<!-- move_bookmark_up_disabled.xml comes from the Android Material icon set, where it is called ic_vertical_align_top.
-    It is released under the Apache License 2.0. -->
+<!-- `move_bookmark_up_disabled.xml` comes from the Android Material icon set, where it is called `ic_vertical_align_top`.  It is released under the Apache License 2.0. -->
 
 <vector
     xmlns:android="http://schemas.android.com/apk/res/android"
index d74ef364b9ab70a91b485208d80d734165528072..eb22338da1031d7f6605e464a80853c9cd8d0c4b 100644 (file)
@@ -1,5 +1,4 @@
-<!-- move_bookmark_up_enabled.xml comes from the Android Material icon set, where it is called ic_vertical_align_top.
-    It is released under the Apache License 2.0. -->
+<!-- `move_bookmark_up_enabled.xml` comes from the Android Material icon set, where it is called `ic_vertical_align_top`.  It is released under the Apache License 2.0. -->
 
 <vector
     xmlns:android="http://schemas.android.com/apk/res/android"
index dd3c4ce60ae1bd55e7c92073028056020a5fab8b..14f3f448e3d6740311c00c1ba8317d493587f806 100644 (file)
@@ -1,5 +1,4 @@
-<!-- move_to_folder.xml comes from the Android Material icon set, where it is called ic_folder_special.
-    It is released under the Apache License 2.0. -->
+<!-- `move_to_folder.xml` comes from the Android Material icon set, where it is called `ic_folder_special`.  It is released under the Apache License 2.0. -->
 
 <!-- `tools:ignore="VectorRaster"` removes the lint warning about `android:autoMirrored="true" not applying to API < 21. -->
 <vector
index 0ed52fca53ac37e3124e2ae8a431ee56ccd4be56..4933c9d7d81bd12e7a1e607cf4341981c3681f56 100644 (file)
@@ -1,5 +1,4 @@
-<!-- next.xml comes from the Android Material icon set, where it is called ic_expand_more.
-    It is released under the Apache License 2.0. -->
+<!-- `next.xml` comes from the Android Material icon set, where it is called `ic_expand_more`.  It is released under the Apache License 2.0. -->
 
 <vector
     xmlns:android="http://schemas.android.com/apk/res/android"
index 9908d7f4b60cc9facc45ae5e1e7f785169e11baa..2b0eb08fcd469f191c933cb3ceba8ebfd4954969 100644 (file)
@@ -1,5 +1,4 @@
-<!-- previous.xml comes from the Android Material icon set, where it is called ic_expand_less.
-    It is released under the Apache License 2.0. -->
+<!-- `previous.xml` comes from the Android Material icon set, where it is called `ic_expand_less`.  It is released under the Apache License 2.0. -->
 
 <vector
     xmlns:android="http://schemas.android.com/apk/res/android"
index c1584f7199388ad323a18c9295f88d4be834a4c5..0f33a676827fbe81e7d452127b3b0c80a6fd4bf0 100644 (file)
@@ -1,6 +1,5 @@
-<!-- privacy_mode.xml is derived from ic_security and ic_language, which are part of the Android Material icon set.
-    They are released under the Apache License 2.0.  Modifications were made by Soren Stoutner <soren@stoutner.com> in 2016.
-    and are released under the GPLv3+ license. -->
+<!-- `privacy_mode.xml` is derived from `ic_security` and `ic_language`, which are part of the Android Material icon set.  They are released under the Apache License 2.0.
+    Modifications were made by Soren Stoutner <soren@stoutner.com> in 2016 and are released under the GPLv3+ license. -->
 
 <vector
     xmlns:android="http://schemas.android.com/apk/res/android"
index 95f6083132c3bf31fb84c00e8f0250917026f222..216677e3c81a7accd820d841aa3cba2558991bd8 100644 (file)
@@ -1,5 +1,4 @@
-<!-- select_all.xml comes from the Android Material icon set, where it is called ic_select_all.
-    It is released under the Apache License 2.0. -->
+<!-- `select_all.xml` comes from the Android Material icon set, where it is called `ic_select_all`.  It is released under the Apache License 2.0. -->
 
 <vector
     xmlns:android="http://schemas.android.com/apk/res/android"
index f267c6a4e27789c3f0dc585daedec708a13a5408..3837ce8696136bb7252dd1b9d2928e5babeefcf8 100644 (file)
@@ -1,5 +1,4 @@
-<!-- settings.xml comes from the Android Material icon set, where it is called ic_settings.
-    It is released under the Apache License 2.0. -->
+<!-- `settings.xml` comes from the Android Material icon set, where it is called `ic_settings`.  It is released under the Apache License 2.0. -->
 
 <vector
     xmlns:android="http://schemas.android.com/apk/res/android"
diff --git a/app/src/main/res/drawable/user_agent.xml b/app/src/main/res/drawable/user_agent.xml
new file mode 100644 (file)
index 0000000..08b897e
--- /dev/null
@@ -0,0 +1,18 @@
+<!-- `move_to_folder.xml` comes from the Android Material icon set, where it is called `ic_folder_special`.  It is released under the Apache License 2.0. -->
+
+<!-- `tools:ignore="VectorRaster"` removes the lint warning about `android:autoMirrored="true" not applying to API < 21. -->
+<vector
+    xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:tools="http://schemas.android.com/tools"
+    android:height="24dp"
+    android:width="24dp"
+    android:viewportHeight="24.0"
+    android:viewportWidth="24.0"
+    android:autoMirrored="true"
+    tools:ignore="VectorRaster" >
+
+    <!-- We have to use a hard coded color code until API >= 21.  Then we can use `@color`. -->
+    <path
+        android:fillColor="#FF000000"
+        android:pathData="M3,6h18L21,4L3,4c-1.1,0 -2,0.9 -2,2v12c0,1.1 0.9,2 2,2h4v-2L3,18L3,6zM13,12L9,12v1.78c-0.61,0.55 -1,1.33 -1,2.22s0.39,1.67 1,2.22L9,20h4v-1.78c0.61,-0.55 1,-1.34 1,-2.22s-0.39,-1.67 -1,-2.22L13,12zM11,17.5c-0.83,0 -1.5,-0.67 -1.5,-1.5s0.67,-1.5 1.5,-1.5 1.5,0.67 1.5,1.5 -0.67,1.5 -1.5,1.5zM22,8h-6c-0.5,0 -1,0.5 -1,1v10c0,0.5 0.5,1 1,1h6c0.5,0 1,-0.5 1,-1L23,9c0,-0.5 -0.5,-1 -1,-1zM21,18h-4v-8h4v8z"/>
+</vector>
index 463aa30c7130597700e59639ea678e3b86413fcb..863c1262723c54cef0723070e68a5ccbf393b96b 100644 (file)
@@ -1,6 +1,5 @@
-<!-- warning.xml is derived from ic_security and ic_language, which are part of the Android Material icon set.
-    They are released under the Apache License 2.0.  Modifications were made by Soren Stoutner <soren@stoutner.com> in 2016.
-        and are released under the GPLv3+ license. -->
+<!-- `warning.xml` is derived from `ic_security` and `ic_language`, which are part of the Android Material icon set.  They are released under the Apache License 2.0.
+    Modifications were made by Soren Stoutner <soren@stoutner.com> in 2016 and are released under the GPLv3+ license. -->
 
 <vector
     xmlns:android="http://schemas.android.com/apk/res/android"
index 48428580d6edd8571c54e603aa8a3b6d54c22b53..801d7ccc184dc48df1e98f3ad3707ba75dc650b4 100644 (file)
         android:id="@+id/domains_listview"
         android:layout_height="match_parent"
         android:layout_width="0dp"
-        android:layout_weight="1"
+        android:layout_weight="2"
         android:choiceMode="singleChoice"
         android:divider="@color/white"
         android:dividerHeight="0dp" />
 
-    <LinearLayout
-        android:id="@+id/domain_settings_linearlayout"
+    <ScrollView
+        android:id="@+id/domain_settings_scrollview"
         android:layout_height="match_parent"
         android:layout_width="0dp"
-        android:layout_weight="3"
-        android:orientation="horizontal" />
+        android:layout_weight="3" />
 </LinearLayout>
\ No newline at end of file
index a71cd610052c2bd62c977e201e656e015966bb42..725041ea1ab702a6299b659dbaa5aab6b91e65e7 100644 (file)
   You should have received a copy of the GNU General Public License
   along with Privacy Browser.  If not, see <http://www.gnu.org/licenses/>. -->
 
-<LinearLayout
+<ScrollView
     xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_height="match_parent"
+    xmlns:tools="http://schemas.android.com/tools"
+    android:layout_height="wrap_content"
     android:layout_width="match_parent"
-    android:orientation="horizontal" >
+    android:focusable="true"
+    android:focusableInTouchMode="true"
+    android:descendantFocusability="beforeDescendants" >
 
-    <!-- Labels `LinearLayout`. -->
     <LinearLayout
+        xmlns:android="http://schemas.android.com/apk/res/android"
         android:layout_height="wrap_content"
-        android:layout_width="wrap_content"
-        android:orientation="vertical" >
+        android:layout_width="match_parent"
+        android:layout_margin="12dp"
+        android:orientation="vertical"
+        android:divider="?android:attr/dividerVertical"
+        android:showDividers="middle" >
 
-        <TextView
+        <!-- Domain name. -->
+        <LinearLayout
             android:layout_height="wrap_content"
-            android:layout_width="wrap_content"
-            android:text="@string/domain_name"
-            android:labelFor="@+id/domain_settings_name_edittext"/>
-    </LinearLayout>
+            android:layout_width="match_parent"
+            android:orientation="horizontal" >
 
-    <!-- Data `LinearLayout`. -->
-    <LinearLayout
-        android:layout_height="wrap_content"
-        android:layout_width="wrap_content"
-        android:orientation="vertical" >
+            <ImageView
+                android:layout_height="wrap_content"
+                android:layout_width="wrap_content"
+                android:layout_marginBottom="26dp"
+                android:layout_gravity="bottom"
+                android:src="@drawable/domains"
+                android:tint="@color/blue_800"
+                tools:ignore="contentDescription" />
+
+            <!-- `android.support.design.widget.TextInputLayout` makes the `android:hint` float above the `EditText`. -->
+            <android.support.design.widget.TextInputLayout
+                android:layout_height="wrap_content"
+                android:layout_width="match_parent"
+                android:layout_marginStart="6dp"
+                android:layout_marginBottom="14dp" >
 
-        <!-- `android:inputType="textUri"` disables spell check in the `EditText`. -->
-        <EditText
-            android:id="@id/domain_settings_name_edittext"
-            android:layout_width="wrap_content"
+                <!-- `android:inputType="textUri"` disables spell check in the `EditText`. -->
+                <android.support.design.widget.TextInputEditText
+                    android:id="@+id/domain_settings_name_edittext"
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:hint="@string/domain_name"
+                    android:inputType="textUri" />
+            </android.support.design.widget.TextInputLayout>
+        </LinearLayout>
+
+        <!-- JavaScript. -->
+        <LinearLayout
             android:layout_height="wrap_content"
-            android:inputType="textUri" />
-    </LinearLayout>
+            android:layout_width="match_parent"
+            android:orientation="horizontal" >
+
+            <ImageView
+                android:layout_height="wrap_content"
+                android:layout_width="wrap_content"
+                android:layout_gravity="center_vertical"
+                android:src="@drawable/privacy_mode"
+                tools:ignore="contentDescription" />
+
+            <Switch
+                android:id="@+id/domain_settings_javascript_switch"
+                android:layout_height="wrap_content"
+                android:layout_width="match_parent"
+                android:layout_marginStart="8dp"
+                android:layout_marginTop="14dp"
+                android:layout_marginBottom="14dp"
+                android:text="@string/javascript_enabled"
+                android:textSize="18sp" />
+        </LinearLayout>
+
+        <!-- First-Party Cookies. -->
+        <LinearLayout
+            android:layout_height="wrap_content"
+            android:layout_width="match_parent"
+            android:orientation="horizontal" >
+
+            <ImageView
+                android:layout_height="wrap_content"
+                android:layout_width="wrap_content"
+                android:layout_marginTop="1dp"
+                android:layout_gravity="center_vertical"
+                android:src="@drawable/cookies_enabled"
+                android:tint="@color/blue_800"
+                tools:ignore="contentDescription" />
+
+            <Switch
+                android:id="@+id/domain_settings_first_party_cookies_switch"
+                android:layout_height="wrap_content"
+                android:layout_width="match_parent"
+                android:layout_marginStart="8dp"
+                android:layout_marginTop="14dp"
+                android:layout_marginBottom="14dp"
+                android:text="@string/first_party_cookies_enabled"
+                android:textSize="18sp" />
+        </LinearLayout>
+
+        <!-- Third-Party Cookies. -->
+        <LinearLayout
+            android:layout_height="wrap_content"
+            android:layout_width="match_parent"
+            android:orientation="horizontal" >
+
+            <ImageView
+                android:layout_height="wrap_content"
+                android:layout_width="wrap_content"
+                android:layout_marginTop="1dp"
+                android:layout_gravity="center_vertical"
+                android:src="@drawable/cookies_enabled"
+                android:tint="@color/blue_800"
+                tools:ignore="contentDescription" />
+
+            <Switch
+                android:id="@+id/domain_settings_third_party_cookies_switch"
+                android:layout_height="wrap_content"
+                android:layout_width="match_parent"
+                android:layout_marginStart="8dp"
+                android:layout_marginTop="14dp"
+                android:layout_marginBottom="14dp"
+                android:text="@string/third_party_cookies_enabled"
+                android:textSize="18sp" />
+        </LinearLayout>
 
-</LinearLayout>
\ No newline at end of file
+        <!-- DOM Storage. -->
+        <LinearLayout
+            android:layout_height="wrap_content"
+            android:layout_width="match_parent"
+            android:orientation="horizontal" >
+
+            <ImageView
+                android:layout_height="wrap_content"
+                android:layout_width="wrap_content"
+                android:layout_marginTop="1dp"
+                android:layout_gravity="center_vertical"
+                android:src="@drawable/dom_storage_enabled"
+                android:tint="@color/blue_800"
+                tools:ignore="contentDescription" />
+
+            <Switch
+                android:id="@+id/domain_settings_dom_storage_switch"
+                android:layout_height="wrap_content"
+                android:layout_width="match_parent"
+                android:layout_marginStart="8dp"
+                android:layout_marginTop="14dp"
+                android:layout_marginBottom="14dp"
+                android:text="@string/dom_storage_enabled"
+                android:textSize="18sp" />
+        </LinearLayout>
+
+        <!-- Form Data. -->
+        <LinearLayout
+            android:layout_height="wrap_content"
+            android:layout_width="match_parent"
+            android:orientation="horizontal">
+
+            <ImageView
+                android:layout_height="wrap_content"
+                android:layout_width="wrap_content"
+                android:layout_marginTop="1dp"
+                android:layout_gravity="center_vertical"
+                android:src="@drawable/form_data_enabled"
+                android:tint="@color/blue_800"
+                tools:ignore="contentDescription" />
+
+            <Switch
+                android:id="@+id/domain_settings_form_data_switch"
+                android:layout_height="wrap_content"
+                android:layout_width="match_parent"
+                android:layout_marginStart="8dp"
+                android:layout_marginTop="14dp"
+                android:layout_marginBottom="14dp"
+                android:text="@string/form_data_enabled"
+                android:textSize="18sp" />
+        </LinearLayout>
+
+        <!-- User Agent. -->
+        <LinearLayout
+            android:layout_height="wrap_content"
+            android:layout_width="match_parent"
+            android:orientation="horizontal">
+
+            <ImageView
+                android:layout_height="wrap_content"
+                android:layout_width="wrap_content"
+                android:layout_marginTop="1dp"
+                android:layout_gravity="center_vertical"
+                android:src="@drawable/user_agent"
+                android:tint="@color/blue_800"
+                android:contentDescription="@string/user_agent" />
+
+            <Spinner
+                android:id="@+id/domain_settings_user_agent_spinner"
+                android:layout_height="wrap_content"
+                android:layout_width="match_parent"
+                android:layout_marginTop="14dp"
+                android:layout_marginBottom="14dp" />
+        </LinearLayout>
+
+        <!-- Font Size. -->
+        <!-- We need to add an extra `android:layout_marginBottom="14dp"` to the last `LinearLayout` or the bottom of the `ScrollView` gets cutoff if API 25. -->
+        <LinearLayout
+            android:layout_height="wrap_content"
+            android:layout_width="match_parent"
+            android:orientation="horizontal"
+            android:layout_marginBottom="14dp" >
+
+            <ImageView
+                android:layout_height="wrap_content"
+                android:layout_width="wrap_content"
+                android:layout_marginTop="1dp"
+                android:layout_gravity="center_vertical"
+                android:src="@drawable/font_size"
+                android:tint="@color/blue_800"
+                android:contentDescription="@string/font_size" />
+
+            <Spinner
+                android:id="@+id/domain_settings_font_size_spinner"
+                android:layout_height="wrap_content"
+                android:layout_width="match_parent"
+                android:layout_marginTop="14dp"
+                android:layout_marginBottom="14dp"/>
+        </LinearLayout>
+    </LinearLayout>
+</ScrollView>
\ No newline at end of file
index b2c7fb575596f80002d2656602b787ba03c8108a..506e9c12a491e529e2dfbc13603d89cff2f32a74 100644 (file)
@@ -23,7 +23,8 @@
     xmlns:tools="http://schemas.android.com/tools"
     xmlns:android="http://schemas.android.com/apk/res/android"
     android:layout_height="wrap_content"
-    android:layout_width="match_parent" >
+    android:layout_width="match_parent"
+    tools:context=".activities.MainWebViewActivity" >
 
     <!-- `RelativeLayout` is used instead of a `LinearLayout` because `supportAppBar` does not let `android:layout_weight="1"` cause `urlTextBox` to fill all the available space. -->
     <RelativeLayout
index efe7d613ebeaccc1f715a6eb03fca0541ebabbc1..9dbfc3bf1c91118475f87857f9513ee1f80d1b81 100644 (file)
     <string name="domain_settings">Domain Settings</string>
     <string name="add_domain">Add Domain</string>
     <string name="add">Add</string>
-    <string name="domain_name">Domain Name</string>
+    <string name="domain_name">Domain name</string>
 
     <!-- Guide. -->
     <string name="privacy_browser_guide">Privacy Browser Guide</string>
index 4c8acdfd8e312af59a3a49fcae0151bb490b4181..ef87e8d049628327db3b811579194f5af1c2e973 100644 (file)
     <style name="PrivacyBrowser" parent="Theme.AppCompat.Light.NoActionBar">
         <item name="android:windowTranslucentStatus">true</item>
         <item name="colorAccent">@color/blue_700</item>
+        <item name="android:textColorHighlight">@color/blue_200</item>
     </style>
 
     <!-- `colorPrimaryDark` goes behind the status bar, which is then darkened by the overlay.
         `windowActionModeOverlay` makes the contextual app bar cover the support app bar. -->
     <style name="PrivacyBrowser.SecondaryActivity">
         <item name="colorPrimaryDark">@color/blue_700</item>
+        <item name="android:textColorHighlight">@color/blue_200</item>
         <item name="windowActionModeOverlay">true</item>
         <item name="android:actionModeBackground">@color/blue_700</item>
         <item name="actionBarPopupTheme">@style/LightPopupOverlay</item>
+        <item name="android:spinnerItemStyle">@style/spinnerItemStyle</item>
+        <item name="android:spinnerDropDownItemStyle">@style/spinnerDropDownItemStyle</item>
     </style>
 
     <!-- `colorPrimaryDark` is the color of the status bar. -->
     <style name="LightAlertDialog" parent="Theme.AppCompat.Light.Dialog.Alert" >
         <item name="colorAccent">@color/blue_700</item>
     </style>
+
+    <style name="spinnerItemStyle" >
+        <item name="android:paddingStart">8dp</item>
+        <item name="android:textColor">@color/black</item>
+        <item name="android:textSize">18sp</item>
+    </style>
+
+    <style name="spinnerDropDownItemStyle" >
+        <item name="android:paddingStart">16dp</item>
+        <item name="android:paddingEnd">16dp</item>
+        <item name="android:paddingTop">8dp</item>
+        <item name="android:paddingBottom">8dp</item>
+        <item name="android:textColor">@color/black</item>
+        <item name="android:textSize">18sp</item>
+    </style>
 </resources>
\ No newline at end of file