On Tue, Sep 18, 2012 at 12:27 PM, Victor Bombi <son...@telefonica.net> wrote:
>
>> Is there any difference between luaBitOp and the one wxLua provides?
>
> The main reason I am using it is because I need it in secondary
> lanes.(requiring wx for that would be
> too much,  besides it cant be done)

I plan to switch to the Lua 5.2 bitlib, so it will be in the table
bit32 to smooth the 5.2 transition.

Something along these lines:
http://smbolton.com/lua/lbitlib-5.2.0-alpha-backport1.c

>> On the other hand, if you want to use wxWidgets structures like a
>> wxImage, wxRect, etc, then consider that calling require("wx") takes a
>> fair amount of time itself and it may not be worth creating the
>> thread. Perhaps you can extract the work that needs to be done in
>> pure-Lua structures.
>
> I am not sure about what you mean. If you mean sending by lindas some kind
> of description for the
> work to be done by the wx lane and receiving the answer by lindas also, That
> is what I am already
> doing for creating windows from other lanes or using wxDir.

Perhaps it doesn't make sense for what you are doing, but I was
suggesting doing the calculations or whatever long task you need to do
in the thread in pure Lua so you wouldn't even need wxLua.

-----------------------------

In terms of not loading wxLua twice, there is not very much difference
between the 2.8.10 and 2.8.12 version.

2.8.12
http://wxlua.svn.sourceforge.net/viewvc/wxlua/trunk/wxLua/modules/luamodule/luamodule.cpp?revision=136&view=markup

2.8.10
http://wxlua.cvs.sourceforge.net/viewvc/wxlua/wxLua/modules/luamodule/src/luamodule.cpp?revision=1.10&view=markup

In fact, in terms of calling require("wx") the only difference I think
matters is the call to wxSetInstance(hDll);

Can you change it to this and see if you can load it multiple times as
you used to?

161     #ifdef __WXMSW__
162     // wxEntryStart() calls DoCommonPreInit() which calls
163     // wxSetInstance(::GetModuleHandle(NULL)); if wxGetInstance() is NULL.

if (hDll == NULL)
   wxSetInstance(hDll);

165     #endif // __WXMSW__

Regards,
    John

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
wxlua-users mailing list
wxlua-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wxlua-users

Reply via email to