summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorsabetts <sabetts>2002-03-13 08:25:20 +0000
committersabetts <sabetts>2002-03-13 08:25:20 +0000
commitec4753341dc1712c02989f477902a763af7daec0 (patch)
tree74d594e6b823ad46c7fbbd4ba58a6bf18e0b3617
parentcdb7cc536917ee9d34d4d9f5ed05a3b751044027 (diff)
downloadratpoison-ec4753341dc1712c02989f477902a763af7daec0.zip
* src/actions.c (cmd_nextscreen): An error message is displayed
when there is only 1 screen. (cmd_prevscreen): likewise
-rw-r--r--ChangeLog4
-rw-r--r--src/actions.c13
2 files changed, 14 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 270de17..f9273ae 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
2002-03-13 Shawn Betts <sabetts@vcn.bc.ca>
+ * src/actions.c (cmd_nextscreen): An error message is displayed
+ when there is only 1 screen.
+ (cmd_prevscreen): likewise
+
* src/split.c (set_active_frame): fix to operate properly with
multiple screens.
diff --git a/src/actions.c b/src/actions.c
index a5b2f65..ec44cda 100644
--- a/src/actions.c
+++ b/src/actions.c
@@ -2439,8 +2439,11 @@ cmd_nextscreen (int interactive, void *data)
int new_screen;
/* No need to go through the motions when we don't have to. */
- if (num_screens <= 1) return NULL;
-
+ if (num_screens <= 1)
+ {
+ message (" nextscreen: No other screen ");
+ return NULL;
+ }
new_screen = rp_current_screen + 1;
if (new_screen >= num_screens)
new_screen = 0;
@@ -2456,7 +2459,11 @@ cmd_prevscreen (int interactive, void *data)
int new_screen;
/* No need to go through the motions when we don't have to. */
- if (num_screens <= 1) return NULL;
+ if (num_screens <= 1)
+ {
+ message (" prevscreen: No other screen ");
+ return NULL;
+ }
new_screen = rp_current_screen - 1;
if (new_screen < 0)