~drbob/+junk/diary-main

« back to all changes in this revision

Viewing changes to src/link.c

  • Committer: Philip Withnall
  • Date: 2008-03-23 12:35:24 UTC
  • Revision ID: philip@tecnocode.co.uk-20080323123524-eziv3p2dz11uyzgz
Fixed test profiling in the Makefile.
Some comments moved to stop them showing up in the POT file unnecessarily.
Improvements to the debug code.

Show diffs side-by-side

added added

removed removed

Lines of Context:
52
52
static const DiaryLinkType link_types[] = {
53
53
        /* Type,        Name,                   Description,                            Icon,                           Columns,        Format function,                View function,          Dialogue build function,        Get values function */
54
54
        /*{ "email",    N_("E-mail"),           N_("An e-mail you sent or received."),  "mail-read",                    2,              &link_email_format_value,       &link_email_view,       &link_email_build_dialog,       &link_email_get_values },*/
 
55
 
 
56
        /* Translators: These are the names and descriptions of the different link types. */
55
57
        { "file",       N_("File"),             N_("An attached file."),                "system-file-manager",          1,              &link_file_format_value,        &link_file_view,        &link_file_build_dialog,        &link_file_get_values },
56
58
        { "picasa",     N_("Picasa Album"),     N_("A Picasa album on the Internet."),  "insert-image",                 2,              &link_picasa_format_value,      &link_picasa_view,      &link_picasa_build_dialog,      &link_picasa_get_values },
57
59
        { "uri",        N_("URI"),              N_("A URI of a file or web page."),     "applications-internet",        1,              &link_uri_format_value,         &link_uri_view,         &link_uri_build_dialog,         &link_uri_get_values }
67
69
                gtk_list_store_append (list_store, &iter);
68
70
                gtk_list_store_set (list_store, &iter,
69
71
                                    type_column, link_types[i].type,
70
 
                                    name_column, link_types[i].name,
 
72
                                    name_column, _(link_types[i].name),
71
73
                                    icon_name_column, link_types[i].icon_name,
72
74
                                    -1);
73
75
        }
122
124
{
123
125
        const DiaryLinkType *link_type = diary_link_get_type (link->type);
124
126
        g_assert (link_type != NULL);
 
127
 
 
128
        if (diary->debug)
 
129
                g_debug ("Viewing %s link ('%s', '%s')", link->type, link->value, link->value2);
 
130
 
125
131
        return link_type->view_func (link);
126
132
}
127
133