Thu, 29 Jun 2017 15:33:29 -0500
gtkidle: Port XScreensaver to DBus ScreenSaver interfaces
Modern Linux desktops use one of 3 DBus interfaces for querying if
the screensaver is currently active. There's a FreeDesktop one, a
GNOME one, and a KDE one. Rather than querying XScreensaver, which
may not be available, such as with Wayland, this patch ports Pidgin's
idle checking function to use these modern DBus interfaces.
Because Gio includes built-in DBus API, this patch also drops the
guards around pidgin_get_time_idle(), which also re-enables the
Win32 code which wasn't enabled with the previous guards.
|
20147
66f05a854eee
applied changes from 8a731bbd0197fbcc91a705c2d8f528154216defa
Richard Laager <rlaager@pidgin.im>
parents:
19859
diff
changeset
|
1 | /* pidgin |
| 11475 | 2 | * |
| 15572 | 3 | * Pidgin is the legal property of its developers, whose names are too numerous |
| 11475 | 4 | * to list here. Please refer to the COPYRIGHT file distributed with this |
| 5 | * source distribution. | |
| 6 | * | |
| 7 | * This program is free software; you can redistribute it and/or modify | |
| 8 | * it under the terms of the GNU General Public License as published by | |
| 9 | * the Free Software Foundation; either version 2 of the License, or | |
| 10 | * (at your option) any later version. | |
| 11 | * | |
| 12 | * This program is distributed in the hope that it will be useful, | |
| 13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
| 14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
| 15 | * GNU General Public License for more details. | |
| 16 | * | |
| 17 | * You should have received a copy of the GNU General Public License | |
| 18 | * along with this program; if not, write to the Free Software | |
|
19859
71d37b57eff2
The FSF changed its address a while ago; our files were out of date.
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
15931
diff
changeset
|
19 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA |
| 11475 | 20 | */ |
| 21 | ||
|
15562
8c8249fe5e3c
gaim_gtk to pidgin. I hope
Sean Egan <seanegan@pidgin.im>
parents:
15435
diff
changeset
|
22 | #ifndef _PIDGINWHITEBOARD_H_ |
|
8c8249fe5e3c
gaim_gtk to pidgin. I hope
Sean Egan <seanegan@pidgin.im>
parents:
15435
diff
changeset
|
23 | #define _PIDGINWHITEBOARD_H_ |
|
35451
206524351826
Add sections for finch and re-arrange its doc index
Ankit Vani <a@nevitus.org>
parents:
35405
diff
changeset
|
24 | /** |
|
206524351826
Add sections for finch and re-arrange its doc index
Ankit Vani <a@nevitus.org>
parents:
35405
diff
changeset
|
25 | * SECTION:gtkwhiteboard |
|
206524351826
Add sections for finch and re-arrange its doc index
Ankit Vani <a@nevitus.org>
parents:
35405
diff
changeset
|
26 | * @section_id: pidgin-gtkwhiteboard |
|
206524351826
Add sections for finch and re-arrange its doc index
Ankit Vani <a@nevitus.org>
parents:
35405
diff
changeset
|
27 | * @short_description: <filename>gtkwhiteboard.h</filename> |
|
206524351826
Add sections for finch and re-arrange its doc index
Ankit Vani <a@nevitus.org>
parents:
35405
diff
changeset
|
28 | * @title: Whiteboard Frontend |
|
206524351826
Add sections for finch and re-arrange its doc index
Ankit Vani <a@nevitus.org>
parents:
35405
diff
changeset
|
29 | */ |
| 11475 | 30 | |
| 15577 | 31 | #include "pidgin.h" |
| 11475 | 32 | |
|
32790
b95c7c504118
Add G_BEGIN/END_DECLS to Pidgin public headers, most of which did
Elliott Sales de Andrade <qulogic@pidgin.im>
parents:
20147
diff
changeset
|
33 | G_BEGIN_DECLS |
| 11475 | 34 | |
|
11802
b97b3fea95ce
[gaim-migrate @ 14093]
Gary Kramlich <grim@reaperworld.com>
parents:
11475
diff
changeset
|
35 | /*****************************************************************************/ |
| 35472 | 36 | /* PidginWhiteboard API */ |
|
11802
b97b3fea95ce
[gaim-migrate @ 14093]
Gary Kramlich <grim@reaperworld.com>
parents:
11475
diff
changeset
|
37 | /*****************************************************************************/ |
| 11475 | 38 | |
|
11802
b97b3fea95ce
[gaim-migrate @ 14093]
Gary Kramlich <grim@reaperworld.com>
parents:
11475
diff
changeset
|
39 | /** |
|
35405
d3f9e6dad44b
Convert docs from doxygen to gtk-doc format for UI headers that change in .plugins
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
40 | * pidgin_whiteboard_get_ui_ops: |
|
d3f9e6dad44b
Convert docs from doxygen to gtk-doc format for UI headers that change in .plugins
Ankit Vani <a@nevitus.org>
parents:
35393
diff
changeset
|
41 | * |
|
11802
b97b3fea95ce
[gaim-migrate @ 14093]
Gary Kramlich <grim@reaperworld.com>
parents:
11475
diff
changeset
|
42 | * Gets the GtkWhiteboard UI Operations. |
|
b97b3fea95ce
[gaim-migrate @ 14093]
Gary Kramlich <grim@reaperworld.com>
parents:
11475
diff
changeset
|
43 | * |
|
35393
00f876b129bc
Initial replacements for gtk-doc style comments
Ankit Vani <a@nevitus.org>
parents:
33167
diff
changeset
|
44 | * Returns: The GtkWhiteboard UI Operations. |
|
11802
b97b3fea95ce
[gaim-migrate @ 14093]
Gary Kramlich <grim@reaperworld.com>
parents:
11475
diff
changeset
|
45 | */ |
|
35543
a0f314250ac6
Hide PidginWhiteboard API
Tomasz Wasilczyk <twasilczyk@pidgin.im>
parents:
35500
diff
changeset
|
46 | PurpleWhiteboardUiOps *pidgin_whiteboard_get_ui_ops(void); |
| 11475 | 47 | |
|
32790
b95c7c504118
Add G_BEGIN/END_DECLS to Pidgin public headers, most of which did
Elliott Sales de Andrade <qulogic@pidgin.im>
parents:
20147
diff
changeset
|
48 | G_END_DECLS |
| 11475 | 49 | |
|
15562
8c8249fe5e3c
gaim_gtk to pidgin. I hope
Sean Egan <seanegan@pidgin.im>
parents:
15435
diff
changeset
|
50 | #endif /* _PIDGINWHITEBOARD_H_ */ |