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 - GPS Icon not disapearing after closing app

GPS Icon not disapearing after closing app

Put problem concerning MapActivities, MapViews, Overlays and GPS in this forum.

GPS Icon not disapearing after closing app

Postby iifuzz » Wed Jun 03, 2009 9:26 pm

Anyone have any ideas why my GPS icon stays up even after i close my app?

How do I get the app to recognize when the back button was pressed to exit the program?
that way i can use

locationManager.removeUpdates(this);
locationManager = null;
finish();
iifuzz
Junior Developer
Junior Developer
 
Posts: 22
Joined: Thu May 21, 2009 6:00 pm

Top

Re: GPS Icon not disapearing after closing app

Postby orux » Thu Jun 04, 2009 9:02 am

You can listen key press

@Override
public boolean onKeyDown(int keyCode, KeyEvent event) {

if (keyCode == KeyEvent.KEYCODE_BACK){} // back key

if (keyCode == KeyEvent.KEYCODE_HOME){} //home key

return super.onKeyDown(keyCode, event);
}
orux
Freshman
Freshman
 
Posts: 5
Joined: Wed May 13, 2009 3:12 pm

Re: GPS Icon not disapearing after closing app

Postby orux » Thu Jun 04, 2009 9:07 am

But after "locationManager.removeUpdates(myLocationListener);" GPS icon is not removed from StatusBar (almost in emulator).

Is that normal???

Thanks
orux
Freshman
Freshman
 
Posts: 5
Joined: Wed May 13, 2009 3:12 pm

Postby iifuzz » Thu Jun 04, 2009 12:13 pm

maybe it is the finish(); in my quit menu button that is making the GPS icon go away and not the removeupdate..


anyways, i will try the code you posted today . thanks ^_^
iifuzz
Junior Developer
Junior Developer
 
Posts: 22
Joined: Thu May 21, 2009 6:00 pm

Postby iifuzz » Thu Jun 04, 2009 2:29 pm

Hmm, i dont think thats what i needed.

IS there a way to detect when the app was closed... For example, when you push the back button to get out of it?
iifuzz
Junior Developer
Junior Developer
 
Posts: 22
Joined: Thu May 21, 2009 6:00 pm

Top

Return to Map Problems

Who is online

Users browsing this forum: Yahoo [Bot] and 1 guest