diff options
author | mar-v-in <github@rvin.mooo.com> | 2014-07-06 02:10:35 +0200 |
---|---|---|
committer | mar-v-in <github@rvin.mooo.com> | 2014-07-06 02:10:35 +0200 |
commit | 1b0666e9de5caea14997a3e638a6209b45c97d60 (patch) | |
tree | 5062c61342a65aa0c1e49423dc2510ce43cbcf08 /OpenKeychain/src/main/res/layout | |
parent | 51a4b0466ba1e1c1c72d9d8112c28628d1efc84b (diff) | |
download | open-keychain-1b0666e9de5caea14997a3e638a6209b45c97d60.tar.gz open-keychain-1b0666e9de5caea14997a3e638a6209b45c97d60.tar.bz2 open-keychain-1b0666e9de5caea14997a3e638a6209b45c97d60.zip |
Many changes to file ... and still incomplete
- Multi file
- Reworked UI
Diffstat (limited to 'OpenKeychain/src/main/res/layout')
10 files changed, 253 insertions, 237 deletions
diff --git a/OpenKeychain/src/main/res/layout/encrypt_activity.xml b/OpenKeychain/src/main/res/layout/encrypt_activity.xml index 65c2ee8fd..839bddc75 100644 --- a/OpenKeychain/src/main/res/layout/encrypt_activity.xml +++ b/OpenKeychain/src/main/res/layout/encrypt_activity.xml @@ -1,10 +1,11 @@ <?xml version="1.0" encoding="utf-8"?> -<android.support.v4.widget.FixedDrawerLayout xmlns:android="http://schemas.android.com/apk/res/android" - xmlns:bootstrapbutton="http://schemas.android.com/apk/res-auto" - xmlns:fontawesometext="http://schemas.android.com/apk/res-auto" - android:id="@+id/drawer_layout" - android:layout_width="match_parent" - android:layout_height="match_parent"> +<android.support.v4.widget.FixedDrawerLayout + xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:tools="http://schemas.android.com/tools" + android:id="@+id/drawer_layout" + android:layout_width="match_parent" + android:layout_height="match_parent" + tools:context=".ui.EncryptActivity"> <include layout="@layout/encrypt_content"/> diff --git a/OpenKeychain/src/main/res/layout/encrypt_asymmetric_fragment.xml b/OpenKeychain/src/main/res/layout/encrypt_asymmetric_fragment.xml index cde92b477..284fdd9ce 100644 --- a/OpenKeychain/src/main/res/layout/encrypt_asymmetric_fragment.xml +++ b/OpenKeychain/src/main/res/layout/encrypt_asymmetric_fragment.xml @@ -9,69 +9,15 @@ android:paddingRight="16dp" android:paddingLeft="16dp"> - <LinearLayout - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:orientation="horizontal"> - - <CheckBox + <CheckBox android:id="@+id/sign" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="center_vertical" - android:text="@string/label_sign" /> + android:text="@string/label_sign"/> - <LinearLayout + <org.sufficientlysecure.keychain.ui.widget.EncryptKeyCompletionView + android:id="@+id/recipient_list" android:layout_width="match_parent" - android:layout_height="wrap_content" - android:orientation="vertical" - android:paddingLeft="16dp" - android:paddingRight="4dip"> - - <TextView - android:id="@+id/mainUserId" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:layout_gravity="right" - android:ellipsize="end" - android:singleLine="true" - android:text="" - android:textAppearance="?android:attr/textAppearanceMedium" /> - - <TextView - android:id="@+id/mainUserIdRest" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:layout_gravity="right" - android:ellipsize="end" - android:singleLine="true" - android:text="" - android:textAppearance="?android:attr/textAppearanceSmall" /> - </LinearLayout> - </LinearLayout> - - <LinearLayout - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:orientation="horizontal"> - - <TextView - android:id="@+id/label_selectPublicKeys" - android:layout_width="0dip" - android:layout_height="wrap_content" - android:layout_gravity="center_vertical" - android:layout_weight="1" - android:text="@string/label_select_public_keys" - android:textAppearance="?android:attr/textAppearanceMedium" /> - - <Button - android:id="@+id/btn_selectEncryptKeys" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:layout_gravity="center_vertical" - android:layout_margin="4dp" - android:text="@string/select_keys_button_default" - android:background="@drawable/button_edgy" - android:drawableLeft="@drawable/ic_action_person" /> - </LinearLayout> + android:layout_height="wrap_content"/> </LinearLayout>
\ No newline at end of file diff --git a/OpenKeychain/src/main/res/layout/encrypt_content.xml b/OpenKeychain/src/main/res/layout/encrypt_content.xml index e719d07e1..ec71b25e5 100644 --- a/OpenKeychain/src/main/res/layout/encrypt_content.xml +++ b/OpenKeychain/src/main/res/layout/encrypt_content.xml @@ -6,19 +6,12 @@ android:layout_height="match_parent" android:orientation="vertical"> - <android.support.v4.view.ViewPager + <org.sufficientlysecure.keychain.ui.widget.NoSwipeWrapContentViewPager android:id="@+id/encrypt_pager_mode" android:layout_width="match_parent" - android:layout_height="150dp"> + android:layout_height="wrap_content"> - <android.support.v4.view.PagerTabStrip - android:id="@+id/encrypt_pager_tab_strip_mode" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:layout_gravity="top" - android:background="@color/emphasis" - android:textColor="#fff" /> - </android.support.v4.view.ViewPager> + </org.sufficientlysecure.keychain.ui.widget.NoSwipeWrapContentViewPager> <android.support.v4.view.ViewPager android:id="@+id/encrypt_pager_content" @@ -30,8 +23,7 @@ android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_gravity="top" - android:background="@color/emphasis" - android:textColor="#fff" /> + android:textColor="@color/emphasis" /> </android.support.v4.view.ViewPager> </LinearLayout>
\ No newline at end of file diff --git a/OpenKeychain/src/main/res/layout/encrypt_content_adv_settings.xml b/OpenKeychain/src/main/res/layout/encrypt_content_adv_settings.xml index 8394fd4fe..67f7032c1 100644 --- a/OpenKeychain/src/main/res/layout/encrypt_content_adv_settings.xml +++ b/OpenKeychain/src/main/res/layout/encrypt_content_adv_settings.xml @@ -21,30 +21,4 @@ android:layout_height="wrap_content" android:layout_gravity="center_vertical"/> </LinearLayout> - - <LinearLayout - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:orientation="horizontal"> - - <CheckBox - android:id="@+id/deleteAfterEncryption" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:layout_gravity="center_vertical" - android:text="@string/label_delete_after_encryption"/> - </LinearLayout> - - <LinearLayout - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:orientation="horizontal"> - - <CheckBox - android:id="@+id/asciiArmor" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:layout_gravity="center_vertical" - android:text="@string/label_ascii_armor"/> - </LinearLayout> </merge> diff --git a/OpenKeychain/src/main/res/layout/encrypt_file_fragment.xml b/OpenKeychain/src/main/res/layout/encrypt_file_fragment.xml index c97069e67..d52097433 100644 --- a/OpenKeychain/src/main/res/layout/encrypt_file_fragment.xml +++ b/OpenKeychain/src/main/res/layout/encrypt_file_fragment.xml @@ -1,46 +1,15 @@ <?xml version="1.0" encoding="utf-8"?> <ScrollView xmlns:android="http://schemas.android.com/apk/res/android" - xmlns:custom="http://schemas.android.com/apk/res-auto" android:layout_width="match_parent" android:layout_height="match_parent" android:fillViewport="true"> <LinearLayout - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:paddingLeft="16dp" - android:paddingRight="16dp" - android:orientation="vertical"> - - <LinearLayout android:layout_width="match_parent" - android:layout_height="?android:attr/listPreferredItemHeight" - android:orientation="horizontal" - - android:id="@+id/btn_browse" - android:clickable="true" - style="@style/SelectableItem"> - - <TextView - android:layout_width="wrap_content" - android:layout_height="match_parent" - android:paddingLeft="8dp" - android:textAppearance="?android:attr/textAppearanceMedium" - android:text="@string/label_file_colon" - android:gravity="center_vertical"/> - - <TextView - android:id="@+id/filename" - android:paddingLeft="8dp" - android:paddingRight="8dp" - android:textAppearance="?android:attr/textAppearanceMedium" - android:layout_width="match_parent" - android:layout_height="match_parent" - android:hint="@string/filemanager_title_open" - android:drawableRight="@drawable/ic_action_collection" - android:drawablePadding="8dp" - android:gravity="center_vertical"/> - </LinearLayout> + android:layout_height="wrap_content" + android:paddingLeft="16dp" + android:paddingRight="16dp" + android:orientation="vertical"> <View android:layout_width="match_parent" @@ -48,73 +17,66 @@ android:background="?android:attr/listDivider" android:layout_marginBottom="8dp"/> - <org.sufficientlysecure.keychain.ui.widget.FoldableLinearLayout - android:layout_width="match_parent" - android:layout_height="wrap_content" - custom:foldedLabel="@string/btn_encryption_advanced_settings_show" - custom:unFoldedLabel="@string/btn_encryption_advanced_settings_hide" - custom:foldedIcon="fa-chevron-right" - custom:unFoldedIcon="fa-chevron-down"> + <ListView + android:id="@+id/selected_files_list" + android:dividerHeight="4dip" + android:divider="@android:color/transparent" + android:layout_width="match_parent" + android:layout_height="0dip" + android:layout_weight="1"/> - <include layout="@layout/encrypt_content_adv_settings" /> + <View + android:layout_width="match_parent" + android:layout_height="1dip" + android:background="?android:attr/listDivider" + android:layout_marginBottom="8dp"/> - </org.sufficientlysecure.keychain.ui.widget.FoldableLinearLayout> + <include layout="@layout/encrypt_content_adv_settings" /> - <RelativeLayout - android:layout_width="match_parent" - android:layout_height="match_parent"> + <View + android:layout_width="match_parent" + android:layout_height="1dip" + android:background="?android:attr/listDivider"/> + <LinearLayout + android:id="@+id/action_encrypt_share" + android:paddingLeft="8dp" + android:layout_width="match_parent" + android:layout_height="?android:attr/listPreferredItemHeight" + android:layout_marginBottom="8dp" + android:clickable="true" + style="@style/SelectableItem" + android:orientation="horizontal"> - <LinearLayout - android:id="@+id/action_encrypt_share" + <TextView android:paddingLeft="8dp" - android:layout_width="match_parent" - android:layout_height="?android:attr/listPreferredItemHeight" - android:layout_alignParentBottom="true" - android:layout_alignParentLeft="true" - android:layout_alignParentStart="true" - android:layout_marginBottom="8dp" - 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/btn_encrypt_share_file" - android:layout_weight="1" - android:drawableRight="@drawable/ic_action_share" - 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/action_encrypt_file" - android:layout_width="wrap_content" - android:layout_height="match_parent" - android:padding="8dp" - android:src="@drawable/ic_action_save" - android:layout_gravity="center_vertical" - style="@style/SelectableItem"/> - - </LinearLayout> + android:paddingRight="8dp" + android:textAppearance="?android:attr/textAppearanceMedium" + android:layout_width="0dip" + android:layout_height="match_parent" + android:text="@string/btn_encrypt_share_file" + android:layout_weight="1" + android:drawableRight="@drawable/ic_action_share" + android:drawablePadding="8dp" + android:gravity="center_vertical"/> <View - android:layout_width="match_parent" - android:layout_height="1dip" - android:background="?android:attr/listDivider" - android:layout_above="@+id/action_encrypt_share"/> + 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/action_encrypt_file" + android:layout_width="wrap_content" + android:layout_height="match_parent" + android:padding="8dp" + android:src="@drawable/ic_action_save" + android:layout_gravity="center_vertical" + style="@style/SelectableItem"/> - </RelativeLayout> + </LinearLayout> </LinearLayout> </ScrollView>
\ No newline at end of file diff --git a/OpenKeychain/src/main/res/layout/encrypt_symmetric_fragment.xml b/OpenKeychain/src/main/res/layout/encrypt_symmetric_fragment.xml index 89381e499..699f991a7 100644 --- a/OpenKeychain/src/main/res/layout/encrypt_symmetric_fragment.xml +++ b/OpenKeychain/src/main/res/layout/encrypt_symmetric_fragment.xml @@ -1,52 +1,46 @@ <?xml version="1.0" encoding="utf-8"?> -<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" +<TableLayout xmlns:android="http://schemas.android.com/apk/res/android" + android:id="@+id/modeSymmetric" android:layout_width="match_parent" - android:layout_height="match_parent" + android:layout_height="wrap_content" + android:stretchColumns="1" android:paddingTop="4dp" android:paddingBottom="4dp" android:paddingLeft="16dp" android:paddingRight="16dp" - android:orientation="vertical"> + android:layout_centerVertical="true"> - <TableLayout - android:id="@+id/modeSymmetric" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:stretchColumns="1" - android:layout_centerVertical="true"> + <TableRow> - <TableRow> + <TextView + android:id="@+id/label_passphrase" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:paddingRight="8dp" + android:text="@string/label_passphrase" + android:textAppearance="?android:attr/textAppearanceMedium" /> - <TextView - android:id="@+id/label_passphrase" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:paddingRight="8dp" - android:text="@string/label_passphrase" - android:textAppearance="?android:attr/textAppearanceMedium" /> + <EditText + android:id="@+id/passphrase" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:inputType="textPassword" /> + </TableRow> - <EditText - android:id="@+id/passphrase" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:inputType="textPassword" /> - </TableRow> + <TableRow> - <TableRow> + <TextView + android:id="@+id/label_passphraseAgain" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:paddingRight="8dp" + android:text="@string/label_passphrase_again" + android:textAppearance="?android:attr/textAppearanceMedium" /> - <TextView - android:id="@+id/label_passphraseAgain" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:paddingRight="8dp" - android:text="@string/label_passphrase_again" - android:textAppearance="?android:attr/textAppearanceMedium" /> - - <EditText - android:id="@+id/passphraseAgain" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:inputType="textPassword" /> - </TableRow> - </TableLayout> -</RelativeLayout>
\ No newline at end of file + <EditText + android:id="@+id/passphraseAgain" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:inputType="textPassword" /> + </TableRow> +</TableLayout>
\ No newline at end of file diff --git a/OpenKeychain/src/main/res/layout/file_list_entry.xml b/OpenKeychain/src/main/res/layout/file_list_entry.xml new file mode 100644 index 000000000..f6fde2447 --- /dev/null +++ b/OpenKeychain/src/main/res/layout/file_list_entry.xml @@ -0,0 +1,60 @@ +<?xml version="1.0" encoding="utf-8"?> + +<RelativeLayout + xmlns:android="http://schemas.android.com/apk/res/android" + android:layout_width="match_parent" + android:layout_height="48dip" + android:background="@drawable/attachment_bg_holo"> + + <ImageView + android:id="@+id/thumbnail" + android:layout_alignParentLeft="true" + android:layout_centerVertical="true" + android:scaleType="center" + android:layout_width="48dip" + android:layout_height="48dip"/> + + <LinearLayout + android:orientation="vertical" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_toRightOf="@+id/thumbnail" + android:layout_centerVertical="true"> + + <TextView + android:id="@+id/filename" + android:layout_marginLeft="8dip" + android:layout_marginRight="32dip" + android:maxLines="1" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:textColor="?android:attr/textColorSecondary" + android:textAppearance="?android:attr/textAppearanceSmall" + android:ellipsize="end"/> + + <TextView + android:id="@+id/filesize" + android:layout_marginLeft="8dip" + android:layout_marginRight="32dip" + android:maxLines="1" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:textColor="?android:attr/textColorTertiary" + android:textAppearance="?android:attr/textAppearanceSmall" + android:textSize="12sp" + android:ellipsize="end"/> + + </LinearLayout> + + <ImageButton + android:id="@+id/action_remove_file_from_list" + android:layout_width="48dip" + android:layout_height="48dip" + android:layout_alignParentRight="true" + android:paddingRight="16dip" + android:paddingLeft="16dip" + android:src="@drawable/ic_action_cancel" + android:clickable="true" + android:layout_centerVertical="true" + style="@style/SelectableItem"/> +</RelativeLayout>
\ No newline at end of file diff --git a/OpenKeychain/src/main/res/layout/file_list_entry_add.xml b/OpenKeychain/src/main/res/layout/file_list_entry_add.xml new file mode 100644 index 000000000..2f24227fa --- /dev/null +++ b/OpenKeychain/src/main/res/layout/file_list_entry_add.xml @@ -0,0 +1,21 @@ +<?xml version="1.0" encoding="utf-8"?> + +<FrameLayout + xmlns:android="http://schemas.android.com/apk/res/android" + android:padding="4dp" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:clickable="true" + style="@style/SelectableItem"> + <TextView + android:paddingLeft="8dp" + android:paddingRight="8dp" + android:textAppearance="?android:attr/textAppearanceMedium" + android:layout_width="wrap_content" + android:layout_height="match_parent" + android:layout_gravity="center" + android:text="Add file(s)" + android:drawableLeft="@drawable/ic_action_collection" + android:drawablePadding="8dp" + android:gravity="center"/> +</FrameLayout>
\ No newline at end of file diff --git a/OpenKeychain/src/main/res/layout/recipient_box_entry.xml b/OpenKeychain/src/main/res/layout/recipient_box_entry.xml new file mode 100644 index 000000000..a7862c515 --- /dev/null +++ b/OpenKeychain/src/main/res/layout/recipient_box_entry.xml @@ -0,0 +1,24 @@ +<?xml version="1.0" encoding="utf-8"?> + +<LinearLayout + xmlns:android="http://schemas.android.com/apk/res/android" + android:orientation="horizontal" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:background="@drawable/attachment_bg_holo"> + <TextView + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:padding="4dip" + android:id="@android:id/text1" + android:layout_gravity="center_vertical"/> + + <ImageView + android:id="@android:id/icon" + android:layout_width="32dip" + android:layout_height="32dip" + android:layout_marginLeft="12dip" + android:cropToPadding="true" + android:background="#ccc" + android:scaleType="centerCrop"/> +</LinearLayout>
\ No newline at end of file diff --git a/OpenKeychain/src/main/res/layout/recipient_selection_list_entry.xml b/OpenKeychain/src/main/res/layout/recipient_selection_list_entry.xml new file mode 100644 index 000000000..2be37fb4c --- /dev/null +++ b/OpenKeychain/src/main/res/layout/recipient_selection_list_entry.xml @@ -0,0 +1,42 @@ +<?xml version="1.0" encoding="utf-8"?> + +<LinearLayout + xmlns:android="http://schemas.android.com/apk/res/android" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:minHeight="48dip" + android:orientation="horizontal" + android:gravity="center_vertical"> + <LinearLayout + android:layout_width="0dip" + android:layout_height="wrap_content" + android:gravity="center_vertical" + android:orientation="vertical" + android:layout_weight="1"> + <TextView android:id="@android:id/title" + android:textColor="?android:attr/textColorSecondary" + android:textSize="18sp" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:paddingLeft="8dip" + android:singleLine="true" + android:ellipsize="end"/> + <TextView android:id="@android:id/text1" + android:textColor="?android:attr/textColorTertiary" + android:textSize="14sp" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:paddingLeft="16dip" + android:singleLine="true" + android:ellipsize="end" + android:layout_marginTop="-4dip"/> + </LinearLayout> + <ImageView + android:id="@android:id/icon" + android:layout_width="48dip" + android:layout_height="48dip" + android:layout_marginLeft="12dip" + android:cropToPadding="true" + android:background="#ccc" + android:scaleType="centerCrop"/> +</LinearLayout>
\ No newline at end of file |