Microsoft Windows Phone 8.1 support ends (13 Jul 2017)

Microsoft has ended support for Windows Phone 8.1

Questions about Android development and PDF

how to bring to normal size after double click

More
IP: 192.168.0.71 11 years 3 months ago #7930 by asliyanage
I found below method in pdfreader class.

public boolean OnPDFDoubleTapped(float x, float y)
{
if( m_status != STA_NORMAL ) return false;
m_view.vSetScale(m_view.vGetScale() + Global.zoomStep, x, y);
return true;
}

I need to bring the pdf when if double click happens when the pdf is in mazimum size.So how to identify the maximum size ?is there any status like STA_NORMAL for maximum size ?
More
IP: 192.168.0.158 11 years 3 months ago #7981 by nermeen
You can do it like:
Code:
if(m_view.vGetScale() == m_view.vGetMaxScale()) Global.zoomStep *= -1; //this will reverse the zoom behavior
More
IP: 192.168.0.71 11 years 3 months ago #7985 by asliyanage
I change the code as below.Now it maximize if i double clicks the pdf and if i double click it comes to normal size.

public boolean OnPDFDoubleTapped(float x, float y)
{

if(m_view.vGetScale() == m_view.vGetMinScale()){
m_view.vSetScale(m_view.vGetMaxScale(),x,y );
}else{
m_view.vSetScale(m_view.vGetMinScale(),x,y );
}

}
Time to create page: 0.421 seconds
Powered by Kunena Forum