summaryrefslogtreecommitdiff
path: root/src/de/blinkt/openvpn/OpenVpnPreferencesFragment.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/de/blinkt/openvpn/OpenVpnPreferencesFragment.java')
-rw-r--r--src/de/blinkt/openvpn/OpenVpnPreferencesFragment.java51
1 files changed, 0 insertions, 51 deletions
diff --git a/src/de/blinkt/openvpn/OpenVpnPreferencesFragment.java b/src/de/blinkt/openvpn/OpenVpnPreferencesFragment.java
deleted file mode 100644
index 4cf3b10b..00000000
--- a/src/de/blinkt/openvpn/OpenVpnPreferencesFragment.java
+++ /dev/null
@@ -1,51 +0,0 @@
-package de.blinkt.openvpn;
-
-import android.os.Bundle;
-import android.preference.PreferenceFragment;
-
-public abstract class OpenVpnPreferencesFragment extends PreferenceFragment {
-
- protected VpnProfile mProfile;
-
- protected abstract void loadSettings();
- protected abstract void saveSettings();
-
- @Override
- public void onCreate(Bundle savedInstanceState) {
- super.onCreate(savedInstanceState);
-
- String profileUUID = getArguments().getString(getActivity().getPackageName() + ".profileUUID");
- mProfile = ProfileManager.get(getActivity(),profileUUID);
- getActivity().setTitle(getString(R.string.edit_profile_title, mProfile.getName()));
-
- }
-
- @Override
- public void onPause() {
- super.onPause();
- saveSettings();
- }
-
- @Override
- public void onActivityCreated(Bundle savedInstanceState) {
- super.onActivityCreated(savedInstanceState);
- if(savedInstanceState!=null) {
- String profileUUID=savedInstanceState.getString(VpnProfile.EXTRA_PROFILEUUID);
- mProfile = ProfileManager.get(getActivity(),profileUUID);
- loadSettings();
- }
- }
-
- @Override
- public void onStop() {
- // TODO Auto-generated method stub
- super.onStop();
- }
-
- @Override
- public void onSaveInstanceState (Bundle outState) {
- super.onSaveInstanceState(outState);
- saveSettings();
- outState.putString(VpnProfile.EXTRA_PROFILEUUID, mProfile.getUUIDString());
- }
-}