-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Android] Implement OTA Provider exception case (#30777)
* Implement Android OTA Provider exception case * Restyled by google-java-format * Restyled by clang-format * Add TooManyFunctions exception --------- Co-authored-by: Restyled.io <[email protected]>
- Loading branch information
Showing
8 changed files
with
726 additions
and
42 deletions.
There are no files selected for viewing
395 changes: 383 additions & 12 deletions
395
...ool/app/src/main/java/com/google/chip/chiptool/clusterclient/OtaProviderClientFragment.kt
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
60 changes: 60 additions & 0 deletions
60
examples/android/CHIPTool/app/src/main/res/layout/write_default_otaproviders_dialog.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android" | ||
xmlns:app="http://schemas.android.com/apk/res-auto" | ||
xmlns:tools="http://schemas.android.com/tools" | ||
android:layout_width="wrap_content" | ||
android:layout_height="wrap_content" | ||
android:padding="16dp"> | ||
<TextView | ||
android:id="@+id/titleText" | ||
android:layout_width="wrap_content" | ||
android:layout_height="wrap_content" | ||
android:text="@string/ota_provider_write_default_ota_providers_text" | ||
android:textSize="22sp" | ||
app:layout_constraintStart_toStartOf="parent" | ||
app:layout_constraintTop_toTopOf="parent" /> | ||
|
||
<EditText | ||
android:id="@+id/fabricIndexEd" | ||
android:layout_width="wrap_content" | ||
android:layout_height="wrap_content" | ||
android:hint="@string/ota_provider_fabric_index_text" | ||
android:inputType="number" | ||
android:textSize="16sp" | ||
android:layout_marginBottom="8dp" | ||
app:layout_constraintStart_toStartOf="parent" | ||
app:layout_constraintTop_toBottomOf="@id/titleText" | ||
app:layout_constraintBottom_toTopOf="@id/providerNodeIdEd"/> | ||
|
||
<EditText | ||
android:id="@+id/providerNodeIdEd" | ||
android:layout_width="wrap_content" | ||
android:layout_height="wrap_content" | ||
android:hint="@string/ota_provider_provider_node_id_text" | ||
android:inputType="number" | ||
android:textSize="16sp" | ||
android:layout_marginBottom="8dp" | ||
app:layout_constraintStart_toStartOf="parent" | ||
app:layout_constraintTop_toBottomOf="@id/fabricIndexEd" | ||
app:layout_constraintBottom_toTopOf="@id/endpointIdEd"/> | ||
|
||
<EditText | ||
android:id="@+id/endpointIdEd" | ||
android:layout_width="wrap_content" | ||
android:layout_height="wrap_content" | ||
android:hint="@string/ota_provider_endpoint_id_text" | ||
android:inputType="number" | ||
android:textSize="16sp" | ||
android:layout_marginBottom="8dp" | ||
app:layout_constraintStart_toStartOf="parent" | ||
app:layout_constraintTop_toBottomOf="@id/providerNodeIdEd" | ||
app:layout_constraintBottom_toTopOf="@id/writeDefaultOtaProvidersBtn"/> | ||
|
||
<Button | ||
android:id="@+id/writeDefaultOtaProvidersBtn" | ||
android:layout_width="wrap_content" | ||
android:layout_height="wrap_content" | ||
android:text="@string/group_setting_write_btn_text" | ||
app:layout_constraintBottom_toBottomOf="parent" | ||
app:layout_constraintEnd_toEndOf="parent" /> | ||
</androidx.constraintlayout.widget.ConstraintLayout> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.