Re: [Planner Dev] New undo patch: Link/unlink tasks
- From: Alvaro del Castillo <acs lambdaux com>
- To: Richard Hult <richard imendio com>
- Cc: Planner Project Manager - Development List <planner-dev lists imendio com>
- Subject: Re: [Planner Dev] New undo patch: Link/unlink tasks
- Date: Wed, 05 May 2004 17:23:08 +0000
Hi!
El mié, 05-05-2004 a las 14:46, Richard Hult escribió:
> On ons, 2004-05-05 at 16:00 +0000, Alvaro del Castillo wrote:
> > El mié, 05-05-2004 a las 11:45, Richard Hult escribió:
> > > On ons, 2004-05-05 at 07:57 +0000, Alvaro del Castillo wrote:
> > > > Hi guys!
> > > >
> > > > Here goes another patch for the undo system. With this one you can
> > > > do/undo link/unlink tasks, using the link/unlink button and also,
> > > > linking tasks with drag and drop.
> > >
> > > Thanks, will take a look later today.
> > >
> > > > I have had to modify a little the PlannerCmd and here goes a proposal to
> > > > add 2 new fields: error and success. Richard, what do you think? I am
> > > > not sure I like to add new fields in this way to PlannerCmd.
> > >
> > > Hm, the boolean return value is for indicating success/failure, why do
> > > you need the field?
> > >
> >
> > I need the field because I need to know if a "PlannerCmd" has been
> > executed ok. For example:
> >
> > cmd = planner_task_tree_task_cmdlink (tree, task, target_task,
> > MRP_RELATION_FS, 0);
> >
> > if (cmd->success == FALSE) {
> > GtkWidget *dialog;
> >
> > ...
> >
> > a dialog to tell the user that the cmd can't be done.
>
> But that's what the boolean I added is for. The function shouldn't
> return a cmd if it didn't succeed, it should return NULL.
> (..._insert_and_do propagates the boolean from the command).
>
So the cmd return is NULL when the command fails and this is like a
"FALSE". Hmmm, ok, I think I can live with that. I think that I have
mixed my need with the error string with the boolean.
Sorry for the noise ;-)
Cheers
> /Richard
--
Alvaro del Castillo San Félix
Lambdaux Software Services S.R.L.
Universidad Rey Juan Carlos
Centro de Apoyo Tecnológico
C/ Tulipán sn 28933 Mostoles, Madrid-Spain
www.lambdaux.com
rocapal lambdaux com
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]