Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781
[phpBB Debug] PHP Notice: in file /includes/session.php on line 1007: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/session.php on line 1007: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/session.php on line 1007: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)

Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781

Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781

Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4362: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4364: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4365: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4366: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
anddev.org • View topic - Getting X,Y Co-ordinates ?

Getting X,Y Co-ordinates ?

Put problem concerning Views, Layouts and other XML-Resources (like AndroidManifest) here.

Getting X,Y Co-ordinates ?

Postby Andy » Tue Dec 23, 2008 1:55 pm

Hi All,

How to get the screen (X,Y) Co-ordinates of the pointer pressed in touch screen.


Is there any method avaliable ?


Regards,
Andy
A n D r O i D
Andy
Junior Developer
Junior Developer
 
Posts: 13
Joined: Fri Dec 19, 2008 2:53 pm

Top

Postby logtoavi » Tue Dec 23, 2008 2:28 pm

ye there is option

take alook at this code

@Override
public boolean onTouchEvent(MotionEvent motion){
int x = (int)motion.getX();
int y = (int)motion.getY();
}
Thanks and Regards
Avishek Kumar
logtoavi
Freshman
Freshman
 
Posts: 9
Joined: Wed Dec 17, 2008 11:30 am
Location: Noida

Postby Andy » Tue Dec 23, 2008 3:08 pm

Thanks logtoavi!!


Just discovered the same thing here..... :)


Regards,
Andy
A n D r O i D
Andy
Junior Developer
Junior Developer
 
Posts: 13
Joined: Fri Dec 19, 2008 2:53 pm

Top

Return to View, Layout & Resource Problems

Who is online

Users browsing this forum: Exabot [Bot] and 5 guests