views:

49

answers:

1

Hi there, i'm making a program that disables your wifi when you lock your screen but i can't find an object the holds that kind of information (wether it's locked or not)

+1  A: 

In most Android phones Wifi is turned off a few minutes after the screen is locked.
This setting can also be controlled by the user in Settings->Wireless Netowrks->WiFi->Advanced.

Anyway, if you want to tell when the screen is locked, register to receive the ACTION_SCREEN_OFF broadcast intent.

adamk