Re: [evolution-patches] mailer: vtrash/vjunk folder info patch for evo/HEAD



okie, I have updated the patch and committed.

Radek

On Sun, 2003-11-30 at 22:53, Not Zed wrote:
> 
> A couple of things, from the old code, be nice to clean up:
> 
> +static void
> +add_vtrash_info (CamelStore *store, CamelFolderInfo *info)
> +{
> +       add_vtrash_or_vjunk_info (store, info, CAMEL_VTRASH_NAME,
> _("Trash"), "vtrash", FALSE);
> +}
> +
> +static void
> +add_vjunk_info (CamelStore *store, CamelFolderInfo *info)
> +{
> +       add_vtrash_or_vjunk_info (store, info, CAMEL_VJUNK_NAME,
> _("Junk"), "vjunk", TRUE);
> +}
> 
> this is redundant, just call add_vtrash_or_vjunk_info directly from
> camel_store_get_folder_info.
> 
> maybe call it add_special_info() or something too, the current one is
> a pretty awful name.  You should also set vinfo->flags to at least
> CAMEL_FOLDER_NOINFERIORS (& maybe CAMEL_FOLDER_SUBSCRIBED) if a new
> one was created.
> 
> and:
> 
>                 else if (!strcasecmp (path, "/Trash"))
>                         pixbuf = folder_icons[FOLDER_ICON_TRASH];
> +               else if (!strcasecmp (path, "/Junk"))
> +                       pixbuf = folder_icons[FOLDER_ICON_JUNK];
> 
> 
> This should use CAMEL_VTRASH_NAME and CAMEL_VJUNK_NAME instead of the
> hardcoded paths.
> 
> (you'll have ot check against path+1 since the names dont include /).
> 
> This is one reason i said it should be done via a type field,
> otherwise you have to do string checks all over the place.
> 
> 
> These names also have to be translated when they are output into the
> tree view.





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