2
0
mirror of https://github.com/KDE/kdeconnect-android synced 2025-08-22 18:07:55 +00:00

30 Commits

Author SHA1 Message Date
Isira Seneviratne
1c416852e2 Use IOUtils.copy(). 2020-07-11 21:36:24 +00:00
Isira Seneviratne
6e747e2166 Use IOUtils' readLines() and toString(). 2020-07-11 21:36:24 +00:00
Simon Redman
6f81c67632 Refactor contacts-getting code to be either "everything" or "one"
Fixes bug from mailing list conversation dated 12 October 2019
2019-10-27 21:23:52 +00:00
Simon Redman
b1c6df405c Delete broken getVCardsFast
This method does not work because the API doesn't provide the information we need.

If we decide to ressurect it, we can look this commit up later.

#TIMECAPSULE
2019-10-19 09:01:10 -07:00
Erik Duisters
779d5e625a Do not return duplicate contact uIDs because it will crash kdeconnectd 2019-08-31 11:11:58 +02:00
Nicolas Fella
cf526953f3 Remove unnecessary supression 2019-04-19 21:29:39 +02:00
Simon Redman
dc5f10c073 Revert "Try-with-resources on inputstreams"
This reverts commit aa776739b7feed778826593949f9cb471a6a9fb6
2019-04-19 05:10:11 +00:00
Nicolas Fella
21b97d335c Add NonNull annotations 2019-04-19 01:31:19 +02:00
Albert Vaca Cintora
aa776739b7 Try-with-resources on inputstreams
As suggested by lgtm.com
2019-04-18 20:59:54 +02:00
Nicolas Fella
f1194e88c2 Use Log.e instead of printStackTrace 2019-03-31 20:09:44 +02:00
Erik Duisters
da9b4ea19e Do not query for contacts when there are no contacts 2019-01-29 11:13:44 +01:00
Erik Duisters
f684fbe8ef Migrate from android support libraries to androidx
Summary: Use the new AndroidX libraries instead of the legacy support libraries

Test Plan: Apply patch and verify everything works as before

Reviewers: #kde_connect, nicolasfella

Reviewed By: #kde_connect, nicolasfella

Subscribers: shubham, kdeconnect

Tags: #kde_connect

Differential Revision: https://phabricator.kde.org/D17818
2018-12-27 16:43:34 +01:00
Nicolas Fella
b4df9f0cb6 Use try-with-resource
Reviewers: #kde_connect, albertvaka

Reviewed By: #kde_connect, albertvaka

Subscribers: kdeconnect

Tags: #kde_connect

Differential Revision: https://phabricator.kde.org/D17778
2018-12-24 22:32:03 +01:00
Albert Vaca
a9ab77471e Use try-with-resources in places where it looked safe 2018-10-30 13:04:45 +01:00
Nicolas Fella
a49a145d69 Only use required access modifiers 2018-10-26 23:59:20 +02:00
Nicolas Fella
74d2b2e828 Fix javadoc warning 2018-10-26 23:09:24 +02:00
Simon Redman
3b19b6ebe2 Add contacts-reading plugin (Android side)
Summary:
Add a plugin to the KDE Connect Android application which supports reading the Android contacts databases and sending the requested data as vcards
 - Android automatically has support for exporting vcards with all the fields you would expect (phone, email, photo, etc.)
  - I add two custom fields, one for the modification timestamp and another for the NAME_RAW_CONTACT_ID so that the contacts can be correlated back to the Android database

This does not (yet) support writing contacts back to the phone nor does it automatically listen to the phone's contacts database to change

BUG: 367999

Test Plan:
Connect the device to the desktop and verify that vcards are created in QStandardPaths::GenericDataLocation / kpeoplevcard". On my system this is ~/.local/share/kpeoplevcard

Create a dummy contact on the device and verify it is synchronized (Currently not automatic, have to disconnect and reconnect or use dbus)

Modify the dummy contact and verify the modifications are synchronized (Currently not automatic, have to disconnect and reconnect or use dbus)

Delete the dummy contact and verify the deletion is synchronized (Currently not automatic, have to disconnect and reconnect or use dbus)

Reviewers: #kde_connect, mtijink, nicolasfella

Reviewed By: #kde_connect, nicolasfella

Subscribers: MatMaul, philipc, kdeconnect, nicolasfella, andyholmes, mtijink

Tags: #kde_connect

Maniphest Tasks: T8283

Differential Revision: https://phabricator.kde.org/D9690
2018-06-07 21:04:43 -06:00
Nicolas Fella
60049dab2a Apply coding style to whole project
Summary: Sorry for the huge diff, but all I did was applying Android Studio's 'Reformat Code' to all files. If everyone does that before submitting a patch we can keep it clean easily.

Test Plan: Compiles

Reviewers: #kde_connect, mtijink

Reviewed By: #kde_connect, mtijink

Subscribers: mtijink, sredman, #kde_connect

Tags: #kde_connect

Differential Revision: https://phabricator.kde.org/D10905
2018-03-03 16:14:42 +01:00
Nicolas Fella
c2e9edc09c Remove unnecessary semicolons
Summary: Depends on D10905

Reviewers: #kde_connect, mtijink

Reviewed By: #kde_connect, mtijink

Subscribers: #kde_connect

Tags: #kde_connect

Differential Revision: https://phabricator.kde.org/D10946
2018-03-03 16:11:27 +01:00
Nicolas Fella
fa5a37c472 Apply coding style to whole project
Summary: Sorry for the huge diff, but all I did was applying Android Studio's 'Reformat Code' to all files. If everyone does that before submitting a patch we can keep it clean easily.

Test Plan: Compiles

Reviewers: #kde_connect, mtijink

Reviewed By: #kde_connect, mtijink

Subscribers: mtijink, sredman, #kde_connect

Tags: #kde_connect

Differential Revision: https://phabricator.kde.org/D10905
2018-03-03 16:09:52 +01:00
Albert Vaca
37aab9a520 Ignore all exceptions from ContentResolver.query 2017-06-21 03:27:03 +02:00
Albert Vaca
c5456fd84e Fixed issues detected in static analysis by Coverity 2016-07-07 17:45:04 +02:00
Albert Vaca
1a04bfbbea Fixed simple issues detected by lint 2016-06-21 16:44:21 +02:00
Albert Vaca
0836453c35 Project-wise optimize imports 2016-06-09 13:42:54 +02:00
Albert Vaca
6f0b581c02 Fixed crash 2016-06-03 14:51:31 +02:00
Àlex Fiestas
76eb88b51f Removed unused variable from ContactsHelper 2016-03-07 11:37:54 +01:00
Àlex Fiestas
c87b09c5f0 If the contact has a photo, include it in the packet
Basically adds as base64 in the packet the contact Photo. We should not
have to worry about the size of it since it is always 96x96 and android
takes care of that.
2016-03-06 21:58:01 +01:00
Àlex Fiestas
708bcf9928 Adapt phoneNumberLookup to return more information
It returns now photoID plus the name and it can be easily expanded in
the future if required.
2016-03-06 21:58:01 +01:00
Joao Carreira
d59750441f Changes in Contacts Helper
Modify the contact helper in oder to split contact name and
contact number. Those values are sent separately
2015-10-27 11:44:04 -07:00
Albert Vaca
f01811446a Migrated project to latest Android SDK and moved sources out of 'main' dir
Sorry for the conflicts caused by moving the sources!
2014-11-22 17:04:37 -08:00