[gnome-builder] source-view: remove filename variable knowledge from source-view.
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder] source-view: remove filename variable knowledge from source-view.
- Date: Mon, 8 Sep 2014 06:27:33 +0000 (UTC)
commit 1fb2be0d298cb4e9b8939417ec5002195b3605a0
Author: Christian Hergert <christian hergert me>
Date: Sun Sep 7 23:23:29 2014 -0700
source-view: remove filename variable knowledge from source-view.
src/editor/gb-source-view.c | 22 ----------------------
1 files changed, 0 insertions(+), 22 deletions(-)
---
diff --git a/src/editor/gb-source-view.c b/src/editor/gb-source-view.c
index 1cfdb9d..85d9509 100644
--- a/src/editor/gb-source-view.c
+++ b/src/editor/gb-source-view.c
@@ -163,23 +163,6 @@ gb_source_view_set_show_shadow (GbSourceView *view,
invalidate_window (view);
}
-static gchar *
-get_filename (GbSourceView *view)
-{
- GtkTextBuffer *buffer;
- GFile *file;
-
- buffer = gtk_text_view_get_buffer (GTK_TEXT_VIEW (view));
- g_assert (GB_IS_EDITOR_DOCUMENT (buffer));
-
- file = gb_editor_document_get_file (GB_EDITOR_DOCUMENT (buffer));
-
- if (!file)
- return g_strdup ("");
-
- return g_file_get_basename (file);
-}
-
static void
get_rect_for_iters (GtkTextView *text_view,
const GtkTextIter *iter1,
@@ -417,7 +400,6 @@ gb_source_view_push_snippet (GbSourceView *view,
GtkTextIter iter;
gboolean has_more_tab_stops;
gboolean insert_spaces;
- gchar *name;
gchar *line_prefix;
guint tab_width;
@@ -428,10 +410,6 @@ gb_source_view_push_snippet (GbSourceView *view,
context = gb_source_snippet_get_context (snippet);
- name = get_filename (view);
- gb_source_snippet_context_add_variable (context, "filename", name);
- g_free (name);
-
if ((previous = g_queue_peek_head (priv->snippets)))
gb_source_snippet_pause (previous);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]