public void onPause() { prefs.unregisterOnSharedPreferenceChangeListener(this); super.onPause(); if (!app.getRecorderCtx().isRunning() && !exit && !preferences) app.notificationShow(); preferences = false; }