diff -aru metacity-2.23.13/src/core/prefs.c metacity-2.23.13.new/src/core/prefs.c
--- metacity-2.23.13/src/core/prefs.c	2008-04-27 20:24:53.000000000 +0200
+++ metacity-2.23.13.new/src/core/prefs.c	2008-05-04 16:20:54.000000000 +0200
@@ -93,6 +93,7 @@
 static char *cursor_theme = NULL;
 static int   cursor_size = 24;
 static gboolean compositing_manager = FALSE;
+static gboolean workspaces_loop_mode = FALSE;
 
 static MetaVisualBellType visual_bell_type = META_VISUAL_BELL_FULLSCREEN_FLASH;
 static MetaButtonLayout button_layout;
@@ -379,6 +380,11 @@
       META_PREF_COMPOSITING_MANAGER,
       FALSE,
     },
+    { "/apps/metacity/general/workspaces_loop_mode",
+      &workspaces_loop_mode,
+      META_PREF_WORKSPACES_LOOP_MODE,
+      FALSE,
+    },
     { NULL, NULL, 0, FALSE },
   };
 
@@ -1607,6 +1613,12 @@
 }
 
 gboolean
+meta_prefs_get_workspaces_loop_mode (void)
+{
+  return workspaces_loop_mode;
+}
+
+gboolean
 meta_prefs_get_application_based (void)
 {
   return FALSE; /* For now, we never want this to do anything */
@@ -1671,6 +1683,9 @@
     case META_PREF_NUM_WORKSPACES:
       return "NUM_WORKSPACES";
 
+    case META_PREF_WORKSPACES_LOOP_MODE:
+      return "WORKSPACES_LOOP_MODE";
+
     case META_PREF_APPLICATION_BASED:
       return "APPLICATION_BASED";
 
diff -aru metacity-2.23.13/src/core/workspace.c metacity-2.23.13.new/src/core/workspace.c
--- metacity-2.23.13/src/core/workspace.c	2008-04-27 20:24:53.000000000 +0200
+++ metacity-2.23.13.new/src/core/workspace.c	2008-05-04 16:43:26.000000000 +0200
@@ -739,14 +739,34 @@
       break;
     }
 
-  if (layout.current_col < 0)
-    layout.current_col = 0;
-  if (layout.current_col >= layout.cols)
-    layout.current_col = layout.cols - 1;
-  if (layout.current_row < 0)
-    layout.current_row = 0;
-  if (layout.current_row >= layout.rows)
-    layout.current_row = layout.rows - 1;
+  /* which method use to switch to an out-of-range workspace
+   *  - loop:   when trying to go to the right from the right workspace, go to
+   *            the left workspace
+   *  - linear: when trying to go to the right from the right workspace, don't
+   *            do anything
+   */
+  if (meta_prefs_get_workspaces_loop_mode ())
+    { /* "loop" mode */
+      if (layout.current_col < 0)
+        layout.current_col = layout.cols - 1;
+      if (layout.current_col >= layout.cols)
+        layout.current_col = 0;
+      if (layout.current_row < 0)
+        layout.current_row = layout.rows - 1;
+      if (layout.current_row >= layout.rows)
+        layout.current_row = 0;
+    }
+  else
+    { /* "linear" ("normal") mode */
+      if (layout.current_col < 0)
+        layout.current_col = 0;
+      if (layout.current_col >= layout.cols)
+        layout.current_col = layout.cols - 1;
+      if (layout.current_row < 0)
+        layout.current_row = 0;
+      if (layout.current_row >= layout.rows)
+        layout.current_row = layout.rows - 1;
+    }
 
   i = layout.grid[layout.current_row * layout.cols + layout.current_col];
 
diff -aru metacity-2.23.13/src/include/prefs.h metacity-2.23.13.new/src/include/prefs.h
--- metacity-2.23.13/src/include/prefs.h	2008-04-27 20:24:49.000000000 +0200
+++ metacity-2.23.13.new/src/include/prefs.h	2008-05-04 15:51:18.000000000 +0200
@@ -43,6 +43,7 @@
   META_PREF_THEME,
   META_PREF_TITLEBAR_FONT,
   META_PREF_NUM_WORKSPACES,
+  META_PREF_WORKSPACES_LOOP_MODE,
   META_PREF_APPLICATION_BASED,
   META_PREF_WINDOW_KEYBINDINGS,
   META_PREF_SCREEN_KEYBINDINGS,
@@ -80,6 +81,7 @@
 /* returns NULL if GTK default should be used */
 const PangoFontDescription* meta_prefs_get_titlebar_font      (void);
 int                         meta_prefs_get_num_workspaces     (void);
+gboolean                    meta_prefs_get_workspaces_loop_mode (void);
 gboolean                    meta_prefs_get_application_based  (void);
 gboolean                    meta_prefs_get_disable_workarounds (void);
 gboolean                    meta_prefs_get_auto_raise         (void);
Seulement dans metacity-2.23.13/src/: inlinepixbufs.h
Seulement dans metacity-2.23.13/src/: metacity.desktop
Seulement dans metacity-2.23.13/src/: metacity.schemas
diff -aru metacity-2.23.13/src/metacity.schemas.in metacity-2.23.13.new/src/metacity.schemas.in
--- metacity-2.23.13/src/metacity.schemas.in	2008-04-27 20:24:56.000000000 +0200
+++ metacity-2.23.13.new/src/metacity.schemas.in	2008-05-04 16:26:52.000000000 +0200
@@ -274,6 +274,22 @@
     </schema>
 
     <schema>
+      <key>/schemas/apps/metacity/general/workspaces_loop_mode</key>
+      <applyto>/apps/metacity/general/workspaces_loop_mode</applyto>      
+      <owner>metacity</owner>
+      <type>bool</type>
+      <default>false</default>
+      <locale name="C">
+        <short>Loop mode for workspace switching</short>
+        <long>
+          Determines the switching mode if there is no workspace in demanded
+          direction. Loop mode switch to the opposite workspace; Normal mode
+          do nothing and keep current workspace.
+        </long>
+      </locale>
+    </schema>
+
+    <schema>
       <key>/schemas/apps/metacity/general/visual_bell</key>
       <applyto>/apps/metacity/general/visual_bell</applyto>      
       <owner>metacity</owner>
