Commit graph

1803 commits

Author SHA1 Message Date
Joris Pelgröm cb59ce1208
Handle updated intents for Matter commissioning (#3535)
- It looks like fast pair/shared Matter devices now re-use the commissioning activity if it is still open in the background. Set the launch mode to single top to be able to use onNewIntent and get data for new devices.
2023-05-20 14:58:23 -04:00
googlvalenzuela f811c09175
Set Loading State for Entities (#3502)
* Set Loading State for Entities

* Fixing Ktlin LInt.

* Entity to executing take 2

* Adding buffering and disarming.

* Adding arming
2023-05-20 14:57:31 -04:00
Joris Pelgröm 6cf6c06c4c
Don't reset QS tile entity when changing servers if existing on new server (#3530)
- Prevent unnecessary changes to the selected entity when changing servers, if an entity exists on both servers. It already didn't clear everything like title/icon, just the selected entity!
 - Still calling selectEntityId in case the icon is different
2023-05-20 14:56:45 -04:00
Joris Pelgröm d81913b7ea
Add throttling/debouncing on Wear OS for registry updates (#3517) 2023-05-12 23:00:56 -04:00
Joris Pelgröm 7d6f11af4f
Add support for Assist pipeline, update Wear implementation (#3526)
* Group incoming messages by subscription to prevent out-of-order delivery

 - Messages received on the websocket are processed asynchronously, which is usually fine but can cause issues if messages need to be received in a specific order for a subscription. To fix this, process messages in order for the same subscription.

* Implement Assist pipeline API

 - Add basic support for the Assist pipeline API
 - Update conversation function to use the Assist pipeline when on the minimum required version
 - Update UI to refer to Assist pipeline requirement
2023-05-12 22:51:47 -04:00
Joris Pelgröm 57024e1561
Restore reading service data for configured button widgets (#3514) 2023-05-12 22:45:26 -04:00
Joris Pelgröm 7e1dc203ec
Fix expanded zone id for high accuracy zone constraint (#3509)
- When checking if an expanded zone geofence should be created include the server ID in the comparison as that is what is used everywhere else. Otherwise expanded zones are never added, and as a result high accuracy mode won't work as expected.
2023-05-12 22:43:38 -04:00
Joris Pelgröm 97634e3903
Fix dialog options for high accuracy zone constraint entity id (#3508)
Fix dialog for high accuracy zone constraint entity id

 - Zone entity ids can contain underscores, only split on underscores once to keep those that belong to the entity id (string is serverid_entityid). The data was being stored correctly.
2023-05-12 22:43:01 -04:00
Joris Pelgröm 87042137a4
Fix app lock 'retry' unlocking app (#3507)
- Only change the time for when the session expires if the app is in use, otherwise the new session expires timestamp might unlock the app
2023-05-12 22:39:56 -04:00
dependabot[bot] 8b32f9bffd
Bump com.squareup.okhttp3:okhttp from 4.10.0 to 4.11.0 (#3490)
Bumps [com.squareup.okhttp3:okhttp](https://github.com/square/okhttp) from 4.10.0 to 4.11.0.
- [Release notes](https://github.com/square/okhttp/releases)
- [Changelog](https://github.com/square/okhttp/blob/master/CHANGELOG.md)
- [Commits](https://github.com/square/okhttp/compare/parent-4.10.0...parent-4.11.0)

---
updated-dependencies:
- dependency-name: com.squareup.okhttp3:okhttp
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-04-24 21:09:24 -04:00
Joris Pelgröm 608a11211e
Use Kelvin for light color temperature if available (#3477)
- When using at least HA 2022.11, use Kelvins for the color temperature instead of mireds to match the frontend
2023-04-24 21:06:42 -04:00
Joris Pelgröm 1eb6ea61f4
Fix Wear OS template tile preview server (#3469)
Fix Wear template preview server

 - This still used an implicit server where it should be using a specific one
2023-04-24 21:05:49 -04:00
dependabot[bot] 6b03613352
Bump com.android.tools.build:gradle from 7.4.2 to 8.0.0 (#3474)
* Bump com.android.tools.build:gradle from 7.4.2 to 8.0.0

Bumps com.android.tools.build:gradle from 7.4.2 to 8.0.0.

---
updated-dependencies:
- dependency-name: com.android.tools.build:gradle
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* Bump Gradle version

* Build default values changes

 - Remove items that match new defaults
 - Add item to keep old default to allow for those changes to happen in another PR

* Align target Kotlin version with target Java version

* Use JDK 17

* Remove one more item that now matches default

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Joris Pelgröm <joris.pelgrom@gmail.com>
2023-04-24 21:05:20 -04:00
Daniel Shokouhi 32a793337f
Update change log week of 4/14 (#3475) 2023-04-14 17:36:11 -07:00
Joris Pelgröm 64ee62b8fa
Entity state complication improvements (more flexibility) (#3465)
* Add ComplicationType.LONG_TEXT support, friendly state

 - Makes it possible for watch faces to request a long text complication
 - Use the friendly state to support translated states and dates

* Add show title option

 - Allows hiding the title of a complication in case it doesn't look right

* Implement/fix reading state from database

 - When a entity ID is provided in the configuration request, load data for that complication from the database to allow easy reconfiguration
 - Provide more appropriate error messages when complication isn't configured / the entity doesn't exist

* ktlint
2023-04-08 16:33:16 -04:00
Daniel Shokouhi 95a322fc0b
Update change log week of 4/7 (#3462) 2023-04-07 19:12:27 -04:00
dependabot[bot] cffda9d3b4
Bump com.google.accompanist:accompanist-themeadapter-material from 0.28.0 to 0.30.1 (#3455)
Bump com.google.accompanist:accompanist-themeadapter-material

Bumps [com.google.accompanist:accompanist-themeadapter-material](https://github.com/google/accompanist) from 0.28.0 to 0.30.1.
- [Release notes](https://github.com/google/accompanist/releases)
- [Commits](https://github.com/google/accompanist/compare/v0.28.0...v0.30.1)

---
updated-dependencies:
- dependency-name: com.google.accompanist:accompanist-themeadapter-material
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-04-07 19:11:41 -04:00
Daniel Shokouhi 186e43b0e7
Bump a few app dependencies (#3461) 2023-04-07 19:11:16 -04:00
chriss158 8bffed7340
Fix option "Always show first view" with HA 2023.04 (#3459)
* Fix "Always show first view" option with HA > 2023.04

* Revert "Fix "Always show first view" option with HA > 2023.04"

This reverts commit bb1421e3f7.

* Much easier fix for "Always show first view" option with HA >2023.04
2023-04-07 19:10:39 -04:00
Joris Pelgröm fdde72b81e
Fix zone event zone ID including server ID (#3457)
- The zone ID sent to the server included the server ID, which could break automations listening for the zone ID (server ID isn't intended to be exposed)
2023-04-07 19:10:12 -04:00
Daniel Shokouhi f540c9cb49
Resize camera widget images to screen width (#3456)
* Resize camera widget images to screen width

* Only scale down image during resize
2023-04-07 19:09:47 -04:00
Joris Pelgröm 34ac4ad298
Disable favorites only view on Wear if all favorites are deleted (#3454) 2023-04-07 19:09:09 -04:00
Markus Friedli b4f877aa2d
Add Android OS sensors (#3449)
* Add Android OS sensors

* Rework review findings
2023-04-07 19:08:14 -04:00
pascal-t 94881a23d2
New intent extra types (#3436)
* Add more types to intent_extras

* Rearrange the intent_extras conversions to match the documentation

* Add String.urlencoded type for consistency.
2023-04-07 19:06:45 -04:00
Joris Pelgröm 75c7c08b2b
Improve phone feedback for Wear onboarding (#3450)
- Show a loading indicator after sending data
 - Show a Snackbar for success/errors
2023-04-02 20:20:16 -04:00
dependabot[bot] e592c334ea
Bump org.jetbrains.kotlin:kotlin-stdlib from 1.8.10 to 1.8.20 (#3442)
Bumps [org.jetbrains.kotlin:kotlin-stdlib](https://github.com/JetBrains/kotlin) from 1.8.10 to 1.8.20.
- [Release notes](https://github.com/JetBrains/kotlin/releases)
- [Changelog](https://github.com/JetBrains/kotlin/blob/master/ChangeLog.md)
- [Commits](https://github.com/JetBrains/kotlin/commits)

---
updated-dependencies:
- dependency-name: org.jetbrains.kotlin:kotlin-stdlib
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-04-01 04:02:29 +00:00
dependabot[bot] bdd7e6baec
Bump io.sentry:sentry-android from 6.14.0 to 6.17.0 (#3446)
Bumps [io.sentry:sentry-android](https://github.com/getsentry/sentry-java) from 6.14.0 to 6.17.0.
- [Release notes](https://github.com/getsentry/sentry-java/releases)
- [Changelog](https://github.com/getsentry/sentry-java/blob/main/CHANGELOG.md)
- [Commits](https://github.com/getsentry/sentry-java/compare/6.14.0...6.17.0)

---
updated-dependencies:
- dependency-name: io.sentry:sentry-android
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-03-31 23:45:11 -04:00
Joris Pelgröm cc20ffe83b
Add logged out state to Wear tiles (#3440)
- Adds a generic tile to be used when the Wear app isn't logged in
 - Simplify tile root layout building using Timeline.fromLayoutElement
2023-03-31 23:35:34 -04:00
Joris Pelgröm b6688c6388
Share Wear session with main app to fix mismatch (#3439)
- Exchange server information between the Wear app and phone app, and create a temporary server on the phone that holds the Wear server information, to ensure that the same server is used on both devices
2023-03-31 23:30:57 -04:00
Joris Pelgröm 4aadcd0315
Fix notification for missing notification command permissions (#3435)
- Fixes notifications for missing notification command permissions crashing the app because there was no server ID included for the notification
2023-03-31 23:22:31 -04:00
dependabot[bot] b947157f89
Bump com.google.accompanist:accompanist-themeadapter-material from 0.28.0 to 0.30.0 (#3431)
* Bump com.google.accompanist:accompanist-themeadapter-material

Bumps [com.google.accompanist:accompanist-themeadapter-material](https://github.com/google/accompanist) from 0.28.0 to 0.30.0.
- [Release notes](https://github.com/google/accompanist/releases)
- [Commits](https://github.com/google/accompanist/compare/v0.28.0...v0.30.0)

---
updated-dependencies:
- dependency-name: com.google.accompanist:accompanist-themeadapter-material
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* Update LiveData observer

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Joris Pelgröm <joris.pelgrom@gmail.com>
2023-03-31 23:22:05 -04:00
Joris Pelgröm f89d3c7c78
Fix Android Auto connected sensor intent crash (#3434)
- The CarConnection class registers for intents using the provided context, so switch to application context instead
2023-03-31 22:57:40 -04:00
Joris Pelgröm 3c0145eed3
Add Matter module preferred to manifest, again (#3427) 2023-03-31 22:57:33 -04:00
Joris Pelgröm 300edaa26b
Send device-preferred Thread dataset if different from core (#3426)
- Expand the automatic Thread dataset sync on Matter commissioning to also send the device-preferred Thread dataset if it's different from core (it will either receive something new or update)
2023-03-31 22:57:21 -04:00
Bassett, Justin 45c4e16074 Use less memory. 2023-03-31 22:21:58 -04:00
Bassett, Justin b22eb713c2 Let publishing of Automotive fail. 2023-03-31 22:04:29 -04:00
Bassett, Justin 66b86b5a55 Using the Automotive Track:
https://developers.google.com/android-publisher/tracks#ff-track-name
2023-03-31 21:06:50 -04:00
Justin Bassett b0d8ef625a
Make sure release keys are inflated. (#3447) 2023-03-31 22:47:51 +00:00
googlvalenzuela 8a322c624f
Android Automotive Module (#3423)
* Creation of Automotive Module and Fix OnboardingActivity parent Activity.

* Adding Manifest Dependencies.

* Fixing ktlint

* Remove unused import.

* Copy Google Services to android automotive

Github actions for PR require this to be set up in order for the build to pass.

* Missing two entries to copy the google-services.json file

* Fixing Build Process.

* Version code +2

We add 2 because the app, wear (+1) and automotive versions need to have different version codes.

* Update +3 per recomendation.

* Code to support transition from Full app to Car App Library.

* Fixing linter.

* More ktlin

/home/runner/work/android/android/app/src/main/java/io/homeassistant/companion/android/BaseActivity.kt:19:1 Needless blank line(s)
/home/runner/work/android/android/app/src/main/java/io/homeassistant/companion/android/BaseActivity.kt:31:95 Unnecessary semicolon
/home/runner/work/android/android/app/src/main/java/io/homeassistant/companion/android/BaseActivity.kt:39:1 Unexpected blank line(s) before "}"
/home/runner/work/android/android/app/src/main/java/io/homeassistant/companion/android/BaseActivity.kt:44:1 First line in a method block should not be empty

* Changes to allow navigate back from / native and feedback from PR.

* Indentation fixes.
2023-03-31 17:54:33 -04:00
dependabot[bot] e1f797add7
Bump actions/setup-java from 3.10.0 to 3.11.0 (#3438)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-03-28 10:43:01 +02:00
Joris Pelgröm d96fc78cad
Add background to Wear screenshots (#3437)
* Add background to Wear screenshots

* Wear onboarding background
2023-03-27 13:19:53 -04:00
Joris Pelgröm 8d2c9f1cb4
Get user information and prevent using admin-only calls (#3417)
* Get and cache user information

 - Add function to get information about the current user
 - Cache user information alongside server in database

* Replace/prevent admin only calls
2023-03-16 07:10:27 +00:00
Joris Pelgröm 421f38f1c2
Use new auth/revoke endpoint (#3416) 2023-03-15 19:15:16 -04:00
Joris Pelgröm 1a7091a761
Server trust feature (#3410)
* Server trust feature

* Always allow clear_notification, remove_channel and command_stop_tts commands
2023-03-15 19:14:39 -04:00
Daniel Shokouhi 0d9ea48fa7
Update change log week of 3/10 (#3413)
* Update change log week of 3/10

* Wording tweaks
2023-03-10 10:43:49 -08:00
Joris Pelgröm cc8dd47fcd
Drop 'tile' from template tile name (#3414) 2023-03-10 18:23:43 +00:00
Stefano Semeraro e63d8b33f3
Properly handle multiple permissions requests (#3411)
* Properly handle multiple permissions requests

* Removed empty newline at the beginning of the block
2023-03-10 13:16:23 -05:00
Daniel Shokouhi 52c2f3a8c5
Move away from runBlocking and fix some bugs in geofence updates and clearing notification (#3409) 2023-03-10 13:14:22 -05:00
Adrian Huber 3ebae7ee08
Fix listed beacons that are out of range after enable (#3398)
* Fix listed beacons that are out of range after enable

* Fix linter
2023-03-10 13:10:49 -05:00
Daniel Shokouhi b38974b30f
Allow clickAction to be set to noAction to do nothing (#3407) 2023-03-08 16:32:22 -05:00