sipp11
5 years ago
4 changed files with 159 additions and 54 deletions
@ -1,29 +1,66 @@ |
|||||||
<?xml version="1.0" encoding="utf-8"?> |
<?xml version="1.0" encoding="utf-8"?> |
||||||
<android.support.constraint.ConstraintLayout |
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" |
||||||
xmlns:android="http://schemas.android.com/apk/res/android" |
|
||||||
xmlns:tools="http://schemas.android.com/tools" |
xmlns:tools="http://schemas.android.com/tools" |
||||||
android:layout_width="match_parent" |
android:layout_width="match_parent" |
||||||
android:layout_height="match_parent" |
android:layout_height="match_parent" |
||||||
|
android:orientation="vertical" |
||||||
tools:context=".MainActivity"> |
tools:context=".MainActivity"> |
||||||
|
|
||||||
|
|
||||||
|
<TextView |
||||||
|
android:layout_width="match_parent" |
||||||
|
android:layout_height="wrap_content" |
||||||
|
android:text="Status" /> |
||||||
|
|
||||||
<LinearLayout |
<LinearLayout |
||||||
android:layout_width="match_parent" |
android:layout_width="match_parent" |
||||||
android:layout_height="wrap_content" |
android:layout_height="wrap_content" |
||||||
android:orientation="vertical"> |
android:orientation="horizontal"> |
||||||
|
|
||||||
|
<TextView |
||||||
|
android:layout_width="wrap_content" |
||||||
|
android:layout_height="wrap_content" |
||||||
|
android:layout_weight="1" |
||||||
|
android:background="@android:color/background_light" |
||||||
|
android:text="GPS" /> |
||||||
|
|
||||||
|
<TextView |
||||||
|
android:id="@+id/location_status_textview" |
||||||
|
android:layout_width="wrap_content" |
||||||
|
android:layout_height="wrap_content" |
||||||
|
android:layout_weight="3" |
||||||
|
android:textAlignment="center" |
||||||
|
android:background="@android:color/background_light" |
||||||
|
android:text="" /> |
||||||
|
|
||||||
<Button |
<Button |
||||||
android:id="@+id/btnStartService" |
android:id="@+id/ask_location_permission_button" |
||||||
android:layout_width="match_parent" |
android:layout_width="wrap_content" |
||||||
android:layout_height="wrap_content" |
android:layout_height="wrap_content" |
||||||
android:text="Start Foreground Service" android:paddingTop="20dp" android:layout_marginTop="20dp"/> |
android:layout_weight="3" |
||||||
|
android:padding="0dp" |
||||||
|
android:text="Permission Request" /> |
||||||
|
|
||||||
|
</LinearLayout> |
||||||
|
|
||||||
|
<LinearLayout |
||||||
|
android:layout_width="match_parent" |
||||||
|
android:layout_height="wrap_content" |
||||||
|
android:orientation="horizontal"> |
||||||
|
|
||||||
<Button |
<Button |
||||||
android:id="@+id/btnStopService" |
android:id="@+id/start_service_btn" |
||||||
android:layout_width="match_parent" |
android:layout_width="wrap_content" |
||||||
android:layout_height="wrap_content" |
android:layout_height="wrap_content" |
||||||
android:text="Stop Foreground Service"/> |
android:layout_weight="1" |
||||||
|
android:text="Start Foreground Service" /> |
||||||
|
|
||||||
|
<Button |
||||||
|
android:id="@+id/stop_service_btn" |
||||||
|
android:layout_width="wrap_content" |
||||||
|
android:layout_height="wrap_content" |
||||||
|
android:layout_weight="1" |
||||||
|
android:text="Stop Foreground Service" /> |
||||||
</LinearLayout> |
</LinearLayout> |
||||||
|
|
||||||
</android.support.constraint.ConstraintLayout> |
</LinearLayout> |
Loading…
Reference in new issue