summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--main/src/main/AndroidManifest.xml5
-rw-r--r--main/src/main/java/de/blinkt/openvpn/OnBootReceiver.java2
-rw-r--r--main/src/main/java/de/blinkt/openvpn/fragments/ConnectionsAdapter.java4
-rw-r--r--main/src/main/res/layout-v21/connection_fab.xml5
-rw-r--r--main/src/main/res/layout-v21/profile_list_fabs.xml8
-rw-r--r--main/src/main/res/values/dimens.xml2
6 files changed, 14 insertions, 12 deletions
diff --git a/main/src/main/AndroidManifest.xml b/main/src/main/AndroidManifest.xml
index e226bdfc..dbc9c243 100644
--- a/main/src/main/AndroidManifest.xml
+++ b/main/src/main/AndroidManifest.xml
@@ -59,6 +59,7 @@
</intent-filter>
</service>
<service
+ tools:ignore="ExportedService"
android:name=".api.ExternalOpenVPNService">
<intent-filter>
<action android:name="de.blinkt.openvpn.api.IOpenVPNAPIService" />
@@ -82,6 +83,8 @@
<intent-filter
android:priority="999">
<action android:name="android.intent.action.BOOT_COMPLETED" />
+ <action android:name="android.intent.action.MY_PACKAGE_REPLACED" />
+
</intent-filter>
</receiver>
@@ -108,7 +111,7 @@
</intent-filter>
<intent-filter android:label="@string/import_config" >
- <!-- http://stackoverflow.com/questions/7030832/associating-certain-file-extension-to-my-android-application/7102838#7102838 -->
+ <!-- http://stackoverflow.com/questions/7f030832/associating-certain-file-extension-to-my-android-application/7102838#7102838 -->
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.BROWSABLE" />
diff --git a/main/src/main/java/de/blinkt/openvpn/OnBootReceiver.java b/main/src/main/java/de/blinkt/openvpn/OnBootReceiver.java
index bc8385a2..bc73bb26 100644
--- a/main/src/main/java/de/blinkt/openvpn/OnBootReceiver.java
+++ b/main/src/main/java/de/blinkt/openvpn/OnBootReceiver.java
@@ -19,7 +19,7 @@ public class OnBootReceiver extends BroadcastReceiver {
final String action = intent.getAction();
- if(Intent.ACTION_BOOT_COMPLETED.equals(action)) {
+ if(Intent.ACTION_BOOT_COMPLETED.equals(action) || Intent.ACTION_MY_PACKAGE_REPLACED.equals(action)) {
VpnProfile bootProfile = ProfileManager.getLastConnectedProfile(context, true);
if(bootProfile != null) {
launchVPN(bootProfile, context);
diff --git a/main/src/main/java/de/blinkt/openvpn/fragments/ConnectionsAdapter.java b/main/src/main/java/de/blinkt/openvpn/fragments/ConnectionsAdapter.java
index 6d11c7d7..4474c669 100644
--- a/main/src/main/java/de/blinkt/openvpn/fragments/ConnectionsAdapter.java
+++ b/main/src/main/java/de/blinkt/openvpn/fragments/ConnectionsAdapter.java
@@ -14,14 +14,12 @@ import android.text.TextWatcher;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
-import android.widget.Button;
import android.widget.CheckBox;
import android.widget.CompoundButton;
import android.widget.EditText;
import android.widget.ImageButton;
import android.widget.RadioGroup;
import android.widget.Switch;
-import android.widget.TextView;
import java.util.Arrays;
@@ -48,7 +46,6 @@ public class ConnectionsAdapter extends RecyclerView.Adapter<ConnectionsAdapter.
public static class ConnectionsHolder extends RecyclerView.ViewHolder {
private final EditText mServerNameView;
- private final TextView mServerPortNumber;
private final EditText mPortNumberView;
private final Switch mRemoteSwitch;
private final RadioGroup mProtoGroup;
@@ -59,7 +56,6 @@ public class ConnectionsAdapter extends RecyclerView.Adapter<ConnectionsAdapter.
public ConnectionsHolder(View card) {
super(card);
- mServerPortNumber = ((TextView)card.findViewById(R.id.portnumber));
mServerNameView = (EditText) card.findViewById(R.id.servername);
mPortNumberView = (EditText) card.findViewById(R.id.portnumber);
mRemoteSwitch = (Switch) card.findViewById (R.id.remoteSwitch);
diff --git a/main/src/main/res/layout-v21/connection_fab.xml b/main/src/main/res/layout-v21/connection_fab.xml
index 571a2a17..0392539a 100644
--- a/main/src/main/res/layout-v21/connection_fab.xml
+++ b/main/src/main/res/layout-v21/connection_fab.xml
@@ -7,14 +7,15 @@
-->
<ImageButton xmlns:android="http://schemas.android.com/apk/res/android"
+ tools:ignore="InconsistentLayout"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/add_new_remote"
android:layout_width="@dimen/round_button_diameter"
android:layout_height="@dimen/round_button_diameter"
android:layout_alignParentBottom="true"
- android:layout_alignParentRight="true"
+ android:layout_alignParentEnd="true"
android:layout_marginBottom="16dp"
- android:layout_marginRight="16dp"
+ android:layout_marginEnd="16dp"
android:background="@drawable/oval_ripple"
android:elevation="1dp"
android:src="@android:drawable/ic_input_add"
diff --git a/main/src/main/res/layout-v21/profile_list_fabs.xml b/main/src/main/res/layout-v21/profile_list_fabs.xml
index 11c68348..121225ae 100644
--- a/main/src/main/res/layout-v21/profile_list_fabs.xml
+++ b/main/src/main/res/layout-v21/profile_list_fabs.xml
@@ -4,7 +4,9 @@
~ Distributed under the GNU GPL v2. For full terms see the file doc/LICENSE.txt
-->
-<merge xmlns:android="http://schemas.android.com/apk/res/android">
+<merge xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:tools="http://schemas.android.com/tools"
+ tools:ignore="InconsistentLayout">
<ImageButton
android:id="@+id/add_button"
@@ -16,9 +18,11 @@
android:elevation="@dimen/elevation_low"
android:layout_marginBottom="@dimen/add_button_margin_topfab"
android:layout_marginEnd="@dimen/add_button_margin"
- android:src="@drawable/ic_archive_grey600_24dp" />
+ android:src="@drawable/ic_archive_grey600_24dp"
+ android:contentDescription="@string/import_config" />
<ImageButton
+ android:contentDescription="@string/add_profile"
android:id="@+id/import_button"
android:layout_width="@dimen/round_button_diameter"
android:layout_height="@dimen/round_button_diameter"
diff --git a/main/src/main/res/values/dimens.xml b/main/src/main/res/values/dimens.xml
index e688289d..727f5a78 100644
--- a/main/src/main/res/values/dimens.xml
+++ b/main/src/main/res/values/dimens.xml
@@ -17,6 +17,4 @@
<dimen name="round_button_diameter">56dp</dimen>
<dimen name="switchbar_pad">16dp</dimen>
<dimen name="vpn_setting_padding">16dp</dimen>
- <integer name="num_columns">1</integer>
-
</resources> \ No newline at end of file