<?xml version="1.0" encoding="UTF-8"?>
<!--
 
     
 This file is part of Keepass2Android, Copyright 2013 Philipp Crocoll. This file is based on Keepassdroid, Copyright Brian Pellin.

  Keepass2Android is free software: you can redistribute it and/or modify
  it under the terms of the GNU General Public License as published by
  the Free Software Foundation, either version 2 of the License, or
  (at your option) any later version.

  Keepass2Android is distributed in the hope that it will be useful,
  but WITHOUT ANY WARRANTY; without even the implied warranty of
  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  GNU General Public License for more details.

  You should have received a copy of the GNU General Public License
  along with Keepass2Android.  If not, see <http://www.gnu.org/licenses/>.
-->
<PreferenceScreen
	xmlns:android="http://schemas.android.com/apk/res/android"
  android:key="mainprefs">
	<PreferenceScreen
	  android:key="@string/db_key"
	  android:title="@string/database"
	  android:summary="@string/menu_db_settings">
    <keepass2android.ToolbarPreference
    android:key="@string/db_key"
    android:title="@string/database" />
		<EditTextPreference
                android:title="@string/database_name"
                android:persistent="false"
                android:key="@string/database_name_key"/>
		
      <ListPreference
			  android:key="@string/algorithm_key"
			  android:title="@string/algorithm"
			  android:dialogTitle="@string/algorithm"/>

    <PreferenceScreen
	  android:key="@string/kdf_screen_key"
	  android:title="@string/KeyDerivFunc" >
<keepass2android.ToolbarPreference
    android:key="@string/kdf_screen_key"
    android:title="@string/KeyDerivFunc" />
     
      <ListPreference
			  android:key="@string/kdf_key"
			  android:title="@string/KeyDerivFunc"
			  android:dialogTitle="@string/KeyDerivFunc"/>

      

    <keepass2android.settings.RoundsPreference
		  android:key="@string/rounds_key"
		  android:persistent="false"
		  android:title="@string/rounds"
		  android:dialogLayout="@layout/database_settings"
		  android:positiveButtonText="@string/entry_save"
		  android:negativeButtonText="@string/entry_cancel"/>
    
    <keepass2android.settings.Argon2RoundsPreference
		  android:key="argon2rounds"
		  android:persistent="false"
		  android:title="@string/rounds"
		  android:dialogLayout="@layout/database_settings"
		  android:positiveButtonText="@string/entry_save"
		  android:negativeButtonText="@string/entry_cancel"/>
    
    <keepass2android.settings.Argon2MemoryPreference
		  android:key="argon2memory"
		  android:persistent="false"
		  android:title="@string/argon2memory"
		  android:dialogLayout="@layout/database_settings"
		  android:positiveButtonText="@string/entry_save"
		  android:negativeButtonText="@string/entry_cancel"/>
    
    <keepass2android.settings.Argon2ParallelismPreference
		  android:key="argon2parallelism"
		  android:persistent="false"
		  android:title="@string/argon2parallelism"
		  android:dialogLayout="@layout/database_settings"
		  android:positiveButtonText="@string/entry_save"
		  android:negativeButtonText="@string/entry_cancel"/>
