Захват изображения с камеры. Фрагмент потерян, перейдите к предыдущему фрагменту.

1

Когда я щелкаю изображение с камеры, при щелчке по метке я автоматически перемещаюсь по предыдущему фрагменту. Это происходит только в Redmi 6A.

Код намерения камеры -

Intent cameraIntent = new Intent(android.provider.MediaStore.ACTION_IMAGE_CAPTURE);
                        startActivityForResult(cameraIntent, 0);

Код результата деятельности -

if (resultCode == RESULT_OK) {
                    Uri selectedImage = data.getData();                     
                    String file_name = File_Path.getPath(getContext(), selectedImage);
                    destination = new File(file_name);
Glide.with(Objects.requireNonNull(getContext()))
                            .load(file_name)
                            .into(imageView);
                }

и получите это error-

E/libc: Access denied finding property "ro.sf.lcd_density"
E/InputTransport: ro.sf.lcd_density must be defined as a build property
Теги:
android-camera-intent

1 ответ

0

Добрый вечер, у меня тоже проблемы с приложением на Redmi 6A.

Чтобы поделиться извлечением, приложение генерирует .png из FragmentLayout, но эта проблема возникает только на этом устройстве.

Вот мой полный код ошибки.

    04/18 17:46:31: Launching app
No apk changes detected since last installation, skipping installation of C:\Users\Win7_Android\Documents\Projeto\SisLotec\app\build\outputs\apk\debug\app-debug.apk
$ adb shell am force-stop lotecsis.sislotec
$ adb shell am start -n "lotecsis.sislotec/lotecsis.sislotec.classes.MainActivity" -a android.intent.action.MAIN -c android.intent.category.LAUNCHER
Client not ready yet..Waiting for process to come online
Connected to process 14087 on device xiaomi-redmi_6a-0899dd357d2b
Capturing and displaying logcat messages from application. This behavior can be disabled in the "Logcat output" section of the "Debugger" settings page.
D/AccessibilityManager: AccessibilityManager status: mPackageName = lotecsis.sislotec, mOptimizeEnabled = false, mIsEnabled = false, mIsUiAutomationEnabled = false, mIsInterestedPackage =false
I/zygote: Do partial code cache collection, code=29KB, data=28KB
I/zygote: After code cache collection, code=29KB, data=28KB
I/zygote: Increasing code cache capacity to 128KB
I/zygote: Do partial code cache collection, code=39KB, data=57KB
I/zygote: After code cache collection, code=39KB, data=57KB
I/zygote: Increasing code cache capacity to 256KB
I/zygote: Compiler allocated 4MB to compile void android.widget.TextView.<init>(android.content.Context, android.util.AttributeSet, int, int)
E/Restarou: a hora
I/SurfaceFactory: [static] sSurfaceFactory = com.mediatek.view.impl.SurfaceFactoryImpl@2cc51f4
D/OpenGLRenderer: Dumper init 2 threads <0x9957f3e0>
D/OpenGLRenderer: <lotecsis.sislotec> is running.
D/OpenGLRenderer: HWUI GL Pipeline
D/ViewRootImpl[MainActivity]: hardware acceleration = true , fakeHwAccelerated = false, sRendererDisabled = false, forceHwAccelerated = false, sSystemRendererDisabled = false
W/tecsis.sislotec: type=1400 audit(0.0:14283): avc: denied { read } for name="u:object_r:graphics_config_prop:s0" dev="tmpfs" ino=650 scontext=u:r:untrusted_app:s0:c512,c768 tcontext=u:object_r:graphics_config_prop:s0 tclass=file permissive=0
E/libc: Access denied finding property "ro.sf.lcd_density"
E/InputTransport: ro.sf.lcd_density must be defined as a build property
V/PhoneWindow: DecorView setVisiblity: visibility = 0, Parent = ViewRoot{6569960 lotecsis.sislotec/lotecsis.sislotec.classes.MainActivity,ident = 0}, this = DecorView@5dabe19[MainActivity]
D/Surface: Surface::allocateBuffers(this=0x998e1800)
I/zygote: android::hardware::configstore::V1_0::ISurfaceFlingerConfigs::hasWideColorDisplay retrieved: 0
I/OpenGLRenderer: Initialized EGL, version 1.4
D/OpenGLRenderer: Swap behavior 2
D/OpenGLRenderer: [init] completed
D/HWUIExtension: MTKProgramCache.init: enable enhancement 1
I/HWUIExtension: Get disable program binary service property (0)
I/HWUIExtension: Initializing program atlas...
I/ProgramBinary/Service: ProgramBinaryService client side disable debugging.
I/ProgramBinary/Service: ProgramBinaryService client side disable binary content debugging.
D/ProgramBinary/Service: BpProgramBinaryService.getReady
D/ProgramBinary/Service: zhiyin- 1 BpProgramBinaryService::getReady()
D/ProgramBinary/Service: zhiyin- 2 BpProgramBinaryService::getReady()
D/ProgramBinary/Service: BpProgramBinaryService.getProgramBinaryData
I/HWUIExtension: Program binary detail: Binary length is 314156, program map length is 104.
I/HWUIExtension: Succeeded to mmap program binaries. File descriptor is 63, and path is /dev/ashmem.
I/HWUIExtension: No need to use file discriptor anymore, close fd(63).
D/HWUIExtension: Dumper init 2 threads <0x8cfe8cc0>
D/HWUIExtension: <lotecsis.sislotec> is running.
D/HWUIExtension: Initializing program cache from 0x0, size = -1
D/Surface: Surface::connect(this=0x998e1800,api=1)
I/zygote: Do full code cache collection, code=109KB, data=85KB
I/zygote: After code cache collection, code=92KB, data=61KB
D/GraphicBuffer: register, handle(0x9faa64c0) (w:720 h:1440 s:736 f:0x1 u:b00)
D/HWUIExtension: MTKProgramCache.generateProgram: 0
D/HWUIExtension: createProgram 0x0000000000000000, binary 0x9921e000, length 10736, format 37168 within 2047ns
D/HWUIExtension: MTKProgramCache.generateProgram: 240518168576
D/HWUIExtension: createProgram 0x0000003800000000, binary 0x99223661, length 11450, format 37168 within 517ns
D/HWUIExtension: MTKProgramCache.generateProgram: 68724719680
D/HWUIExtension: createProgram 0x0000001000500040, binary 0x992209f0, length 11377, format 37168 within 390ns
D/HWUIExtension: MTKProgramCache.generateProgram: 562984313159683
D/HWUIExtension: createProgram 0x0002000800000003, binary 0x9923158b, length 11447, format 37168 within 405ns
D/GraphicBuffer: register, handle(0x9faa6640) (w:720 h:1440 s:736 f:0x1 u:b00)
D/GraphicBuffer: register, handle(0x9faa6640) (w:720 h:1440 s:736 f:0x1 u:b00)
D/Surface: Surface::disconnect(this=0x998e1800,api=1)
D/GraphicBuffer: unregister, handle(0x9faa67c0) (w:720 h:1440 s:736 f:0x1 u:b00)
D/GraphicBuffer: unregister, handle(0x9faa6700) (w:720 h:1440 s:736 f:0x1 u:b00)
D/GraphicBuffer: unregister, handle(0x9faa6580) (w:720 h:1440 s:736 f:0x1 u:b00)
D/View: [Warning] assignParent to null: this = DecorView@5dabe19[MainActivity]
Application terminated.

Ещё вопросы

Сообщество Overcoder
Наверх
Меню