Made selection on mobile devices work with touchend and not click (not final)

This commit is contained in:
Andreas Stöckel 2011-06-02 22:50:35 +00:00
parent 0afe6ae498
commit 6c1e8e0d06

View File

@ -39,7 +39,7 @@ function nextmatchRowAOI(_node)
$(_node).mousedown(egwPreventSelect);
// Now append some action code to the node
$(_node).click(function(e) {
selectHandler = function(e) {
// Reset the prevent selection code (in order to allow wanted
// selection of text)
@ -54,7 +54,13 @@ function nextmatchRowAOI(_node)
!egwBitIsSet(state, EGW_AO_SHIFT_STATE_MULTI) || !selected,
state);
}
});
};
if (egwIsMobile()) {
_node.ontouchend = selectHandler;
} else {
$(node).click(selectHandler);
}
$(aoi.checkBox).change(function() {
aoi.updateState(EGW_AO_STATE_SELECTED, this.checked, EGW_AO_SHIFT_STATE_MULTI);