From: Thomas Geymayer Date: Thu, 19 Jun 2014 11:30:01 +0000 (+0200) Subject: Nasal: set CustomEvent::bubbles. X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=1d5f2296530722acc782748474a18d270c51720e;p=flightgear.git Nasal: set CustomEvent::bubbles. --- diff --git a/src/Scripting/NasalCanvas.cxx b/src/Scripting/NasalCanvas.cxx index ee1b3dad1..64619a1d1 100644 --- a/src/Scripting/NasalCanvas.cxx +++ b/src/Scripting/NasalCanvas.cxx @@ -285,6 +285,7 @@ static naRef f_createCustomEvent(const nasal::CallContext& ctx) if( type.empty() ) return naNil(); + bool bubbles = false; simgear::StringMap detail; if( ctx.isHash(1) ) { @@ -292,9 +293,12 @@ static naRef f_createCustomEvent(const nasal::CallContext& ctx) naRef na_detail = cfg.get("detail"); if( naIsHash(na_detail) ) detail = ctx.from_nasal(na_detail); + bubbles = cfg.get("bubbles"); } - return ctx.to_nasal( sc::CustomEventPtr(new sc::CustomEvent(type, detail)) ); + return ctx.to_nasal( + sc::CustomEventPtr(new sc::CustomEvent(type, bubbles, detail)) + ); } struct CustomEventDetailWrapper: