Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/android/212.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Android gallery没有在4.4中显示摄像头图像?_Android_Android Intent_Camera_Gallery - Fatal编程技术网

Android gallery没有在4.4中显示摄像头图像?

Android gallery没有在4.4中显示摄像头图像?,android,android-intent,camera,gallery,Android,Android Intent,Camera,Gallery,我有一些活动可以使用摄像头将图片拍摄到我的AppFolder中,但在android gallery中看不到图片。我几乎可以肯定,在低于4.4的版本中,它是好的 Intent intent = new Intent("android.media.action.IMAGE_CAPTURE"); imageFileName = ... File imageFileFolder = new File(Environment

我有一些活动可以使用摄像头将图片拍摄到我的AppFolder中,但在android gallery中看不到图片。我几乎可以肯定,在低于4.4的版本中,它是好的

        Intent intent = new Intent("android.media.action.IMAGE_CAPTURE");

        imageFileName = ...
        File imageFileFolder = new File(Environment
                .getExternalStorageDirectory(), "/AppFolder/");
        imageFileFolder.mkdir();
        intent = new Intent(
                android.provider.MediaStore.ACTION_IMAGE_CAPTURE);
        intent.putExtra(
                MediaStore.EXTRA_OUTPUT,
                Uri.parse("file:///sdcard/AppFolder/"
                        + imageFileName));

        photoTimeStamp = System.currentTimeMillis();
        startActivityForResult(intent, Constants.TAKE_PICTURE);