1 //
2 //   Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010,
3 //   2011 Free Software Foundation, Inc
4 //
5 // This program is free software; you can redistribute it and/or modify
6 // it under the terms of the GNU General Public License as published by
7 // the Free Software Foundation; either version 3 of the License, or
8 // (at your option) any later version.
9 //
10 // This program is distributed in the hope that it will be useful,
11 // but WITHOUT ANY WARRANTY; without even the implied warranty of
12 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13 // GNU General Public License for more details.
14 //
15 // You should have received a copy of the GNU General Public License
16 // along with this program; if not, write to the Free Software
17 // Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
18 //
19 
20 #ifdef HAVE_CONFIG_H
21 #include "gnashconfig.h"
22 #endif
23 
24 #include "gtk_glue.h"
25 
26 #include <gtk/gtk.h>
27 #include <gdk/gdk.h>
28 
29 namespace gnash
30 {
31 
32 class GtkAggGlue : public GtkGlue
33 {
34   public:
35     GtkAggGlue();
36     ~GtkAggGlue();
37 
38     bool init(int argc, char **argv[]);
needsDrawingArea()39     bool needsDrawingArea() { return true; };
40     void prepDrawingArea(GtkWidget *drawing_area);
41     Renderer* createRenderHandler();
42     void setRenderHandlerSize(int width, int height);
43     virtual void beforeRendering(movie_root* stage);
44     void render();
45     void render(int minx, int miny, int maxx, int maxy);
46     void configure(GtkWidget *const widget, GdkEventConfigure *const event);
47 
48   private:
49     GdkImage* _offscreenbuf;
50     Renderer *_agg_renderer;
51 };
52 
53 } // namespace gnash
54 
55 // local Variables:
56 // mode: C++
57 // indent-tabs-mode: nil
58 // End:
59