Commit graph

28 commits

Author SHA1 Message Date
Aleix Pol
2c2cb21ee1 Don't clean the devices that looked us up in the first place 2015-09-12 20:53:05 +02:00
Albert Vaca
217d4b60ff Fixed outging capabilities 2015-09-12 08:51:39 -07:00
Aleix Pol
4730022810 Pass arguments as const-reference 2015-09-12 09:45:59 +02:00
Aleix Pol
6a379e9227 Rename missingPlugins to unsupportedPlugins 2015-09-08 17:38:33 +02:00
Aleix Pol
df3581459a Add a test that makes sure that capabilities are gathered correctly
While at it, fix the logic, because it wasn't working all that well.

Reviewed by Albert Vaca
2015-09-08 17:35:30 +02:00
Aleix Pol
4960247fb5 Add a package type that updates the device capabilities
Every time we reload the plugin list, report the plugins that we support.
If the remote devices' capabilities change, update the plugin list.

Reviewed by Albert Vaca
2015-09-07 20:03:05 +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
Aleix Pol
d835d01a09 Add a test for file sending, using the loopback device
Extends unit testing by making sure that file sharing works locally.

REVIEW: 125086
2015-09-07 15:03:04 +02:00
Aleix Pol
43451d6ae1 Simplify Device::id management
Removes the id->row mapping. It was broken as the indices weren't updated
when a row was added or removed.
Stop exposing Device::id through dbus, just store it in the interface
class.
* It's redundant as it's part of the interface definition
* If we keep it it will save us quite some dbus round-trips
* It will be reliable, as nowadays id() sometimes QString() if the dbus
connection is invalid.

REVIEW: 124158
2015-06-24 20:57:17 +02:00
Albert Vaca
08938689c5 Emit less redundant events 2015-06-21 19:39:04 -07:00
Aleix Pol
cee2c6b057 Remove unused declaration 2015-06-13 01:27:16 +02:00
Aleix Pol
ef788e0658 Restore removed API, deprecate
REVIEW: 124084
2015-06-12 17:54:47 +02:00
Aleix Pol
b592dc99a0 Merge pairingSuccessful and unpaired signals into pairingChanged(bool)
REVIEW: 124067
2015-06-11 16:19:00 +02:00
Albert Vaca
e5b897884c Added device status icons to be used in the KCM instead of the IM ones 2015-05-17 23:28:58 -07:00
Albert Vaca
563233cac7 Fixed unpair still using the old KConfig 2015-03-15 19:31:01 -07:00
Aleix Pol
6fe7a9b158 Make it possible for the DevicesModel to react to device name changes 2015-03-14 04:28:54 +01:00
Aleix Pol
9c45c5469c Prefer to specify the property
Tie the change signal to the getter, makes the interface easier to read
and opens the possibility to adopt certain optimizations in the Qt side.
2015-03-14 04:09:14 +01:00
Aleix Pol
807926473d Use better types to store the device internal data
https://marcmutz.wordpress.com/effective-qt/containers/
2015-03-14 04:07:55 +01:00
Aleix Pol
0e96d837ff Make sure the capabilities don't change over time by constifying
It exposed a problem later on, where we'd end up removing our own
capabilities into the remote's.
2015-03-14 02:44:21 +01:00
Albert Vaca
c7c91c1289 Added KdeConnectConfig class that aims to be a KConfig abstraction
Benefits:
- We had config files in different paths, now they will be centralized.
- Daemon, LanLinkProvider and NetworkPackage depend only on Qt now.
- KConfig is accessed with strings as keys, where a typo can go unnoticed.
- Daemon is now thinner, as it doesn't need to initialize config values.
- QCA::Initializer is in a single place now (was in Daemon and Plugin).
2015-03-01 20:16:07 -08:00
Aleix Pol
ef70772f70 Clean up generation of the host's private key
Only look for it in the writable path, as it won't ever be installed in a
common place.
Don't look for the path in the config file either.
Don't make it depend on the application name.

REVIEW: 122744
2015-03-02 00:49:44 +01:00
Aleix Pol
21ab5a4f81 Merge branch 'master' into frameworks
Mostly kDebug -> qCDebug
Also some KCmdLineArgs -> QCommandLineParser

Conflicts:
	cli/kdeconnect-cli.cpp
	core/CMakeLists.txt
	core/backends/lan/lanlinkprovider.cpp
	core/daemon.cpp
	core/pluginloader.cpp
	interfaces/CMakeLists.txt
	kio/kiokdeconnect.cpp
	plugins/mousepad/CMakeLists.txt
	plugins/mousepad/mousepadplugin.h
	plugins/mpriscontrol/mpriscontrolplugin.cpp
	plugins/sftp/sftpplugin.cpp
2014-11-04 19:12:29 +01:00
Aleix Pol
380006114a Use the incoming/outgoing capabilities for trimming loaded plugins
Only lets the plugins that support something offered on the other end or
that offer something supported on the other end. If we don't have
information about the other device, we enable everything like we used to.

Also refactors a bit the plugin loader, to be able to provide information
step by step.

Currently it works, but we need support for capabilities at least on
Android to start taking good advantage of it.

REVIEW: 118820
CCMAIL: kdeconnect@kde.org
2014-07-11 01:54:19 +02:00
Aleix Pol
c8dbbed685 Move the send ping code to the ping plugin
turn it into a dbus call to the plugin

Reviewed by Albert Vaca
2014-06-27 18:21:40 +02:00
Albert Vaca
734b27ed50 De-duplicated small piece of code 2014-06-15 21:40:19 +02:00
Aleix Pol
6ce0b6b874 Document in the desktop files the outgoing types for the plugins
This way we narrow the things a plugin can send, to its own scope. Still
every plugin can set a list of types, so it should be ok.
2014-06-14 20:35:00 +02:00
Aleix Pol
b7420146eb Expose the icon name from the device instance 2014-06-14 19:42:34 +02:00
Aleix Pol
b88897847b Reorganize sources
We broke kded into core and kded, core contains the library with the backends
and plugins.
Also we renamed libkdeconnect to interfaces.
2014-06-14 15:22:40 +02:00
Renamed from kded/device.h (Browse further)