--- unity-settings-daemon-15.04.1+19.04.20190209.orig/configure.ac +++ unity-settings-daemon-15.04.1+19.04.20190209/configure.ac @@ -397,6 +397,21 @@ PKG_CHECK_MODULES(SHARING, gio-2.0 $NM_MODULE) # --------------------------------------------------------------------------- +# Rfkill +# --------------------------------------------------------------------------- + +AC_ARG_ENABLE(rfkill, + AS_HELP_STRING([--disable-rfkill], [disable rfkill support (default: enabled)]),, + enable_rfkill=yes, enabled_rfkill=no) + +if test x"$enable_rfkill" != x"no" ; then + AC_CHECK_HEADERS([linux/rfkill.h],, + AC_MSG_ERROR([RFKill headers not found but rfkill support requested])) +fi + +AM_CONDITIONAL(BUILD_RFKILL, [test x"$enable_rfkill" = x"yes"]) + +# --------------------------------------------------------------------------- # Enable Profiling # --------------------------------------------------------------------------- AC_ARG_ENABLE(profiling, @@ -515,6 +530,7 @@ plugins/mouse/Makefile plugins/orientation/Makefile plugins/remote-display/Makefile +plugins/rfkill/Makefile plugins/screensaver-proxy/Makefile plugins/sharing/Makefile plugins/smartcard/Makefile @@ -565,6 +581,7 @@ Smartcard support: ${have_smartcard_support} Cups support: ${enable_cups} Wacom support: ${have_wacom} + RFKill support: ${enable_rfkill} ${NSS_DATABASE:+\ System nssdb: ${NSS_DATABASE} }\ --- unity-settings-daemon-15.04.1+19.04.20190209.orig/debian/changelog +++ unity-settings-daemon-15.04.1+19.04.20190209/debian/changelog @@ -0,0 +1,755 @@ +unity-settings-daemon (15.04.1+19.04.20190209-0ubuntu3) eoan; urgency=medium + + * Unity-control-center has been ported away from libnm-glib to libnm 1.2. + + -- Khurshid Alam Fri, 17 May 2019 09:28:07 +0200 + +unity-settings-daemon (15.04.1+19.04.20190209-0ubuntu2) disco; urgency=medium + + [ Khurshid Alam ] + * Unity uses legacy key-grabber code. But since artful unity isn't the + default session anymore and DESKTOP_SESSION changed from ubuntu to unity. + Fixes LP: #1755106 LP: #1188569 LP: #1727842 + + -- Sebastien Bacher Fri, 01 Mar 2019 17:53:16 +0100 + +unity-settings-daemon (15.04.1+19.04.20190209-0ubuntu1) disco; urgency=medium + + [ Khurshid Alam ] + * Transition from gnome-settings-daemon-schemas to gnome-settings- + daemon-common. Fixes LP: #1811118 (LP: #1811118) + + -- Jeremy Bicha Sat, 09 Feb 2019 02:33:41 +0000 + +unity-settings-daemon (15.04.1+19.04.20181122-0ubuntu1) disco; urgency=medium + + [ Khurshid Alam ] + * Add sharing plugin (LP: #1741027) + + -- Marco Trevisan (Treviño) Thu, 22 Nov 2018 00:21:48 +0000 + +unity-settings-daemon (15.04.1+18.04.20180413-0ubuntu4) disco; urgency=medium + + [ Dariusz Gadomski ] + * gnome-settings-daemon/display-name.c: + - some vendors record the screen ratio (e.g 16/9) in the EDID instead + of including the screen size, detect those cases and display + the product name instead of the screen diagonal. (lp: #1755490) + + -- Sebastien Bacher Tue, 20 Nov 2018 16:07:31 +0100 + +unity-settings-daemon (15.04.1+18.04.20180413-0ubuntu2) cosmic; urgency=medium + + [ Kai-Heng Feng ] + * power: Choose correct backlight device on laptops with hybrid graphics + (LP: #1683445) + Backported from gnome-settings-daemon commit ed7c2744 + + -- Sebastien Bacher Tue, 03 Jul 2018 11:27:01 +0200 + +unity-settings-daemon (15.04.1+18.04.20180413-0ubuntu1) bionic; urgency=medium + + [ Marco Trevisan (Treviño) ] + * gsd-rr-config: rename monitor config files to unity-monitors.xml* + (LP: #1763806) + * debian: + - build-depends on dh-migrations and run dh_migrations on post-install + - add debian/unity-settings-daemon.migrations to install migration files + * scripts/01-usd-migration-monitors-xml.sh: + - Move monitors.xml to unity-monitors.xml if migration is needed + (LP: #1763806) + + [ Robert Ancell ] + * Support new AccountsService method of setting background file. + + -- Marco Trevisan (Treviño) Fri, 13 Apr 2018 21:33:54 +0000 + +unity-settings-daemon (15.04.1+18.04.20180216-0ubuntu1) bionic; urgency=medium + + * No-change rebuild against latest gnome-desktop3 + + -- Jeremy Bicha Fri, 16 Feb 2018 01:57:58 +0000 + +unity-settings-daemon (15.04.1+18.04.20180214.1-0ubuntu1) bionic; urgency=medium + + [ Khurshid Alam ] + * gtk_icon_info_free has been deprecated since gtk-3.8. Replace it + with g_object_unref (LP: #1747154) + + [ Robert Ancell ] + * Remove obsolete --enable-systemd compile flag + + -- Jeremy Bicha Wed, 14 Feb 2018 12:41:27 +0000 + +unity-settings-daemon (15.04.1+17.10.20171003-0ubuntu1) artful; urgency=medium + + * XSettings: under unity use com.ubuntu.user-interface.desktop keys + for scaling settings + + -- Marco Trevisan (Treviño) Tue, 03 Oct 2017 06:05:23 +0000 + +unity-settings-daemon (15.04.1+17.04.20170619-0ubuntu3) artful; urgency=medium + + * debian/control: use 'X-Ubuntu-Use-Langpack: yes' since the indicator + is now in universe, this way the translations are still available on + launchpad and exported to the langpacks + + -- Sebastien Bacher Wed, 06 Sep 2017 16:47:19 +0200 + +unity-settings-daemon (15.04.1+17.04.20170619-0ubuntu2) artful; urgency=medium + + * remove debian/unity-settings-daemon.gsettings-override: the key combination + is already upstream's default. + + -- Didier Roche Mon, 07 Aug 2017 15:11:27 +0200 + +unity-settings-daemon (15.04.1+17.04.20170619-0ubuntu1) artful; urgency=medium + + * Rename ubuntu-session systemd target to unity-session to inline with + new session name: + - ship unity-settings-daemon service symlink in the new systemd target. + - Breaks against older version of ubuntu-session, now that unity-session + provides that new systemd target name. + + -- Didier Roche Mon, 19 Jun 2017 11:04:53 +0200 + +unity-settings-daemon (15.04.1+17.04.20170418-0ubuntu1) zesty; urgency=medium + + * Fix calculator keyboard key by adapting to gnome-calculator 3.24 + .desktop rename (LP: #1676431) + + -- Jeremy Bicha Tue, 18 Apr 2017 11:58:34 +0000 + +unity-settings-daemon (15.04.1+17.04.20170328-0ubuntu1) zesty; urgency=medium + + [ Chris Coulson ] + * Filter out outputs that don't have any corresponding CRTCs or modes. + (LP: #1542699) + + -- Łukasz Zemczak Tue, 28 Mar 2017 08:18:02 +0000 + +unity-settings-daemon (15.04.1+17.04.20170322-0ubuntu1.1) zesty; urgency=medium + + * Revert drop updates plugin (LP: #1675612) + + -- Robert Ancell Fri, 24 Mar 2017 16:40:30 +1300 + +unity-settings-daemon (15.04.1+17.04.20170322-0ubuntu1) zesty; urgency=medium + + * Drop updates plugin (handled by GNOME Software, dropped by gnome- + settings-daemon now, and long-disabled in Ubuntu) + * Drop dependency on gnome-common to fix FTBFS (backported from gnome- + settings-daemon) + + -- Jeremy Bicha Wed, 22 Mar 2017 20:00:38 +0000 + +unity-settings-daemon (15.04.1+16.10.20161003-0ubuntu1) yakkety; urgency=medium + + [ Dmitry Shachnev ] + * Upstart: Split XDG_CURRENT_DESKTOP properly and start only on Unity + sessions + + [ Iain Lane ] + * Check XDG_CURRENT_DESKTOP properly in the keyboard plugin (LP: + #1554878) + + -- iain@orangesquash.org.uk Mon, 03 Oct 2016 10:15:27 +0000 + +unity-settings-daemon (15.04.1+16.10.20160819-0ubuntu2) yakkety; urgency=medium + + * Add systemd user unit. + * Install u-s-d.service into ubuntu-session.target.wants and keep u-s-d.conf + as a stub until unity7 gets a systemd service. + + -- Martin Pitt Mon, 22 Aug 2016 15:07:09 +0200 + +unity-settings-daemon (15.04.1+16.10.20160819-0ubuntu1) yakkety; urgency=medium + + [ Alberts Muktupāvels ] + * Use automatic scaling in GNOME Flashback session. + + -- Dmitry Shachnev Fri, 19 Aug 2016 17:47:36 +0000 + +unity-settings-daemon (15.04.1+16.10.20160615-0ubuntu1) yakkety; urgency=medium + + [ Kai-Heng Feng ] + * SettingsManager: Queue up signals before getting D-Bus connection. + (LP: #1571640) + + [ Marco Trevisan (Treviño) ] + * GsdPowerManager: use proper return value for upower_kbd_toggle + wherever we use it (LP: #1592816) + + -- Marco Trevisan (Treviño) Wed, 15 Jun 2016 15:55:39 +0000 + +unity-settings-daemon (15.04.1+16.10.20160613-0ubuntu1) yakkety; urgency=medium + + [ Marco Trevisan (Treviño) ] + * PowerManager: connect to keyboard BrightnessChanged signal to update + the cached current value properly (LP: #1510344) + * GsdPowerManager: don't cache kbd backlight current value (LP: + #1583861) + * common: backport g-s-d commits for having single shared dbus proxies + * ScreensaverProxy: redirect supported calls to gnome screensaver APIs + (LP: #1415265, #1584161) + + [ Robert Ancell ] + * Correctly check value of XDG_CURRENT_DESKTOP. + * Remove code for disabling plugin under GNOME Shell - they don't use + u-s-d. + * Drop print notifications - not used under Unity. + + [ Sebastien Bacher ] + * power: '0' keyboard backlight is a valid value (LP: #1510344) + * Don't hit an xerror when a device is removed while being configured + (LP: #1503758) + * wacom: don't segfault when a device is removed while being + configured. (LP: #1439427) + * power: fix crasher when the plugin is unloaded (LP: #1567116) + * power: Add sound notification on power plug/unplug + + -- Marco Trevisan (Treviño) Mon, 13 Jun 2016 11:31:26 +0000 + +unity-settings-daemon (15.04.1+16.04.20160209-0ubuntu1) xenial; urgency=medium + + * Restore the scaling on the greeter, the menu placement is correct + now (LP: #1286878) + + -- Sebastien Bacher Tue, 09 Feb 2016 10:03:45 +0000 + +unity-settings-daemon (15.04.1+16.04.20160201-0ubuntu1) xenial; urgency=medium + + [ CI Train Bot ] + * No-change rebuild. + + -- Łukasz Zemczak Mon, 01 Feb 2016 12:39:42 +0000 + +unity-settings-daemon (15.04.1+16.04.20160121-0ubuntu2) xenial; urgency=medium + + * Multiarchify the library packages. + + -- Matthias Klose Thu, 28 Jan 2016 18:08:04 +0100 + +unity-settings-daemon (15.04.1+16.04.20160121-0ubuntu1) xenial; urgency=medium + + * Revert part of the previous upload, since it broke keyboard + shortcuts in some applications. + + -- Iain Lane Thu, 21 Jan 2016 11:03:46 +0000 + +unity-settings-daemon (15.04.1+16.04.20160119-0ubuntu1) xenial; urgency=medium + + [ William Hua ] + * plugins/keyboard/gsd-keyboard-manager.c: + - Fix shortcuts for non-latin keyboard layouts in certain programs, + but only when the user's layout switching shortcuts are not + Shift_L, Shift_R, Shift_L, or Shift_R (LP: #1226962) + + [ Rui Matos ] + * power: Fix a crash when reading invalid backlight values + + [ Sebastien Bacher ] + * keyboard: Avoid warning when bell-custom-file changes + + -- Iain Lane Tue, 19 Jan 2016 17:08:48 +0000 + +unity-settings-daemon (15.04.1+16.04.20151214-0ubuntu1) xenial; urgency=medium + + [ David Henningsson ] + * Update PulseAudio port names to fix LP: #1521664 (LP: #1521664) + + -- Sebastien Bacher Mon, 14 Dec 2015 10:02:41 +0000 + +unity-settings-daemon (15.04.1+16.04.20151118.1-0ubuntu2) xenial; urgency=high + + * Fix build-dependencies to use new libystemd-dev package.name. + + -- Dimitri John Ledkov Mon, 07 Dec 2015 10:54:09 +0000 + +unity-settings-daemon (15.04.1+16.04.20151118.1-0ubuntu1) xenial; urgency=medium + + [ Shih-Yuan Lee (FourDollars) ] + * power: On raw backlight types, clamp the value to a minumum (LP: + #1381625) gsd-rr: Apply the similar method from power plugin to fix + the lowest brightness issue. (LP: #1381625) (LP: #1381625) + + -- Shih-Yuan Lee Wed, 18 Nov 2015 09:36:58 +0000 + +unity-settings-daemon (15.04.1+16.04.20151106-0ubuntu1) xenial; urgency=medium + + [ CI Train Bot ] + * New rebuild forced. + + [ Lars Uebernickel ] + * power: disconnect signals from rr_screen (LP: #1508327) + + [ Mitsuya Shibata ] + * unity-settings-daemon should initialize org.gnome.desktop.input- + sources for fcitx as same as ibus when sources property is empty. + (LP: #1465535) + + [ Sebastien Bacher ] + * remove g_warning debug leftover + * wacom: backport upstream change to use correct device types + * xsettings: disconnect signal from plugin_settings + + -- Sebastien Bacher Fri, 06 Nov 2015 14:40:42 +0000 + +unity-settings-daemon (15.04.1+15.10.20151021-0ubuntu1) wily; urgency=medium + + [ Lars Uebernickel ] + * power: disconnect from device's "notify" signals (LP: #1436861) + + -- Sebastien Bacher Wed, 21 Oct 2015 11:05:04 +0000 + +unity-settings-daemon (15.04.1+15.10.20151012-0ubuntu1) wily; urgency=medium + + [ "Jan Alexander Steffens (heftig)" ] + * xsettings: Export cursor theme on X RESOURCE_MANAGER and notify X on + changes (LP: #1505161) + + [ Marco Trevisan (Treviño) ] + * xsettings: Export cursor theme on X RESOURCE_MANAGER and notify X on + changes (LP: #1505161) + + -- Marco Trevisan (Treviño) Mon, 12 Oct 2015 14:39:35 +0000 + +unity-settings-daemon (15.04.1+15.10.20151008-0ubuntu1) wily; urgency=medium + + [ Bastien Nocera ] + * housekeeping: Don't follow symlinks to subdirectories, that can lead + to data being deleted that shouldn't + * media-keys: Postpone initialisation of libcanberra + + [ Carlos Garnacho ] + * [xsettings] backport some small fixes from upstream, should fix + issues where settings changes are delayed + + [ Cosimo Cecchi ] + * housekeeping: Don't follow symlinks to subdirectories, that can lead + to data being deleted that shouldn't + + [ Florian Müllner ] + * [xsettings] backport some small fixes from upstream, should fix + issues where settings changes are delayed + + [ Jan Alexander Steffens (heftig) ] + * [xsettings] backport some small fixes from upstream, should fix + issues where settings changes are delayed + + [ Kalev Lember ] + * [xsettings] backport some small fixes from upstream, should fix + issues where settings changes are delayed + + [ Matthias Clasen ] + * [xsettings] backport some small fixes from upstream, should fix + issues where settings changes are delayed + + [ Peter Hutterer ] + * Backport changes from upstream git and + https://bugzilla.gnome.org/show_bug.cgi?id=724789 to better handle + XError + + [ Ryan Lortie ] + * [xsettings] backport some small fixes from upstream, should fix + issues where settings changes are delayed + + [ Sebastien Bacher ] + * [orientation] tweaked version of upstream fix for settings updates + * [xrandr] slightly updated version of an upstream bugfix for a + segfault issue (LP: #1298024) + + -- Sebastien Bacher Thu, 08 Oct 2015 16:15:07 +0000 + +unity-settings-daemon (15.04.1+15.10.20151001-0ubuntu1) wily; urgency=medium + + [ Robert Ancell ] + * Fix shell watch callback not being destroyed. (LP: #1501576) + + [ William Hua ] + * Don't call fcitx_input_method_activate (). It breaks fcitx' "extra + key for trigger input method" shortcut. (LP: #1494331) + + -- Sebastien Bacher Thu, 01 Oct 2015 09:45:25 +0000 + +unity-settings-daemon (15.04.1+15.10.20150930-0ubuntu1) wily; urgency=medium + + [ Rui Matos ] + * Backport upstream commit (LP: #1496656) + + -- Sebastien Bacher Wed, 30 Sep 2015 15:47:07 +0000 + +unity-settings-daemon (15.04.1+15.10.20150917-0ubuntu1) wily; urgency=medium + + [ Michael Terry ] + * Notice when unplugging a closed laptop and apply the correct policy. + (LP: #1456745) + + -- Iain Lane Thu, 17 Sep 2015 09:49:32 +0000 + +unity-settings-daemon (15.04.1+15.10.20150825-0ubuntu1) wily; urgency=medium + + [ Alberto Milone ] + * Make touchscreen mapping non-blocking, and kill it if it takes more + than 3 seconds; finally, in case of failure, try again after a few + seconds. This helps on resume from S3 (LP: #1471708). (LP: #1471708) + + -- CI Train Bot Tue, 25 Aug 2015 09:09:33 +0000 + +unity-settings-daemon (15.04.1+15.10.20150818-0ubuntu1) wily; urgency=medium + + [ Carlos Garnacho ] + * Cherry-pick upstream changes for relocated peripheral settings (LP: + #1475949) + + [ Tim Lunn ] + * Cherry-pick upstream changes for relocated peripheral settings (LP: + #1475949) + + [ darkxst ] + * Cherry-pick upstream changes for relocated peripheral settings (LP: + #1475949) + + -- CI Train Bot Tue, 18 Aug 2015 12:11:23 +0000 + +unity-settings-daemon (15.04.1+15.10.20150720-0ubuntu1) wily; urgency=medium + + [ Lars Uebernickel ] + * mouse: allow force-disabling touchpad (LP: #1454950) + * xsettings: include needed libs for test program + + -- CI Train Bot Mon, 20 Jul 2015 15:39:14 +0000 + +unity-settings-daemon (15.04.1+15.10.20150630.1-0ubuntu1) wily; urgency=medium + + [ CI Train Bot ] + * New rebuild forced. + + [ Dmitry Shachnev ] + * xsettings: fix some settings not being updated with the latest glib + + [ Marco Trevisan (Treviño) ] + * AutoMount: also try to connect to Unity Session and delay automounts + when locked (LP: #1438870) + + -- CI Train Bot Tue, 30 Jun 2015 15:48:02 +0000 + +unity-settings-daemon (15.04.1+15.04.20150408-0ubuntu1) vivid; urgency=medium + + [ Sebastien Bacher ] + * Don't scale under unity-greeter, it creates issues. That can be + revisited once bug #1286878 and #1434094 are resolved but that's not + going to be for this cycle (LP: #1434094, #1286878) + + -- CI Train Bot Wed, 08 Apr 2015 14:46:48 +0000 + +unity-settings-daemon (15.04.1+15.04.20150401-0ubuntu1) vivid; urgency=medium + + [ Ryan Tandy ] + * gsd_idle_monitor_get_idletime() has to return a value. Use the + correct macro for that. Fixes r4073. (LP: #1416081) + + [ Sebastien Bacher ] + * let the label wrap as they should in the mount dialog + + -- CI Train Bot Wed, 01 Apr 2015 10:40:40 +0000 + +unity-settings-daemon (15.04.1+15.04.20150324.1-0ubuntu1) vivid; urgency=medium + + [ CI Train Bot ] + * New rebuild forced. + + [ Sebastien Bacher ] + * use timestamp provided by compiz to run keybinding commands so focus + works (LP: #1433648) + + -- CI Train Bot Tue, 24 Mar 2015 16:09:44 +0000 + +unity-settings-daemon (15.04.1+15.04.20150318-0ubuntu1) vivid; urgency=medium + + [ Ryan Tandy ] + * Don't call XSyncQueryCounter with a null counter. Avoids a crash + under FreeNX/X2Go which don't support the IDLETIME counter. (LP: + #1416081) + + [ Sebastien Bacher ] + * Open the battery info dialog when using the corresponding hotkey. + The current code was trying to display a notification with the info + but we don't have design on how that should look like with notify- + osd so go back to what we were doing before (LP: #1432976) + * Restore code that set the scaling factor according the screen dpi, + but only when not under and Unity session. That was desactived in + r4020 because Unity is handling those values, but this is not the + case under ubiquity or unity-greeter. (LP: #1286878) + + -- CI Train Bot Wed, 18 Mar 2015 12:07:44 +0000 + +unity-settings-daemon (15.04.1+15.04.20150313-0ubuntu1) vivid; urgency=medium + + [ William Hua ] + * Remove fcitx-data from Recommends and check if the required file, + config.desc, is available at runtime. Trying to dist-upgrade + currently pulls in the fcitx-bin which is higher priority than ibus. + (LP: #1430971) + + -- CI Train Bot Fri, 13 Mar 2015 12:54:01 +0000 + +unity-settings-daemon (15.04.1+15.04.20150310-0ubuntu1) vivid; urgency=medium + + [ William Hua ] + * Basic Fcitx support. (LP: #1363150) + + -- CI Train Bot Tue, 10 Mar 2015 17:22:52 +0000 + +unity-settings-daemon (15.04.1+15.04.20150205-0ubuntu1) vivid; urgency=medium + + [ Sebastien Bacher ] + * housekeeping: set labels width, so they wrap instead of stretching + the dialog + + -- Ubuntu daily release Thu, 05 Feb 2015 11:19:40 +0000 + +unity-settings-daemon (15.04.1+15.04.20150107-0ubuntu1) vivid; urgency=low + + [ Hui Wang ] + * show correct microphone mute icon (LP: #1381856, #1389099) + + -- Ubuntu daily release Wed, 07 Jan 2015 16:55:42 +0000 + +unity-settings-daemon (15.04.1+15.04.20141128-0ubuntu1) vivid; urgency=low + + [ Bastien Nocera ] + * Remove recall check, upower doesn't support this any more and it was + causing a crash. (LP: #1397135) + + -- Ubuntu daily release Fri, 28 Nov 2014 09:48:43 +0000 + +unity-settings-daemon (15.04.1+15.04.20141127-0ubuntu1) vivid; urgency=medium + + [ Iain Lane ] + * Add patch from Tim Lunn to support upower 0.99 properly. (LP: #1394063) + + [ Dmitry Shachnev ] + * Add Gtk/DecorationLayout XSettings export (based on + org.gnome.desktop.wm.preferences button-layout GSettings key). + + -- Ubuntu daily release Thu, 27 Nov 2014 11:42:11 +0000 + +unity-settings-daemon (15.04.0+15.10.20141030-0ubuntu1) vivid; urgency=medium + + [ Tim Lunn ] + * Query logind instead of upower for "can suspend/hibernate", and rebuild + against upower 0.99. (LP: #1330037) + + [ Martin Pitt ] + * Add missing Vcs-Bzr: control field. + + -- Martin Pitt Thu, 30 Oct 2014 17:29:53 +0100 + +unity-settings-daemon (14.04.0+14.10.20141014-0ubuntu1) utopic; urgency=low + + [ Lars Uebernickel ] + * Idle monitor: fix ref counting bugs (LP: #1380278) + + -- Ubuntu daily release Tue, 14 Oct 2014 15:25:59 +0000 + +unity-settings-daemon (14.04.0+14.10.20141010-0ubuntu1) utopic; urgency=low + + [ Tim Lunn ] + * Copy in Idle Monitor from 3.10 and hook up dbus interface (LP: + #1377847) + + -- Ubuntu daily release Fri, 10 Oct 2014 08:06:04 +0000 + +unity-settings-daemon (14.04.0+14.10.20140922-0ubuntu3) utopic; urgency=medium + + * Rebuild for gnome-desktop 3.12 (LP: #1372346) + * debian/control: Drop depends gnome-settings-daemon-schemas (<< 3.10), + gnome-settings-daemon 3.12 reverts all removed keys + * Fix merge of git patch for xkb get/free info_vars + + -- Tim Lunn Mon, 29 Sep 2014 20:05:27 +1000 + +unity-settings-daemon (14.04.0+14.10.20140922-0ubuntu2) utopic; urgency=medium + + * debian/control: + - Move -dev dependencies from libunity-settings-daemon1 to + libunity-settings-daemon-dev and add it to the correct section + (LP: #1372728) + + -- Robert Ancell Wed, 24 Sep 2014 15:38:13 +1200 + +unity-settings-daemon (14.04.0+14.10.20140922-0ubuntu1) utopic; urgency=low + + [ Robert Ancell ] + * Move libgnome-desktop RandR code into u-s-d since newer versions + remove this unstable API (LP: #1372240) + + [ Rui Matos ] + * Apply git patch that pulls in code removed from gnome-desktop3 3.12 + + [ Bastien Nocera ] + * common: Check the exit status of hotplug scripts correctly + + [ Tim Lunn ] + * Apply git patch that pulls in code removed from gnome-desktop3 3.12 + + -- Ubuntu daily release Mon, 22 Sep 2014 11:29:11 +0000 + +unity-settings-daemon (14.04.0+14.10.20140605-0ubuntu2) utopic; urgency=medium + + * No-change rebuild against new colord + + -- Iain Lane Tue, 10 Jun 2014 11:36:54 +0100 + +unity-settings-daemon (14.04.0+14.10.20140605-0ubuntu1) utopic; urgency=low + + [ Alberto Milone ] + * gsd-xrandr-manager.c: do not try to map an invalid touch device on + initialisation Fixes LP: #1326636 (LP: #1326636) + + -- Ubuntu daily release Thu, 05 Jun 2014 10:21:46 +0000 + +unity-settings-daemon (14.04.0+14.10.20140604-0ubuntu1) utopic; urgency=medium + + [ Alberto Milone ] + * gsd-xrandr-manager.c: + - Add support for mapping the main touchscreen onto the laptop + display (LP: #1287341). + This makes sure that the input device knows exactly the area + that represents the display when the screen configuration + changes. Note: this doesn't cover the tablet use case. + - Add support for matching displays with touch input devices + according to the reported size. This is particularly + useful on systems that don't use embedded display connectors + i.e. all-in-one systems such as the Dell Optiplex 9030 AIO. + - This work is a partial backport of the upstream work on + touchscreens. When we finally sync with the upstream code + we can drop this. + + -- Ubuntu daily release Wed, 04 Jun 2014 15:42:47 +0000 + +unity-settings-daemon (14.04.0+14.04.20140414-0ubuntu1) trusty; urgency=low + + [ Dmitry Shachnev ] + * Backport g-s-d patch to fix consecutive xkb grp: options not being + stripped, thanks Роман Донченко. + + -- Ubuntu daily release Mon, 14 Apr 2014 10:13:11 +0000 + +unity-settings-daemon (14.04.0+14.04.20140407-0ubuntu1) trusty; urgency=low + + [ William Hua ] + * Revert regression caused by commit 4033. (LP: #1302353) + + -- Ubuntu daily release Mon, 07 Apr 2014 14:55:36 +0000 + +unity-settings-daemon (14.04.0+14.04.20140404-0ubuntu1) trusty; urgency=low + + [ William Hua ] + * Add a private DBus method that allows us to change the current input + source without saving it in GSettings. This is needed for indicator- + keyboard to temporarily switch input sources on the lock screen + without affecting the user's session input source. + + -- Ubuntu daily release Fri, 04 Apr 2014 16:20:28 +0000 + +unity-settings-daemon (14.04.0+14.04.20140402-0ubuntu1) trusty; urgency=low + + [ Jackson Doak ] + * define XF86AudioMicMute as a mic mute key + + [ William Hua ] + * Treat IBus engines with 'default' layouts as 'us'. (LP: #1298740) + + -- Ubuntu daily release Wed, 02 Apr 2014 11:06:42 +0000 + +unity-settings-daemon (14.04.0+14.04.20140310-0ubuntu2) trusty; urgency=medium + + * unity-settings-demon.user-session.upstart: Use XDG_CURRENT_DESKTOP + as the instance specifier for gnome-session upstart jobs, since + other sessions apart from ubuntu will need to use u-s-d (LP: #1224217) + + -- Tim Lunn Wed, 12 Mar 2014 16:45:51 +1100 + +unity-settings-daemon (14.04.0+14.04.20140310-0ubuntu1) trusty; urgency=low + + [ David Henningsson ] + * Fix what-did-you-plug-in dialog showing up behind other windows. + Simplify launching of "unity-control-center sound". (LP: #1287584) + + -- Ubuntu daily release Mon, 10 Mar 2014 17:25:56 +0000 + +unity-settings-daemon (14.04.0+14.04.20140228-0ubuntu1) trusty; urgency=low + + [ Sebastien Bacher ] + * Backport some small upstream bugfixes + * Enforce schemas from the same serie, some ppa are shipping newer + versions of gnome-settings-daemon which drop keys and that's leading + to reports against unity-settings-daemon. That way users are warned + and get to choose what option they want. + + [ Luke Yelavich ] + * Look for gtk-modules related files in the correct location. + + -- Ubuntu daily release Fri, 28 Feb 2014 17:08:18 +0000 + +unity-settings-daemon (14.04.0+14.04.20140225-0ubuntu1) trusty; urgency=low + + [ Lars Uebernickel ] + * media-keys: add support for allow-amplified-volume When that key is + set, the maximum volume is PA_VOLUME_UI_MAX instead of + PA_VOLUME_NORM. This makes it consistent with the sound indicator + and system settings. + + -- Ubuntu daily release Tue, 25 Feb 2014 09:33:38 +0000 + +unity-settings-daemon (14.04.0+14.04.20140221.1-0ubuntu1) trusty; urgency=low + + [ Iain Lane ] + * Instead of autodetecting the scaling factor, default to 1 if the key + is set to '0'. unity-control-center should be calculating the value + and setting this key accordingly, otherwise the Unity and gtk values + can get out of sync. + + -- Ubuntu daily release Fri, 21 Feb 2014 18:45:23 +0000 + +unity-settings-daemon (14.04.0+14.04.20140221-0ubuntu1) trusty; urgency=low + + [ Iain Lane ] + * Always use gnome-screenshot directly, not the gnome-shell screenshot + interface. We aren't using the legacy keygrabber under Unity, but + neither can we use gnome-shell's interface since Unity doesn't + implement it. (LP: #1282649) + + -- Ubuntu daily release Fri, 21 Feb 2014 13:48:58 +0000 + +unity-settings-daemon (14.04.0+14.04.20140219-0ubuntu1) trusty; urgency=low + + [ David Henningsson ] + * Handle unknown audio jack devices. + + [ William Hua ] + * Revert the legacy key grabber. (LP: #1226962) + + [ Sebastien Bacher ] + * backport upstream change to support hi-dpi screens/scaling. You can + change the scaling value by writting the + "org.gnome.desktop.interface scaling-factor" gsettings key + + -- Ubuntu daily release Wed, 19 Feb 2014 10:44:06 +0000 + +unity-settings-daemon (14.04.0-0ubuntu2) trusty; urgency=medium + + * Change power notifications from popups (expire never), to notify-osd + bubbles (default timeout). + * Start on gnome-session (ubuntu instance) only (for now). + + -- Dimitri John Ledkov Mon, 17 Feb 2014 11:35:35 +0000 + +unity-settings-daemon (14.04.0-0ubuntu1) trusty; urgency=low + + * Fork gnome-settings-daemon so we can maintain it for Unity 7 until it is + replaced by the Unity 8 equivalent. + + -- Robert Ancell Fri, 07 Feb 2014 11:44:36 +0000 --- unity-settings-daemon-15.04.1+19.04.20190209.orig/debian/compat +++ unity-settings-daemon-15.04.1+19.04.20190209/debian/compat @@ -0,0 +1 @@ +9 --- unity-settings-daemon-15.04.1+19.04.20190209.orig/debian/control +++ unity-settings-daemon-15.04.1+19.04.20190209/debian/control @@ -0,0 +1,126 @@ +Source: unity-settings-daemon +Section: gnome +Priority: optional +Maintainer: Ubuntu Desktop Team +Build-Depends: cdbs, + debhelper (>= 9), + gnome-pkg-tools, + gtk-doc-tools, + dh-autoreconf, + dh-migrations, + autotools-dev, + intltool (>= 0.37.1), + libdbus-glib-1-dev (>= 0.74), + libglib2.0-dev (>= 2.35.3), + libgtk-3-dev (>= 3.7.8), + libnm-dev (>= 1.0) [linux-any], + libnotify-dev (>= 0.7.0), + libxt-dev, + libxi-dev, + libfontconfig1-dev, + libxext-dev, + libx11-dev, + libxtst-dev, + gsettings-desktop-schemas-dev (>= 3.15.4), + libgnome-desktop-3-dev (>= 3.7.90), + libpulse-dev (>= 1:2.0), + libasound2-dev, + librsvg2-dev (>= 2.36.2), + libcanberra-gtk3-dev, + libpolkit-gobject-1-dev, + libaccountsservice-dev (>= 0.6.34), + libappindicator3-dev (>= 0.4.90), + hwdata, + libupower-glib-dev (>= 0.99.1), + libcolord-dev (>= 0.1.12), + liblcms2-dev, + libnss3-dev, + libgudev-1.0-dev, + libwacom-dev (>= 0.7), + xserver-xorg-input-wacom, + libgnomekbd-dev (>= 3.5.1), + libxklavier-dev, + libsystemd-dev (>= 183), + libibus-1.0-dev (>= 1.5.0), + fcitx-libs-dev, + gperf, + libgl1-mesa-dev, + libxkbfile-dev, + xkb-data, +Standards-Version: 3.9.3 +Vcs-Bzr: https://code.launchpad.net/~unity-settings-daemon-team/unity-settings-daemon/trunk +X-Ubuntu-Use-Langpack: yes + +Package: unity-settings-daemon +Architecture: any +Depends: ${shlibs:Depends}, + ${misc:Depends}, + accountsservice (>= 0.6.34), + gsettings-desktop-schemas (>= 3.15.4), + nautilus-data (>= 2.91.3-1), + gnome-settings-daemon-common (>= 3.16), + gsettings-ubuntu-schemas (>= 0.0.7+17.10.20170922), +Recommends: ibus (>= 1.5.0), + pulseaudio, + systemd-services +Pre-Depends: ${misc:Pre-Depends} +Breaks: rhythmbox (<< 0.11.5), + banshee (<< 0.13.2+dfsg-7), + totem (<< 2.22.0), + gnome-control-center (<< 1:3.6.3-0ubuntu35), + gnome-session (<< 3.9.90-0ubuntu6), + gnome-screensaver (<< 2.28.0), + gnome-color-manager (<< 3.0), + unity (<< 7.3.2), + unity-greeter (<< 0.2.1-0ubuntu1), + indicator-datetime (<< 12.10.3daily13.03.26), + ubuntu-session (<< 3.24.1-0ubuntu3~), +Suggests: x11-xserver-utils, + gnome-screensaver, + metacity | x-window-manager +Description: daemon handling the Unity session settings + This package contains the daemon which is responsible for setting the + various parameters of a Unity session and the applications that run + under it. It handles the following kinds of settings: + . + * Keyboard: layout, accessibility options, shortcuts, media keys + * Clipboard management + * Theming: background, icons, GTK+ applications + * Cleanup of unused files + * Mouse: cursors, speed, accessibility options + * Startup of other daemons: screensaver, sound daemon + * Typing break + . + It also sets various application settings through X resources and + freedesktop.org XSETTINGS. + +Package: unity-settings-daemon-dev +Architecture: any +Depends: ${shlibs:Depends}, + ${misc:Depends}, + libdbus-glib-1-dev (>= 0.74), + libglib2.0-dev (>= 2.35.3) +Description: Headers for building applications communicating with unity-settings-daemon + This package contains header files required to build applications that + communicate with the Unity settings daemon over D-Bus. + +Package: libunity-settings-daemon1 +Architecture: any +Multi-Arch: same +Pre-Depends: ${misc:Pre-Depends} +Depends: ${shlibs:Depends}, + ${misc:Depends} +Description: Helper library for accessing settings + This package contains a helper library for unity-control-center + +Package: libunity-settings-daemon-dev +Section: libdevel +Architecture: any +Multi-Arch: same +Depends: ${shlibs:Depends}, + ${misc:Depends}, + libunity-settings-daemon1 (= ${binary:Version}), + libglib2.0-dev, + libgtk-3-dev +Description: Helper library for accessing settings (development files) + This package contains a headers for using libunity-settings-daemon --- unity-settings-daemon-15.04.1+19.04.20190209.orig/debian/copyright +++ unity-settings-daemon-15.04.1+19.04.20190209/debian/copyright @@ -0,0 +1,72 @@ +This package was debianized by Sebastien Bacher on +Wed, 16 Jan 2008 11:12:19 +0100. + +It was downloaded from http://ftp.acc.umu.se/pub/GNOME/sources/gnome-settings-daemon + +Upstream Authors: + + Jonathan Blandford + William Jon McCann + +Copyright: + + Copyright © 2001 Ximian, Inc. + Copyright (C) 2007 William Jon McCann + Copyright (C) 2000 Helix Code, Inc + Copyright © 2007 Matthias Clasen + Copyright (C) 2007 Rodrigo Moya + Copyright (C) 2007 Anders Carlsson + Copyright © 2004 Red Hat, Inc. + Copyright 2002 Sun Microsystems, Inc. + Copyright © 2005,2006 Novell, Inc. + Copyright © 2007 The GNOME Foundation + Copyright (C) 2002-2005 - Paolo Maggi + Copyright (C) 2002 Red Hat, Inc. + Copyright 1998, 2001 Tim Janik + Copyright � 2001 Udaltsoft + Copyright (C) 2001, 2002, 2003 Bastien Nocera + Copyright (C) 2003 Ross Burton + Copyright © 2001 Jonathan Blandford + +License: + + This package is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This package is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this package; if not, write to the Free Software + Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + +On Debian systems, the complete text of the GNU General +Public License can be found in `/usr/share/common-licenses/GPL'. + +eggaccelerators.h, eggaccelerators.c + +License: + + This package is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2 of the License, or (at your option) any later version. + + This package is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with this package; if not, write to the Free Software + Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + +On Debian systems, the complete text of the GNU Lesser General +Public License can be found in `/usr/share/common-licenses/LGPL'. + +The Debian packaging is (C) 2008, Sebastien Bacher and +is licensed under the GPL, see above. --- unity-settings-daemon-15.04.1+19.04.20190209.orig/debian/gnome-update-wallpaper-cache.c +++ unity-settings-daemon-15.04.1+19.04.20190209/debian/gnome-update-wallpaper-cache.c @@ -0,0 +1,70 @@ +/* + * Copyright (C) 2010 Canonical, Ltd. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License version 3.0 for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + * + * Authored by Didier Roche + * + * Bug: https://bugs.launchpad.net/bugs/530024 + */ + +#include +#include +#define GNOME_DESKTOP_USE_UNSTABLE_API +#include + +static GOptionEntry entries[] = +{ + { NULL } +}; + +main (int argc, char *argv[]) +{ + GOptionContext *context = NULL; + GError *error = NULL; + + GdkScreen *screen; + GdkRectangle rect; + GnomeBG *bg; + GSettings *settings; + GdkPixbuf *pixbuf; + + gdk_init (&argc, &argv); + + context = g_option_context_new ("- refresh wallpaper cache"); + g_option_context_add_main_entries (context, entries, NULL); + if (!g_option_context_parse (context, &argc, &argv, &error)) { + g_printerr ("option parsing failed: %s\n", error->message); + g_option_context_free(context); + g_error_free (error); + return (1); + } + if (context) + g_option_context_free (context); + + /* cache only the first monitor */ + screen = gdk_screen_get_default (); + gdk_screen_get_monitor_geometry (screen, 0, &rect); + + bg = gnome_bg_new (); + settings = g_settings_new ("org.gnome.desktop.background"); + gnome_bg_load_from_preferences (bg, settings); + + pixbuf = gdk_pixbuf_new (GDK_COLORSPACE_RGB, FALSE, 8, rect.width, rect.height); + gnome_bg_draw (bg, pixbuf, screen, FALSE); + + g_object_unref (settings); + + return (0); +} --- unity-settings-daemon-15.04.1+19.04.20190209.orig/debian/libunity-settings-daemon1.install +++ unity-settings-daemon-15.04.1+19.04.20190209/debian/libunity-settings-daemon1.install @@ -0,0 +1 @@ +usr/lib/*/libunity-settings-daemon.so.* --- unity-settings-daemon-15.04.1+19.04.20190209.orig/debian/libunity-settings-daemon1.symbols +++ unity-settings-daemon-15.04.1+19.04.20190209/debian/libunity-settings-daemon1.symbols @@ -0,0 +1,107 @@ +libunity-settings-daemon.so.1 libunity-settings-daemon1 #MINVER# + gsd_idle_monitor_add_idle_watch@Base 14.04.0 + gsd_idle_monitor_add_user_active_watch@Base 14.04.0 + gsd_idle_monitor_get_core@Base 14.10 + gsd_idle_monitor_get_for_device@Base 14.10 + gsd_idle_monitor_get_idletime@Base 14.04.0 + gsd_idle_monitor_get_type@Base 14.04.0 + gsd_idle_monitor_handle_xevent_all@Base 14.10 + gsd_idle_monitor_init_dbus@Base 14.10 + gsd_idle_monitor_remove_watch@Base 14.04.0 + gsd_pnp_ids_get_pnp_id@Base 14.04.0 + gsd_pnp_ids_get_type@Base 14.04.0 + gsd_pnp_ids_new@Base 14.04.0 + gsd_rr_config_applicable@Base 14.04.0 + gsd_rr_config_apply_from_filename_with_time@Base 14.04.0 + gsd_rr_config_apply_with_time@Base 14.04.0 + gsd_rr_config_ensure_primary@Base 14.04.0 + gsd_rr_config_equal@Base 14.04.0 + gsd_rr_config_get_backup_filename@Base 14.04.0 + gsd_rr_config_get_clone@Base 14.04.0 + gsd_rr_config_get_intended_filename@Base 14.04.0 + gsd_rr_config_get_outputs@Base 14.04.0 + gsd_rr_config_get_type@Base 14.04.0 + gsd_rr_config_load_current@Base 14.04.0 + gsd_rr_config_load_filename@Base 14.04.0 + gsd_rr_config_match@Base 14.04.0 + gsd_rr_config_new_current@Base 14.04.0 + gsd_rr_config_new_stored@Base 14.04.0 + gsd_rr_config_sanitize@Base 14.04.0 + gsd_rr_config_save@Base 14.04.0 + gsd_rr_config_set_clone@Base 14.04.0 + gsd_rr_crtc_can_drive_output@Base 14.04.0 + gsd_rr_crtc_get_current_mode@Base 14.04.0 + gsd_rr_crtc_get_current_rotation@Base 14.04.0 + gsd_rr_crtc_get_gamma@Base 14.04.0 + gsd_rr_crtc_get_id@Base 14.04.0 + gsd_rr_crtc_get_position@Base 14.04.0 + gsd_rr_crtc_get_rotations@Base 14.04.0 + gsd_rr_crtc_get_type@Base 14.04.0 + gsd_rr_crtc_set_config_with_time@Base 14.04.0 + gsd_rr_crtc_set_gamma@Base 14.04.0 + gsd_rr_crtc_supports_rotation@Base 14.04.0 + gsd_rr_error_quark@Base 14.04.0 + gsd_rr_mode_get_freq@Base 14.04.0 + gsd_rr_mode_get_height@Base 14.04.0 + gsd_rr_mode_get_id@Base 14.04.0 + gsd_rr_mode_get_type@Base 14.04.0 + gsd_rr_mode_get_width@Base 14.04.0 + gsd_rr_output_can_clone@Base 14.04.0 + gsd_rr_output_get_backlight@Base 14.04.0 + gsd_rr_output_get_backlight_max@Base 14.04.0 + gsd_rr_output_get_backlight_min@Base 14.04.0 + gsd_rr_output_get_connector_type@Base 14.04.0 + gsd_rr_output_get_crtc@Base 14.04.0 + gsd_rr_output_get_current_mode@Base 14.04.0 + gsd_rr_output_get_display_name@Base 14.04.0 + gsd_rr_output_get_edid_data@Base 14.04.0 + gsd_rr_output_get_height_mm@Base 14.04.0 + gsd_rr_output_get_id@Base 14.04.0 + gsd_rr_output_get_ids_from_edid@Base 14.04.0 + gsd_rr_output_get_is_primary@Base 14.04.0 + gsd_rr_output_get_name@Base 14.04.0 + gsd_rr_output_get_position@Base 14.04.0 + gsd_rr_output_get_preferred_mode@Base 14.04.0 + gsd_rr_output_get_type@Base 14.04.0 + gsd_rr_output_get_width_mm@Base 14.04.0 + gsd_rr_output_info_get_aspect_ratio@Base 14.04.0 + gsd_rr_output_info_get_display_name@Base 14.04.0 + gsd_rr_output_info_get_geometry@Base 14.04.0 + gsd_rr_output_info_get_name@Base 14.04.0 + gsd_rr_output_info_get_preferred_height@Base 14.04.0 + gsd_rr_output_info_get_preferred_width@Base 14.04.0 + gsd_rr_output_info_get_primary@Base 14.04.0 + gsd_rr_output_info_get_product@Base 14.04.0 + gsd_rr_output_info_get_refresh_rate@Base 14.04.0 + gsd_rr_output_info_get_rotation@Base 14.04.0 + gsd_rr_output_info_get_serial@Base 14.04.0 + gsd_rr_output_info_get_type@Base 14.04.0 + gsd_rr_output_info_get_vendor@Base 14.04.0 + gsd_rr_output_info_is_active@Base 14.04.0 + gsd_rr_output_info_is_connected@Base 14.04.0 + gsd_rr_output_info_set_active@Base 14.04.0 + gsd_rr_output_info_set_geometry@Base 14.04.0 + gsd_rr_output_info_set_primary@Base 14.04.0 + gsd_rr_output_info_set_refresh_rate@Base 14.04.0 + gsd_rr_output_info_set_rotation@Base 14.04.0 + gsd_rr_output_is_connected@Base 14.04.0 + gsd_rr_output_is_laptop@Base 14.04.0 + gsd_rr_output_list_modes@Base 14.04.0 + gsd_rr_output_set_backlight@Base 14.04.0 + gsd_rr_output_supports_mode@Base 14.04.0 + gsd_rr_screen_get_crtc_by_id@Base 14.04.0 + gsd_rr_screen_get_dpms_mode@Base 14.04.0 + gsd_rr_screen_get_output_by_id@Base 14.04.0 + gsd_rr_screen_get_output_by_name@Base 14.04.0 + gsd_rr_screen_get_ranges@Base 14.04.0 + gsd_rr_screen_get_timestamps@Base 14.04.0 + gsd_rr_screen_get_type@Base 14.04.0 + gsd_rr_screen_list_clone_modes@Base 14.04.0 + gsd_rr_screen_list_crtcs@Base 14.04.0 + gsd_rr_screen_list_modes@Base 14.04.0 + gsd_rr_screen_list_outputs@Base 14.04.0 + gsd_rr_screen_new@Base 14.04.0 + gsd_rr_screen_refresh@Base 14.04.0 + gsd_rr_screen_set_dpms_mode@Base 14.04.0 + gsd_rr_screen_set_primary_output@Base 14.04.0 + gsd_rr_screen_set_size@Base 14.04.0 --- unity-settings-daemon-15.04.1+19.04.20190209.orig/debian/rules +++ unity-settings-daemon-15.04.1+19.04.20190209/debian/rules @@ -0,0 +1,38 @@ +#!/usr/bin/make -f + +include /usr/share/cdbs/1/rules/debhelper.mk +include /usr/share/cdbs/1/rules/utils.mk +include /usr/share/cdbs/1/class/gnome.mk + +LDFLAGS += -Wl,-O1 -Wl,-z,defs -Wl,--warn-unresolved-symbols -Wl,--as-needed + +DEB_DH_MAKESHLIBS_ARGS_ALL += -X/usr/lib/unity-settings-daemon-1.0 +DEB_CONFIGURE_SCRIPT := ./autogen.sh +DEB_CONFIGURE_EXTRA_FLAGS = --disable-packagekit --enable-ibus --enable-fcitx --enable-network-manager + +build/unity-settings-daemon:: + gcc -o gnome-settings-daemon/gnome-update-wallpaper-cache debian/gnome-update-wallpaper-cache.c `pkg-config --cflags --libs glib-2.0 gdk-3.0 gdk-x11-3.0 gio-2.0 gnome-desktop-3.0` + +# don't configure with --libdir, but move the files manually, because +# other files in /usr/lib/ should not change +common-install-impl:: + mkdir -p debian/tmp/usr/lib/$(DEB_HOST_MULTIARCH) + mv debian/tmp/usr/lib/lib*.so* debian/tmp/usr/lib/pkgconfig \ + debian/tmp/usr/lib/$(DEB_HOST_MULTIARCH) + +install/unity-settings-daemon:: + /usr/bin/install -c gnome-settings-daemon/gnome-update-wallpaper-cache 'debian/tmp/usr/lib/unity-settings-daemon' + install -m 644 -D debian/unity-settings-daemon.user-session.upstart debian/unity-settings-daemon/usr/share/upstart/sessions/unity-settings-daemon.conf + install -m 644 -D debian/unity-settings-daemon.user-session.desktop debian/unity-settings-daemon/usr/share/upstart/xdg/autostart/unity-settings-daemon.desktop + +binary-install/unity-settings-daemon:: + find debian -name '*.a' -delete + find debian -name '*.la' -delete + +binary-post-install/unity-settings-daemon:: + dh_migrations + +common-binary-post-install-arch:: list-missing + +clean:: + rm -f gnome-settings-daemon/gnome-update-wallpaper-cache --- unity-settings-daemon-15.04.1+19.04.20190209.orig/debian/source/format +++ unity-settings-daemon-15.04.1+19.04.20190209/debian/source/format @@ -0,0 +1 @@ +1.0 --- unity-settings-daemon-15.04.1+19.04.20190209.orig/debian/source_unity-settings-daemon.py +++ unity-settings-daemon-15.04.1+19.04.20190209/debian/source_unity-settings-daemon.py @@ -0,0 +1,16 @@ +import os, apport.packaging, re +from apport.hookutils import * + +def add_info(report): + # the issue is not in the unity-settings-daemon code so reassign + if "Stacktrace" in report and "/usr/libg/nome-settings-daemon-3.0" in report["Stacktrace"]: + for words in report["Stacktrace"].split(): + if words.startswith("/usr/lib/unity-settings-daemon-3.0"): + if apport.packaging.get_file_package(words) != 'unity-settings-daemon': + report.add_package_info(apport.packaging.get_file_package(words)) + return + # update the title to reflect the component and tab + component = re.compile("lib(\w*).so").search(words).groups(1)[0] + report['Title'] = '[%s]: %s' % (component, report.get('Title', report.standard_title())) + report['Tags'] = '%s %s' % (report.get('Tags', ""), component) + break # Stop on the first .so that's the interesting one --- unity-settings-daemon-15.04.1+19.04.20190209.orig/debian/unity-settings-daemon-dev.install +++ unity-settings-daemon-15.04.1+19.04.20190209/debian/unity-settings-daemon-dev.install @@ -0,0 +1,3 @@ +usr/include +usr/lib/*/pkgconfig +usr/lib/*/libunity-settings-daemon.so --- unity-settings-daemon-15.04.1+19.04.20190209.orig/debian/unity-settings-daemon.install +++ unity-settings-daemon-15.04.1+19.04.20190209/debian/unity-settings-daemon.install @@ -0,0 +1,9 @@ +etc +usr/lib/unity-settings-daemon* +usr/share/icons +usr/share/locale +usr/share/unity-settings-daemon +usr/share/polkit-1 +debian/source_unity-settings-daemon.py /usr/share/apport/package-hooks +debian/user/unity-settings-daemon.service /usr/lib/systemd/user/ +debian/user/unity-settings-daemon.override /usr/share/upstart/systemd-session/upstart/ --- unity-settings-daemon-15.04.1+19.04.20190209.orig/debian/unity-settings-daemon.links +++ unity-settings-daemon-15.04.1+19.04.20190209/debian/unity-settings-daemon.links @@ -0,0 +1,3 @@ +usr/lib/unity-settings-daemon/unity-settings-daemon usr/bin/unity-settings-daemon +# needed until unity7 gets a systemd unit with Requires=u-s-d +/usr/lib/systemd/user/unity-settings-daemon.service /usr/lib/systemd/user/unity-session.target.wants/unity-settings-daemon.service --- unity-settings-daemon-15.04.1+19.04.20190209.orig/debian/unity-settings-daemon.maintscript +++ unity-settings-daemon-15.04.1+19.04.20190209/debian/unity-settings-daemon.maintscript @@ -0,0 +1,7 @@ +rm_conffile /etc/gnome/config/Editres.ad 3.6.3-0ubuntu3~ +rm_conffile /etc/gnome/config/Emacs.ad 3.6.3-0ubuntu3~ +rm_conffile /etc/gnome/config/General.ad 3.6.3-0ubuntu3~ +rm_conffile /etc/gnome/config/Motif.ad 3.6.3-0ubuntu3~ +rm_conffile /etc/gnome/config/Tk.ad 3.6.3-0ubuntu3~ +rm_conffile /etc/gnome/config/Xaw.ad 3.6.3-0ubuntu3~ +rm_conffile /etc/dbus-1/system.d/org.gnome.SettingsDaemon.DateTimeMechanism.conf 3.6.4-0ubuntu7~ --- unity-settings-daemon-15.04.1+19.04.20190209.orig/debian/unity-settings-daemon.migrations +++ unity-settings-daemon-15.04.1+19.04.20190209/debian/unity-settings-daemon.migrations @@ -0,0 +1 @@ +scripts/*-usd-migration-* --- unity-settings-daemon-15.04.1+19.04.20190209.orig/debian/unity-settings-daemon.postinst +++ unity-settings-daemon-15.04.1+19.04.20190209/debian/unity-settings-daemon.postinst @@ -0,0 +1,21 @@ +#! /bin/sh +set -e + +#DEBHELPER# + +# Remove obsolete conffiles + +case "$1" in +configure) + if dpkg --compare-versions "$2" lt-nl "2.24.1"; then + rm -rf /etc/gnome/config/xrdb + fi + if dpkg --compare-versions "$2" lt-nl "2.26.1"; then + rm -f /etc/xdg/autostart/gnome-settings-daemon.desktop + fi + if dpkg --compare-versions "$2" lt-nl "3.6.3-0ubuntu3"; then + if [ -d /etc/gnome/config ]; then + rmdir --ignore-fail-on-non-empty /etc/gnome/config + fi + fi +esac --- unity-settings-daemon-15.04.1+19.04.20190209.orig/debian/unity-settings-daemon.user-session.desktop +++ unity-settings-daemon-15.04.1+19.04.20190209/debian/unity-settings-daemon.user-session.desktop @@ -0,0 +1,5 @@ +[Desktop Entry] +Type=Application +Name=Unity Settings Daemon +Exec=/usr/lib/unity-settings-daemon/unity-settings-daemon +Hidden=true --- unity-settings-daemon-15.04.1+19.04.20190209.orig/debian/unity-settings-daemon.user-session.upstart +++ unity-settings-daemon-15.04.1+19.04.20190209/debian/unity-settings-daemon.user-session.upstart @@ -0,0 +1,18 @@ +description "The Unity Settings Daemon" +author "Dimitri John Ledkov " + +start on started dbus and starting gnome-session +stop on stopping gnome-session + +pre-start script + for DESKTOP in $(echo "$XDG_CURRENT_DESKTOP" | sed 's/:/ /g') + do + if [ "x$DESKTOP" = "xUnity" ]; then + exit 0 + fi + done + stop +end script + +respawn +exec /usr/lib/unity-settings-daemon/unity-settings-daemon --- unity-settings-daemon-15.04.1+19.04.20190209.orig/debian/user/unity-settings-daemon.override +++ unity-settings-daemon-15.04.1+19.04.20190209/debian/user/unity-settings-daemon.override @@ -0,0 +1,3 @@ +# FIXME: can be moved to "manual" once unity7 gets a systemd service file +# manual +exec true --- unity-settings-daemon-15.04.1+19.04.20190209.orig/debian/user/unity-settings-daemon.service +++ unity-settings-daemon-15.04.1+19.04.20190209/debian/user/unity-settings-daemon.service @@ -0,0 +1,7 @@ +[Unit] +Description=Unity Settings Daemon +PartOf=graphical-session.target + +[Service] +ExecStart=/usr/lib/unity-settings-daemon/unity-settings-daemon +Restart=on-failure --- unity-settings-daemon-15.04.1+19.04.20190209.orig/plugins/Makefile.am +++ unity-settings-daemon-15.04.1+19.04.20190209/plugins/Makefile.am @@ -48,5 +48,11 @@ disabled_plugins += wacom endif +if BUILD_RFKILL +enabled_plugins += rfkill +else +disabled_plugins += rfkill +endif + SUBDIRS = common $(enabled_plugins) DIST_SUBDIRS = $(SUBDIRS) $(disabled_plugins) --- unity-settings-daemon-15.04.1+19.04.20190209.orig/plugins/media-keys/gsd-media-keys-manager.c +++ unity-settings-daemon-15.04.1+19.04.20190209/plugins/media-keys/gsd-media-keys-manager.c @@ -223,7 +223,7 @@ GDBusConnection *connection; GCancellable *bus_cancellable; GDBusProxy *xrandr_proxy; - GCancellable *cancellable; + GCancellable *cancellable; /* Only used for XRandR operations */ guint start_idle_id; @@ -699,6 +699,7 @@ { GsdMediaKeysManager *manager = data; + g_debug ("Retrying to grab accelerators"); grab_media_keys (manager); return FALSE; } @@ -718,8 +719,10 @@ if (error) { retry = (error->code == G_DBUS_ERROR_UNKNOWN_METHOD); - if (!retry) - g_warning ("%d: %s", error->code, error->message); + if (!retry && !g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED)) + g_warning ("Failed to grab accelerators: %s (%d)", error->message, error->code); + else if (retry) + g_debug ("Failed to grab accelerators, will retry: %s (%d)", error->message, error->code); g_error_free (error); } else { int i; @@ -768,9 +771,14 @@ { GrabData *data = user_data; MediaKey *key = data->key; + GError *error = NULL; - shell_key_grabber_call_grab_accelerator_finish (SHELL_KEY_GRABBER (object), - &key->accel_id, result, NULL); + if (!shell_key_grabber_call_grab_accelerator_finish (SHELL_KEY_GRABBER (object), + &key->accel_id, result, &error)) { + if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED)) + g_warning ("Failed to grab accelerator: %s", error->message); + g_error_free (error); + } g_slice_free (GrabData, data); } @@ -838,8 +846,14 @@ gpointer user_data) { GsdMediaKeysManager *manager = user_data; - shell_key_grabber_call_ungrab_accelerator_finish (SHELL_KEY_GRABBER (object), - NULL, result, NULL); + + GError *error = NULL; + if (!shell_key_grabber_call_ungrab_accelerator_finish (SHELL_KEY_GRABBER (object), + NULL, result, &error)) { + if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED)) + g_warning ("Failed to ungrab accelerator: %s", error->message); + g_error_free (error); + } } static void @@ -1390,7 +1404,7 @@ priv->screen_saver_proxy = gnome_settings_bus_get_screen_saver_proxy (); gsd_screen_saver_call_lock (priv->screen_saver_proxy, - priv->cancellable, + priv->bus_cancellable, (GAsyncReadyCallback) on_screen_locked, manager); } @@ -2005,7 +2019,8 @@ manager->priv->cancellable = NULL; if (error != NULL) { - g_warning ("Unable to call '%s': %s", action, error->message); + if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED)) + g_warning ("Failed to complete XRandR action: %s", error->message); g_error_free (error); } else { g_variant_unref (variant); @@ -2275,7 +2290,7 @@ guint first; gint i, n; - if (g_strcmp0 (g_getenv ("DESKTOP_SESSION"), "ubuntu") != 0) + if (g_strcmp0 (g_getenv ("DESKTOP_SESSION"), "unity") != 0) if (!priv->have_legacy_keygrabber) return; @@ -2817,6 +2832,9 @@ { guint i; + g_debug ("Received accel id %u (device-id: %u, timestamp: %u", + accel_id, deviceid, timestamp); + for (i = 0; i < manager->priv->keys->len; i++) { MediaKey *key; @@ -2831,6 +2849,8 @@ do_action (manager, deviceid, key->key_type, timestamp); return; } + + g_warning ("Could not find accelerator for accel id %u", accel_id); } static void @@ -2962,12 +2982,17 @@ gpointer data) { GsdMediaKeysManager *manager = data; + GError *error = NULL; manager->priv->key_grabber = - shell_key_grabber_proxy_new_for_bus_finish (result, NULL); + shell_key_grabber_proxy_new_for_bus_finish (result, &error); - if (!manager->priv->key_grabber) + if (!manager->priv->key_grabber) { + if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED)) + g_warning ("Failed to create proxy for key grabber: %s", error->message); + g_error_free (error); return; + } g_signal_connect (manager->priv->key_grabber, "accelerator-activated", G_CALLBACK (on_accelerator_activated), manager); @@ -2979,7 +3004,7 @@ session_has_key_grabber (void) { const gchar *session = g_getenv ("DESKTOP_SESSION"); - return g_strcmp0 (session, "gnome") == 0 || g_strcmp0 (session, "ubuntu") == 0; + return g_strcmp0 (session, "gnome") == 0 || g_strcmp0 (session, "unity") == 0; } static void @@ -3379,7 +3404,8 @@ res = g_dbus_proxy_call_with_unix_fd_list_finish (proxy, &fd_list, result, &error); if (res == NULL) { - g_warning ("Unable to inhibit keypresses: %s", error->message); + if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED)) + g_warning ("Unable to inhibit keypresses: %s", error->message); g_error_free (error); } else { g_variant_get (res, "(h)", &idx); @@ -3478,7 +3504,8 @@ manager->priv->xrandr_proxy = g_dbus_proxy_new_finish (res, &error); if (manager->priv->xrandr_proxy == NULL) { - g_warning ("Failed to get proxy for XRandR operations: %s", error->message); + if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED)) + g_warning ("Failed to get proxy for XRandR operations: %s", error->message); g_error_free (error); } } @@ -3492,8 +3519,9 @@ manager->priv->power_proxy = g_dbus_proxy_new_finish (res, &error); if (manager->priv->power_proxy == NULL) { - g_warning ("Failed to get proxy for power: %s", - error->message); + if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED)) + g_warning ("Failed to get proxy for power: %s", + error->message); g_error_free (error); } } @@ -3507,8 +3535,9 @@ manager->priv->power_screen_proxy = g_dbus_proxy_new_finish (res, &error); if (manager->priv->power_screen_proxy == NULL) { - g_warning ("Failed to get proxy for power (screen): %s", - error->message); + if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED)) + g_warning ("Failed to get proxy for power (screen): %s", + error->message); g_error_free (error); } } @@ -3522,8 +3551,9 @@ manager->priv->power_keyboard_proxy = g_dbus_proxy_new_finish (res, &error); if (manager->priv->power_keyboard_proxy == NULL) { - g_warning ("Failed to get proxy for power (keyboard): %s", - error->message); + if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED)) + g_warning ("Failed to get proxy for power (keyboard): %s", + error->message); g_error_free (error); } } @@ -3536,15 +3566,11 @@ GDBusConnection *connection; GError *error = NULL; - if (manager->priv->bus_cancellable == NULL || - g_cancellable_is_cancelled (manager->priv->bus_cancellable)) { - g_warning ("Operation has been cancelled, so not retrieving session bus"); - return; - } connection = g_bus_get_finish (res, &error); if (connection == NULL) { - g_warning ("Could not get session bus: %s", error->message); + if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED)) + g_warning ("Could not get session bus: %s", error->message); g_error_free (error); return; } --- unity-settings-daemon-15.04.1+19.04.20190209.orig/plugins/rfkill/61-gnome-settings-daemon-rfkill.rules +++ unity-settings-daemon-15.04.1+19.04.20190209/plugins/rfkill/61-gnome-settings-daemon-rfkill.rules @@ -0,0 +1,8 @@ +# Get access to /dev/rfkill for users +# See https://bugzilla.redhat.com/show_bug.cgi?id=514798 +# +# Simplified by Kay Sievers +# https://bugzilla.redhat.com/show_bug.cgi?id=733326 +# See also https://bugzilla.gnome.org/show_bug.cgi?id=711373 + +KERNEL=="rfkill", SUBSYSTEM=="misc", TAG+="uaccess" --- unity-settings-daemon-15.04.1+19.04.20190209.orig/plugins/rfkill/Makefile.am +++ unity-settings-daemon-15.04.1+19.04.20190209/plugins/rfkill/Makefile.am @@ -0,0 +1,69 @@ +plugin_name = rfkill + +libexec_PROGRAMS = gsd-test-rfkill + +gsd_test_rfkill_SOURCES = \ + gsd-rfkill-manager.h \ + gsd-rfkill-manager.c \ + rfkill-glib.c \ + rfkill-glib.h \ + rfkill.h \ + test-rfkill.c + +gsd_test_rfkill_CFLAGS = \ + -I$(top_srcdir)/gnome-settings-daemon \ + -I$(top_builddir)/gnome-settings-daemon \ + -I$(top_srcdir)/plugins/common \ + -DGNOME_SETTINGS_LOCALEDIR=\""$(datadir)/locale"\" \ + $(PLUGIN_CFLAGS) \ + $(SETTINGS_PLUGIN_CFLAGS) \ + $(AM_CFLAGS) + +gsd_test_rfkill_LDADD = \ + $(top_builddir)/gnome-settings-daemon/libgsd.la \ + $(top_builddir)/plugins/common/libcommon.la \ + $(SETTINGS_PLUGIN_LIBS) + +plugin_LTLIBRARIES = librfkill.la + +librfkill_la_SOURCES = \ + gsd-rfkill-plugin.c \ + gsd-rfkill-manager.h \ + gsd-rfkill-manager.c \ + rfkill-glib.c \ + rfkill-glib.h \ + rfkill.h + +librfkill_la_CPPFLAGS = \ + -I$(top_srcdir)/gnome-settings-daemon \ + -I$(top_builddir)/gnome-settings-daemon \ + -I$(top_srcdir)/data/ \ + -DGNOME_SETTINGS_LOCALEDIR=\""$(datadir)/locale"\" \ + -DLIBEXECDIR=\""$(libexecdir)"\" \ + $(AM_CPPFLAGS) + +librfkill_la_CFLAGS = \ + $(PLUGIN_CFLAGS) \ + $(RFKILL_CFLAGS) \ + $(SETTINGS_PLUGIN_CFLAGS) \ + $(AM_CFLAGS) + +librfkill_la_LDFLAGS = \ + $(GSD_PLUGIN_LDFLAGS) + +librfkill_la_LIBADD = \ + $(RFKILL_LIBS) \ + $(SETTINGS_PLUGIN_LIBS) + +plugin_in_files = rfkill.gnome-settings-plugin.in + +plugin_DATA = $(plugin_in_files:.gnome-settings-plugin.in=.gnome-settings-plugin) + +udevrulesdir = $(prefix)/lib/udev/rules.d +udevrules_DATA = 61-gnome-settings-daemon-rfkill.rules + +EXTRA_DIST = $(plugin_in_files) $(udevrules_DATA) +CLEANFILES = $(plugin_DATA) +DISTCLEANFILES = $(plugin_DATA) + +@GSD_INTLTOOL_PLUGIN_RULE@ --- unity-settings-daemon-15.04.1+19.04.20190209.orig/plugins/rfkill/gsd-rfkill-manager.c +++ unity-settings-daemon-15.04.1+19.04.20190209/plugins/rfkill/gsd-rfkill-manager.c @@ -0,0 +1,736 @@ +/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- + * + * Copyright (C) 2007 William Jon McCann + * Copyright (C) 2010,2011 Red Hat, Inc. + * + * Author: Bastien Nocera + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, see . + * + */ + +#include "config.h" + +#include +#include + +#include "gnome-settings-plugin.h" +#include "gnome-settings-profile.h" +#include "gsd-rfkill-manager.h" +#include "rfkill-glib.h" +#include "gnome-settings-bus.h" + +#define GSD_RFKILL_MANAGER_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), GSD_TYPE_RFKILL_MANAGER, GsdRfkillManagerPrivate)) + +struct GsdRfkillManagerPrivate +{ + GDBusNodeInfo *introspection_data; + guint name_id; + GDBusConnection *connection; + GCancellable *cancellable; + + CcRfkillGlib *rfkill; + GHashTable *killswitches; + GHashTable *bt_killswitches; + + /* In addition to using the rfkill kernel subsystem + (which is exposed by wlan, wimax, bluetooth, nfc, + some platform drivers and some usb modems), we + need to go through NetworkManager, which in turn + will tell ModemManager to write the right commands + in the USB bus to take external modems down, all + from userspace. + */ + GDBusProxy *nm_client; + gboolean wwan_enabled; + GDBusObjectManager *mm_client; + gboolean wwan_interesting; + + gchar *chassis_type; +}; + +#define GSD_RFKILL_DBUS_NAME GSD_DBUS_NAME ".Rfkill" +#define GSD_RFKILL_DBUS_PATH GSD_DBUS_PATH "/Rfkill" + +static const gchar introspection_xml[] = +"" +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +""; + +static void gsd_rfkill_manager_class_init (GsdRfkillManagerClass *klass); +static void gsd_rfkill_manager_init (GsdRfkillManager *rfkill_manager); +static void gsd_rfkill_manager_finalize (GObject *object); + +G_DEFINE_TYPE (GsdRfkillManager, gsd_rfkill_manager, G_TYPE_OBJECT) + +static gpointer manager_object = NULL; + +static void +gsd_rfkill_manager_class_init (GsdRfkillManagerClass *klass) +{ + GObjectClass *object_class = G_OBJECT_CLASS (klass); + + object_class->finalize = gsd_rfkill_manager_finalize; + + g_type_class_add_private (klass, sizeof (GsdRfkillManagerPrivate)); +} + +static void +gsd_rfkill_manager_init (GsdRfkillManager *manager) +{ + manager->priv = GSD_RFKILL_MANAGER_GET_PRIVATE (manager); +} + +static gboolean +engine_get_airplane_mode_helper (GHashTable *killswitches) +{ + GHashTableIter iter; + gpointer key, value; + + if (g_hash_table_size (killswitches) == 0) + return FALSE; + + g_hash_table_iter_init (&iter, killswitches); + while (g_hash_table_iter_next (&iter, &key, &value)) { + int state; + + state = GPOINTER_TO_INT (value); + + /* A single rfkill switch that's unblocked? Airplane mode is off */ + if (state == RFKILL_STATE_UNBLOCKED) + return FALSE; + } + + return TRUE; +} + +static gboolean +engine_get_bluetooth_airplane_mode (GsdRfkillManager *manager) +{ + return engine_get_airplane_mode_helper (manager->priv->bt_killswitches); +} + +static gboolean +engine_get_bluetooth_hardware_airplane_mode (GsdRfkillManager *manager) +{ + GHashTableIter iter; + gpointer key, value; + + /* If we have no killswitches, hw airplane mode is off. */ + if (g_hash_table_size (manager->priv->bt_killswitches) == 0) + return FALSE; + + g_hash_table_iter_init (&iter, manager->priv->bt_killswitches); + while (g_hash_table_iter_next (&iter, &key, &value)) { + int state; + + state = GPOINTER_TO_INT (value); + + /* A single rfkill switch that's not hw blocked? Hw airplane mode is off */ + if (state != RFKILL_STATE_HARD_BLOCKED) { + return FALSE; + } + } + + return TRUE; +} + +static gboolean +engine_get_has_bluetooth_airplane_mode (GsdRfkillManager *manager) +{ + return (g_hash_table_size (manager->priv->bt_killswitches) > 0); +} + +static gboolean +engine_get_airplane_mode (GsdRfkillManager *manager) +{ + if (!manager->priv->wwan_interesting) + return engine_get_airplane_mode_helper (manager->priv->killswitches); + /* wwan enabled? then airplane mode is off (because an USB modem + could be on in this state) */ + return engine_get_airplane_mode_helper (manager->priv->killswitches) && !manager->priv->wwan_enabled; +} + +static gboolean +engine_get_hardware_airplane_mode (GsdRfkillManager *manager) +{ + GHashTableIter iter; + gpointer key, value; + + /* If we have no killswitches, hw airplane mode is off. */ + if (g_hash_table_size (manager->priv->killswitches) == 0) + return FALSE; + + g_hash_table_iter_init (&iter, manager->priv->killswitches); + while (g_hash_table_iter_next (&iter, &key, &value)) { + int state; + + state = GPOINTER_TO_INT (value); + + /* A single rfkill switch that's not hw blocked? Hw airplane mode is off */ + if (state != RFKILL_STATE_HARD_BLOCKED) { + return FALSE; + } + } + + return TRUE; +} + +static gboolean +engine_get_has_airplane_mode (GsdRfkillManager *manager) +{ + return (g_hash_table_size (manager->priv->killswitches) > 0) || + manager->priv->wwan_interesting; +} + +static gboolean +engine_get_should_show_airplane_mode (GsdRfkillManager *manager) +{ + return (g_strcmp0 (manager->priv->chassis_type, "desktop") != 0) && + (g_strcmp0 (manager->priv->chassis_type, "server") != 0) && + (g_strcmp0 (manager->priv->chassis_type, "vm") != 0) && + (g_strcmp0 (manager->priv->chassis_type, "container") != 0); +} + +static void +engine_properties_changed (GsdRfkillManager *manager) +{ + GVariantBuilder props_builder; + GVariant *props_changed = NULL; + + /* not yet connected to the session bus */ + if (manager->priv->connection == NULL) + return; + + g_variant_builder_init (&props_builder, G_VARIANT_TYPE ("a{sv}")); + + g_variant_builder_add (&props_builder, "{sv}", "AirplaneMode", + g_variant_new_boolean (engine_get_airplane_mode (manager))); + g_variant_builder_add (&props_builder, "{sv}", "HardwareAirplaneMode", + g_variant_new_boolean (engine_get_hardware_airplane_mode (manager))); + g_variant_builder_add (&props_builder, "{sv}", "HasAirplaneMode", + g_variant_new_boolean (engine_get_has_airplane_mode (manager))); + g_variant_builder_add (&props_builder, "{sv}", "ShouldShowAirplaneMode", + g_variant_new_boolean (engine_get_should_show_airplane_mode (manager))); + g_variant_builder_add (&props_builder, "{sv}", "BluetoothAirplaneMode", + g_variant_new_boolean (engine_get_bluetooth_airplane_mode (manager))); + g_variant_builder_add (&props_builder, "{sv}", "BluetoothHardwareAirplaneMode", + g_variant_new_boolean (engine_get_bluetooth_hardware_airplane_mode (manager))); + g_variant_builder_add (&props_builder, "{sv}", "BluetoothHasAirplaneMode", + g_variant_new_boolean (engine_get_has_bluetooth_airplane_mode (manager))); + + props_changed = g_variant_new ("(s@a{sv}@as)", GSD_RFKILL_DBUS_NAME, + g_variant_builder_end (&props_builder), + g_variant_new_strv (NULL, 0)); + + g_dbus_connection_emit_signal (manager->priv->connection, + NULL, + GSD_RFKILL_DBUS_PATH, + "org.freedesktop.DBus.Properties", + "PropertiesChanged", + props_changed, NULL); +} + +static void +rfkill_changed (CcRfkillGlib *rfkill, + GList *events, + GsdRfkillManager *manager) +{ + GList *l; + int value; + + for (l = events; l != NULL; l = l->next) { + struct rfkill_event *event = l->data; + + switch (event->op) { + case RFKILL_OP_ADD: + case RFKILL_OP_CHANGE: + if (event->hard) + value = RFKILL_STATE_HARD_BLOCKED; + else if (event->soft) + value = RFKILL_STATE_SOFT_BLOCKED; + else + value = RFKILL_STATE_UNBLOCKED; + + g_hash_table_insert (manager->priv->killswitches, + GINT_TO_POINTER (event->idx), + GINT_TO_POINTER (value)); + if (event->type == RFKILL_TYPE_BLUETOOTH) + g_hash_table_insert (manager->priv->bt_killswitches, + GINT_TO_POINTER (event->idx), + GINT_TO_POINTER (value)); + g_debug ("%s %srfkill with ID %d", + event->op == RFKILL_OP_ADD ? "Added" : "Changed", + event->type == RFKILL_TYPE_BLUETOOTH ? "Bluetooth " : "", + event->idx); + break; + case RFKILL_OP_DEL: + g_hash_table_remove (manager->priv->killswitches, + GINT_TO_POINTER (event->idx)); + if (event->type == RFKILL_TYPE_BLUETOOTH) + g_hash_table_remove (manager->priv->bt_killswitches, + GINT_TO_POINTER (event->idx)); + g_debug ("Removed %srfkill with ID %d", event->type == RFKILL_TYPE_BLUETOOTH ? "Bluetooth " : "", + event->idx); + break; + } + } + + engine_properties_changed (manager); +} + +static void +rfkill_set_cb (GObject *source_object, + GAsyncResult *res, + gpointer user_data) +{ + gboolean ret; + GError *error = NULL; + + ret = cc_rfkill_glib_send_change_all_event_finish (CC_RFKILL_GLIB (source_object), res, &error); + if (!ret) { + if (g_error_matches (error, G_IO_ERROR, G_IO_ERROR_TIMED_OUT)) + g_debug ("Timed out waiting for blocked rfkills"); + else if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED)) + g_warning ("Failed to set RFKill: %s", error->message); + g_error_free (error); + } +} + +static void +set_wwan_complete (GObject *object, + GAsyncResult *result, + gpointer user_data) +{ + GError *error; + GVariant *variant; + + error = NULL; + variant = g_dbus_proxy_call_finish (G_DBUS_PROXY (object), result, &error); + + if (variant == NULL) { + if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED)) + g_warning ("Failed to set WWAN power status: %s", error->message); + + g_error_free (error); + } else { + g_variant_unref (variant); + } +} + +static gboolean +engine_set_bluetooth_airplane_mode (GsdRfkillManager *manager, + gboolean enable) +{ + cc_rfkill_glib_send_change_all_event (manager->priv->rfkill, RFKILL_TYPE_BLUETOOTH, + enable, manager->priv->cancellable, rfkill_set_cb, manager); + + return TRUE; +} + +static gboolean +engine_set_airplane_mode (GsdRfkillManager *manager, + gboolean enable) +{ + cc_rfkill_glib_send_change_all_event (manager->priv->rfkill, RFKILL_TYPE_ALL, + enable, manager->priv->cancellable, rfkill_set_cb, manager); + + /* Note: we set the the NM property even if there are no modems, so we don't + need to resync when one is plugged in */ + if (manager->priv->nm_client) { + g_dbus_proxy_call (manager->priv->nm_client, + "org.freedesktop.DBus.Properties.Set", + g_variant_new ("(ssv)", + "org.freedesktop.NetworkManager", + "WwanEnabled", + g_variant_new_boolean (!enable)), + G_DBUS_CALL_FLAGS_NONE, + -1, /* timeout */ + manager->priv->cancellable, + set_wwan_complete, NULL); + } + + return TRUE; +} + +static gboolean +handle_set_property (GDBusConnection *connection, + const gchar *sender, + const gchar *object_path, + const gchar *interface_name, + const gchar *property_name, + GVariant *value, + GError **error, + gpointer user_data) +{ + GsdRfkillManager *manager = GSD_RFKILL_MANAGER (user_data); + + if (g_strcmp0 (property_name, "AirplaneMode") == 0) { + gboolean airplane_mode; + g_variant_get (value, "b", &airplane_mode); + return engine_set_airplane_mode (manager, airplane_mode); + } else if (g_strcmp0 (property_name, "BluetoothAirplaneMode") == 0) { + gboolean airplane_mode; + g_variant_get (value, "b", &airplane_mode); + return engine_set_bluetooth_airplane_mode (manager, airplane_mode); + } + + return FALSE; +} + +static GVariant * +handle_get_property (GDBusConnection *connection, + const gchar *sender, + const gchar *object_path, + const gchar *interface_name, + const gchar *property_name, + GError **error, + gpointer user_data) +{ + GsdRfkillManager *manager = GSD_RFKILL_MANAGER (user_data); + + /* Check session pointer as a proxy for whether the manager is in the + start or stop state */ + if (manager->priv->connection == NULL) { + return NULL; + } + + if (g_strcmp0 (property_name, "AirplaneMode") == 0) { + gboolean airplane_mode; + airplane_mode = engine_get_airplane_mode (manager); + return g_variant_new_boolean (airplane_mode); + } + + if (g_strcmp0 (property_name, "HardwareAirplaneMode") == 0) { + gboolean hw_airplane_mode; + hw_airplane_mode = engine_get_hardware_airplane_mode (manager); + return g_variant_new_boolean (hw_airplane_mode); + } + + if (g_strcmp0 (property_name, "ShouldShowAirplaneMode") == 0) { + gboolean should_show_airplane_mode; + should_show_airplane_mode = engine_get_should_show_airplane_mode (manager); + return g_variant_new_boolean (should_show_airplane_mode); + } + + if (g_strcmp0 (property_name, "HasAirplaneMode") == 0) { + gboolean has_airplane_mode; + has_airplane_mode = engine_get_has_airplane_mode (manager); + return g_variant_new_boolean (has_airplane_mode); + } + + if (g_strcmp0 (property_name, "BluetoothAirplaneMode") == 0) { + gboolean airplane_mode; + airplane_mode = engine_get_bluetooth_airplane_mode (manager); + return g_variant_new_boolean (airplane_mode); + } + + if (g_strcmp0 (property_name, "BluetoothHardwareAirplaneMode") == 0) { + gboolean hw_airplane_mode; + hw_airplane_mode = engine_get_bluetooth_hardware_airplane_mode (manager); + return g_variant_new_boolean (hw_airplane_mode); + } + + if (g_strcmp0 (property_name, "BluetoothHasAirplaneMode") == 0) { + gboolean has_airplane_mode; + has_airplane_mode = engine_get_has_bluetooth_airplane_mode (manager); + return g_variant_new_boolean (has_airplane_mode); + } + + return NULL; +} + +static const GDBusInterfaceVTable interface_vtable = +{ + NULL, + handle_get_property, + handle_set_property +}; + +static void +on_bus_gotten (GObject *source_object, + GAsyncResult *res, + GsdRfkillManager *manager) +{ + GDBusConnection *connection; + GError *error = NULL; + + connection = g_bus_get_finish (res, &error); + if (connection == NULL) { + if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED)) + g_warning ("Could not get session bus: %s", error->message); + g_error_free (error); + return; + } + manager->priv->connection = connection; + + g_dbus_connection_register_object (connection, + GSD_RFKILL_DBUS_PATH, + manager->priv->introspection_data->interfaces[0], + &interface_vtable, + manager, + NULL, + NULL); + + manager->priv->name_id = g_bus_own_name_on_connection (connection, + GSD_RFKILL_DBUS_NAME, + G_BUS_NAME_OWNER_FLAGS_NONE, + NULL, + NULL, + NULL, + NULL); +} + +static void +sync_wwan_enabled (GsdRfkillManager *manager) +{ + GVariant *property; + + property = g_dbus_proxy_get_cached_property (manager->priv->nm_client, + "WwanEnabled"); + + if (property == NULL) { + /* GDBus telling us NM went down */ + return; + } + + manager->priv->wwan_enabled = g_variant_get_boolean (property); + engine_properties_changed (manager); + + g_variant_unref (property); +} + +static void +nm_signal (GDBusProxy *proxy, + char *sender_name, + char *signal_name, + GVariant *parameters, + gpointer user_data) +{ + GsdRfkillManager *manager = user_data; + GVariant *changed; + GVariant *property; + + if (g_strcmp0 (signal_name, "PropertiesChanged") == 0) { + changed = g_variant_get_child_value (parameters, 0); + property = g_variant_lookup_value (changed, "WwanEnabled", G_VARIANT_TYPE ("b")); + g_dbus_proxy_set_cached_property (proxy, "WwanEnabled", property); + + if (property != NULL) { + sync_wwan_enabled (manager); + g_variant_unref (property); + } + + g_variant_unref (changed); + } +} + +static void +on_nm_proxy_gotten (GObject *source, + GAsyncResult *result, + gpointer user_data) +{ + GsdRfkillManager *manager = user_data; + GDBusProxy *proxy; + GError *error; + + error = NULL; + proxy = g_dbus_proxy_new_for_bus_finish (result, &error); + + if (proxy == NULL) { + if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED) && + !g_error_matches (error, G_DBUS_ERROR, G_DBUS_ERROR_SERVICE_UNKNOWN)) + g_warning ("Failed to acquire NetworkManager proxy: %s", error->message); + + g_error_free (error); + goto out; + } + + manager->priv->nm_client = proxy; + + g_signal_connect (manager->priv->nm_client, "g-signal", + G_CALLBACK (nm_signal), manager); + sync_wwan_enabled (manager); + + out: + g_object_unref (manager); +} + +static void +sync_wwan_interesting (GDBusObjectManager *object_manager, + GDBusObject *object, + GDBusInterface *interface, + gpointer user_data) +{ + GsdRfkillManager *manager = user_data; + GList *objects; + + objects = g_dbus_object_manager_get_objects (object_manager); + manager->priv->wwan_interesting = (objects != NULL); + engine_properties_changed (manager); + + g_list_free_full (objects, g_object_unref); +} + +static void +on_mm_proxy_gotten (GObject *source, + GAsyncResult *result, + gpointer user_data) +{ + GsdRfkillManager *manager = user_data; + GDBusObjectManager *proxy; + GError *error; + + error = NULL; + proxy = g_dbus_object_manager_client_new_for_bus_finish (result, &error); + + if (proxy == NULL) { + if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED) && + !g_error_matches (error, G_DBUS_ERROR, G_DBUS_ERROR_SERVICE_UNKNOWN)) + g_warning ("Failed to acquire ModemManager proxy: %s", error->message); + + g_error_free (error); + goto out; + } + + manager->priv->mm_client = proxy; + + g_signal_connect (manager->priv->mm_client, "interface-added", + G_CALLBACK (sync_wwan_interesting), manager); + g_signal_connect (manager->priv->mm_client, "interface-removed", + G_CALLBACK (sync_wwan_interesting), manager); + sync_wwan_interesting (manager->priv->mm_client, NULL, NULL, manager); + + out: + g_object_unref (manager); +} + +gboolean +gsd_rfkill_manager_start (GsdRfkillManager *manager, + GError **error) +{ + gnome_settings_profile_start (NULL); + + manager->priv->introspection_data = g_dbus_node_info_new_for_xml (introspection_xml, NULL); + g_assert (manager->priv->introspection_data != NULL); + + manager->priv->killswitches = g_hash_table_new (g_direct_hash, g_direct_equal); + manager->priv->bt_killswitches = g_hash_table_new (g_direct_hash, g_direct_equal); + manager->priv->rfkill = cc_rfkill_glib_new (); + g_signal_connect (G_OBJECT (manager->priv->rfkill), "changed", + G_CALLBACK (rfkill_changed), manager); + cc_rfkill_glib_open (manager->priv->rfkill); + + manager->priv->cancellable = g_cancellable_new (); + + manager->priv->chassis_type = gnome_settings_get_chassis_type (); + + g_dbus_proxy_new_for_bus (G_BUS_TYPE_SYSTEM, + G_DBUS_PROXY_FLAGS_NONE, + NULL, /* g-interface-info */ + "org.freedesktop.NetworkManager", + "/org/freedesktop/NetworkManager", + "org.freedesktop.NetworkManager", + manager->priv->cancellable, + on_nm_proxy_gotten, g_object_ref (manager)); + + g_dbus_object_manager_client_new_for_bus (G_BUS_TYPE_SYSTEM, + G_DBUS_OBJECT_MANAGER_CLIENT_FLAGS_DO_NOT_AUTO_START, + "org.freedesktop.ModemManager1", + "/org/freedesktop/ModemManager1", + NULL, NULL, NULL, /* get_proxy_type and closure */ + manager->priv->cancellable, + on_mm_proxy_gotten, g_object_ref (manager)); + + /* Start process of owning a D-Bus name */ + g_bus_get (G_BUS_TYPE_SESSION, + manager->priv->cancellable, + (GAsyncReadyCallback) on_bus_gotten, + manager); + + gnome_settings_profile_end (NULL); + + return TRUE; +} + +void +gsd_rfkill_manager_stop (GsdRfkillManager *manager) +{ + GsdRfkillManagerPrivate *p = manager->priv; + + g_debug ("Stopping rfkill manager"); + + if (manager->priv->name_id != 0) { + g_bus_unown_name (manager->priv->name_id); + manager->priv->name_id = 0; + } + + g_clear_pointer (&p->introspection_data, g_dbus_node_info_unref); + g_clear_object (&p->connection); + g_clear_object (&p->rfkill); + g_clear_pointer (&p->killswitches, g_hash_table_destroy); + g_clear_pointer (&p->bt_killswitches, g_hash_table_destroy); + + if (p->cancellable) { + g_cancellable_cancel (p->cancellable); + g_clear_object (&p->cancellable); + } + + g_clear_object (&p->nm_client); + g_clear_object (&p->mm_client); + p->wwan_enabled = FALSE; + p->wwan_interesting = FALSE; + + g_clear_pointer (&p->chassis_type, g_free); +} + +static void +gsd_rfkill_manager_finalize (GObject *object) +{ + GsdRfkillManager *manager; + + g_return_if_fail (object != NULL); + g_return_if_fail (GSD_IS_RFKILL_MANAGER (object)); + + manager = GSD_RFKILL_MANAGER (object); + + g_return_if_fail (manager->priv != NULL); + + gsd_rfkill_manager_stop (manager); + + G_OBJECT_CLASS (gsd_rfkill_manager_parent_class)->finalize (object); +} + +GsdRfkillManager * +gsd_rfkill_manager_new (void) +{ + if (manager_object != NULL) { + g_object_ref (manager_object); + } else { + manager_object = g_object_new (GSD_TYPE_RFKILL_MANAGER, NULL); + g_object_add_weak_pointer (manager_object, + (gpointer *) &manager_object); + } + + return GSD_RFKILL_MANAGER (manager_object); +} --- unity-settings-daemon-15.04.1+19.04.20190209.orig/plugins/rfkill/gsd-rfkill-manager.h +++ unity-settings-daemon-15.04.1+19.04.20190209/plugins/rfkill/gsd-rfkill-manager.h @@ -0,0 +1,57 @@ +/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- + * + * Copyright (C) 2007 William Jon McCann + * Copyright (C) 2010 Red Hat, Inc. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, see . + * + */ + +#ifndef __GSD_RFKILL_MANAGER_H +#define __GSD_RFKILL_MANAGER_H + +#include + +G_BEGIN_DECLS + +#define GSD_TYPE_RFKILL_MANAGER (gsd_rfkill_manager_get_type ()) +#define GSD_RFKILL_MANAGER(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), GSD_TYPE_RFKILL_MANAGER, GsdRfkillManager)) +#define GSD_RFKILL_MANAGER_CLASS(k) (G_TYPE_CHECK_CLASS_CAST((k), GSD_TYPE_RFKILL_MANAGER, GsdRfkillManagerClass)) +#define GSD_IS_RFKILL_MANAGER(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), GSD_TYPE_RFKILL_MANAGER)) +#define GSD_IS_RFKILL_MANAGER_CLASS(k) (G_TYPE_CHECK_CLASS_TYPE ((k), GSD_TYPE_RFKILL_MANAGER)) +#define GSD_RFKILL_MANAGER_GET_CLASS(o) (G_TYPE_INSTANCE_GET_CLASS ((o), GSD_TYPE_RFKILL_MANAGER, GsdRfkillManagerClass)) + +typedef struct GsdRfkillManagerPrivate GsdRfkillManagerPrivate; + +typedef struct +{ + GObject parent; + GsdRfkillManagerPrivate *priv; +} GsdRfkillManager; + +typedef struct +{ + GObjectClass parent_class; +} GsdRfkillManagerClass; + +GType gsd_rfkill_manager_get_type (void); + +GsdRfkillManager * gsd_rfkill_manager_new (void); +gboolean gsd_rfkill_manager_start (GsdRfkillManager *manager, + GError **error); +void gsd_rfkill_manager_stop (GsdRfkillManager *manager); + +G_END_DECLS + +#endif /* __GSD_RFKILL_MANAGER_H */ --- unity-settings-daemon-15.04.1+19.04.20190209.orig/plugins/rfkill/gsd-rfkill-plugin.c +++ unity-settings-daemon-15.04.1+19.04.20190209/plugins/rfkill/gsd-rfkill-plugin.c @@ -0,0 +1,29 @@ +/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- + * + * Copyright (C) 2007 William Jon McCann + * Copyright (C) 2010 Red Hat, Inc. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, see . + * + */ + +#include "config.h" + +#include +#include + +#include "gnome-settings-plugin.h" +#include "gsd-rfkill-manager.h" + +GNOME_SETTINGS_PLUGIN_REGISTER (GsdRfkill, gsd_rfkill) --- unity-settings-daemon-15.04.1+19.04.20190209.orig/plugins/rfkill/rfkill-glib.c +++ unity-settings-daemon-15.04.1+19.04.20190209/plugins/rfkill/rfkill-glib.c @@ -0,0 +1,532 @@ +/* + * + * gnome-bluetooth - Bluetooth integration for GNOME + * + * Copyright (C) 2012 Bastien Nocera + * + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + * + */ + +#ifdef HAVE_CONFIG_H +#include +#endif + +#include +#include +#include +#include +#include +#include + +#include +#include +#include + +#include "rfkill-glib.h" + +enum { + CHANGED, + LAST_SIGNAL +}; + +static int signals[LAST_SIGNAL] = { 0 }; + +#define CC_RFKILL_GLIB_GET_PRIVATE(obj) (G_TYPE_INSTANCE_GET_PRIVATE((obj), \ + CC_RFKILL_TYPE_GLIB, CcRfkillGlibPrivate)) + +struct CcRfkillGlibPrivate { + GOutputStream *stream; + GIOChannel *channel; + guint watch_id; + + /* Pending Bluetooth enablement */ + guint change_all_timeout_id; + struct rfkill_event *event; + GSimpleAsyncResult *simple; + GCancellable *cancellable; +}; + +G_DEFINE_TYPE(CcRfkillGlib, cc_rfkill_glib, G_TYPE_OBJECT) + +#define CHANGE_ALL_TIMEOUT 500 + +static const char *type_to_string (unsigned int type); + +gboolean +cc_rfkill_glib_send_event_finish (CcRfkillGlib *rfkill, + GAsyncResult *res, + GError **error) +{ + GSimpleAsyncResult *simple = G_SIMPLE_ASYNC_RESULT (res); + + g_return_val_if_fail (RFKILL_IS_GLIB (rfkill), FALSE); + g_warn_if_fail (g_simple_async_result_get_source_tag (simple) == cc_rfkill_glib_send_event); + + if (g_simple_async_result_propagate_error (simple, error)) + return FALSE; + + return (g_simple_async_result_get_op_res_gssize (simple) >= 0); +} + +static void +write_done_cb (GObject *source_object, + GAsyncResult *res, + gpointer user_data) +{ + GSimpleAsyncResult *simple = G_SIMPLE_ASYNC_RESULT (user_data); + GError *error = NULL; + gssize ret; + + ret = g_output_stream_write_finish (G_OUTPUT_STREAM (source_object), res, &error); + if (ret < 0) + g_simple_async_result_take_error (simple, error); + else + g_simple_async_result_set_op_res_gssize (simple, ret); + + g_simple_async_result_complete_in_idle (simple); + g_object_unref (simple); +} + +void +cc_rfkill_glib_send_event (CcRfkillGlib *rfkill, + struct rfkill_event *event, + GCancellable *cancellable, + GAsyncReadyCallback callback, + gpointer user_data) +{ + GSimpleAsyncResult *simple; + + g_return_if_fail (RFKILL_IS_GLIB (rfkill)); + g_return_if_fail (rfkill->priv->stream); + + simple = g_simple_async_result_new (G_OBJECT (rfkill), + callback, + user_data, + cc_rfkill_glib_send_event); + + g_output_stream_write_async (rfkill->priv->stream, + event, sizeof(struct rfkill_event), + G_PRIORITY_DEFAULT, + cancellable, write_done_cb, simple); +} + +gboolean +cc_rfkill_glib_send_change_all_event_finish (CcRfkillGlib *rfkill, + GAsyncResult *res, + GError **error) +{ + GSimpleAsyncResult *simple = G_SIMPLE_ASYNC_RESULT (res); + + g_return_val_if_fail (RFKILL_IS_GLIB (rfkill), FALSE); + g_warn_if_fail (g_simple_async_result_get_source_tag (simple) == cc_rfkill_glib_send_change_all_event); + + if (g_simple_async_result_propagate_error (simple, error)) + return FALSE; + + return g_simple_async_result_get_op_res_gboolean (simple); +} + +static void +write_change_all_again_done_cb (GObject *source_object, + GAsyncResult *res, + gpointer user_data) +{ + CcRfkillGlib *rfkill = user_data; + GError *error = NULL; + gssize ret; + + g_debug ("Finished writing second RFKILL_OP_CHANGE_ALL event"); + + ret = g_output_stream_write_finish (G_OUTPUT_STREAM (source_object), res, &error); + if (ret < 0) + g_simple_async_result_take_error (rfkill->priv->simple, error); + else + g_simple_async_result_set_op_res_gboolean (rfkill->priv->simple, ret >= 0); + + g_simple_async_result_complete_in_idle (rfkill->priv->simple); + g_clear_object (&rfkill->priv->simple); + g_clear_pointer (&rfkill->priv->event, g_free); +} + +static gboolean +write_change_all_timeout_cb (CcRfkillGlib *rfkill) +{ + g_assert (rfkill->priv->event); + + g_debug ("Sending second RFKILL_OP_CHANGE_ALL timed out"); + + g_simple_async_result_set_error (rfkill->priv->simple, + G_IO_ERROR, G_IO_ERROR_TIMED_OUT, + "Enabling rfkill for %s timed out", + type_to_string (rfkill->priv->event->type)); + g_simple_async_result_complete_in_idle (rfkill->priv->simple); + + g_clear_object (&rfkill->priv->simple); + g_clear_pointer (&rfkill->priv->event, g_free); + g_clear_object (&rfkill->priv->cancellable); + rfkill->priv->change_all_timeout_id = 0; + + return G_SOURCE_REMOVE; +} + +static void +write_change_all_done_cb (GObject *source_object, + GAsyncResult *res, + gpointer user_data) +{ + CcRfkillGlib *rfkill = user_data; + GError *error = NULL; + gssize ret; + + g_debug ("Sending original RFKILL_OP_CHANGE_ALL event done"); + + ret = g_output_stream_write_finish (G_OUTPUT_STREAM (source_object), res, &error); + if (ret < 0) { + g_simple_async_result_take_error (rfkill->priv->simple, error); + goto bail; + } else if (rfkill->priv->event->soft == 1 || + rfkill->priv->event->type != RFKILL_TYPE_BLUETOOTH) { + g_simple_async_result_set_op_res_gboolean (rfkill->priv->simple, ret >= 0); + goto bail; + } + + rfkill->priv->change_all_timeout_id = g_timeout_add (CHANGE_ALL_TIMEOUT, + (GSourceFunc) write_change_all_timeout_cb, + rfkill); + + return; + +bail: + g_simple_async_result_complete_in_idle (rfkill->priv->simple); + g_clear_object (&rfkill->priv->simple); + g_clear_pointer (&rfkill->priv->event, g_free); + g_clear_object (&rfkill->priv->cancellable); +} + +void +cc_rfkill_glib_send_change_all_event (CcRfkillGlib *rfkill, + guint rfkill_type, + gboolean enable, + GCancellable *cancellable, + GAsyncReadyCallback callback, + gpointer user_data) +{ + GSimpleAsyncResult *simple; + struct rfkill_event *event; + + g_return_if_fail (RFKILL_IS_GLIB (rfkill)); + g_return_if_fail (rfkill->priv->stream); + + simple = g_simple_async_result_new (G_OBJECT (rfkill), + callback, + user_data, + cc_rfkill_glib_send_change_all_event); + + if (rfkill->priv->change_all_timeout_id > 0) { + g_source_remove (rfkill->priv->change_all_timeout_id); + rfkill->priv->change_all_timeout_id = 0; + write_change_all_timeout_cb (rfkill); + } + + event = g_new0 (struct rfkill_event, 1); + event->op = RFKILL_OP_CHANGE_ALL; + event->type = rfkill_type; + event->soft = enable ? 1 : 0; + + rfkill->priv->event = event; + rfkill->priv->simple = simple; + rfkill->priv->cancellable = cancellable ? g_object_ref (cancellable) : NULL; + rfkill->priv->change_all_timeout_id = 0; + + g_output_stream_write_async (rfkill->priv->stream, + event, sizeof(struct rfkill_event), + G_PRIORITY_DEFAULT, + cancellable, write_change_all_done_cb, rfkill); +} + +static const char * +type_to_string (unsigned int type) +{ + switch (type) { + case RFKILL_TYPE_ALL: + return "ALL"; + case RFKILL_TYPE_WLAN: + return "WLAN"; + case RFKILL_TYPE_BLUETOOTH: + return "BLUETOOTH"; + case RFKILL_TYPE_UWB: + return "UWB"; + case RFKILL_TYPE_WIMAX: + return "WIMAX"; + case RFKILL_TYPE_WWAN: + return "WWAN"; + default: + return "UNKNOWN"; + } +} + +static const char * +op_to_string (unsigned int op) +{ + switch (op) { + case RFKILL_OP_ADD: + return "ADD"; + case RFKILL_OP_DEL: + return "DEL"; + case RFKILL_OP_CHANGE: + return "CHANGE"; + case RFKILL_OP_CHANGE_ALL: + return "CHANGE_ALL"; + default: + g_assert_not_reached (); + } +} + +static void +print_event (struct rfkill_event *event) +{ + g_debug ("RFKILL event: idx %u type %u (%s) op %u (%s) soft %u hard %u", + event->idx, + event->type, type_to_string (event->type), + event->op, op_to_string (event->op), + event->soft, event->hard); +} + +static gboolean +got_change_event (GList *events) +{ + GList *l; + + g_assert (events != NULL); + + for (l = events ; l != NULL; l = l->next) { + struct rfkill_event *event = l->data; + + if (event->op == RFKILL_OP_CHANGE) + return TRUE; + } + + return FALSE; +} + +static void +emit_changed_signal_and_free (CcRfkillGlib *rfkill, + GList *events) +{ + if (events == NULL) + return; + + g_signal_emit (G_OBJECT (rfkill), + signals[CHANGED], + 0, events); + + if (rfkill->priv->change_all_timeout_id > 0 && + got_change_event (events)) { + g_debug ("Received a change event after a RFKILL_OP_CHANGE_ALL event, re-sending RFKILL_OP_CHANGE_ALL"); + + g_output_stream_write_async (rfkill->priv->stream, + rfkill->priv->event, sizeof(struct rfkill_event), + G_PRIORITY_DEFAULT, + rfkill->priv->cancellable, write_change_all_again_done_cb, rfkill); + + g_source_remove (rfkill->priv->change_all_timeout_id); + rfkill->priv->change_all_timeout_id = 0; + } + + g_list_free_full (events, g_free); +} + +static gboolean +event_cb (GIOChannel *source, + GIOCondition condition, + CcRfkillGlib *rfkill) +{ + GList *events; + + events = NULL; + + if (condition & G_IO_IN) { + GIOStatus status; + struct rfkill_event event; + gsize read; + + status = g_io_channel_read_chars (source, + (char *) &event, + sizeof(event), + &read, + NULL); + + while (status == G_IO_STATUS_NORMAL && read == sizeof(event)) { + struct rfkill_event *event_ptr; + + print_event (&event); + + event_ptr = g_memdup (&event, sizeof(event)); + events = g_list_prepend (events, event_ptr); + + status = g_io_channel_read_chars (source, + (char *) &event, + sizeof(event), + &read, + NULL); + } + events = g_list_reverse (events); + } else { + g_debug ("Something unexpected happened on rfkill fd"); + return FALSE; + } + + emit_changed_signal_and_free (rfkill, events); + + return TRUE; +} + +static void +cc_rfkill_glib_init (CcRfkillGlib *rfkill) +{ + CcRfkillGlibPrivate *priv; + + priv = CC_RFKILL_GLIB_GET_PRIVATE (rfkill); + rfkill->priv = priv; +} + +int +cc_rfkill_glib_open (CcRfkillGlib *rfkill) +{ + CcRfkillGlibPrivate *priv; + int fd; + int ret; + GList *events; + + g_return_val_if_fail (RFKILL_IS_GLIB (rfkill), -1); + g_return_val_if_fail (rfkill->priv->stream == NULL, -1); + + priv = rfkill->priv; + + fd = open("/dev/rfkill", O_RDWR); + if (fd < 0) { + if (errno == EACCES) + g_warning ("Could not open RFKILL control device, please verify your installation"); + return fd; + } + + ret = fcntl(fd, F_SETFL, O_NONBLOCK); + if (ret < 0) { + g_debug ("Can't set RFKILL control device to non-blocking"); + close(fd); + return ret; + } + + events = NULL; + + while (1) { + struct rfkill_event event; + struct rfkill_event *event_ptr; + ssize_t len; + + len = read(fd, &event, sizeof(event)); + if (len < 0) { + if (errno == EAGAIN) + break; + g_debug ("Reading of RFKILL events failed"); + break; + } + + if (len != RFKILL_EVENT_SIZE_V1) { + g_warning ("Wrong size of RFKILL event\n"); + continue; + } + + if (event.op != RFKILL_OP_ADD) + continue; + + g_debug ("Read killswitch of type '%s' (idx=%d): soft %d hard %d", + type_to_string (event.type), + event.idx, event.soft, event.hard); + + event_ptr = g_memdup (&event, sizeof(event)); + events = g_list_prepend (events, event_ptr); + } + + /* Setup monitoring */ + priv->channel = g_io_channel_unix_new (fd); + priv->watch_id = g_io_add_watch (priv->channel, + G_IO_IN | G_IO_HUP | G_IO_ERR, + (GIOFunc) event_cb, + rfkill); + + if (events) { + events = g_list_reverse (events); + emit_changed_signal_and_free (rfkill, events); + } else { + g_debug ("No rfkill device available on startup"); + } + + /* Setup write stream */ + priv->stream = g_unix_output_stream_new (fd, TRUE); + + return fd; +} + +static void +cc_rfkill_glib_finalize (GObject *object) +{ + CcRfkillGlib *rfkill; + CcRfkillGlibPrivate *priv; + + rfkill = CC_RFKILL_GLIB (object); + priv = rfkill->priv; + + if (priv->change_all_timeout_id > 0) + write_change_all_timeout_cb (rfkill); + + /* cleanup monitoring */ + if (priv->watch_id > 0) { + g_source_remove (priv->watch_id); + priv->watch_id = 0; + g_io_channel_shutdown (priv->channel, FALSE, NULL); + g_io_channel_unref (priv->channel); + } + g_clear_object (&priv->stream); + + G_OBJECT_CLASS(cc_rfkill_glib_parent_class)->finalize(object); +} + +static void +cc_rfkill_glib_class_init(CcRfkillGlibClass *klass) +{ + GObjectClass *object_class = (GObjectClass *) klass; + + g_type_class_add_private(klass, sizeof(CcRfkillGlibPrivate)); + object_class->finalize = cc_rfkill_glib_finalize; + + signals[CHANGED] = + g_signal_new ("changed", + G_TYPE_FROM_CLASS (klass), + G_SIGNAL_RUN_LAST, + G_STRUCT_OFFSET (CcRfkillGlibClass, changed), + NULL, NULL, + NULL, + G_TYPE_NONE, 1, G_TYPE_POINTER); + +} + +CcRfkillGlib * +cc_rfkill_glib_new (void) +{ + return CC_RFKILL_GLIB (g_object_new (CC_RFKILL_TYPE_GLIB, NULL)); +} --- unity-settings-daemon-15.04.1+19.04.20190209.orig/plugins/rfkill/rfkill-glib.h +++ unity-settings-daemon-15.04.1+19.04.20190209/plugins/rfkill/rfkill-glib.h @@ -0,0 +1,85 @@ +/* + * + * gnome-bluetooth - Bluetooth integration for GNOME + * + * Copyright (C) 2012 Bastien Nocera + * + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + * + */ + +#ifndef __CC_RFKILL_GLIB_H +#define __CC_RFKILL_GLIB_H + +#include +#include +#include "rfkill.h" + +G_BEGIN_DECLS + +#define CC_RFKILL_TYPE_GLIB (cc_rfkill_glib_get_type()) +#define CC_RFKILL_GLIB(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), \ + CC_RFKILL_TYPE_GLIB, CcRfkillGlib)) +#define CC_RFKILL_GLIB_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), \ + CC_RFKILL_TYPE_GLIB, CcRfkillGlibClass)) +#define RFKILL_IS_GLIB(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj), \ + CC_RFKILL_TYPE_GLIB)) +#define RFKILL_IS_GLIB_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), \ + CC_RFKILL_TYPE_GLIB)) +#define RFKILL_GET_GLIB_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS((obj), \ + CC_RFKILL_TYPE_GLIB, CcRfkillGlibClass)) + +typedef struct CcRfkillGlibPrivate CcRfkillGlibPrivate; + +typedef struct _CcRfkillGlib { + GObject parent; + CcRfkillGlibPrivate *priv; +} CcRfkillGlib; + +typedef struct _CcRfkillGlibClass { + GObjectClass parent_class; + + void (*changed) (CcRfkillGlib *rfkill, GList *events); +} CcRfkillGlibClass; + +GType cc_rfkill_glib_get_type (void); +CcRfkillGlib *cc_rfkill_glib_new (void); +int cc_rfkill_glib_open (CcRfkillGlib *rfkill); + +void cc_rfkill_glib_send_event (CcRfkillGlib *rfkill, + struct rfkill_event *event, + GCancellable *cancellable, + GAsyncReadyCallback callback, + gpointer user_data); + +gboolean cc_rfkill_glib_send_event_finish (CcRfkillGlib *rfkill, + GAsyncResult *res, + GError **error); + +void cc_rfkill_glib_send_change_all_event (CcRfkillGlib *rfkill, + guint rfkill_type, + gboolean enable, + GCancellable *cancellable, + GAsyncReadyCallback callback, + gpointer user_data); + +gboolean cc_rfkill_glib_send_change_all_event_finish (CcRfkillGlib *rfkill, + GAsyncResult *res, + GError **error); + +G_END_DECLS + +#endif /* __CC_RFKILL_GLIB_H */ --- unity-settings-daemon-15.04.1+19.04.20190209.orig/plugins/rfkill/rfkill.gnome-settings-plugin.in +++ unity-settings-daemon-15.04.1+19.04.20190209/plugins/rfkill/rfkill.gnome-settings-plugin.in @@ -0,0 +1,10 @@ +[GNOME Settings Plugin] +Module=rfkill +IAge=0 +# Default Priority +# Priority=100 +_Name=Rfkill +_Description=Rfkill plugin +Authors=Bastien Nocera +Copyright=Copyright © 2013 +Website= --- unity-settings-daemon-15.04.1+19.04.20190209.orig/plugins/rfkill/rfkill.h +++ unity-settings-daemon-15.04.1+19.04.20190209/plugins/rfkill/rfkill.h @@ -0,0 +1,107 @@ +#ifndef __RFKILL_H +#define __RFKILL_H + +/* + * Copyright (C) 2006 - 2007 Ivo van Doorn + * Copyright (C) 2007 Dmitry Torokhov + * Copyright 2009 Johannes Berg + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES + * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR + * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES + * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN + * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF + * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + */ + +#include + +/* define userspace visible states */ +#define RFKILL_STATE_SOFT_BLOCKED 0 +#define RFKILL_STATE_UNBLOCKED 1 +#define RFKILL_STATE_HARD_BLOCKED 2 + +/** + * enum rfkill_type - type of rfkill switch. + * + * @RFKILL_TYPE_ALL: toggles all switches (requests only - not a switch type) + * @RFKILL_TYPE_WLAN: switch is on a 802.11 wireless network device. + * @RFKILL_TYPE_BLUETOOTH: switch is on a bluetooth device. + * @RFKILL_TYPE_UWB: switch is on a ultra wideband device. + * @RFKILL_TYPE_WIMAX: switch is on a WiMAX device. + * @RFKILL_TYPE_WWAN: switch is on a wireless WAN device. + * @RFKILL_TYPE_GPS: switch is on a GPS device. + * @RFKILL_TYPE_FM: switch is on a FM radio device. + * @NUM_RFKILL_TYPES: number of defined rfkill types + */ +enum rfkill_type { + RFKILL_TYPE_ALL = 0, + RFKILL_TYPE_WLAN, + RFKILL_TYPE_BLUETOOTH, + RFKILL_TYPE_UWB, + RFKILL_TYPE_WIMAX, + RFKILL_TYPE_WWAN, + RFKILL_TYPE_GPS, + RFKILL_TYPE_FM, + NUM_RFKILL_TYPES, +}; + +/** + * enum rfkill_operation - operation types + * @RFKILL_OP_ADD: a device was added + * @RFKILL_OP_DEL: a device was removed + * @RFKILL_OP_CHANGE: a device's state changed -- userspace changes one device + * @RFKILL_OP_CHANGE_ALL: userspace changes all devices (of a type, or all) + */ +enum rfkill_operation { + RFKILL_OP_ADD = 0, + RFKILL_OP_DEL, + RFKILL_OP_CHANGE, + RFKILL_OP_CHANGE_ALL, +}; + +/** + * struct rfkill_event - events for userspace on /dev/rfkill + * @idx: index of dev rfkill + * @type: type of the rfkill struct + * @op: operation code + * @hard: hard state (0/1) + * @soft: soft state (0/1) + * + * Structure used for userspace communication on /dev/rfkill, + * used for events from the kernel and control to the kernel. + */ +struct rfkill_event { + __u32 idx; + __u8 type; + __u8 op; + __u8 soft, hard; +} __attribute__((packed)); + +/* + * We are planning to be backward and forward compatible with changes + * to the event struct, by adding new, optional, members at the end. + * When reading an event (whether the kernel from userspace or vice + * versa) we need to accept anything that's at least as large as the + * version 1 event size, but might be able to accept other sizes in + * the future. + * + * One exception is the kernel -- we already have two event sizes in + * that we've made the 'hard' member optional since our only option + * is to ignore it anyway. + */ +#define RFKILL_EVENT_SIZE_V1 8 + +/* ioctl for turning off rfkill-input (if present) */ +#define RFKILL_IOC_MAGIC 'R' +#define RFKILL_IOC_NOINPUT 1 +#define RFKILL_IOCTL_NOINPUT _IO(RFKILL_IOC_MAGIC, RFKILL_IOC_NOINPUT) + +/* and that's all userspace gets */ + +#endif /* RFKILL_H */ --- unity-settings-daemon-15.04.1+19.04.20190209.orig/plugins/rfkill/test-rfkill.c +++ unity-settings-daemon-15.04.1+19.04.20190209/plugins/rfkill/test-rfkill.c @@ -0,0 +1,7 @@ +#define NEW gsd_rfkill_manager_new +#define START gsd_rfkill_manager_start +#define STOP gsd_rfkill_manager_stop +#define MANAGER GsdRfkillManager +#include "gsd-rfkill-manager.h" + +#include "test-plugin.h" --- unity-settings-daemon-15.04.1+19.04.20190209.orig/po/POTFILES.in +++ unity-settings-daemon-15.04.1+19.04.20190209/po/POTFILES.in @@ -34,6 +34,7 @@ plugins/power/com.ubuntu.unity-settings-daemon.plugins.power.policy.in.in [type: gettext/ini]plugins/power/power.gnome-settings-plugin.in [type: gettext/ini]plugins/remote-display/remote-display.gnome-settings-plugin.in +[type: gettext/ini]plugins/rfkill/rfkill.gnome-settings-plugin.in [type: gettext/ini]plugins/screensaver-proxy/screensaver-proxy.gnome-settings-plugin.in plugins/smartcard/gsd-smartcard.c plugins/smartcard/gsd-smartcard-manager.c