1
我正在使用通用圖像加載程序在我的應用程序中顯示圖像。有圖像共享功能與其他應用程序共享圖像。通用圖像加載程序與其他應用程序共享圖像
現在我做:
ImageLoader imageLoader = ImageLoader.getInstance();
File file = imageLoader.getDiskCache().get(url);
if (file != null) {
Util.shareImage(getActivity(), file);
}
public static void shareImage(Context context, File pictureFile) {
Uri imageUri = Uri.parse(pictureFile.getAbsolutePath());
Intent shareIntent = new Intent();
shareIntent.setAction(Intent.ACTION_SEND);
shareIntent.putExtra(Intent.EXTRA_STREAM, imageUri);
//shareIntent.setType("image/jpeg");
shareIntent.setType("image/*");
context.startActivity(Intent.createChooser(shareIntent, "Share"));
}
下面是變量的值。
不知道爲什麼它不工作?
不工作:/ –