Edit key: subkey adding, not finished
This commit is contained in:
@@ -1,14 +1,97 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent" >
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<TableLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingLeft="16dp"
|
||||
android:paddingRight="16dp"
|
||||
android:stretchColumns="1" >
|
||||
android:stretchColumns="1">
|
||||
|
||||
<TableRow>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/label_expiry"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:paddingRight="10dip"
|
||||
android:text="@string/label_expiry" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/expiry"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="40dp"
|
||||
android:text="@string/none"
|
||||
android:background="@drawable/button_edgy" />
|
||||
</TableRow>
|
||||
|
||||
<TableRow android:id="@+id/row_certify">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/label_usage"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:paddingRight="10dip"
|
||||
android:text="@string/label_usage" />
|
||||
|
||||
<CheckBox
|
||||
android:id="@+id/chkCertify"
|
||||
android:enabled="false"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/flag_certify" />
|
||||
</TableRow>
|
||||
|
||||
<TableRow android:id="@+id/row_sign">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/label_usage2"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:paddingRight="10dip"
|
||||
android:text="@string/label_usage" />
|
||||
|
||||
<CheckBox
|
||||
android:id="@+id/chkSign"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/flag_sign" />
|
||||
</TableRow>
|
||||
|
||||
<TableRow android:id="@+id/row_encrypt">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:paddingRight="10dip" />
|
||||
|
||||
<CheckBox
|
||||
android:id="@+id/chkEncrypt"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/flag_encrypt" />
|
||||
</TableRow>
|
||||
|
||||
<TableRow android:id="@+id/row_authenticate">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:paddingRight="10dip" />
|
||||
|
||||
<CheckBox
|
||||
android:id="@+id/chkAuthenticate"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/flag_authenticate" />
|
||||
</TableRow>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
@@ -17,13 +100,6 @@
|
||||
android:padding="4dp"
|
||||
android:text="@string/key_creation_el_gamal_info" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:padding="4dp"
|
||||
android:text="@string/key_creation_weak_rsa_info" />
|
||||
|
||||
<TableRow>
|
||||
|
||||
<TextView
|
||||
@@ -58,28 +134,28 @@
|
||||
</TableRow>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/custom_key_size_label"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:padding="4dp"
|
||||
android:text="@string/key_size_custom_info"
|
||||
android:visibility="gone"/>
|
||||
android:id="@+id/custom_key_size_label"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:padding="4dp"
|
||||
android:text="@string/key_size_custom_info"
|
||||
android:visibility="gone" />
|
||||
|
||||
<EditText
|
||||
android:id="@+id/custom_key_size_input"
|
||||
android:layout_width="0dip"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:inputType="number"
|
||||
android:visibility="gone"/>
|
||||
android:id="@+id/custom_key_size_input"
|
||||
android:layout_width="0dip"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:inputType="number"
|
||||
android:visibility="gone" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/custom_key_size_info"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:padding="4dp" />
|
||||
android:id="@+id/custom_key_size_info"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:padding="4dp" />
|
||||
|
||||
</TableLayout>
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
android:text="@string/label_key_id" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/keyId"
|
||||
android:id="@+id/subkey_item_key_id"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingRight="5dip"
|
||||
|
||||
@@ -1,179 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:orientation="horizontal"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="5dp">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:minWidth="10dp"
|
||||
android:background="@color/android_green_light" />
|
||||
|
||||
<TableLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:paddingLeft="8dp"
|
||||
android:stretchColumns="1">
|
||||
|
||||
<TableRow>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/label_expiry"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:paddingRight="10dip"
|
||||
android:text="@string/label_expiry" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/expiry"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="40dp"
|
||||
android:text="@string/none"
|
||||
android:background="@drawable/button_edgy" />
|
||||
</TableRow>
|
||||
|
||||
<TableRow
|
||||
android:id="@+id/row_certify">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/label_usage"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:paddingRight="10dip"
|
||||
android:text="@string/label_usage" />
|
||||
<CheckBox
|
||||
android:id="@+id/chkCertify"
|
||||
android:enabled = "false"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/flag_certify" />
|
||||
</TableRow>
|
||||
|
||||
<TableRow
|
||||
android:id="@+id/row_sign">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/label_usage2"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:paddingRight="10dip"
|
||||
android:text="@string/label_usage" />
|
||||
<CheckBox
|
||||
android:id="@+id/chkSign"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/flag_sign" />
|
||||
</TableRow>
|
||||
|
||||
<TableRow
|
||||
android:id="@+id/row_encrypt">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:paddingRight="10dip" />
|
||||
<CheckBox
|
||||
android:id="@+id/chkEncrypt"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/flag_encrypt" />
|
||||
</TableRow>
|
||||
|
||||
<TableRow
|
||||
android:id="@+id/row_authenticate">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:paddingRight="10dip" />
|
||||
<CheckBox
|
||||
android:id="@+id/chkAuthenticate"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/flag_authenticate" />
|
||||
</TableRow>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:padding="4dp"
|
||||
android:text="@string/key_creation_el_gamal_info" />
|
||||
|
||||
<TableRow>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:padding="4dp"
|
||||
android:text="@string/label_algorithm" />
|
||||
|
||||
<Spinner
|
||||
android:id="@+id/create_key_algorithm"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="4dp" />
|
||||
</TableRow>
|
||||
|
||||
<TableRow>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:padding="4dp"
|
||||
android:text="@string/label_key_size" />
|
||||
|
||||
<Spinner
|
||||
android:id="@+id/create_key_size"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="right"
|
||||
android:padding="4dp" />
|
||||
</TableRow>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/custom_key_size_label"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:padding="4dp"
|
||||
android:text="@string/key_size_custom_info"
|
||||
android:visibility="gone" />
|
||||
|
||||
<EditText
|
||||
android:id="@+id/custom_key_size_input"
|
||||
android:layout_width="0dip"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:inputType="number"
|
||||
android:visibility="gone" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/custom_key_size_info"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:padding="4dp"
|
||||
android:visibility="gone" />
|
||||
|
||||
</TableLayout>
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/subkey_added_item_delete"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:padding="8dp"
|
||||
android:src="@drawable/ic_action_cancel"
|
||||
android:layout_gravity="center_vertical"
|
||||
style="@style/SelectableItem" />
|
||||
</LinearLayout>
|
||||
@@ -100,7 +100,7 @@
|
||||
android:orientation="vertical" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/keyId"
|
||||
android:id="@+id/subkey_item_key_id"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="0xBBBBBBBBBBBBBBBB"
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
android:textAppearance="?android:attr/textAppearanceSmall" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/keyId"
|
||||
android:id="@+id/subkey_item_key_id"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="0xBBBBBBBBBBBBBBB"
|
||||
|
||||
@@ -6,36 +6,39 @@
|
||||
android:orientation="horizontal"
|
||||
android:singleLine="true">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ic_masterKey"
|
||||
<FrameLayout
|
||||
android:id="@+id/subkey_item_buttons"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:src="@drawable/key_small"
|
||||
android:padding="8dp"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_alignParentLeft="true"
|
||||
android:layout_alignParentStart="true" />
|
||||
|
||||
<ImageView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:id="@+id/user_id_item_edit_image"
|
||||
android:src="@drawable/ic_action_edit"
|
||||
android:padding="8dp"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_alignParentEnd="true" />
|
||||
android:layout_alignParentEnd="true">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/subkey_item_edit_image"
|
||||
android:src="@drawable/ic_action_edit"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="8dp" />
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/subkey_item_delete_button"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="8dp"
|
||||
android:src="@drawable/ic_action_cancel"
|
||||
style="@style/SelectableItem" />
|
||||
|
||||
</FrameLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:orientation="vertical"
|
||||
android:layout_toRightOf="@id/ic_masterKey"
|
||||
android:layout_toLeftOf="@id/user_id_item_edit_image"
|
||||
android:layout_toLeftOf="@id/subkey_item_buttons"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginRight="8dp"
|
||||
android:id="@+id/linearLayout">
|
||||
android:layout_marginLeft="8dp"
|
||||
android:layout_marginRight="8dp">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
@@ -46,7 +49,7 @@
|
||||
android:paddingTop="2dip">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/keyId"
|
||||
android:id="@+id/subkey_item_key_id"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="0x00000000"
|
||||
@@ -55,7 +58,7 @@
|
||||
android:layout_weight="1" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ic_certifyKey"
|
||||
android:id="@+id/subkey_item_ic_certify"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/certify_small"
|
||||
@@ -63,7 +66,7 @@
|
||||
android:layout_gravity="center_vertical" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ic_encryptKey"
|
||||
android:id="@+id/subkey_item_ic_encrypt"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/encrypted_small"
|
||||
@@ -71,7 +74,7 @@
|
||||
android:layout_gravity="center_vertical" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ic_signKey"
|
||||
android:id="@+id/subkey_item_ic_sign"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/signed_small"
|
||||
@@ -79,7 +82,7 @@
|
||||
android:layout_gravity="center_vertical" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ic_revokedKey"
|
||||
android:id="@+id/subkey_item_ic_revoked"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/revoked_key_small"
|
||||
@@ -94,7 +97,7 @@
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/keyDetails"
|
||||
android:id="@+id/subkey_item_details"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingRight="5dip"
|
||||
@@ -103,7 +106,7 @@
|
||||
android:layout_weight="1" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/keyExpiry"
|
||||
android:id="@+id/subkey_item_expiry"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="Expiry: 4/7/2016"
|
||||
|
||||
Reference in New Issue
Block a user