Browse Source

Imported Upstream version 2.4.0

upstream upstream/2.4.0
Fabio Fantoni 8 years ago
parent
commit
fe1047149d
  1. 2
      Makefile.am
  2. 8
      configure.ac
  3. 8
      src/Makefile.am
  4. 5
      src/compositor/meta-window-actor.c
  5. 2
      src/compositor/plugins/Makefile.am
  6. 2
      src/core/constraints.c
  7. 4
      src/core/core.c
  8. 17
      src/core/display-private.h
  9. 18
      src/core/display.c
  10. 2
      src/core/keybindings-private.h
  11. 273
      src/core/keybindings.c
  12. 76
      src/core/prefs.c
  13. 29
      src/core/screen.c
  14. 2
      src/core/window-private.h
  15. 169
      src/core/window.c
  16. 2
      src/core/workspace.c
  17. 1
      src/meta/atomnames.h
  18. 19
      src/meta/common.h
  19. 5
      src/meta/display.h
  20. 8
      src/meta/prefs.h
  21. 3
      src/meta/window.h
  22. 6
      src/muffin-schemas.convert
  23. 379
      src/org.cinnamon.muffin.gschema.xml.in
  24. 2
      src/tools/Makefile.am
  25. 30
      src/ui/frames.c
  26. 2
      src/ui/menu.c
  27. 3
      src/ui/theme-parser.c
  28. 4
      src/ui/theme.c
  29. 3
      src/ui/tile-hud.c
  30. 2
      src/wm-tester/Makefile.am

2
Makefile.am

@ -1,6 +1,8 @@
SUBDIRS=src po doc
ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS}
EXTRA_DIST = HACKING MAINTAINERS rationales.txt
DISTCLEANFILES = intltool-extract intltool-merge intltool-update po/stamp-it po/.intltool-merge-cache

8
configure.ac

