Commit graph

192 commits

Author SHA1 Message Date
Alexander Lohnau
b21f5b02e3 Fix windows build issues
- Add dummy args param to QProcess::startDetached
- Remove logging category from inline snippet. This was removed due to
  being unused in non-windows builds.
2023-07-22 16:39:55 +02:00
Albert Vaca Cintora
c3a2665477 Do not call first() on a temporary list 2023-07-20 23:36:05 +02:00
Albert Vaca Cintora
0e2d2af402 Bump KDE compiler settings to latest
This already uses C++17 and C99, so no need to set it manually
2023-07-20 15:47:27 +00:00
Alexander Lohnau
c5bfc4a5b0 Allow building against Qt6/KF6 2023-07-20 11:15:41 +03:00
Albert Vaca Cintora
9c87393b28 clang-format pass 2023-07-16 16:20:34 +02:00
l10n daemon script
09f38caec5 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2023-06-20 01:54:21 +00:00
Albert Vaca Cintora
fb73fe2ecc Windows: change the systray icon for light/dark themes 2023-06-12 15:34:43 +02:00
Albert Vaca Cintora
6396fc8e5a Windows indicator: print output when ran in console 2023-06-12 15:30:30 +02:00
Albert Vaca Cintora
144a60b58a Allow disabling clipboard auto-share and add option to share manually
Continues the work started in !396 by rebasing it onto latest master and
making the "send clipboard" button from the plasmoid invisible when
automatic syncing is enabled.
    
I didn't find a way to do the same in kdeconnect-indicator and
kdeconnect-app (why do we have 3 UIs???), so in those we always show the
option for now.
2023-06-07 19:48:25 +00:00
Albert Vaca Cintora
064ddfa3fe Refactor PairingHandler
We now have a single PairingHandler for all types of links.

The implementation now is more aligned with the one for Android.
2023-06-02 16:38:52 +00:00
l10n daemon script
ebd70efd3e SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2023-04-10 01:39:38 +00:00
Albert Vaca Cintora
7b7a3f41b0 Maybe fix KCM from macos app 2023-03-09 00:35:00 +01:00
l10n daemon script
9ee562cac3 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2023-03-05 01:58:22 +00:00
l10n daemon script
c4495d5855 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2023-02-04 02:05:14 +00:00
l10n daemon script
b5ab505074 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2023-02-02 02:03:13 +00:00
l10n daemon script
6acbcd628d SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2022-12-15 01:56:04 +00:00
l10n daemon script
4656144ac9 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2022-11-19 01:48:52 +00:00
Volker Krause
002848efa8 Adapt build system to also support Qt 6
This is complicated by the Qt 5.6 requirement of SailfishOS, hopefully
that didn't get broken by this.
2022-10-29 16:51:41 +02:00
l10n daemon script
e77ba5b542 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2022-10-20 02:01:51 +00:00
l10n daemon script
f556dc721b SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2022-09-30 01:47:48 +00:00
Nicolas Fella
a918ffc0cb Add and make use of ECM's clang-format integration 2022-09-11 23:21:58 +00:00
l10n daemon script
34da0ad9e1 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2022-09-05 01:43:43 +00:00
l10n daemon script
b25f7e07a8 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2022-08-27 01:49:35 +00:00
l10n daemon script
fae10ece8b SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2022-07-01 01:48:04 +00:00
Weixuan Xiao
19d0b8f4bc Improve D-Bus processing on macOS
Unset launchctl env before running the new one, to avoid connecting through the old launchctl env.
Show a warn message for D-Bus connection failure on macOS.
2022-06-26 18:16:55 +00:00
Nicolas Fella
f7f3c01ec8 Use undeprecated install dirs
Using kde-dev-scripts/kf5/cmakelists_install_vars.pl
2022-04-21 00:50:14 +02:00
Weixuan Xiao
f1843cb492 Improve D-Bus implementation on macOS
Better patch to replace !218.

- Auto and quick detection of previous D-Bus instance;
- Remove private D-Bus compile definition, only use it on macOS without an existing D-Bus instance;
- Safe reboot after crashes because the indicator is not relating on the kdeconnectd to run a D-Bus session;
- Safe exit after clicking on `Quit` in the systray.


More details in commit logs:

Only enable private D-Bus on macOS because the other platforms do not
need them.
The app should be able to easily detect the session bus from the env
DBUS_LAUNCHD_SESSION_BUS_SOCKET from launchd through launchctl.
Because https://gitlab.freedesktop.org/dbus/dbus/-/blob/master/dbus/dbus-sysdeps-unix.c#L4392
shows that it is the only probing method on macOS with launchd.

The D-Bus session bus can be easily found from launchd/launchctl
with DBUS_LAUNCHD_SESSION_BUS_SOCKET env. It can be an external one
(installed from HomeBrew) or an internal one (launched by a previous
instance followed by a crash).

The indicator helper on macOS can now automatically detect whether we can use a potentially
(with launchd/launchctl env set, or KDE Connect macOS
private_bus_address set) existed and usable session bus.
If previous bus is usable, just try to launch the kdeconnectd with us.
Otherwise, launch a private D-Bus daemon, export the launchd/launchctl
env, and run a kdeconnectd instance.

