diff options
| author | Joakim Verona | 2011-07-20 18:46:43 +0200 |
|---|---|---|
| committer | Joakim Verona | 2011-07-20 18:46:43 +0200 |
| commit | 9c4f13500786571d004d4530e2ffd84c5457d61c (patch) | |
| tree | 7c978208d3ba8ac0dc9fd22d1d3c39a69e74f28d /src | |
| parent | 7cdff38f2f77f7c1c8ec2bfb3b268ccdce6ff218 (diff) | |
| download | emacs-9c4f13500786571d004d4530e2ffd84c5457d61c.tar.gz emacs-9c4f13500786571d004d4530e2ffd84c5457d61c.zip | |
cleanups
Diffstat (limited to 'src')
| -rw-r--r-- | src/Makefile.in | 2 | ||||
| -rw-r--r-- | src/dispextern.h | 1 | ||||
| -rw-r--r-- | src/dispnew.c | 3 | ||||
| -rw-r--r-- | src/emacsgtkfixed.c | 2 | ||||
| -rw-r--r-- | src/frame.h | 4 | ||||
| -rw-r--r-- | src/gtkutil.c | 4 | ||||
| -rw-r--r-- | src/lisp.h | 2 | ||||
| -rw-r--r-- | src/xdisp.c | 6 | ||||
| -rw-r--r-- | src/xwidget-attic.c | 3 | ||||
| -rw-r--r-- | src/xwidget.c | 8 |
10 files changed, 11 insertions, 24 deletions
diff --git a/src/Makefile.in b/src/Makefile.in index 4821cb942a4..2dfef64a762 100644 --- a/src/Makefile.in +++ b/src/Makefile.in | |||
| @@ -343,7 +343,7 @@ base_obj = dispnew.o frame.o scroll.o xdisp.o menu.o $(XMENU_OBJ) window.o \ | |||
| 343 | syntax.o $(UNEXEC_OBJ) bytecode.o \ | 343 | syntax.o $(UNEXEC_OBJ) bytecode.o \ |
| 344 | process.o gnutls.o callproc.o \ | 344 | process.o gnutls.o callproc.o \ |
| 345 | region-cache.o sound.o atimer.o \ | 345 | region-cache.o sound.o atimer.o \ |
| 346 | doprnt.o intervals.o textprop.o composite.o xml.o \ | 346 | doprnt.o intervals.o textprop.o composite.o xml.o \ |
| 347 | xwidget.o \ | 347 | xwidget.o \ |
| 348 | $(MSDOS_OBJ) $(MSDOS_X_OBJ) $(NS_OBJ) $(CYGWIN_OBJ) $(FONT_OBJ) | 348 | $(MSDOS_OBJ) $(MSDOS_X_OBJ) $(NS_OBJ) $(CYGWIN_OBJ) $(FONT_OBJ) |
| 349 | obj = $(base_obj) $(NS_OBJC_OBJ) | 349 | obj = $(base_obj) $(NS_OBJC_OBJ) |
diff --git a/src/dispextern.h b/src/dispextern.h index b8ef4656220..442839c3cf9 100644 --- a/src/dispextern.h +++ b/src/dispextern.h | |||
| @@ -437,7 +437,6 @@ struct glyph | |||
| 437 | int img_id; | 437 | int img_id; |
| 438 | 438 | ||
| 439 | struct xwidget* xwidget; | 439 | struct xwidget* xwidget; |
| 440 | |||
| 441 | /* Sub-structure for type == STRETCH_GLYPH. */ | 440 | /* Sub-structure for type == STRETCH_GLYPH. */ |
| 442 | struct | 441 | struct |
| 443 | { | 442 | { |
diff --git a/src/dispnew.c b/src/dispnew.c index 7b20979e45d..e1311634e2c 100644 --- a/src/dispnew.c +++ b/src/dispnew.c | |||
| @@ -313,9 +313,8 @@ add_window_display_history (struct window *w, const char *msg, int paused_p) | |||
| 313 | ? SSDATA (BVAR (XBUFFER (w->buffer), name)) | 313 | ? SSDATA (BVAR (XBUFFER (w->buffer), name)) |
| 314 | : "???"), | 314 | : "???"), |
| 315 | paused_p ? " ***paused***" : ""); | 315 | paused_p ? " ***paused***" : ""); |
| 316 | |||
| 317 | strcat (buf, msg); | 316 | strcat (buf, msg); |
| 318 | } | 317 | |
| 319 | 318 | ||
| 320 | 319 | ||
| 321 | /* Add to the redisplay history that frame F has been displayed. | 320 | /* Add to the redisplay history that frame F has been displayed. |
diff --git a/src/emacsgtkfixed.c b/src/emacsgtkfixed.c index 5a0e57d0146..637903d85b4 100644 --- a/src/emacsgtkfixed.c +++ b/src/emacsgtkfixed.c | |||
| @@ -74,7 +74,7 @@ static void emacs_fixed_gtk_widget_size_allocate (GtkWidget *widget, | |||
| 74 | parent_class = g_type_class_peek_parent (klass); | 74 | parent_class = g_type_class_peek_parent (klass); |
| 75 | parent_class->size_allocate (widget, allocation); | 75 | parent_class->size_allocate (widget, allocation); |
| 76 | 76 | ||
| 77 | 77 | ||
| 78 | //then modify allocations | 78 | //then modify allocations |
| 79 | gtk_container_foreach (widget, | 79 | gtk_container_foreach (widget, |
| 80 | aloc_callback, | 80 | aloc_callback, |
diff --git a/src/frame.h b/src/frame.h index 4b4788b9e74..8dccfb8540a 100644 --- a/src/frame.h +++ b/src/frame.h | |||
| @@ -492,10 +492,6 @@ struct frame | |||
| 492 | /* All display backends seem to need these two pixel values. */ | 492 | /* All display backends seem to need these two pixel values. */ |
| 493 | unsigned long background_pixel; | 493 | unsigned long background_pixel; |
| 494 | unsigned long foreground_pixel; | 494 | unsigned long foreground_pixel; |
| 495 | |||
| 496 | /* xwidgets need the gtk container to place gtk widgets*/ | ||
| 497 | //GtkWidget *gwfixed; | ||
| 498 | void *gwfixed;//JAVE TODO i dont feel like fixing all compilation errors right now | ||
| 499 | }; | 495 | }; |
| 500 | 496 | ||
| 501 | #define FRAME_KBOARD(f) ((f)->terminal->kboard) | 497 | #define FRAME_KBOARD(f) ((f)->terminal->kboard) |
diff --git a/src/gtkutil.c b/src/gtkutil.c index c4b5feb9f25..35b366222de 100644 --- a/src/gtkutil.c +++ b/src/gtkutil.c | |||
| @@ -1100,9 +1100,9 @@ xg_create_frame_widgets (FRAME_PTR f) | |||
| 1100 | whbox = gtk_hbox_new (FALSE, 0); | 1100 | whbox = gtk_hbox_new (FALSE, 0); |
| 1101 | 1101 | ||
| 1102 | #ifdef HAVE_GTK3 | 1102 | #ifdef HAVE_GTK3 |
| 1103 | f->gwfixed = wfixed = emacs_fixed_new (f); | 1103 | wfixed = emacs_fixed_new (f); |
| 1104 | #else | 1104 | #else |
| 1105 | f->gwfixed = wfixed = gtk_fixed_new (); | 1105 | wfixed = gtk_fixed_new (); |
| 1106 | #endif | 1106 | #endif |
| 1107 | 1107 | ||
| 1108 | if (! wtop || ! wvbox || ! whbox || ! wfixed) | 1108 | if (! wtop || ! wvbox || ! whbox || ! wfixed) |
diff --git a/src/lisp.h b/src/lisp.h index 30afc6e484b..623dfabec99 100644 --- a/src/lisp.h +++ b/src/lisp.h | |||
| @@ -389,7 +389,7 @@ enum pvec_type | |||
| 389 | PVEC_FONT = 0x200000, | 389 | PVEC_FONT = 0x200000, |
| 390 | PVEC_OTHER = 0x400000, | 390 | PVEC_OTHER = 0x400000, |
| 391 | PVEC_XWIDGET = 0x800000, | 391 | PVEC_XWIDGET = 0x800000, |
| 392 | PVEC_XWIDGET_VIEW = 0x1000000, | 392 | PVEC_XWIDGET_VIEW = 0x1000000, |
| 393 | PVEC_TYPE_MASK = 0x3fffe00 | 393 | PVEC_TYPE_MASK = 0x3fffe00 |
| 394 | 394 | ||
| 395 | #if 0 /* This is used to make the value of PSEUDOVECTOR_FLAG available to | 395 | #if 0 /* This is used to make the value of PSEUDOVECTOR_FLAG available to |
diff --git a/src/xdisp.c b/src/xdisp.c index 816c7d36ce3..ecb7007e1f3 100644 --- a/src/xdisp.c +++ b/src/xdisp.c | |||
| @@ -15483,12 +15483,6 @@ try_window_reusing_current_matrix (struct window *w) | |||
| 15483 | struct glyph_row *start_row; | 15483 | struct glyph_row *start_row; |
| 15484 | int start_vpos, min_y, max_y; | 15484 | int start_vpos, min_y, max_y; |
| 15485 | 15485 | ||
| 15486 | #if HAVE_XWIDGETS_hhh | ||
| 15487 | return 0; | ||
| 15488 | //xwidgets doesnt like blit scrolling and stuff, try this for now | ||
| 15489 | //should be optimized, perhaps by just inhibiting optimizations of windows containing xwidgets. | ||
| 15490 | #endif | ||
| 15491 | |||
| 15492 | #if GLYPH_DEBUG | 15486 | #if GLYPH_DEBUG |
| 15493 | if (inhibit_try_window_reusing) | 15487 | if (inhibit_try_window_reusing) |
| 15494 | return 0; | 15488 | return 0; |
diff --git a/src/xwidget-attic.c b/src/xwidget-attic.c index b80b57c8e07..5bbbddc2d57 100644 --- a/src/xwidget-attic.c +++ b/src/xwidget-attic.c | |||
| @@ -44,8 +44,7 @@ xwidget_composite_draw_phantom(struct xwidget* xw, | |||
| 44 | /* get our child (in this case, the event box) */ | 44 | /* get our child (in this case, the event box) */ |
| 45 | child = xw->widget; //gtk_bin_get_child (GTK_BIN (widget)); | 45 | child = xw->widget; //gtk_bin_get_child (GTK_BIN (widget)); |
| 46 | /* create a cairo context to draw to the emacs window */ | 46 | /* create a cairo context to draw to the emacs window */ |
| 47 | // cr = gdk_cairo_create (gtk_widget_get_window (f->gwfixed));//GTK_WIDGET(xw->emacswindow));//xw->widgetwindow));//widget->window); | 47 | cr = gdk_cairo_create (gtk_widget_get_window (FRAME_GTK_WIDGET (s->f)));//GTK_WIDGET(xw->emacswindow));//));//widget->window); |
| 48 | cr = gdk_cairo_create (gtk_widget_get_window (f->gwfixed));//GTK_WIDGET(xw->emacswindow));//));//widget->window); | ||
| 49 | /* the source data is the (composited) xwidget */ | 48 | /* the source data is the (composited) xwidget */ |
| 50 | //cairo_move_to(cr, xw->x, xw->y); | 49 | //cairo_move_to(cr, xw->x, xw->y); |
| 51 | 50 | ||
diff --git a/src/xwidget.c b/src/xwidget.c index c75f9bbd83e..bd007aad005 100644 --- a/src/xwidget.c +++ b/src/xwidget.c | |||
| @@ -447,7 +447,7 @@ xwidget_init_view ( | |||
| 447 | } else if (EQ(xww->type, Qcairo)) { | 447 | } else if (EQ(xww->type, Qcairo)) { |
| 448 | //Cairo view | 448 | //Cairo view |
| 449 | //uhm cairo is differentish in gtk 3. | 449 | //uhm cairo is differentish in gtk 3. |
| 450 | //gdk_cairo_create (gtk_widget_get_window (f->gwfixed)); | 450 | //gdk_cairo_create (gtk_widget_get_window (FRAME_GTK_WIDGET (s->f))); |
| 451 | #ifdef HAVE_GOOCANVAS | 451 | #ifdef HAVE_GOOCANVAS |
| 452 | xv->widget = goo_canvas_new(); | 452 | xv->widget = goo_canvas_new(); |
| 453 | GooCanvasItem *root, *rect_item, *text_item; | 453 | GooCanvasItem *root, *rect_item, *text_item; |
| @@ -518,7 +518,7 @@ xwidget_init_view ( | |||
| 518 | //make container widget 1st, and put the actual widget inside the container | 518 | //make container widget 1st, and put the actual widget inside the container |
| 519 | //later, drawing should crop container window if necessary to handle case where xwidget | 519 | //later, drawing should crop container window if necessary to handle case where xwidget |
| 520 | //is partially obscured by other emacs windows | 520 | //is partially obscured by other emacs windows |
| 521 | xv->emacswindow = GTK_CONTAINER (s->f->gwfixed); | 521 | xv->emacswindow = GTK_CONTAINER (FRAME_GTK_WIDGET (s->f)); |
| 522 | //xw->widgetwindow = GTK_CONTAINER (gtk_layout_new (NULL, NULL)); | 522 | //xw->widgetwindow = GTK_CONTAINER (gtk_layout_new (NULL, NULL)); |
| 523 | //xw->widgetwindow = GTK_CONTAINER (gtk_offscreen_window_new ()); | 523 | //xw->widgetwindow = GTK_CONTAINER (gtk_offscreen_window_new ()); |
| 524 | 524 | ||
| @@ -555,7 +555,7 @@ xwidget_init_view ( | |||
| 555 | 555 | ||
| 556 | gtk_widget_set_size_request (GTK_WIDGET (xv->widget), xww->width, xww->height); | 556 | gtk_widget_set_size_request (GTK_WIDGET (xv->widget), xww->width, xww->height); |
| 557 | gtk_widget_set_size_request (GTK_WIDGET (xv->widgetwindow), xww->width, xww->height); | 557 | gtk_widget_set_size_request (GTK_WIDGET (xv->widgetwindow), xww->width, xww->height); |
| 558 | gtk_fixed_put (GTK_FIXED (s->f->gwfixed), GTK_WIDGET (xv->widgetwindow), x, y); | 558 | gtk_fixed_put (GTK_FIXED (FRAME_GTK_WIDGET (s->f)), GTK_WIDGET (xv->widgetwindow), x, y); |
| 559 | xv->x = x; xv->y = y; | 559 | xv->x = x; xv->y = y; |
| 560 | gtk_widget_show_all (GTK_WIDGET (xv->widgetwindow)); | 560 | gtk_widget_show_all (GTK_WIDGET (xv->widgetwindow)); |
| 561 | 561 | ||
| @@ -634,7 +634,7 @@ x_draw_xwidget_glyph_string (struct glyph_string *s) | |||
| 634 | if (!xwidget_hidden(xv)) //hidden equals not being seen during redisplay | 634 | if (!xwidget_hidden(xv)) //hidden equals not being seen during redisplay |
| 635 | { | 635 | { |
| 636 | //TODO should be possible to use xwidget_show_view here | 636 | //TODO should be possible to use xwidget_show_view here |
| 637 | gtk_fixed_move (GTK_FIXED (s->f->gwfixed), | 637 | gtk_fixed_move (GTK_FIXED (FRAME_GTK_WIDGET (s->f)), |
| 638 | GTK_WIDGET (xv->widgetwindow), | 638 | GTK_WIDGET (xv->widgetwindow), |
| 639 | x + clip_left, y + clip_top); | 639 | x + clip_left, y + clip_top); |
| 640 | } | 640 | } |