In zoomed state stop fling gesture to next page - RadaeePDF.com
Signin/Signup with: 
Welcome, Guest
Username: Password: Remember me
13 Jul 2017
Microsoft has ended support for Windows Phone 8.1
Read More...
Questions about Android development and PDF
  • Page:
  • 1

TOPIC: In zoomed state stop fling gesture to next page

In zoomed state stop fling gesture to next page 4 years 2 months ago #5169

  • rohitks
  • rohitks's Avatar Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
  • Posts: 4
  • Thank you received: 0
1) Use def_view = 3
2) Zoom a specific page to more than300 %
3) In above scenario, user can perform the following actions:
a) user can scroll within the page (panning).
b) User can change the page through page thumbnails.
c) User can also fling the page to go to next page.
It is required to avoid "c) User can also fling the page to go to next page."
i.e. User should not be allowed to fling the page to go to next page in such scenario.

Please help us and suggest appropriate resolution.

Please Log in or Create an account to join the conversation.

In zoomed state stop fling gesture to next page 4 years 2 months ago #5187

  • nermeen
  • nermeen's Avatar
  • Offline
  • Moderator
  • Moderator
  • Posts: 789
  • Karma: 20
  • Thank you received: 58
You need to change the behavior in PDFViewDual.vOnFling(float, float, float, float) .. add a check on the scale level m_scale

Please Log in or Create an account to join the conversation.

In zoomed state stop fling gesture to next page 4 years 2 months ago #5216

  • SONAWANE
  • SONAWANE's Avatar
  • Offline
  • Fresh Boarder
  • Fresh Boarder
  • Posts: 7
  • Thank you received: 0
You can do that by adding one condition in "PDFGestureListener" class which you can find in "PDFView"

just replace code from below


earlier


if (vOnFling(dx, dy, velocityX, velocityY)) {
m_status = STA_NONE;
if (m_listener != null)
m_listener.OnPDFInvalidate(false);
return true;
} else
return false;


change with


if (vGetMinScale() == vGetScale())
if (vOnFling(dx, dy, velocityX, velocityY)) {
m_status = STA_NONE;
if (m_listener != null)
m_listener.OnPDFInvalidate(false);
return true;
} else
return false;
else
return false;

Please Log in or Create an account to join the conversation.

In zoomed state stop fling gesture to next page 3 years 3 months ago #8335

  • alex.temp
  • alex.temp's Avatar
  • Offline
  • Fresh Boarder
  • Fresh Boarder
  • Posts: 9
  • Thank you received: 0
Hi, I cannot edit the PDFView as I'm using the standard version.
Any other way to solve this without editing the PDFView?

Please Log in or Create an account to join the conversation.

  • Page:
  • 1
Powered by Kunena Forum