diff options
-rw-r--r-- | AndroidManifest.xml | 8 | ||||
-rw-r--r-- | res/drawable-hdpi/ic_menu_add.png | bin | 0 -> 2194 bytes | |||
-rw-r--r-- | res/drawable-hdpi/ic_menu_login.png | bin | 0 -> 1656 bytes | |||
-rw-r--r-- | res/drawable-hdpi/ic_menu_settings_holo_light.png | bin | 0 -> 1227 bytes | |||
-rw-r--r-- | res/drawable-ldpi/ic_menu_add.png | bin | 0 -> 1580 bytes | |||
-rw-r--r-- | res/drawable-ldpi/ic_menu_login.png | bin | 0 -> 1512 bytes | |||
-rwxr-xr-x | res/drawable-mdpi/ic_menu_add.png | bin | 0 -> 1339 bytes | |||
-rw-r--r-- | res/drawable-mdpi/ic_menu_login.png | bin | 0 -> 1114 bytes | |||
-rw-r--r-- | res/drawable-mdpi/ic_menu_settings_holo_light.png | bin | 0 -> 866 bytes | |||
-rw-r--r-- | res/drawable-xhdpi/ic_menu_add.png | bin | 0 -> 3061 bytes | |||
-rw-r--r-- | res/drawable-xhdpi/ic_menu_login.png | bin | 0 -> 2178 bytes | |||
-rw-r--r-- | res/drawable-xhdpi/ic_menu_settings_holo_light.png | bin | 0 -> 1622 bytes | |||
-rw-r--r-- | res/layout/provider_list_fragment.xml | 9 | ||||
-rw-r--r-- | res/menu/client_dashboard.xml | 33 | ||||
-rw-r--r-- | res/menu/configuration_wizard_activity.xml | 7 | ||||
-rw-r--r-- | src/se/leap/bitmaskclient/ConfigurationWizard.java | 7 |
16 files changed, 46 insertions, 18 deletions
diff --git a/AndroidManifest.xml b/AndroidManifest.xml index 70e0211d..df0eba0f 100644 --- a/AndroidManifest.xml +++ b/AndroidManifest.xml @@ -40,6 +40,7 @@ <application android:allowBackup="true" android:icon="@drawable/icon" + android:logo="@drawable/icon" android:label="@string/app" > <activity android:name="se.leap.openvpn.AboutFragment" /> <activity @@ -142,7 +143,9 @@ <activity android:name="se.leap.bitmaskclient.Dashboard" - android:label="@string/title_activity_dashboard" > + android:label="@string/title_activity_dashboard" + android:uiOptions="splitActionBarWhenNarrow" > + <intent-filter android:label="@string/app_name"> <action android:name="android.intent.action.MAIN" /> @@ -151,7 +154,8 @@ </activity> <activity android:name="se.leap.bitmaskclient.ConfigurationWizard" - android:label="@string/title_activity_configuration_wizard" > + android:label="@string/title_activity_configuration_wizard" + android:uiOptions="splitActionBarWhenNarrow" > </activity> <service android:name="se.leap.bitmaskclient.EIP" android:exported="false"> diff --git a/res/drawable-hdpi/ic_menu_add.png b/res/drawable-hdpi/ic_menu_add.png Binary files differnew file mode 100644 index 00000000..444e8a5e --- /dev/null +++ b/res/drawable-hdpi/ic_menu_add.png diff --git a/res/drawable-hdpi/ic_menu_login.png b/res/drawable-hdpi/ic_menu_login.png Binary files differnew file mode 100644 index 00000000..afa152b2 --- /dev/null +++ b/res/drawable-hdpi/ic_menu_login.png diff --git a/res/drawable-hdpi/ic_menu_settings_holo_light.png b/res/drawable-hdpi/ic_menu_settings_holo_light.png Binary files differnew file mode 100644 index 00000000..577e0558 --- /dev/null +++ b/res/drawable-hdpi/ic_menu_settings_holo_light.png diff --git a/res/drawable-ldpi/ic_menu_add.png b/res/drawable-ldpi/ic_menu_add.png Binary files differnew file mode 100644 index 00000000..89620af8 --- /dev/null +++ b/res/drawable-ldpi/ic_menu_add.png diff --git a/res/drawable-ldpi/ic_menu_login.png b/res/drawable-ldpi/ic_menu_login.png Binary files differnew file mode 100644 index 00000000..d4181de5 --- /dev/null +++ b/res/drawable-ldpi/ic_menu_login.png diff --git a/res/drawable-mdpi/ic_menu_add.png b/res/drawable-mdpi/ic_menu_add.png Binary files differnew file mode 100755 index 00000000..361c7c46 --- /dev/null +++ b/res/drawable-mdpi/ic_menu_add.png diff --git a/res/drawable-mdpi/ic_menu_login.png b/res/drawable-mdpi/ic_menu_login.png Binary files differnew file mode 100644 index 00000000..122ba33b --- /dev/null +++ b/res/drawable-mdpi/ic_menu_login.png diff --git a/res/drawable-mdpi/ic_menu_settings_holo_light.png b/res/drawable-mdpi/ic_menu_settings_holo_light.png Binary files differnew file mode 100644 index 00000000..f32a37e4 --- /dev/null +++ b/res/drawable-mdpi/ic_menu_settings_holo_light.png diff --git a/res/drawable-xhdpi/ic_menu_add.png b/res/drawable-xhdpi/ic_menu_add.png Binary files differnew file mode 100644 index 00000000..7d498a96 --- /dev/null +++ b/res/drawable-xhdpi/ic_menu_add.png diff --git a/res/drawable-xhdpi/ic_menu_login.png b/res/drawable-xhdpi/ic_menu_login.png Binary files differnew file mode 100644 index 00000000..5095ed97 --- /dev/null +++ b/res/drawable-xhdpi/ic_menu_login.png diff --git a/res/drawable-xhdpi/ic_menu_settings_holo_light.png b/res/drawable-xhdpi/ic_menu_settings_holo_light.png Binary files differnew file mode 100644 index 00000000..aa33c388 --- /dev/null +++ b/res/drawable-xhdpi/ic_menu_settings_holo_light.png diff --git a/res/layout/provider_list_fragment.xml b/res/layout/provider_list_fragment.xml index 0db0734b..5a6770c8 100644 --- a/res/layout/provider_list_fragment.xml +++ b/res/layout/provider_list_fragment.xml @@ -8,15 +8,8 @@ <ListView
android:id="@id/android:list"
android:layout_width="match_parent"
- android:layout_height="match_parent"
+ android:layout_height="0dip"
android:layout_weight="1"
- android:layout_alignParentTop="true"
android:drawSelectorOnTop="false" />
- <Button
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:onClick="addAndSelectNewProvider"
- android:text="@string/new_provider_button" />
-
</LinearLayout>
diff --git a/res/menu/client_dashboard.xml b/res/menu/client_dashboard.xml index 55ad91b4..2ce8b87c 100644 --- a/res/menu/client_dashboard.xml +++ b/res/menu/client_dashboard.xml @@ -3,12 +3,33 @@ <item android:id="@+id/menu_settings" android:orderInCategory="100" - android:showAsAction="never" + android:showAsAction="ifRoom" + android:icon="@drawable/ic_menu_settings_holo_light" android:title="@string/menu_settings"/> - <item android:id="@+id/about_leap" android:title="@string/about" android:orderInCategory="110" /> - <item android:id="@+id/legacy_interface" android:title="ICS OpenVPN Interface" android:orderInCategory="500" /> - <item android:id="@+id/switch_provider" android:title="@string/switch_provider_menu_option" android:orderInCategory="501"/> - <item android:id="@+id/login_button" android:title="@string/login_button" android:visible="false"></item> - <item android:id="@+id/logout_button" android:title="@string/logout_button" android:visible="false"></item> + <item + android:id="@+id/about_leap" + android:orderInCategory="110" + android:title="@string/about"/> + <item + android:id="@+id/legacy_interface" + android:orderInCategory="500" + android:title="ICS OpenVPN Interface"/> + <item + android:id="@+id/switch_provider" + android:orderInCategory="501" + android:title="@string/switch_provider_menu_option"/> + <item + android:id="@+id/login_button" + android:showAsAction="ifRoom" + android:icon="@drawable/ic_menu_login" + android:title="@string/login_button" + android:visible="false"> + </item> + <item + android:id="@+id/logout_button" + android:showAsAction="ifRoom" + android:title="@string/logout_button" + android:visible="false"> + </item> </menu>
\ No newline at end of file diff --git a/res/menu/configuration_wizard_activity.xml b/res/menu/configuration_wizard_activity.xml index 9e441a18..9936b6dc 100644 --- a/res/menu/configuration_wizard_activity.xml +++ b/res/menu/configuration_wizard_activity.xml @@ -5,4 +5,11 @@ android:orderInCategory="110" android:title="@string/about"/> + <item + android:id="@+id/new_provider" + android:orderInCategory="210" + android:title="@string/new_provider_button" + android:showAsAction="ifRoom|withText" + android:icon="@drawable/ic_menu_add" + /> </menu>
\ No newline at end of file diff --git a/src/se/leap/bitmaskclient/ConfigurationWizard.java b/src/se/leap/bitmaskclient/ConfigurationWizard.java index bcb4fa9f..a0ac1bc2 100644 --- a/src/se/leap/bitmaskclient/ConfigurationWizard.java +++ b/src/se/leap/bitmaskclient/ConfigurationWizard.java @@ -301,9 +301,8 @@ implements ProviderListFragment.Callbacks, NewProviderDialog.NewProviderDialogIn /**
* Open the new provider dialog
- * @param view from which the dialog is showed
*/
- public void addAndSelectNewProvider(View view) {
+ public void addAndSelectNewProvider() {
FragmentTransaction fragment_transaction = getFragmentManager().beginTransaction();
Fragment previous_new_provider_dialog = getFragmentManager().findFragmentByTag(NewProviderDialog.TAG);
if (previous_new_provider_dialog != null) {
@@ -380,6 +379,10 @@ implements ProviderListFragment.Callbacks, NewProviderDialog.NewProviderDialogIn switch (item.getItemId()){
case R.id.about_leap:
showAboutFragment(getCurrentFocus());
+ return true;
+ case R.id.new_provider:
+ addAndSelectNewProvider();
+ return true;
default:
return super.onOptionsItemSelected(item);
}
|