Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>After several hours and a ton of test case, I finally find an acceptable explanation (but not yet a solution !)</p> <p>Let's explain the scenario :<br/> 1°) the user click on an icon on the screen<br/> 2°) the div#extra, which is already present in the page, is made visible by removing its display property (.style.display="")<br/> 3°) the div#extra is filed by an AJAX function with some elements depending on which icon was clicked by the user (more than 200 elements in certain case)<br/> 4°) the user click on an other icon to close the div <br/> 5°) all elements from the div#extra are removed<br/> 6°) the div#extra is hidden by putting is display property to 'none' (.style.display="none")<br/></p> <p>At first, on Firefox, I used "<strong>DOMAttrModified</strong>" event on the div#extra to check when the display property was modified and react accordingly. Problem, this event is not supported on Chrome !! </p> <p>So I replace it by "<strong>DOMSubtreeModified</strong>" (attached to div#extra) which is supported by both browser .... but not exactly in the same way :-( <br/> On Firefox, an event is fired for every modification in the subtree but also when the element itself is modified.<br/> On Chrome, they are a little bit more strict and fired event only for modification in the subtree .... and this is my issue !</p> <p>In Firefox,first event is fired at point 2 (in the scenario) and last at point 6 allowing my function to read when the div#extra is made hidden</p> <p>In Chrome, first event is fired at point 3 and last at point 5 ... so when the the div#extra is hidden my function is not called and I can't modify the flag !!!! CQFD </p> <p>Now, or I will add an event listener to the body of the page to intercept when the display property is modified, but it will generate a lot of call to my function, or the developer of TamperMonkey said yesterday that his extension now support "<strong>DOMAttrModified</strong>" (on Chrome) ....</p> <p>Thanks anyway to take the time to understand my question and your proposed solution</p> <p>ericc </p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload