Loading app/src/main/java/net/sourceforge/opencamera/MainActivity.java +4 −13 Original line number Diff line number Diff line Loading @@ -4975,9 +4975,8 @@ public class MainActivity extends AppCompatActivity implements PreferenceFragmen if( MyDebug.LOG ) Log.d(TAG, "openGallery"); //Intent intent = new Intent(Intent.ACTION_VIEW, MediaStore.Images.Media.EXTERNAL_CONTENT_URI); Uri primaryUri = applicationInterface.getStorageUtils().getLastMediaScanned(); Uri uri = null; boolean is_raw = false; Uri uri = applicationInterface.getStorageUtils().getLastMediaScanned(); boolean is_raw = uri != null && applicationInterface.getStorageUtils().getLastMediaScannedIsRaw(); if( MyDebug.LOG && uri != null ) { Log.d(TAG, "found cached most recent uri: " + uri); Log.d(TAG, " is_raw: " + is_raw); Loading Loading @@ -5028,14 +5027,6 @@ public class MainActivity extends AppCompatActivity implements PreferenceFragmen uri = MediaStore.Images.Media.EXTERNAL_CONTENT_URI; is_raw = false; } boolean allowEdit = true; if( uri == null ) { uri = primaryUri; is_raw = uri != null && applicationInterface.getStorageUtils().getLastMediaScannedIsRaw(); allowEdit = false; } if( !is_test ) { // don't do if testing, as unclear how to exit activity to finish test (for testGallery()) if( MyDebug.LOG ) Loading @@ -5053,7 +5044,7 @@ public class MainActivity extends AppCompatActivity implements PreferenceFragmen Log.d(TAG, "try REVIEW_ACTION"); try { Intent intent = new Intent(REVIEW_ACTION, uri); intent.putExtra(KEY_FROM_SNAPCAM, allowEdit); intent.putExtra(KEY_FROM_SNAPCAM, true); this.startActivity(intent); done = true; } Loading @@ -5066,7 +5057,7 @@ public class MainActivity extends AppCompatActivity implements PreferenceFragmen Log.d(TAG, "try ACTION_VIEW"); try { Intent intent = new Intent(Intent.ACTION_VIEW, uri); intent.putExtra(KEY_FROM_SNAPCAM, allowEdit); intent.putExtra(KEY_FROM_SNAPCAM, true); this.startActivity(intent); } catch(ActivityNotFoundException e) { Loading Loading
app/src/main/java/net/sourceforge/opencamera/MainActivity.java +4 −13 Original line number Diff line number Diff line Loading @@ -4975,9 +4975,8 @@ public class MainActivity extends AppCompatActivity implements PreferenceFragmen if( MyDebug.LOG ) Log.d(TAG, "openGallery"); //Intent intent = new Intent(Intent.ACTION_VIEW, MediaStore.Images.Media.EXTERNAL_CONTENT_URI); Uri primaryUri = applicationInterface.getStorageUtils().getLastMediaScanned(); Uri uri = null; boolean is_raw = false; Uri uri = applicationInterface.getStorageUtils().getLastMediaScanned(); boolean is_raw = uri != null && applicationInterface.getStorageUtils().getLastMediaScannedIsRaw(); if( MyDebug.LOG && uri != null ) { Log.d(TAG, "found cached most recent uri: " + uri); Log.d(TAG, " is_raw: " + is_raw); Loading Loading @@ -5028,14 +5027,6 @@ public class MainActivity extends AppCompatActivity implements PreferenceFragmen uri = MediaStore.Images.Media.EXTERNAL_CONTENT_URI; is_raw = false; } boolean allowEdit = true; if( uri == null ) { uri = primaryUri; is_raw = uri != null && applicationInterface.getStorageUtils().getLastMediaScannedIsRaw(); allowEdit = false; } if( !is_test ) { // don't do if testing, as unclear how to exit activity to finish test (for testGallery()) if( MyDebug.LOG ) Loading @@ -5053,7 +5044,7 @@ public class MainActivity extends AppCompatActivity implements PreferenceFragmen Log.d(TAG, "try REVIEW_ACTION"); try { Intent intent = new Intent(REVIEW_ACTION, uri); intent.putExtra(KEY_FROM_SNAPCAM, allowEdit); intent.putExtra(KEY_FROM_SNAPCAM, true); this.startActivity(intent); done = true; } Loading @@ -5066,7 +5057,7 @@ public class MainActivity extends AppCompatActivity implements PreferenceFragmen Log.d(TAG, "try ACTION_VIEW"); try { Intent intent = new Intent(Intent.ACTION_VIEW, uri); intent.putExtra(KEY_FROM_SNAPCAM, allowEdit); intent.putExtra(KEY_FROM_SNAPCAM, true); this.startActivity(intent); } catch(ActivityNotFoundException e) { Loading