Skip to content
This repository has been archived by the owner on Sep 12, 2023. It is now read-only.

Unexpected back press behavior on Android 14 #1322

Open
4 of 5 tasks
FooIbar opened this issue Aug 3, 2023 · 4 comments
Open
4 of 5 tasks

Unexpected back press behavior on Android 14 #1322

FooIbar opened this issue Aug 3, 2023 · 4 comments
Labels
bug Something isn't working

Comments

@FooIbar
Copy link
Contributor

FooIbar commented Aug 3, 2023

复现步骤 / Step to reproduce

  1. Launch app
  2. Navigate to Downloads
  3. Press back button

预期行为 / Expected behaviour

Back to homepage

实际行为 / Actual Behaviour

Back to launcher

应用日志 / App logs

No response

备注 / Addition details

And this:

Screen_recording_20230804_010840.mp4

EhViewer 版本号 / EhViewer version code

1.8.9.0-SNAPSHOT

EhViewer CI 版本 / EhViewer CI Version

5422c04

Android 系统版本 / Android version

14

设备型号 / Device model

sdk_gphone64_x86_64

SoC 型号 / Soc model

/

自查步骤 / Verify steps

  • 如果您有足够的时间和能力,并愿意为此提交 PR ,请勾上此复选框 / Pull request is welcome. Check this if you want to start a pull request
  • 您已仔细查看并知情 Q&A 中的内容 / You have checked Q&A carefully
  • 您已搜索过 Issue Tracker,没有找到类似内容 / I have searched on Issue Tracker, No duplicate or related open issue has been found
  • 您确保这个 Issue 只提及一个问题。如果您有多个问题报告,烦请发起多个 Issue / Ensure there is only one bug report in this issue. Please make mutiply issue for mutiply bugs
  • 您确保已使用最新 CI 版本测试,并且该问题在最新 CI 版本中并未解决 / This bug have not solved in latest CI version
@FooIbar FooIbar added the bug Something isn't working label Aug 3, 2023
@FooIbar
Copy link
Contributor Author

FooIbar commented Aug 3, 2023

┬───
│ GC Root: Thread object
│
├─ android.os.HandlerThread instance
│    Leaking: NO (PathClassLoader↓ is not leaking)
│    Thread name: 'LeakCanary-Heap-Dump'
│    ↓ Thread.contextClassLoader
├─ dalvik.system.PathClassLoader instance
│    Leaking: NO (DownloadManager↓ is not leaking and A ClassLoader is never leaking)
│    ↓ ClassLoader.runtimeInternalObjects
├─ java.lang.Object[] array
│    Leaking: NO (DownloadManager↓ is not leaking)
│    ↓ Object[3266]
├─ com.hippo.ehviewer.download.DownloadManager class
│    Leaking: NO (DownloadsScene↓ is not leaking and a class is never leaking)
│    ↓ static DownloadManager.mDownloadInfoListeners
├─ java.util.ArrayList instance
│    Leaking: NO (DownloadsScene↓ is not leaking)
│    ↓ ArrayList[1]
├─ com.hippo.ehviewer.ui.scene.DownloadsScene instance
│    Leaking: NO (FragmentContainerView↓ is not leaking and Fragment#mFragmentManager is not null)
│    Fragment.mTag=0f77fb06-a118-4e37-9677-ba3056f3c5cb
│    ↓ Fragment.mContainer
├─ androidx.fragment.app.FragmentContainerView instance
│    Leaking: NO (View attached)
│    View is part of a window view hierarchy
│    View.mAttachInfo is not null (view attached)
│    View.mID = R.id.fragment_container
│    View.mWindowAttachCount = 1
│    mContext instance of com.hippo.ehviewer.ui.MainActivity with mDestroyed = false
│    ↓ FragmentContainerView.disappearingFragmentChildren
│                            ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
├─ java.util.ArrayList instance
│    Leaking: UNKNOWN
│    Retaining 60 B in 2 objects
│    ↓ ArrayList[2]
│               ~~~
╰→ androidx.coordinatorlayout.widget.CoordinatorLayout instance
​     Leaking: YES (ObjectWatcher was watching this because com.hippo.ehviewer.ui.scene.GalleryListScene received
​     Fragment#onDestroyView() callback (references to its views should be cleared to prevent leaks))
​     Retaining 260.3 kB in 5935 objects
​     key = ce15d164-edd8-4583-980f-a714a3150570
​     watchDurationMillis = 15502
​     retainedDurationMillis = 7324
​     View not part of a window view hierarchy
​     View.mAttachInfo is null (view detached)
​     View.mWindowAttachCount = 1
​     mContext instance of com.hippo.ehviewer.ui.MainActivity with mDestroyed = false

Meanwhile

@asuka-mio
Copy link
Member

Androidx fragment写的有点问题

@FooIbar
Copy link
Contributor Author

FooIbar commented Aug 4, 2023

Also back press on Android 14 won't close right drawer.

@FooIbar
Copy link
Contributor Author

FooIbar commented Aug 8, 2023

Predictive back 选择留在原界面会导致:

Screen_recording_20230808_222732.mp4

FooIbar referenced this issue in FooIbar/EhViewer Aug 11, 2023
Reland after #1322 resolved
FooIbar referenced this issue in FooIbar/EhViewer Aug 11, 2023
Reland after #1322 resolved
FooIbar referenced this issue in FooIbar/EhViewer Aug 11, 2023
Reland after #1322 resolved
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
Development

No branches or pull requests

2 participants