mirror of
				https://github.com/commons-app/apps-android-commons.git
				synced 2025-10-30 22:34:02 +01:00 
			
		
		
		
	Merge remote-tracking branch 'refs/remotes/origin/2.8-release'
This commit is contained in:
		
						commit
						23014e07c8
					
				
					 13 changed files with 459 additions and 85 deletions
				
			
		|  | @ -95,7 +95,7 @@ public class ContributionController { | |||
| 
 | ||||
|     public void handleImagePicked(int requestCode, @Nullable Uri uri, boolean isDirectUpload, String wikiDataEntityId) { | ||||
|         FragmentActivity activity = fragment.getActivity(); | ||||
|         Timber.d("handleImagePicked() called with onActivityResult()"); | ||||
|         Timber.d("handleImagePicked() called with onActivityResult(). Boolean isDirectUpload: " + isDirectUpload + "String wikiDataEntityId: " + wikiDataEntityId); | ||||
|         Intent shareIntent = new Intent(activity, ShareActivity.class); | ||||
|         shareIntent.setAction(ACTION_SEND); | ||||
|         switch (requestCode) { | ||||
|  | @ -113,21 +113,26 @@ public class ContributionController { | |||
|                 shareIntent.setType("image/jpeg"); | ||||
|                 shareIntent.putExtra(EXTRA_STREAM, lastGeneratedCaptureUri); | ||||
|                 shareIntent.putExtra(EXTRA_SOURCE, SOURCE_CAMERA); | ||||
| 
 | ||||
|                 break; | ||||
|             default: | ||||
|                 break; | ||||
|         } | ||||
| 
 | ||||
|         Timber.i("Image selected"); | ||||
|         shareIntent.putExtra("isDirectUpload", isDirectUpload); | ||||
|         Timber.d("Put extras into image intent, isDirectUpload is " + isDirectUpload); | ||||
| 
 | ||||
|         try { | ||||
|             shareIntent.putExtra("isDirectUpload", isDirectUpload); | ||||
|             if (wikiDataEntityId != null && !wikiDataEntityId.equals("")) { | ||||
|                 shareIntent.putExtra(WIKIDATA_ENTITY_ID_PREF, wikiDataEntityId); | ||||
|             } | ||||
|             activity.startActivity(shareIntent); | ||||
|         } catch (SecurityException e) { | ||||
|             Timber.e(e, "Security Exception"); | ||||
|         } | ||||
| 
 | ||||
|         if (activity != null) { | ||||
|             activity.startActivity(shareIntent); | ||||
|         } | ||||
|     } | ||||
| 
 | ||||
|     void saveState(Bundle outState) { | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 misaochan
						misaochan