Lordy, if the OP is a newbie, I'm finished. Their code is better than mine after 14 years of trying ;-0
S ET <nmset.set@gmail.com >: Sep 27 03:16AM -0700
Hello,
This is my very first step with FLTK and there are certainly many basic
things I'm missing about this library.
My concern here is about object destruction.
The following mockup is
...more
Daniel G. <dani.giritzer@gmail.com >: Sep 27 04:02AM -0700
Hi,
in C++ if you create objects with the keyword 'new' you need to delete them
yourself with 'delete'.
Please learn about RAII and Smart Pointers. Modern concepts which help you
...more
Albrecht Schlosser <fltk@aljus.de >: Sep 27 02:40PM +0200
On 9/27/26 12:16 S ET wrote:
> Hello,
> This is my very first step with FLTK and there are certainly many
> basic things I'm missing about this library.
Welcome to the FLTK world!
...more
imm <imacarthur@gmail.com >: Sep 27 01:47PM +0100
> in C++ if you create objects with the keyword 'new' you need to delete them yourself with 'delete'.
Well... this is "mostly true", and probably if you were doing this on
a school course the
...more
Daniel G. <dani.giritzer@gmail.com >: Sep 27 06:39AM -0700
> Well... this is "mostly true", and probably if you were doing this on
a school course the tutor would expect you to delete any object you
new'd...
Because it is good practice to take care of
...more
S ET <nmset.set@gmail.com >: Sep 27 06:40AM -0700
I got to deleting the main window in a handler, may be it's not the optimal
way though:
//
----------------------------------------------------------------------------------------------
...more
imm <imacarthur@gmail.com >: Sep 27 03:05PM +0100
On Sun, 27 Sept 2026 at 14:42, Daniel G. wrote:
> a school course the tutor would expect you to delete any object you
> new'd...
> Because it is good practice to take care of the things you own
...more
Albrecht Schlosser <fltk@aljus.de >: Sep 27 04:08PM +0200
On 9/27/26 15:40 S ET wrote:
> }
> //
> ----------------------------------------------------------------------------------------------
Unfortunately you didn't write how you established
...more
S ET <nmset.set@gmail.com >: Sep 27 07:45AM -0700
> cw->callback(OnMainWindowEvent, ...);
That's exactly it.
> but it doesn't remove your directory, does it?
No indeed. But in the real tiny app I'm working on, it's not *UserInterface*
...more
Albrecht Schlosser <fltk@aljus.de >: Sep 27 05:03PM +0200
On 9/27/26 16:45 S ET wrote:
> > cw->callback(OnMainWindowEvent, ...);
> That's exactly it.
OK, but this code needs compiler flag `-fpermissive`, and even with that
it still issues a warning.
...more
--
You received this message because you are subscribed to the Google Groups "fltk.general" group.
To unsubscribe from this group and stop receiving emails from it, send an email to fltkgeneral+unsubscribe@googlegroups.com .
To view this discussion visit https://groups.google.com/d/msgid/fltkgeneral/CAH%2BTFfmw0OrwbrM-f_P5DhqihZzH21yzL%2BmMhZ2MQnV8B%3DzAjA%40mail.gmail.com .
[ Direct Link to Message ]