[gnome-utils] screenshot: cleanup initial delay handling
- From: Cosimo Cecchi <cosimoc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-utils] screenshot: cleanup initial delay handling
- Date: Mon, 26 Sep 2011 20:56:39 +0000 (UTC)
commit e6826cb6c78734f49333a55e8ef87254dbc46420
Author: Cosimo Cecchi <cosimoc gnome org>
Date: Mon Sep 26 13:51:50 2011 -0400
screenshot: cleanup initial delay handling
gnome-screenshot/gnome-screenshot.c | 5 ++---
gnome-screenshot/screenshot-config.c | 7 +++++++
2 files changed, 9 insertions(+), 3 deletions(-)
---
diff --git a/gnome-screenshot/gnome-screenshot.c b/gnome-screenshot/gnome-screenshot.c
index d300a69..5c92ce4 100644
--- a/gnome-screenshot/gnome-screenshot.c
+++ b/gnome-screenshot/gnome-screenshot.c
@@ -685,9 +685,8 @@ main (int argc, char *argv[])
}
}
- if (((screenshot_config->delay > 0 && interactive_arg) || delay_arg > 0) &&
- !screenshot_config->take_area_shot)
- {
+ if (screenshot_config->delay > 0)
+ {
g_timeout_add (screenshot_config->delay * 1000,
prepare_screenshot_timeout,
NULL);
diff --git a/gnome-screenshot/screenshot-config.c b/gnome-screenshot/screenshot-config.c
index be181d5..6441919 100644
--- a/gnome-screenshot/screenshot-config.c
+++ b/gnome-screenshot/screenshot-config.c
@@ -79,6 +79,13 @@ screenshot_load_config (gboolean clipboard_arg,
return FALSE;
}
+ if (delay_arg && area_arg)
+ {
+ g_printerr (_("Conflicting options: --area and --delay should not be "
+ "used at the same time.\n"));
+ return FALSE;
+ }
+
config = g_slice_new0 (ScreenshotConfig);
initialized = TRUE;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]