3.2.0

onHeaderClicked Question

Hi there,

is there a way to change the "onHeaderClicked" to "onHeaderLeftClicked"?
cause i have a context menu on this, but every time i´m clicking with right mouse click on it, it´ll start sorting
i´m not this big in js, so i have to ask, where is the definition of onHeaderClicked or any other event like this, somewhere there must be standing what does onHeaderClicked means (not what happens when you click on it)
Markus Schostok, Germany
October 9,
function raiseMenuEvent2(event){
    this.raiseEvent("onHeadersContextMenu", event, obj.getSortColumn());
    }
    obj.getHeadersTemplate().setEvent("oncontextmenu", raiseMenuEvent2);


is there a similar way to create the onHeaderLeftClicked and overwrite the normal sorting function to this?
or disable the call of it when the right mouse is clicked?
Markus Schostok, Germany
October 9,
Yes, you can disable the default action (sorting) when the right mouse button is pressed -

obj.onHeaderClicked = function(event){
    if (event.button == 2){ // right button
        return true; // cancels further processing
    }
}
Alex (ActiveWidgets)
October 9,
many thanks
works perfect, even solved another problem i had... for my context i always had to double right click in firefox...
again... many thanks
Markus Schostok, Germany
October 10,

This topic is archived.

See also:


Back to support forum