1
0
mirror of https://codeberg.org/Freeyourgadget/Gadgetbridge synced 2024-06-29 08:20:16 +02:00
Commit Graph

639 Commits

Author SHA1 Message Date
Andreas Shimokawa
46bbab7df0 rename IDSenderLookup to LimitedQueue and store Object instead of String 2016-01-09 16:07:22 +01:00
Andreas Shimokawa
de5f30ae97 WIP: Work towards SMS replies / canned replies, round 3
- put random id/phone number pair into limited lookup list (last 16 sms messages) when sms arrives
- lookup the phone number when replying from the a device

THIS STILL DOES NOT DO ANYTHING USEFUL
2015-12-14 23:31:31 +01:00
cpfeiffer
f258e62633 Refactoring: centralize GBDevice creation
- created and provided by DeviceHelper
- passed from UI to service
- without UI, service uses DeviceHelper directly

=> Cleaner and less duplicated code
2015-12-13 00:43:07 +01:00
cpfeiffer
159c187e5e On Quit, remove all pending notifications
At least the notifications from #141 don't stay there forever, then.
2015-12-08 21:48:56 +01:00
Andreas Shimokawa
8b87e97f51 fix crash in FileUTils.copyURItoFile() if source and destination are the same file.
This allows to install pbw files from the pbw-cache manually though a file manager.
2015-12-08 18:59:37 +01:00
cpfeiffer
7f8ba83aab This might fix the missing progress bar #155
setVisibility(Public) is only available since Lollipop.
2015-12-07 23:09:19 +01:00
Andreas Shimokawa
1c3e0b628b Pebble: store app details in pbw-cache and display them in app manager on firmware 3.x
Improves #93
2015-12-07 18:16:23 +01:00
Andreas Shimokawa
79f92b8495 Fix installing pbw files from different URIs than local files on Firmware 3.x. Fixes #183 2015-12-06 17:22:07 +01:00
cpfeiffer
bd0716ba58 Some more lint warnings fixed 2015-11-23 23:04:46 +01:00
cpfeiffer
34e08f6de8 Avoid potential NPE. Check for null first. 2015-11-18 23:21:56 +01:00
cpfeiffer
1e6db708d2 Fix NPE.
Now that is a really crappy API in Android that returns an array with null values.

closes #167
2015-11-18 23:18:01 +01:00
cpfeiffer
d4f070f0aa Simplify external dir handling again -- prefer the primary dir
The primary external dir is often a user-partition on the internal
storage medium. This one is safe in multi-user environments.

The "removable storage" (sdcard) on the other hand can be read by
everyone. If the former is not available or not writable, use the
latter.

