- Posts: 11
- Thank you received: 0
Microsoft Windows Phone 8.1 support ends (13 Jul 2017)
Microsoft has ended support for Windows Phone 8.1
Here you should submit your bug reports with logcat.
Search results positioning bug on Android
- [email protected]
- Topic Author
- Offline
- New Member
-
Less
More
10 years 2 months ago #10109
by [email protected]
Replied by [email protected] on topic Search results positioning bug on Android
It's your example
I believe in this case Global.def_view = 3.
Thanks!
Thanks!
- [email protected]
- Topic Author
- Offline
- New Member
-
Less
More
- Posts: 11
- Thank you received: 0
10 years 2 months ago #10170
by [email protected]
Replied by [email protected] on topic Search results positioning bug on Android
Hello, any update on that?
Thanks.
Thanks.
- [email protected]
- Topic Author
- Offline
- New Member
-
Less
More
- Posts: 11
- Thank you received: 0
10 years 1 month ago #10218
by [email protected]
Replied by [email protected] on topic Search results positioning bug on Android
Hello, still no updates?
10 years 1 month ago - 10 years 1 month ago #10220
by Davide
Replied by Davide on topic Search results positioning bug on Android
Hi,
maintain the old edit I suggested you and add the following line to vFind method of PDFView after vFindGoTo():
vCenterPage(m_finder.find_get_page());
Example:
maintain the old edit I suggested you and add the following line to vFind method of PDFView after vFindGoTo():
vCenterPage(m_finder.find_get_page());
Example:
Code:
public int vFind(int dir)
{
if( m_pages == null ) return -1;
int ret = m_finder.find_prepare(dir);
if( ret == 1 )
{
if( m_listener != null )
m_listener.OnPDFFound( true );
vFindGoto();
vCenterPage(m_finder.find_get_page());
return 0;//succeeded
}
if( ret == 0 )
{
if( m_listener != null )
m_listener.OnPDFFound( false );
return -1;//failed
}
m_thread.start_find( m_finder );//need thread operation.
return 1;
}
Last edit: 10 years 1 month ago by Davide.
- [email protected]
- Topic Author
- Offline
- New Member
-
Less
More
- Posts: 11
- Thank you received: 0
10 years 1 month ago - 10 years 1 month ago #10245
by [email protected]
Replied by [email protected] on topic Search results positioning bug on Android
Change made (keeping the earlier you sent us), but nothing changes
Last edit: 10 years 1 month ago by [email protected].
10 years 1 month ago #10246
by Davide
Replied by Davide on topic Search results positioning bug on Android
Hi,
please add this method to PDFLayout class:
You have to make public or protected some variables of VPage class (m_x, m_y, m_w, m_h).
Then you have to call this method : vCenterPage(m_finder.find_get_page()); at line 136 and 1033 of PDFView class.
This will solve your issue.
please add this method to PDFLayout class:
Code:
public void vCenterPage( int pageno )
{
if( m_pages == null || m_doc == null || m_w <= 0 || m_h <= 0 ) return;
m_scroller.forceFinished(true);
m_scroller.abortAnimation();
int left = m_pages[pageno].m_x - m_page_gap/2;
int top = m_pages[pageno].m_y - m_page_gap/2;
int w = m_pages[pageno].m_w + m_page_gap;
int h = m_pages[pageno].m_h + m_page_gap;
int x = left + (w - m_w)/2;
int y = top + (h - m_h)/2;
int oldx = m_scroller.getCurrX();
int oldy = m_scroller.getCurrY();
m_scroller.startScroll(oldx, oldy, x - oldx, y - oldy);
}
You have to make public or protected some variables of VPage class (m_x, m_y, m_w, m_h).
Then you have to call this method : vCenterPage(m_finder.find_get_page()); at line 136 and 1033 of PDFView class.
This will solve your issue.
Time to create page: 0.381 seconds