Re: [evolution-patches] calendar and task source deletion



On Mon, 2004-03-29 at 13:01 -0500, William Jon McCann wrote:

> Rodrigo Moya wrote:
> > hmm, I think it doesn't, but not your fault, but the original code. It
> > is written in a way that will only remove calendars that are selected,
> > that is:
> > 
> > cal = e_cal_model_get_client_for_uri (gnome_calendar_get_calendar_model
> > (priv->calendar), uri);
> > if (cal)
> > 	...
> > 
> > This will search the calendar in the view's model (which only contains
> > the calendars currently loaded). So, if the calendar is not loaded, the
> > source will be removed, but e_cal_remove won't be called for that
> > calendar, meaning that files won't be deleted for local calendars,
> > folders won't be removed for remote calendars, etc
> 
> Oh, I see.  Thanks for the explanation.
> 
> I think one way around this is to do an e_cal_new if the cal isn't 
> loaded already.  From what I can see that is OK as long as e_cal_open 
> isn't done too.
> 
yes, calling e_cal_remove should not need e_cal_open to be called
before.

> Updated patch attached.
> 
looks ok

cheers




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]