@ -1,8 +1,8 @@
AC_PREREQ(2.50)
m4_define([muffin_major_version], [2])
m4_define([muffin_minor_version], [2])
m4_define([muffin_micro_version], [6])
m4_define([muffin_minor_version], [4])
m4_define([muffin_micro_version], [0])
m4_define([muffin_version],
[muffin_major_version.muffin_minor_version.muffin_micro_version])
@ -15,7 +15,7 @@ AC_INIT([muffin], [muffin_version],
AC_CONFIG_SRCDIR(src/core/display.c)
AC_CONFIG_HEADERS(config.h)
AM_INIT_AUTOMAKE([1.11 no-dist-gzip dist-xz tar-ustar])
AM_INIT_AUTOMAKE([1.11 no-dist-gzip dist-xz tar-ustar subdir-objects])
m4_ifdef([AM_SILENT_RULES],[AM_SILENT_RULES([yes])],)
AM_MAINTAINER_MODE([enable])
@ -82,7 +82,7 @@ MUFFIN_PC_MODULES="
gio-2.0 >= 2.25.10
pango >= 1.2.0
cairo >= 1.10.0
cinnamon-desktop >= 1.0.0
cinnamon-desktop >= 2.3.0
xcomposite >= 0.2 xfixes xrender xdamage
$CLUTTER_PACKAGE >= 1.9.10
cogl-1.0 >= 1.9.6

8
src/Makefile.am

@ -5,7 +5,7 @@ lib_LTLIBRARIES = libmuffin.la
SUBDIRS=wm-tester tools compositor/plugins
INCLUDES= \
AM_CPPFLAGS= \
$(MUFFIN_CFLAGS) \
-I$(srcdir) \
-I$(srcdir)/core \
@ -229,7 +229,7 @@ INTROSPECTION_GIRS = Meta-$(api_version).gir
Meta-$(api_version).gir: libmuffin.la
@META_GIR@_INCLUDES = GObject-2.0 CDesktopEnums-3.0 Gdk-3.0 Gtk-3.0 Clutter-1.0 xlib-2.0 xfixes-4.0
@META_GIR@_PACKAGES = clutter-1.0 gtk+-3.0
@META_GIR@_CFLAGS = $(INCLUDES)
@META_GIR@_CFLAGS = $(AM_CPPFLAGS)
@META_GIR@_LIBS = libmuffin.la
@META_GIR@_FILES = \
muffin-enum-types.h \
@ -268,9 +268,6 @@ gsettings_SCHEMAS = org.cinnamon.muffin.gschema.xml
@INTLTOOL_XML_NOMERGE_RULE@
@GSETTINGS_RULES@
convertdir = $(datadir)/GConf/gsettings
convert_DATA = muffin-schemas.convert
IMAGES=stock_maximize.png stock_minimize.png stock_delete.png
VARIABLES=stock_maximize_data $(srcdir)/stock_maximize.png \
stock_minimize_data $(srcdir)/stock_minimize.png \
@ -298,7 +295,6 @@ EXTRA_DIST=$(desktopfiles_files) \
$(desktopfiles_in_files) \
$(xml_in_files) \
org.cinnamon.muffin.gschema.xml.in \
muffin-schemas.convert \
libmuffin.pc.in \
muffin-plugins.pc.in \
muffin-enum-types.h.in \

5
src/compositor/meta-window-actor.c

@ -1226,6 +1226,9 @@ meta_window_actor_should_unredirect (MetaWindowActor *self)
if (!meta_window_is_monitor_sized (metaWindow))
return FALSE;
if (!meta_prefs_get_unredirect_fullscreen_windows())
return FALSE;
if (meta_window_requested_bypass_compositor (metaWindow))
return TRUE;
@ -1396,7 +1399,7 @@ meta_window_actor_hide (MetaWindowActor *self,
priv = self->priv;
info = meta_screen_get_compositor_data (priv->screen);
g_return_if_fail (priv->visible);
g_return_if_fail (priv->visible || (!priv->visible && meta_window_is_attached_dialog (priv->window)));
priv->visible = FALSE;

2
src/compositor/plugins/Makefile.am

@ -1,7 +1,7 @@
pkglibdir=@MUFFIN_PLUGIN_DIR@
INCLUDES=@MUFFIN_CFLAGS@ -I $(top_srcdir)/src -DMUFFIN_LIBEXECDIR=\"$(libexecdir)\" -DHOST_ALIAS=\"@HOST_ALIAS@\" -DMUFFIN_LOCALEDIR=\"$(prefix)/@DATADIRNAME@/locale\" -DMUFFIN_PKGDATADIR=\"$(pkgdatadir)\" -DMUFFIN_DATADIR=\"$(datadir)\" -DG_LOG_DOMAIN=\"muffin\" -DSN_API_NOT_YET_FROZEN=1 -DMUFFIN_MAJOR_VERSION=$(MUFFIN_MAJOR_VERSION) -DMUFFIN_MINOR_VERSION=$(MUFFIN_MINOR_VERSION) -DMUFFIN_MICRO_VERSION=$(MUFFIN_MICRO_VERSION) -DMUFFIN_PLUGIN_API_VERSION=$(MUFFIN_PLUGIN_API_VERSION) -DMUFFIN_PLUGIN_DIR=\"@MUFFIN_PLUGIN_DIR@\"
AM_CPPFLAGS=@MUFFIN_CFLAGS@ -I $(top_srcdir)/src -DMUFFIN_LIBEXECDIR=\"$(libexecdir)\" -DHOST_ALIAS=\"@HOST_ALIAS@\" -DMUFFIN_LOCALEDIR=\"$(prefix)/@DATADIRNAME@/locale\" -DMUFFIN_PKGDATADIR=\"$(pkgdatadir)\" -DMUFFIN_DATADIR=\"$(datadir)\" -DG_LOG_DOMAIN=\"muffin\" -DSN_API_NOT_YET_FROZEN=1 -DMUFFIN_MAJOR_VERSION=$(MUFFIN_MAJOR_VERSION) -DMUFFIN_MINOR_VERSION=$(MUFFIN_MINOR_VERSION) -DMUFFIN_MICRO_VERSION=$(MUFFIN_MICRO_VERSION) -DMUFFIN_PLUGIN_API_VERSION=$(MUFFIN_PLUGIN_API_VERSION) -DMUFFIN_PLUGIN_DIR=\"@MUFFIN_PLUGIN_DIR@\"
default_la_CFLAGS = -fPIC
default_la_SOURCES = default.c

2
src/core/constraints.c

@ -624,7 +624,7 @@ place_window_if_needed(MetaWindow *window,
window->snap_queued = TRUE;
else
window->snap_queued = FALSE;
meta_window_tile (window, TRUE);
meta_window_real_tile (window, TRUE);
meta_XFree (tile_info);
}
}

4
src/core/core.c

@ -89,6 +89,7 @@ meta_core_get (Display *xdisplay,
if (request != META_CORE_WINDOW_HAS_FRAME &&
(window == NULL || window->frame == NULL)) {
meta_bug ("No such frame window 0x%lx!\n", xwindow);
va_end (args);
return;
}
@ -662,6 +663,9 @@ meta_core_get_menu_accelerator (MetaMenuOp menu_op,
case META_MENU_OP_MOVE_DOWN:
name = "move-to-workspace-down";
break;
case META_MENU_OP_MOVE_NEW:
name = "move-to-workspace-new";
break;
case META_MENU_OP_RECOVER:
/* No keybinding for this one */
break;

17
src/core/display-private.h

@ -74,19 +74,6 @@ typedef void (* MetaWindowPingFunc) (MetaDisplay *display,
*/
#define N_IGNORED_CROSSING_SERIALS 10
typedef enum {
META_TILE_NONE,
META_TILE_LEFT,
META_TILE_RIGHT,
META_TILE_ULC,
META_TILE_LLC,
META_TILE_URC,
META_TILE_LRC,
META_TILE_TOP,
META_TILE_BOTTOM,
META_TILE_MAXIMIZE
} MetaTileMode;
struct _MetaDisplay
{
GObject parent_instance;
@ -240,8 +227,6 @@ struct _MetaDisplay
unsigned int hyper_mask;
unsigned int super_mask;
unsigned int meta_mask;
MetaKeyCombo overlay_key_combo;
gboolean overlay_key_only_pressed;
/* Monitor cache */
unsigned int monitor_cache_invalidated : 1;
@ -437,8 +422,6 @@ void meta_display_queue_autoraise_callback (MetaDisplay *display,
MetaWindow *window);
void meta_display_remove_autoraise_callback (MetaDisplay *display);
void meta_display_overlay_key_activate (MetaDisplay *display);
/* In above-tab-keycode.c */
guint meta_display_get_above_tab_keycode (MetaDisplay *display);

18
src/core/display.c

@ -133,7 +133,6 @@ G_DEFINE_TYPE(MetaDisplay, meta_display, G_TYPE_OBJECT);
/* Signals */
enum
{
OVERLAY_KEY,
FOCUS_WINDOW,
WINDOW_CREATED,
WINDOW_DEMANDS_ATTENTION,
@ -232,14 +231,6 @@ meta_display_class_init (MetaDisplayClass *klass)
object_class->get_property = meta_display_get_property;
object_class->set_property = meta_display_set_property;
display_signals[OVERLAY_KEY] =
g_signal_new ("overlay-key",
G_TYPE_FROM_CLASS (klass),
G_SIGNAL_RUN_LAST,
0,
NULL, NULL, NULL,
G_TYPE_NONE, 0);
display_signals[WINDOW_CREATED] =
g_signal_new ("window-created",
G_TYPE_FROM_CLASS (klass),
@ -1830,7 +1821,8 @@ event_callback (XEvent *event,
if (event->xbutton.button == 4 || event->xbutton.button == 5)
{
if (event->xbutton.state == display->window_grab_modifiers)
gboolean unmodified = (event->xbutton.state & display->window_grab_modifiers) == 0;
if (!unmodified && event->xbutton.state == display->window_grab_modifiers)
{
if (event->xbutton.button == 4)
{
@ -5466,12 +5458,6 @@ meta_display_remove_autoraise_callback (MetaDisplay *display)
}
}
LOCAL_SYMBOL void
meta_display_overlay_key_activate (MetaDisplay *display)
{
g_signal_emit (display, display_signals[OVERLAY_KEY], 0);
}
void
meta_display_get_compositor_version (MetaDisplay *display,
int *major,

2
src/core/keybindings-private.h

@ -80,7 +80,7 @@ gboolean meta_prefs_add_keybinding (const char *name,
gboolean meta_prefs_remove_keybinding (const char *name);
gboolean meta_prefs_add_custom_keybinding (const char *name,
const char *binding,
const char **binding,
MetaKeyBindingAction action,
MetaKeyBindingFlags flags);

273
src/core/keybindings.c

@ -48,9 +48,11 @@
#include <X11/XKBlib.h>
#endif
#define SCHEMA_MUFFIN_KEYBINDINGS "org.cinnamon.muffin.keybindings"
#define SCHEMA_MUFFIN_KEYBINDINGS "org.cinnamon.desktop.keybindings.wm"
#define SCHEMA_MUFFIN "org.cinnamon.muffin"
static gboolean all_bindings_disabled = FALSE;
static gboolean modifier_only_is_down = FALSE;
static gboolean add_builtin_keybinding (MetaDisplay *display,
const char *name,
@ -303,12 +305,6 @@ reload_keycodes (MetaDisplay *display)
meta_topic (META_DEBUG_KEYBINDINGS,
"Reloading keycodes for binding tables\n");
if (display->overlay_key_combo.keysym != 0)
{
display->overlay_key_combo.keycode =
keysym_to_keycode (display, display->overlay_key_combo.keysym);
}
if (display->key_bindings)
{
int i;
@ -479,19 +475,6 @@ rebuild_key_binding_table (MetaDisplay *display)
g_list_free (prefs);
}
static void
rebuild_special_bindings (MetaDisplay *display)
{
MetaKeyCombo combo;
meta_prefs_get_overlay_binding (&combo);
if (combo.keysym != None || combo.keycode != 0)
{
display->overlay_key_combo = combo;
}
}
static void
regrab_key_bindings (MetaDisplay *display)
{
@ -662,7 +645,7 @@ meta_display_remove_keybinding (MetaDisplay *display,
static gboolean
add_custom_keybinding_internal (MetaDisplay *display,
const char *name,
const char *binding,
const char **bindings,
MetaKeyBindingFlags flags,
MetaKeyBindingAction action,
MetaKeyHandlerFunc func,
@ -672,7 +655,7 @@ add_custom_keybinding_internal (MetaDisplay *display,
{
MetaKeyHandler *handler;
if (!meta_prefs_add_custom_keybinding (name, binding, action, flags))
if (!meta_prefs_add_custom_keybinding (name, bindings, action, flags))
return FALSE;
handler = g_new0 (MetaKeyHandler, 1);
@ -694,7 +677,7 @@ add_custom_keybinding_internal (MetaDisplay *display,
* meta_display_add_custom_keybinding:
* @display: a #MetaDisplay
* @name: the binding's unique name
* @binding: the parseable keystrokes string (<Control>F1, etc..)
* @bindings: (allow-none) (array zero-terminated=1): array of parseable keystrokes
* @callback: function to run when the keybinding is invoked
* @user_data: the data to pass to @handler
* @free_data: function to free @user_data
@ -706,15 +689,15 @@ add_custom_keybinding_internal (MetaDisplay *display,
* otherwise %FALSE
*/
gboolean
meta_display_add_custom_keybinding (MetaDisplay *display,
meta_display_add_custom_keybinding (MetaDisplay *display,
const char *name,
const char *binding,
const char **bindings,
MetaKeyHandlerFunc callback,
gpointer user_data,
GDestroyNotify free_data)
{
return add_custom_keybinding_internal (display, name, binding,
return add_custom_keybinding_internal (display, name, bindings,
META_KEY_BINDING_NONE,
META_KEYBINDING_ACTION_CUSTOM,
(MetaKeyHandlerFunc)callback, 0, user_data, free_data);
@ -797,22 +780,6 @@ meta_display_keybinding_action_invoke_by_code (MetaDisplay *display,
invoke_handler_by_name (display, NULL, binding->name, NULL, NULL);
}
gboolean
meta_display_get_is_overlay_key (MetaDisplay *display,
unsigned int keycode,
unsigned long mask)
{
MetaKeyCombo combo;
KeySym keysym;
keysym = XkbKeycodeToKeysym (display->xdisplay, keycode, 0, 0);
mask = mask & 0xff & ~display->ignored_modifier_mask;
meta_prefs_get_overlay_binding (&combo);
return combo.keysym == keysym && combo.modifiers == mask;
}
LOCAL_SYMBOL void
meta_display_process_mapping_event (MetaDisplay *display,
XEvent *event)
@ -879,7 +846,6 @@ bindings_changed_callback (MetaPreference pref,
{
case META_PREF_KEYBINDINGS:
rebuild_key_binding_table (display);
rebuild_special_bindings (display);
reload_keycodes (display);
reload_modifiers (display);
regrab_key_bindings (display);
@ -893,7 +859,6 @@ void
meta_display_rebuild_keybindings (MetaDisplay *display)
{
rebuild_key_binding_table (display);
rebuild_special_bindings (display);
reload_keycodes (display);
reload_modifiers (display);
regrab_key_bindings (display);
@ -1070,18 +1035,11 @@ ungrab_all_keys (MetaDisplay *display,
LOCAL_SYMBOL void
meta_screen_grab_keys (MetaScreen *screen)
{
MetaDisplay *display = screen->display;
if (screen->all_keys_grabbed)
return;
if (screen->keys_grabbed)
return;
if (display->overlay_key_combo.keycode != 0)
meta_grab_key (display, screen->xroot,
display->overlay_key_combo.keysym,
display->overlay_key_combo.keycode,
display->overlay_key_combo.modifiers);
grab_keys (screen->display->key_bindings,
screen->display->n_key_bindings,
@ -1518,6 +1476,62 @@ invoke_handler_by_name (MetaDisplay *display,
invoke_handler (display, screen, handler, window, event, NULL);
}
static gboolean
modifier_only_keysym (KeySym keysym)
{
return keysym == XK_Super_L ||
keysym == XK_Super_R ||
keysym == XK_Control_L ||
keysym == XK_Control_R ||
keysym == XK_Alt_L ||
keysym == XK_Alt_R ||
keysym == XK_Shift_L ||
keysym == XK_Shift_R;
}
static void
strip_self_mod (KeySym keysym, unsigned long *mask)
{
unsigned long mod = 0;
switch (keysym)
{
case XK_Super_L:
case XK_Super_R:
mod = GDK_MOD4_MASK;
break;
case XK_Control_L:
case XK_Control_R:
mod = GDK_CONTROL_MASK;
break;
case XK_Alt_L:
case XK_Alt_R:
mod = GDK_MOD1_MASK;
break;
case XK_Shift_L:
case XK_Shift_R:
mod = GDK_SHIFT_MASK;
break;
default:
mod = 0;
break;
}
*mask = *mask & ~mod;
}
static gboolean
is_modifier_only_kb (MetaDisplay *display, XEvent *event, KeySym keysym)
{
unsigned long mask;
mask = (event->xkey.state & 0xff & ~(display->ignored_modifier_mask));
strip_self_mod (keysym, &mask);
return mask == 0 && modifier_only_keysym (keysym);
}
/* now called from only one place, may be worth merging */
static gboolean
process_event (MetaKeyBinding *bindings,
@ -1527,13 +1541,23 @@ process_event (MetaKeyBinding *bindings,
MetaWindow *window,
XEvent *event,
KeySym keysym,
gboolean on_window)
gboolean on_window,
gboolean allow_release)
{
int i;
unsigned long mask;
/* we used to have release-based bindings but no longer. */
if (event->type == KeyRelease)
if (event->type == KeyRelease && !allow_release)
return FALSE;
mask = event->xkey.state & 0xff & ~(display->ignored_modifier_mask);
if (allow_release)
{
strip_self_mod (keysym, &mask);
}
/*
* TODO: This would be better done with a hash table;
* it doesn't suit to use O(n) for such a common operation.
@ -1543,10 +1567,9 @@ process_event (MetaKeyBinding *bindings,
MetaKeyHandler *handler = bindings[i].handler;
if ((!on_window && handler->flags & META_KEY_BINDING_PER_WINDOW) ||
event->type != KeyPress ||
(event->type != KeyPress && !allow_release) ||
bindings[i].keycode != event->xkey.keycode ||
((event->xkey.state & 0xff & ~(display->ignored_modifier_mask)) !=
bindings[i].mask))
mask != bindings[i].mask)
continue;
/*
@ -1584,16 +1607,16 @@ process_event (MetaKeyBinding *bindings,
}
static gboolean
process_overlay_key (MetaDisplay *display,
process_modifier_key (MetaDisplay *display,
MetaScreen *screen,
XEvent *event,
KeySym keysym)
{
if (display->overlay_key_only_pressed)
if (modifier_only_is_down)
{
if (event->xkey.keycode != display->overlay_key_combo.keycode)
if (!is_modifier_only_kb (display, event, keysym))
{
display->overlay_key_only_pressed = FALSE;
modifier_only_is_down = FALSE;
/* OK, the user hit modifier+key rather than pressing and
* releasing the ovelay key. We want to handle the key
@ -1610,7 +1633,7 @@ process_overlay_key (MetaDisplay *display,
if (process_event (display->key_bindings,
display->n_key_bindings,
display, screen, NULL, event, keysym,
FALSE))
FALSE, FALSE))
{
/* As normally, after we've handled a global key
* binding, we unfreeze the keyboard but keep the grab
@ -1627,19 +1650,22 @@ process_overlay_key (MetaDisplay *display,
}
else if (event->xkey.type == KeyRelease)
{
display->overlay_key_only_pressed = FALSE;
modifier_only_is_down = FALSE;
/* We want to unfreeze events, but keep the grab so that if the user
* starts typing into the overlay we get all the keys */
XAllowEvents (display->xdisplay, AsyncKeyboard, event->xkey.time);
meta_display_overlay_key_activate (display);
return process_event (display->key_bindings,
display->n_key_bindings,
display, screen, NULL, event, keysym,
FALSE, TRUE);
}
return TRUE;
}
else if (event->xkey.type == KeyPress &&
event->xkey.keycode == display->overlay_key_combo.keycode)
is_modifier_only_kb (display, event, keysym))
{
display->overlay_key_only_pressed = TRUE;
modifier_only_is_down = TRUE;
/* We keep the keyboard frozen - this allows us to use ReplayKeyboard
* on the next event if it's not the release of the overlay key */
XAllowEvents (display->xdisplay, SyncKeyboard, event->xkey.time);
@ -1719,9 +1745,10 @@ meta_display_process_key_event (MetaDisplay *display,
window ? window->desc : "(no window)");
all_keys_grabbed = window ? window->all_keys_grabbed : screen->all_keys_grabbed;
if (!all_keys_grabbed)
{
handled = process_overlay_key (display, screen, event, keysym);
handled = process_modifier_key (display, screen, event, keysym);
if (handled)
return TRUE;
}
@ -1818,7 +1845,7 @@ meta_display_process_key_event (MetaDisplay *display,
return process_event (display->key_bindings,
display->n_key_bindings,
display, screen, window, event, keysym,
!all_keys_grabbed && window);
!all_keys_grabbed && window, FALSE);
}
static gboolean
@ -1853,7 +1880,7 @@ process_mouse_move_resize_grab (MetaDisplay *display,
META_MAXIMIZE_VERTICAL);
else if (window->tile_mode != META_TILE_NONE) {
window->custom_snap_size = FALSE;
meta_window_tile (window, FALSE);
meta_window_real_tile (window, FALSE);
} else
meta_window_move_resize (display->grab_window,
TRUE,
@ -2791,19 +2818,17 @@ handle_move_to_corner_backend (MetaDisplay *display,
{
MetaRectangle work_area;
MetaRectangle outer;
int orig_x, orig_y;
int new_x, new_y;
meta_window_get_work_area_all_monitors (window, &work_area);
meta_window_get_outer_rect (window, &outer);
meta_window_get_position (window, &orig_x, &orig_y);
if (xchange) {
new_x = work_area.x + (to_right ?
work_area.width - outer.width :
0);
} else {
new_x = orig_x;
new_x = outer.x;
}
if (ychange) {
@ -2811,7 +2836,7 @@ handle_move_to_corner_backend (MetaDisplay *display,
work_area.height - outer.height :
0);
} else {
new_y = orig_y;
new_y = outer.y;
}
meta_window_move_frame (window,
@ -3077,9 +3102,6 @@ handle_panel (MetaDisplay *display,
switch (action)
{
/* FIXME: The numbers are wrong */
case META_KEYBINDING_ACTION_PANEL_MAIN_MENU:
action_atom = display->atom__GNOME_PANEL_ACTION_MAIN_MENU;
break;
case META_KEYBINDING_ACTION_PANEL_RUN_DIALOG:
action_atom = display->atom__GNOME_PANEL_ACTION_RUN_DIALOG;
break;
@ -3498,59 +3520,10 @@ handle_tile_action (MetaDisplay *display,
if (new_mode == window->tile_mode)
return;
gboolean can_do = FALSE;
switch (new_mode) {
case META_TILE_LEFT:
case META_TILE_RIGHT:
can_do = meta_window_can_tile_side_by_side (window);
break;
case META_TILE_TOP:
case META_TILE_BOTTOM:
can_do = meta_window_can_tile_top_bottom (window);
break;
case META_TILE_ULC:
case META_TILE_LLC:
case META_TILE_URC:
case META_TILE_LRC:
can_do = meta_window_can_tile_corner (window);
break;
default:
can_do = TRUE;
break;
}
if (!can_do)
if (!meta_window_can_tile (window, new_mode))
return;
if (new_mode != META_TILE_NONE) {
window->last_tile_mode = window->tile_mode;
window->snap_queued = snap;
window->tile_monitor_number = window->monitor->number;
window->tile_mode = new_mode;
window->custom_snap_size = FALSE;
window->saved_maximize = FALSE;
/* Maximization constraints beat tiling constraints, so if the window
* is maximized, tiling won't have any effect unless we unmaximize it
* horizontally first; rather than calling meta_window_unmaximize(),
* we just set the flag and rely on meta_window_tile() syncing it to
* save an additional roundtrip.
*/
meta_window_tile (window, TRUE);
} else {
window->last_tile_mode = window->tile_mode;
window->tile_mode = new_mode;
window->custom_snap_size = FALSE;
meta_window_set_tile_type (window, META_WINDOW_TILE_TYPE_NONE);
window->tile_monitor_number = window->saved_maximize ? window->monitor->number
: -1;
if (window->saved_maximize)
meta_window_maximize (window, META_MAXIMIZE_VERTICAL |
META_MAXIMIZE_HORIZONTAL);
else
meta_window_unmaximize (window, META_MAXIMIZE_VERTICAL |
META_MAXIMIZE_HORIZONTAL);
}
meta_window_tile (window, new_mode, snap);
}
static void
@ -3695,6 +3668,7 @@ handle_move_to_workspace (MetaDisplay *display,
{
gint which = binding->handler->data;
gboolean flip = (which < 0);
gboolean new = (which == META_MOTION_NOT_EXIST_YET);
MetaWorkspace *workspace;
/* If which is zero or positive, it's a workspace number, and the window
@ -3709,15 +3683,17 @@ handle_move_to_workspace (MetaDisplay *display,
return;
workspace = NULL;
if (flip)
{
workspace = meta_workspace_get_neighbor (screen->active_workspace,
which);
}
else
{
workspace = meta_screen_get_workspace_by_index (screen, which);
}
if (!new) {
if (flip)
{
workspace = meta_workspace_get_neighbor (screen->active_workspace,
which);
}
else
{
workspace = meta_screen_get_workspace_by_index (screen, which);
}
}
if (workspace)
{
@ -3734,10 +3710,15 @@ handle_move_to_workspace (MetaDisplay *display,
event->xkey.time);
}
}
else
else if (new)
{
/* We could offer to create it I suppose */
}
workspace = meta_screen_append_new_workspace (window->screen, FALSE, event->xkey.time);
GSettings *cinnamon = g_settings_new ("org.cinnamon");
g_settings_set_int (cinnamon, "number-workspaces", g_list_length (screen->workspaces));
g_object_unref (cinnamon);
meta_window_change_workspace (window, workspace);
}
}
static void
@ -4029,7 +4010,6 @@ init_builtin_key_bindings (MetaDisplay *display)
META_KEYBINDING_ACTION_WORKSPACE_DOWN,
handle_switch_to_workspace, META_MOTION_DOWN);
/* The ones which have inverses. These can't be bound to any keystroke
* containing Shift because Shift will invert their "backward" state.
*
@ -4153,13 +4133,6 @@ init_builtin_key_bindings (MetaDisplay *display)
META_KEYBINDING_ACTION_SHOW_DESKTOP,
handle_show_desktop, 0);
add_builtin_keybinding (display,
"panel-main-menu",
SCHEMA_MUFFIN_KEYBINDINGS,
META_KEY_BINDING_NONE,
META_KEYBINDING_ACTION_PANEL_MAIN_MENU,
handle_panel, META_KEYBINDING_ACTION_PANEL_MAIN_MENU);
add_builtin_keybinding (display,
"panel-run-dialog",
SCHEMA_MUFFIN_KEYBINDINGS,
@ -4443,6 +4416,13 @@ init_builtin_key_bindings (MetaDisplay *display)
META_KEYBINDING_ACTION_MOVE_TO_WORKSPACE_DOWN,
handle_move_to_workspace, META_MOTION_DOWN);
add_builtin_keybinding (display,
"move-to-workspace-new",
SCHEMA_MUFFIN_KEYBINDINGS,
META_KEY_BINDING_PER_WINDOW,
META_KEYBINDING_ACTION_MOVE_TO_WORKSPACE_NEW,
handle_move_to_workspace, META_MOTION_NOT_EXIST_YET);
add_builtin_keybinding (display,
"raise-or-lower",
SCHEMA_MUFFIN_KEYBINDINGS,
@ -4591,7 +4571,6 @@ meta_display_init_keys (MetaDisplay *display)
init_builtin_key_bindings (display);
rebuild_key_binding_table (display);
rebuild_special_bindings (display);
reload_keycodes (display);
reload_modifiers (display);

76
src/core/prefs.c

@ -55,7 +55,6 @@
#define KEY_MIN_WINDOW_OPACITY "min-window-opacity"
#define KEY_WS_NAMES_GNOME "workspace-names"
#define KEY_OVERLAY_KEY "overlay-key"
#define KEY_LIVE_HIDDEN_WINDOWS "live-hidden-windows"
#define KEY_WORKSPACES_ONLY_ON_PRIMARY "workspaces-only-on-primary"
#define KEY_NO_TAB_POPUP "no-tab-popup"
@ -89,6 +88,7 @@ static CDesktopTitlebarAction action_middle_click_titlebar = C_DESKTOP_TITLEBAR_
static CDesktopTitlebarAction action_right_click_titlebar = C_DESKTOP_TITLEBAR_ACTION_MENU;
static CDesktopTitlebarScrollAction action_scroll_titlebar = C_DESKTOP_TITLEBAR_SCROLL_ACTION_NONE;
static gboolean dynamic_workspaces = FALSE;
static gboolean unredirect_fullscreen_windows = FALSE;
static gboolean application_based = FALSE;
static gboolean disable_workarounds = FALSE;
static gboolean auto_raise = FALSE;
@ -326,6 +326,13 @@ static MetaBoolPreference preferences_bool[] =
},
&dynamic_workspaces,
},
{
{ "unredirect-fullscreen-windows",
SCHEMA_MUFFIN,
META_PREF_UNREDIRECT_FULLSCREEN_WINDOWS,
},
&unredirect_fullscreen_windows,
},
{
{ "application-based",
SCHEMA_GENERAL,
@ -1154,10 +1161,6 @@ settings_changed (GSettings *settings,
else
handle_preference_update_string (settings, key);
}
else if (g_str_equal (key, KEY_OVERLAY_KEY))
{
queue_changed (META_PREF_KEYBINDINGS);
}
else if (g_str_equal (key, KEY_WS_NAMES_GNOME))
{
return;
@ -1680,6 +1683,12 @@ meta_prefs_get_dynamic_workspaces (void)
return dynamic_workspaces;
}
gboolean
meta_prefs_get_unredirect_fullscreen_windows (void)
{
return unredirect_fullscreen_windows;
}
gboolean
meta_prefs_get_application_based (void)
{
@ -1812,6 +1821,9 @@ meta_preference_to_string (MetaPreference pref)
case META_PREF_DYNAMIC_WORKSPACES:
return "DYNAMIC_WORKSPACES";
case META_PREF_UNREDIRECT_FULLSCREEN_WINDOWS:
return "UNREDIRECT_FULLSCREEN_WINDOWS";
case META_PREF_SNAP_MODIFIER:
return "SNAP_MODIFIER";
@ -1851,8 +1863,6 @@ meta_prefs_set_num_workspaces (int n_workspaces)
static GHashTable *key_bindings;
static MetaKeyCombo overlay_key_combo = { 0, 0, 0 };
static void
meta_key_pref_free (MetaKeyPref *pref)
{
@ -1864,37 +1874,11 @@ meta_key_pref_free (MetaKeyPref *pref)
g_free (pref);
}
/* These bindings are for modifiers alone, so they need special handling */
static void
init_special_bindings (void)
{
char *val;
/* Default values for bindings which are global, but take special handling */
meta_ui_parse_accelerator ("Super_L", &overlay_key_combo.keysym,
&overlay_key_combo.keycode,
&overlay_key_combo.modifiers);
val = g_settings_get_string (SETTINGS (SCHEMA_MUFFIN), KEY_OVERLAY_KEY);
if (val && meta_ui_parse_accelerator (val, &overlay_key_combo.keysym,
&overlay_key_combo.keycode,
&overlay_key_combo.modifiers))
;
else
{
meta_topic (META_DEBUG_KEYBINDINGS,
"Failed to parse value for overlay_key\n");
}
g_free (val);
}
static void
init_bindings (void)
{
key_bindings = g_hash_table_new_full (g_str_hash, g_str_equal, g_free,
(GDestroyNotify)meta_key_pref_free);
init_special_bindings ();
}
static void
@ -2217,9 +2201,9 @@ meta_prefs_remove_keybinding (const char *name)
LOCAL_SYMBOL gboolean
meta_prefs_add_custom_keybinding (const char *name,
const char *binding,
MetaKeyBindingAction action,
MetaKeyBindingFlags flags)
const char **bindings,
MetaKeyBindingAction action,
MetaKeyBindingFlags flags)
{
MetaKeyPref *pref;
@ -2232,16 +2216,14 @@ meta_prefs_add_custom_keybinding (const char *name,
pref = g_new0 (MetaKeyPref, 1);
pref->name = g_strdup (name);
pref->schema = g_strdup (binding);
pref->schema = NULL;
pref->action = action;
pref->bindings = NULL;
pref->add_shift = (flags & META_KEY_BINDING_REVERSES) != 0;
pref->per_window = (flags & META_KEY_BINDING_PER_WINDOW) != 0;
pref->builtin = (flags & META_KEY_BINDING_BUILTIN) != 0;
char **strokes = g_strsplit(binding, "XYZZY", 1);
update_binding (pref, strokes);
g_strfreev (strokes);
update_binding (pref, (gchar **)bindings);
g_hash_table_insert (key_bindings, g_strdup (name), pref);
@ -2278,12 +2260,6 @@ meta_prefs_get_keybindings ()
return g_hash_table_get_values (key_bindings);
}
void
meta_prefs_get_overlay_binding (MetaKeyCombo *combo)
{
*combo = overlay_key_combo;
}
CDesktopTitlebarAction
meta_prefs_get_action_double_click_titlebar (void)
{
@ -2504,3 +2480,9 @@ meta_prefs_get_min_win_opacity (void)
{
return min_window_opacity;
}
gint
meta_prefs_get_ui_scale (void)
{
return ui_scale;
}

29
src/core/screen.c

@ -2299,11 +2299,14 @@ meta_screen_get_mouse_window (MetaScreen *screen,
MetaWindow *not_this_one)
{
MetaWindow *window;
GList *windows;
Window root_return, child_return;
int root_x_return, root_y_return;
int win_x_return, win_y_return;
unsigned int mask_return;
window = NULL;
if (not_this_one)
meta_topic (META_DEBUG_FOCUS,
"Focusing mouse window excluding %s\n", not_this_one->desc);
@ -2320,11 +2323,27 @@ meta_screen_get_mouse_window (MetaScreen *screen,
&mask_return);
meta_error_trap_pop (screen->display);
window = meta_stack_get_default_focus_window_at_point (screen->stack,
screen->active_workspace,
not_this_one,
root_x_return,
root_y_return);
if (screen->active_workspace->showing_desktop)
{
windows = screen->active_workspace->mru_list;
while (windows != NULL)
{
MetaWindow *w = windows->data;
if (w->screen == screen &&
w->type == META_WINDOW_DESKTOP)
{
window = w;
break;
}
windows = windows->next;
}
}
else
window = meta_stack_get_default_focus_window_at_point (screen->stack,
screen->active_workspace,
not_this_one,
root_x_return,
root_y_return);
return window;
}

2
src/core/window-private.h

@ -548,7 +548,7 @@ void meta_window_unmanage (MetaWindow *window,
void meta_window_calc_showing (MetaWindow *window);
void meta_window_queue (MetaWindow *window,
guint queuebits);
void meta_window_tile (MetaWindow *window,
void meta_window_real_tile (MetaWindow *window,
gboolean force);
void meta_window_maximize_internal (MetaWindow *window,
MetaMaximizeFlags directions,

169
src/core/window.c

@ -1698,7 +1698,7 @@ meta_window_unmanage (MetaWindow *window,
if (window->display->compositor)
{
if (window->visible_to_compositor)
if (window->visible_to_compositor || meta_window_is_attached_dialog (window))
meta_compositor_hide_window (window->display->compositor, window,
META_COMP_EFFECT_DESTROY);
@ -3810,7 +3810,7 @@ normalize_tile_state (MetaWindow *window)
}
LOCAL_SYMBOL void
meta_window_tile (MetaWindow *window, gboolean force)
meta_window_real_tile (MetaWindow *window, gboolean force)
{
/* Don't do anything if no tiling is requested or we're already tiled */
if (window->tile_mode == META_TILE_NONE || (META_WINDOW_TILED_OR_SNAPPED (window) && !force))
@ -4129,7 +4129,7 @@ meta_window_unmaximize (MetaWindow *window,
window->tile_mode == META_TILE_RIGHT)
{
window->maximized_horizontally = FALSE;
meta_window_tile (window, FALSE);
meta_window_real_tile (window, FALSE);
return;
}
@ -7413,8 +7413,7 @@ send_configure_notify (MetaWindow *window)
event.xconfigure.override_redirect = False;
meta_topic (META_DEBUG_GEOMETRY,
"Sending synthetic configure notify to %s with x: %d y: %d w: %d h: %d\n",
window->desc,
"Sending synthetic configure notify to %s with x: %d y: %d w: %d h: %d\n", window->desc,
event.xconfigure.x, event.xconfigure.y,
event.xconfigure.width, event.xconfigure.height);
@ -7976,6 +7975,13 @@ is_ime_popup (MetaWindow *window)
return !deco && (icon == NULL) && is_target_name;
}
static gboolean
is_steam (MetaWindow *window)
{
return window->type == META_WINDOW_MENU &&
g_strcmp0 (meta_window_get_wm_class (window), "Steam") == 0;
}
LOCAL_SYMBOL void
meta_window_recalc_window_type (MetaWindow *window)
{
@ -8068,13 +8074,15 @@ recalc_window_type (MetaWindow *window)
case META_WINDOW_NORMAL:
if (is_ime_popup (window)) {
window->type = META_WINDOW_POPUP_MENU;
break;
}
else
window->type = META_WINDOW_OVERRIDE_OTHER;
break;
case META_WINDOW_DIALOG:
case META_WINDOW_MODAL_DIALOG:
case META_WINDOW_MENU:
if (is_steam (window)) {
window->type = META_WINDOW_POPUP_MENU;
break;
}
case META_WINDOW_UTILITY:
window->type = META_WINDOW_OVERRIDE_OTHER;
break;
@ -8519,6 +8527,13 @@ menu_callback (MetaWindowMenu *menu,
workspace_index);
break;
case META_MENU_OP_MOVE_NEW:
workspace = meta_screen_append_new_workspace (window->screen, FALSE, timestamp);
GSettings *cinnamon = g_settings_new ("org.cinnamon");
g_settings_set_int (cinnamon, "number-workspaces", g_list_length (window->screen->workspaces));
g_object_unref (cinnamon);
break;
case META_MENU_OP_STICK:
meta_window_stick (window);
break;
@ -8594,7 +8609,7 @@ meta_window_show_menu (MetaWindow *window,
MetaWindowMenu *menu;
MetaWorkspaceLayout layout;
int n_workspaces;
gboolean ltr;
// gboolean ltr;
g_return_if_fail (!window->override_redirect);
@ -8608,6 +8623,7 @@ meta_window_show_menu (MetaWindow *window,
ops = META_MENU_OP_NONE;
insensitive = META_MENU_OP_NONE;
//ops |= (META_MENU_OP_DELETE | META_MENU_OP_MINIMIZE | META_MENU_OP_MOVE | META_MENU_OP_RESIZE | META_MENU_OP_MOVE_NEW);
ops |= (META_MENU_OP_DELETE | META_MENU_OP_MINIMIZE | META_MENU_OP_MOVE | META_MENU_OP_RESIZE);
if (!meta_window_titlebar_is_onscreen (window) &&
@ -8628,21 +8644,21 @@ meta_window_show_menu (MetaWindow *window,
meta_workspace_index ( window->screen->active_workspace),
&layout);
if (!window->on_all_workspaces)
{
ltr = meta_ui_get_direction() == META_UI_DIRECTION_LTR;
if (layout.current_col > 0)
ops |= ltr ? META_MENU_OP_MOVE_LEFT : META_MENU_OP_MOVE_RIGHT;
if ((layout.current_col < layout.cols - 1) &&
(layout.current_row * layout.cols + (layout.current_col + 1) < n_workspaces))
ops |= ltr ? META_MENU_OP_MOVE_RIGHT : META_MENU_OP_MOVE_LEFT;
if (layout.current_row > 0)
ops |= META_MENU_OP_MOVE_UP;
if ((layout.current_row < layout.rows - 1) &&
((layout.current_row + 1) * layout.cols + layout.current_col < n_workspaces))
ops |= META_MENU_OP_MOVE_DOWN;
}
// if (!window->on_all_workspaces)
// {
// ltr = meta_ui_get_direction() == META_UI_DIRECTION_LTR;
// if (layout.current_col > 0)
// ops |= ltr ? META_MENU_OP_MOVE_LEFT : META_MENU_OP_MOVE_RIGHT;
// if ((layout.current_col < layout.cols - 1) &&
// (layout.current_row * layout.cols + (layout.current_col + 1) < n_workspaces))
// ops |= ltr ? META_MENU_OP_MOVE_RIGHT : META_MENU_OP_MOVE_LEFT;
// if (layout.current_row > 0)
// ops |= META_MENU_OP_MOVE_UP;
// if ((layout.current_row < layout.rows - 1) &&
// ((layout.current_row + 1) * layout.cols + layout.current_col < n_workspaces))
// ops |= META_MENU_OP_MOVE_DOWN;
// }
meta_screen_free_workspace_layout (&layout);
@ -8960,7 +8976,12 @@ meta_window_get_current_zone (MetaWindow *window,
zone = ZONE_6;
break;
case ZONE_TOP:
if (meta_window_can_tile_top_bottom (window))
if (meta_prefs_get_tile_maximize() || window->maybe_retile_maximize)
{
if (meta_window_can_tile_maximized(window))
zone = ZONE_0;
}
else if (meta_window_can_tile_top_bottom (window))
zone = ZONE_0;
break;
case ZONE_BOTTOM:
@ -9078,15 +9099,12 @@ update_move (MetaWindow *window,
y,
meta_prefs_get_tile_hud_threshold ());
int scale;
scale = CLAMP ((int)(clutter_backend_get_resolution (clutter_get_default_backend ()) / 96.0), 1, 4);
guint edge_zone = meta_window_get_current_zone (window,
monitor->rect,
work_area,
x,
y,
HUD_WIDTH * scale);
HUD_WIDTH * meta_prefs_get_ui_scale ());
switch (edge_zone) {
case ZONE_0:
@ -9636,7 +9654,7 @@ update_resize (MetaWindow *window,
window->snap_queued = window->resizing_tile_type == META_WINDOW_TILE_TYPE_SNAPPED;
window->tile_mode = window->resize_tile_mode;
window->custom_snap_size = TRUE;
meta_window_tile (window, TRUE);
meta_window_real_tile (window, TRUE);
}
}
@ -9818,7 +9836,7 @@ meta_window_handle_mouse_grab_op_event (MetaWindow *window,
if (window->tile_mode == META_TILE_MAXIMIZE)
meta_window_maximize(window, META_MAXIMIZE_VERTICAL | META_MAXIMIZE_HORIZONTAL);
else
meta_window_tile (window, FALSE);
meta_window_real_tile (window, FALSE);
}
else if (event->xbutton.root == window->screen->xroot)
update_move (window,
@ -11697,3 +11715,92 @@ meta_window_mouse_on_edge (MetaWindow *window, gint x, gint y)
return ret;
}
/**
* meta_window_can_tile:
* @window: a #MetaWindow
* @mode: the #MetaTileMode to check for
*
* Tests if @window can be tiled or snapped in the supplied
* tiling zone
*
* Return value: whether @window can be tiled
*/
gboolean
meta_window_can_tile (MetaWindow *window, MetaTileMode mode)
{
g_return_val_if_fail (META_IS_WINDOW (window), FALSE);
switch (mode) {
case META_TILE_LEFT:
case META_TILE_RIGHT:
return meta_window_can_tile_side_by_side (window);
case META_TILE_TOP:
case META_TILE_BOTTOM:
return meta_window_can_tile_top_bottom (window);
case META_TILE_ULC:
case META_TILE_LLC:
case META_TILE_URC:
case META_TILE_LRC:
return meta_window_can_tile_corner (window);
case META_TILE_MAXIMIZE:
case META_TILE_NONE:
return TRUE;
default:
return FALSE;
}
}
/**
* meta_window_tile:
* @window: a #MetaWindow
* @mode: the #MetaTileMode to use
* @snap: whether to snap the window (as opposed to simple tile)
*
* Tiles or snaps the window in the requested configuration
*
* Return value: whether or not @window was successfully tiled
*/
gboolean
meta_window_tile (MetaWindow *window,
MetaTileMode mode,
gboolean snap)
{
g_return_val_if_fail (META_IS_WINDOW (window), FALSE);
if (!meta_window_can_tile (window, mode))
return FALSE;
if (mode != META_TILE_NONE) {
window->last_tile_mode = window->tile_mode;
window->snap_queued = snap;
window->tile_monitor_number = window->monitor->number;
window->tile_mode = mode;
window->custom_snap_size = FALSE;
window->saved_maximize = FALSE;
/* Maximization constraints beat tiling constraints, so if the window
* is maximized, tiling won't have any effect unless we unmaximize it
* horizontally first; rather than calling meta_window_unmaximize(),
* we just set the flag and rely on meta_window_real_tile() syncing it to
* save an additional roundtrip.
*/
meta_window_real_tile (window, TRUE);
} else {
window->last_tile_mode = window->tile_mode;
window->tile_mode = mode;
window->custom_snap_size = FALSE;
meta_window_set_tile_type (window, META_WINDOW_TILE_TYPE_NONE);
window->tile_monitor_number = window->saved_maximize ? window->monitor->number
: -1;
if (window->saved_maximize)
meta_window_maximize (window, META_MAXIMIZE_VERTICAL |
META_MAXIMIZE_HORIZONTAL);
else
meta_window_unmaximize (window, META_MAXIMIZE_VERTICAL |
META_MAXIMIZE_HORIZONTAL);
}
return TRUE;
}

2
src/core/workspace.c

@ -1156,6 +1156,8 @@ meta_motion_direction_to_string (MetaMotionDirection direction)
return "Up-Left";
case META_MOTION_DOWN_LEFT:
return "Down-Left";
case META_MOTION_NOT_EXIST_YET:
return "Nothing";
}
return "Unknown";

1
src/meta/atomnames.h

@ -68,7 +68,6 @@ item(_GTK_MENUBAR_OBJECT_PATH)
item(_GTK_FRAME_EXTENTS)
item(_GNOME_WM_KEYBINDINGS)
item(_GNOME_PANEL_ACTION)
item(_GNOME_PANEL_ACTION_MAIN_MENU)
item(_GNOME_PANEL_ACTION_RUN_DIALOG)
item(_MUFFIN_SENTINEL)
item(_MUFFIN_VERSION)

19
src/meta/common.h

@ -82,7 +82,8 @@ typedef enum
META_MENU_OP_MOVE_RIGHT = 1 << 14,
META_MENU_OP_MOVE_UP = 1 << 15,
META_MENU_OP_MOVE_DOWN = 1 << 16,
META_MENU_OP_RECOVER = 1 << 17
META_MENU_OP_RECOVER = 1 << 17,
META_MENU_OP_MOVE_NEW = 1 << 18
} MetaMenuOp;
typedef struct _MetaWindowMenu MetaWindowMenu;
@ -237,7 +238,8 @@ typedef enum
META_MOTION_UP_LEFT = -5,
META_MOTION_UP_RIGHT = -6,
META_MOTION_DOWN_LEFT = -7,
META_MOTION_DOWN_RIGHT = -8
META_MOTION_DOWN_RIGHT = -8,
META_MOTION_NOT_EXIST_YET = -30
} MetaMotionDirection;
/* Sometimes we want to talk about sides instead of directions; note
@ -272,6 +274,19 @@ typedef enum
META_BUTTON_FUNCTION_LAST
} MetaButtonFunction;
typedef enum {
META_TILE_NONE,
META_TILE_LEFT,
META_TILE_RIGHT,
META_TILE_ULC,
META_TILE_LLC,
META_TILE_URC,
META_TILE_LRC,
META_TILE_TOP,
META_TILE_BOTTOM,
META_TILE_MAXIMIZE
} MetaTileMode;
typedef enum {
META_WINDOW_TILE_TYPE_NONE,
META_WINDOW_TILE_TYPE_TILED,