[parted-devel] History with undo redo

Matt Davis mattdavis9 at gmail.com
Wed Jul 4 02:41:41 UTC 2007


On 7/3/07, Otavio Salvador <otavio at debian.org> wrote:
> "Matt Davis" <mattdavis9 at gmail.com> writes:
>
> >> On 6/29/07, Otavio Salvador <otavio at debian.org> wrote:
> > [-- Snip --]
> >> disk.h, define it in disk.c (which makes a call to history.{c,h}).
> >> Further, placing history as a library routine would make this easier.
> > [-- Snip --]
> >
> > As suggested, I rolled history into libparted instead of just a set of
> > routines solely for parted.  I like the idea, my question regards
> > output.  I feel very unsettled about putting any printf/output calls
> > in library routines.
>
> Yes, output shouldn't be done on the library.

Good....  I see we're sailing the same ship :-)

>
> > I could make all of the routines that might need to inform the user
> > via output return a special structure that each implementing
> > application can handle (and display the information at their
> > discretion)  Thoughts?  Should I check in what I have now?  I do
> > prefer to checkin early/often
>
> Or maybe just returns and exeptions that could be handled by the
> application?

Good point.  I think I have a solution for this.  I'll try to dabble
up something and submit by the weekend if I have time.

-Matt



More information about the parted-devel mailing list