r2-testapp-kotlin icon indicating copy to clipboard operation
r2-testapp-kotlin copied to clipboard

Top bar (header) doesnt show sometimes

Open mrifni opened this issue 3 years ago • 3 comments

Bug Report

What happened?

Top bar header doesnt seems to be showing after sometime playing with the page swiping and changing the reading mode as seen on the video attached.

You can see in the video I am trying to bring the top bar back by clicking on the page but it doesnt come. ( its done after the first minute.

https://user-images.githubusercontent.com/1643992/123521811-f2bd1c00-d6b0-11eb-9274-afb55ae08136.mp4

Environment

develop branch

Readium versions

all develop versions, i dont think its a problem with the latest version, ive been seeing this for a while now.

  • r2-shared-kotlin:
  • r2-streamer-kotlin:
  • r2-navigator-kotlin:
  • r2-opds-kotlin:
  • r2-lcp-kotlin:

Development environment

  • OS: macOS 10.3
  • IDE: Android Studio 4.1.3

Testing device

  • Android version:
  • Model: Pixel 4 API 26
  • Is it an emulator? Yes

mrifni avatar Jun 26 '21 18:06 mrifni

does anyone know what the issue is ?

mrifni avatar Jun 30 '21 11:06 mrifni

I couldn't reproduce this issue but it seems pretty random from what you described.

You might need to investigate yourself with your debugger. I would check in order:

  • Is the JavaScript onClick event called? https://github.com/readium/r2-navigator-kotlin/blob/77f80c4bcc6a9f9b842354980a10597fa903eda4/r2-navigator/src/main/assets/readium/scripts/gestures.js#L12
    • You can use the Chrome Web Inspector to debug the web view from an Android device. Just open chrome://inspect on your computer.
  • Is the native onTap event called, and does the event passes all the conditions? https://github.com/readium/r2-navigator-kotlin/blob/77f80c4bcc6a9f9b842354980a10597fa903eda4/r2-navigator/src/main/java/org/readium/r2/navigator/R2BasicWebView.kt#L198
    • Then check that the listener is set and listener.onTap is called https://github.com/readium/r2-navigator-kotlin/blob/77f80c4bcc6a9f9b842354980a10597fa903eda4/r2-navigator/src/main/java/org/readium/r2/navigator/R2BasicWebView.kt#L229
  • Is R2EpubActivity.onTap called https://github.com/readium/r2-navigator-kotlin/blob/77f80c4bcc6a9f9b842354980a10597fa903eda4/r2-navigator/src/main/java/org/readium/r2/navigator/epub/R2EpubActivity.kt#L187-L189
    • Then inspect toggleActionBar() https://github.com/readium/r2-navigator-kotlin/blob/77f80c4bcc6a9f9b842354980a10597fa903eda4/r2-navigator/src/main/java/org/readium/r2/navigator/epub/R2EpubActivity.kt#L140

mickael-menu avatar Jul 01 '21 11:07 mickael-menu

Yes, even I observed this issue. steps worked at my end to reproduce the issue.

  1. open ebook and tap on it appbar will appear
  2. tap once again appbar will disappear
  3. Now swipe quickly the pages (moving forward)
  4. now tap on the reader and check the behavior. appbar will not appear.
  5. repeat the steps 2 to 4 incase it is not reproduced .

nareshsvn avatar Aug 26 '21 08:08 nareshsvn