Project

General

Profile

Feature #510

Trigger callback function when clicking header

Added by Marc Boegem almost 12 years ago. Updated about 10 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
Start date:
05/16/2012
Due date:
% Done:

0%

Estimated time:
Browser (if web client):

Description

Would it be possible to have the bean triggering a callback function when a title header is clicked?
Preferable the callback function receives a column number.


Files

servoy-treeview.jar (105 KB) servoy-treeview.jar Header column click Imre Tokai, 05/16/2012 08:43 PM
servoy-treeview.jar (117 KB) servoy-treeview.jar node passed, Servoy 6 aware (without warnings) Imre Tokai, 05/18/2012 08:52 PM

History

#1

Updated by Imre Tokai almost 12 years ago

Hi,

Try attached version, please
Need to extend Servoy solution in 2 places:

1. init
elements.treeview.onHeaderClick( onHeaderClick )

2. invoked function
@/** * @param * node * @param {Number} colIndex index of the column clicked in the header * * properties={typeid:24,uuid:"CEB11B55-C167-4DF2-A7D8-2EBBCE29463D"}
*/
function onHeaderClick( node, colIndex ){
application.output('Column index: '+colIndex)
}

Let us know how things are going

Regards

#2

Updated by Imre Tokai almost 12 years ago

  • Status changed from New to In Progress
#3

Updated by Marc Boegem almost 12 years ago

  • Assignee set to Imre Tokai

Hi Imre,

This new function does exactly what I meant it to do. Thnkx!

There's only 1 thing: the attached version doesn't seem to be fully Servoy aware anymore, as a result I get warnings on all the bean functions.
But... it is loaded in Serclipse and I see it as an element on my form. (This was an existing reference to the beanclass used by the previous version)

Further more: the 'node' parameter doesn't seem to contain anything.

#4

Updated by Imre Tokai almost 12 years ago

Test attached, please
Let us know how things are going

Regards

#5

Updated by Marc Boegem almost 12 years ago

This version solved the problems of the previous.

Just curious: what is the reason the headerclick passes the node id?
This is currently always the first node

#6

Updated by Imre Tokai about 10 years ago

  • Status changed from In Progress to Resolved

Feature should be available in servoy-treeview-experimental.jar
If further work is needed, reopen/create case, please

Regards

Also available in: Atom PDF