mirror of
https://github.com/brl/mutter.git
synced 2024-11-25 17:40:40 -05:00
call meta_image_window_new in multihead-safe way
2002-10-18 Havoc Pennington <hp@redhat.com> * src/effects.c (meta_effects_draw_box_animation): call meta_image_window_new in multihead-safe way * src/ui.c (meta_image_window_new): multihead safety
This commit is contained in:
parent
915c2db3b9
commit
70b6a57003
@ -1,3 +1,10 @@
|
|||||||
|
2002-10-18 Havoc Pennington <hp@redhat.com>
|
||||||
|
|
||||||
|
* src/effects.c (meta_effects_draw_box_animation): call
|
||||||
|
meta_image_window_new in multihead-safe way
|
||||||
|
|
||||||
|
* src/ui.c (meta_image_window_new): multihead safety
|
||||||
|
|
||||||
2002-10-18 Havoc Pennington <hp@redhat.com>
|
2002-10-18 Havoc Pennington <hp@redhat.com>
|
||||||
|
|
||||||
* src/window.c (meta_window_refresh_resize_popup): only create the
|
* src/window.c (meta_window_refresh_resize_popup): only create the
|
||||||
|
@ -333,7 +333,9 @@ meta_effects_draw_box_animation (MetaScreen *screen,
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
context->image_window = meta_image_window_new (initial_rect->width,
|
context->image_window = meta_image_window_new (screen->display->xdisplay,
|
||||||
|
screen->number,
|
||||||
|
initial_rect->width,
|
||||||
initial_rect->height);
|
initial_rect->height);
|
||||||
context->orig_pixbuf = pix;
|
context->orig_pixbuf = pix;
|
||||||
meta_image_window_set (context->image_window,
|
meta_image_window_set (context->image_window,
|
||||||
|
10
src/ui.c
10
src/ui.c
@ -303,13 +303,21 @@ struct _MetaImageWindow
|
|||||||
};
|
};
|
||||||
|
|
||||||
MetaImageWindow*
|
MetaImageWindow*
|
||||||
meta_image_window_new (int max_width,
|
meta_image_window_new (Display *xdisplay,
|
||||||
|
int screen_number,
|
||||||
|
int max_width,
|
||||||
int max_height)
|
int max_height)
|
||||||
{
|
{
|
||||||
MetaImageWindow *iw;
|
MetaImageWindow *iw;
|
||||||
|
GdkDisplay *gdisplay;
|
||||||
|
GdkScreen *gscreen;
|
||||||
|
|
||||||
|
gdisplay = gdk_x11_lookup_xdisplay (xdisplay);
|
||||||
|
gscreen = gdk_display_get_screen (gdisplay, screen_number);
|
||||||
|
|
||||||
iw = g_new (MetaImageWindow, 1);
|
iw = g_new (MetaImageWindow, 1);
|
||||||
iw->window = gtk_window_new (GTK_WINDOW_POPUP);
|
iw->window = gtk_window_new (GTK_WINDOW_POPUP);
|
||||||
|
gtk_window_set_screen (GTK_WINDOW (iw->window), gscreen);
|
||||||
gtk_widget_realize (iw->window);
|
gtk_widget_realize (iw->window);
|
||||||
iw->pixmap = gdk_pixmap_new (iw->window->window,
|
iw->pixmap = gdk_pixmap_new (iw->window->window,
|
||||||
max_width, max_height,
|
max_width, max_height,
|
||||||
|
4
src/ui.h
4
src/ui.h
@ -104,7 +104,9 @@ void meta_ui_window_menu_popup (MetaWindowMenu *menu,
|
|||||||
void meta_ui_window_menu_free (MetaWindowMenu *menu);
|
void meta_ui_window_menu_free (MetaWindowMenu *menu);
|
||||||
|
|
||||||
|
|
||||||
MetaImageWindow* meta_image_window_new (int max_width,
|
MetaImageWindow* meta_image_window_new (Display *xdisplay,
|
||||||
|
int screen_number,
|
||||||
|
int max_width,
|
||||||
int max_height);
|
int max_height);
|
||||||
void meta_image_window_free (MetaImageWindow *iw);
|
void meta_image_window_free (MetaImageWindow *iw);
|
||||||
void meta_image_window_set_showing (MetaImageWindow *iw,
|
void meta_image_window_set_showing (MetaImageWindow *iw,
|
||||||
|
Loading…
Reference in New Issue
Block a user