events capturing sometimes not work
krumza

as example i create a div with buttons and then append to main_wade_div for align

i add onclick to this div - 1) stopPropagation 2) return true; but event alas bubbling to canvas

what i must do that stop bubbling event to canvas from non-canvas DOM elements?

this cause i insert my GUI into main_wade_div, but if i do not do this - i cant align my GUI to canvas

dilemma

p.s. i found answer but i do not think that is full - 

- i create div#gui fully copy styles for wade_main_div

- than  div#gui append in document above wade_main_div

- than on wade.update div#gui get size of wade_main_div

- to unlock canvas to events i add css rule for div#gui  pointer-events: none;

- and for it children buttons css rule  pointer-events: all;

it work as i want but i do not think that is an ideal

No Comments Yet
Post a reply
Add Attachment
Submit Reply
Login to Reply