diff --git a/res/values/config.xml b/res/values/config.xml
index c5cc341..3491922 100755
--- a/res/values/config.xml
+++ b/res/values/config.xml
@@ -46,5 +46,10 @@
     <string name="config_wallpaper_picker_class" translatable="false">com.android.settings.Settings$WallpaperSettingsActivity</string>
 
     <!-- Backup settings to launch -->
-    <string name="config_backup_settings_intent"></string>
+    <string name="config_backup_settings_intent" translatable="false"></string>
+
+    <!-- Double twist sensor name and vendor used by gesture setting -->
+    <string name="gesture_double_twist_sensor_name" translatable="false"></string>
+    <string name="gesture_double_twist_sensor_vendor" translatable="false"></string>
+
 </resources>
diff --git a/src/com/android/settings/gestures/GestureSettings.java b/src/com/android/settings/gestures/GestureSettings.java
index a24d810..2c065ac 100644
--- a/src/com/android/settings/gestures/GestureSettings.java
+++ b/src/com/android/settings/gestures/GestureSettings.java
@@ -18,11 +18,12 @@
 
 import android.content.Context;
 import android.content.res.Resources;
+import android.hardware.Sensor;
+import android.hardware.SensorManager;
 import android.os.Build;
 import android.os.Bundle;
 import android.os.SystemProperties;
 import android.provider.SearchIndexableResource;
-import android.provider.Settings.Global;
 import android.provider.Settings.Secure;
 import android.support.v7.preference.Preference;
 import android.support.v7.widget.RecyclerView;
@@ -98,6 +99,18 @@
             removePreference(PREF_KEY_SWIPE_DOWN_FINGERPRINT);
         }
 
+        // Double twist for camera mode
+        if (isDoubleTwistAvailable(context)) {
+            int doubleTwistEnabled = Secure.getInt(
+                    getContentResolver(), Secure.CAMERA_DOUBLE_TWIST_TO_FLIP_ENABLED, 1);
+            GesturePreference preference =
+                    (GesturePreference) findPreference(PREF_KEY_DOUBLE_TWIST);
+            preference.setChecked(doubleTwistEnabled != 0);
+            preference.setOnPreferenceChangeListener(this);
+        } else {
+            removePreference(PREF_KEY_DOUBLE_TWIST);
+        }
+
         if (savedInstanceState == null) {
             final Bundle args = getArguments();
             if (args != null && args.containsKey(ARG_SCROLL_TO_PREFERENCE)) {
@@ -131,8 +144,11 @@
         } else if (PREF_KEY_PICK_UP_AND_NUDGE.equals(key)) {
             Secure.putInt(getContentResolver(), Secure.DOZE_ENABLED, enabled ? 1 : 0);
         } else if (PREF_KEY_SWIPE_DOWN_FINGERPRINT.equals(key)) {
-            Global.putInt(getContentResolver(),
-                    Global.SYSTEM_NAVIGATION_KEYS_ENABLED, enabled ? 1 : 0);
+            Secure.putInt(getContentResolver(),
+                    Secure.SYSTEM_NAVIGATION_KEYS_ENABLED, enabled ? 1 : 0);
+        } else if (PREF_KEY_DOUBLE_TWIST.equals(key)) {
+            Secure.putInt(getContentResolver(),
+                    Secure.CAMERA_DOUBLE_TWIST_TO_FLIP_ENABLED, enabled ? 1 : 0);
         }
         return true;
     }
@@ -167,10 +183,26 @@
     }
 
     private static boolean isSystemUINavigationEnabled(Context context) {
-        return Global.getInt(context.getContentResolver(), Global.SYSTEM_NAVIGATION_KEYS_ENABLED, 1)
+        return Secure.getInt(context.getContentResolver(), Secure.SYSTEM_NAVIGATION_KEYS_ENABLED, 1)
                 == 1;
     }
 
+    private static boolean isDoubleTwistAvailable(Context context) {
+        Resources resources = context.getResources();
+        String name = resources.getString(R.string.gesture_double_twist_sensor_name);
+        String vendor = resources.getString(R.string.gesture_double_twist_sensor_vendor);
+        if (!TextUtils.isEmpty(name) && !TextUtils.isEmpty(vendor)) {
+            SensorManager sensorManager =
+                    (SensorManager) context.getSystemService(Context.SENSOR_SERVICE);
+            for (Sensor s : sensorManager.getSensorList(Sensor.TYPE_ALL)) {
+                if (name.equals(s.getName()) && vendor.equals(s.getVendor())) {
+                    return true;
+                }
+            }
+        }
+        return false;
+    }
+
     public static final Indexable.SearchIndexProvider SEARCH_INDEX_DATA_PROVIDER =
         new BaseSearchIndexProvider() {
             @Override
