Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
Akuma
bitmask_android
Commits
f510feb3
Commit
f510feb3
authored
Aug 09, 2019
by
akuma
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Commented allow apps switch. Allow app fragment title
parent
302f4108
Pipeline
#26241
failed with stages
Changes
5
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
26 additions
and
24 deletions
+26
-24
app/src/main/java/se/leap/bitmaskclient/drawer/NavigationDrawerFragment.java
...e/leap/bitmaskclient/drawer/NavigationDrawerFragment.java
+4
-3
app/src/main/java/se/leap/bitmaskclient/fragments/Settings_Allowed_Apps.java
...e/leap/bitmaskclient/fragments/Settings_Allowed_Apps.java
+13
-13
app/src/main/res/layout/allowed_vpn_apps.xml
app/src/main/res/layout/allowed_vpn_apps.xml
+2
-2
app/src/main/res/values/strings.xml
app/src/main/res/values/strings.xml
+1
-0
app/src/main/res/values/untranslatable.xml
app/src/main/res/values/untranslatable.xml
+6
-6
No files found.
app/src/main/java/se/leap/bitmaskclient/drawer/NavigationDrawerFragment.java
View file @
f510feb3
...
...
@@ -59,7 +59,6 @@ import se.leap.bitmaskclient.R;
import
se.leap.bitmaskclient.fragments.AboutFragment
;
import
se.leap.bitmaskclient.fragments.AlwaysOnDialog
;
import
se.leap.bitmaskclient.fragments.LogFragment
;
import
se.leap.bitmaskclient.fragments.SelectAppsFragment
;
import
se.leap.bitmaskclient.fragments.Settings_Allowed_Apps
;
import
static
android
.
content
.
Context
.
MODE_PRIVATE
;
...
...
@@ -79,9 +78,11 @@ import static se.leap.bitmaskclient.DrawerSettingsAdapter.LOG;
import
static
se
.
leap
.
bitmaskclient
.
DrawerSettingsAdapter
.
SELECT_APPS
;
import
static
se
.
leap
.
bitmaskclient
.
DrawerSettingsAdapter
.
SWITCH_PROVIDER
;
import
static
se
.
leap
.
bitmaskclient
.
R
.
string
.
about_fragment_title
;
import
static
se
.
leap
.
bitmaskclient
.
R
.
string
.
allow_apps_fragment_title
;
import
static
se
.
leap
.
bitmaskclient
.
R
.
string
.
donate_title
;
import
static
se
.
leap
.
bitmaskclient
.
R
.
string
.
log_fragment_title
;
import
static
se
.
leap
.
bitmaskclient
.
R
.
string
.
switch_provider_menu_option
;
import
static
se
.
leap
.
bitmaskclient
.
R
.
string
.
allow_apps_fragment_title
;
import
static
se
.
leap
.
bitmaskclient
.
utils
.
ConfigHelper
.
isDefaultBitmask
;
import
static
se
.
leap
.
bitmaskclient
.
utils
.
PreferenceHelper
.
getProviderName
;
import
static
se
.
leap
.
bitmaskclient
.
utils
.
PreferenceHelper
.
getSaveBattery
;
...
...
@@ -276,7 +277,7 @@ public class NavigationDrawerFragment extends Fragment {
settingsListAdapter
.
addItem
(
getSimpleTextInstance
(
getContext
(),
getString
(
donate_title
),
R
.
drawable
.
ic_donate_36
,
DONATE
));
}
settingsListAdapter
.
addItem
(
getSimpleTextInstance
(
getContext
(),
getString
(
about_fragment_title
),
R
.
drawable
.
ic_about_36
,
ABOUT
));
settingsListAdapter
.
addItem
(
getSimpleTextInstance
(
getContext
(),
getString
(
a
bout
_fragment_title
),
R
.
drawable
.
ic_about_36
,
SELECT_APPS
));
settingsListAdapter
.
addItem
(
getSimpleTextInstance
(
getContext
(),
getString
(
a
llow_apps
_fragment_title
),
R
.
drawable
.
ic_about_36
,
SELECT_APPS
));
}
private
ActionBar
setupActionBar
()
{
...
...
@@ -500,7 +501,7 @@ public class NavigationDrawerFragment extends Fragment {
break
;
case
SELECT_APPS:
fragment
=
new
Settings_Allowed_Apps
();
setActionBarTitle
(
a
bout
_fragment_title
);
setActionBarTitle
(
a
llow_apps
_fragment_title
);
break
;
default
:
break
;
...
...
app/src/main/java/se/leap/bitmaskclient/fragments/Settings_Allowed_Apps.java
View file @
f510feb3
...
...
@@ -39,8 +39,7 @@ import java.util.Set;
import
java.util.Vector
;
import
de.blinkt.openvpn.VpnProfile
;
import
se.leap.bitmaskclient.EipSetupListener
;
import
se.leap.bitmaskclient.EipSetupObserver
;
import
se.leap.bitmaskclient.R
;
/**
...
...
@@ -274,7 +273,7 @@ public class Settings_Allowed_Apps extends Fragment implements AdapterView.OnIte
allow_apps
=
this
.
getContext
().
getSharedPreferences
(
"BITMASK"
,
Context
.
MODE_MULTI_PROCESS
);
allow_apps_editor
=
allow_apps
.
edit
();
apps
=
new
HashSet
<
String
>(
allow_apps
.
getStringSet
(
"ALLOW_APPS"
,
new
HashSet
<
String
>())
)
;
apps
=
allow_apps
.
getStringSet
(
"ALLOW_APPS"
,
new
HashSet
<
String
>());
// /String profileUuid = getArguments().getString(getActivity().getPackageName() + ".profileUUID");
// mProfile = EipSetupObserver.getProfile();
...
...
@@ -322,18 +321,19 @@ public class Settings_Allowed_Apps extends Fragment implements AdapterView.OnIte
public
View
onCreateView
(
LayoutInflater
inflater
,
ViewGroup
container
,
Bundle
savedInstanceState
)
{
View
v
=
inflater
.
inflate
(
R
.
layout
.
allowed_vpn_apps
,
container
,
false
);
mDefaultAllowTextView
=
(
TextView
)
v
.
findViewById
(
R
.
id
.
default_allow_text
);
Switch
vpnOnDefaultSwitch
=
(
Switch
)
v
.
findViewById
(
R
.
id
.
default_allow
);
// mDefaultAllowTextView = (TextView) v.findViewById(R.id.default_allow_text);
vpnOnDefaultSwitch
.
setOnCheckedChangeListener
(
new
CompoundButton
.
OnCheckedChangeListener
()
{
@Override
public
void
onCheckedChanged
(
CompoundButton
buttonView
,
boolean
isChecked
)
{
changeDisallowText
(
isChecked
);
mProfile
.
mAllowedAppsVpnAreDisallowed
=
isChecked
;
}
});
// Switch vpnOnDefaultSwitch = (Switch) v.findViewById(R.id.default_allow);
//
// vpnOnDefaultSwitch.setOnCheckedChangeListener(new CompoundButton.OnCheckedChangeListener() {
// @Override
// public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
//
// changeDisallowText(isChecked);
// mProfile.mAllowedAppsVpnAreDisallowed = isChecked;
// }
// });
// vpnOnDefaultSwitch.setChecked(mProfile.mAllowedAppsVpnAreDisallowed);
...
...
app/src/main/res/layout/allowed_vpn_apps.xml
View file @
f510feb3
...
...
@@ -9,7 +9,7 @@
android:layout_width=
"match_parent"
tools:ignore=
"RtlCompat"
android:layout_height=
"match_parent"
>
<!--
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
...
...
@@ -35,7 +35,7 @@
android:layout_width="wrap_content"
android:layout_centerVertical="true"
android:layout_height="wrap_content" />
</RelativeLayout>
</RelativeLayout>
-->
<ListView
android:visibility=
"gone"
...
...
app/src/main/res/values/strings.xml
View file @
f510feb3
...
...
@@ -32,6 +32,7 @@
<string
name=
"password_mismatch"
>
Passwords do not match
</string>
<string
name=
"user_message"
>
User message
</string>
<string
name=
"about_fragment_title"
>
About
</string>
<string
name=
"allow_apps_fragment_title"
>
Select Apps
</string>
<string
name=
"error_srp_math_error_user_message"
>
Try again: Server math error
</string>
<string
name=
"error_bad_user_password_user_message"
>
Incorrect username or password
</string>
<string
name=
"error_not_valid_password_user_message"
>
It must be at least 8 characters long
</string>
...
...
app/src/main/res/values/untranslatable.xml
View file @
f510feb3
...
...
@@ -2,13 +2,13 @@
<resources>
<string
name=
"notifcation_title_bitmask"
translatable=
"false"
>
%s - %s
</string>
<string
name=
"copyright_leapgui"
translatable=
"false"
>
Copyright 2012-2019\nLEAP Encryption Access Project
<
info@leap.se>
</string>
<string
name=
"opevpn_copyright"
translatable=
"false"
>
Copyright
©
2002
–
2019 OpenVPN Technologies, Inc.
<
sales@openvpn.net>\n
<string
name=
"opevpn_copyright"
translatable=
"false"
>
Copyright
?
2002
?
2019 OpenVPN Technologies, Inc.
<
sales@openvpn.net>\n
"OpenVPN" is a trademark of OpenVPN Technologies, Inc.
</string>
<string
name=
"lzo_copyright"
translatable=
"false"
>
Copyright
©
1996
–
2011 Markus Franz Xaver Johannes Oberhumer
</string>
<string
name=
"lzo_copyright"
translatable=
"false"
>
Copyright
?
1996
?
2011 Markus Franz Xaver Johannes Oberhumer
</string>
<string
name=
"copyright_openssl"
translatable=
"false"
>
Copyright 1995-2018 The OpenSSL Project Authors. All Rights Reserved.\n\n
This product includes cryptographic software written by Eric Young (eay@cryptsoft.com)\n
Copyright
©
1995-1998 Eric Young (eay@cryptsoft.com) All rights reserved.
</string>
<string
name=
"copyright_okhttp"
translatable=
"false"
>
Copyright
©
2019 Square, Inc.
</string>
Copyright
?
1995-1998 Eric Young (eay@cryptsoft.com) All rights reserved.
</string>
<string
name=
"copyright_okhttp"
translatable=
"false"
>
Copyright
?
2019 Square, Inc.
</string>
<string
name=
"okhttp"
translatable=
"false"
>
OkHttp
</string>
<string
name=
"openvpn"
translatable=
"false"
>
OpenVPN
</string>
<string
name=
"lzo"
translatable=
"false"
>
LZO
</string>
...
...
@@ -23,14 +23,14 @@
<string
name=
"copyright_openvpn3"
translatable=
"false"
>
GNU AFFERO GENERAL PUBLIC LICENSE\n
Version 3, 19 November 2007
</string>
<string
name=
"unknown_state"
translatable=
"false"
>
Unknown state
</string>
<string
name=
"copyright_blinktgui"
translatable=
"false"
>
Copyright 2012
–
2019 Arne Schwabe
<
arne@rfc2549.org>
</string>
<string
name=
"copyright_blinktgui"
translatable=
"false"
>
Copyright 2012
?
2019 Arne Schwabe
<
arne@rfc2549.org>
</string>
<string
name=
"defaultserver"
translatable=
"false"
>
openvpn.uni-paderborn.de
</string>
<string
name=
"defaultport"
translatable=
"false"
>
1194
</string>
<string
name=
"copyright_file_dialog"
translatable=
"false"
>
File Dialog based on work by Alexander Ponomarev
</string>
<string
name=
"file_dialog"
translatable=
"false"
>
File Dialog
</string>
<string
name=
"permission_description"
translatable=
"false"
>
Allows another app to control OpenVPN
</string>
<string
name=
"bouncy_castle"
translatable=
"false"
>
Bouncy Castle Crypto APIs
</string>
<string
name=
"copyright_bouncycastle"
translatable=
"false"
>
Copyright
©
2000
–
2012 The Legion Of The Bouncy Castle (http://www.bouncycastle.org)
</string>
<string
name=
"copyright_bouncycastle"
translatable=
"false"
>
Copyright
?
2000
?
2012 The Legion Of The Bouncy Castle (http://www.bouncycastle.org)
</string>
<string
name=
"state_user_vpn_permission"
translatable=
"false"
>
Waiting for user permission to use VPN API
</string>
<string
name=
"state_user_vpn_password"
translatable=
"false"
>
Waiting for user VPN password
</string>
<string
name=
"state_user_vpn_password_cancelled"
translatable=
"false"
>
VPN password input dialog cancelled
</string>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment