Changeset 33098

Show
Ignore:
Timestamp:
21.05.2019 17:09:13 (4 weeks ago)
Author:
wy59
Message:

For the description input field, we're no longer using the oninput event handler, but have switched to the onchange handler, because with autocomplete a newly entered or pasted value wasn't always getting stored properly when using oninput.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone3/web/interfaces/default/js/map-scripts-editor.js

    r33096 r33098  
    119119     
    120120    var descriptionInput = document.getElementById("description" + "-" + this.id); 
    121     descriptionInput.oninput = function () {         
     121    // don't use oninput, use onchange, because with autocomplete a newly entered or pasted value 
     122    // doesn't always get stored properly when using oninput. 
     123    descriptionInput.onchange = function () {        
    122124        that.shapeSpecsChangeOnInput(); // takes care of history (undo/redo)         
    123125        var description = this.value;