Support numeric9x4 passphrase-format during decryption
This commit is contained in:
@@ -0,0 +1,53 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:paddingBottom="14dp"
|
||||
android:paddingTop="14dp">
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/input"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/passphrase_text"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="24dp"
|
||||
android:layout_marginBottom="24dp"
|
||||
android:text="@string/passphrase_transfer"
|
||||
android:textAppearance="@style/TextAppearance.AppCompat.Medium" />
|
||||
|
||||
<include layout="@layout/transfer_code_input" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/progress"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerInParent="true"
|
||||
android:orientation="horizontal"
|
||||
android:visibility="invisible">
|
||||
|
||||
<ProgressBar
|
||||
style="?android:attr/progressBarStyle"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_horizontal" />
|
||||
|
||||
<TextView
|
||||
style="?android:attr/textAppearanceMedium"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:padding="4dp"
|
||||
android:text="@string/label_unlock" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</RelativeLayout>
|
||||
135
OpenKeychain/src/main/res/layout/transfer_code_input.xml
Normal file
135
OpenKeychain/src/main/res/layout/transfer_code_input.xml
Normal file
@@ -0,0 +1,135 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:orientation="vertical"
|
||||
tools:showIn="@layout/backup_code_fragment">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<EditText
|
||||
android:id="@+id/transfer_code_block_1"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
tools:text="1234"
|
||||
style="@style/TransferCodeText"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/TransferCodeTextSep" />
|
||||
|
||||
<EditText
|
||||
android:id="@+id/transfer_code_block_2"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/TransferCodeText" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/TransferCodeTextSep" />
|
||||
|
||||
<EditText
|
||||
android:id="@+id/transfer_code_block_3"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/TransferCodeText"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/TransferCodeTextSep" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<EditText
|
||||
android:id="@+id/transfer_code_block_4"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/TransferCodeText"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/TransferCodeTextSep" />
|
||||
|
||||
<EditText
|
||||
android:id="@+id/transfer_code_block_5"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/TransferCodeText"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/TransferCodeTextSep" />
|
||||
|
||||
<EditText
|
||||
android:id="@+id/transfer_code_block_6"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/TransferCodeText"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/TransferCodeTextSep" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<EditText
|
||||
android:id="@+id/transfer_code_block_7"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/TransferCodeText"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/TransferCodeTextSep" />
|
||||
|
||||
<EditText
|
||||
android:id="@+id/transfer_code_block_8"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/TransferCodeText"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/TransferCodeTextSep" />
|
||||
|
||||
<EditText
|
||||
android:id="@+id/transfer_code_block_9"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/TransferCodeText"
|
||||
/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
@@ -333,6 +333,7 @@
|
||||
<string name="passphrase_for_any">"Enter password"</string>
|
||||
<string name="passphrase_keyboard_hint_alpha">"Switch to alphabetic keyboard"</string>
|
||||
<string name="passphrase_keyboard_hint_numeric">"Switch to numeric keyboard"</string>
|
||||
<string name="passphrase_transfer">"Enter transfer code"</string>
|
||||
<string name="pin_for">"Enter PIN for '%s'"</string>
|
||||
<string name="security_token_pin_for">"Enter PIN to access Security Token for '%s'"</string>
|
||||
<string name="security_token_nfc_text">"Hold Security Token against the NFC marker at the back of your device."</string>
|
||||
@@ -1176,6 +1177,8 @@
|
||||
<string name="msg_dc_asym">"Found block of asymmetrically encrypted data for key %s"</string>
|
||||
<string name="msg_dc_charset">"Found charset header: '%s'"</string>
|
||||
<string name="msg_dc_backup_version">"Found backupVersion header: '%s'"</string>
|
||||
<string name="msg_dc_passphrase_format">"Found Passphrase-Format header: '%s'"</string>
|
||||
<string name="msg_dc_passphrase_begin">"Found Passphrase-Begin header: '%s'"</string>
|
||||
<string name="msg_dc_clear_data">"Processing literal data"</string>
|
||||
<string name="msg_dc_clear_decompress">"Unpacking compressed data"</string>
|
||||
<string name="msg_dc_clear_meta_file">"Filename: %s"</string>
|
||||
|
||||
@@ -65,4 +65,22 @@
|
||||
<item name="android:textSize" tools:ignore="SpUsage">14dp</item>
|
||||
</style>
|
||||
|
||||
<style name="TransferCodeText">
|
||||
<item name="android:gravity">center_vertical</item>
|
||||
<item name="android:singleLine">true</item>
|
||||
<item name="android:hint">1234</item>
|
||||
<item name="android:textColorHint">@android:color/transparent</item>
|
||||
<item name="android:textSize">18sp</item>
|
||||
<item name="android:minHeight">42sp</item>
|
||||
<item name="android:textStyle">bold</item>
|
||||
<item name="android:typeface">monospace</item>
|
||||
<item name="android:textColor">#000</item>
|
||||
<item name="android:inputType">numberPassword|textVisiblePassword</item>
|
||||
</style>
|
||||
|
||||
<style name="TransferCodeTextSep" parent="TransferCodeText">
|
||||
<item name="android:hint"></item>
|
||||
<item name="android:text">-</item>
|
||||
</style>
|
||||
|
||||
</resources>
|
||||
|
||||
Reference in New Issue
Block a user