- if (mPinCodeChecked &&
- ( mActivity.equals("FileDisplayActivity") || mActivity.equals("PreviewImageActivity") ) ){
- finish();
- } else if (mPinCodeChecked){
-
- Intent intent = getIntent();
- String newState = intent.getStringExtra(EXTRA_NEW_STATE);
-
- if (newState.equals("false")){
- SharedPreferences.Editor appPrefs = PreferenceManager
- .getDefaultSharedPreferences(getApplicationContext()).edit();
- appPrefs.putBoolean("set_pincode",false);
- appPrefs.commit();
-
- setInitVars();
- pinCodeEnd(false);
-
- }else{
-
- if (!mConfirmingPinCode){
- pinCodeChangeRequest();
-
+ if (mPinCodeChecked) {
+ // TODO remove or update:
+ // PassCodeManager.setUnlockTimestamp();
+
+ if (ACTION_REQUEST.equals(getIntent().getAction())) {
+ finish();
+
+ } else if (mPinCodeChecked) {
+ String newState = getIntent().getStringExtra(EXTRA_NEW_STATE);
+
+ // TODO - next decision should done according to the current state of PIN in prefs (enable or not), not whatever says de client
+ if (newState.equals("false")) {
+ SharedPreferences.Editor appPrefs = PreferenceManager
+ .getDefaultSharedPreferences(getApplicationContext()).edit();
+ appPrefs.putBoolean("set_pincode", false);
+ appPrefs.commit();
+
+ setInitVars();
+ pinCodeEnd(false);
+