Catch the "draw" event on the GtkFixed widget and redraw the html
area since it's just been erased by the widget default draw handler git-svn-id: svn://10.0.0.236/trunk@13415 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -68,6 +68,11 @@ html_view_size_allocate(GtkWidget *widget,
|
||||
GtkAllocation *alloc,
|
||||
void *data);
|
||||
|
||||
static gint
|
||||
html_view_draw(GtkWidget *widget,
|
||||
GdkRectangle *area,
|
||||
void *data);
|
||||
|
||||
static gint
|
||||
html_view_realize_handler(GtkWidget *widget,
|
||||
void *data)
|
||||
@@ -105,9 +110,33 @@ html_view_realize_handler(GtkWidget *widget,
|
||||
printf("connecting size_realloc to context %x\n", context);
|
||||
gtk_signal_connect(GTK_OBJECT(MOZ_VIEW(view)->subview_parent), "size_allocate",
|
||||
GTK_SIGNAL_FUNC(html_view_size_allocate), context);
|
||||
gtk_signal_connect(GTK_OBJECT(MOZ_VIEW(view)->subview_parent), "draw",
|
||||
GTK_SIGNAL_FUNC(html_view_draw), context);
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
static gint
|
||||
html_view_draw(GtkWidget *widget,
|
||||
GdkRectangle *area,
|
||||
void *data)
|
||||
{
|
||||
MWContext *context = (MWContext *)data;
|
||||
MozHTMLView *view = NULL;
|
||||
|
||||
if (!data)
|
||||
return FALSE;
|
||||
view = find_html_view(context);
|
||||
if (!view)
|
||||
return FALSE;
|
||||
moz_html_view_refresh_rect(view,
|
||||
area->x,
|
||||
area->y,
|
||||
area->width,
|
||||
area->height);
|
||||
/* let any other draws work too */
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
static gint
|
||||
html_view_handle_pointer_motion_part2(MWContext *context, LO_Element *element, int32 event,
|
||||
void *closure, ETEventStatus status)
|
||||
|
||||
Reference in New Issue
Block a user