Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » U++ Callbacks and Timers » Feature request
Feature request [message #39541] Tue, 26 March 2013 19:10 Go to next message
Alboni is currently offline  Alboni
Messages: 196
Registered: January 2012
Location: Deventer, Netherlands
Experienced Member
I would like to see things like:

Callback whenKillFocus;
Callback whenSetFocus;
etc.

in Ctrl

that would make writing complicated forms a lot easier.
Re: Feature request [message #42012 is a reply to message #39541] Mon, 10 February 2014 20:19 Go to previous messageGo to next message
mirek is currently offline  mirek
Messages: 12519
Registered: November 2005
Ultimate Member
Alboni wrote on Tue, 26 March 2013 14:10

I would like to see things like:

Callback whenKillFocus;
Callback whenSetFocus;
etc.

in Ctrl

that would make writing complicated forms a lot easier.



I understand the sentiment, but 'etc.' can mean a lot... In any case, each such thing means 8 bytes more in sizeof(Ctrl), which is not very good for filling e.g. ArrayCtrl with widgets.

Generally, for focus games, ChildGotFocus and ChildLostFocus virtual methods in parent often even better than those individual callbacks.
Re: Feature request [message #42019 is a reply to message #39541] Tue, 11 February 2014 09:59 Go to previous messageGo to next message
Alboni is currently offline  Alboni
Messages: 196
Registered: January 2012
Location: Deventer, Netherlands
Experienced Member
I hear you. I hadn't discovered those functions yet at the time of posting.
Re: Feature request [message #42222 is a reply to message #42019] Fri, 28 February 2014 12:58 Go to previous message
mdelfede is currently offline  mdelfede
Messages: 1264
Registered: September 2007
Senior Contributor
Maybe a generic callback with a 'what' parameter could be added to Ctrl.... I mean

ctrl.GenericAction = THISBACK1(handler)
......
void handler(int reason)


This would not add too much size to ctrl and more 'reasons' could be added in future.
Previous Topic: manually creating callback
Next Topic: Kill callbacks when parent is destructed
Goto Forum:
  


Current Time: Wed Jun 03 18:31:13 CEST 2020

Total time taken to generate the page: 0.00830 seconds