extFixes.js (tine20-2020.08.3) | : | extFixes.js (tine20-2020.08.4) | ||
---|---|---|---|---|
skipping to change at line 208 | skipping to change at line 208 | |||
for(var i = 0, len = cs.length; i < len; i++) { | for(var i = 0, len = cs.length; i < len; i++) { | |||
cs[i].expand(deep, anim, ticketFn()); | cs[i].expand(deep, anim, ticketFn()); | |||
} | } | |||
} | } | |||
wrapTicket(); | wrapTicket(); | |||
} | } | |||
}); | }); | |||
/** | /** | |||
* fix timezone handling for date picker | ||||
* | ||||
* The getValue function always returns 00:00:00 as time. So if a form got fille | ||||
d | ||||
* with a date like 2008-10-01T21:00:00 the form returns 2008-10-01T00:00:00 alt | ||||
hough | ||||
* the user did not change the fieled. | ||||
* | ||||
* In a multi timezone context this is fatal! When a user in a certain timezone | ||||
set | ||||
* a date (just a date and no time information), this means in his timezone the | ||||
* time range from 2008-10-01T00:00:00 to 2008-10-01T23:59:59. | ||||
* _BUT_ for an other user sitting in a different timezone it means e.g. the | ||||
* time range from 2008-10-01T02:00:00 to 2008-10-02T21:59:59. | ||||
* | ||||
* So on the one hand we need to make sure, that the date picker only returns | ||||
* changed datetime information when the user did a change. | ||||
* | ||||
* @todo On the other hand we | ||||
* need adjust the day +/- one day according to the timeshift. | ||||
*/ | ||||
/** | ||||
* @private | ||||
*/ | ||||
Ext.form.DateField.prototype.setValue = function(date){ | ||||
// get value must not return a string representation, so we convert this alw | ||||
ays here | ||||
// before memorisation | ||||
if (Ext.isString(date)) { | ||||
var v = Date.parseDate(date, Date.patterns.ISO8601Long); | ||||
if (Ext.isDate(v)) { | ||||
date = v; | ||||
} else { | ||||
date = Ext.form.DateField.prototype.parseDate.call(this, date); | ||||
} | ||||
} | ||||
// preserve original datetime information | ||||
this.fullDateTime = date; | ||||
Ext.form.DateField.superclass.setValue.call(this, this.formatDate(this.parse | ||||
Date(date))); | ||||
}; | ||||
/** | ||||
* @private | ||||
*/ | ||||
Ext.form.DateField.prototype.getValue = function(){ | ||||
//var value = this.parseDate(Ext.form.DateField.superclass.getValue.call(thi | ||||
s)); | ||||
// return the value that was set (has time information when unchanged in cli | ||||
ent) | ||||
// and not just the date part! | ||||
var value = this.fullDateTime; | ||||
return value || ""; | ||||
}; | ||||
/** | ||||
* Need this for ArrowEvents to navigate. | * Need this for ArrowEvents to navigate. | |||
*/ | */ | |||
Ext.KeyNav.prototype.forceKeyDown = Ext.isGecko; | Ext.KeyNav.prototype.forceKeyDown = Ext.isGecko; | |||
/** | /** | |||
* We need to overwrite to preserve original time information because | * We need to overwrite to preserve original time information because | |||
* Ext.form.TimeField does not support seconds | * Ext.form.TimeField does not support seconds | |||
* | * | |||
* @param {} time | * @param {} time | |||
* @private | * @private | |||
skipping to change at line 625 | skipping to change at line 574 | |||
cmp.syncSize(); | cmp.syncSize(); | |||
} | } | |||
cmp.wasVisible = visible; | cmp.wasVisible = visible; | |||
}); | }); | |||
Ext.form.TriggerField.prototype.taskForResize.delay(300); | Ext.form.TriggerField.prototype.taskForResize.delay(300); | |||
}); | }); | |||
Ext.form.TriggerField.prototype.taskForResize.delay(300); | Ext.form.TriggerField.prototype.taskForResize.delay(300); | |||
Ext.override(Ext.form.TwinTriggerField, { | ||||
getTriggerWidth: function(){ | ||||
var tw = 0; | ||||
Ext.each(this.triggers, function(t, index){ | ||||
var triggerIndex = 'Trigger' + (index + 1), | ||||
w = t.getWidth(); | ||||
if(w === 0 && !t['hidden' + triggerIndex]){ | ||||
tw += this.defaultTriggerWidth; | ||||
}else{ | ||||
tw += w; | ||||
} | ||||
}, this); | ||||
return tw; | ||||
} | ||||
}); | ||||
// fixing layers in LayerCombo | // fixing layers in LayerCombo | |||
// TODO maybe expand this to all Ext.Layers: | // TODO maybe expand this to all Ext.Layers: | |||
// Ext.Layer.prototype.showAction = Ext.Layer.prototype.showAction.createSequenc e(function() { | // Ext.Layer.prototype.showAction = Ext.Layer.prototype.showAction.createSequenc e(function() { | |||
// Ext.Layer.prototype.hideAction = Ext.Layer.prototype.hideAction.createSequenc e(function() { | // Ext.Layer.prototype.hideAction = Ext.Layer.prototype.hideAction.createSequenc e(function() { | |||
Ext.form.ComboBox.prototype.expand = Ext.form.ComboBox.prototype.expand.createSe quence(function() { | Ext.form.ComboBox.prototype.expand = Ext.form.ComboBox.prototype.expand.createSe quence(function() { | |||
// fix z-index problem when used in editorGrids | // fix z-index problem when used in editorGrids | |||
// manage z-index by windowMgr | // manage z-index by windowMgr | |||
this.list.setActive = Ext.emptyFn; | this.list.setActive = Ext.emptyFn; | |||
this.list.setZIndex = Ext.emptyFn; | this.list.setZIndex = Ext.emptyFn; | |||
Ext.WindowMgr.register(this.list); | Ext.WindowMgr.register(this.list); | |||
End of changes. 2 change blocks. | ||||
74 lines changed or deleted | 0 lines changed or added |