diff options
author | Vincent Breitmoser <valodim@mugenguild.com> | 2014-04-06 01:57:28 +0200 |
---|---|---|
committer | Vincent Breitmoser <valodim@mugenguild.com> | 2014-04-06 01:57:28 +0200 |
commit | 120e1eada729c34bf138138b7df4e6827acb6535 (patch) | |
tree | fe90d5d15955e1e46e42b94b17190325dedfbe44 /OpenPGP-Keychain/src/main | |
parent | 84857df703c2ffe941bc803669f8fd8d04270869 (diff) | |
download | open-keychain-120e1eada729c34bf138138b7df4e6827acb6535.tar.gz open-keychain-120e1eada729c34bf138138b7df4e6827acb6535.tar.bz2 open-keychain-120e1eada729c34bf138138b7df4e6827acb6535.zip |
certs: ditch selection spinner from certs view
Diffstat (limited to 'OpenPGP-Keychain/src/main')
-rw-r--r-- | OpenPGP-Keychain/src/main/java/org/sufficientlysecure/keychain/ui/ViewKeyCertsFragment.java | 38 | ||||
-rw-r--r-- | OpenPGP-Keychain/src/main/res/layout/view_key_certs_fragment.xml | 13 |
2 files changed, 1 insertions, 50 deletions
diff --git a/OpenPGP-Keychain/src/main/java/org/sufficientlysecure/keychain/ui/ViewKeyCertsFragment.java b/OpenPGP-Keychain/src/main/java/org/sufficientlysecure/keychain/ui/ViewKeyCertsFragment.java index eb2efcfa7..325e9e179 100644 --- a/OpenPGP-Keychain/src/main/java/org/sufficientlysecure/keychain/ui/ViewKeyCertsFragment.java +++ b/OpenPGP-Keychain/src/main/java/org/sufficientlysecure/keychain/ui/ViewKeyCertsFragment.java @@ -71,8 +71,6 @@ public class ViewKeyCertsFragment extends Fragment public static final String ARG_DATA_URI = "data_uri"; private StickyListHeadersListView mStickyList; - private Spinner mSpinner; - private CertListAdapter mAdapter; private Uri mDataUri; @@ -84,46 +82,10 @@ public class ViewKeyCertsFragment extends Fragment return view; } - private void changeShowState(int type) { - switch(type) { - case 0: - mDataUri = mBaseUri.buildUpon().appendPath("has_secret").build(); - break; - case 1: - mDataUri = mBaseUri; - break; - case 2: - mDataUri = mBaseUri.buildUpon().appendPath("all").build(); - break; - } - getLoaderManager().restartLoader(0, null, this); - } - @Override public void onActivityCreated(Bundle savedInstanceState) { super.onActivityCreated(savedInstanceState); - mSpinner = (Spinner) getActivity().findViewById(R.id.spinner); - ArrayAdapter<String> adapter = new ArrayAdapter<String>(getActivity(), - android.R.layout.simple_spinner_item, new String[] { - getResources().getString(R.string.certs_list_known_secret), - getResources().getString(R.string.certs_list_known), - getResources().getString(R.string.certs_list_all) - } ); - adapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item); - mSpinner.setAdapter(adapter); - mSpinner.setSelection(1); - mSpinner.setOnItemSelectedListener(new AdapterView.OnItemSelectedListener() { - @Override - public void onItemSelected(AdapterView<?> adapterView, View view, int i, long l) { - changeShowState(i); - } - - @Override - public void onNothingSelected(AdapterView<?> adapterView) { - } - }); - mStickyList = (StickyListHeadersListView) getActivity().findViewById(R.id.list); if (!getArguments().containsKey(ARG_DATA_URI)) { diff --git a/OpenPGP-Keychain/src/main/res/layout/view_key_certs_fragment.xml b/OpenPGP-Keychain/src/main/res/layout/view_key_certs_fragment.xml index 032b9eee6..33042c541 100644 --- a/OpenPGP-Keychain/src/main/res/layout/view_key_certs_fragment.xml +++ b/OpenPGP-Keychain/src/main/res/layout/view_key_certs_fragment.xml @@ -1,5 +1,4 @@ <ScrollView 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="match_parent" android:fillViewport="true"> @@ -9,16 +8,6 @@ android:layout_height="wrap_content" android:orientation="vertical"> - <Spinner - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:id="@+id/spinner" - android:layout_gravity="center_horizontal" - android:gravity="center_horizontal" - android:layout_centerHorizontal="true" - android:layout_marginTop="2dp" - android:layout_marginBottom="2dp" /> - <view android:layout_width="match_parent" android:layout_height="match_parent" @@ -28,7 +17,7 @@ android:paddingLeft="16dp" android:layout_alignParentStart="false" android:layout_alignParentEnd="false" - android:layout_below="@+id/spinner" /> + android:layout_below="@+id/list" /> <TextView android:layout_width="wrap_content" |