</PreferenceScreen>
  
		<EditTextPreference
			  android:title="@string/default_username"
			  android:persistent="false"
			  android:key="@string/default_username_key"/>
		
		<Preference android:key="@string/master_pwd_key"
		  android:title="@string/menu_change_key"
					/>
    
    <PreferenceScreen
        android:key="fingerprint_prefs"
        android:title="@string/fingerprint_prefs"
	  >
      <intent android:action="kp2a.action.FingerprintSetupActivity"/>
    </PreferenceScreen>

    <Preference android:key="AddTemplates_pref_key"
		  android:title="@string/AddTemplates_pref"
					/>
    

    <PreferenceScreen
	  android:key="export_prefs"
	  android:title="@string/export_prefs"
	  >
			<intent android:action="kp2a.action.ExportDatabaseActivity"/>
		</PreferenceScreen>

		<Preference
	  android:key="import_db_prefs"
	  android:title="@string/import_db_prefs"
	  />
		
		<Preference
			  android:key="import_keyfile_prefs"
			  android:title="@string/import_keyfile_prefs"
	  />
		
		
    
	</PreferenceScreen>
	

	<PreferenceScreen
	  android:key="@string/app_key"
	  android:title="@string/application"
	  android:summary="@string/application_settings">
    <keepass2android.ToolbarPreference
        android:key="@string/app_key"
        android:title="@string/application" />
		<PreferenceScreen
	  android:key="@string/security_prefs_key"
	  android:title="@string/security_prefs"
	  >
      <keepass2android.ToolbarPreference
    android:key="@string/security_prefs_key"
	  android:title="@string/security_prefs" />

			<ListPreference
			  android:key="@string/clipboard_timeout_key"
			  android:title="@string/clipboard_timeout"
			  android:summary="@string/clipboard_timeout_summary"
			  android:entries="@array/clipboard_timeout_options"
			  android:entryValues="@array/clipboard_timeout_values"
			  android:dialogTitle="@string/clipboard_timeout"
			  android:defaultValue="@string/clipboard_timeout_default"/>
			<ListPreference
			  android:key="@string/app_timeout_key"
			  android:title="@string/app_timeout"
			  android:summary="@string/app_timeout_summary"
			  android:entries="@array/clipboard_timeout_options"
			  android:entryValues="@array/clipboard_timeout_values"
			  android:dialogTitle="@string/app_timeout"
			  android:defaultValue="@string/clipboard_timeout_default"/>
			<CheckBoxPreference
			   android:enabled="true"
				 android:persistent="true"
				 android:summary="@string/LockWhenScreenOff_summary"
				 android:defaultValue="false"
				 android:title="@string/LockWhenScreenOff_title"
				 android:key="@string/LockWhenScreenOff_key" />

			<CheckBoxPreference
			   android:enabled="true"
				 android:persistent="true"
				 android:summary="@string/LockWhenNavigateBack_summary"
				 android:defaultValue="false"
				 android:title="@string/LockWhenNavigateBack_title"
				 android:key="@string/LockWhenNavigateBack_key" />

			<CheckBoxPreference
				android:key="@string/RememberRecentFiles_key"
				android:title="@string/RememberRecentFiles_title"
				android:summary="@string/RememberRecentFiles_summary"
				android:defaultValue="@bool/RememberRecentFiles_default"/>

			<CheckBoxPreference
				android:key="@string/keyfile_key"
				android:title="@string/remember_keyfile_title"
				android:summary="@string/remember_keyfile_summary"
				android:defaultValue="@bool/keyfile_default"/>

			<CheckBoxPreference
				android:key="@string/show_kill_app_key"
				android:title="@string/show_kill_app"
				android:summary="@string/show_kill_app_summary"
				android:defaultValue="false"/>
			
			<CheckBoxPreference
			     android:enabled="true"
				 android:persistent="true"
				 android:summary="@string/ClearPasswordOnLeave_summary"
				 android:defaultValue="false"
				 android:title="@string/ClearPasswordOnLeave_title"
				 android:key="@string/ClearPasswordOnLeave_key" />


		</PreferenceScreen>
		<PreferenceScreen
	  android:key="@string/display_prefs_key"
	  android:title="@string/display_prefs"
	  >
      <keepass2android.ToolbarPreference
    android:key="@string/display_prefs_key"
	  android:title="@string/display_prefs" />
			<CheckBoxPreference
				android:enabled="true"
					 android:persistent="true"
					 android:summary="@string/ShowUnlockedNotification_summary"
					 android:defaultValue="@bool/ShowUnlockedNotification_default"
					 android:title="@string/ShowUnlockedNotification_title"
					 android:key="@string/ShowUnlockedNotification_key" />
			<CheckBoxPreference
			  android:key="@string/maskpass_key"
			  android:title="@string/maskpass_title"
			  android:summary="@string/maskpass_summary"
			  android:defaultValue="@bool/maskpass_default"/>

			<CheckBoxPreference
			  android:key="@string/ShowUsernameInList_key"
			  android:title="@string/ShowUsernameInList_title"
			  android:summary="@string/ShowUsernameInList_summary"
			  android:defaultValue="@bool/ShowUsernameInList_default"/>

			<CheckBoxPreference
			  android:key="@string/ShowGroupnameInSearchResult_key"
			  android:title="@string/ShowGroupnameInSearchResult_title"
			  android:summary="@string/ShowGroupnameInSearchResult_resume"
			  android:defaultValue="@bool/ShowGroupnameInSearchResult_default"/>
			<CheckBoxPreference
			  android:key="ShowGroupInEntry"
			  android:title="@string/ShowGroupInEntry_title"
			  android:defaultValue="false"/>
			<ListPreference
			  android:key="@string/list_size_key"
			  android:title="@string/list_size_title"
			  android:summary="@string/list_size_summary"
			  android:entries="@array/list_size_options"
			  android:entryValues="@array/list_size_values"
			  android:dialogTitle="@string/list_size_summary"
			  android:defaultValue="@string/list_size_default"/>

      <keepass2android.IconSetPreference
                android:title="@string/IconSet_title"
                android:persistent="false"
                android:key="IconSetKey"/>

      <ListPreference
			  android:key="@string/design_key"
			  android:title="@string/design_title"
			  android:entries="@array/design_options"
			  android:entryValues="@array/design_values"
			  android:dialogTitle="@string/design_title"
			  android:defaultValue="@string/design_default"/>

      
      <CheckBoxPreference
				android:enabled="true"
					 android:persistent="true"
					 android:summary="@string/ViewDatabaseSecure_summary"
					 android:defaultValue="true"
					 android:title="@string/ViewDatabaseSecure_title"
					 android:key="@string/ViewDatabaseSecure_key" />

			<CheckBoxPreference
				android:enabled="true"
					 android:persistent="true"
					 android:summary="@string/NoDonateOption_summary"
					 android:defaultValue="false"
					 android:title="@string/NoDonateOption_title"
					 android:key="@string/NoDonateOption_key" />

      <CheckBoxPreference
				android:enabled="true"
					 android:persistent="true"
					 android:summary="@string/NoDonationReminder_summary"
					 android:defaultValue="false"
					 android:title="@string/NoDonationReminder_title"
					 android:key="@string/NoDonationReminder_key" />
		</PreferenceScreen>

		<PreferenceScreen
			  android:key="@string/password_access_prefs_key"
			  android:title="@string/password_access_prefs"
			  >
      <keepass2android.ToolbarPreference
    android:key="@string/password_access_prefs_key"
			  android:title="@string/password_access_prefs" />
			<CheckBoxPreference
				android:enabled="true"
				  android:persistent="true"
				  android:summary="@string/ShowCopyToClipboardNotification_summary"
				  android:defaultValue="@bool/CopyToClipboardNotification_default"
				  android:title="@string/ShowCopyToClipboardNotification_title"
				  android:key="@string/CopyToClipboardNotification_key" />
			<CheckBoxPreference
				android:enabled="true"
				  android:persistent="true"
				  android:summary="@string/ShowKp2aKeyboardNotification_summary"
				  android:defaultValue="@bool/UseKp2aKeyboard_default"
				  android:title="@string/ShowKp2aKeyboardNotification_title"
				  android:key="@string/UseKp2aKeyboard_key" />

			<CheckBoxPreference
				android:enabled="true"
				  android:persistent="true"
				  android:summary="@string/ShowSeparateNotifications_summary"
				  android:defaultValue="@bool/ShowSeparateNotifications_default"
				  android:title="@string/ShowSeparateNotifications_title"
				  android:key="@string/ShowSeparateNotifications_key" />

			<PreferenceScreen
				 android:key="@string/keyboardswitch_prefs_key"
	  android:title="@string/keyboardswitch_prefs"
				 			android:dependency="@string/UseKp2aKeyboard_key"
	  >
        <keepass2android.ToolbarPreference
  android:key="@string/keyboardswitch_prefs_key"
	  android:title="@string/keyboardswitch_prefs"/>
				<CheckBoxPreference
							android:key="kp2a_switch_rooted"
							android:title="@string/kp2a_switch_rooted"
							android:summary="@string/kp2a_switch_rooted_summary"
							android:persistent="true"
							android:defaultValue="false"
            />


				<!-- no autoswitch on root only-->
				<CheckBoxPreference
				android:enabled="true"
				  android:persistent="true"
				  android:summary="@string/OpenKp2aKeyboardAutomatically_summary"
				  android:defaultValue="@bool/OpenKp2aKeyboardAutomatically_default"
				  android:title="@string/OpenKp2aKeyboardAutomatically_title"
				  android:key="@string/OpenKp2aKeyboardAutomatically_key" />
				
				<!-- autoswitch on root only-->
				<CheckBoxPreference
				android:enabled="true"
				  android:persistent="true"
				  android:summary="@string/OpenKp2aKeyboardAutomaticallyOnlyAfterSearch_summary"
				  android:defaultValue="@bool/OpenKp2aKeyboardAutomaticallyOnlyAfterSearch_default"
				  android:title="@string/OpenKp2aKeyboardAutomaticallyOnlyAfterSearch_title"
				  android:key="@string/OpenKp2aKeyboardAutomaticallyOnlyAfterSearch_key" />
				
					
				<!-- with and without autoswitch on root-->
				<CheckBoxPreference
				android:enabled="true"
				  android:persistent="true"
				  android:summary="@string/AutoSwitchBackKeyboard_summary"
				  android:defaultValue="@bool/AutoSwitchBackKeyboard_default"
				  android:title="@string/AutoSwitchBackKeyboard_title"
				  android:key="@string/AutoSwitchBackKeyboard_key" />
				
				<CheckBoxPreference
            android:key="kp2a_switch_on_sendgodone"
            android:title="@string/kp2a_switch_on_sendgodone"
            android:summary="@string/kp2a_switch_on_sendgodone_summary"
            android:persistent="true"
            android:defaultValue="false"
            />

			</PreferenceScreen>
		</PreferenceScreen>
		<PreferenceScreen
			  android:key="@string/QuickUnlock_prefs_key"
			  android:title="@string/QuickUnlock_prefs"
			  >
      <keepass2android.ToolbarPreference
  android:key="@string/QuickUnlock_prefs_key"
			  android:title="@string/QuickUnlock_prefs"/>
			<CheckBoxPreference
			android:enabled="true"
				 android:persistent="true"
				 android:summary="@string/QuickUnlockDefaultEnabled_summary"
				 android:defaultValue="true"
				 android:title="@string/QuickUnlockDefaultEnabled_title"
				 android:key="@string/QuickUnlockDefaultEnabled_key" />
			<EditTextPreference
				 android:enabled="true"
				 android:persistent="true"
				 android:summary="@string/QuickUnlockLength_summary"
				 android:numeric="integer"
				 android:defaultValue="3"
				 android:title="@string/QuickUnlockLength_title"
				 android:key="@string/QuickUnlockLength_key" />
			<CheckBoxPreference
			android:enabled="true"
				 android:persistent="true"
				 android:summary="@string/QuickUnlockIconHidden_summary"
				 android:defaultValue="false"
				 android:title="@string/QuickUnlockIconHidden_title"
				 android:key="@string/QuickUnlockIconHidden_key" />
			<CheckBoxPreference
			android:enabled="true"
				 android:persistent="true"
				 android:summary="@string/QuickUnlockIconHidden16_summary"
				 android:defaultValue="true"
				 android:title="@string/QuickUnlockIconHidden16_title"
				 android:key="@string/QuickUnlockIconHidden16_key" />
		</PreferenceScreen>
		<PreferenceScreen
	  android:key="@string/FileHandling_prefs_key"
	  android:title="@string/FileHandling_prefs"
		>
      <keepass2android.ToolbarPreference
  android:key="@string/FileHandling_prefs_key"
	  android:title="@string/FileHandling_prefs"/>

			<EditTextPreference
				 android:enabled="true"
				 android:persistent="true"
				 android:summary="@string/BinaryDirectory_summary"
				 android:defaultValue="@string/BinaryDirectory_default"
				 android:title="@string/BinaryDirectory_title"
				 android:key="@string/BinaryDirectory_key" />
			<CheckBoxPreference
				  android:enabled="true"
				  android:persistent="true"
				  android:summary="@string/UseOfflineCache_summary"
				  android:defaultValue="true"
				  android:title="@string/UseOfflineCache_title"
				  android:key="@string/UseOfflineCache_key" />
			<ListPreference
			  android:key="@string/AcceptAllServerCertificates_key"
			  android:title="@string/AcceptAllServerCertificates_title"
			  android:summary="@string/AcceptAllServerCertificates_summary"
			  android:entries="@array/AcceptAllServerCertificates_options"
			  android:entryValues="@array/AcceptAllServerCertificates_values"
			  android:dialogTitle="@string/AcceptAllServerCertificates_title"
			  android:defaultValue="@string/AcceptAllServerCertificates_default"/>
			
		
			<CheckBoxPreference
				android:enabled="true"
				  android:persistent="true"
				  android:summary="@string/CheckForFileChangesOnSave_summary"
				  android:defaultValue="true"
				  android:title="@string/CheckForFileChangesOnSave_title"
				  android:key="@string/CheckForFileChangesOnSave_key" />
			<CheckBoxPreference
			   android:enabled="true"
				 android:persistent="true"
				 android:summary="@string/UseFileTransactions_summary"
				 android:defaultValue="true"
				 android:title="@string/UseFileTransactions_title"
				 android:key="@string/UseFileTransactions_key" />

			<CheckBoxPreference
				android:enabled="true"
					 android:persistent="true"
					 android:summary="@string/PreloadDatabaseEnabled_summary"
					 android:defaultValue="@bool/PreloadDatabaseEnabled_default"
					 android:title="@string/PreloadDatabaseEnabled_title"
					 android:key="@string/PreloadDatabaseEnabled_key" />
			<CheckBoxPreference
  android:key="@string/TanExpiresOnUse_key"
  android:title="@string/TanExpiresOnUse_title"
  android:summary="@string/TanExpiresOnUse_summary"
  android:defaultValue="@bool/TanExpiresOnUse_default"/>
			<CheckBoxPreference
							android:enabled="true"
							  android:persistent="true"
							  android:summary="@string/CheckForDuplicateUuids_summary"
							  android:defaultValue="true"
							  android:title="@string/CheckForDuplicateUuids_title"
							  android:key="@string/CheckForDuplicateUuids_key" />

		</PreferenceScreen>
		<PreferenceScreen
	  android:key="keyboard_prefs"
	  android:title="@string/keyboard_prefs"
	  >
			<intent android:action="keepass2android.softkeyboard.LatinIMESettings"/>
		</PreferenceScreen>
		
		<PreferenceScreen
	  android:key="@string/TrayTotp_prefs_key"
	  android:title="@string/TrayTotp_prefs"
		>
      <keepass2android.ToolbarPreference
        android:key="@string/TrayTotp_prefs_key"
	  android:title="@string/TrayTotp_prefs"/>
      
			<EditTextPreference
				 android:enabled="true"
				 android:persistent="true"
				 android:summary="@string/TrayTotp_SeedField_summary"
				 android:defaultValue="TOTP Seed"
				 android:title="@string/TrayTotp_SeedField_title"
				 android:key="@string/TrayTotp_SeedField_key" />
			<EditTextPreference
				 android:enabled="true"
				 android:persistent="true"
				 android:summary="@string/TrayTotp_SettingsField_summary"
				 android:defaultValue="TOTP Settings"
				 android:title="@string/TrayTotp_SettingsField_title"
				 android:key="@string/TrayTotp_SettingsField_key" />
	</PreferenceScreen>
		
<ListPreference
			  android:key="pref_ErrorReportMode"
			  android:title="@string/ErrorReportPrefTitle"
			  android:summary="@string/ErrorReportPromise"/>
			
	</PreferenceScreen>

	<PreferenceScreen android:key="plugin_key" android:title="@string/plugins">
		<intent android:action="kp2a.action.PluginListActivity"/>
	</PreferenceScreen>

	<PreferenceScreen
			  android:key="@string/about_prefs_key"
			  android:title="@string/menu_about"
			  >
		<intent android:action="kp2a.action.AboutActivity"/>
	</PreferenceScreen>
	

		
</PreferenceScreen>
