summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFederico Mena Quintero <federico@novell.com>2008-12-04 00:30:14 +0000
committerFederico Mena Quintero <federico@src.gnome.org>2008-12-04 00:30:14 +0000
commit6de65fe9e455510de9977a8da6bde798c7eb1c86 (patch)
treed3586a567b512462ed17dde5beaff150e92167ef
parent3016bf52fc2ed218ca005f9866d20a05a0de42a7 (diff)
downloadgnome-desktop-6de65fe9e455510de9977a8da6bde798c7eb1c86.tar.gz
Fix prototypes; report errors from gnome_rr_config_applicable()
Signed-off-by: Federico Mena Quintero <federico@novell.com> svn path=/trunk/; revision=5317
-rw-r--r--libgnome-desktop/gnome-rr-config.c13
-rw-r--r--libgnome-desktop/libgnomeui/gnome-rr-config.h6
2 files changed, 14 insertions, 5 deletions
diff --git a/libgnome-desktop/gnome-rr-config.c b/libgnome-desktop/gnome-rr-config.c
index 2566ea67..adc329cd 100644
--- a/libgnome-desktop/gnome-rr-config.c
+++ b/libgnome-desktop/gnome-rr-config.c
@@ -885,12 +885,19 @@ make_outputs (GnomeRRConfig *config)
gboolean
gnome_rr_config_applicable (GnomeRRConfig *configuration,
- GnomeRRScreen *screen)
+ GnomeRRScreen *screen,
+ GError **error)
{
- GnomeOutputInfo **outputs = make_outputs (configuration);
- CrtcAssignment *assign = crtc_assignment_new (screen, outputs);
+ GnomeOutputInfo **outputs;
+ CrtcAssignment *assign;
gboolean result;
+ g_return_val_if_fail (configuration != NULL, FALSE);
+ g_return_val_if_fail (error == NULL || *error == NULL, FALSE);
+
+ outputs = make_outputs (configuration);
+ assign = crtc_assignment_new (screen, outputs, error);
+
if (assign)
{
result = TRUE;
diff --git a/libgnome-desktop/libgnomeui/gnome-rr-config.h b/libgnome-desktop/libgnomeui/gnome-rr-config.h
index 1032d868..e8c602d3 100644
--- a/libgnome-desktop/libgnomeui/gnome-rr-config.h
+++ b/libgnome-desktop/libgnomeui/gnome-rr-config.h
@@ -84,11 +84,13 @@ gboolean gnome_rr_config_save (GnomeRRConfig *configuration,
GError **err);
void gnome_rr_config_sanitize (GnomeRRConfig *configuration);
gboolean gnome_rr_config_apply (GnomeRRConfig *configuration,
- GnomeRRScreen *screen);
+ GnomeRRScreen *screen,
+ GError **error);
gboolean gnome_rr_config_apply_stored (GnomeRRScreen *screen,
GError **error);
gboolean gnome_rr_config_applicable (GnomeRRConfig *configuration,
- GnomeRRScreen *screen);
+ GnomeRRScreen *screen,
+ GError **error);
/* A utility function that isn't really in the spirit of this file, but I don't
* don't know a better place for it.