diff options
Diffstat (limited to 'main/src/ui')
-rw-r--r-- | main/src/ui/java/de/blinkt/openvpn/views/SeekBarTicks.java | 7 | ||||
-rw-r--r-- | main/src/ui/res/menu/configmenu.xml | 5 | ||||
-rw-r--r-- | main/src/ui/res/menu/connections.xml | 5 | ||||
-rw-r--r-- | main/src/ui/res/menu/import_menu.xml | 7 | ||||
-rw-r--r-- | main/src/ui/res/menu/logmenu.xml | 13 | ||||
-rw-r--r-- | main/src/ui/res/menu/main_menu.xml | 5 | ||||
-rw-r--r-- | main/src/ui/res/menu/vpnpreferences_menu.xml | 7 | ||||
-rw-r--r-- | main/src/ui/res/values/refs.xml | 27 | ||||
-rw-r--r-- | main/src/ui/res/values/styles.xml | 98 |
9 files changed, 152 insertions, 22 deletions
diff --git a/main/src/ui/java/de/blinkt/openvpn/views/SeekBarTicks.java b/main/src/ui/java/de/blinkt/openvpn/views/SeekBarTicks.java index 347ce708..cdc683c0 100644 --- a/main/src/ui/java/de/blinkt/openvpn/views/SeekBarTicks.java +++ b/main/src/ui/java/de/blinkt/openvpn/views/SeekBarTicks.java @@ -9,13 +9,12 @@ import android.content.Context; import android.content.res.TypedArray; import android.graphics.Canvas; import android.graphics.Paint; -import android.graphics.drawable.Drawable; import android.util.AttributeSet; -import android.util.TypedValue; -import android.view.ViewConfiguration; import android.widget.SeekBar; -public class SeekBarTicks extends SeekBar { +import androidx.appcompat.widget.AppCompatSeekBar; + +public class SeekBarTicks extends AppCompatSeekBar { private Paint mTickPaint; private float mTickHeight; diff --git a/main/src/ui/res/menu/configmenu.xml b/main/src/ui/res/menu/configmenu.xml index 96515c24..8c2442e6 100644 --- a/main/src/ui/res/menu/configmenu.xml +++ b/main/src/ui/res/menu/configmenu.xml @@ -4,12 +4,13 @@ ~ Distributed under the GNU GPL v2 with additional terms. For full terms see the file doc/LICENSE.txt --> -<menu xmlns:android="http://schemas.android.com/apk/res/android" > +<menu xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:app="http://schemas.android.com/apk/res-auto"> <item android:id="@+id/sendConfig" android:icon="@drawable/ic_menu_share" - android:showAsAction="ifRoom" + app:showAsAction="ifRoom" android:title="@string/send_config" android:titleCondensed="@string/send"/> diff --git a/main/src/ui/res/menu/connections.xml b/main/src/ui/res/menu/connections.xml index 64ca4a2c..631e01a8 100644 --- a/main/src/ui/res/menu/connections.xml +++ b/main/src/ui/res/menu/connections.xml @@ -4,12 +4,13 @@ ~ Distributed under the GNU GPL v2 with additional terms. For full terms see the file doc/LICENSE.txt --> -<menu xmlns:android="http://schemas.android.com/apk/res/android"> +<menu xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:app="http://schemas.android.com/apk/res-auto"> <item android:icon="@drawable/ic_menu_add" android:title="@string/add_remote" android:id="@+id/add_new_remote" android:titleCondensed="@string/add" - android:showAsAction="always" + app:showAsAction="always" /> </menu>
\ No newline at end of file diff --git a/main/src/ui/res/menu/import_menu.xml b/main/src/ui/res/menu/import_menu.xml index 52c96516..f1be023b 100644 --- a/main/src/ui/res/menu/import_menu.xml +++ b/main/src/ui/res/menu/import_menu.xml @@ -4,18 +4,19 @@ ~ Distributed under the GNU GPL v2 with additional terms. For full terms see the file doc/LICENSE.txt --> -<menu xmlns:android="http://schemas.android.com/apk/res/android" > +<menu xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:app="http://schemas.android.com/apk/res-auto"> <item android:id="@+id/cancel" android:icon="@drawable/ic_menu_close_clear_cancel" - android:showAsAction="ifRoom" + app:showAsAction="ifRoom" android:title="@android:string/cancel" android:titleCondensed="@string/cancel"/> <item android:id="@+id/ok" android:icon="@drawable/ic_menu_save" - android:showAsAction="ifRoom" + app:showAsAction="ifRoom" android:title="@string/add_profile" android:titleCondensed="@string/import_vpn"/> diff --git a/main/src/ui/res/menu/logmenu.xml b/main/src/ui/res/menu/logmenu.xml index cb9a86f0..d0cb588f 100644 --- a/main/src/ui/res/menu/logmenu.xml +++ b/main/src/ui/res/menu/logmenu.xml @@ -4,39 +4,40 @@ ~ Distributed under the GNU GPL v2 with additional terms. For full terms see the file doc/LICENSE.txt --> -<menu xmlns:android="http://schemas.android.com/apk/res/android"> +<menu xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:app="http://schemas.android.com/apk/res-auto"> <item android:id="@+id/toggle_time" android:alphabeticShortcut="t" android:icon="@drawable/ic_menu_view" - android:showAsAction="ifRoom" + app:showAsAction="ifRoom" android:title="@string/logview_options" /> <item android:id="@+id/clearlog" android:icon="@drawable/ic_menu_delete" - android:showAsAction="ifRoom" + app:showAsAction="ifRoom" android:title="@string/clear_log" android:titleCondensed="@string/clear"/> <item android:id="@+id/send" android:icon="@drawable/ic_menu_share" - android:showAsAction="ifRoom" + app:showAsAction="ifRoom" android:title="@string/send_logfile" android:titleCondensed="@string/send"/> <item android:id="@+id/cancel" android:icon="@drawable/ic_menu_close_clear_cancel" - android:showAsAction="ifRoom" + app:showAsAction="ifRoom" android:title="@string/cancel_connection_long" android:titleCondensed="@string/cancel_connection"/> <item android:id="@+id/edit_vpn" android:alphabeticShortcut="e" android:icon="@drawable/ic_menu_edit" - android:showAsAction="ifRoom" + app:showAsAction="ifRoom" android:title="@string/edit_vpn"/> </menu>
\ No newline at end of file diff --git a/main/src/ui/res/menu/main_menu.xml b/main/src/ui/res/menu/main_menu.xml index f5e0bf08..e2e22eb4 100644 --- a/main/src/ui/res/menu/main_menu.xml +++ b/main/src/ui/res/menu/main_menu.xml @@ -4,11 +4,12 @@ ~ Distributed under the GNU GPL v2 with additional terms. For full terms see the file doc/LICENSE.txt --> -<menu xmlns:android="http://schemas.android.com/apk/res/android"> +<menu xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:app="http://schemas.android.com/apk/res-auto"> <item android:id="@+id/show_log" android:icon="@drawable/ic_receipt" - android:showAsAction="ifRoom" + app:showAsAction="ifRoom" android:title="@string/show_log_window" android:titleCondensed="@string/show_log"/> </menu>
\ No newline at end of file diff --git a/main/src/ui/res/menu/vpnpreferences_menu.xml b/main/src/ui/res/menu/vpnpreferences_menu.xml index e31d6ddf..bbeb3096 100644 --- a/main/src/ui/res/menu/vpnpreferences_menu.xml +++ b/main/src/ui/res/menu/vpnpreferences_menu.xml @@ -4,19 +4,20 @@ ~ Distributed under the GNU GPL v2 with additional terms. For full terms see the file doc/LICENSE.txt --> -<menu xmlns:android="http://schemas.android.com/apk/res/android" > +<menu xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:app="http://schemas.android.com/apk/res-auto"> <item android:id="@+id/remove_vpn" android:alphabeticShortcut="d" android:icon="@drawable/ic_menu_delete" - android:showAsAction="ifRoom" + app:showAsAction="ifRoom" android:title="@string/remove_vpn"/> <item android:id="@+id/duplicate_vpn" android:alphabeticShortcut="c" android:icon="@drawable/ic_menu_copy" - android:showAsAction="ifRoom" + app:showAsAction="ifRoom" android:title="Duplicate VPN" /> </menu>
\ No newline at end of file diff --git a/main/src/ui/res/values/refs.xml b/main/src/ui/res/values/refs.xml new file mode 100644 index 00000000..5d2ea134 --- /dev/null +++ b/main/src/ui/res/values/refs.xml @@ -0,0 +1,27 @@ +<?xml version="1.0" encoding="utf-8"?><!-- + ~ Copyright (c) 2012-2016 Arne Schwabe + ~ Distributed under the GNU GPL v2 with additional terms. For full terms see the file doc/LICENSE.txt + --> + +<resources> + <drawable name="ic_menu_close_clear_cancel">@drawable/ic_close_white_24dp</drawable> + <drawable name="ic_menu_play">@drawable/ic_play_arrow_white_24dp</drawable> + <drawable name="ic_menu_pause">@drawable/ic_pause_white_24dp</drawable> + <drawable name="ic_menu_share">@drawable/ic_share_white_24dp</drawable> + <drawable name="ic_menu_save">@drawable/ic_check_white_24dp</drawable> + <drawable name="ic_menu_view">@drawable/ic_filter_list_white_24dp</drawable> + <drawable name="ic_menu_delete">@drawable/ic_delete_white_24dp</drawable> + <drawable name="ic_menu_copy">@drawable/ic_content_copy_white_24dp</drawable> + <drawable name="ic_menu_delete_grey">@drawable/ic_delete_grey600_24dp</drawable> + + <drawable name="ic_menu_edit">@drawable/ic_edit_white_24dp</drawable> + <drawable name="ic_menu_import">@drawable/ic_archive_white_24dp</drawable> + <drawable name="vpn_item_edit">@drawable/ic_edit_grey600_24dp</drawable> + <drawable name="ic_menu_add">@drawable/ic_add_circle_outline_white_24dp</drawable> + <drawable name="ic_dialog_alert">@drawable/ic_warning_black_36dp</drawable> + <drawable name="ic_menu_add_grey">@drawable/ic_add_circle_outline_grey600_24dp</drawable> + <drawable name="ic_menu_import_grey">@drawable/ic_archive_grey600_24dp</drawable> + <drawable name="ic_receipt">@drawable/ic_receipt_white_24dp</drawable> + <drawable name="ic_sort">@drawable/ic_sort_white_24dp</drawable> + +</resources>
\ No newline at end of file diff --git a/main/src/ui/res/values/styles.xml b/main/src/ui/res/values/styles.xml new file mode 100644 index 00000000..f90da367 --- /dev/null +++ b/main/src/ui/res/values/styles.xml @@ -0,0 +1,98 @@ +<?xml version="1.0" encoding="utf-8"?><!-- + ~ Copyright (c) 2012-2016 Arne Schwabe + ~ Distributed under the GNU GPL v2 with additional terms. For full terms see the file doc/LICENSE.txt + --> + +<resources> + + <style name="blinkt.baseTheme" parent="Theme.AppCompat.DayNight.DarkActionBar"> + <item name="colorPrimary">@color/primary</item> + <item name="colorPrimaryDark">@color/primary_dark</item> + <item name="colorAccent">@color/accent</item> + <item name="alertDialogTheme">@style/blinkt.alertDialog</item> + </style> + + <style name="blinkt.dialog" parent="Theme.AppCompat.DayNight.Dialog"> + <item name="colorPrimary">@color/primary</item> + <item name="colorPrimaryDark">@color/primary_dark</item> + <item name="colorAccent">@color/accent</item> + <item name="alertDialogTheme">@style/blinkt.alertDialog</item> + </style> + + <style name="blinkt.alertDialog" parent="Theme.AppCompat.DayNight.Dialog.Alert"> + <item name="colorPrimary">@color/primary</item> + <item name="colorPrimaryDark">@color/primary_dark</item> + <item name="colorAccent">@color/accent</item> + </style> + + + <style name="blinkt" parent="blinkt.baseTheme" /> + + + <style name="item"> + <item name="android:layout_width">match_parent</item> + <item name="android:layout_height">wrap_content</item> + <item name="android:textAppearance">?android:attr/textAppearanceMedium</item> + <item name="android:singleLine">true</item> + </style> + + <style name="faqitem"> + <item name="android:layout_width">match_parent</item> + <item name="android:layout_height">wrap_content</item> + <item name="android:textAppearance">?android:attr/textAppearanceSmall</item> + </style> + + <style name="faqhead"> + <item name="android:paddingTop">10sp</item> + <item name="android:layout_width">match_parent</item> + <item name="android:layout_height">wrap_content</item> + <item name="android:textAppearance">?android:attr/textAppearanceLarge</item> + <!-- <item name="android:singleLine">true</item> --> + </style> + + <style name="accountSetupButton"> + <item name="android:layout_width">160sp</item> + <item name="android:layout_height">40sp</item> + <item name="android:textColor">?android:attr/textColorPrimary</item> + <item name="android:textAppearance">?android:attr/textAppearanceSmall</item> + </style> + + <style name="Theme.CreateShortCut" parent="android:Theme.Holo.DialogWhenLarge" /> + + <style name="logWindowStatusText"> + <item name="android:paddingLeft">@dimen/paddingItemsSidebarLog</item> + <item name="android:layout_width">wrap_content</item> + <item name="android:layout_height">wrap_content</item> + <item name="android:textAppearance">?android:attr/textAppearanceLarge</item> + </style> + + <style name="logWindowStatusTitle"> + <item name="android:layout_width">wrap_content</item> + <item name="android:layout_height">wrap_content</item> + </style> + + + <style name="blinkt.translucent" parent="blinkt.dialog"> + <item name="android:windowNoTitle">true</item> + <item name="android:windowActionBar">false</item> + <item name="android:windowFullscreen">true</item> + <item name="android:windowContentOverlay">@null</item> + </style> + + <style name="AppTabLayout" parent="Widget.Design.TabLayout"> + <item name="tabIndicatorColor">?attr/colorAccent</item> + <item name="tabIndicatorHeight">4dp</item> + <item name="tabPaddingStart">2dp</item> + <item name="tabPaddingEnd">2dp</item> + + <item name="tabBackground">@color/primary</item> + <item name="tabTextAppearance">@style/AppTabTextAppearance</item> + <item name="tabSelectedTextColor">@android:color/white</item> + </style> + + <!-- for text --> + <style name="AppTabTextAppearance" parent="TextAppearance.Design.Tab"> + <item name="textAllCaps">true</item> + </style> + +</resources>
\ No newline at end of file |