mirror of
https://github.com/moparisthebest/open-keychain
synced 2025-02-12 13:10:18 -05:00
Prettify buttons
This commit is contained in:
parent
dab540e121
commit
0403cbf11a
@ -22,7 +22,6 @@ import android.os.Bundle;
|
|||||||
import android.support.v7.app.ActionBarActivity;
|
import android.support.v7.app.ActionBarActivity;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
import android.view.Window;
|
import android.view.Window;
|
||||||
import android.widget.Button;
|
|
||||||
|
|
||||||
import org.sufficientlysecure.keychain.Constants;
|
import org.sufficientlysecure.keychain.Constants;
|
||||||
import org.sufficientlysecure.keychain.R;
|
import org.sufficientlysecure.keychain.R;
|
||||||
@ -31,9 +30,9 @@ import org.sufficientlysecure.keychain.util.Log;
|
|||||||
|
|
||||||
public class FirstTimeActivity extends ActionBarActivity {
|
public class FirstTimeActivity extends ActionBarActivity {
|
||||||
|
|
||||||
Button mCreateKey;
|
View mCreateKey;
|
||||||
Button mImportKey;
|
View mImportKey;
|
||||||
Button mSkipSetup;
|
View mSkipSetup;
|
||||||
|
|
||||||
public static final int REQUEST_CODE_CREATE_OR_IMPORT_KEY = 0x00007012;
|
public static final int REQUEST_CODE_CREATE_OR_IMPORT_KEY = 0x00007012;
|
||||||
|
|
||||||
@ -45,9 +44,9 @@ public class FirstTimeActivity extends ActionBarActivity {
|
|||||||
|
|
||||||
setContentView(R.layout.first_time_activity);
|
setContentView(R.layout.first_time_activity);
|
||||||
|
|
||||||
mCreateKey = (Button) findViewById(R.id.first_time_create_key);
|
mCreateKey = findViewById(R.id.first_time_create_key);
|
||||||
mImportKey = (Button) findViewById(R.id.first_time_import_key);
|
mImportKey = findViewById(R.id.first_time_import_key);
|
||||||
mSkipSetup = (Button) findViewById(R.id.first_time_cancel);
|
mSkipSetup = findViewById(R.id.first_time_cancel);
|
||||||
|
|
||||||
mSkipSetup.setOnClickListener(new View.OnClickListener() {
|
mSkipSetup.setOnClickListener(new View.OnClickListener() {
|
||||||
@Override
|
@Override
|
||||||
|
@ -2,50 +2,86 @@
|
|||||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:paddingTop="16dp"
|
android:paddingTop="16dp">
|
||||||
android:paddingBottom="8dp">
|
|
||||||
|
|
||||||
<Button
|
|
||||||
android:id="@+id/first_time_cancel"
|
|
||||||
android:layout_alignParentBottom="true"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginBottom="8dp"
|
|
||||||
android:layout_marginLeft="8dp"
|
|
||||||
android:layout_marginRight="8dp"
|
|
||||||
android:text="@string/first_time_skip"
|
|
||||||
android:background="@drawable/button_edgy" />
|
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:id="@+id/first_time_buttons"
|
android:id="@+id/first_time_buttons"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_above="@id/first_time_cancel"
|
android:paddingLeft="16dp"
|
||||||
android:orientation="horizontal">
|
android:paddingRight="16dp"
|
||||||
|
android:layout_alignParentBottom="true"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
<Button
|
<View
|
||||||
android:id="@+id/first_time_create_key"
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="1dip"
|
||||||
|
android:background="?android:attr/listDivider" />
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_gravity="center_horizontal"
|
android:orientation="horizontal">
|
||||||
android:layout_weight="1"
|
|
||||||
android:layout_marginLeft="8dp"
|
|
||||||
android:layout_marginRight="4dp"
|
|
||||||
android:text="@string/first_time_create_key"
|
|
||||||
android:background="@drawable/button_edgy"
|
|
||||||
android:drawableLeft="@drawable/ic_action_new_account" />
|
|
||||||
|
|
||||||
<Button
|
<TextView
|
||||||
android:id="@+id/first_time_import_key"
|
android:id="@+id/first_time_create_key"
|
||||||
|
android:paddingLeft="8dp"
|
||||||
|
android:paddingRight="8dp"
|
||||||
|
android:textAppearance="?android:attr/textAppearanceMedium"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:text="@string/first_time_create_key"
|
||||||
|
android:minHeight="?android:attr/listPreferredItemHeight"
|
||||||
|
android:drawableRight="@drawable/ic_action_new_account"
|
||||||
|
android:drawablePadding="8dp"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:clickable="true"
|
||||||
|
style="@style/SelectableItem" />
|
||||||
|
|
||||||
|
<View
|
||||||
|
android:layout_width="1dp"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_marginTop="8dp"
|
||||||
|
android:layout_marginBottom="8dp"
|
||||||
|
android:background="?android:attr/listDivider" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/first_time_import_key"
|
||||||
|
android:paddingLeft="8dp"
|
||||||
|
android:paddingRight="8dp"
|
||||||
|
android:textAppearance="?android:attr/textAppearanceMedium"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:text="@string/first_time_import_key"
|
||||||
|
android:minHeight="?android:attr/listPreferredItemHeight"
|
||||||
|
android:drawableRight="@drawable/ic_action_download"
|
||||||
|
android:drawablePadding="8dp"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:clickable="true"
|
||||||
|
style="@style/SelectableItem" />
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<View
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="1dip"
|
||||||
|
android:background="?android:attr/listDivider" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/first_time_cancel"
|
||||||
|
android:paddingLeft="8dp"
|
||||||
|
android:paddingRight="8dp"
|
||||||
|
android:textAppearance="?android:attr/textAppearanceMedium"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_weight="1"
|
android:text="@string/first_time_skip"
|
||||||
android:layout_gravity="center_horizontal"
|
android:minHeight="?android:attr/listPreferredItemHeight"
|
||||||
android:layout_marginLeft="4dp"
|
android:gravity="center"
|
||||||
android:layout_marginRight="8dp"
|
android:clickable="true"
|
||||||
android:text="@string/first_time_import_key"
|
style="@style/SelectableItem"
|
||||||
android:background="@drawable/button_edgy"
|
android:layout_gravity="center_horizontal" />
|
||||||
android:drawableLeft="@drawable/ic_action_download" />
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
|
Loading…
Reference in New Issue
Block a user