Commit graph

91 commits

Author SHA1 Message Date
Nicolas Fella
f2d97193eb Remove defunct calls to KAboutData::pluginData
The data is never registered so they always return nullptr. We might as well not pass it.
2020-10-31 19:58:05 +00:00
Nicolas Fella
87db95b22f Convert license headers to SPDX expressions 2020-08-17 09:48:10 +00:00
Nicolas Fella
3b8fedea1a Replace http GNU urls with https 2019-03-23 17:29:26 +01:00
Nicolas Fella
1f1462e813 Remove unused includes 2019-02-28 14:11:23 +01:00
Nicolas Fella
fc4da13d64 Add context object 2019-02-28 14:08:17 +01:00
Nicolas Fella
68d0c5d143 Do not require Frameworks 5.45
Summary: Ifdef for old KF5 as discussed in D11684.

Test Plan: Can still use feature when above 5.45

Reviewers: apol

Reviewed By: apol

Subscribers: kdeconnect

Tags: #kde_connect

Differential Revision: https://phabricator.kde.org/D12810
2018-05-10 19:48:40 +02:00
Aleix Pol
dd031d3deb Show the KCM with the run commands open when a setup packet is received
Summary: Depends on D11683.

Test Plan: Tested the `kcmshell kdeconnect --args mydeviceid:kdeconnect_runcommand` works

Reviewers: #kde_connect, nicolasfella

Reviewed By: #kde_connect, nicolasfella

Subscribers: nicolasfella

Tags: #kde_connect