Everything works better and quicker now :)
2022-04-12 05:40:03 +00:00
Nicolas Fella
12d8adef76 Enable highdpi for all executables 2022-04-02 14:32:54 +02:00
l10n daemon script
a09825c498 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2022-03-20 02:05:33 +00:00
Ryan Adolf
531418c7d2 Change tray icon so it is the right color on MacOS
## Summary

On MacOS the system tray icon is off-color because it uses the gray-colored `kdeconnectindicatordark` icon which does not match the rest of MacOS.

![image](/uploads/430933399d9570dc1c59807e4715e87b/image.png)

BUG: 430226

I've used two patches to fix this:
1. Always use the status `KStatusNotifierItem::Passive` on MacOS. `KStatusNotifierItem` will only mark the icon as a mask (which is needed to allow it to dynamically switch between light and dark theme) [if the status is passive](cff7c337ab/src/kstatusnotifieritem.cpp (L1079-1081)).
2. The above should theoretically be enough to fix the issue and I swear at one point it was all that was needed. However, to fix this issue in my dev environment I also needed to pass in a `QIcon` with `setIsMask(true)` instead of setting the icon by its name. And I also use the `kdeconnectindicator` instead of `kdeconnectindicatordark` icon.

## Test Plan

The icon now renders in the correct color, regardless of whether devices are connected:

![image](/uploads/5010a07cbb5f23a286ece641c6b3879c/image.png) ![image](/uploads/2ae5d3d8aa633ebafb260febe313057c/image.png)

## Future work

Once I've verified this PR is working in the right direction, I want to look into making the icon gray (and hopefully a much easier-to-see gray) when no devices are connected!

For example, WireGuard, when not connected, looks like this:

![image](/uploads/43c2ef6bc7261431e878c9c1c05174f9/image.png) ![image](/uploads/f7587190648606df77ad3e3dde84098f/image.png)

P.S. I've been testing off the v21.12.2 tag since the master branch doesn't compile for me, so I haven't tested this change on the latest dev commit. But there should be no conflicts.
2022-03-02 12:06:36 +00:00
Ryan Adolf
14543fcba5 Raise configuration window (MacOS bug)
## Summary

I've added a call to [`dialog->raise()`](https://doc.qt.io/qt-5/qwindow.html#raise) when launching the configuration dialog.

This is intended to fix a MacOS bug where the configuration window launches behind other open windows, but this call shouldn't harm operating systems as well.

BUG: 416050

## Test Plan

### Before:
Configuration dialog launches behind other open windows on MacOS.

### After:
Configuration dialog launches over other open windows on MacOS.
2022-02-26 10:23:20 +00:00
l10n daemon script
5b314846fe SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2022-02-20 01:45:04 +00:00
Alexander Lohnau
fd681e62ab Port deprecated KCMultiDialog methods & embed json metadata in KCM
This KCM will have to get installed installed in the new plasma namespace eventually.
But considering that this app is part of the release service, we should not
depend on changes in a not yet released Plasma version.

Task: https://phabricator.kde.org/T14501
2021-12-15 08:24:22 +01:00
l10n daemon script
5c76528250 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2021-11-24 01:36:30 +00:00
l10n daemon script
c630a3de90 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2021-11-04 01:16:42 +00:00
Albert Vaca Cintora
0ebe9db019 Fix MacOS build
If neither  PRIVATE_DBUS_ENABLED and APPLE_IN_APP_BUNDLE weren't set,
DBusHelper::macosUnsetLaunchctlEnv() wasn't declared.
2021-10-19 18:29:55 +02:00
l10n daemon script
61b2e607b4 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2021-09-26 01:12:22 +00:00
Nicolas Fella
c9bdf625c0 Set breeze as fallback icon theme for all executables 2021-07-27 23:03:51 +02:00
Piyush Aggarwal
db675eb7b2 connectivity_action: replace manual ifs with code 2021-07-13 23:25:02 +05:30
Piyush Aggarwal
296de907b5 indicator: fix single-click to open app and remove unnecessary capture 2021-07-12 05:35:25 +05:30
Piyush Aggarwal
e683dd218a indicator: add singleClick to open main app interface 2021-07-02 23:09:47 +05:30
Piyush Aggarwal
c647de6ab7 connectivity_action.cpp: remove stray qDebug() 2021-06-29 07:03:56 +05:30
Piyush Aggarwal
4d868a2e92 deviceindicator: add path to look in for kdeconnect-handler.exe 2021-06-25 14:15:02 +05:30
Weixuan XIAO
6f342d3ec2 Fix exit due to too early D-Bus call on macOS
Move D-Bus call related code after daemonHook.
This should also keep compatibility on Windows.
2021-06-22 15:03:46 +02:00
Piyush Aggarwal
8356cf4e5b systray_actions: add license 2021-06-22 15:24:05 +05:30
Piyush Aggarwal
e10b098ed3 systray: add photo plugin to systray actions 2021-06-17 15:03:21 +00:00
Piyush Aggarwal
3273cea4c8 systray: add separator 2021-06-17 15:03:21 +00:00
Piyush Aggarwal
fc4a19dee0 systray: disable status actions - battery and connectivity - since they don't have any 'on-Click action' bound to them anyways 2021-06-17 15:03:21 +00:00
Piyush Aggarwal
98077b86d6 indicator: replace send file invocation with urlhandler 2021-06-17 15:03:21 +00:00
Piyush Aggarwal
de02b9b50e systray: add dynamic icon support for connectivity action 2021-06-17 15:03:21 +00:00