Compare commits

...

10 Commits

Author SHA1 Message Date
75af6fc40c Bump version to 3.0.2.1
Update NEWS
2011-05-25 15:42:10 -04:00
bbfcde1caa Make session saving work a bit better
Previously, the restart command hardcoded "mutter" as the binary name.
This commit changes it to use g_get_prgname() which has a better chance
of being correct (and it does fix session saving for gnome-shell).

Now that mutter is a library, it might be more correct (but also
much higher overhead) to add api for setting these things from
the outside.

https://bugzilla.gnome.org/show_bug.cgi?id=648828
2011-05-25 15:39:23 -04:00
31e6cdf345 Bump version to 3.0.2
Update NEWS
2011-05-25 14:40:58 -04:00
c8aaa5e33e Fix crash in meta_display_get_above_tab_keycode
https://bugzilla.gnome.org/show_bug.cgi?id=647777
2011-05-25 14:22:57 -04:00
65aa3e3927 window: don't allow side-by-side tiling of non-maximizable windows
If a window is not maximizable, then that probably means it looks dumb
at very large sizes. Even if its hints would allow you to manually
resize it to a large size, don't allow automatically tiling it to half
the screen.

https://bugzilla.gnome.org/show_bug.cgi?id=647901
2011-05-23 23:50:14 -04:00
b192771b93 Filter mirrored monitors from the monitors list
For the purposes of window placement or arranging window manager or
plugin controls, screens that are just mirrors of other screens should
be ignored, so filter them out of the monitors list.

https://bugzilla.gnome.org/show_bug.cgi?id=649299
2011-05-23 23:49:58 -04:00
c1977b6532 region-utils.c: Squash a memory leak
"chunk" was an allocated but unused variable.

https://bugzilla.gnome.org/show_bug.cgi?id=649504
2011-05-23 23:49:33 -04:00
50d1b53267 theme.c: Squash memory leak
When converting a token to a different type, we need to free its
string.

https://bugzilla.gnome.org/show_bug.cgi?id=649500
2011-05-23 23:49:10 -04:00
cbec96a62f Make _NET_WM_WINDOW_OPACITY orthogonal to window actor opacity
Using MetaWindowActor.opacity for _NET_WM_WINDOW_OPACITY makes it
difficult to implement effects like fading a window in on map.
Instead, set the opacity on the MetaShadedTexture child and use
it when drawing the shadow.

Since the check MetaWindowGroup does on meta_actor_get_paint_opacity()
no longer covers this, we need to handle the opacity in
meta_window_actor_get_obscured_region() explicitly.

https://bugzilla.gnome.org/show_bug.cgi?id=648613
2011-05-23 23:48:48 -04:00
a28a5749db Added UG translation 2011-05-02 18:48:56 +02:00
10 changed files with 403 additions and 207 deletions

32
NEWS
View File

@ -1,3 +1,35 @@
3.0.2.1
=======
* When saving the session, use the "program name" rather than
harcoding mutter, fixing session saving for gnome-shell [Matthias]
https://bugzilla.gnome.org/show_bug.cgi?id=648828
Contributors:
Matthias Clasen
3.0.2
=====
* Fix a crash when running without XKB support [Adam]
https://bugzilla.gnome.org/show_bug.cgi?id=647777
* Fix smallish memory leaks [Colin]
https://bugzilla.gnome.org/show_bug.cgi?id=649500
https://bugzilla.gnome.org/show_bug.cgi?id=649504
* Ignore mirrored monitors when listing monitors, fixing
drag-and-drop problems in GNOME Shell [Owen]
https://bugzilla.gnome.org/show_bug.cgi?id=649299
* Don't allow side-by-side tiling of non-maximizable windows
like dialogs and utility windows [Dan]
* Fix interaction of _NET_WM_WINDOW_OPACITY with window effects,
making it work again with GNOME Shell
https://bugzilla.gnome.org/show_bug.cgi?id=648613
Contributors:
Adam Jackson, Colin Walters, Dan Winship
Translations:
Abduxukur Abdurixit [ug]
3.0.1
=====

