summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: a68b271)
raw | patch | inline | side by side (parent: a68b271)
author | Jonas Fonseca <fonseca@diku.dk> | |
Fri, 30 Jan 2009 21:46:47 +0000 (22:46 +0100) | ||
committer | Jonas Fonseca <fonseca@diku.dk> | |
Mon, 2 Feb 2009 08:17:58 +0000 (09:17 +0100) |
tig.c | patch | blob | history |
index c569afc52fcfdebc1ffb7a2dbf8e54b9025957c7..b9543707cbea8f546b793060393048db231429f1 100644 (file)
--- a/tig.c
+++ b/tig.c
return draw_field(view, LINE_DATE, date, DATE_COLS, FALSE);
}
+static bool
+draw_author(struct view *view, const char *author)
+{
+ return draw_field(view, LINE_MAIN_AUTHOR, author, opt_author_cols, TRUE);
+}
+
static bool
draw_view_line(struct view *view, unsigned int lineno)
{
if (draw_field(view, LINE_TREE_MODE, mode, 11, TRUE))
return TRUE;
- if (opt_author &&
- draw_field(view, LINE_MAIN_AUTHOR, entry->author, opt_author_cols, TRUE))
+ if (opt_author && draw_author(view, entry->author))
return TRUE;
if (opt_date && draw_date(view, *entry->author ? &entry->time : NULL))
if (opt_date && draw_date(view, time))
return TRUE;
- if (opt_author &&
- draw_field(view, LINE_MAIN_AUTHOR, author, opt_author_cols, TRUE))
+ if (opt_author && draw_author(view, author))
return TRUE;
if (draw_field(view, LINE_BLAME_ID, id, ID_COLS, FALSE))
if (opt_date && draw_date(view, &commit->time))
return TRUE;
- if (opt_author &&
- draw_field(view, LINE_MAIN_AUTHOR, commit->author, opt_author_cols, TRUE))
+ if (opt_author && draw_author(view, commit->author))
return TRUE;
if (opt_rev_graph && commit->graph_size &&