Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -50,31 +50,30 @@
map:latLngBoundsSouthWestLongitude="-122.1" />

<LinearLayout
android:background="@color/white"
android:background="?attr/colorSurface"
android:id="@+id/container"
android:layout_width="wrap_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:padding="4dp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/top_bar">

<LinearLayout
android:layout_width="wrap_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center_vertical"
android:paddingHorizontal="4dp"
android:orientation="horizontal">

<com.google.android.material.button.MaterialButton
android:id="@+id/clamp_min_zoom"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/clamp_min_zoom" />

<com.google.android.material.button.MaterialButton
android:id="@+id/clamp_max_zoom"
android:layout_width="wrap_content"
<TextView
android:id="@+id/zoom_label"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:text="@string/clamp_max_zoom" />
android:layout_weight="1"
android:textAppearance="?attr/textAppearanceBodyMedium"
android:text="@string/initial_zoom_limits" />

<com.google.android.material.button.MaterialButton
android:id="@+id/clamp_zoom_reset"
Expand All @@ -83,43 +82,63 @@
android:text="@string/clamp_zoom_reset" />
</LinearLayout>

<LinearLayout
android:layout_width="wrap_content"
<com.google.android.material.slider.RangeSlider
android:id="@+id/zoom_range_slider"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
android:valueFrom="2.0"
android:valueTo="21.0"
android:stepSize="0.5"
app:values="@array/initial_zoom_range" />

<com.google.android.material.button.MaterialButtonToggleGroup
android:id="@+id/latlng_clamp_toggle_group"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:singleSelection="true"
app:selectionRequired="false">

<com.google.android.material.button.MaterialButton
android:id="@+id/clamp_latlng_adelaide"
android:layout_width="wrap_content"
style="?attr/materialButtonOutlinedStyle"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="0.5"
android:layout_weight="1"
android:text="@string/clamp_latlng_adelaide" />

<com.google.android.material.button.MaterialButton
android:id="@+id/clamp_latlng_pacific"
android:layout_width="wrap_content"
style="?attr/materialButtonOutlinedStyle"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="0.5"
android:layout_weight="1"
android:text="@string/clamp_latlng_pacific" />

<com.google.android.material.button.MaterialButton
android:id="@+id/clamp_latlng_reset"
android:layout_width="wrap_content"
style="?attr/materialButtonOutlinedStyle"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@string/clamp_latlng_reset" />
</LinearLayout>
</com.google.android.material.button.MaterialButtonToggleGroup>

<LinearLayout
android:layout_width="wrap_content"
<TextView
android:id="@+id/clamp_status_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">

<TextView
android:id="@+id/camera_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/move_the_camera" />
</LinearLayout>
android:paddingHorizontal="4dp"
android:paddingTop="4dp"
android:textAppearance="?attr/textAppearanceBodyMedium"
android:text="@string/latlng_clamp_status_none" />

<TextView
android:id="@+id/camera_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingHorizontal="4dp"
android:paddingTop="2dp"
android:text="@string/move_the_camera" />
</LinearLayout>

</androidx.constraintlayout.widget.ConstraintLayout>
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:title="@string/background_color_customization_demo_label"
app:title="@string/camera_demo_label"
app:titleTextColor="?attr/colorOnPrimary" />

<androidx.fragment.app.FragmentContainerView
Expand All @@ -40,7 +40,7 @@
android:id="@+id/first_container"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@color/white"
android:background="?attr/colorSurface"
android:baselineAligned="false"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
Expand Down Expand Up @@ -160,7 +160,7 @@
android:id="@+id/second_container"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@color/white"
android:background="?attr/colorSurface"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/first_container">
Expand All @@ -183,7 +183,7 @@
android:id="@+id/third_container"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@color/white"
android:background="?attr/colorSurface"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/second_container">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,12 @@
app:layout_constraintTop_toBottomOf="@+id/top_bar" />

<LinearLayout
android:id="@+id/events_info_panel"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_height="wrap_content"
android:background="?attr/colorSurface"
android:orientation="vertical"

android:padding="12dp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/top_bar">
Expand All @@ -49,12 +51,15 @@
android:id="@+id/tap_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:textAppearance="?attr/textAppearanceBodyMedium"
android:text="@string/tap_instructions" />

<com.google.android.material.textview.MaterialTextView
android:id="@+id/camera_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="4dp"
android:textAppearance="?attr/textAppearanceBodyMedium"
android:text="@string/move_the_camera" />
</LinearLayout>
</androidx.constraintlayout.widget.ConstraintLayout>
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
android:id="@+id/container"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@color/white"
android:background="?attr/colorSurface"
android:padding="5dp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
Expand Down
16 changes: 9 additions & 7 deletions ApiDemos/project/common-ui/src/main/res/layout/layers_demo.xml
Original file line number Diff line number Diff line change
Expand Up @@ -43,38 +43,40 @@
android:id="@+id/checkbox_container"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:background="@color/white"
android:minWidth="160dp"
android:background="?attr/colorSurface"
android:orientation="vertical"
android:padding="6dp"
android:padding="8dp"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="@id/map">

<Spinner
android:id="@+id/layers_spinner"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
android:layout_height="wrap_content"
android:minHeight="48dp" />

<CheckBox
<com.google.android.material.checkbox.MaterialCheckBox
android:id="@+id/traffic"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/traffic" />

<CheckBox
<com.google.android.material.checkbox.MaterialCheckBox
android:id="@+id/my_location"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:checked="false"
android:text="@string/my_location" />

<CheckBox
<com.google.android.material.checkbox.MaterialCheckBox
android:id="@+id/buildings"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:checked="true"
android:text="@string/buildings" />

<CheckBox
<com.google.android.material.checkbox.MaterialCheckBox
android:id="@+id/indoor"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
Expand Down
Loading