diff --git a/sample/CairoSample.cs b/sample/CairoSample.cs index abc39d31f..b1fb52886 100644 --- a/sample/CairoSample.cs +++ b/sample/CairoSample.cs @@ -133,13 +133,9 @@ class Knockout : DrawingArea circles.Destroy (); } - protected override bool OnExposeEvent (Gdk.EventExpose e) + protected override bool OnDrawn (Cairo.Context ctx) { - using (Context cr = Gdk.CairoHelper.Create (e.Window)) { - int w, h; - e.Window.GetSize (out w, out h); - Draw (cr, w, h); - } + Draw (ctx, Window.Width, Window.Height); return true; } diff --git a/sample/Makefile.am b/sample/Makefile.am index 7783ae83e..e105663ba 100755 --- a/sample/Makefile.am +++ b/sample/Makefile.am @@ -8,7 +8,7 @@ DOTNET_TARGETS= DOTNET_ASSEMBLY= endif -TARGETS = gtk-hello-world.exe button.exe calendar.exe subclass.exe menu.exe treeviewdemo.exe managedtreeviewdemo.exe nodeviewdemo.exe treemodeldemo.exe actions.exe spawn.exe assistant.exe registerprop.exe gexceptiontest.exe native-instantiation.exe polarfixed.exe # cairo-sample.exe custom-widget.exe custom-cellrenderer.exe scribble.exe scribble-xinput.exe testdnd.exe $(DOTNET_TARGETS) +TARGETS = gtk-hello-world.exe button.exe calendar.exe subclass.exe menu.exe treeviewdemo.exe managedtreeviewdemo.exe nodeviewdemo.exe treemodeldemo.exe actions.exe spawn.exe assistant.exe registerprop.exe gexceptiontest.exe native-instantiation.exe polarfixed.exe cairo-sample.exe # custom-widget.exe custom-cellrenderer.exe scribble.exe scribble-xinput.exe testdnd.exe $(DOTNET_TARGETS) DEBUGS = $(addsuffix .mdb, $(TARGETS))