Re: [evolution-patches] Patch for Proxy Assignement/ Editing and deleting



Are these strings displayed/need to be translated?

On Sun, 2005-07-10 at 12:26 +0530, Shreyas wrote:
> +       column = gtk_tree_view_column_new_with_attributes ("Picture",
> renderer, "pixbuf", ACCOUNT_PICTURE, NULL);
> +       gtk_tree_view_append_column (GTK_TREE_VIEW (priv->tree),
> column);
> +       renderer = gtk_cell_renderer_text_new ();
> +       column = gtk_tree_view_column_new_with_attributes ("Name",
> renderer, "text", ACCOUNT_NAME, NULL); 


Dont ever make url's using printf.  Use camel-url or other url object.

> +       key =  g_strdup_printf ("groupwise://%s %s/", url->user,
> poa_address); 
> +       
> +       if (!g_str_equal (use_ssl, "never"))

^^ Umm, use strcmp here.  g_str_equal actually returns a boolean true if
it is equal, but you're using it like strcmp returning 0 for equal.  the
g_str_equal function is really only for ghashtable use.

> +               uri = g_strdup_printf ("https://%s:%s/soap";,
> poa_address, soap_port);
> +       else 
> +               uri = g_strdup_printf ("http://%s:%s/soap";,
> poa_address, soap_port);
> +       

Dont use g_strstr here, just use strncmp("groupwise:", ...).

> 
> +       if(!g_strrstr (e_account_get_string(account,
> E_ACCOUNT_SOURCE_URL), "groupwise://"))
> +               return NULL;


> I personally did not see any way around putting everything on Account
> (as associations). Please have a look at the patch and let me know if
> anything is broken.

Well you could just set 1 data object as a struct, and just access that,
and include all the various fields on that.  That might be easiest.  You
really should be using set_data_full too, so it frees stuff
appropriately, since you may not get called for freeing stuff otherwise.

For the eimport target i added a gdatalist, maybe something could be
added to all targets; but just doing it on the eaccount object should
suffice.

I guess the rest looks fine enough (i only skimmed it).

Thanks,
 Michael





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