Commit cea13b06 authored by 林生雨's avatar 林生雨

commit

parent 65160352
......@@ -17,6 +17,7 @@ import android.widget.Toast
import com.example.gengmei_flutter_plugin.result.ResultManager
import com.example.gengmei_flutter_plugin.sharedPrefernces.SharedManager
import com.example.gengmei_flutter_plugin.utils.DebugUtil
import com.example.gengmei_flutter_plugin.utils.MyUtil.Companion.getFileName
import com.example.gengmei_flutter_plugin.utils.addTo
import com.example.myimagepicker.luban.Luban
import com.example.myimagepicker.repository.ImageRespository
......@@ -28,6 +29,7 @@ import io.reactivex.disposables.CompositeDisposable
import kotlin.collections.ArrayList
import kotlin.collections.HashMap
import java.io.File
import java.io.FileNotFoundException
class GengmeiFlutterPlugin : MethodCallHandler {
......@@ -336,9 +338,15 @@ class GengmeiFlutterPlugin : MethodCallHandler {
map.put("path", it.second)
map.put("isVideo", "F")
map.put("folderName", "GengmeiAlbum")
Log.e("lsy", " ${map} ")
Log.e("lsy", " ${it.first} ")
Log.e("lsy", " ${it.second} ")
// try {
// MediaStore.Images.Media.insertImage(resign.context().applicationContext.getContentResolver(),
// nativeImage!!.absolutePath, getFileName(nativeImage!!.absolutePath), null);
// } catch ( e: FileNotFoundException) {
// e.printStackTrace();
// }
// 最后通知图库更新
resign.context().applicationContext.sendBroadcast(Intent(Intent.ACTION_MEDIA_SCANNER_SCAN_FILE,
Uri.fromFile(nativeImage)))
ImageRespository.getInstance().recordImageListMap.add(map)
ResultManager.getInstance().resultSuccess(gotoNativeCameraKey, map);
}, {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment