Revert "samsung: doze: Add back button to action bar"
authorZhao Wei Liew <zhaoweiliew@gmail.com>
Sat, 3 Sep 2016 09:41:48 +0000 (17:41 +0800)
committerJan Altensen <info@stricted.net>
Fri, 20 Mar 2020 13:56:36 +0000 (14:56 +0100)
Starting N, top-level Settings activities should a drawer menu up
on the action bar. Remove the up/back button as it is now obsolete.

This reverts commit 5cfd7e76cf8099ebd22f4580cac8ed2217c3ead4.

Change-Id: I07af4c08a12bafbef424d01f62521cf226abbc2f

doze/src/com/cyanogenmod/settings/device/TouchscreenGestureSettings.java

index 73914f0e400c01122cae094aa419817a84bf26f3..30bbcf42033cd68395273fbe51e2dadc52823385 100644 (file)
 
 package com.cyanogenmod.settings.device;
 
-import android.app.ActionBar;
 import android.os.Bundle;
 import android.preference.Preference;
 import android.preference.PreferenceActivity;
 import android.preference.SwitchPreference;
 import android.provider.Settings;
-import android.view.Menu;
-import android.view.MenuItem;
 
 import org.cyanogenmod.internal.util.ScreenType;
 
@@ -59,9 +56,6 @@ public class TouchscreenGestureSettings extends PreferenceActivity {
         mProximityWakePreference =
             (SwitchPreference) findPreference(KEY_PROXIMITY_WAKE);
         mProximityWakePreference.setOnPreferenceChangeListener(mProximityListener);
-
-        final ActionBar actionBar = getActionBar();
-        actionBar.setDisplayHomeAsUpEnabled(true);
     }
 
     @Override
@@ -74,15 +68,6 @@ public class TouchscreenGestureSettings extends PreferenceActivity {
         }
     }
 
-    @Override
-    public boolean onOptionsItemSelected(MenuItem item) {
-        if (item.getItemId() == android.R.id.home) {
-            onBackPressed();
-            return true;
-        }
-        return false;
-    }
-
     private boolean enableDoze(boolean enable) {
         return Settings.Secure.putInt(getContentResolver(),
                 Settings.Secure.DOZE_ENABLED, enable ? 1 : 0);