Behavior about saving on exit

Pierre-Yves Chibon pingou at pingoured.fr
Tue Jul 17 22:59:40 PDT 2012


On Tue, 2012-07-17 at 15:30 -0700, Dirk Hohndel wrote:
> > This last change might be better off using overloading for the
> save_file
> > function for the case where it is accessed from the menu entry or
> while
> > closing the program. This would keep the current behavior still
> allowing
> > the described closing approach.
> 
> Not sure what you mean here. Can you elaborate?

In the current change: 
http://ambre.pingoured.fr/cgit/subsurface.git/commit/?id=91b20d2fd5200506c4dcc561bc4784987504f67c

I, basically, added a 'save_file_as' function which is quite close to
the 'save_file' function and I am wondering if there would not be a way
to merge the two functions using overloading (add a boolean to take the
existing_filename into account or not).

> > The beginning of this work is available at:
> > http://ambre.pingoured.fr/cgit/subsurface.git
> > I already found that there is at least one problem but this being my
> > first lines of C++ I'll have to dig/ask to people with more
> knowledge to
> > fix them if the ideas are considered interesting.
> 
> I think all this is actually C, not C++ :-) 

Well, that might actually solve the question above :-)

Thanks for the feedback, I will test more and submit the patches
described.

Regards,
Pierre


More information about the subsurface mailing list