Commit graph

344 commits

Author SHA1 Message Date
Paulus Schoutsen 6c9204bc91
Mention install SDK in README (#860)
* Mention install SDK.

* Update README.md
2020-09-01 10:27:00 -04:00
Justin Bassett 72888cc754
Fix location Spam (#863)
* Reduce/eliminate the number of duplicate location updates.

* Limit accurate location requests to once per minute max.

* Remove some validation code.

* Swap around statements.

* Send location every 15 minutes even if it's the same.
2020-09-01 10:05:30 -04:00
Justin Bassett 44551543bd
Ensure the change-log is short for Google Play (#850) 2020-08-31 12:42:02 -04:00
Daniel Shokouhi 7ffabca380
Add description for each sensor on details screen, only show device class and icon if they are set (#847)
* Add description for each sensor, only show device class and icon if they are set

* Minor cleanup

* Lint

* Switch to better implementation per review comments

* Only use basicSensor since it contains all the data we need
2020-08-30 18:08:53 -04:00
Justin Bassett 4fe2489432
Sentry.io Changes (#846)
* Set the sentry.io release version explicitly.

* Include session tracking to improve crash support.

* ktlint

* Remove comments in build
2020-08-30 15:19:20 -04:00
Piotr Potulski 1d31d8743a
Update instructions for running the project from the scratch (#837)
* Update instructions for running the project from the scratch

* Update README.md

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

Co-authored-by: Justin Bassett <bassett.justint@gmail.com>
2020-08-30 14:46:02 -04:00
Daniel Shokouhi 83c4dbb92c
Add link to companion docs under app configuration (#845)
* Add link to companion docs under app configuration

* Review comments
2020-08-30 08:18:35 -04:00
Justin Bassett de1b8d58d9
More build updates (#844)
* Remove version code from version string.

* Make sure true releases work.

* Beta Sentry.io releases

* Really do Sentry,io Releaes

* Sentry.io releases for production
2020-08-29 18:23:58 -04:00
Anna Tikhomirova 7dde8bba7b
Remove excess calls to setupLocationTracking (#843)
* Remove excess calls to setupLocationTracking

* Remove unused import
2020-08-29 17:02:45 -04:00
Daniel Shokouhi 49aaf1566f
Bump some app dependencies (#842)
* Bump some app dependencies

* Revert appcompat bump

* Revert constraintlayout bump
2020-08-29 16:53:23 -04:00
Basset, Justin f393f3b958 Fix Playstore Publish 2020-08-29 16:33:35 -04:00
Basset, Justin 5760c57856 Broke release actions down further to allow play to use upload cert rather than actual. 2020-08-29 16:14:16 -04:00
Basset, Justin d71a867143 Hotfix build. 2020-08-29 14:30:40 -04:00
Justin Bassett 8647122aca
CI/CD Changes (#828)
* Use new secrets from Github.

* Add support for pre-releases in repo.

* Fork the validate to make PR builds faster!

* More parallel!

* More parallel for real!

* Make sure release notes actually work and add to readme.
2020-08-29 14:26:36 -04:00
Daniel Shokouhi 51a6fa5c0c
Fix location updates in the background (#834) 2020-08-27 17:31:13 -04:00
Daniel Shokouhi e6f2e589d2
Fix geocoded crash, report expected minimum accuracy for location (#832)
* Fix geocoded crash, report minimum accuracy for location

* Lint

* Always log exceptions!

Co-authored-by: Justin Bassett <bassett.justint@gmail.com>
2020-08-27 13:15:58 -04:00
Home Assistant Bot 5ee23a764e
Lokalise: updates (#827) 2020-08-27 00:22:00 -04:00
Justin Bassett 63285c4cc6
Fix requests for accurate location on app open. (#824) 2020-08-26 15:10:12 -04:00
Justin Bassett 63ded1a1d3
Hopefully fix the background location updates randomly stopping. (#816) 2020-08-25 23:23:00 -04:00
Justin Bassett 0a17e8e09b
Sensor Crashes (#819)
* Ensure that location isn't null.

* Ensure a single sensor can't stop the rest.
2020-08-25 23:14:02 -04:00
Daniel Shokouhi 9cae26b771
Add do not disturb sensor (#813)
* Initial commit of DND sensor

* Update sensor name

* Adapt to new sensor model

* Review comments
2020-08-25 23:04:25 -04:00
Daniel Shokouhi a958b0f95c
Use latest context in pressure and proximity sensor (#818) 2020-08-25 22:44:28 -04:00
Justin Bassett c6c35411bc
Fix wakelock error for requesting accurate location. (#815)
* Fix wakelock error for requesting accurate location.

* ktlint
2020-08-25 22:42:40 -04:00
Justin Bassett 41d7d5f82e
Sensor Refactor (#809)
* Persist all sensor data so we can make UI reflect last sent sensor data.

* No value can be null.

* UI now uses database rather than new values.

* Sensors are now async and UI uses entities rather than actually polling sensors.

* Opening sensor ui now causes us to request sensor updates every 10 seconds.

* Fix minimal build.

* Don't just poll the sensors, send updates to HA.
ktlint

* Fix DB migration.

* PR Review Fixes.

* Fix new sensors for new format.

* Only attempt to register if sensor entity has enough data.
2020-08-25 15:17:21 -04:00
Daniel Shokouhi 5e1d275dce
Proximity Sensor (#801) 2020-08-25 13:08:26 -04:00
Krisjanis Lejejs d8990b18a4
Fixed widget errors with service calls containing 'all' (#810) 2020-08-25 13:02:33 -04:00
Daniel Shokouhi 101e519f32
Add audio sensor (#806)
* Add audio sensor

* Lint

* Lint
2020-08-25 11:44:02 -04:00
Daniel Shokouhi bcd9a3b0fc
Initial commit of pressure sensor (#803) 2020-08-25 11:30:42 -04:00
Oleksandr Kapshuk bd3b58c007
Activity recognition sensor added (#784)
* Activity recognition sensor added

* Added all probable activities with their confidence

* Corrected update interval

* ktlint
2020-08-25 10:52:58 -04:00
uvjustin c50c0adf0e
Add Exoplayer view and interface (#739)
* Add Exoplayer view and interface

* Fix play/pause buttons

* Support PictureInPicture

* Migrate dependencies to Config.kt

* Move code from inline to functions

* Add spacing in playback control layout

* Changes per @balloob

* Fix ktlint errors
2020-08-25 10:38:51 -04:00
chriss158 abfceba63b
Fix back stack of mobileAppIntegrationFragment (#804) 2020-08-22 14:49:55 -04:00
Justin Bassett 87647eeab1
Support opening NFC Settings from external bus. (#772)
* Support opening NFC Settings from external bus.

* Support frontend passing tag to write.

* ktlint

* Update to return empty object when tag is written.

* Remove commented code

* ktlintFormat

* Loosen restriction on tags to include more than just UUID.

* Close NFC activity when writing for frontend.
2020-08-22 14:42:34 -04:00
chriss158 7844360760
Fix top button back stack of settings activity (#802)
* Fix back stack of settings activity

* Remove overwrite of onBackPressed because not using super

* Fix lint
2020-08-21 21:39:06 -04:00
Krisjanis Lejejs 1fdb9e062a
Added onDeleted function to Static widget (#797) 2020-08-21 09:05:09 -04:00
chriss158 631b9d1cf5
Add themes selector (#780)
* Add themes selector

* Fix lint

* Fix test

* Remove german translation

* Default theme "system" on >= Pie

* Use useSimpleSummaryProvider for themes preference

* Fix lint

* Fix dark mode wait color text in "unable to connect to home assistant" message

* Fix tint of widget button icon in light mode

* Implement ThemeManager to handle theming

* Fix lint

* Fix WebViewPresenterImplSpec test
2020-08-21 09:04:11 -04:00
Krisjanis Lejejs b4a6a607b1
Added possibility to use multiple attributes for static widgets (#789)
* Added possibility to use multiple attributes for static widgets

* Fixed migration

* Remove empty line

* Fixed catch statement

* Renamed TAG
2020-08-20 09:27:42 -04:00
Krisjanis Lejejs ba621ca00e
Increased connection timeout delay (#795) 2020-08-20 09:20:16 -04:00
Daniel Shokouhi 26de39f9f0
Last reboot sensor (#794) 2020-08-20 08:53:35 -04:00
Oleksandr Kapshuk fd62b0e280
Enhance PhoneStateSensorManager with carrier information sensors (#786)
* Enhance PhoneStateSensorManager with carrier information sensors

* Check for api version while getting available sensors
2020-08-20 08:17:37 -04:00
Daniel Shokouhi c61bf25854
Add steps counter sensor (#792)
* Add steps sensor

* Fix permission and set correct icon
2020-08-19 20:55:38 -04:00
Justin Bassett 8e5f063200
Add a template widget (#790)
* Add backend for requests to get a template.

* Add frontend for template widgets!

* ktlintFormat

* Fix tests.
2020-08-19 20:49:34 -04:00
Krisjanis Lejejs 58312c134e
Added multiple entity state widget options (#771)
* Added entity widget text size, separator options

* Fix kLint

* kLint#2

* Fixed DB migration

* kLint fix

* Improved code quality
2020-08-19 07:48:36 -04:00
Justin Bassett 1372902dae
Fix name-spacing issue (#781)
* Apparently Kotlin does funny things when importing a class with the same name as the current class.

* ktlint.
2020-08-16 23:15:32 -04:00
Justin Bassett 4c91c34ec8
Let widgets use any material icon (#745)
* Functional widgets with all material icons to pick from.

* Load icons in io thread since it takes a hot second.

* Bump DB version.

* ktlint

* Blow away widget prefs since it was a hack anyway.

* Migrate static widgets to room db.

* ktlint and tests.

* Little more cleanup.

* More ktlint.

* Initial attempt at Migrations.

* Add missing Migrations.kt

* Add full migration support from old to new widgets.
2020-08-16 22:18:20 -04:00
chriss158 6bc19488b4
Add easier way to use of emoji in notifications (#741)
* Add easier way to use of emoji in notifications

* Try to exclude org.json:json

* Fix lint
2020-08-16 21:57:47 -04:00
Justin Bassett 47a88000e9
Fix issue with Room DB migrations. (#778)
* Fix issue with Room DB migrations.

* Add migration for sensors.
2020-08-16 15:59:08 -04:00
Daniel Shokouhi 16a0f66a8d
Change order of package for apps that don't provide it (#775)
* Change order of package for apps that don't provide it

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

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

* Lint

Co-authored-by: Justin Bassett <bassett.justint@gmail.com>
2020-08-16 14:44:40 -04:00
Daniel Shokouhi b24574c46c
Allow certain fields to be copied (#776) 2020-08-16 13:51:01 -04:00
Daniel Shokouhi 0e885e7b80
Attempt to fix SD card path in storage sensor (#770)
* Attempt to fix SD card path in storage sensor

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

Co-authored-by: Jesse Hills <3060199+jesserockz@users.noreply.github.com>

Co-authored-by: Jesse Hills <3060199+jesserockz@users.noreply.github.com>
2020-08-15 22:45:05 -04:00
Daniel Shokouhi 469be0310d
Fix light sensor crash on older devices (#766) 2020-08-15 07:43:04 -04:00