tiagolr / dconsole

Haxe game-like console that provides runtime acess to methods, variables and more.
MIT License
169 stars 16 forks source link

Problem with adding components over dconsole #42

Closed ianharrigan closed 10 years ago

ianharrigan commented 10 years ago

Normally i initialize dconsole and then add a root (sprite) over the top of it... This means the console never shows as its created underneath a full screen sprite.

This can be solved pretty easy, by adding this line:

parent.setChildIndex(this, parent.numChildren - 1);

At line 154 in DCInterface.hx

Cheers, Ian

tiagolr commented 10 years ago

Nice, there was already toFront method using parent.swapChildren.. using setChildIndex is better and using it when show console also sounds good unless someone complains in the future.