);

else

Intent

intent

new

ContextWrapper

getApplicationContext

()).

registerReceiver

null

new

IntentFilter

Intent

ACTION_BATTERY_CHANGED

));

batteryLevel

intent

getIntExtra

BatteryManager

EXTRA_LEVEL

100

intent

getIntExtra

BatteryManager

EXTRA_SCALE

);

return

batteryLevel