diff options
author | Dominik Schürmann <dominik@dominikschuermann.de> | 2014-06-18 00:03:06 +0200 |
---|---|---|
committer | Dominik Schürmann <dominik@dominikschuermann.de> | 2014-06-18 00:03:06 +0200 |
commit | 8c7a360d6ed6875774c912e070cb18807e0e831d (patch) | |
tree | 1ee9bfe4f518a127270d2ad1bcfaf88f4f470d12 /OpenKeychain/src/main/res/layout | |
parent | 21e9d0b7b4b0375c43287d4acd66ee01f2f1d5a0 (diff) | |
download | open-keychain-8c7a360d6ed6875774c912e070cb18807e0e831d.tar.gz open-keychain-8c7a360d6ed6875774c912e070cb18807e0e831d.tar.bz2 open-keychain-8c7a360d6ed6875774c912e070cb18807e0e831d.zip |
Redesign Import, still some todos and regression bugs
Diffstat (limited to 'OpenKeychain/src/main/res/layout')
9 files changed, 201 insertions, 120 deletions
diff --git a/OpenKeychain/src/main/res/layout/import_keys_activity.xml b/OpenKeychain/src/main/res/layout/import_keys_activity.xml index 0486b6bd6..fc9d21e23 100644 --- a/OpenKeychain/src/main/res/layout/import_keys_activity.xml +++ b/OpenKeychain/src/main/res/layout/import_keys_activity.xml @@ -3,7 +3,7 @@ android:id="@+id/content_frame" android:layout_marginLeft="@dimen/drawer_content_padding" android:layout_width="match_parent" - android:layout_height="fill_parent" + android:layout_height="match_parent" android:orientation="vertical"> <LinearLayout @@ -12,21 +12,38 @@ android:layout_height="wrap_content" android:orientation="vertical" /> - <FrameLayout - android:id="@+id/import_navigation_fragment" + <org.sufficientlysecure.keychain.ui.widget.SlidingTabLayout + android:id="@+id/import_sliding_tab_layout" android:layout_width="match_parent" - android:layout_height="wrap_content" - android:orientation="vertical" /> + android:layout_height="wrap_content" /> + + <android.support.v4.view.ViewPager + android:id="@+id/import_pager" + android:layout_width="match_parent" + android:layout_height="64dp" + android:background="@android:color/white" /> + + <View + android:layout_width="match_parent" + android:layout_height="2dip" + android:background="?android:attr/listDivider" /> + + <View + android:layout_width="match_parent" + android:layout_height="16dp" /> + + <View + android:layout_width="match_parent" + android:layout_height="2dip" + android:background="?android:attr/listDivider" /> <FrameLayout android:id="@+id/import_keys_list_container" android:layout_width="match_parent" android:layout_height="0dp" android:orientation="vertical" - android:paddingTop="8dp" - android:paddingLeft="16dp" - android:paddingRight="16dp" - android:layout_weight="0.9" /> + android:layout_weight="1" + android:background="@android:color/white" /> <LinearLayout android:id="@+id/import_footer" @@ -34,7 +51,8 @@ android:layout_height="wrap_content" android:orientation="vertical" android:paddingLeft="16dp" - android:paddingRight="16dp"> + android:paddingRight="16dp" + android:background="@android:color/white"> <View android:layout_width="match_parent" diff --git a/OpenKeychain/src/main/res/layout/import_keys_clipboard_fragment.xml b/OpenKeychain/src/main/res/layout/import_keys_clipboard_fragment.xml deleted file mode 100644 index 739c34fba..000000000 --- a/OpenKeychain/src/main/res/layout/import_keys_clipboard_fragment.xml +++ /dev/null @@ -1,20 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" - xmlns:bootstrapbutton="http://schemas.android.com/apk/res-auto" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:paddingTop="8dp" - android:paddingLeft="16dp" - android:paddingRight="16dp" - android:orientation="horizontal" > - - <com.beardedhen.androidbootstrap.BootstrapButton - android:id="@+id/import_clipboard_button" - android:layout_width="match_parent" - android:layout_height="70dp" - android:text="@string/import_clipboard_button" - bootstrapbutton:bb_icon_left="fa-clipboard" - bootstrapbutton:bb_size="default" - bootstrapbutton:bb_type="default" /> - -</LinearLayout>
\ No newline at end of file diff --git a/OpenKeychain/src/main/res/layout/import_keys_file_fragment.xml b/OpenKeychain/src/main/res/layout/import_keys_file_fragment.xml index c07d2bb40..b1056dab3 100644 --- a/OpenKeychain/src/main/res/layout/import_keys_file_fragment.xml +++ b/OpenKeychain/src/main/res/layout/import_keys_file_fragment.xml @@ -1,21 +1,66 @@ <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" - xmlns:bootstrapbutton="http://schemas.android.com/apk/res-auto" android:layout_width="match_parent" android:layout_height="wrap_content" - android:paddingTop="8dp" - android:paddingLeft="16dp" - android:paddingRight="16dp" android:orientation="vertical"> - <com.beardedhen.androidbootstrap.BootstrapButton + <LinearLayout android:id="@+id/import_keys_file_browse" + android:paddingLeft="8dp" android:layout_width="match_parent" - android:layout_height="70dp" - android:text="@string/filemanager_title_open" - android:contentDescription="@string/filemanager_title_open" - bootstrapbutton:bb_icon_left="fa-folder-open" - bootstrapbutton:bb_size="default" - bootstrapbutton:bb_type="default" /> + android:layout_height="?android:attr/listPreferredItemHeight" + android:clickable="true" + style="@style/SelectableItem" + android:orientation="horizontal"> + + <TextView + android:paddingLeft="8dp" + android:paddingRight="8dp" + android:textAppearance="?android:attr/textAppearanceMedium" + android:layout_width="0dip" + android:layout_height="match_parent" + android:text="@string/filemanager_title_open" + android:layout_weight="1" + android:drawableRight="@drawable/ic_action_collection" + android:drawablePadding="8dp" + android:gravity="center_vertical" /> + + <View + android:layout_width="1dip" + android:layout_height="match_parent" + android:gravity="right" + android:layout_marginBottom="8dp" + android:layout_marginTop="8dp" + android:background="?android:attr/listDivider" /> + + <ImageButton + android:id="@+id/import_clipboard_button" + android:layout_width="wrap_content" + android:layout_height="match_parent" + android:padding="8dp" + android:src="@drawable/ic_action_paste" + android:layout_gravity="center_vertical" + style="@style/SelectableItem" /> + + </LinearLayout> + + <TextView + android:id="@+id/import_qrcode_text" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:paddingLeft="16dp" + android:paddingRight="16dp" + android:paddingTop="8dp" + android:visibility="gone" /> + + <ProgressBar + android:id="@+id/import_qrcode_progress" + style="?android:attr/progressBarStyleHorizontal" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:paddingLeft="16dp" + android:paddingRight="16dp" + android:progress="0" + android:visibility="gone" /> </LinearLayout>
\ No newline at end of file diff --git a/OpenKeychain/src/main/res/layout/import_keys_keybase_fragment.xml b/OpenKeychain/src/main/res/layout/import_keys_keybase_fragment.xml index ceba0e1ce..bf00b77e7 100644 --- a/OpenKeychain/src/main/res/layout/import_keys_keybase_fragment.xml +++ b/OpenKeychain/src/main/res/layout/import_keys_keybase_fragment.xml @@ -1,16 +1,12 @@ <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" - xmlns:bootstrapbutton="http://schemas.android.com/apk/res-auto" android:layout_width="match_parent" android:layout_height="wrap_content" - android:paddingTop="8dp" - android:paddingLeft="16dp" - android:paddingRight="16dp" android:orientation="horizontal"> - <EditText android:id="@+id/import_keybase_query" + android:layout_marginLeft="8dp" android:layout_width="0dip" android:layout_height="wrap_content" android:layout_weight="1" @@ -22,17 +18,24 @@ android:lines="1" android:maxLines="1" android:minLines="1" + android:layout_marginRight="8dp" android:layout_gravity="center_vertical" /> - <com.beardedhen.androidbootstrap.BootstrapButton + <View + android:layout_width="1dip" + android:layout_height="match_parent" + android:gravity="right" + android:layout_marginBottom="8dp" + android:layout_marginTop="8dp" + android:background="?android:attr/listDivider" /> + + <ImageButton android:id="@+id/import_keybase_search" android:layout_width="wrap_content" - android:layout_height="wrap_content" + android:layout_height="match_parent" + android:padding="16dp" + android:src="@drawable/ic_action_search" android:layout_gravity="center_vertical" - android:layout_marginLeft="8dp" - bootstrapbutton:bb_icon_left="fa-search" - bootstrapbutton:bb_roundedCorners="true" - bootstrapbutton:bb_size="default" - bootstrapbutton:bb_type="default" /> + style="@style/SelectableItem" /> </LinearLayout>
\ No newline at end of file diff --git a/OpenKeychain/src/main/res/layout/import_keys_list_entry.xml b/OpenKeychain/src/main/res/layout/import_keys_list_entry.xml index c91335a5b..56f34e2eb 100644 --- a/OpenKeychain/src/main/res/layout/import_keys_list_entry.xml +++ b/OpenKeychain/src/main/res/layout/import_keys_list_entry.xml @@ -17,9 +17,13 @@ <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="wrap_content" + android:minHeight="?android:attr/listPreferredItemHeight" android:orientation="horizontal" - android:paddingRight="?android:attr/scrollbarSize" - android:singleLine="true"> + android:singleLine="true" + android:paddingLeft="8dp" + android:paddingRight="16dp" + android:paddingTop="4dp" + android:paddingBottom="4dp"> <CheckBox android:id="@+id/selected" diff --git a/OpenKeychain/src/main/res/layout/import_keys_nfc_fragment.xml b/OpenKeychain/src/main/res/layout/import_keys_nfc_fragment.xml deleted file mode 100644 index 8c0a80e4e..000000000 --- a/OpenKeychain/src/main/res/layout/import_keys_nfc_fragment.xml +++ /dev/null @@ -1,30 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" - xmlns:bootstrapbutton="http://schemas.android.com/apk/res-auto" - android:layout_width="fill_parent" - android:layout_height="wrap_content" - android:paddingTop="8dp" - android:paddingLeft="16dp" - android:paddingRight="16dp" - android:orientation="horizontal"> - - <com.beardedhen.androidbootstrap.BootstrapButton - android:id="@+id/import_nfc_button" - android:layout_width="wrap_content" - android:layout_height="70dp" - android:layout_alignParentRight="true" - android:layout_alignParentTop="true" - android:layout_marginLeft="8dp" - android:text="@string/import_nfc_help_button" - bootstrapbutton:bb_icon_left="fa-question" - bootstrapbutton:bb_size="default" - bootstrapbutton:bb_type="default" /> - - <TextView - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:layout_centerVertical="true" - android:layout_toLeftOf="@+id/import_nfc_button" - android:text="@string/import_nfc_text" /> - -</RelativeLayout>
\ No newline at end of file diff --git a/OpenKeychain/src/main/res/layout/import_keys_qr_code_fragment.xml b/OpenKeychain/src/main/res/layout/import_keys_qr_code_fragment.xml index 590f7f797..09a31b4a8 100644 --- a/OpenKeychain/src/main/res/layout/import_keys_qr_code_fragment.xml +++ b/OpenKeychain/src/main/res/layout/import_keys_qr_code_fragment.xml @@ -1,21 +1,48 @@ <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" - xmlns:bootstrapbutton="http://schemas.android.com/apk/res-auto" - android:layout_width="fill_parent" + android:layout_width="match_parent" android:layout_height="wrap_content" - android:paddingTop="8dp" - android:paddingLeft="16dp" - android:paddingRight="16dp" android:orientation="vertical"> - <com.beardedhen.androidbootstrap.BootstrapButton + <LinearLayout android:id="@+id/import_qrcode_button" + android:paddingLeft="8dp" android:layout_width="match_parent" - android:layout_height="70dp" - android:text="@string/import_qr_scan_button" - bootstrapbutton:bb_icon_left="fa-barcode" - bootstrapbutton:bb_size="default" - bootstrapbutton:bb_type="default" /> + android:layout_height="?android:attr/listPreferredItemHeight" + android:clickable="true" + style="@style/SelectableItem" + android:orientation="horizontal"> + + <TextView + android:paddingLeft="8dp" + android:paddingRight="8dp" + android:textAppearance="?android:attr/textAppearanceMedium" + android:layout_width="0dip" + android:layout_height="match_parent" + android:text="@string/import_qr_code_button" + android:layout_weight="1" + android:drawableRight="@drawable/ic_action_qr_code" + android:drawablePadding="8dp" + android:gravity="center_vertical" /> + + <View + android:layout_width="1dip" + android:layout_height="match_parent" + android:gravity="right" + android:layout_marginBottom="8dp" + android:layout_marginTop="8dp" + android:background="?android:attr/listDivider" /> + + <Button + android:id="@+id/import_nfc_button" + android:layout_width="wrap_content" + android:layout_height="match_parent" + android:padding="8dp" + android:text="NFC?" + android:layout_gravity="center_vertical" + style="@style/SelectableItem" /> + + </LinearLayout> <TextView android:id="@+id/import_qrcode_text" diff --git a/OpenKeychain/src/main/res/layout/import_keys_server_fragment.xml b/OpenKeychain/src/main/res/layout/import_keys_server_fragment.xml index e17dbe783..7562eaa9b 100644 --- a/OpenKeychain/src/main/res/layout/import_keys_server_fragment.xml +++ b/OpenKeychain/src/main/res/layout/import_keys_server_fragment.xml @@ -1,20 +1,13 @@ <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" - xmlns:bootstrapbutton="http://schemas.android.com/apk/res-auto" + xmlns:custom="http://schemas.android.com/apk/res-auto" android:layout_width="match_parent" - android:layout_height="match_parent" - android:paddingTop="8dp" - android:paddingLeft="16dp" - android:paddingRight="16dp" + android:layout_height="wrap_content" android:orientation="vertical"> - <Spinner - android:id="@+id/import_server_spinner" - android:layout_width="match_parent" - android:layout_height="wrap_content" /> - <LinearLayout android:layout_width="match_parent" - android:layout_height="wrap_content" + android:paddingLeft="8dp" + android:layout_height="?android:attr/listPreferredItemHeight" android:orientation="horizontal"> <EditText @@ -30,18 +23,63 @@ android:lines="1" android:maxLines="1" android:minLines="1" + android:layout_marginRight="8dp" android:layout_gravity="center_vertical" /> - <com.beardedhen.androidbootstrap.BootstrapButton + <View + android:layout_width="1dip" + android:layout_height="match_parent" + android:gravity="right" + android:layout_marginBottom="8dp" + android:layout_marginTop="8dp" + android:background="?android:attr/listDivider" /> + + <ImageButton android:id="@+id/import_server_search" android:layout_width="wrap_content" - android:layout_height="wrap_content" + android:layout_height="match_parent" + android:padding="16dp" + android:src="@drawable/ic_action_search" + android:layout_gravity="center_vertical" + style="@style/SelectableItem" /> + + <View + android:layout_width="1dip" + android:layout_height="match_parent" + android:gravity="right" + android:layout_marginBottom="8dp" + android:layout_marginTop="8dp" + android:background="?android:attr/listDivider" /> + + <ImageButton + android:id="@+id/import_server_config_button" + android:layout_width="wrap_content" + android:layout_height="match_parent" + android:padding="8dp" + android:src="@drawable/ic_action_settings" android:layout_gravity="center_vertical" + style="@style/SelectableItem" /> + + </LinearLayout> + + <LinearLayout + android:id="@+id/import_server_config" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:orientation="vertical"> + + <View + android:layout_width="match_parent" + android:layout_height="1dip" + android:background="?android:attr/listDivider" /> + + <Spinner + android:id="@+id/import_server_spinner" android:layout_marginLeft="8dp" - bootstrapbutton:bb_icon_left="fa-search" - bootstrapbutton:bb_roundedCorners="true" - bootstrapbutton:bb_size="default" - bootstrapbutton:bb_type="default" /> + android:layout_marginRight="8dp" + android:layout_width="match_parent" + android:layout_height="wrap_content" /> + </LinearLayout> </LinearLayout>
\ No newline at end of file diff --git a/OpenKeychain/src/main/res/layout/view_key_share_fragment.xml b/OpenKeychain/src/main/res/layout/view_key_share_fragment.xml index 67c2e241a..1cd2b9f1b 100644 --- a/OpenKeychain/src/main/res/layout/view_key_share_fragment.xml +++ b/OpenKeychain/src/main/res/layout/view_key_share_fragment.xml @@ -24,8 +24,7 @@ <LinearLayout android:id="@+id/view_key_action_fingerprint_share" android:layout_width="match_parent" - android:layout_height="wrap_content" - android:minHeight="?android:attr/listPreferredItemHeight" + android:layout_height="?android:attr/listPreferredItemHeight" android:clickable="true" style="@style/SelectableItem" android:orientation="horizontal"> @@ -63,7 +62,6 @@ </LinearLayout> - <View android:layout_width="match_parent" android:layout_height="1dip" @@ -90,8 +88,7 @@ <LinearLayout android:id="@+id/view_key_action_key_share" android:layout_width="match_parent" - android:layout_height="wrap_content" - android:minHeight="?android:attr/listPreferredItemHeight" + android:layout_height="?android:attr/listPreferredItemHeight" android:clickable="true" style="@style/SelectableItem" android:orientation="horizontal"> @@ -135,8 +132,7 @@ <LinearLayout android:id="@+id/view_key_action_nfc_help" android:layout_width="match_parent" - android:layout_height="wrap_content" - android:minHeight="?android:attr/listPreferredItemHeight" + android:layout_height="?android:attr/listPreferredItemHeight" android:clickable="true" style="@style/SelectableItem" android:orientation="horizontal" |