Commit graph

1425 commits

Author SHA1 Message Date
dependabot[bot] a2499e6389
Bump sentry-android from 6.9.2 to 6.10.0 (#3164)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 6.9.2 to 6.10.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.9.2...6.10.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>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-12-30 19:53:37 -05:00
Joris Pelgröm e9712582b4
Fix app lock bypass on home WiFi command, code style (#3173)
* Fix app lock bypass on home WiFi command, code style

 - Fix the app lock bypass when on home WiFi notification command
 - Fix code style for app lock notification commands

* Consistent variable names
2022-12-30 19:53:02 -05:00
Daniel Shokouhi 4f5f6a1539
Update change log 12/19 (#3165)
* Update change log 12/19

* Remove trailing space

* Combine all QS tile updates
2022-12-20 12:07:10 -05:00
Joris Pelgröm f928da2e6d
Matter dependency update and tweaks for shared devices + errors (#3161)
* Update Matter dependency

* Improve shared device commissioning

 - Show device name if available
 - Show error codes if returned

* Show toast for commissioning request errors

 - When an error occurs for commissioning requests/before the Play Services UI is shown, show a toast informing the user that Matter is currently unavailable. Most user-facing errors will be shown in the Play Services UI (during commissioning).
2022-12-18 21:37:35 +00:00
chriss158 e5191aed51
Add setting to start the app always on the first dashboard view (#3024)
* Add setting to start the app always on the first dashboard view

* Run linting

* Do not close SettingsActivity

* Only show first view if not in HA Config + Fix flash of dashboard when navigating to app settings

* Scroll to top when calling first view of dashboard

If we are on a another view a we are scrolled to the bottom, the first view will be also at the bottom

* Use default dashboard as starting dashboard

* Allow HA config dashboard to call the first view of dashboard

- Also disallow /hassio (Home Assistant addons) to call the first view

* Enhance show first view setting description

* Fix class name spelling LifecycleHandler

* Fix calling first view of dashboard on config/areas and config/automation

Co-authored-by: Justin Bassett <bassett.justint@gmail.com>
2022-12-18 21:08:22 +00:00
Joris Pelgröm 7e5e3adfe9
Use entity icon for quick settings tiles by default (#3160)
- When creating a new quick setting tile, use the entity's icon by default
 - Move Wear icon based on entity domain code to common
2022-12-18 15:31:01 -05:00
Daniel Shokouhi 8df504e1d7
Migrate more sensors to Wear OS (#3115) 2022-12-18 15:20:12 -05:00
Daniel Shokouhi 84d392f681
Update change log week of 12/16 (#3157) 2022-12-16 10:01:00 -08:00
dependabot[bot] e29f692986
Bump sentry-android from 6.9.1 to 6.9.2 (#3141)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 6.9.1 to 6.9.2.
- [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.9.1...6.9.2)

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

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

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-12-16 10:01:09 -05:00
Tamás Nagy 77f6de4550
Fix monochrome icon on Android 13+ (#3131)
Signed-off-by: Tamás Nagy (T-bond) <tbondvagyok@gmail.com>

Signed-off-by: Tamás Nagy (T-bond) <tbondvagyok@gmail.com>
2022-12-16 10:00:10 -05:00
Daniel Shokouhi e7c18b870c
Add new option to vibrate when quick settings tile is clicked (#3123)
* Add new option to vibrate when quick settings tile is clicked

* Use vibration effects if the device supports it

* Review comments

* Remove question mark

* Set switch color when unchecked
2022-12-16 09:55:59 -05:00
Daniel Shokouhi 956b26cc99
Update change log week of 12/3 (#3133)
* Update change log week of 12/3

* Rewrite some changes

* Add Matter
2022-12-03 16:39:53 -08:00
dependabot[bot] 9e8949fe9b
Bump sentry-android from 6.9.0 to 6.9.1 (#3127)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 6.9.0 to 6.9.1.
- [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.9.0...6.9.1)

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

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

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-12-03 17:53:52 -05:00
Joris Pelgröm 69d5949f14
Add initial Matter commissioning support (#3132)
* Matter commissioning: MVP

 - Implement a basic framework for the app to support Matter commissioning
 - Add hooks for the `matter/commission` message that will be sent by the frontend to trigger Matter commissioning

* [WIP] HA as Matter share target

* [WIP] Updated commissioning flow

 - Add websocket Matter API support
 - Update architecture to better ensure a working minimal build
 - Remove external bus responses for Matter commissioning message

* Rename MatterRepository

* Handle shared Matter devices

 - Adds UI to handle shared Matter devices instead of copying the pairing code to the clipboard
 - Updates the on network pairing pin/code to be a String, which may be received for shared devices

* Cleanup test button

* Pairing code type and service error handling

 - Update pairing/pin code type to Long for server
 - Send Play Services error if commissioning returned an error

* Increase timeout for Matter commissioning requests

* Use normal commissioning for shared devices

 - Use the normal matter/commission command for devices shared with the app
 - Shared device UI polishing

* Fix minimal and remove old name

* Update frontend commissioning status enum
2022-12-03 17:36:12 -05:00
Daniel Shokouhi 312a36e898
Update quick setting tiles with state updates (#3121)
* Update quick setting tiles with state updates

* Keep track of appropriate job to cancel when needed, use variable for toggle with lock

* Switch to Job from CoroutineScope
2022-11-30 15:19:00 -05:00
dependabot[bot] 8ced5d3974
Bump sentry-android from 6.8.0 to 6.9.0 (#3117)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 6.8.0 to 6.9.0.
- [Release notes](https://github.com/getsentry/sentry-java/releases)
- [Changelog](https://github.com/getsentry/sentry-java/blob/6.9.0/CHANGELOG.md)
- [Commits](https://github.com/getsentry/sentry-java/compare/6.8.0...6.9.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>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-11-30 15:00:20 -05:00
dependabot[bot] ffd658b539
Bump accompanist-appcompat-theme from 0.27.1 to 0.28.0 (#3116)
Bumps [accompanist-appcompat-theme](https://github.com/google/accompanist) from 0.27.1 to 0.28.0.
- [Release notes](https://github.com/google/accompanist/releases)
- [Commits](https://github.com/google/accompanist/compare/v0.27.1...v0.28.0)

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

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

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-11-30 15:00:11 -05:00
Joris Pelgröm 4ec5fbf1f0
Remove NFC tag sample YAML for 'scanned by this device' on 2022.12+ (#3114) 2022-11-28 22:14:30 -05:00
Joris Pelgröm 11e8d5a8e8
Only request multiple tasks for HA notification intents (#3109)
Only request multiple tasks for notification intents for HA
2022-11-28 22:13:51 -05:00
Joris Pelgröm 71bf6a76f1
Don't crash when system is unable to handle download intent (#3108)
Catch ActivityNotFoundException for downloads

 - When trying to forward a download intent to the system catch the exception that is thrown if the system can't handle it to prevent a crash
2022-11-28 22:12:55 -05:00
Joris Pelgröm 442cb25e59
Add deeplinks to Wear OS sensor sync notifications (#3105)
Add deeplinks to Wear sensor sync notifications
2022-11-28 22:11:57 -05:00
Daniel Shokouhi fd7a593c41
Fix current version sensor so it properly reports the flavor (#3104)
* Fix current version sensor so it properly reports the flavor

* Review comments
2022-11-28 22:11:12 -05:00
Joris Pelgröm bd044c9be0
Support automation entities in quick settings tiles (#3102) 2022-11-28 22:06:30 -05:00
Tanishq Manuja 9bf5299fb2
Button Widget: Uniform Spacing (#3099)
* style(widget): more uniform spacing in button widget

* style(widget): more uniform spacing in entity state widget

* fix: revert unused changes
2022-11-28 22:05:30 -05:00
Tanishq Manuja f35f9ce26e
Button Widget: Hide label if empty or null (#3097)
* feat(widget): hide label if empty or null

* fix(formatting): ktlint issue
2022-11-28 22:05:04 -05:00
dependabot[bot] 7af5b237cc
Bump sentry-android from 6.7.0 to 6.8.0 (#3089)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 6.7.0 to 6.8.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.7.0...6.8.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>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-11-22 19:17:51 +00:00
dependabot[bot] ee60714ad5
Bump accompanist-appcompat-theme from 0.27.0 to 0.27.1 (#3085)
Bumps [accompanist-appcompat-theme](https://github.com/google/accompanist) from 0.27.0 to 0.27.1.
- [Release notes](https://github.com/google/accompanist/releases)
- [Commits](https://github.com/google/accompanist/compare/v0.27.0...v0.27.1)

---
updated-dependencies:
- dependency-name: com.google.accompanist:accompanist-appcompat-theme
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

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

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-11-22 14:05:31 -05:00
Daniel Shokouhi f15b192a79
Reduce usage of job scheduling to avoid throttling (#3087) 2022-11-22 14:04:55 -05:00
dependabot[bot] 21d301b3f8
Bump reorderable from 0.9.5 to 0.9.6 (#3064)
* Bump reorderable from 0.9.5 to 0.9.6

Bumps [reorderable](https://github.com/aclassen/ComposeReorderable) from 0.9.5 to 0.9.6.
- [Release notes](https://github.com/aclassen/ComposeReorderable/releases)
- [Commits](https://github.com/aclassen/ComposeReorderable/commits/0.9.6)

---
updated-dependencies:
- dependency-name: org.burnoutcrew.composereorderable:reorderable
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

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

* Update canDragOver to new format

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>
2022-11-22 14:02:47 -05:00
Joris Pelgröm c50ce30b5b
Update and fix in-app language picker (#3080)
* Manage app language using AndroidX, integrate with Android 13

 - Manage the app language using AndroidX to fix the setting not being applied and to be able to easily integrate with Android 13's system setting

* Move locales_config.xml to common

* Generate locales_config.xml when downloading translations

* Fix multiple variants for languages being collapsed into one

* Fix language codes with region variants

* Don't split languages when using app bundles

* Rename
2022-11-22 13:59:24 -05:00
dependabot[bot] 62ebb90f2e
Bump hilt-android from 2.44 to 2.44.2 (#3071)
Bumps [hilt-android](https://github.com/google/dagger) from 2.44 to 2.44.2.
- [Release notes](https://github.com/google/dagger/releases)
- [Changelog](https://github.com/google/dagger/blob/master/CHANGELOG.md)
- [Commits](https://github.com/google/dagger/compare/dagger-2.44...dagger-2.44.2)

---
updated-dependencies:
- dependency-name: com.google.dagger:hilt-android
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

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

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-11-17 14:42:31 +00:00
dependabot[bot] 1b5ab1c2ec
Bump hilt-android-compiler from 2.44 to 2.44.2 (#3072)
Bumps [hilt-android-compiler](https://github.com/google/dagger) from 2.44 to 2.44.2.
- [Release notes](https://github.com/google/dagger/releases)
- [Changelog](https://github.com/google/dagger/blob/master/CHANGELOG.md)
- [Commits](https://github.com/google/dagger/compare/dagger-2.44...dagger-2.44.2)

---
updated-dependencies:
- dependency-name: com.google.dagger:hilt-android-compiler
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

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

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-11-17 09:30:21 -05:00
Joris Pelgröm 0bccff65c3
Revert jackson-module-kotlin bump to fix compatibility on older Android version (#3077) 2022-11-17 09:06:31 -05:00
Daniel Shokouhi 4eb709d9c6
Update change log week of 11/11 (#3058) 2022-11-12 09:26:10 -08:00
dependabot[bot] 65df318161
Bump reorderable from 0.9.2 to 0.9.5 (#3055)
Bumps [reorderable](https://github.com/aclassen/ComposeReorderable) from 0.9.2 to 0.9.5.
- [Release notes](https://github.com/aclassen/ComposeReorderable/releases)
- [Commits](https://github.com/aclassen/ComposeReorderable/commits)

---
updated-dependencies:
- dependency-name: org.burnoutcrew.composereorderable:reorderable
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

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

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-11-12 08:25:00 -05:00
Daniel Shokouhi 70c66fcb46
Bump location dependency (#3056) 2022-11-12 08:24:38 -05:00
dependabot[bot] 5bac66c0c7
Bump sentry-android from 6.6.0 to 6.7.0 (#3049)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 6.6.0 to 6.7.0.
- [Release notes](https://github.com/getsentry/sentry-java/releases)
- [Changelog](https://github.com/getsentry/sentry-java/blob/6.7.0/CHANGELOG.md)
- [Commits](https://github.com/getsentry/sentry-java/compare/6.6.0...6.7.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>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-11-09 16:18:18 -05:00
dependabot[bot] a20fb24ddc
Bump jackson-module-kotlin from 2.13.4 to 2.14.0 (#3048)
Bumps [jackson-module-kotlin](https://github.com/FasterXML/jackson-module-kotlin) from 2.13.4 to 2.14.0.
- [Release notes](https://github.com/FasterXML/jackson-module-kotlin/releases)
- [Commits](https://github.com/FasterXML/jackson-module-kotlin/compare/jackson-module-kotlin-2.13.4...jackson-module-kotlin-2.14.0)

---
updated-dependencies:
- dependency-name: com.fasterxml.jackson.module:jackson-module-kotlin
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

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

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-11-09 16:18:05 -05:00
chriss158 367e35dae4
Remove quick bar deprecation comment (#3052)
Remove quick bar comment

Home assistant core has fixed the issue in 2022.10.0
2022-11-09 16:17:39 -05:00
Daniel Shokouhi 57b3b771b4
Track time between hardware sensor updates to restart the listener as needed (#3026)
* Check if listener got stuck for heart rate sensor and restart if needed

* Apply reset listener logic to other hardware sensors

* Review comments
2022-11-09 16:14:49 -05:00
Daniel Shokouhi affc60178e
Add daily floors sensor for Wear OS3 devices (#3005)
* Add daily floors sensor for Wear OS3 devices

* Do a compatibility check for sensor availability in health services

* Print more logs and attempt to send latest data, update more getAvailableSensor methods

* Process review comments

* Process more review comments, use actual time in millis

* Clear out available sensors when updating with new list

* Log the capabilities in case we need to troubleshoot later

* Review comment

* Missed one additional review comment

* Return immediately instead of storing a list
2022-11-09 16:12:13 -05:00
Daniel Shokouhi 8a50f0d048
Revert reorderable bump until upstream issue is fixed (#3035) 2022-11-03 17:40:35 +00:00
dependabot[bot] 38ea6e8dcd
Bump accompanist-appcompat-theme from 0.25.1 to 0.27.0 (#2997)
Bumps [accompanist-appcompat-theme](https://github.com/google/accompanist) from 0.25.1 to 0.27.0.
- [Release notes](https://github.com/google/accompanist/releases)
- [Commits](https://github.com/google/accompanist/compare/v0.25.1...v0.27.0)

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

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

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-11-03 16:48:18 +00:00
Daniel Shokouhi c89184bf31
Bump and switch to compose BOM dependency (#3028)
* Bump and switch to compose BOM dependency

* Bump kotlin and compose extensions
2022-11-03 12:31:35 -04:00
Joris Pelgröm 150f919a1b
Don't log full exception with no Wear app installed (#3031)
- If no Wear app is installed on a device, checking for nodes will throw an exception that the API is unavailable. This is an expected error, don't log it to not confuse users.
2022-11-03 12:30:31 -04:00
Joris Pelgröm 2b445ca03c
Increase notification video attachment GIF length (#3027)
- Increase the length of the GIF created for video attachments in notifications as the Android 13 bug that limited this has been resolved
2022-11-03 12:29:42 -04:00
Joris Pelgröm 0e3d50960f
Catch Geocoder exceptions on Android 13 (#3021)
- Switch from Error to Exception on errors which will be caught
2022-11-03 12:28:02 -04:00
Joris Pelgröm c57b80b978
Only use internal URL when data is also using Wi-Fi (#3015) 2022-11-03 12:27:23 -04:00
Daniel Shokouhi 66bc26037c
Update change log 10/28 (#3013)
* Update change log for recent commits

* Revert "Update change log for recent commits"

This reverts commit 33914d6e36f6fa77e0639c08763145d362c01299.

* Update change log week of 10/28
2022-10-28 19:37:06 -07:00
dependabot[bot] 35dd73966e
Bump reorderable from 0.9.2 to 0.9.4 (#3007)
Bumps [reorderable](https://github.com/aclassen/ComposeReorderable) from 0.9.2 to 0.9.4.
- [Release notes](https://github.com/aclassen/ComposeReorderable/releases)
- [Commits](https://github.com/aclassen/ComposeReorderable/compare/0.9.2...0.9.4)

---
updated-dependencies:
- dependency-name: org.burnoutcrew.composereorderable:reorderable
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

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

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-10-28 13:22:17 -04:00
Tiger Oakes 3f9b01affa
Remove unused setters (#3002) 2022-10-28 13:20:29 -04:00
Daniel Shokouhi 4ae3494c66
Bump play services location tracking and move away from deprecated methods (#2999)
* Bump play services location tracking and move away from deprecated methods

* Restore comments
2022-10-25 21:52:01 +00:00
dependabot[bot] 8779bd0485
Bump sentry-android from 6.5.0 to 6.6.0 (#2998)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 6.5.0 to 6.6.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.5.0...6.6.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>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-10-25 21:27:18 +00:00
Justin Bassett fa001ffc29
Remove dependency that caused beta to fail to publish. (#2991) 2022-10-25 17:11:17 -04:00
Joris Pelgröm a64565108b
Revert/set force dark again for webview (#2989) 2022-10-25 17:10:51 -04:00
Tyler Carberry a0c149ad55
Fix navigation bar color on OnboardingActivity (#2988) 2022-10-25 17:09:06 -04:00
Joris Pelgröm 326ab94652
Make more onboarding screens scrollable (#2987)
- Fixes not being able to continue as the buttons are off screen
2022-10-25 17:08:38 -04:00
Tiger Oakes 993012f9dd
Convert Play tasks to coroutines (#2962)
* Convert tasks to coroutines

* Fix lint issues

* fullImplementation
2022-10-25 17:07:19 -04:00
Dmitry Tsyrulnikov 90a0aca2c0
Improve monochrome icon (#2980)
* Improve monochrome icon

* Include updated icon

* Remove debug version of the icon
2022-10-23 16:07:00 -04:00
Daniel Shokouhi 58bd438efc
Change log 10/21 (#2983)
* Update change log for week of 10/21

* Add data roaming breaking change fix

* Update per recent merges

* Mention breaking change for command_bluetooth on android 13+ devices
2022-10-21 11:49:48 -07:00
Daniel Shokouhi c95725f767
Add more Wear OS sensors (#2981)
* Add more Wear OS sensors

* Update description for how sensors update, also update the type
2022-10-21 18:19:41 +00:00
Joris Pelgröm 760aca4fa1
Tweak onboarding design to be more unified (#2979) 2022-10-21 14:01:05 -04:00
Joris Pelgröm e637b423f2
Support zone name only location tracking (#2969)
* Support zone name only location tracking

* Update strings to match iOS

* Only add Sent location setting on supported versions

* String updates

* Simplify code as the setting is always on
2022-10-21 13:59:02 -04:00
dependabot[bot] bd26435eb8
Bump community-material-typeface from 6.4.95.0-kotlin to 7.0.96.0-kotlin (#2944)
* Bump community-material-typeface from 6.4.95.0-kotlin to 7.0.96.0-kotlin

Bumps [community-material-typeface](https://github.com/mikepenz/Android-Iconics) from 6.4.95.0-kotlin to 7.0.96.0-kotlin.
- [Release notes](https://github.com/mikepenz/Android-Iconics/releases)
- [Changelog](https://github.com/mikepenz/Android-Iconics/blob/develop/gradle-release.gradle)
- [Commits](https://github.com/mikepenz/Android-Iconics/commits)

---
updated-dependencies:
- dependency-name: com.mikepenz:community-material-typeface
  dependency-type: direct:production
  update-type: version-update:semver-major
...

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

* Rename text-to-speech to microphone-message

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>
Co-authored-by: Justin Bassett <bassett.justint@gmail.com>
2022-10-21 17:57:15 +00:00
dependabot[bot] fa095a8bb2
Bump iconics-core from 5.3.4 to 5.4.0 (#2945)
Bumps [iconics-core](https://github.com/mikepenz/Android-Iconics) from 5.3.4 to 5.4.0.
- [Release notes](https://github.com/mikepenz/Android-Iconics/releases)
- [Changelog](https://github.com/mikepenz/Android-Iconics/blob/develop/gradle-release.gradle)
- [Commits](https://github.com/mikepenz/Android-Iconics/compare/v5.3.4...v5.4.0)

---
updated-dependencies:
- dependency-name: com.mikepenz:iconics-core
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

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

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-10-21 17:56:36 +00:00
dependabot[bot] 1d3e8d67e9
Bump iconics-compose from 5.3.4 to 5.4.0 (#2943)
Bumps [iconics-compose](https://github.com/mikepenz/Android-Iconics) from 5.3.4 to 5.4.0.
- [Release notes](https://github.com/mikepenz/Android-Iconics/releases)
- [Changelog](https://github.com/mikepenz/Android-Iconics/blob/develop/gradle-release.gradle)
- [Commits](https://github.com/mikepenz/Android-Iconics/compare/v5.3.4...v5.4.0)

---
updated-dependencies:
- dependency-name: com.mikepenz:iconics-compose
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

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

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-10-21 13:42:10 -04:00
RoboMagus 1f226a71fe
Settings activity app lock (#2926)
* Extract app lock timout functionality from WebViewActivity

* Add app lock authentication to SettingsActivity.
Handle enabling app lock setting authentication in SettingsActivity to avoid callback clash.

* Add blurview to SettingsActivity when app is locked

* Increase blur radius: 5px seems small enough to have text still somewhat legible

* Cleanup

* Cache appLock state for use in touch listeners

* Review rework

* Add onWindowFocusChanged to settingsActivity to check for authentication

* Cleanup SessionExpireMillis functions

* Fix logging formats

* Cleanup debug logging in onResume / onWindowFocusChanged handlers

* Linter fix

* Test SettingsActivity blurview without explicit background

* Improve isAppLocked() debug logging

* Increase applock grace period

* Fix setLockAuthenticationResult return value

* remove authentication from onResume. Perform only onWindowFocusChanged.

* Prevent double authentication prompt when enabling app lock

* Fix missing NotificationManagerCompat import
2022-10-21 13:41:24 -04:00
Daniel Shokouhi 07845fb797
Breaking Change: Fix mobile data roaming sensor after target SDK change (#2978)
Fix mobile data roaming sensor after target SDK change
2022-10-19 21:06:27 -04:00
Joris Pelgröm acd8d2d660
Improve settings when using Home Assistant Cloud (#2965)
* Save cloud URL separately and add pref

 - Save the cloud / remote UI url that is received during registration separately, and add a preference to use the cloud url instead of the external url
 - Save the cloud / remote UI url and cloudhook url received during webhook config updates, to be able to support using cloud after the app was set up
 - Clean up cloudhook url when logging out

* Add UI for "Use Home Assistant Cloud" url

* Cleanup

* Fix function order
2022-10-19 14:53:01 -04:00
Daniel Shokouhi 3e72f2719d
Fix permission requests for beacon monitor (#2964)
* Fix permission requests for beacon monitor

* Remove unneeded permission

* Adjust remaining BT permission issues
2022-10-19 14:51:21 -04:00
Daniel Shokouhi 865c911cb0
Add a screen off timeout sensor and command for control (#2960) 2022-10-19 14:50:25 -04:00
Joris Pelgröm 47e8957a92
Update deprecated onBackPressed, support predictive back gesture (#2959)
- Update onBackPressed functions which have been deprecated to use the new OnBackPressedDispatcher and OnBackPressedCallback
 - Indicate support for the predictive back gesture
2022-10-19 14:49:49 -04:00
Joris Pelgröm 51f9a3fe68
Don't use a hardcoded list of apps for Wear OS detection (#2958) 2022-10-19 14:49:12 -04:00
Joris Pelgröm 0ea8821193
Update filter in Manage Sensors to all/enabled/disabled (#2950)
* Update filter in Manage Sensors to all/enabled/disabled

* Cleanup when (enums are exhaustive)
2022-10-19 14:47:23 -04:00
Joris Pelgröm dd800d00ea
Use compressed entity changes for device controls (#2942)
* Use compressed entity changes for device controls

 - Add support for the subscribe_entities websocket subscription which delivers initial state + changes in a compressed format to reduce data usage
 - Use the new subscribe_entities format in device controls on supported Home Assistant versions

* Less duplicate code
2022-10-19 14:47:10 -04:00
RoboMagus 983dbd58e4
Add notify command for app-lock (#2868)
* Add notify command for app-lock

* Add null check for optional parameters

* Only allow enabling app_lock by notify command if previously enabled by user

* Use constants for app lock command parameters

* Add BiometricManager check before turning on app_lock

* Remove 'hasLockEverBeenEnabled' in favor of only biometricmanager check.

* Improved value checking for app lock command. 
Made setAppLock function suspending i.s.o. sepearate runBlocking calls.

* Show notification if no parameters were updated.

* improved parameter value checking

* Don't make changes when invalid data is provided

* Early check on argument validity for app lock commands

* Cleanup app lock command parameter validation
2022-10-19 14:45:22 -04:00
Joris Pelgröm 4a9dd8ba04
Android 13 notification changes + target (#2682)
* Request notification permission during onboarding

 - When using Android 13 or the minimal version, add a screen to onboarding to request to enable notifications on the device. This screen is based on iOS onboarding. When tapping Continue, on Android 13 this requests the system permission and/or on the minimal version this changes the websocket setting.
 - Compile with and target SDK 33 (targeting required to be able to request notification system permission on demand)

* Add notification settings link in settings when off

 - Show a new setting in settings for the user to enable notifications for the Home Assistant app, either because the permission was denied (Android 13) or the user manually turned off all notifications (Android 8-12).
 - This new setting replaces the notification channels setting when everything is off; in this case there is no point managing individual channels. If at least one channel is on, the existing notification channels setting is shown instead.

* Compose tweaks

 - Remove redundant content description for icon
 - Change to a simpler scroll modifier

* Fix skipping notifications on minimal version

 - Ensure that the value is actually saved to the database

* Post Bluetooth on/off commands as if invalid

 - When using Android 13, post notification commands to control Bluetooth on/off as a normal notification as if they were invalid, as the function has been deprecated for the app

* Remove type that can be inferred
2022-10-19 14:43:15 -04:00
dependabot[bot] 72681ca632
Bump sentry-android from 6.4.3 to 6.5.0 (#2963)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 6.4.3 to 6.5.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.4.3...6.5.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>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-10-11 13:04:07 -04:00
dependabot[bot] 0b6a934607
Bump sentry-android from 6.4.2 to 6.4.3 (#2953)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 6.4.2 to 6.4.3.
- [Release notes](https://github.com/getsentry/sentry-java/releases)
- [Changelog](https://github.com/getsentry/sentry-java/blob/6.4.3/CHANGELOG.md)
- [Commits](https://github.com/getsentry/sentry-java/compare/6.4.2...6.4.3)

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

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

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-10-10 10:36:28 -04:00
Daniel Shokouhi 93844ffea0
Add pixel watch companion to list of Wear OS apps (#2957) 2022-10-07 14:21:56 -04:00
Daniel Shokouhi ddce1ca1b3
Set the media player widget icon if available, otherwise default to cast icon (#2940)
* Set the media player widget icon if available, otherwise default to cast icon

* Use icon directly per review comment
2022-10-04 08:34:40 -04:00
Daniel Shokouhi e4e414d5b4
Update change log week of 10/1 for beta (#2938)
* Update change log week of 10/1 for beta

* Add back changes so they are not missed during weekly beta

* Separate release blocks
2022-10-01 14:42:19 -07:00
Justin Bassett 1adc33bf61
Bump Hilt version to 2.44 (#2939)
Bump hilt version to 2.44
2022-10-01 17:12:32 -04:00
Daniel Shokouhi 48f2ca3125
Default to app icon if icon is not available for notification (#2936) 2022-10-01 16:15:24 -04:00
Joris Pelgröm abf0220430
Update Gradle to 7.5.1, Android Gradle plugin to 7.3.0 (#2934)
- Update Gradle to latest version (7.5.1)
 - Update Android Gradle plugin to latest version (7.3.0)
 - Move package property out of manifest into gradle build files namespace as recommended
2022-10-01 16:14:45 -04:00
Chris Kemp 203e6868d1
Add new force_on and force_off options to command_high_accuracy_mode. (#2924) 2022-10-01 16:12:44 -04:00
Joris Pelgröm c2937e77aa
Simplify themes (#2923)
* Merge Follow Home Assistant/Follow System Settings theme

 - As these two themes behave the same now, don't present two options but instead just one. The default setting has been renamed back to "Follow System Settings" to best match expectations. Internally the "android" setting still works, settings will show "Not set".

* Remove useless webview force dark

 - The WebView force dark settings are no longer required (and will no longer be supported when targeting Android 13), as the latest appcompat/webview/HA frontend already respect the app's theme setting and allow overriding it
2022-10-01 16:11:31 -04:00
Daniel Shokouhi 60aadc906a
Show custom icon if set for the entity in device controls (#2922)
* Add support for showing custom icons in device controls

* Clean up and set color based on state

* Set icon size and adjust colors based on domain

* Move color values to resources and add more color options from source

* Review comments

* Only set the icon if it exists in the library
2022-10-01 16:10:52 -04:00
Daniel Shokouhi 1a5776371e
Add commands to control screen brightness and a sensor to get its value (#2894)
* Add commands to control screen brightness and a sensor to get the value

* Minor file clean up

* Review comments

* Rename Device Settings to Display Sensors
2022-10-01 16:09:01 -04:00
Daniel Shokouhi 070a839b74
Update iBeacon format to have underscores (#2930)
* Update iBeacon format to have underscores

* Update change log
2022-10-01 19:57:01 +00:00
Daniel Shokouhi 79802c18a8
Update change log week of 10/1 (#2937) 2022-10-01 19:38:03 +00:00
Daniel Shokouhi cabd41e6d5
Breaking Change: Only update geocoded sensor with location if the setting is turned on (#2913)
* Add a setting to control if the geocoded sensor should update with device tracker

* Update strings for settings
2022-09-26 10:55:02 -04:00
Daniel Shokouhi 113582ad2d
Update change log week of 9/24 (#2914) 2022-09-26 10:54:05 -04:00
Daniel Shokouhi fbe300e30b
Breaking Change: Add bluetooth connect permission to beacon monitor to prevent log spam from library (#2920)
Add bluetooth connect permission to beacon monitor to prevent log spam from library
2022-09-26 10:53:42 -04:00
Joris Pelgröm db98a7ced3
Fix BLE monitor new beacon check (#2918) 2022-09-26 10:52:28 -04:00
Daniel Shokouhi e541db2ca8
Only check for beacons if the index is present (#2916)
* Only check for beacons if the index is present

* Remove assert

* Review comment
2022-09-26 10:52:08 -04:00
dependabot[bot] 1449ff5409
Bump sentry-android from 6.4.1 to 6.4.2 (#2898)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 6.4.1 to 6.4.2.
- [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.4.1...6.4.2)

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

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

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-09-24 20:19:34 +00:00
Joris Pelgröm 0222d6b673
Bump Google dependencies (#2910) 2022-09-24 16:04:58 -04:00
Daniel Shokouhi 603e411823
Breaking Change: Add major and minor to UUID for beacon attribute in beacon monitor (#2909)
* Add major and minor to UUID for beacon attribute

* Review comments
2022-09-24 16:04:31 -04:00
Daniel Shokouhi 7c6096634f
Allow custom intents register for categories in case they are required (#2901)
* Allow custom intents register for categories in case they are required

* Update description

* Update string to be more generalized and readable
2022-09-24 16:03:32 -04:00
Daniel Shokouhi 91a4b02500
Change TTS error message and clean up some other strings (#2890) 2022-09-24 16:01:20 -04:00
Daniel Shokouhi 2e19dc4474
Add support for intent scheme URI and deep links in clickAction and actionable notifications (#2888)
* Add support for intent scheme URI in clickAction and actionable notifications

* Add a new prefix for app links in actions

* Rename app link to deep link to be more precise

* Use correct intent prefix

* Take user to the play store if the app is not installed

* Fix taking user to the market if app is missing, remove ability for deep links since we can't get the package name

* Only open the play store if we have an actual package to open to
2022-09-24 16:00:29 -04:00
Daniel Shokouhi 763819746a
Add a dynamic color sensor for accent color (#2884)
* Add a dynamic color sensor for accent color

* Update colors to color to match material design label
2022-09-24 15:56:10 -04:00
Joris Pelgröm 80816df6f5
Add support for using BSSIDs for internal connection (#2883)
* Add support for using BSSIDs for internal connection

 - Add support for entering BSSIDs to use for detecting when the internal connection URL should be used. These are saved like any regular SSID, but contain the prefix "BSSID:".

* Add link to documentation
2022-09-24 15:55:36 -04:00
Daniel Shokouhi 9fa983c6dc
Fix full screen mode for all devices (#2878)
* Fix full screen mode for all devices

* Hide system UI when we regain focus and a video is still full screen

* Revert theme changes

* Remove unneeded line break
2022-09-24 15:54:38 -04:00
Daniel Shokouhi d87781dea4
Breaking Change: Only send notification received event if a notification wants the confirmation (#2899)
* Breaking Change: Only send notification received event if a notification wants the confirmation

* Update change log
2022-09-20 19:48:51 +00:00
Daniel Shokouhi a34487409c
Update change log week of 9/2 (#2842)
* Update change log week of 9/2

* Reduce description as docs also mention the rate limit

* Add more changes from recent merges
2022-09-10 12:33:52 -07:00
Daniel Shokouhi 0ce8cbe871
Add item ID to active notification attributes to keep them unique (#2856) 2022-09-10 15:22:11 -04:00
Joris Pelgröm 6a0ffd82b1
Tweak camera control active state: true if not unavailable (#2871)
- Set the thumbnail template for the camera control to active as long as the camera isn't unavailable and the app was able to download an image, to show the camera image more often and better match the frontend.
2022-09-10 15:18:45 -04:00
Joris Pelgröm 6756e21112
Fix template widgets that render null in websocket subscription (#2866)
Fix widgets that return null in websocket subscription

 - Just like in the preview, null is a valid result and should be handled by the app
2022-09-10 15:18:10 -04:00
Joris Pelgröm a31afb3455
Only subscribe to state changes for added controls (#2864)
- Instead of receiving all state changes when the device controls are open, only receive state changes for entities that were added as controls. This potentially reduces the amount of data used while controls are open.
2022-09-10 15:17:49 -04:00
Joris Pelgröm bdc9094845
Improve adding quick settings tile (#2860)
* Improve adding quick settings tiles

 - Use the new option available on Android 13 to prompt the user to add a tile to the quick settings panel, if a tile wasn't already added
 - Switch Toast to Snackbar
 - Move some logic from the manage tiles view to viewmodel

* Only show subtitle field when supported

 - Setting a tile subtitle is only supported on Android Q+, so don't show the field on versions before that!

* Deeplink into app for tiles that aren't setup

 - Instead of disabling a tile if it isn't setup, if the user is logged in set it up as inactive with the default icon/label and deeplink into the app settings with a notice that it needs to be setup first. This provides a better first use experience, as the user can simply tap it to setup instead of requiring them to manually go to the settings.
2022-09-10 15:16:36 -04:00
dependabot[bot] 2380741a45
Bump jackson-module-kotlin from 2.13.3 to 2.13.4 (#2851)
Bumps [jackson-module-kotlin](https://github.com/FasterXML/jackson-module-kotlin) from 2.13.3 to 2.13.4.
- [Release notes](https://github.com/FasterXML/jackson-module-kotlin/releases)
- [Commits](https://github.com/FasterXML/jackson-module-kotlin/compare/jackson-module-kotlin-2.13.3...jackson-module-kotlin-2.13.4)

---
updated-dependencies:
- dependency-name: com.fasterxml.jackson.module:jackson-module-kotlin
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

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

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-09-05 14:42:26 +00:00
Joris Pelgröm a711c659a4
Update Wear onboarding to always use phone for sign in (#2838)
* Always do Wear onboarding on phone

 - Switch the Wear onboarding to always use the sign in flow on the paired phone, instead of offering the option to sign in completely on the watch.
 - When opening the companion app using the Wear app, immediately link the user to the list of instances or sign in screen.
 - Use standard OAuth flow for devices without companion app installed.
 - Fix type casting of location preference in Wear onboarding result.

* Fix ListenableFuture await import
2022-09-05 10:25:13 -04:00
Daniel Shokouhi dab3640c6b
Fix sensorDao not initialized error after geocoded update (#2772)
* Fix sensorDao not initialized error after geocoded update

* Switch to sending an intent to update the sensor

* Review comments
2022-09-05 10:11:38 -04:00
Adrian Huber d0016e530e
Add Beacon Monitor (#2472)
* Add BLE Beacon Monitoring Sensor

* Fix on/off toggle

* Add on/off commands

* Fix commands

* Add all beacons to attributtes

* Add Kalman Filter

* Improve performance

* More settings

* cleanup

* Fix linter errors

* Update description

* Show monitoring state in sensor

* Add missing permissions

* Fix permissions

* Fix Bluetooth state of Android 12

* Use instance instead of singelton

* Use runBlocking for updateLastSendState

* Use own scope for beacon manager

* Use new notification commands

* fix rebase

* use null instead of empty string

* return if sensor is disabled
2022-09-05 10:07:26 -04:00
dependabot[bot] 647d6c4533
Bump sentry-android from 6.4.0 to 6.4.1 (#2836)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 6.4.0 to 6.4.1.
- [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.4.0...6.4.1)

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

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

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-09-05 10:05:33 -04:00
Joris Pelgröm e31ec2f731
Send external url to Wear discovery (#2839) 2022-09-05 10:05:04 -04:00
leroyboerefijn 3926a04e21
Update companion settings landing page for Wear settings (#2837)
* Update companion settings landing page for Wear settings

* Fix description

* Update text and label
2022-09-05 10:04:26 -04:00
Joris Pelgröm 567e286bfa
Fix media notification command (#2835)
Fix media command

 - Fixes the media command code using 'command' to check if it is included but 'media_command' to do the actual command
2022-09-05 10:00:08 -04:00
Joris Pelgröm c6b36d82bb
Support device controls on locked Android 13 device (#2820)
- Add support for using device controls while the device is locked on Android 13 devices
 - Start compiling with Android 13's SDK to make this possible
2022-09-05 09:58:13 -04:00
Joris Pelgröm 232fbb2b2d
Better state change subscriptions in entity state and media player widgets (#2814)
Implement subscribe_trigger and use it in widgets

 - Implement support for subscribing using subscribe_trigger, currently used to get state changes only for specific entities
 - Change the entity state and media player widgets to use this new subscription instead of subscribing to all state changes, based on the template widget
 - Removed some placeholder code from media player widget
2022-09-05 09:56:44 -04:00
RoboMagus 2cf5a7d215
Option to bypass app lock on home network (#2800)
* Add setting to bypass app lock on home network

* Debug loging to check logic

* Fix logic. Cleanup logging.

* Disable home lock bypass when no home networks are configured.

* Only check for WiFi SSID, not internal URL when evaluating isLockEnabled.

* Fix build error
2022-09-05 09:53:07 -04:00
andyboeh 6b06e0d8a8
Add authentication to widget buttons (#2798) 2022-09-05 09:50:53 -04:00
Daniel Shokouhi 6e647cb436
Only add next subscription if control is not null (#2812)
* Only add next subscription if control is not null

* Add one more null check for control
2022-08-29 20:50:09 -04:00
Aaron Wood cfafffd27f
Remove toast when failing to send notification clear event (#2576) 2022-08-29 20:31:49 -04:00
Joris Pelgröm e30390533d
Don't notify about cancellations in WebsocketManager (#2831)
Don't notify about cancellations in WebSocketManager
2022-08-29 20:27:46 -04:00
Joris Pelgröm af0371fb7b
Fix adding media player widget from settings (#2813)
- Adding a media player widget from settings didn't work because the list used to check that entities have been selected isn't updated immediately, but only on load or in a callback after pinning the widget. To work around this, manually check it before pinning the widget.
2022-08-29 20:26:39 -04:00
Daniel Shokouhi db8913c712
Breaking Change: Add some more attributes to geocoded sensor and check that device supports it (#2809)
* Add some more attributes to geocoded sensor and check that device supports it

* Remove language attribute as it does not supply the expected data

* Combine latitude and longitude into the location attribute again
2022-08-29 20:25:48 -04:00
Joris Pelgröm a995d9410b
Support multiple subscriptions of same type in websocket and use in template widget (#2801)
* Update WebSocketRepository for multiple subscriptions of same type

 - Change the structure of how the websocket repository tracks individual subscriptions to allow subscribing multiple times with the same type, but different data

* Update TemplateWidget to use template subscriptions

 - Instead of depending on entity state changes and refreshing any time there is a change, use the render_template subscription for the template widget to limit the amount of data and power used. To make this possible without too much abstractions, the TemplateWidget no longer implements BaseWidgetProvider.
 - Fix hardcoded "Loading" string

* Handle potential null subscription ID

 - Implements #2795 for changes to tracked subscription ID

* Handle failed subscribing similar to other failures (null)

 - When subscribing fails, return null and don't store an active subscription instead of continuing and returning a flow (which would never emit messages)

* Update manifest
2022-08-29 20:23:48 -04:00
Daniel Shokouhi ebc6b76dda
Update changelog week of 8/19 (#2808)
* Update changelog week of 8/19

* Mention battery power sensor
2022-08-20 08:52:49 -07:00
dependabot[bot] 358854b894
Bump sentry-android from 6.3.1 to 6.4.0 (#2806)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 6.3.1 to 6.4.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.3.1...6.4.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>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-08-19 20:35:11 -04:00
Daniel Shokouhi efdd5272e0
Add exclude recents flag to avoid showing multiple open activities in recents (#2805)
Add exclude recents flag to avoid showing multiple open activities
2022-08-19 20:34:57 -04:00
Daniel Shokouhi da8263dc9c
Only update geocode sensor if accuracy and time are valid, like location updates (#2802) 2022-08-19 20:34:33 -04:00
Daniel Shokouhi ae0f788bb4
Expand the error so its more meaningful (#2794) 2022-08-19 20:30:55 -04:00
dependabot[bot] e7dcdacda0
Bump accompanist-appcompat-theme from 0.25.0 to 0.25.1 (#2787)
Bumps [accompanist-appcompat-theme](https://github.com/google/accompanist) from 0.25.0 to 0.25.1.
- [Release notes](https://github.com/google/accompanist/releases)
- [Commits](https://github.com/google/accompanist/compare/v0.25.0...v0.25.1)

---
updated-dependencies:
- dependency-name: com.google.accompanist:accompanist-appcompat-theme
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

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

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-08-13 20:58:03 -04:00
Daniel Shokouhi 7f5ec402db
Bump some more app dependencies (#2792) 2022-08-13 20:52:34 -04:00
Joris Pelgröm 550c18c6e2
Handle foreground service restrictions for persistent connection (#2790)
* Handle foreground service restrictions for persistent connection

 - When trying to start the WebsocketManager as a foreground service, catch exceptions due to restrictions and show the user a notification to fix it

* Update logging in WebsocketManager
2022-08-13 20:49:55 -04:00
Joris Pelgröm 5e11df521c
Fix opening my.home-assistant.io links (#2780) 2022-08-13 20:38:07 -04:00
Joris Pelgröm 3436f2169d
Use OkHttpClient to download notification videos (#2779)
- Change to the OkHttpClient used elsewhere by the app to download notification videos to resolve problems related to cookies and mTLS authentication. As a result, storing and deleting the file is now handled by the app instead of by the system.
2022-08-13 20:37:26 -04:00
Daniel Shokouhi d3c22cf341
Fix unable to Toast on QS tiles being clicked error (#2776)
* Fix unable to Toast on QS tiles being clicked error

* Review comments
2022-08-13 20:36:32 -04:00
Daniel Shokouhi 03a356f147
Only change channel if variable actually provided (#2773) 2022-08-13 20:33:22 -04:00
Rogue136198 0c9e8ac65f
Improve Notification GIFs (#2657)
* Modify Notification GIF Framerate

Modoify VIDEO_INCREMENT_MICROSECONDS to have notification GIFs generate a frame every 0.5 seconds for a video instead of the current every 2 seconds. This should result in smoother notification animations thus improving the UX

* Increase processingFrames.size

Increase processingFrames.size as increasing the framerate results in the animation ending too soon

* Scale video to a max width of 480 while maintaining video ratio

Notification video width scaled to 480. (1920 / 4) Height will scale accordingly while maintaining video aspect ratio. e.g. 1920x2560 will be scaled to 480x640

Frames are set to every 1 seconds with 5 frames resulting in a 5 second GIF

* Update MessagingManager.kt

Based on research and rapid prototyping under another fork, I've decided that scaling the image to a fixed width and a ratioed height is not going to work. There are issues that need to be resolved which result in the image being cut off and stretched in the notification. 

End result is the only overall change is changing the frame generation from once every 2 seconds to once every 1 second. This has improved the fluidity of notifications but I understand is my own subjective opinion.

This means there is still a potential case where 4K cameras will exceed the size limits of notifications.

* Typo fix

* Re-Implement Scaling to a Constant Width

* Update MessagingManager.kt

* Add logic to not scale videos smaller than specified width and Increase GIF speed (ViewFlipper)

* Tune processing times

Tune processing time to have one frame generated every 0.75s, then frames are played back at 3x speed. This results in 9 seconds of activity being played in 3 seconds.

* Implement Dynamic Frame Count

Dynamic number of frames up to a specified size limit (currently 2.5MB)

* Review Before Merge
2022-08-13 20:33:00 -04:00
Joris Pelgröm 22df320fd9
Use OkHttpClient to download notification images (#2768)
- Change to the OkHttpClient used elsewhere by the app to download notification images to resolve problems related to cookies and mTLS authentication
2022-08-06 13:03:38 -04:00
Joris Pelgröm 5d5e31e1cf
Update Wear OS companion app packages (#2766) 2022-08-06 13:02:26 -04:00
Daniel Shokouhi cc68946026
Add fragment dependency to resolve settings view model crashes (#2764) 2022-08-05 01:25:19 +00:00
dependabot[bot] ca6c0c505f
Bump hilt-android from 2.42 to 2.43.2 (#2754)
Bumps [hilt-android](https://github.com/google/dagger) from 2.42 to 2.43.2.
- [Release notes](https://github.com/google/dagger/releases)
- [Changelog](https://github.com/google/dagger/blob/master/CHANGELOG.md)
- [Commits](https://github.com/google/dagger/compare/dagger-2.42...dagger-2.43.2)

---
updated-dependencies:
- dependency-name: com.google.dagger:hilt-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>
2022-08-04 22:59:49 +00:00
Daniel Shokouhi 06b3dd386f
Update change log for week of 8/3 (#2756) 2022-08-04 15:55:35 -07:00
dependabot[bot] c45618b355
Bump hilt-android-compiler from 2.42 to 2.43.2 (#2755)
Bumps [hilt-android-compiler](https://github.com/google/dagger) from 2.42 to 2.43.2.
- [Release notes](https://github.com/google/dagger/releases)
- [Changelog](https://github.com/google/dagger/blob/master/CHANGELOG.md)
- [Commits](https://github.com/google/dagger/compare/dagger-2.42...dagger-2.43.2)

---
updated-dependencies:
- dependency-name: com.google.dagger:hilt-android-compiler
  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>
2022-08-04 18:24:00 -04:00
dependabot[bot] d4f7f84f1d
Bump sentry-android from 6.3.0 to 6.3.1 (#2759)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 6.3.0 to 6.3.1.
- [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.3.0...6.3.1)

---
updated-dependencies:
- dependency-name: io.sentry:sentry-android
  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>
2022-08-04 18:12:54 -04:00
dependabot[bot] cffb397ffc
Bump accompanist-appcompat-theme from 0.23.1 to 0.25.0 (#2719)
Bumps [accompanist-appcompat-theme](https://github.com/google/accompanist) from 0.23.1 to 0.25.0.
- [Release notes](https://github.com/google/accompanist/releases)
- [Commits](https://github.com/google/accompanist/compare/v0.23.1...v0.25.0)

---
updated-dependencies:
- dependency-name: com.google.accompanist:accompanist-appcompat-theme
  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>
2022-08-04 18:01:39 -04:00
Daniel Shokouhi c717e16afc
Update geocode location sensor with location updates that are sent to HA (#2757)
* Actually update geocoded sensor on location updates we send to HA

* Ensure sensor is updated before checking if we should send the update

* Move update logic to sensor receiver, ensure last sent attributes are updated
2022-08-04 18:00:07 -04:00
Daniel Shokouhi a6341251ea
Add a notification command to stop TTS (#2740) 2022-08-03 18:08:16 -04:00
Daniel Shokouhi 67d77d3b89
Restart location updates if we detect too much time passed since last update (#2732)
* Restart location updates if we detect too much time passed since last update

* Switch to last location received for proper evaluation

* Code review: move variable logic to be inside the condition
2022-08-03 18:07:11 -04:00
Joris Pelgröm 7953f81b95
Fix websocket stays subscribed after widget edit due to multiple instances (#2753)
* Fix websocket stays subscribed after widget edit due to multiple instances

 - When a widget is edited, the system will send a broadcast to _a new instance_ of the widget class. Because there is a websocket connection to keep widgets updated, the new instance of the class should also receive events to unsubscribe.

* Use companion object to prevent unnecessary updates

 - Only actually start listening for updates in one of the instances in order to prevent unnecessary duplicate widget updates
2022-08-03 18:04:50 -04:00
Daniel Shokouhi c543aff9eb
Switch to non-deprecated method to get FCM token during registration resync (#2752) 2022-08-03 18:03:30 -04:00
Daniel Shokouhi d68666dae0
Bump some app dependencies (#2751)
* Bump some phone app dependencies

* Add wear dependencies

* Bump compile SDK in common
2022-08-03 18:03:14 -04:00
Joris Pelgröm bddb3a62dd
Don't include session in backup/transfer (#2747)
- The session data is unique to the device and shouldn't be included in a backup or transfer
 - Add Android 12+ backup rules for Wear OS
2022-08-03 18:02:31 -04:00
Daniel Shokouhi d7aeb582bb
Make sure to fallback to background updates when disable is selected in high accuracy notification (#2746)
* Make sure to fallback to background updates when disable is selected in notification

* Review comment
2022-08-03 18:01:45 -04:00
Daniel Shokouhi db0ddf25c2
Actually check the paired state instead of assuming it for bluetooth connection sensor (#2738)
* Actually check the paired state instead of assuming it

* Ensure the attributes have no duplicates by making the lists distinct

* Actually check for duplicate devices to remove them

* Apply code suggestion

* Revert some changes and remove allowDuplicates per comment
2022-08-03 18:01:21 -04:00
Daniel Shokouhi 8d57290314
Add support for lock domain in QS tiles and other improvements (#2737)
* Add support for lock domain in QS tiles, change tile not setup message to be more precise

* Update dispatcher

* Review comments: Remove not setup from string, only get state if domain is lock when tile is clicked

* Remove duplicate strings
2022-08-03 18:01:13 -04:00
Joris Pelgröm 9fc98e464e
Remove error message on null template (#2735)
* Remove error message on null template

 - Null is a valid value for a template so the app should reflect that instead of suggesting there is an error, which may cause users to start looking in the wrong place.

* Log.e instead of Log.i
2022-08-03 17:59:00 -04:00
Márton Maráz 7f1677a2dd
Fix Last Notification sensor not updating when notification is repeated with the same content (#2734)
Make Sensor::lastSentState and lastSentIcon nullable, set them to null when forceUpdate = true, and make null their default value everywhere.
2022-08-03 17:58:23 -04:00
Daniel Shokouhi 90a9a27e5e
Update changelog for week of 7/21 (#2665)
* Update changelog for week of 7/9

* Add a few more changes

* Update changes for recent merges
2022-07-29 15:16:12 -07:00
Joris Pelgröm c7b4f229ec
Improve discovery reliability for some devices (#2718)
- Some devices (most notably Google Pixels) require manually requesting a multicast lock in order for DNS-SD to work reliably
2022-07-29 17:55:06 -04:00
Daniel Shokouhi d03eb74fa9
Improve logging and error messages during onboarding (#2716)
* Add logging in authentication fragment to print errors

* Expand error messages to contain more useful data

* Add error content to pop-up to provide more data to the user

* Show more descriptive onReceivedError message

* Ensure the correct messages are used

* Add changes from @jpelgrom to only show the error on the expected URL

* Add condition to onReceivedErrror as well
2022-07-29 17:51:44 -04:00
Joris Pelgröm 8ee0e14e12
Support downloading data URIs (#2715)
- Adds support for downloading data URIs
 - Redirect unsupported download requests to the browser (or other app that supports it)
2022-07-29 17:51:04 -04:00
Daniel Shokouhi 285adfa5ce
Allow UUID, Major and Minor to be changed via notification command (#2713)
* Allow UUID, Major and Minor to be achanged via notification command

* Ensure transmitter restarts and attributes are updated upon change
2022-07-29 17:49:38 -04:00
Daniel Shokouhi b7fc9bbcff
Use correct default value for update interval to avoid double registrations on cold start (#2712) 2022-07-29 17:48:35 -04:00
Daniel Shokouhi 4b123ef2cf
Fire an event when a notification is received (#2705)
* Add a tsetting to fire an event when a notification is received

* Add a toast message to visually notify about failure

* Remove setting and toast
2022-07-29 17:47:59 -04:00
Joris Pelgröm 1cf3506d4b
Automatically delete 'stale'/old widgets from database (#2702)
Automatically delete stale widgets from database

 - Automatically removes widgets that are no longer bound to the widget provider but that are still in the database -> 'stale'/old widgets will no longer cause unnecessary updates
2022-07-29 17:46:02 -04:00
Joris Pelgröm 2e7c72456c
Remove external storage permission for logs, completely on Android 10+ (#2691)
- Removes the external storage permission for logs for devices on Android 6+, because the external cache dir is usable without this permission and it will no longer work when targeting Android 13 on Android 13 devices. It should work on Android 4.4 and above but this bug suggests it might not on Android 5, but it is auto-granted and needed for downloads anyway: https://issuetracker.google.com/issues/37013142.
 - Set the maximum version for the external storage permission to Android 9; starting with Android 10 the download manager will use MediaStore.Downloads which doesn't require any additional permissions.
2022-07-29 17:44:31 -04:00
leroyboerefijn e7a926396d
Implement html styling on the template tile (#2653)
* Implement styling on the template tyle

* Also process preview in phone settings

* Small cleanup

* Improve template null handling

* Update template rendering error

* Update help text to indicate new line and markup options

* Also support newline

* More extensive replacement for <br>
2022-07-29 17:42:17 -04:00
dependabot[bot] f9ceeb0d65
Bump sentry-android from 6.2.1 to 6.3.0 (#2693)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 6.2.1 to 6.3.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.2.1...6.3.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>
2022-07-21 20:51:59 -04:00
Daniel Shokouhi fca56364b6
Add channel, category and group to notification sensor attributes (#2676)
* Add channel, category and group to notification sensor attributes

* Review comments
2022-07-21 20:42:44 -04:00
Daniel Shokouhi 33f6673e61
Minor location update fixes (#2670)
* Minor location update fixes

* Remove delay and use a new location intent for high accuracy updates to avoid a conflict
2022-07-21 20:41:08 -04:00
Daniel Shokouhi d072b90843
Breaking Change: Add friendly BT name next to the mac address if we have it (#2697)
* Breaking Change: Add friendly BT name next to the mac address if we have it

* Only add the name if we have it
2022-07-21 20:39:14 -04:00
Joris Pelgröm f4eea70b2c
Deprecate Android WebView quick bar gesture support (#2690)
* Deprecate WebView quick bar gesture in code

* Clarify 'up to' to exclude the mentioned version
2022-07-21 20:38:41 -04:00
dependabot[bot] f8d0d46124
Bump kotlinx-coroutines-play-services from 1.6.3 to 1.6.4 (#2685)
Bumps [kotlinx-coroutines-play-services](https://github.com/Kotlin/kotlinx.coroutines) from 1.6.3 to 1.6.4.
- [Release notes](https://github.com/Kotlin/kotlinx.coroutines/releases)
- [Changelog](https://github.com/Kotlin/kotlinx.coroutines/blob/master/CHANGES.md)
- [Commits](https://github.com/Kotlin/kotlinx.coroutines/compare/1.6.3...1.6.4)

---
updated-dependencies:
- dependency-name: org.jetbrains.kotlinx:kotlinx-coroutines-play-services
  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>
2022-07-17 03:42:40 +00:00
dependabot[bot] 41f6045557
Bump kotlinx-coroutines-android from 1.6.3 to 1.6.4 (#2678)
Bumps [kotlinx-coroutines-android](https://github.com/Kotlin/kotlinx.coroutines) from 1.6.3 to 1.6.4.
- [Release notes](https://github.com/Kotlin/kotlinx.coroutines/releases)
- [Changelog](https://github.com/Kotlin/kotlinx.coroutines/blob/master/CHANGES.md)
- [Commits](https://github.com/Kotlin/kotlinx.coroutines/compare/1.6.3...1.6.4)

---
updated-dependencies:
- dependency-name: org.jetbrains.kotlinx:kotlinx-coroutines-android
  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>
2022-07-17 03:32:15 +00:00
dependabot[bot] a67b2014f9
Bump kotlinx-coroutines-core from 1.6.3 to 1.6.4 (#2677)
Bumps [kotlinx-coroutines-core](https://github.com/Kotlin/kotlinx.coroutines) from 1.6.3 to 1.6.4.
- [Release notes](https://github.com/Kotlin/kotlinx.coroutines/releases)
- [Changelog](https://github.com/Kotlin/kotlinx.coroutines/blob/master/CHANGES.md)
- [Commits](https://github.com/Kotlin/kotlinx.coroutines/compare/1.6.3...1.6.4)

---
updated-dependencies:
- dependency-name: org.jetbrains.kotlinx:kotlinx-coroutines-core
  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>
2022-07-16 23:24:38 -04:00
dependabot[bot] 0503214079
Bump sentry-android from 6.1.4 to 6.2.1 (#2672)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 6.1.4 to 6.2.1.
- [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.1.4...6.2.1)

---
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>
2022-07-16 23:24:21 -04:00
Joris Pelgröm 0e0994de7f
Add camera device control (#2663)
* Add camera device control

 - Adds a camera device control on supported devices (12+)
 - Update content description for camera widget

* Improve Icon if downloading thumbnail fails

 - Show a blank grey thumbnail like an empty tile if downloading the camera thumbnail fails, because the system will stretch the provided image so a 'proper' icon can end up looking weird

* Improve error handling
2022-07-09 15:29:47 -04:00
Joris Pelgröm 9474675a88
Migrate SSID dialog to Compose, move + rename prioritize internal (#2662)
* Migrate SSID dialog to Compose, move + rename prioritize internal

 - Replaces the SSID dialog with a new screen built with Compose (same functionality as before)
 - Move the prioritize internal setting to the new SSID screen where it makes more sense, and rename it + style it as a dropdown to prevent unnecessary changes

* Remove unused Spacer
2022-07-09 15:26:56 -04:00
Daniel Shokouhi 0883ada422
Update changelog for week of 7/1 (#2652)
* Update changelog for week of 7/1

* Add wear OS changes to changelog

* Split Wear OS changes to its own section
2022-07-01 10:53:10 -07:00
dependabot[bot] a3e9a62e6a
Bump sentry-android from 6.1.3 to 6.1.4 (#2645)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 6.1.3 to 6.1.4.
- [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.1.3...6.1.4)

---
updated-dependencies:
- dependency-name: io.sentry:sentry-android
  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>
2022-06-30 21:59:41 -04:00
Joris Pelgröm 0fe14ca8a2
Fix editing service button widget shows/creates incorrect field values (#2651)
* Fix button widget field data overwrite on text change

 - The text changed listener might be called while the button widget fields were being setup if a value exists. If other fields are bound at the same time this might overwrite their values and cause problems, so make sure to use the adapter position for the viewholder instead.
 - If setting a value fails set the text input to empty instead of showing the previous value

* Fix incorrect input in button widget fields

 - Properly set the hint for the button widget fields to null if no hint is available to prevent an old hint from being visible
 - Properly set the autocomplete functionality to null if no autocomplete functionality is expected to prevent unwanted autocompletion

* Fix services list if service was previously selected

 - Always load the full services list, even if a service was previously selected, and apply a filter on the list after setting it to prevent the dropdown from showing incorrect values
2022-06-30 21:59:28 -04:00
Joris Pelgröm d13e6068f1
Fix background crash due to button widgets without size (#2649) 2022-06-30 21:58:54 -04:00
Joris Pelgröm 7b401abddc
Don't complete onboarding on registration error (#2646)
- Add specific error if the app encounters a HTTP 404 response during onboarding registration, because that means the mobile_app integration is missing
 - After an error, clean up the session data to make sure a new registration attempt is made
2022-06-30 21:58:24 -04:00
Joris Pelgröm aa256676c4
Show entity state on chip background (#2634)
* Show entity state on entity chip in Wear OS app

 - Shows the color and position of an entity state on the entity's chip in the Wear OS app by using a custom background class that accepts more than a single Color

* Use horizontal instead of diagonal gradients

 - The default BrushPainter actually isn't the correct one, the ToggleChip class uses its own but that is marked as internal and we cannot override the default BrushPainter so another copied class it is

* RTL entity position support

 - When using an RTL language, the entity chip should fill in the position value from the right side

* Support cover position

 - Show cover position as entity chip's background
 - Adjust background color code to also work when a chip isn't checked for covers that are currently closing

* Cleanup EntityUi

* Cleanup duplicate code in device controls

* Naming conventions

 - Should've used a lowercase letter to start
 - Fix class

* Fix build

 - Updates because ToggleChipColors has changed
 - Add workaround for implementing Compose interface because kotlin-gradle-plugin is linked to stable Compose and we cannot update yet

* Update gradient values to match rc02

 - Wear Compose 1.0.0-rc02 changed the default values for the gradients in ToggleChips, so update the values used when using a custom background to match
2022-06-30 21:56:38 -04:00
dimitri bf5a983be2
TLS Client Authentication Support (#2526)
* Rebasing First TLS Client (MTLS) implemention onto upstream's master

* Removed commented code

* First Client TLS implementation rebased with upstream's masster

* Removed redundant semicolon

* Added try/catch to key import, added import feedback to enduser

* ktlint fixes

* Rely on the device Credential store

* Tweaked and cleaned the strings related to the TLS Client Auth message

* Removed commented code

* Attempt to remember the key alias and load it as soon as the app starts

* Cleaned rebase and tidying up code

* Added handler for HTTP error (when a certificate is not provided)

* When no certificate is availble, do the request to get an HTTP error back (for error handling)

* Pleased the linter

* Pleased the linter

* Switched to constructor injection

* Attempt to load the key in a non-blocking fashion.

* Do not loop around the blocking code

* onReceivedClientCertRequest now runs non blocking and the KCAC callback is used instead of polling.

* Wait until the executor task actually completes.

* Cleaned the code

* Removed unused import

* Wait for the executor to finishes executing its task

* During onboarding, if TLS Client Auth is enabled but no certificate is available, correctly report to the user

* Use a safe call on errorResponse

* Do not block anymore

* Removed unused return types

* Removed unused return types and the executor

* Removed unused imports

* Code cleanup

* Improved synchronization

* Added a string for certificate expiration

* Added a function to clear the alias and removed blocking code

* Added a function to clear the alias

* Display an error message if the user certificate is not valid plus minor refactoring

* Check the validity of the selected certificate

* Added an error message if the client certificate is not valid

* Resolved warnings and linting issues

* Fixed broken branch when testing for error condition

* Removed unused imports

Co-authored-by: Mirco Boschi <mircoboschi@gmail.com>
2022-06-30 21:55:23 -04:00
Daniel Shokouhi 44d4d56486
Breaking Change: Switch notification command parameters (#1759) 2022-06-30 21:53:39 -04:00
dependabot[bot] dc785597bd
Bump sentry-android from 6.1.2 to 6.1.3 (#2644)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 6.1.2 to 6.1.3.
- [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.1.2...6.1.3)

---
updated-dependencies:
- dependency-name: io.sentry:sentry-android
  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>
2022-06-26 19:52:56 +00:00
dependabot[bot] a9de8e3f72
Bump iconics-compose from 5.3.3 to 5.3.4 (#2643)
Bumps [iconics-compose](https://github.com/mikepenz/Android-Iconics) from 5.3.3 to 5.3.4.
- [Release notes](https://github.com/mikepenz/Android-Iconics/releases)
- [Changelog](https://github.com/mikepenz/Android-Iconics/blob/develop/gradle-release.gradle)
- [Commits](https://github.com/mikepenz/Android-Iconics/compare/v5.3.3...v5.3.4)

---
updated-dependencies:
- dependency-name: com.mikepenz:iconics-compose
  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>
2022-06-26 15:41:23 -04:00
dependabot[bot] 1efc605c42
Bump kotlinx-coroutines-android from 1.6.2 to 1.6.3 (#2642)
Bumps [kotlinx-coroutines-android](https://github.com/Kotlin/kotlinx.coroutines) from 1.6.2 to 1.6.3.
- [Release notes](https://github.com/Kotlin/kotlinx.coroutines/releases)
- [Changelog](https://github.com/Kotlin/kotlinx.coroutines/blob/master/CHANGES.md)
- [Commits](https://github.com/Kotlin/kotlinx.coroutines/compare/1.6.2...1.6.3)

---
updated-dependencies:
- dependency-name: org.jetbrains.kotlinx:kotlinx-coroutines-android
  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>
2022-06-26 15:41:08 -04:00
dependabot[bot] 1a9a8adfb5
Bump iconics-core from 5.3.3 to 5.3.4 (#2640)
Bumps [iconics-core](https://github.com/mikepenz/Android-Iconics) from 5.3.3 to 5.3.4.
- [Release notes](https://github.com/mikepenz/Android-Iconics/releases)
- [Changelog](https://github.com/mikepenz/Android-Iconics/blob/develop/gradle-release.gradle)
- [Commits](https://github.com/mikepenz/Android-Iconics/compare/v5.3.3...v5.3.4)

---
updated-dependencies:
- dependency-name: com.mikepenz:iconics-core
  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>
2022-06-26 18:33:12 +00:00
dependabot[bot] 641edaf75d
Bump kotlinx-coroutines-core from 1.6.2 to 1.6.3 (#2629)
Bumps [kotlinx-coroutines-core](https://github.com/Kotlin/kotlinx.coroutines) from 1.6.2 to 1.6.3.
- [Release notes](https://github.com/Kotlin/kotlinx.coroutines/releases)
- [Changelog](https://github.com/Kotlin/kotlinx.coroutines/blob/master/CHANGES.md)
- [Commits](https://github.com/Kotlin/kotlinx.coroutines/compare/1.6.2...1.6.3)

---
updated-dependencies:
- dependency-name: org.jetbrains.kotlinx:kotlinx-coroutines-core
  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>
2022-06-26 14:22:08 -04:00
dependabot[bot] 4e7be45823
Bump kotlinx-coroutines-play-services from 1.6.2 to 1.6.3 (#2628)
Bumps [kotlinx-coroutines-play-services](https://github.com/Kotlin/kotlinx.coroutines) from 1.6.2 to 1.6.3.
- [Release notes](https://github.com/Kotlin/kotlinx.coroutines/releases)
- [Changelog](https://github.com/Kotlin/kotlinx.coroutines/blob/master/CHANGES.md)
- [Commits](https://github.com/Kotlin/kotlinx.coroutines/compare/1.6.2...1.6.3)

---
updated-dependencies:
- dependency-name: org.jetbrains.kotlinx:kotlinx-coroutines-play-services
  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>
2022-06-26 14:21:31 -04:00
Márton Maráz d35ce2f16b
Fix Storage sensors to update continuously and display correct size unit (#2638)
* Fix storage sensors to update continuously and do some refactoring in StorageSensorManager

* Fix size unit formatter logic.
So now it can not only output 0GB for smaller values (<1GB) but also 345MB or 640KB for example

* Use String.format(...) for adding thousands separator and replace StringBuilder usage with template
2022-06-26 14:21:10 -04:00
Joris Pelgröm 71b1fe1a00
Speed up device controls/Wear OS loading by doing network async (#2636)
* Speed up loading device controls by running network async

 - Speed up loading the device controls menu and initial controls by launching all requests in an async block, which allows the server to respond out of order
 - For individual controls, only start listening for changes once we have provided initial controls

* Speed up Wear OS cold boot by running network async

 - Speed up a cold boot of the Wear OS app by launching all network requests in an async block, which allows the server to respond out of order
2022-06-26 14:19:24 -04:00
Daniel Shokouhi f91c4691c0
Only apply prioritize internal to WebView when location is disabled on the device (#2635) 2022-06-26 14:17:50 -04:00
Prasad Bankar 12b9e81f9a
Implement a themed app icon (#2371)
* Implement a themed app icon

* Implement a themed app icon
2022-06-26 13:51:04 -04:00
dependabot[bot] 4a59a20d3b
Bump sentry-android from 6.1.0 to 6.1.2 (#2626)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 6.1.0 to 6.1.2.
- [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.1.0...6.1.2)

---
updated-dependencies:
- dependency-name: io.sentry:sentry-android
  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>
2022-06-21 00:37:31 +00:00
Stephen Eisenhauer fe377fcad8
Render widget button icons at higher resolutions (#2625) 2022-06-20 20:18:40 -04:00
Changwoo Ryu f3f00e3fdc
Fix webview restart on keyboard changes (#2622) (#2624)
* The webview activities now handle keyboard|keyboardHidden|navigation
  configuration changes by keyboard connection changes, to avoid the
  activity restart which leads to frontend reload.
2022-06-20 20:16:46 -04:00
Joris Pelgröm 58b69b89be
Don't crash manage widgets screen on duplicate id (#2620) 2022-06-20 20:15:28 -04:00
Daniel Shokouhi 6be2fa3d1b
Update location service dependency (#2611) 2022-06-18 15:29:29 -04:00
dependabot[bot] 74f1609b57
Bump reorderable from 0.9.0 to 0.9.2 (#2617)
Bumps [reorderable](https://github.com/aclassen/ComposeReorderable) from 0.9.0 to 0.9.2.
- [Release notes](https://github.com/aclassen/ComposeReorderable/releases)
- [Commits](https://github.com/aclassen/ComposeReorderable/compare/0.9.0...0.9.2)

---
updated-dependencies:
- dependency-name: org.burnoutcrew.composereorderable:reorderable
  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>
2022-06-18 15:00:02 -04:00
dependabot[bot] fc8adb54d2
Bump sentry-android from 6.0.0 to 6.1.0 (#2614)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 6.0.0 to 6.1.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.0.0...6.1.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>
2022-06-18 14:58:15 -04:00
Daniel Shokouhi f5f2cc66d9
Update changelog 6/14 (#2612) 2022-06-15 10:13:17 -07:00
Joris Pelgröm 38d70e0345
Fix onboarding duplicate fragment on recreation (#2609) 2022-06-14 15:16:42 -04:00
Joris Pelgröm da0903b3c9
Fix settings fragment backstack on recreation (#2610)
Fix settings duplicate fragment on recreation
2022-06-14 15:15:59 -04:00
dependabot[bot] e8fd1760f4
Bump okhttp from 4.9.3 to 4.10.0 (#2608)
Bumps [okhttp](https://github.com/square/okhttp) from 4.9.3 to 4.10.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.9.3...parent-4.10.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>
2022-06-14 13:52:56 +00:00
Joris Pelgröm 1fe299b4a1
Improve service button widget feedback state speed (#2603) 2022-06-14 09:51:20 -04:00
Tiger Oakes c5b021504d
Update delete methods in daos (#2593)
* Update delete methods in daos

* Make widgetDao.getAll a suspend function
2022-06-14 09:44:27 -04:00
Daniel Shokouhi 827d20190a
Update changelog for week of 6/9 (#2601) 2022-06-09 15:11:20 +00:00
Daniel Shokouhi 2f588fec2d
Use minimal specific string for home wifi option on persistent connection (#2584)
* Use minimal specific string for home wifi option on persistent connection

* Review comment for consistency
2022-06-09 15:03:13 +00:00
Joris Pelgröm 574623d837
Fix slow service button widgets (#2597)
* Make service button widgets execute calls faster

* Fix service call feedback background border radius
2022-06-09 10:10:01 -04:00
Joris Pelgröm dba77ee825
Use Bluetooth device address for high accuracy mode BT constraint, fixes settings crash (#2591)
* Don't include devices twice in Bluetooth list

 - Don't include Bluetooth devices twice in the devices list when using it for location-related functions. Do allow duplicates for the BT sensor for backwards compatibility.

* Switch high accuracy mode BT constraint to device address

 - Change the Bluetooth device constraint for high accuracy mode for location updates to use the Bluetooth device address instead of the device name to ensure uniqueness + fix crash in sensor settings screen
 - Set padding in Scaffold because lint doesn't seem to like ignoring it

* Migrate high accuracy mode BT constraint names to addresses

 - When enabling the high accuracy mode, make sure that all data for the Bluetooth device constraint is a Bluetooth device address and if not try to match it to a device.
 - Because the database can contain devices that are not currently paired/connected, without changing to a new setting this check always must be executed, which is why it is placed in the function for enabling the high accuracy mode.

* Also show user-friendly labels in sensor settings detail screen

 - Update the sensor settings detail screen to also show a user-friendly label for list settings on the main screen, before opening a dialog. This will use the same function as when the dialog info is populated, which simplifies code.
 - Merge SensorSettingType.LIST with other list types rows in sensor settings detail screen, remove getSettingTranslatedEntry in viewmodel which is no longer necessary.

* Fix empty Bluetooth list setting value when off
2022-06-09 10:00:05 -04:00
Joris Pelgröm 0f0edcf4a9
Bump reorderable and fix/improve design (#2587)
* Bump reorderable and fix breaking changes

* Only include reorderable with full version

* Improve "Wear Favorite Entities" screen design

 - Fix too small touch targets for dragging
 - Fix no background resulting in overlapping text when dragging
 - Update design to standard Material design
 - Re-use Composable for selected and unselected favorite entities
2022-06-09 09:54:53 -04:00
dependabot[bot] ffaf9fa11a
Bump sentry-android from 5.7.4 to 6.0.0 (#2595)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 5.7.4 to 6.0.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/5.7.4...6.0.0)

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

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-06-09 09:54:02 -04:00
Daniel Shokouhi 1190e0a302
Register for the shutdown intent to send 1 final sensor update before device restarts or powers down (#2572) 2022-06-08 09:01:32 -07:00
Daniel Shokouhi 206ea4ba5d
Update google play wear OS screenshots to match demo site functionality (#2583) 2022-06-03 16:35:23 +00:00
Joris Pelgröm db5713839d
Fix crash when notification extras cannot be mapped (#2581)
Fix crash when notification extras contain internal class
2022-06-02 22:16:36 -04:00
Justin Bassett dcfc590458
Fix issues with initing view models. (#2575)
Add missing `@AndroidEntryPoint` annotations.
2022-06-01 20:19:11 -04:00
Joris Pelgröm d95ab887cb
Fix manage tiles screen crash if there are tiles, updating tiles (#2568)
* Fix crash when opening manage tiles screen if there are tiles

* Fix updating existing tiles

* Remove IO thread, not required
2022-06-01 11:34:50 -04:00
Joris Pelgröm f8a3584054
Remove specific jackson-databind dependency (#2567) 2022-06-01 11:34:38 -04:00
Justin Bassett 7e34271e56
Hotfix: Sensor DAO Injection Issues (#2566)
Fix issues with SensorDao.
2022-06-01 11:34:27 -04:00
dependabot[bot] 31ab4e822c
Bump jackson-module-kotlin from 2.13.2 to 2.13.3 (#2562)
Bumps [jackson-module-kotlin](https://github.com/FasterXML/jackson-module-kotlin) from 2.13.2 to 2.13.3.
- [Release notes](https://github.com/FasterXML/jackson-module-kotlin/releases)
- [Commits](https://github.com/FasterXML/jackson-module-kotlin/compare/jackson-module-kotlin-2.13.2...jackson-module-kotlin-2.13.3)

---
updated-dependencies:
- dependency-name: com.fasterxml.jackson.module:jackson-module-kotlin
  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>
2022-05-30 20:42:39 +00:00
dependabot[bot] 9ad8ec3def
Bump sentry-android from 5.7.3 to 5.7.4 (#2563)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 5.7.3 to 5.7.4.
- [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/5.7.3...5.7.4)

---
updated-dependencies:
- dependency-name: io.sentry:sentry-android
  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>
2022-05-30 20:21:24 +00:00
dependabot[bot] 0ef230a29c
Bump jackson-databind from 2.13.2.2 to 2.13.3 (#2561)
Bumps [jackson-databind](https://github.com/FasterXML/jackson) from 2.13.2.2 to 2.13.3.
- [Release notes](https://github.com/FasterXML/jackson/releases)
- [Commits](https://github.com/FasterXML/jackson/commits)

---
updated-dependencies:
- dependency-name: com.fasterxml.jackson.core:jackson-databind
  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>
2022-05-30 20:18:38 +00:00
dependabot[bot] 78150f4fe0
Bump kotlinx-coroutines-android from 1.6.1 to 1.6.2 (#2559)
Bumps [kotlinx-coroutines-android](https://github.com/Kotlin/kotlinx.coroutines) from 1.6.1 to 1.6.2.
- [Release notes](https://github.com/Kotlin/kotlinx.coroutines/releases)
- [Changelog](https://github.com/Kotlin/kotlinx.coroutines/blob/master/CHANGES.md)
- [Commits](https://github.com/Kotlin/kotlinx.coroutines/compare/1.6.1...1.6.2)

---
updated-dependencies:
- dependency-name: org.jetbrains.kotlinx:kotlinx-coroutines-android
  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>
2022-05-30 20:07:31 +00:00
dependabot[bot] f7496e0b0c
Bump kotlinx-coroutines-play-services from 1.6.1 to 1.6.2 (#2558)
Bumps [kotlinx-coroutines-play-services](https://github.com/Kotlin/kotlinx.coroutines) from 1.6.1 to 1.6.2.
- [Release notes](https://github.com/Kotlin/kotlinx.coroutines/releases)
- [Changelog](https://github.com/Kotlin/kotlinx.coroutines/blob/master/CHANGES.md)
- [Commits](https://github.com/Kotlin/kotlinx.coroutines/compare/1.6.1...1.6.2)

---
updated-dependencies:
- dependency-name: org.jetbrains.kotlinx:kotlinx-coroutines-play-services
  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>
2022-05-30 15:56:12 -04:00
dependabot[bot] 82191172c4
Bump kotlinx-coroutines-core from 1.6.1 to 1.6.2 (#2557)
Bumps [kotlinx-coroutines-core](https://github.com/Kotlin/kotlinx.coroutines) from 1.6.1 to 1.6.2.
- [Release notes](https://github.com/Kotlin/kotlinx.coroutines/releases)
- [Changelog](https://github.com/Kotlin/kotlinx.coroutines/blob/master/CHANGES.md)
- [Commits](https://github.com/Kotlin/kotlinx.coroutines/compare/1.6.1...1.6.2)

---
updated-dependencies:
- dependency-name: org.jetbrains.kotlinx:kotlinx-coroutines-core
  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>
2022-05-30 15:56:05 -04:00
Justin Bassett 11868c185c
Dependency bumps. (#2556) 2022-05-30 15:40:54 -04:00
Daniel Shokouhi 400edbd57f
Update change log for week of 5/29 (#2553) 2022-05-30 11:24:52 -07:00
Tiger Oakes f4375e4b72
Add dagger module for daos (#2541)
* Add dagger module for daos

* Update classes in common to inject daos

* Update app view models to use inject

* Use inject with widgets

* Update app activities and fragments to use inject

* Clean up imports

* Make TileExtensions use coroutines
2022-05-30 14:04:26 -04:00
Joris Pelgröm 0094f9163a
Show snackbar if sensor can't be enabled due to permissions (#2549)
- Instead of silently failing, inform the user that a sensor cannot be enabled due to missing permissions and provide a link to change the setting. If possible, name the specific permission that is required.
2022-05-29 11:27:11 -04:00
Joris Pelgröm ea55fdee35
Don't show changelog immediately on new app installs (#2548) 2022-05-29 11:23:21 -04:00
Joris Pelgröm c98b291d30
Sync sensor enabled state with core 2022.6+ (#2547)
* Sync sensor enabled state from app to core

 - Change sensor 'registered' to indicate not registered, registered as disabled or registered as enabled
 - When a sensor is disabled, set it's status as such on core 2022.6 servers
 - In the sensor registration, use the basic sensor details in case there is no info in the database that can be used

* Clean up version check

 - Now that there is a standard function to get the version, re-use it

* Improve which sensors are synced to core

 - Update database migration to reset registration state on db upgrade to make sure the information is correct for all sensors
 - Only sync sensors that are actually available on the device
 - Fix registering all sensors on core <2022.6 on app/core version change
 - Fix unnecessary sensor updates due to location sensors which are never registered always triggering update on core >=2022.6

* Sync sensor enabled state from core to app

  - After pushing app enabled changes to core, if on core 2022.6 check if the enabled state for any of the sensors is different from what is registered in the app and try to update the sensors. This is done by reading the entire config, because otherwise we wouldn't know about sensors that have been enabled and the app already updates all sensors at the same time so no need for tracking individual updates in the sensor update response.
  - Restore getting config using webhooks, because only the webhook config contains information about entity enabled state
  - Add support for opening a specific sensor's settings page, used for the notification when trying to enable a sensor that requires granting (additional) permissions
2022-05-29 11:22:52 -04:00
Tiger Oakes c532b74a94
Update compose items loops to use keys (#2544) 2022-05-29 10:32:20 -04:00
Tiger Oakes 977d367c8b
Update ManageTilesView for performance (#2540)
* Update ManageTilesView for performance

Removes blocking calls and reduces recompositions

* Don't need to double-sort

getEntities is already sorted

* Revert tile entity change

* Fix crash
2022-05-29 10:18:44 -04:00
Jannis Göing b9c1092302
Multiple media players per widget (#2534)
* Update Media Player Widget Preview

* Add support for multiple media players. optionally show media source label

* fix crop of media player widget preview image. avoid unnecessary api call's when finding active media player. add db migrations. add text color to media source label. set default value of showsource to false.

* remove placeholder source for source icon to fix widget preview
2022-05-29 08:57:52 -04:00
Justin Bassett 7b9fb83f1e
Fix build from bad merge. (#2552) 2022-05-29 08:22:46 -04:00
Thomas Sigmund 10f2e0f6b0
Add additional location setting to combine connected BT devices and entering a zone to enable high accuracy mode (#2491) 2022-05-29 07:30:36 -04:00
Tiger Oakes 7b8720963e
Create a WidgetConfigureActivity base class (#2488) 2022-05-29 07:29:12 -04:00
Joris Pelgröm def3b3081f
Better SSL error handling in WebViewActivity (#2535)
- Use unique tags to allow identifying which function receives an error
 - Actually use the onReceivedSslError callback error
 - Also show SSL errors in the external auth callback
2022-05-23 17:39:26 -04:00
Joris Pelgröm a06f96fd4d
Provide Compose preview for Play Store listing screens (#2542)
* Provide Compose preview for Play Store listing screens

* Update previews for onboarding

 - Set theme correctly and show system UI
 - Add variant for dark mode

* Update Wear OS listing image

* Remove specific icon, we can use domain default
2022-05-23 17:13:31 -04:00
Joris Pelgröm cb3471ad6a
Improve time zone sensor state (#2536)
* Improve time zone sensor string

 - Update string to reflect if the time zone is using summer/daylight savings time or not
 - Use the user's language settings instead of always using English

* Keep using English for sensor state
2022-05-23 16:02:41 -04:00
Joris Pelgröm 22ee199bcd
Catch exceptions during app registration (#2533)
- Catch any exceptions thrown during app registration (after webview login) instead of crashing. There should only be a few errors possible here that are not encountered in the webview.
 - Set dialog theme to fix background on API <31
2022-05-23 16:02:12 -04:00
Joris Pelgröm f2ccd8657b
Fix widget settings scrolling with narrow buttons (#2528)
- Set the width of the LazyColumn, which provides the scrollable container for this screen, to the full width of the screen to also allow scrolling the screen when touching on the right of narrow buttons
2022-05-14 14:24:23 -04:00
Joris Pelgröm 954801b73e
Save + show crash stacktrace in app settings logs (#2527) 2022-05-14 14:23:43 -04:00
Joris Pelgröm 658f3638e0
Fix device controls crashing System UI on long press (#2513) 2022-05-14 14:15:09 -04:00
Joris Pelgröm b1e48d5900
Allow setting push notification visibility/sensitivity (#2505) 2022-05-08 13:12:51 -04:00
Daniel Shokouhi b504492f40
BLE Transmit fix blank state and check device supports advertising (#2500)
* Check if device supports BLE transmitter

* Always send a state instead of blank string

* Add attribute if transmitter is supported instead of sensor availability
2022-05-08 13:11:48 -04:00
Joris Pelgröm 66c57d5768
Add theming to widgets: Dynamic color (Material You) and Transparent (#2496)
* Add transparent widgets

 - Add options to the service, entity and template widgets to have a transparent background
 - Register configuration change intent filter for widgets in order to be able to respond to day/night changes (no longer fully automatic due to setting color with int)

* Support Material You dynamic color in widgets

 - In widgets that support theming (day/night or transparent), add an option to use Material You dynamic colors
 - Dynamic colors is now the default widget style for new widgets on devices that support them

* Tweak dynamic color theming

 - Update dynamic color values to better match other themed widgets such as those from Google
 - Remove configuration changed intent receiver for widgets because it is no longer required to get colors

* Add dynamic color theming to media player widget

 - Make the media player widget themeable and add an option to use dynamic colors (transparent doesn't make sense for this layout)

* Fix camera widget background if data cannot be loaded

* Add text size option to template widgets

 - Added an option to set the text size to template widgets to better align with other widget options

* Additional Android 12 widget updates

 - When using the dynamic color theme, also use the new Android 12 widget corner radius
 - Update placeholder values in widgets to match images, and refer to dynamic color XML to provide a better preview on Android 12. Reset values when providing template to match existing behaviour when no widget is found in the database.
 - Update entity state and template widget target size to 2x1 to match preview image
 - Make sure media player album art doesn't extend past corner radius if possible

* Change theme selection to dropdown, text color alignment

 - Change theme selection to use a dropdown menu (Spinner) instead of right-aligned radio buttons on multiple lines
 - Change text color selection to left-align radio buttons
2022-05-08 13:10:58 -04:00
Joris Pelgröm f33743dc14
Fix crash on start app on SDK <26 (#2497)
- Manually specify databind version to fix https://github.com/FasterXML/jackson-databind/issues/3412, as the Kotlin module still depends on the unfixed version and hasn't had a new release yet
2022-05-01 14:32:00 -04:00
Daniel Shokouhi f398d1bb37
Update changelog for week of 4/30 (#2495) 2022-04-30 20:13:14 -07:00
Joris Pelgröm 13a747fdb9
Notification sensors: make arrays and bundles within main bundle readable (#2482)
* Notification sensors: convert extra bundle arrays to lists

 - If the notification extras contain any arrays, convert them to lists because when stringified, this will create a human readable text like "[Message 1, Message 2]" instead of something like "[Ljava.lang.String;@5d099f62"

* Convert BaseBundle arrays to lists as well

 - Include array types that are in the superclass BaseBundle as well when converting values to a list
 - Moved to another function to limit duplicated code

* Map bundles within a notification's bundle as well

 - Also map any bundles we find inside a bundle, or if there is an array of bundles, to make this information readable as well
2022-04-30 07:53:30 -04:00
Joris Pelgröm b418491667
Breaking change: send sensor list attributes as list to server (#2478)
* Breaking change: send sensor list attributes as list to server

 - Send a sensor attribute that is managed by the app as a list, to the server as a list as well instead of a stringified version of a list.

* Fallback to string for lists that include separator

 - To prevent issues where we can't distinguish the list items separator from a value that includes the separator, don't try to convert a value to a list if that is the case but instead use string

* Improve string fallback for lists that include separator

 - Instead of only falling back when a list includes a String with the separator, just use toString() to also support other objects which might include ", " when stringified, such as nested lists

* Store list data as JSON

 - To remove any confusion when sending individual list items, store data as JSON to escape characters if necessary
 - Map Any data in a list that is not any of the specific types to string, for consistency with the same types when not in a list and to prevent JSON serialization issues
2022-04-30 07:47:44 -04:00
Joris Pelgröm d6add75168
Show media player artist/album more often (#2493)
- Also show media player artist if there is only an album artist
 - Also show media player album if there is no artist known
2022-04-30 07:41:17 -04:00
Daniel Shokouhi a4fc7b0a3f
Add a sensor for high accuracy update interval (#2490) 2022-04-30 07:37:54 -04:00
Joris Pelgröm bbaea010bd
Handle individual exceptions while creating device controls better (#2484)
* Ensure current mode is also supported for climate entities

* Don't crash when creating control fails

 - Handle failures while creating a control gracefully: skip controls when showing all available controls, and show an error tile similar to network errors for existing controls
2022-04-30 07:36:38 -04:00
Joris Pelgröm fe0fcf8c54
Fix Wear endlessly loading on no connected devices (#2476)
- Fix the Wear OS settings activity (seemingly) endlessly loading if there are no connected devices, by showing a proper error message for this situation
 - Set title for Toolbar
2022-04-30 07:30:51 -04:00
Tiger Oakes 2384f0f84d
Use enum for sensor setting type (#2469)
* Use enum for sensor setting type

* Clean up type conversions

* Full variant
2022-04-30 07:29:26 -04:00
dependabot[bot] ec6ae4345c
Bump kotlin-stdlib-jdk8 from 1.6.20 to 1.6.21 (#2467)
Bumps [kotlin-stdlib-jdk8](https://github.com/JetBrains/kotlin) from 1.6.20 to 1.6.21.
- [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-jdk8
  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>
2022-04-23 07:34:05 -04:00
dependabot[bot] 129906915a
Bump kotlin-reflect from 1.6.20 to 1.6.21 (#2466)
Bumps [kotlin-reflect](https://github.com/JetBrains/kotlin) from 1.6.20 to 1.6.21.
- [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-reflect
  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>
2022-04-23 07:22:53 -04:00
Tiger Oakes 3309c59bfd
Move SensorDao operations to Transactions (#2447)
* Add setSensorsEnabled helper

* Update SensorDetailViewModel

* Update sensormanager
2022-04-23 07:10:51 -04:00
Joris Pelgröm f4c4d72518
Suggest or highlight current SSID in home SSID dialog (#2457)
- Show a chip suggesting the user to add the SSID of the currently connected network, if not already added to the list of home SSIDs, in the home SSID dialog
  - Change icon for listed SSIDs in home SSID dialog to DKGRAY by default, and only show currently connected SSID icon in accent color
  - Add missing contentDescription for ImageButtons
  - Use correct tint namespace
  - Update deprecated code
2022-04-17 08:48:40 -04:00
Daniel Shokouhi 90b8d03002
Update change log for week of 4/16 (#2461) 2022-04-16 15:01:55 -07:00
dependabot[bot] d3014ba074
Bump sentry-android from 5.7.2 to 5.7.3 (#2459)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 5.7.2 to 5.7.3.
- [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/5.7.2...5.7.3)

---
updated-dependencies:
- dependency-name: io.sentry:sentry-android
  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>
2022-04-14 08:41:32 -04:00
dependabot[bot] 48e0792cf2
Bump kotlinx-coroutines-play-services from 1.6.0 to 1.6.1 (#2454)
Bumps [kotlinx-coroutines-play-services](https://github.com/Kotlin/kotlinx.coroutines) from 1.6.0 to 1.6.1.
- [Release notes](https://github.com/Kotlin/kotlinx.coroutines/releases)
- [Changelog](https://github.com/Kotlin/kotlinx.coroutines/blob/master/CHANGES.md)
- [Commits](https://github.com/Kotlin/kotlinx.coroutines/compare/1.6.0...1.6.1)

---
updated-dependencies:
- dependency-name: org.jetbrains.kotlinx:kotlinx-coroutines-play-services
  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>
2022-04-12 19:49:39 -04:00
dependabot[bot] 04d8980ad0
Bump sentry-android from 5.7.1 to 5.7.2 (#2453)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 5.7.1 to 5.7.2.
- [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/5.7.1...5.7.2)

---
updated-dependencies:
- dependency-name: io.sentry:sentry-android
  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>
2022-04-12 19:37:18 -04:00
dependabot[bot] 9ed331f9e7
Bump kotlinx-coroutines-android from 1.6.0 to 1.6.1 (#2451)
Bumps [kotlinx-coroutines-android](https://github.com/Kotlin/kotlinx.coroutines) from 1.6.0 to 1.6.1.
- [Release notes](https://github.com/Kotlin/kotlinx.coroutines/releases)
- [Changelog](https://github.com/Kotlin/kotlinx.coroutines/blob/master/CHANGES.md)
- [Commits](https://github.com/Kotlin/kotlinx.coroutines/compare/1.6.0...1.6.1)

---
updated-dependencies:
- dependency-name: org.jetbrains.kotlinx:kotlinx-coroutines-android
  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>
2022-04-12 19:18:05 -04:00
dependabot[bot] 484e3127c1
Bump kotlinx-coroutines-core from 1.6.0 to 1.6.1 (#2432)
Bumps [kotlinx-coroutines-core](https://github.com/Kotlin/kotlinx.coroutines) from 1.6.0 to 1.6.1.
- [Release notes](https://github.com/Kotlin/kotlinx.coroutines/releases)
- [Changelog](https://github.com/Kotlin/kotlinx.coroutines/blob/master/CHANGES.md)
- [Commits](https://github.com/Kotlin/kotlinx.coroutines/compare/1.6.0...1.6.1)

---
updated-dependencies:
- dependency-name: org.jetbrains.kotlinx:kotlinx-coroutines-core
  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>
2022-04-12 19:16:56 -04:00
dependabot[bot] 536139ab5e
Bump kotlin-stdlib-jdk8 from 1.6.10 to 1.6.20 (#2427)
Bumps [kotlin-stdlib-jdk8](https://github.com/JetBrains/kotlin) from 1.6.10 to 1.6.20.
- [Release notes](https://github.com/JetBrains/kotlin/releases)
- [Changelog](https://github.com/JetBrains/kotlin/blob/v1.6.20/ChangeLog.md)
- [Commits](https://github.com/JetBrains/kotlin/compare/v1.6.10...v1.6.20)

---
updated-dependencies:
- dependency-name: org.jetbrains.kotlin:kotlin-stdlib-jdk8
  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>
2022-04-12 19:16:41 -04:00
dependabot[bot] 4a54defab6
Bump kotlin-reflect from 1.6.10 to 1.6.20 (#2425)
Bumps [kotlin-reflect](https://github.com/JetBrains/kotlin) from 1.6.10 to 1.6.20.
- [Release notes](https://github.com/JetBrains/kotlin/releases)
- [Changelog](https://github.com/JetBrains/kotlin/blob/v1.6.20/ChangeLog.md)
- [Commits](https://github.com/JetBrains/kotlin/compare/v1.6.10...v1.6.20)

---
updated-dependencies:
- dependency-name: org.jetbrains.kotlin:kotlin-reflect
  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>
2022-04-12 18:44:13 -04:00
Joris Pelgröm 4a5d58053c
Don't load icon dialog resources every time and on main thread (#2450)
- Don't load the icon dialog's icon pack every time the fragment is resumed, it only needs to be loaded once
 - Don't load the icon dialog's icon pack on the main thread, instead load it on the IO thread to prevent blocking the fragment UI thread (as suggested in the loadDrawables function)
 - Clean up @RequiresApi(Build.VERSION_CODES.N_MR1) annotations
2022-04-12 18:41:52 -04:00
Tiger Oakes 93203419a7
Convert HomeAssistantSearcher to LifecycleObserver (#2446) 2022-04-12 18:35:31 -04:00
Nicolas Mowen 06125bde2b
Add persistent websocket connection notification command (#2445)
* Add persistent websocket connection notification command

* Remove unused import

* Catch invalid persistent type

* Start / stop websocket immediately
2022-04-12 18:33:31 -04:00
Joris Pelgröm c4c414f9f4
Breaking change: update user agent and append to webview UA (#2442)
- Include the original webview user agent in the webview to improve compatibility with sites that use user agent sniffing
 - Updates the app's user agent to use the more standard product/version (details) format
2022-04-12 18:31:34 -04:00
Joris Pelgröm 8ce64f5ed6
Convert NFC tags interface to Compose and update design (#2441)
* Convert NFC tags interface to Compose

 - Rebuild the NFC tags interface with Compose instead of multiple fragments, move more functionality to the NfcViewModel
 - Design updates to match other settings screens (white top app bar, additional icons, don't use text inputs for showing data)
 - Update strings for consistency
 - Update Navigation version to latest stable, and remove non-Compose dependency because it is no longer required

* Update NFC trigger example

 - Add slightly more text to explain how to use it as a trigger in the visual automation editor, which most users will use
 - Add an easier example for scanning the tag, and rename the existing example to clarify that it is only for this device

* Add link to tag documentation to top app bar

* Handle NFC turned off

 - Check to see if NFC is actually turned on when the user opens settings, and prompt them to turn it on if required. Also do the same for the tag writing screen because that might be opened directly by the frontend.
 - Update strings to always use 'device' instead of a mix of 'device' and 'phone'

* Add option to change ID written to tag

 - Allow the user to change the ID that is written to the NFC tag when using the 'write tag' button from the app settings, to match frontend and iOS which also allow the user to change the tag ID

* Don't allow setting state outside NfcViewModel

* Simplify device trigger example even further

* Don't duplicate tag data extraction code

* Also convert tag reader activity to Compose

 - Shouldn't be seen in most cases by users
2022-04-12 18:29:57 -04:00
Tiger Oakes 6c64b31f7e
Use collectAsState for SensorDao.getAllFlow (#2423) 2022-04-06 17:52:21 -04:00
Tiger Oakes cd008d9785
Streamline TileDao (#2422)
* Remove unused tileList

* Make TileDao.add a coroutine
2022-04-06 17:49:25 -04:00
Joris Pelgröm 6e8ed81455
Rename Lovelace to Dashboard (#2435)
- Renames Lovelace to Dashboard to follow core 2022.4
 - Remove unused string array that also included Lovelace
2022-04-06 17:44:27 -04:00
dependabot[bot] 7dada2d812
Bump sentry-android from 5.7.0 to 5.7.1 (#2415)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 5.7.0 to 5.7.1.
- [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/5.7.0...5.7.1)

---
updated-dependencies:
- dependency-name: io.sentry:sentry-android
  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>
2022-04-03 08:40:07 -04:00
Tiger Oakes c788901778
Use suspend calls for widget daos (#2410)
* Add base interface for widget entities

* Helper for widget flow -> state

* Refactor ManageWidgetsView to avoid duplicate code and string types

* Switch add/deleteAll to suspend

* Change abstract functions to suspend

* Remove unused imports
2022-04-03 08:35:15 -04:00
Joris Pelgröm c2f0293837
Faster 'Detected Activity' sensor while updating fast (#2420)
- Request an update for the detected activity sensor every minute if the app is currently doing faster sensor updates, instead of every 2 minutes, to try to have an up-to-date recognition value every time the data is sent.
 - Fix inconsistent update behaviour after changing the setting but before restarting when registered for the ACTION_TIME_TICK intent by always checking the setting, and not only when set to 'fast while charging'.
2022-04-03 08:28:27 -04:00
Joris Pelgröm aaef43ae38
Improve Manage sensors list and details screens (#2418)
* Add sticky headers to manage sensors list

 - The list of managers, and for some managers the list of sensors, is getting so long that sticky headers while scrolling is nice to have to quickly see where you are when doing a fast scroll
 - Remove useless sorting of managers, original list is already sorted

* Include manager name in manage sensors search

 - Also match sensors when using the search function in the manage sensors list when their manager's name matches the search query. This will for example allow searching for all audio sensors, or finding high accuracy mode when searching for location.

* Add stateless/fallback/default icons to sensors

 - Add a new stateless icon to sensors that is used as a default/fallback within the UI
 - Add icons for sensors to the main list of sensors, blue like in the frontend when enabled and disabled alpha when disabled
 - Name deviceClass and unitOfMeasurement arguments where used in sensors

* Fix sensor a-z sorting

* Show entity in details screen more like frontend

 - Update the design for the entity details screen to closer match what is shown in the frontend; at the top of the screen there is now a card that mimics the layout of the entity on the (default) dashboard. This includes the icon (no longer text only), name (previously completely absent from this screen) and the state. Enable/disable is now better highlighted.
 - Some technical information was removed, in line with making this page less like a database dump (use dev tools if that's required).

* Show 'None selected' for empty multi-list preferences

* Add info about update frequency to BasicSensor

 - Adds information about the update frequency to a BasicSensor
 - Change design for sensor details to better highlight description, and add a chip that shows current sensor update frequency taking into account app settings and Android version

* Change description on Sensor Update Frequency screen

* Fix description

* Change update type for detected activity sensor

 - This uses a callback on a ~2 minute interval but can be more frequent when other apps are using the API. Worker updates only re-register the callback.

* Revert "Change update type for detected activity sensor"

 - It might be updated faster but doesn't actually send new values any faster
2022-04-03 08:25:01 -04:00
Tiger Oakes 0f26ce3382
Remove blocking calls from HaControls (#2413)
* Launch performAction in a coroutine scope

* Change performAction to suspend function
2022-04-03 08:05:40 -04:00
Daniel Shokouhi e4c069f743
Update changelog for week of 3/25 (#2406) 2022-03-26 13:14:00 -07:00
Julien Ehrhart cfd277e2f7
Correct minimal value for high_accuracy_set_update_interval (#2402)
Fixes #2401
2022-03-25 12:46:03 -04:00
Joris Pelgröm 0623d16142
Fix gesture detection on WebViewActivity (#2396)
* Fix gesture detection on WebViewActivity

 - Add actual gesture detection to the webview instead of pointer detection in order to fix the search box showing up any time 3 fingers are placed on the screen

* Remove nullable min/max velocity

 - These always get a value so there is no need to make them initially nullable

* Cleanup fling detection

* Reduce minimum swipe velocity requirement

* Change direction calculation to average

 - Use the average velocity of all pointers to determine in which direction the user has swiped. The previous implementation used the first/last pointer's angle which isn't necessarily the same pointer.
 - Fix reducing number of pointers when velocity tracker is reset due to an opposing pointer
2022-03-25 12:44:06 -04:00
Daniel Shokouhi 7c05b899b1
Add missing volume streams to sensor and command (#2397)
* Add missing volume streams to sensor and command

* Add more missing volume streams and 1 missing audio mode
2022-03-25 12:09:59 -04:00
Joris Pelgröm 668cc0c73d
Update settings screens styling (#2393)
* Change toolbar/status bar for configuration

 - Change the colors used for the toolbar and status bar for configuration from the blue accent color to a white, to better match the default frontend theme

* Switch to AppCompat SearchView

* Update Wear settings' app bar, up everywhere

 - Update Wear settings' top app bar in the app to also use the white style and activity theme
 - Add up navigation to all screens in Wear settings

* Compose settings design consistency updates

 - When there is a scrollable column, use a scrollable Box instead around that column to make sure the padding is applied to the content instead of the entire scrollable container (which always gives padding at the top/bottom of the screen, even when content is scrolled)
 - Consistently use 16dp for content padding instead of a mix of 16 and 20; 16 matches the other non-Compose settings so let's use that
2022-03-22 20:30:53 -04:00
Joris Pelgröm 965ee61b11
Don't crash on sensor update on on/off/setting change (#2391)
* Don't crash on sensor update on on/off/setting change

* Update logging message, also for Wear OS
2022-03-22 20:17:17 -04:00
Daniel Shokouhi ead6a9377f
Add a command to easily launch an application, or take user to install page (#2390) 2022-03-22 20:16:21 -04:00
Daniel Shokouhi 0d9a1367b5
Fix SIM sensor crash (#2389)
* Fix SIM sensor crash

* Update app/src/main/java/io/homeassistant/companion/android/sensors/PhoneStateSensorManager.kt

Co-authored-by: Justin Bassett <bassett.justint@gmail.com>

* Update app/src/main/java/io/homeassistant/companion/android/sensors/PhoneStateSensorManager.kt

Co-authored-by: Justin Bassett <bassett.justint@gmail.com>

* lint

Co-authored-by: Justin Bassett <bassett.justint@gmail.com>
2022-03-22 20:14:14 -04:00
Richard de Boer 1642e14242
fix headphone sensor: check audio OUTPUT devices, not INPUT (#2388)
Fixes #2387
This probably worked fine with headsets, as those also provide audio input.
2022-03-21 12:54:17 -04:00
chriss158 f80e03aa3b
Fix new line in message (#2385)
* Fix high accuracy mode turns off after turning on with command

* Fix new line replacement in message

* Add comment

* Revert "Fix high accuracy mode turns off after turning on with command"

This reverts commit 4c769bf1b1.
2022-03-20 17:24:36 -04:00
chriss158 e24712dcd9
Fix high accuracy mode turns off after turning on with command (#2383) 2022-03-20 17:19:39 -04:00
dependabot[bot] e29dc0b66f
Bump jackson-module-kotlin from 2.13.1 to 2.13.2 (#2379)
Bumps [jackson-module-kotlin](https://github.com/FasterXML/jackson-module-kotlin) from 2.13.1 to 2.13.2.
- [Release notes](https://github.com/FasterXML/jackson-module-kotlin/releases)
- [Commits](https://github.com/FasterXML/jackson-module-kotlin/compare/jackson-module-kotlin-2.13.1...jackson-module-kotlin-2.13.2)

---
updated-dependencies:
- dependency-name: com.fasterxml.jackson.module:jackson-module-kotlin
  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>
2022-03-19 12:24:48 -04:00
dependabot[bot] 3061791a4d
Bump sentry-android from 5.6.3 to 5.7.0 (#2380)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 5.6.3 to 5.7.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/5.6.3...5.7.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>
2022-03-19 12:12:43 -04:00
dependabot[bot] fa890f7660
Bump android-beacon-library from 2.19.3 to 2.19.4 (#2378)
Bumps [android-beacon-library](https://github.com/AltBeacon/android-beacon-library) from 2.19.3 to 2.19.4.
- [Release notes](https://github.com/AltBeacon/android-beacon-library/releases)
- [Changelog](https://github.com/AltBeacon/android-beacon-library/blob/master/CHANGELOG.md)
- [Commits](https://github.com/AltBeacon/android-beacon-library/commits/2.19.4)

---
updated-dependencies:
- dependency-name: org.altbeacon:android-beacon-library
  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>
2022-03-19 12:09:02 -04:00
Daniel Shokouhi 1351237f9f
Fix widget crash on orientation change and landscape layout fixes (#2377) 2022-03-19 12:08:47 -04:00
Daniel Shokouhi b151f20962
Update changelog for week of 3/11 (#2365)
* Update changelog for week of 3/11

* Updates
2022-03-15 10:29:59 -04:00
Joris Pelgröm b26928bbea
Update Kotlin to 1.6 and Compose to 1.1 (#2372)
* Update Kotlin to 1.6 and Compose to 1.1

 - Remove @ExperimantalComposeUiApi, @ExperimentalWearMaterialApi annotations (because the functions aren't experimental, we are just using an experimental API) and replace with an opt-in declaration at the 'lowest level' usage
 - Websocket: ProducerScope is no longer experimental so the annotation can be completely removed
 - Wear: the animation APIs that are used for the time text are no longer experimental so the annotation can be completely removed

* Update for Compose sensor settings merge
2022-03-15 10:15:14 -04:00
Joris Pelgröm 27514e6df1
Remove internet connectivity requirement for WebsocketManager (#2373)
- Replace the NetworkType.CONNECTED constraint on the job for WebsocketManager with a check that does not take the validation status (= internet access) of the network into account. HA may be accessible without an internet connection.
2022-03-15 09:18:49 -04:00
dependabot[bot] 94a31c52ce
Bump sentry-android from 5.6.2 to 5.6.3 (#2370)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 5.6.2 to 5.6.3.
- [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/5.6.2...5.6.3)

---
updated-dependencies:
- dependency-name: io.sentry:sentry-android
  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>
2022-03-15 09:13:09 -04:00
Joris Pelgröm 3e928bd53d
Migrate "Manage Sensors" to Compose and ViewModels (#2359)
* Replace PreferenceFragment sensors list with Compose

 - Start of migrating the list of sensors and their individual on/off settings to Compose by moving the list over
 - Aims to replicate original design of the page for now

* Rename ViewModel to match view

* Start of sensor detail screen in Compose

 - Add enabled switch and description + permission handling
 - Update main list to use new Compose-based fragment
 - Add new fragments to factory to prevent crash on recreation

* More sensor info to show

 - Add more properties and attributes for the sensor (basically anything that doesn't require a pop-up)
 - Move enabled check with permissions to ViewModel because it also needs to be updated in the database
 - Fix collecting sensor settings

* Add support for sensor settings toggle/text/number

 - Added a framework for setting sensor settings; toggle builds on the existing on/off toggle, and added a MutableState for settings that require the app to show a dialog
 - Support for changing sensor settings that must be toggled
 - Support for changing sensor settings where text or number input is required

* Finish sensor details by adding list-based settings

 - Add support for setting list-based settings
 - Dynamic maximum height for dialog in order to fill most of the screen
 - Remove old fragment and XML since all functionality should now be covered
 - Show translated setting for list settings
 - Fix update of list setting removing the list options in the future, because they were stored in the DB entry but a new entry without any values was created
 - Fix toggle sensor setting (removed the space)

* Tweak single rows with switch and height

 - Don't use two line row height if there is no summary
 - Remove onCheckedChange from Switch so that it is handled by the row
 - Prevent text from getting too close to switch

* UI fixes and tweaks

 - Fix search query still being set when returning to the main sensors list after viewing a sensor's details by clearing the query in the view model if the SearchView is closed
 - Move sorting the sensors for each manager to the UI where the sensors are queried, instead of in an internal variable
 - Set secondary color to allow Switches, RadioButtons and Checkboxes to use the blue HA tint without overriding each one manually
 - Add stable IDs to main sensor list to improve recomposition for search

* Allow selecting some rows in details

* Move dialog popup into a separate file

 - Move the dialog that is used to a separate file because it was already based on a custom dialog for the Manage Widgets screen.
 - Improve max height for dialog by using weight, to make sure it still works correctly for longer titles
 - When using radio button items, don't require the user to press save but instead save it when an item is selected

* Show disabled state for sensor setting rows

* Update unchecked switch thumb colors

 - Google says using the same color as the surface with a minimal shaodw is by design, https://issuetracker.google.com/issues/185418990, but it just results in bad contrast (probably why they switched to a different switch design in Android 12), so manually copied the color code to use

* Also use disabled state for sensor setting row summary

* Fix comment
2022-03-15 08:57:09 -04:00
Daniel Shokouhi bc8765894e
Allow changing high accuracy update interval via command (#2356)
* Allow changing high accuracy update interval via command

* Fix minimal build
2022-03-15 08:35:08 -04:00
Nicolas Mowen 2de5815123
Force resize of video frames instead of compressing (#2362)
* Force resize

* Remove unused import
2022-03-11 07:58:24 -05:00
Daniel Shokouhi 9397d1a565
Hide delete icon on more app created channels (#2354) 2022-03-10 13:59:44 -05:00
Nicolas Mowen 5fc004aa3d
Video notifications max memory (#2353)
* Compress bitmaps to avoid remoteview memory utilization error.

* Cleanup

* Add log helpful for debugging

* Make formatting more consistent with standard notification view

* Switch to only using time based method

* Remove random image

* Fix lint

* Update order of imports
2022-03-10 13:55:50 -05:00
Daniel Shokouhi e3a96d588e
Correctly identify entity category for sensors (#2357) 2022-03-09 08:00:38 -08:00
Daniel Shokouhi 00827d5944
Only skip some reports when high accuracy mode is off (#2347)
* Only skip some reports when high accuracy mode is off

* Use correct function
2022-03-07 21:47:18 -05:00
Nicolas Mowen 508893f02f
FEAT: Ability to show video in notification as a gif (#2342)
* Download mp4 and parse out frames using MediaMetaDataRetriever

* Add view and remote views implementation

* Smoothen out frame selection

* Add constants

* Support all frame rates of video and set frames to show over 2 seconds
2022-03-07 21:42:55 -05:00
Daniel Shokouhi d6f638673a
Add manage notification channels settings screen so users can easily delete channels created by the app (#2340)
* Add a setting screen to easily delete notification channels and edit them

* Minor clean up

* Code review and suggestions

* Code review
2022-03-07 21:41:21 -05:00
Daniel Shokouhi 2a2422b678
Update change log for week of 3/4 (#2338)
* Update change log for week of 3/4

* Changelog update

* Tweak
2022-03-05 21:14:51 -05:00
Daniel Shokouhi d05920d3c3
Check for phone permissions when using call intent (#2344) 2022-03-05 20:00:53 -05:00
Daniel Shokouhi eae2c6e67d
Breaking Change: Make coordinate attributes all lower case for HA compatibility (#2341)
* Make coordinate attributes all lower case for HA compatibility

* Make rest of sensor attributes match expected casing
2022-03-05 19:59:27 -05:00
dependabot[bot] ad57b00bfb
Bump sentry-android from 5.6.1 to 5.6.2 (#2335)
Bumps [sentry-android](https://github.com/getsentry/sentry-java) from 5.6.1 to 5.6.2.
- [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/5.6.1...5.6.2)

---
updated-dependencies:
- dependency-name: io.sentry:sentry-android
  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>
2022-03-05 07:32:27 -05:00
Daniel Shokouhi dda9798713
Add new settings screen to change Sensor Update Frequency (#2317)
* Add option for faster sensor updates, and also while charging

* Move settings to its own view, change logic to store in DB

* Set default value

* Try another way

* Try new default method

* Use correct default

* Clean up

* Review comments

* Remove dependency on is_charging sensor

* Switch to a better condition check per review

* Fix db
2022-03-03 20:19:31 -05:00
Daniel Shokouhi 3d6f50a867
Make sure to remove and start location updates when controlled via command (#2334) 2022-03-03 18:56:30 -05:00
Joris Pelgröm 27b02a0be5
Add fan speed to Wear OS detail panel (#2332)
* Add fan speed detail panel to Wear OS

 - Added a fan speed slider for entities that support setting the fan speed
 - Adjust light brightness string to include percentage symbol

* Rename extension function
2022-03-03 18:55:16 -05:00
Daniel Shokouhi 3de198897d
Changelog update for week of 2/25 (#2320) 2022-02-26 17:55:04 -05:00
dependabot[bot] 3bd019f6f0
Bump accompanist-appcompat-theme from 0.23.0 to 0.23.1 (#2319)
Bumps [accompanist-appcompat-theme](https://github.com/google/accompanist) from 0.23.0 to 0.23.1.
- [Release notes](https://github.com/google/accompanist/releases)
- [Commits](https://github.com/google/accompanist/compare/v0.23.0...v0.23.1)

---
updated-dependencies:
- dependency-name: com.google.accompanist:accompanist-appcompat-theme
  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>
2022-02-26 17:36:45 -05:00
Joris Pelgröm 145f19dc66
Fix refreshing settings after requesting background access (#2324)
- The intent to request that battery optimizations are ignored for the app returns an activity result, not a permissions result. Changed to the correct callback to fix refreshing the setting after accepting/denying.
2022-02-26 17:35:27 -05:00
Joris Pelgröm 72a598fdbe
Add extensions to Entity for domain, lights features (#2322)
* Add extensions to Entity for domain, lights features

 - Add extension property for domain
 - Add extension functions for lights: support for setting brightness and color temperature

* Use domain extension property in more places
2022-02-26 17:34:29 -05:00
SkechyWolf ffeeb4a962
Fix showing null when no attributeIds is present (#2316) 2022-02-26 17:18:20 -05:00
Patrick Decat 1736efc82e
Remove trailing commas and spaces from entity_id for button widgets (#2314) 2022-02-26 17:17:27 -05:00
Daniel Shokouhi d0842ab557
Fix BLE command when enabling or disabling the transmitter (#2313) 2022-02-24 11:14:31 -05:00
Daniel Shokouhi e3bd338bf1
Enhance command_ble_transmitter to change additional options (#2310)
* Enhance command_ble_transmitter to change additional options

* Move strings to constants
2022-02-23 11:35:03 -05:00
Daniel Shokouhi 953374a0ba
Add new option for persistent connection to only connect when on home wifi (#2309)
* Add new option for persistent connection to only connect when on home wifi

* Tweak text to be more understandable
2022-02-23 11:17:47 -05:00
Daniel Shokouhi 87673bc3a9
Allow enabling chrome remote debugging in settings (#2302)
* Allow enabling chrome remote debugging in settings

* Explicitly mention webview debugging
2022-02-23 08:05:51 -05:00
dependabot[bot] 7e3d5aa10d
Bump hilt-android-compiler from 2.40.5 to 2.41 (#2295)
Bumps [hilt-android-compiler](https://github.com/google/dagger) from 2.40.5 to 2.41.
- [Release notes](https://github.com/google/dagger/releases)
- [Changelog](https://github.com/google/dagger/blob/master/CHANGELOG.md)
- [Commits](https://github.com/google/dagger/compare/dagger-2.40.5...dagger-2.41)

---
updated-dependencies:
- dependency-name: com.google.dagger:hilt-android-compiler
  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>
2022-02-19 14:03:01 -05:00
Daniel Shokouhi 72656f5af5
Allow opening notification history from URI action (#2304) 2022-02-19 13:58:48 -05:00
Daniel Shokouhi c70391c0e7
Fix notification receivers for all builds (#2298) 2022-02-19 13:50:26 -05:00
dependabot[bot] 8af88297c1
Bump hilt-android from 2.40.5 to 2.41 (#2293)
Bumps [hilt-android](https://github.com/google/dagger) from 2.40.5 to 2.41.
- [Release notes](https://github.com/google/dagger/releases)
- [Changelog](https://github.com/google/dagger/blob/master/CHANGELOG.md)
- [Commits](https://github.com/google/dagger/compare/dagger-2.40.5...dagger-2.41)

---
updated-dependencies:
- dependency-name: com.google.dagger:hilt-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>
2022-02-19 13:49:40 -05:00
Daniel Shokouhi 23faeac72c
Changelog update for week of 2/16 (#2292) 2022-02-19 13:49:06 -05:00
Daniel Shokouhi 074c8aea43
Clean up old quest flavor code and hide some features from unsupported devices (#2265)
* Clean up old quest flavor code and hide some features from unsupported devices

* Check if device supports telephony for phone sesnors
2022-02-16 23:04:38 -05:00
Daniel Shokouhi 89b091dcfd
Add better icon checks to ensure the value is as expected (#2290) 2022-02-16 22:35:47 -05:00
Daniel Shokouhi 0866d3e93b
Make persistent connection and manage tiles settings screens scrollable (#2283)
* Make persistent connection settings screen scrollable

* Make manage tiles scrollable as well
2022-02-16 22:31:41 -05:00
Joris Pelgröm 09cf216ff1
Remove toast when updating state/camera/template widget fails (#2262)
* Hide toast when updating state/camera/template widget fails

* Change icon to remove cloud/network emphasis

 - The error can also be because the selected entity no longer exists and/or the device failed to handle the response, so use a more generic error while refreshing icon

* Change return type for resolve text to prevent race condition

 - Don't leak widget-specific calls in to a general variable, use a data class in order to be able to return two different data types
2022-02-16 22:27:51 -05:00
dependabot[bot] 2cc8472e62
Bump accompanist-appcompat-theme from 0.20.3 to 0.23.0 (#2255)
Bumps [accompanist-appcompat-theme](https://github.com/google/accompanist) from 0.20.3 to 0.23.0.
- [Release notes](https://github.com/google/accompanist/releases)
- [Commits](https://github.com/google/accompanist/compare/v0.20.3...v0.23.0)

---
updated-dependencies:
- dependency-name: com.google.accompanist:accompanist-appcompat-theme
  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>
2022-02-16 22:21:49 -05:00
Joris Pelgröm 50a74a0365
Allow reconfiguring camera widgets (#2253) 2022-02-16 22:21:25 -05:00
Justin Bassett b137f656d1
Fix build from color issue. (#2291)
* Fix build.

* ktlint
2022-02-16 22:08:26 -05:00
micronen 7eced552ea
Add PinchToZoom option (#2252)
* Add PinchToZoom option

Allow enabling PinchToZoom in WebView via option in preferences

* remove redundant code & update icon

* Add js query to set meta content user-scalable=yes

* Improve js query to filter out values and not hard-code the attributes

* Reset viewport to original string when PinchToZoom is disabled
Update on two events:
1. onPageFinished for 1st time load
2. onResume to update on setting change
2022-02-16 20:48:57 -05:00
Jamie Macdonald 5d9a9df0bb
Add volume up/down buttons on media player widget (#2139) 2022-02-16 20:45:39 -05:00
Timothy Kist e21d095195
Wear OS sensors UI (#2033) 2022-02-16 20:43:23 -05:00