Fix responsiveness issue when selecting features on iPad

Implement an alternative solution for #6028 that doesn't rely on timeouts
This commit is contained in:
Quincy Morgan
2020-03-04 13:10:15 -08:00
parent c41e0b9937
commit 83d2656bbc
4 changed files with 13 additions and 14 deletions
+1 -1
View File
@@ -100,7 +100,7 @@ export function uiSectionPresetFields(context) {
_fieldsArr.forEach(function(field) {
field
.on('change', function(t, onInput) {
dispatch.call('change', field, t, onInput);
dispatch.call('change', field, _entityIDs, t, onInput);
})
.on('revert', function(keys) {
dispatch.call('revert', field, keys);
+6 -1
View File
@@ -553,9 +553,14 @@ export function uiSectionRawTagEditor(id, context) {
}
function scheduleChange() {
// Cache IDs in case the editor is reloaded before the change event is called. - #6028
var entityIDs = _entityIDs;
// Delay change in case this change is blurring an edited combo. - #5878
window.setTimeout(function() {
dispatch.call('change', this, _pendingChange);
if (!_pendingChange) return;
dispatch.call('change', this, entityIDs, _pendingChange);
_pendingChange = null;
}, 10);
}