- Posts: 13
- Thank you received: 0
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 lock the current page
IP: 192.168.0.70
13 years 3 months ago #912
by khaled89
Replied by khaled89 on topic How to lock the current page
thank you I have solved this, I followed the code in the read me document
IP: 192.168.0.70
12 years 5 months ago #4252
by aminnouri
Replied by aminnouri on topic How to lock the current page
i have this method in my code:
public boolean onTouchEvent(MotionEvent event)
{
if( m_view == null ) return false;
if( m_view.vGetLock() == 3 )
{
if( onTouchInk(event) ) return true;
if( onTouchRect(event) ) return true;
if( onTouchEllipse(event) ) return true;
if( onTouchNote(event) ) return true;
if( onTouchLine(event) ) return true;
if( onTouchAnnot(event) ) return true;
}
return m_view.vTouchEvent(event);
}
and i customize that to this:
public boolean onTouchEvent(MotionEvent event)
{
boolean result = true;
if( m_view == null ) return false;
if( m_view.vGetLock() == 3 )
{
if( onTouchInk(event) ) return true;
if( onTouchRect(event) ) return true;
if( onTouchEllipse(event) ) return true;
if( onTouchNote(event) ) return true;
if( onTouchLine(event) ) return true;
if( onTouchAnnot(event) ) return true;
}
if(!zoom_status)
{
result = m_view.vTouchEvent(event);
}
return result;
}
but when zoom don't work any thing and i can't even scroll!
plz help!
public boolean onTouchEvent(MotionEvent event)
{
if( m_view == null ) return false;
if( m_view.vGetLock() == 3 )
{
if( onTouchInk(event) ) return true;
if( onTouchRect(event) ) return true;
if( onTouchEllipse(event) ) return true;
if( onTouchNote(event) ) return true;
if( onTouchLine(event) ) return true;
if( onTouchAnnot(event) ) return true;
}
return m_view.vTouchEvent(event);
}
and i customize that to this:
public boolean onTouchEvent(MotionEvent event)
{
boolean result = true;
if( m_view == null ) return false;
if( m_view.vGetLock() == 3 )
{
if( onTouchInk(event) ) return true;
if( onTouchRect(event) ) return true;
if( onTouchEllipse(event) ) return true;
if( onTouchNote(event) ) return true;
if( onTouchLine(event) ) return true;
if( onTouchAnnot(event) ) return true;
}
if(!zoom_status)
{
result = m_view.vTouchEvent(event);
}
return result;
}
but when zoom don't work any thing and i can't even scroll!
plz help!
IP: 192.168.0.70
12 years 5 months ago #4255
by radaee
Replied by radaee on topic How to lock the current page
not understand, what you want?
IP: 192.168.0.70
12 years 5 months ago #4256
by aminnouri
Replied by aminnouri on topic How to lock the current page
i want when in zoom don't goto next page, it means in zoom swipe doesn't work.
zoom_status is a flag that show that page in zoom or not
zoom_status is a flag that show that page in zoom or not
IP: 192.168.0.70
12 years 5 months ago - 12 years 5 months ago #4258
by radaee
Replied by radaee on topic How to lock the current page
pages shall not be swiped, while zooming.
swipe only happen when zoom finished or just finished.
in single page mode or dual page mode.
when you finished zooming operation, current page may changes, depends on the fixed point and scale value.
in this scene, you can save pageno, before zooming, and restore current pageno just finished zooming.
swipe only happen when zoom finished or just finished.
in single page mode or dual page mode.
when you finished zooming operation, current page may changes, depends on the fixed point and scale value.
in this scene, you can save pageno, before zooming, and restore current pageno just finished zooming.
Last edit: 12 years 5 months ago by .
IP: 192.168.0.70
12 years 5 months ago #4261
by aminnouri
Replied by aminnouri on topic How to lock the current page
my problem is not paging while zooming(in zoom process). my problem is i want lock swipe when a user zoom on a page(when zoom finished), swipe unlocked when zoom out to whole the page (when zoom finished).
Time to create page: 0.376 seconds