07-10-2014, 01:59 PM
ok, controls are in constant position in window.
what's the fastest way to implement so click position linked to an action, something like a range routine...
a derivate from
if(PtInRect(&r f.x f.y))
but with an iteration from rect array (or something like that).
rectangle 1 0 0 100 100
rectangle2 10 10 100 100
foreach rec rectangle
if( PtInRect(&rec f.x f.y))
do action based on rectangle mouse points to..
don't know if it is clear...
what's the fastest way to implement so click position linked to an action, something like a range routine...
a derivate from
if(PtInRect(&r f.x f.y))
but with an iteration from rect array (or something like that).
rectangle 1 0 0 100 100
rectangle2 10 10 100 100
foreach rec rectangle
if( PtInRect(&rec f.x f.y))
do action based on rectangle mouse points to..
don't know if it is clear...
