aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJörg Mayer <jmayer@loplof.de>2011-08-21 16:07:41 +0000
committerJörg Mayer <jmayer@loplof.de>2011-08-21 16:07:41 +0000
commit4a2f14ed6e93f7367ba4357caa2bf53500c501e1 (patch)
treeaa7f378ab4c1904acfd9a72a382f8824547fc8a9
parent65759680c9b41f6da0355366e2d476e212137269 (diff)
Fix the remaining places that GDK_DISABLE_DEPRECATED complained about
(mostly just comment in already present code). svn path=/trunk/; revision=38645
-rw-r--r--gtk/rtp_player.c33
1 files changed, 8 insertions, 25 deletions
diff --git a/gtk/rtp_player.c b/gtk/rtp_player.c
index 588aa0fa79..cfb5a4e4cd 100644
--- a/gtk/rtp_player.c
+++ b/gtk/rtp_player.c
@@ -60,10 +60,6 @@
#include <string.h>
#include "portaudio.h"
-#if defined(GDK_DISABLE_DEPRECATED)
-# undef GDK_DISABLE_DEPRECATED
-#endif
-
#include <gtk/gtk.h>
#include <epan/stats_tree.h>
@@ -973,21 +969,17 @@ draw_channel_cursor(rtp_channel_info_t *rci, guint32 start_index)
/* draw the previous saved pixbuf line */
if (rci->cursor_pixbuf && (rci->cursor_prev>=0)) {
- gdk_draw_pixbuf(rci->pixmap, NULL, rci->cursor_pixbuf, 0, 0, (int) (rci->cursor_prev/MULT), 0, -1, -1, GDK_RGB_DITHER_NONE, 0 ,0);
-#if 0
cr = gdk_cairo_create (rci->pixmap);
gdk_cairo_set_source_pixbuf (cr, rci->cursor_pixbuf, 0, 0);
- cairo_pattern_set_extend (cairo_get_source (cr), CAIRO_EXTEND_REPEAT);
+ cairo_pattern_set_extend (cairo_get_source (cr), CAIRO_EXTEND_REPEAT);
cairo_rectangle (cr, rci->cursor_prev/MULT, 0, -1, -1);
cairo_fill (cr);
+
+ gdk_cairo_set_source_pixmap (cr, rci->pixmap,idx/MULT, 0);
+ cairo_pattern_set_extend (cairo_get_source (cr), CAIRO_EXTEND_REPEAT);
+ cairo_rectangle (cr, rci->cursor_prev/MULT, 0, 1, widget_alloc.height-HEIGHT_TIME_LABEL);
+ cairo_fill (cr);
cairo_destroy (cr);
-#endif
- gdk_draw_drawable(gtk_widget_get_window(rci->draw_area),
- gtk_widget_get_style(rci->draw_area)->fg_gc[gtk_widget_get_state(rci->draw_area)],
- rci->pixmap,
- (int) (rci->cursor_prev/MULT), 0,
- (int) (rci->cursor_prev/MULT), 0,
- 1, widget_alloc.height-HEIGHT_TIME_LABEL);
g_object_unref(rci->cursor_pixbuf);
rci->cursor_pixbuf = NULL;
@@ -1002,22 +994,13 @@ draw_channel_cursor(rtp_channel_info_t *rci, guint32 start_index)
cairo_line_to(cr, idx/MULT, widget_alloc.height-HEIGHT_TIME_LABEL);
cairo_stroke(cr);
cairo_destroy(cr);
- cr=NULL;
-
- gdk_draw_drawable(gtk_widget_get_window(rci->draw_area),
- gtk_widget_get_style(rci->draw_area)->fg_gc[gtk_widget_get_state(rci->draw_area)],
- rci->pixmap,
- (int) (idx/MULT), 0,
- (int) (idx/MULT), 0,
- 1, widget_alloc.height-HEIGHT_TIME_LABEL);
-#if 0
+
cr = gdk_cairo_create (gtk_widget_get_window(rci->draw_area));
gdk_cairo_set_source_pixmap (cr, rci->pixmap,idx/MULT, 0);
- cairo_pattern_set_extend (cairo_get_source (cr), CAIRO_EXTEND_REPEAT);
+ cairo_pattern_set_extend (cairo_get_source (cr), CAIRO_EXTEND_REPEAT);
cairo_rectangle (cr, idx/MULT, 0, 1, widget_alloc.height-HEIGHT_TIME_LABEL);
cairo_fill (cr);
cairo_destroy (cr);
-#endif
}
/* Disconnect the scroll bar "value" signal to not be called */