summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/core/constraints.c6
-rw-r--r--src/core/display.c14
-rw-r--r--src/core/iconcache.c8
-rw-r--r--src/core/keybindings.c58
-rw-r--r--src/core/prefs.c6
-rw-r--r--src/core/screen.c4
-rw-r--r--src/core/util.c20
-rw-r--r--src/core/window.c40
-rw-r--r--src/core/workspace.c2
-rw-r--r--src/core/workspace.h2
-rw-r--r--src/core/xprops.c2
-rw-r--r--src/ui/tabpopup.c8
-rw-r--r--src/ui/theme.c2
13 files changed, 86 insertions, 86 deletions
diff --git a/src/core/constraints.c b/src/core/constraints.c
index 64ce497a..99b4077e 100644
--- a/src/core/constraints.c
+++ b/src/core/constraints.c
@@ -953,7 +953,7 @@ constrain_tiling (MetaWindow *window,
info->resize_gravity,
&allow_resize_horizontally,
&allow_resize_vertically);
-
+
window->tile_resized = TRUE;
}
@@ -974,11 +974,11 @@ constrain_tiling (MetaWindow *window,
}
if(!allow_resize_horizontally)
- {
+ {
info->current.x = target_size.x;
info->current.width = target_size.width;
}
-
+
return TRUE;
}
diff --git a/src/core/display.c b/src/core/display.c
index 0214d5e6..85f43684 100644
--- a/src/core/display.c
+++ b/src/core/display.c
@@ -1613,15 +1613,15 @@ mouse_event_is_in_tab_popup (MetaDisplay *display,
&x, &y, &child1);
GtkWidget *popup_widget = meta_ui_tab_popup_get_widget (screen->tab_popup);
- if (ok1 && popup_widget != NULL)
+ if (ok1 && popup_widget != NULL)
{
Window popup_xid = gdk_x11_window_get_xid (gtk_widget_get_window (popup_widget));
-
+
gboolean ok2 = XTranslateCoordinates (display->xdisplay,
event_window, popup_xid,
event_x, event_y,
popup_x, popup_y, &child2);
-
+
if (ok2 && child1 == popup_xid)
{
int scale = gtk_widget_get_scale_factor (popup_widget);
@@ -1860,7 +1860,7 @@ static gboolean event_callback(XEvent* event, gpointer data)
event->xbutton.y,
&popup_x,
&popup_y);
- if (is_in_tab_popup && event->xbutton.button == Button1)
+ if (is_in_tab_popup && event->xbutton.button == Button1)
{
display->tab_popup_mouse_pressed = TRUE;
meta_ui_tab_popup_mouse_press(screen->tab_popup, popup_x, popup_y);
@@ -1881,7 +1881,7 @@ static gboolean event_callback(XEvent* event, gpointer data)
"Syncing to old stack positions.\n");
screen =
meta_display_screen_for_root (display, event->xany.window);
-
+
if (screen!=NULL)
meta_stack_set_positions (screen->stack,
display->grab_old_window_stacking);
@@ -2056,7 +2056,7 @@ static gboolean event_callback(XEvent* event, gpointer data)
if (display->grab_window == window &&
grab_op_is_mouse (display->grab_op))
meta_window_handle_mouse_grab_op_event (window, event);
- if (event->xbutton.button == Button1)
+ if (event->xbutton.button == Button1)
display->tab_popup_mouse_pressed = FALSE;
break;
case MotionNotify:
@@ -2074,7 +2074,7 @@ static gboolean event_callback(XEvent* event, gpointer data)
event->xbutton.y,
&popup_x,
&popup_y);
- if (is_in_tab_popup)
+ if (is_in_tab_popup)
meta_ui_tab_popup_mouse_press (screen->tab_popup, popup_x, popup_y);
}
break;
diff --git a/src/core/iconcache.c b/src/core/iconcache.c
index 3c0f1b8d..aa1d4339 100644
--- a/src/core/iconcache.c
+++ b/src/core/iconcache.c
@@ -794,7 +794,7 @@ meta_read_icons (MetaScreen *screen,
pixmap != None)
{
icon_cache->wm_hints_dirty_forced = FALSE;
-
+
if (try_pixmap_and_mask (screen->display,
pixmap, mask,
iconp, ideal_width, ideal_height,
@@ -824,7 +824,7 @@ meta_read_icons (MetaScreen *screen,
pixmap != None)
{
icon_cache->kwm_win_icon_dirty_forced = FALSE;
-
+
if (try_pixmap_and_mask (screen->display, pixmap, mask,
iconp, ideal_width, ideal_height,
mini_iconp, ideal_mini_width, ideal_mini_height))
@@ -841,12 +841,12 @@ meta_read_icons (MetaScreen *screen,
}
if ((icon_cache->want_fallback &&
- icon_cache->origin < USING_FALLBACK_ICON)
+ icon_cache->origin < USING_FALLBACK_ICON)
|| (icon_cache->fallback_icon_dirty_forced &&
icon_cache->origin == USING_FALLBACK_ICON))
{
icon_cache->fallback_icon_dirty_forced = FALSE;
-
+
get_fallback_icons (screen,
iconp,
ideal_width,
diff --git a/src/core/keybindings.c b/src/core/keybindings.c
index e9597340..d37ec2cf 100644
--- a/src/core/keybindings.c
+++ b/src/core/keybindings.c
@@ -2339,7 +2339,7 @@ handle_switch_to_workspace (MetaDisplay *display,
meta_workspace_activate (workspace, event->xkey.time);
return;
}
-
+
if (which < 0)
{
/* Negative workspace numbers are directions with respect to the
@@ -2705,11 +2705,11 @@ handle_move_to_monitor (MetaDisplay *display,
MetaWindow *window,
XEvent *event,
MetaKeyBinding *binding)
-{
+{
const MetaScreenDirection move_direction = binding->handler->data;
const MetaXineramaScreenInfo* current;
const MetaXineramaScreenInfo* neighbour;
-
+
current = meta_screen_get_xinerama_for_window(screen, window);
neighbour = meta_screen_get_xinerama_neighbor(screen, current->number, move_direction);
@@ -2846,8 +2846,8 @@ process_workspace_switch_grab (MetaDisplay *display,
window,
event->xkey.time);
}
-
-
+
+
return TRUE; /* we already ended the grab */
}
@@ -2858,10 +2858,10 @@ process_workspace_switch_grab (MetaDisplay *display,
"Ending workspace tabbing & focusing default window; uninteresting key pressed\n");
workspace =
(MetaWorkspace *) meta_ui_tab_popup_get_selected (screen->tab_popup);
-
+
if(display->grab_op == META_GRAB_OP_KEYBOARD_WORKSPACE_SWITCHING)
meta_workspace_focus_default_window (workspace, NULL, event->xkey.time);
-
+
return FALSE;
}
@@ -3391,7 +3391,7 @@ handle_move_to_workspace (MetaDisplay *display,
handle_workspace_switch_or_move (display, screen, window, event, binding, TRUE);
return;
}
-
+
workspace = meta_screen_get_workspace_by_index (screen, which);
if (workspace)
@@ -3617,13 +3617,13 @@ handle_rename_workspace_callback(GIOChannel *ioc, GIOCondition cond, gpointer da
{
meta_topic (META_DEBUG_KEYBINDINGS, "handle_rename_workspace_callback: called.\n");
gint *workspace_index = data;
-
+
if (!already_displaying_rename_workspace)
{
meta_topic (META_DEBUG_KEYBINDINGS, "handle_rename_workspace_callback: done, already_displaying_rename_workspace=FALSE\n");
return FALSE;
}
-
+
if (cond & G_IO_HUP)
{
meta_topic (META_DEBUG_KEYBINDINGS, "handle_rename_workspace_callback: done.\n");
@@ -3631,8 +3631,8 @@ handle_rename_workspace_callback(GIOChannel *ioc, GIOCondition cond, gpointer da
already_displaying_rename_workspace = FALSE;
return FALSE;
}
-
-
+
+
if (cond & G_IO_ERR )
{
meta_warning ("handle_rename_workspace_callback: error. G_IO_ERR.\n");
@@ -3640,7 +3640,7 @@ handle_rename_workspace_callback(GIOChannel *ioc, GIOCondition cond, gpointer da
already_displaying_rename_workspace = FALSE;
return FALSE;
}
-
+
if (cond & G_IO_NVAL )
{
meta_warning ("handle_rename_workspace_callback: error. G_IO_NVAL.\n");
@@ -3648,8 +3648,8 @@ handle_rename_workspace_callback(GIOChannel *ioc, GIOCondition cond, gpointer da
already_displaying_rename_workspace = FALSE;
return FALSE;
}
-
-
+
+
meta_topic (META_DEBUG_KEYBINDINGS, "handle_rename_workspace_callback: workspace_index=%d\n", *workspace_index);
if (*workspace_index < 0 || *workspace_index > 36)
{
@@ -3658,8 +3658,8 @@ handle_rename_workspace_callback(GIOChannel *ioc, GIOCondition cond, gpointer da
already_displaying_rename_workspace = FALSE;
return FALSE;
}
-
-
+
+
if (cond & (!G_IO_IN & !G_IO_PRI))
{
meta_warning ("handle_rename_workspace_callback: unknown error\n");
@@ -3667,14 +3667,14 @@ handle_rename_workspace_callback(GIOChannel *ioc, GIOCondition cond, gpointer da
already_displaying_rename_workspace = FALSE;
return FALSE;
}
-
+
GIOStatus ret;
-
+
gchar buf[RENAME_WORKSPACE_BUFSIZE];
gchar clean_buf[RENAME_WORKSPACE_BUFSIZE];
gsize buf_len = 0;
glong clean_buf_len = 0;
-
+
memset (buf, 0x00, RENAME_WORKSPACE_BUFSIZE);
memset (clean_buf, 0x00, RENAME_WORKSPACE_BUFSIZE);
@@ -3687,7 +3687,7 @@ handle_rename_workspace_callback(GIOChannel *ioc, GIOCondition cond, gpointer da
already_displaying_rename_workspace = FALSE;
return FALSE;
}
-
+
if (!g_utf8_validate (buf, -1, NULL))
{
meta_topic (META_DEBUG_KEYBINDINGS, "handle_rename_workspace_callback: the string is not utf-8: %s\n", buf);
@@ -3704,11 +3704,11 @@ handle_rename_workspace_callback(GIOChannel *ioc, GIOCondition cond, gpointer da
already_displaying_rename_workspace = FALSE;
return FALSE;
}
-
+
g_utf8_strncpy (clean_buf, buf, clean_buf_len - 1);
meta_prefs_change_workspace_name(*workspace_index, clean_buf);
already_displaying_rename_workspace = FALSE;
-
+
return TRUE;
}
@@ -3722,23 +3722,23 @@ handle_rename_workspace(MetaDisplay *display,
gchar *window_title, *window_content;
const char *entry_text;
GPid dialog_pid;
-
+
meta_topic (META_DEBUG_KEYBINDINGS, "handle_rename_workspace: called.\n");
-
+
if (already_displaying_rename_workspace)
{
meta_topic (META_DEBUG_KEYBINDINGS,
"handle_rename_workspace: return, already_displaying_rename_workspace=TRUE.\n");
return;
}
-
+
window_title = g_strdup_printf (_("<tt>Rename Workspace</tt>"));
window_content = g_strdup_printf (_("New Workspace Name:"));
-
+
gint *workspace_index = g_malloc (sizeof (gint));
*workspace_index = meta_workspace_index (screen->active_workspace);
meta_topic (META_DEBUG_KEYBINDINGS, "handle_rename_workspace: workspace_index=%d\n", *workspace_index);
-
+
entry_text = meta_prefs_get_workspace_name(*workspace_index);
dialog_pid = meta_show_entry_dialog (window_content,
workspace_index,
@@ -3747,7 +3747,7 @@ handle_rename_workspace(MetaDisplay *display,
_("OK"), _("Cancel"),
0,
handle_rename_workspace_callback);
-
+
g_free (window_title);
g_free (window_content);
if (dialog_pid > 0)
diff --git a/src/core/prefs.c b/src/core/prefs.c
index f7df9f39..691516a5 100644
--- a/src/core/prefs.c
+++ b/src/core/prefs.c
@@ -541,8 +541,8 @@ static MetaIntPreference preferences_int[] =
KEY_GENERAL_SCHEMA,
META_PREF_ALT_TAB_MAX_COLUMNS,
&alt_tab_max_columns,
- META_MIN_ALT_TAB_MAX_COLUMNS,
- META_MAX_ALT_TAB_MAX_COLUMNS,
+ META_MIN_ALT_TAB_MAX_COLUMNS,
+ META_MAX_ALT_TAB_MAX_COLUMNS,
META_DEFAULT_ALT_TAB_MAX_COLUMNS,
},
{ NULL, NULL, 0, NULL, 0, 0, 0, },
@@ -1166,7 +1166,7 @@ gboolean
meta_prefs_is_in_skip_list (char *class)
{
GList *item;
-
+
for (item = show_desktop_skip_list; item; item = item->next)
{
if (!g_ascii_strcasecmp (class, item->data))
diff --git a/src/core/screen.c b/src/core/screen.c
index feaac951..cdf08bfd 100644
--- a/src/core/screen.c
+++ b/src/core/screen.c
@@ -1511,12 +1511,12 @@ meta_screen_tile_preview_update_timeout (gpointer data)
if (window)
{
switch (window->tile_mode)
- {
+ {
case META_TILE_MAXIMIZED:
if (!META_WINDOW_MAXIMIZED (window))
needs_preview = TRUE;
break;
-
+
case META_TILE_NONE:
needs_preview = FALSE;
break;
diff --git a/src/core/util.c b/src/core/util.c
index 6ebaf3c9..9e15bb26 100644
--- a/src/core/util.c
+++ b/src/core/util.c
@@ -640,13 +640,13 @@ meta_show_entry_dialog(const char *message,
meta_topic (META_DEBUG_KEYBINDINGS,
"meta_show_entry_dialog: called. active_workspace_id=%d message=%s entry_text=%s\n",
*active_workspace_id, message, entry_text);
-
+
GError *error = NULL;
int i = 0;
GPid child_pid;
gint stdout_fd;
const char **argvl = g_malloc (sizeof (char *) * (17));
-
+
argvl[i++] = "zenity";
argvl[i++] = "--entry";
argvl[i++] = "--display";
@@ -658,27 +658,27 @@ meta_show_entry_dialog(const char *message,
argvl[i++] = _ ("Marco");
argvl[i++] = "--text";
argvl[i++] = message;
-
+
if (entry_text)
{
argvl[i++] = "--entry-text";
argvl[i++] = entry_text;
}
-
+
if (ok_text)
{
argvl[i++] = "--ok-label";
argvl[i++] = ok_text;
}
-
+
if (cancel_text)
{
argvl[i++] = "--cancel-label";
argvl[i++] = cancel_text;
}
argvl[i] = NULL;
-
-
+
+
unsetenv ("WINDOWID"); /* start in current workspace */
g_spawn_async_with_pipes (
"/",
@@ -693,9 +693,9 @@ meta_show_entry_dialog(const char *message,
NULL,
&error
);
-
+
g_free (argvl);
-
+
if (error)
{
meta_warning ("%s\n", error->message);
@@ -711,7 +711,7 @@ meta_show_entry_dialog(const char *message,
g_io_add_watch(ioc, G_IO_IN | G_IO_PRI | G_IO_ERR | G_IO_HUP | G_IO_NVAL, stdio_func_cb, active_workspace_id);
g_io_channel_unref(ioc);
}
-
+
return child_pid;
}
/* eof util.c */
diff --git a/src/core/window.c b/src/core/window.c
index bc04b644..b86e6232 100644
--- a/src/core/window.c
+++ b/src/core/window.c
@@ -2743,7 +2743,7 @@ meta_window_tile (MetaWindow *window)
else
meta_window_save_rect(window);
-
+
window->tiled = TRUE;
/* move_resize with new tiling constraints
*/
@@ -2892,7 +2892,7 @@ meta_window_move_to_monitor(MetaWindow *window,
const MetaXineramaScreenInfo *to_monitor)
{
MetaRectangle target_rect;
-
+
if(META_WINDOW_TILED (window))
{
window->tile_monitor_number = to_monitor->number;
@@ -2911,11 +2911,11 @@ meta_window_move_to_monitor(MetaWindow *window,
/* Normally, just transform the window itself */
meta_window_get_client_root_coords(window, &target_rect);
-
+
meta_window_transform_to_monitor(&target_rect,
&from_monitor->rect,
&to_monitor->rect);
-
+
meta_window_move_resize(window, TRUE,
target_rect.x,
target_rect.y,
@@ -2929,7 +2929,7 @@ static void meta_window_transform_to_monitor(MetaRectangle *target_rect,
{
double horizontal_ratio;
double vertical_ratio;
-
+
horizontal_ratio = (double)to_monitor->width / from_monitor->width;
vertical_ratio = (double)to_monitor->height / from_monitor->height;
@@ -4997,8 +4997,8 @@ meta_window_move_resize_request (MetaWindow *window,
y,
width,
height);
-
- }
+
+ }
/* window->user_rect exists to allow "snapping-back" the window if a
* new strut is set (causing the window to move) and then the strut
@@ -7454,17 +7454,17 @@ update_move (MetaWindow *window,
meta_window_get_client_root_coords (window, &old);
/* Don't allow movement in the maximized directions or while tiled */
-
+
if (window->maximized_horizontally || META_WINDOW_TILED (window))
{
new_x = old.x;
}
-
+
if (window->maximized_vertically || META_WINDOW_CORNER_TILED(window))
{
new_y = old.y;
}
-
+
/* Do any edge resistance/snapping */
meta_window_edge_resistance_for_move (window,
@@ -7500,39 +7500,39 @@ static MetaTileMode calculate_tiling_mode(int x,
const MetaXineramaScreenInfo *monitor,
MetaRectangle work_area,
int shake_threshold)
-{
+{
if (meta_window_can_tile (window) &&
x >= monitor->rect.x
&& x < (work_area.x + shake_threshold))
{
if(y >= monitor->rect.y && y < work_area.y + shake_threshold)
- return META_TILE_TOP_LEFT;
+ return META_TILE_TOP_LEFT;
else if(y < monitor->rect.y + monitor->rect.height
&& y > work_area.y + work_area.height - shake_threshold)
- return META_TILE_BOTTOM_LEFT;
+ return META_TILE_BOTTOM_LEFT;
else
- return META_TILE_LEFT;
+ return META_TILE_LEFT;
}
-
+
else if (meta_window_can_tile (window) &&
x >= work_area.x + work_area.width - shake_threshold &&
x < (monitor->rect.x + monitor->rect.width))
{
if(y >= monitor->rect.y && y < work_area.y + shake_threshold)
- return META_TILE_TOP_RIGHT;
+ return META_TILE_TOP_RIGHT;
else if(y < monitor->rect.y + monitor->rect.height
&& y > work_area.y + work_area.height - shake_threshold)
- return META_TILE_BOTTOM_RIGHT;
+ return META_TILE_BOTTOM_RIGHT;
else
- return META_TILE_RIGHT;
+ return META_TILE_RIGHT;
}
else if (meta_window_can_tile_maximized (window) &&
y >= monitor->rect.y && y <= work_area.y &&
meta_prefs_get_allow_top_tiling ())
- return META_TILE_MAXIMIZED;
+ return META_TILE_MAXIMIZED;
else
return META_TILE_NONE;
-
+
}
diff --git a/src/core/workspace.c b/src/core/workspace.c
index 04ba575b..e2960a41 100644
--- a/src/core/workspace.c
+++ b/src/core/workspace.c
@@ -388,7 +388,7 @@ meta_workspace_activate_with_focus (MetaWorkspace *workspace,
/* Note that old can be NULL; e.g. when starting up */
old = workspace->screen->active_workspace;
-
+
/* Save old workspace, to be able to switch back. */
workspace->screen->prev_workspace = old;
diff --git a/src/core/workspace.h b/src/core/workspace.h
index b8ea3c97..3af1997d 100644
--- a/src/core/workspace.h
+++ b/src/core/workspace.h
@@ -52,7 +52,7 @@ struct _MetaWorkspace
MetaScreen *screen;
GList *windows;
-
+
/* The "MRU list", or "most recently used" list, is a list of
* MetaWindows ordered based on the time the the user interacted
* with the window most recently.
diff --git a/src/core/xprops.c b/src/core/xprops.c
index f1b21f00..bd374195 100644
--- a/src/core/xprops.c
+++ b/src/core/xprops.c
@@ -665,7 +665,7 @@ text_property_to_utf8 (Display *xdisplay,
XFreeStringList (local_list);
return NULL;
}
-
+
if (g_get_charset (&charset))
ret = g_strdup (local_list[0]);
else
diff --git a/src/ui/tabpopup.c b/src/ui/tabpopup.c
index fe7107dd..e5cd8736 100644
--- a/src/ui/tabpopup.c
+++ b/src/ui/tabpopup.c
@@ -603,12 +603,12 @@ static void
display_widget (MetaTabPopup *popup,
GtkWidget *w)
{
- if (w != NULL)
+ if (w != NULL)
{
GList *c = popup->entries;
while (c != NULL && ((TabEntry*)c->data)->widget != w)
c = c->next;
- if (c != NULL)
+ if (c != NULL)
{
popup->current = c;
TabEntry *te = c->data;
@@ -623,7 +623,7 @@ meta_ui_tab_popup_down (MetaTabPopup *popup)
if (popup->current != NULL)
{
TabEntry *te = popup->current->data;
- GtkWidget* w = gtk_grid_get_child_at (GTK_GRID(popup->grid),
+ GtkWidget* w = gtk_grid_get_child_at (GTK_GRID(popup->grid),
te->grid_left,
te->grid_top + 1);
display_widget (popup, w);
@@ -636,7 +636,7 @@ meta_ui_tab_popup_up (MetaTabPopup *popup)
if (popup->current != NULL)
{
TabEntry *te = popup->current->data;
- GtkWidget* w = gtk_grid_get_child_at (GTK_GRID(popup->grid),
+ GtkWidget* w = gtk_grid_get_child_at (GTK_GRID(popup->grid),
te->grid_left,
te->grid_top - 1);
display_widget (popup, w);
diff --git a/src/ui/theme.c b/src/ui/theme.c
index 4c3c20b1..711fa0cd 100644
--- a/src/ui/theme.c
+++ b/src/ui/theme.c
@@ -1376,7 +1376,7 @@ meta_color_spec_new_from_string (const char *str,
MetaColorSpec *spec;
spec = NULL;
-
+
if (strncmp (str, "gtk:custom", 10) == 0)
{
const char *color_name_start, *fallback_str_start, *end;