summaryrefslogtreecommitdiff
path: root/html/examples/iuplua_cdlua.wlua
diff options
context:
space:
mode:
Diffstat (limited to 'html/examples/iuplua_cdlua.wlua')
-rw-r--r--html/examples/iuplua_cdlua.wlua3
1 files changed, 3 insertions, 0 deletions
diff --git a/html/examples/iuplua_cdlua.wlua b/html/examples/iuplua_cdlua.wlua
index 5528117..d9c5058 100644
--- a/html/examples/iuplua_cdlua.wlua
+++ b/html/examples/iuplua_cdlua.wlua
@@ -1,6 +1,7 @@
require"cdlua"
require"iuplua"
require"iupluacd"
+require"cdluacontextplus"
cnv = iup.canvas {size = "200x100"}
@@ -13,7 +14,9 @@ box = iup.vbox{
dlg = iup.dialog{box; title="Example IUPLUA/CDLUA"}
function cnv:map_cb()
+ cd.UseContextPlus(true)
canvas = cd.CreateCanvas(cd.IUP, self)
+ cd.UseContextPlus(false)
self.canvas = canvas -- store the CD canvas in a IUP attribute
end