diff options
Diffstat (limited to 'src/net/hoopajoo')
-rw-r--r-- | src/net/hoopajoo/android/SoftKeys/SoftKeysService.java | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/net/hoopajoo/android/SoftKeys/SoftKeysService.java b/src/net/hoopajoo/android/SoftKeys/SoftKeysService.java index fa23127..9371814 100644 --- a/src/net/hoopajoo/android/SoftKeys/SoftKeysService.java +++ b/src/net/hoopajoo/android/SoftKeys/SoftKeysService.java @@ -262,14 +262,6 @@ public class SoftKeysService extends Service { // The main buttons mView = l.inflate( R.layout.service, null ); - - mOrientationListener = new OrientationEventListener( this, SensorManager.SENSOR_DELAY_NORMAL ) { - @Override - public void onOrientationChanged( int orientation ) { - initOrientation(); - } - }; - mOrientationListener.enable(); SharedPreferences settings = PreferenceManager.getDefaultSharedPreferences( this ); @@ -472,6 +464,14 @@ public class SoftKeysService extends Service { wm.addView( mView, makeOverlayParams() ); wm.addView( mExtraView, makeOverlayParams() ); + mOrientationListener = new OrientationEventListener( this, SensorManager.SENSOR_DELAY_NORMAL ) { + @Override + public void onOrientationChanged( int orientation ) { + initOrientation(); + } + }; + mOrientationListener.enable(); + initOrientation(); } |