summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'plugins')
-rw-r--r--plugins/housekeeping/msd-disk-space.c8
-rw-r--r--plugins/media-keys/msd-media-keys-manager.c17
-rw-r--r--plugins/xrandr/msd-xrandr-manager.c11
3 files changed, 29 insertions, 7 deletions
diff --git a/plugins/housekeeping/msd-disk-space.c b/plugins/housekeeping/msd-disk-space.c
index 6842ae5..e36be16 100644
--- a/plugins/housekeeping/msd-disk-space.c
+++ b/plugins/housekeeping/msd-disk-space.c
@@ -181,7 +181,7 @@ ldsm_notify_for_mount (LdsmMountInfo *mount,
gboolean has_trash;
gboolean has_disk_analyzer;
gboolean retval = TRUE;
- const gchar *path;
+ gchar *path;
/* Don't show a dialog if one is already displayed */
if (dialog)
@@ -190,7 +190,7 @@ ldsm_notify_for_mount (LdsmMountInfo *mount,
name = g_unix_mount_guess_name (mount->mount);
free_space = (gint64) mount->buf.f_frsize * (gint64) mount->buf.f_bavail;
has_trash = ldsm_mount_has_trash (mount);
- path = g_unix_mount_get_mount_path (mount->mount);
+ path = g_strdup (g_unix_mount_get_mount_path (mount->mount));
program = g_find_program_in_path (DISK_SPACE_ANALYZER);
has_disk_analyzer = (program != NULL);
@@ -218,7 +218,7 @@ ldsm_notify_for_mount (LdsmMountInfo *mount,
break;
case MSD_LDSM_DIALOG_RESPONSE_ANALYZE:
retval = FALSE;
- ldsm_analyze_path (g_unix_mount_get_mount_path (mount->mount));
+ ldsm_analyze_path (path);
break;
case MSD_LDSM_DIALOG_RESPONSE_EMPTY_TRASH:
retval = TRUE;
@@ -232,6 +232,8 @@ ldsm_notify_for_mount (LdsmMountInfo *mount,
g_assert_not_reached ();
}
+ g_free (path);
+
return retval;
}
diff --git a/plugins/media-keys/msd-media-keys-manager.c b/plugins/media-keys/msd-media-keys-manager.c
index d7e1b04..e7310c6 100644
--- a/plugins/media-keys/msd-media-keys-manager.c
+++ b/plugins/media-keys/msd-media-keys-manager.c
@@ -862,6 +862,19 @@ on_control_default_sink_changed (GvcMixerControl *control,
update_default_sink (manager);
}
+static void
+on_control_stream_removed (GvcMixerControl *control,
+ guint id,
+ GsdMediaKeysManager *manager)
+{
+ if (manager->priv->stream != NULL) {
+ if (gvc_mixer_stream_get_id (manager->priv->stream) == id) {
+ g_object_unref (manager->priv->stream);
+ manager->priv->stream = NULL;
+ }
+ }
+}
+
#endif /* HAVE_PULSE */
static gint
@@ -1186,6 +1199,10 @@ msd_media_keys_manager_start (MsdMediaKeysManager *manager,
"default-sink-changed",
G_CALLBACK (on_control_default_sink_changed),
manager);
+ g_signal_connect (manager->priv->volume,
+ "stream-removed",
+ G_CALLBACK (on_control_stream_removed),
+ manager);
gvc_mixer_control_open (manager->priv->volume);
diff --git a/plugins/xrandr/msd-xrandr-manager.c b/plugins/xrandr/msd-xrandr-manager.c
index dc00be1..7d8d7f5 100644
--- a/plugins/xrandr/msd-xrandr-manager.c
+++ b/plugins/xrandr/msd-xrandr-manager.c
@@ -61,6 +61,7 @@
#define CONF_DIR "/apps/mate_settings_daemon/xrandr"
#define CONF_KEY_SHOW_NOTIFICATION_ICON (CONF_DIR "/show_notification_icon")
+#define CONF_KEY_USE_XORG_MONITOR_SETTINGS (CONF_DIR "/use_xorg_monitor_settings")
#define CONF_KEY_TURN_ON_EXTERNAL_MONITORS_AT_STARTUP (CONF_DIR "/turn_on_external_monitors_at_startup")
#define CONF_KEY_TURN_ON_LAPTOP_MONITOR_AT_STARTUP (CONF_DIR "/turn_on_laptop_monitor_at_startup")
#define CONF_KEY_DEFAULT_CONFIGURATION_FILE (CONF_DIR "/default_configuration_file")
@@ -77,7 +78,7 @@
#define MSD_XRANDR_ICON_NAME "msd-xrandr"
/* executable of the control center's display configuration capplet */
-#define MSD_XRANDR_DISPLAY_CAPPLET "mate-control-center display"
+#define MSD_XRANDR_DISPLAY_CAPPLET "mate-display-properties"
#define MSD_DBUS_PATH "/org/mate/SettingsDaemon"
#define MSD_DBUS_NAME "org.mate.SettingsDaemon"
@@ -2168,10 +2169,11 @@ apply_intended_configuration (MsdXrandrManager *manager, const char *intended_fi
gboolean result;
my_error = NULL;
- result = apply_configuration_from_filename (manager, intended_filename, FALSE, timestamp, &my_error);
+ result = apply_configuration_from_filename (manager, intended_filename, TRUE, timestamp, &my_error);
if (!result) {
if (my_error) {
- if (!g_error_matches (my_error, G_FILE_ERROR, G_FILE_ERROR_NOENT))
+ if (!g_error_matches (my_error, G_FILE_ERROR, G_FILE_ERROR_NOENT) &&
+ !g_error_matches (my_error, MATE_RR_ERROR, MATE_RR_ERROR_NO_MATCHING_CONFIG))
error_message (manager, _("Could not apply the stored configuration for monitors"), my_error, NULL);
g_error_free (my_error);
@@ -2349,7 +2351,8 @@ msd_xrandr_manager_start (MsdXrandrManager *manager,
show_timestamps_dialog (manager, "Startup");
if (!apply_stored_configuration_at_startup (manager, GDK_CURRENT_TIME)) /* we don't have a real timestamp at startup anyway */
if (!apply_default_configuration_from_file (manager, GDK_CURRENT_TIME))
- apply_default_boot_configuration (manager, GDK_CURRENT_TIME);
+ if (!mateconf_client_get_bool (manager->priv->client, CONF_KEY_USE_XORG_MONITOR_SETTINGS, NULL))
+ apply_default_boot_configuration (manager, GDK_CURRENT_TIME);
log_msg ("State of screen after initial configuration:\n");
log_screen (manager->priv->rw_screen);