public class BatteryActivity
extends Activity
Modifier and Type | Class and Description |
---|---|
private class |
BatteryActivity.MyThread
Thread that monitors the battery information about the level and charging
of the device and sends the data collected to the gui if the Battery
Activity is currently showing on the screen.
|
Modifier and Type | Field and Description |
---|---|
private ToggleButton |
button
The button for enabling and disabling the battery monitoring.
|
(package private) Handler |
handler |
private TextView |
textBatteryInfo
The text view that shows the collected information about the battery.
|
Constructor and Description |
---|
BatteryActivity() |
Modifier and Type | Method and Description |
---|---|
void |
buttonPushed(View view)
Method that is called when the button Enable Monitoring is pushed.
|
protected void |
onCreate(Bundle savedInstanceState) |
protected void |
onDestroy() |
protected void |
onPause() |
protected void |
onResume() |
protected void |
onStart() |
protected void |
onStop() |
private TextView textBatteryInfo
private ToggleButton button
Handler handler
protected void onCreate(Bundle savedInstanceState)
protected void onStart()
protected void onResume()
protected void onPause()
protected void onStop()
protected void onDestroy()
public void buttonPushed(View view)