[gedit/wip/gcode] GeditDocument: inherit from GcodeDocument
- From: Sébastien Wilmet <swilmet src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gedit/wip/gcode] GeditDocument: inherit from GcodeDocument
- Date: Wed, 6 May 2015 13:26:03 +0000 (UTC)
commit 88e281b6f5e023355abb8c61e7f938684604c556
Author: Sébastien Wilmet <swilmet gnome org>
Date: Wed May 6 15:23:08 2015 +0200
GeditDocument: inherit from GcodeDocument
It compiles fine, but there are run-time errors due to duplicated
signals etc.
gedit/gedit-document.c | 2 +-
gedit/gedit-document.h | 5 +++--
2 files changed, 4 insertions(+), 3 deletions(-)
---
diff --git a/gedit/gedit-document.c b/gedit/gedit-document.c
index 3dc4a05..9712b49 100644
--- a/gedit/gedit-document.c
+++ b/gedit/gedit-document.c
@@ -110,7 +110,7 @@ static guint document_signals[LAST_SIGNAL] = { 0 };
static GHashTable *allocated_untitled_numbers = NULL;
-G_DEFINE_TYPE_WITH_PRIVATE (GeditDocument, gedit_document, GTK_SOURCE_TYPE_BUFFER)
+G_DEFINE_TYPE_WITH_PRIVATE (GeditDocument, gedit_document, GCODE_TYPE_DOCUMENT)
static gint
get_untitled_number (void)
diff --git a/gedit/gedit-document.h b/gedit/gedit-document.h
index c76faa1..be1ae56 100644
--- a/gedit/gedit-document.h
+++ b/gedit/gedit-document.h
@@ -25,12 +25,13 @@
#define __GEDIT_DOCUMENT_H__
#include <gtksourceview/gtksource.h>
+#include <gedit/gcode/gcode-gedit.h>
G_BEGIN_DECLS
#define GEDIT_TYPE_DOCUMENT (gedit_document_get_type())
-G_DECLARE_DERIVABLE_TYPE (GeditDocument, gedit_document, GEDIT, DOCUMENT, GtkSourceBuffer)
+G_DECLARE_DERIVABLE_TYPE (GeditDocument, gedit_document, GEDIT, DOCUMENT, GcodeDocument)
#ifdef G_OS_WIN32
#define GEDIT_METADATA_ATTRIBUTE_POSITION "position"
@@ -44,7 +45,7 @@ G_DECLARE_DERIVABLE_TYPE (GeditDocument, gedit_document, GEDIT, DOCUMENT, GtkSou
struct _GeditDocumentClass
{
- GtkSourceBufferClass parent_class;
+ GcodeDocumentClass parent_class;
/* Signals */
void (* cursor_moved) (GeditDocument *document);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]