Differential Revision: https://phabricator.kde.org/D11684
2018-04-19 03:03:42 +02:00
Albert Vaca
84bba9429f Merge branch 'master' into 1.x
# Conflicts:
#	core/backends/lan/downloadjob.cpp
#	core/backends/lan/downloadjob.h
#	core/filetransferjob.cpp
#	core/filetransferjob.h
#	plugins/notifications/sendreplydialog.cpp
#	plugins/notifications/sendreplydialog.h
#	plugins/telephony/sendsmsdialog.cpp
#	plugins/telephony/sendsmsdialog.h
2017-09-03 22:05:54 +02:00
Jean Vincent
72535ecf48 Make member variable names, & placement and * placement more coherent
Summary:
Change all member variables to the form m_fooBar because it is the preferred form in Qt (it was half and half between this and mFooBar, and a minority didn't have anything).
Place all references and pointers on the side of the type since it is the majority.

Basically:
 - mFoo -> m_foo
 - foo -> m_foo (if it is a member variable)
 - Type &ref -> Type& ref
 - Type *ptr -> Type* ptr

Reviewers: #kde_connect, nicolasfella, albertvaka

Reviewed By: #kde_connect, nicolasfella, albertvaka

Subscribers: albertvaka, #kde_connect

Tags: #kde_connect

Differential Revision: https://phabricator.kde.org/D7312
2017-09-03 21:45:08 +02:00
Albert Vaca
a18f91ccc1 Swapped labels 2017-08-02 02:59:41 +02:00
Aleix Pol
209e3e2842 Reflect property change when unpairing
There's no pairStatusChanged when the device is not connected to
anything (be it because it's unreachable at the moment).
2017-07-14 01:01:15 +02:00
Aleix Pol
f65392ca6b Expose pair requests on the KCM 2017-02-20 21:00:26 +01:00
Aleix Pol
b947ef6b60 Use asynchronous calls to the device interface when possible
Summary:
Use setWhenAvailable for isTrusted calls
Just deal with the pairing buttons state only once.
Unify semantics (paired vs trusted)

Reviewers: albertvaka, #kde_connect

Reviewed By: albertvaka, #kde_connect

Differential Revision: https://phabricator.kde.org/D4125
2017-01-13 18:36:43 +01:00
Aleix Pol
c822ef8104 Set the device's announcedName when it's available
No need to block on it
2017-01-13 17:48:37 +01:00
Aleix Pol
41fd3d8dd8 Stop enforcing maximum size 2016-11-28 15:32:35 +01:00
Albert Vaca
60331ccbf1 Clazy says all this QStringLiteral and QLatin1String were missing/wrong 2016-11-26 16:21:29 +01:00
Albert Vaca
a1340c8042 Fixed old style connects with clazy 2016-11-26 15:14:19 +01:00
Kai Uwe Broulik
6f7c419baa Merge branch '1.x' 2016-09-10 22:53:37 +02:00
Albert Vaca
3c0f3b9814 Removed unsupported plugins section from KCM 2016-09-06 10:53:19 +02:00
Aleix Pol
ee7420c8a0 Listen to announcedName changes from the kcm 2016-08-21 19:50:27 +02:00
Albert Vaca
bd0920d354 Changed string 2016-07-13 18:25:44 +02:00
Aleix Pol
81634303b2 Make capabilities static
As discussed with Albert, move the population of capabilities into the
identity package, making them static along the execution of the link.

When we receive the identityPackage, we collect the plugins we can use with
the device and stick to those. This should simplify the implementation and
remove the possibility to lose packages if packages are received before the
capabilities are processed in the former approach.

REVIEW: 128386
2016-07-06 17:37:22 +02:00
Albert Vaca
1848e96a91 Fixed old signal name 2015-12-17 05:54:37 -08:00
Albert Vaca
cf6cbd2925 WIPx3! 2015-12-01 10:45:14 -08:00
Albert Vaca
82bc73dd9b WIPx2 2015-12-01 07:25:34 -08:00
Albert Vaca
16f9af908a WIP 2015-11-30 10:36:01 -08:00
Aleix Pol
661fa098d4 Introduce bare documentation for the KDE Connect kcm 2015-10-19 03:25:17 +02:00
Aleix Pol
2707d1f0a8 Fix reload when changing current device on the kcm 2015-09-12 19:43:15 +02:00
Aleix Pol
fe2679a8a5 Prevent the kcm from refreshing the UI while interacting with it
Only refresh it when the available plugins actually change.
2015-09-12 15:02:59 +02:00
Albert Vaca
82d036265c Acquire the discovery mode when refreshing the KCM, in case it's not there 2015-09-11 07:19:07 -07:00
Aleix Pol
a9d2840664 Use acquire and release instead of a boolean property
This way we hope we won't end up without discovery if 2 instances need
discovery at the same time.

Reviewed by Albert Vaca
2015-09-09 20:09:04 +02:00
Aleix Pol
a0da8ba858 Let the KPluginSelector react to changes in the plugin configuration
Mainly whenever the remote capabilities change.

Reviewed by The Vaca Man
2015-09-08 20:03:44 +02:00
Aleix Pol
b9c427a316 fix crash and simplify code
reviewed by Albert Vaca
2015-09-08 17:57:55 +02:00
Aleix Pol
6a379e9227 Rename missingPlugins to unsupportedPlugins 2015-09-08 17:38:33 +02:00
Aleix Pol
817fcbc9d6 Merge branch 'stable' 2015-09-08 10:51:41 +02:00
Aleix Pol
d58f6314fe run Clang Modernize
Minus the auto change
2015-09-08 10:47:37 +02:00
Aleix Pol
4023bf0599 Only keep connections alive with unpaired devices when discovery is enabled
At the moment, we were keeping the connection alive with every reachable
device. While this works optimally for most use-cases, on networks with
several devices with KDE Connect, the amount of connections grows
exponentially.

Reviewed by Albert Vaca

CCBUG: 352424
2015-09-08 09:30:55 +02:00
Aleix Pol
24d4d19b89 Remove debug
Sorry Albert :/
2015-09-08 00:59:17 +02:00
Aleix Pol
91351773fd Mark incompatible plugins as such in the kcm
If a plugin isn't available, display it as unsupported by the device. This
is figured out through capabilities.

Reviewed by Albert Vaca
2015-09-07 19:35:07 +02:00
Albert Vaca
9fa8538bf1 Removed some assertions that could not be true if using the model filter
Also fixed ugly hack where the KCM updated the model
2015-06-21 20:20:40 -07:00
Albert Vaca
c8e0c474ef Fixed crash 2015-06-21 19:43:21 -07:00
Albert Vaca
02bc1bcd90 Fixed progress indicator incorrectly being displayed after unpiring 2015-06-21 19:42:57 -07:00
Albert Vaca
c07c48ee37 Added "about" dialog to KDE Connect settings module.
BUG: 349186
2015-06-19 22:48:18 -07:00
Aleix Pol
7c2e2fb726 QML-ify
Add API to call random public plugin methods
qdbusxml2cpp is not generating the Q_PROPERTY attribute. For now [1], add
it ourselves by addding a proxy signal.

REVIEW: 124077
2015-06-13 01:28:36 +02:00
Aleix Pol
b592dc99a0 Merge pairingSuccessful and unpaired signals into pairingChanged(bool)
REVIEW: 124067
2015-06-11 16:19:00 +02:00
Aleix Pol
05491442e6 Make it possible to fetch the device from the DevicesModel from QML
Uses the row as the argument instead of the QModelIndex.
Defines the Device type so it can be used from QML.

REVIEW: 123361
2015-04-15 13:00:23 +02:00
David Rosca
b71b39761d KCM: Use currentChanged signal instead of clicked in deviceList
Using currentChanged signal it is now possible to select devices
with keyboard.
It also no longer refreshes plugin info when clicking on already
selected device.

REVIEW:123308
2015-04-09 17:47:01 +02:00
Albert Vaca
f237a659ec Added a link to the Android app from the KCM 2015-03-23 00:39:36 -07:00
Aleix Pol
c7cee37330 Port away from KServiceTrader
Uses KPluginLoader+KPluginMetadata instead.
Describes plugins in json instead of desktop files. These desktop files are
then embedded into the .so file. All the plugins will be in a kdeconnect/
directory, and those will be the ones to look for.

Note it doesn't drop the KService dependency as KIOCore is a KDE Connect
dependency as well.

REVIEW: 123042
2015-03-19 16:36:53 +01:00
Albert Vaca
02a2990720 Added a baseclass for the plugins' KCMs and a class for the plugins' config
Centralizing the plugins' config will ensure that all the plugins store it
the same way (ie: not in random files scattered around, like until now).
The base KCM class, together with the already existing base plugin class,
will give easy access to all the plugins to this centralized config. Also,
now the settings are not shared across devices (that is: every device can
have different config for a same plugin).

Note: This commit requires KCMUtils 5.9

REVIEW: 122927
2015-03-13 21:22:21 -07:00