[gitg] diff-view-file: fix the mark position
- From: Ignacio Casal Quinteiro <icq src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gitg] diff-view-file: fix the mark position
- Date: Sat, 19 Dec 2015 12:15:32 +0000 (UTC)
commit 0e4057e95f982b0092555fda62b426322f2ac007
Author: Ignacio Casal Quinteiro <icq gnome org>
Date: Sat Dec 19 13:15:14 2015 +0100
diff-view-file: fix the mark position
libgitg/gitg-diff-view-file.vala | 3 +--
1 files changed, 1 insertions(+), 2 deletions(-)
---
diff --git a/libgitg/gitg-diff-view-file.vala b/libgitg/gitg-diff-view-file.vala
index 5476bf5..025df56 100644
--- a/libgitg/gitg-diff-view-file.vala
+++ b/libgitg/gitg-diff-view-file.vala
@@ -508,7 +508,6 @@ class Gitg.DiffViewFile : Gtk.Grid
}
iter.set_line_offset(0);
- int line_header = iter.get_line();
buffer.create_source_mark(null, "header", iter);
var header = @"@@ -$(hunk.get_old_start()),$(hunk.get_old_lines())
+$(hunk.get_new_start()),$(hunk.get_new_lines()) @@ $h\n";
@@ -570,7 +569,7 @@ class Gitg.DiffViewFile : Gtk.Grid
if (category != null)
{
- buffer.get_iter_at_line(out iter, line_header + i);
+ buffer.get_iter_at_line(out iter, line_hunk_start + i);
buffer.create_source_mark(null, category, iter);
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]