View File

@ -2,7 +2,7 @@ AC_PREREQ(2.50)
m4_define([mutter_major_version], [3])
m4_define([mutter_minor_version], [0])
m4_define([mutter_micro_version], [1])
m4_define([mutter_micro_version], [2.1])
m4_define([mutter_version],
[mutter_major_version.mutter_minor_version.mutter_micro_version])

475
po/ug.po

File diff suppressed because it is too large Load Diff

View File

@ -411,8 +411,6 @@ meta_window_actor_constructed (GObject *object)
if (format && format->type == PictTypeDirect && format->direct.alphaMask)
priv->argb32 = TRUE;
meta_window_actor_update_opacity (self);
if (!priv->actor)
{
priv->actor = meta_shaped_texture_new ();
@ -442,7 +440,7 @@ meta_window_actor_constructed (GObject *object)
clutter_actor_raise_top (priv->actor);
}
meta_window_actor_update_opacity (self);
meta_window_actor_update_shape (self, priv->shaped);
}
@ -725,7 +723,7 @@ meta_window_actor_paint (ClutterActor *actor)
params.y_offset + shape_bounds.y,
shape_bounds.width,
shape_bounds.height,
(clutter_actor_get_paint_opacity (actor) * params.opacity) / 255,
(clutter_actor_get_paint_opacity (actor) * params.opacity * priv->opacity) / (255 * 255),
priv->shadow_clip);
}
@ -1690,7 +1688,7 @@ meta_window_actor_get_obscured_region (MetaWindowActor *self)
{
MetaWindowActorPrivate *priv = self->priv;
if (!priv->argb32 && priv->back_pixmap)
if (!priv->argb32 && priv->opacity == 0xff && priv->back_pixmap)
{
if (priv->shaped)
return priv->shape_region;
@ -2147,5 +2145,5 @@ meta_window_actor_update_opacity (MetaWindowActor *self)
opacity = 255;
self->priv->opacity = opacity;
clutter_actor_set_opacity (CLUTTER_ACTOR (self), opacity);
clutter_actor_set_opacity (self->priv->actor, opacity);
}

View File

@ -248,7 +248,6 @@ expand_region_inverse (cairo_region_t *region,
MetaRegionBuilder builder;
MetaRegionIterator iter;
cairo_rectangle_int_t extents;
cairo_region_t *chunk;
int last_x;
@ -268,16 +267,11 @@ expand_region_inverse (cairo_region_t *region,
extents.x, extents.y + extents.height, extents.width, 1,
x_amount, y_amount, flip);
chunk = NULL;
last_x = extents.x;
for (meta_region_iterator_init (&iter, region);
!meta_region_iterator_at_end (&iter);
meta_region_iterator_next (&iter))
{
if (chunk == NULL)
chunk = cairo_region_create ();
if (iter.rectangle.x > last_x)
add_expanded_rect (&builder,
last_x, iter.rectangle.y,

View File

@ -76,6 +76,8 @@ compute_above_tab_keycode (Display *xdisplay)
keyboard = XkbGetKeyboard (xdisplay,
XkbGBN_ClientSymbolsMask | XkbGBN_KeyNamesMask | XkbGBN_GeometryMask,
XkbUseCoreKbd);
if (!keyboard)
return best_keycode;
geometry = keyboard->geom;

View File

@ -349,6 +349,43 @@ set_wm_icon_size_hint (MetaScreen *screen)
#undef N_VALS
}
/* The list of monitors reported by the windowing system might include
* mirrored monitors with identical bounds. Since mirrored monitors
* shouldn't be treated as separate monitors for most purposes, we
* filter them out here. (We ignore the possibility of partially
* overlapping monitors because they are rare and it's hard to come
* up with any sensible interpretation.)
*/
static void
filter_mirrored_monitors (MetaScreen *screen)
{
int i, j;
/* Currently always true and simplifies things */
g_assert (screen->primary_monitor_index == 0);
for (i = 1; i < screen->n_monitor_infos; i++)
{
/* In case we've filtered previous monitors */
screen->monitor_infos[i].number = i;
for (j = 0; j < i; j++)
{
if (meta_rectangle_equal (&screen->monitor_infos[i].rect,
&screen->monitor_infos[j].rect))
{
memmove (&screen->monitor_infos[i],
&screen->monitor_infos[i + 1],
(screen->n_monitor_infos - i - 1) * sizeof (MetaMonitorInfo));
screen->n_monitor_infos--;
i--;
continue;
}
}
}
}
static void
reload_monitor_infos (MetaScreen *screen)
{
@ -538,6 +575,8 @@ reload_monitor_infos (MetaScreen *screen)
screen->monitor_infos[0].rect = screen->rect;
}
filter_mirrored_monitors (screen);
g_assert (screen->n_monitor_infos > 0);
g_assert (screen->monitor_infos != NULL);
}

View File

@ -308,13 +308,16 @@ meta_session_init (const char *previous_client_id,
*/
char hint = SmRestartIfRunning;
char priority = 20; /* low to run before other apps */
const char *prgname;
prgname = g_get_prgname ();
prop1.name = SmProgram;
prop1.type = SmARRAY8;
prop1.num_vals = 1;
prop1.vals = &prop1val;
prop1val.value = "mutter";
prop1val.length = strlen ("mutter");
prop1val.value = (char *)prgname;
prop1val.length = strlen (prgname);
/* twm sets getuid() for this, but the SM spec plainly
* says pw_name, twm is on crack
@ -573,6 +576,9 @@ set_clone_restart_commands (void)
char *discardv[10];
int i;
SmProp prop1, prop2, prop3, *props[3];
const char *prgname;
prgname = g_get_prgname ();
/* Restart (use same client ID) */
@ -582,7 +588,7 @@ set_clone_restart_commands (void)
g_return_if_fail (client_id);
i = 0;
restartv[i] = "mutter";
restartv[i] = (char *)prgname;
++i;
restartv[i] = "--sm-client-id";
++i;
@ -603,7 +609,7 @@ set_clone_restart_commands (void)
/* Clone (no client ID) */
i = 0;
clonev[i] = "mutter";
clonev[i] = (char *)prgname;
++i;
clonev[i] = NULL;

View File

@ -3450,13 +3450,25 @@ meta_window_tile (MetaWindow *window)
}
}
static gboolean
meta_window_can_tile_maximized (MetaWindow *window)
{
if (!META_WINDOW_ALLOWS_RESIZE (window))
return FALSE;
if (!window->has_maximize_func)
return FALSE;
return TRUE;
}
static gboolean
meta_window_can_tile_side_by_side (MetaWindow *window)
{
const MetaMonitorInfo *monitor;
MetaRectangle tile_area;
if (!META_WINDOW_ALLOWS_RESIZE (window))
if (!meta_window_can_tile_maximized (window))
return FALSE;
monitor = meta_screen_get_current_monitor (window->screen);
@ -3482,18 +3494,6 @@ meta_window_can_tile_side_by_side (MetaWindow *window)
tile_area.height >= window->size_hints.min_height;
}
static gboolean
meta_window_can_tile_maximized (MetaWindow *window)
{
if (!META_WINDOW_ALLOWS_RESIZE (window))
return FALSE;
if (!window->has_maximize_func)
return FALSE;
return TRUE;
}
static void
unmaximize_window_before_freeing (MetaWindow *window)
{

View File

@ -2639,11 +2639,13 @@ meta_theme_replace_constants (MetaTheme *theme,
{
if (meta_theme_lookup_int_constant (theme, t->d.v.name, &ival))
{
g_free (t->d.v.name);
t->type = POS_TOKEN_INT;
t->d.i.val = ival;
}
else if (meta_theme_lookup_float_constant (theme, t->d.v.name, &dval))
{
g_free (t->d.v.name);
t->type = POS_TOKEN_DOUBLE;
t->d.d.val = dval;
}