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 » THISBACK and inheritance
Re: THISBACK and inheritance [message #48484 is a reply to message #48483] Fri, 07 July 2017 08:40 Go to previous message
rafiwui is currently offline  rafiwui
Messages: 105
Registered: June 2017
Location: Stuttgart, Germany
Experienced Member
Oblivion wrote on Thu, 06 July 2017 23:17
Hello Daniel,

It is because those button events aren't called immediately. They are called when there is some user action (They are called WHEN there is action (click/push, etc.).
Had they been called immediately you would have the same undefined behaviour.
On the other hand, MenuBar::Set() method calls the provided callback, and sets the menubar immediately, which leads to crash.


Ah okay. Thanks for your answers.

Oblivion wrote on Thu, 06 July 2017 23:17
Hello Daniel,

Ah, that's my fault. Nevermind. (For some reason, the below macros reminded me of U++ internal macros used in the TheIDE layout editor.)


Oh yeah they are pretty similar Laughing


Greetings
Daniel
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: About storing references and pointers to callbacks.
Next Topic: [REQUEST]: Allow callback() template to work also with non-void and non-bool return types.
Goto Forum:
  


Current Time: Sat Apr 27 16:28:03 CEST 2024

Total time taken to generate the page: 0.04812 seconds