closes #153
2015-11-01 20:49:50 +01:00
cpfeiffer
8920f5e95b Test fixing problem with non-writable getExternalFilesDir() #153 2015-10-29 00:46:52 +01:00
cpfeiffer
1f599c660f Improved file and error handling 2015-10-28 23:54:08 +01:00
cpfeiffer
1e56e540fa Remove hardcoded equals("MI") in favor of DeviceCoordintator #136 2015-10-18 01:01:13 +02:00
Andreas Shimokawa
a9186791dc register/unregister receivers at runtime instead of enabling/disabling them via packagemanger 2015-10-16 00:23:16 +09:00
Andreas Shimokawa
a4a59f5df4 fix hexdump() when using an offset with -1 as length (= full length) 2015-10-04 22:42:21 +09:00
Andreas Shimokawa
e3533a2b18 Pebble: Allow muting (blacklisting) Apps from within generic notifications on the watch
Closes #113
2015-09-25 00:53:40 +02:00
Andreas Shimokawa
1d41f2f8e4 Refactoring
The notfification APIs now use NotificationSpec as their only parameter, which
contains all information (required and optional ones).
We no longer have separate methods and actions for SMS/EMAIL/GENERIC anymore.
The type of notification is important now, not how we received them technically.
2015-09-24 14:45:21 +02:00
Daniele Gobbetti
e1ea8270ca Add a progress notification for the activity data transfer. 2015-09-24 14:03:01 +02:00
cpfeiffer
d9b4bbe550 Move activity data and progress manipulation into dedicated methods
I did this in trying to understand the code better and to easier allow
for error handling/transaction rollback to be added.
2015-09-23 23:16:42 +02:00
cpfeiffer
69b64ed4b6 More logging for time/timezone changes
(trying to find an explanation for #91)
2015-09-05 00:14:09 +02:00
Andreas Shimokawa
2da717ea4c set visibility of service notification to public again 2015-08-31 21:29:00 +02:00
cpfeiffer
25ddc20f89 Fix testcases with sdk 23: don't call Notificaton API during local tests 2015-08-29 20:39:34 +02:00
Daniele Gobbetti
6ebc727f97 Merge remote-tracking branch 'origin/master' into low_battery_notification
Conflicts:
	app/src/main/java/nodomain/freeyourgadget/gadgetbridge/util/GB.java
2015-08-24 17:48:17 +02:00
cpfeiffer
77cad5c47f Initial support for testing the DeviceCommunicationService
Lots of support classes to enable local testing, without
a device or an emulator.
2015-08-22 01:09:56 +02:00
Andreas Shimokawa
1150ad2b8d Pebble: Support taking Pebble Time screenshots. Closes #97. 2015-08-22 00:14:14 +02:00
Daniele Gobbetti
dcc988139f Merge remote-tracking branch 'origin/master' into low_battery_notification 2015-08-21 17:34:11 +02:00
cpfeiffer
a1cb246e27 Add and use a "client interface" for the actions of the service
Previously, the DeviceCommunicationService was invoked directly,
via
Intent intent = new Intent(foo, bar);
intent.setExtra(EXTRA_BAZ, baz);
startService(...);

and this was scattered throughout GadgetBridge.
Now there is a "frontend" available, so that you can call
the service more easily, like
GBApplication.deviceService().connect();

For a start, this client interface (DeviceService) actually
implements the same interface (EventHandler) as the receiving side
(DeviceSupport). This may change in the future.

This will also make testing much easier, because we can use
this client interface to invoke the test service as well.
2015-08-21 01:03:57 +02:00
Daniele Gobbetti
0d8adeb7f9 Some refinements:
- only show the bigtext notification if the device has set extended battery info
- custom icon for the low battery notification (with license information)
- show device name in the notification
- set the notification to high priority
- the battery threshold is now set in GBDevice
2015-08-19 17:36:53 +02:00
Daniele Gobbetti
c3e395818f Adding support for battery events using GBDeviceEvent.
- show notification on low battery (closes #40)
- Miband specific: add date of last charge and number of charges
2015-08-18 17:37:51 +02:00
cpfeiffer
585a888ecb Improved javadoc 2015-08-18 00:11:51 +02:00
cpfeiffer
e6a0c35f73 Extract checksum implementations into separate class CheckSums 2015-08-17 22:43:42 +02:00
cpfeiffer
bcf42f8022 Finally, the prev and next buttons do something (#79)
Far from perfect, but a start.
2015-08-17 02:22:16 +02:00
cpfeiffer
2a2eae068a Improvements to the install activity #30
- made it independent of Mi fw and Pebble fw + app classes
- automatically connect to the last used device
- some other small fixes/improvements
2015-08-06 02:17:38 +02:00
cpfeiffer
910d9ef398 Make firmware reading a bit more failsafe #30 2015-08-04 23:02:36 +02:00
cpfeiffer
7c597b325a Big refactoring: move classes and packages around to get a better structure
- model package contains mostly shared interfaces (UI+service), not named GB*
- impl package contains implementations of those interfaces, named GB*
  the impl classes should not be used by the service (not completely done)
- the service classes should mostly use classes inside the service and deviceevents
  packages (tbd)

Every device now has two packages:
- devices/[device name] for UI related functionality
- service[device name] for lowlevel communication
2015-08-03 23:09:49 +02:00
Andreas Shimokawa
dbbcf20bbc reformat code 2015-07-25 21:52:52 +02:00
cpfeiffer
cc549a6c49 Basic database import and export (to external storage)
(In the Debug Activity)
2015-07-08 23:11:23 +02:00