[evolution/wip/webkit-composer] Rename EEditorFindDialog to EHTMLEditorFindDialog



commit 17a4123d4fc0a625b65407f5b3ee6902d8b98bef
Author: Tomas Popela <tpopela redhat com>
Date:   Mon Mar 31 10:32:53 2014 +0200

    Rename EEditorFindDialog to EHTMLEditorFindDialog

 .../evolution-util/evolution-util-docs.sgml        |    4 +-
 .../evolution-util/evolution-util-sections.txt     |   28 ++++----
 doc/reference/evolution-util/evolution-util.types  |    6 +-
 e-util/Makefile.am                                 |    4 +-
 e-util/e-editor-find-dialog.h                      |   71 -------------------
 e-util/e-html-editor-actions.c                     |    6 +-
 ...r-find-dialog.c => e-html-editor-find-dialog.c} |   48 +++++++-------
 e-util/e-html-editor-find-dialog.h                 |   73 ++++++++++++++++++++
 e-util/e-html-editor-private.h                     |    2 +-
 e-util/e-util.h                                    |    2 +-
 10 files changed, 123 insertions(+), 121 deletions(-)
---
diff --git a/doc/reference/evolution-util/evolution-util-docs.sgml 
b/doc/reference/evolution-util/evolution-util-docs.sgml
index 5e1c665..4f87635 100644
--- a/doc/reference/evolution-util/evolution-util-docs.sgml
+++ b/doc/reference/evolution-util/evolution-util-docs.sgml
@@ -100,7 +100,6 @@
 
   <chapter>
     <title>HTML Editing</title>
-    <xi:include href="xml/e-editor-find-dialog.xml"/>
     <xi:include href="xml/e-editor-hrule-dialog.xml"/>
     <xi:include href="xml/e-editor-image-dialog.xml"/>
     <xi:include href="xml/e-editor-link-dialog.xml"/>
@@ -119,9 +118,10 @@
     <xi:include href="xml/e-emoticon-tool-button.xml"/>
     <xi:include href="xml/e-html-editor.xml"/>
     <xi:include href="xml/e-html-editor-cell-dialog.xml"/>
+    <xi:include href="xml/e-html-editor-dialog.xml"/>
+    <xi:include href="xml/e-html-editor-find-dialog.xml"/>
     <xi:include href="xml/e-html-editor-selection.xml"/>
     <xi:include href="xml/e-html-editor-widget.xml"/>
-    <xi:include href="xml/e-html-editor-dialog.xml"/>
     <xi:include href="xml/e-image-chooser-dialog.xml"/>
     <xi:include href="xml/e-spell-checker.xml"/>
     <xi:include href="xml/e-spell-dictionary.xml"/>
diff --git a/doc/reference/evolution-util/evolution-util-sections.txt 
b/doc/reference/evolution-util/evolution-util-sections.txt
index 10de0eb..0dc9556 100644
--- a/doc/reference/evolution-util/evolution-util-sections.txt
+++ b/doc/reference/evolution-util/evolution-util-sections.txt
@@ -1636,21 +1636,21 @@ EHTMLEditorDialogPrivate
 </SECTION>
 
 <SECTION>
-<FILE>e-editor-find-dialog</FILE>
-<TITLE>EEditorFindDialog</TITLE>
-e_editor_find_dialog_new
-e_editor_find_dialog_find_next
-<SUBSECTION Standard>
-E_EDITOR_FIND_DIALOG
-E_IS_EDITOR_FIND_DIALOG
-E_TYPE_EDITOR_FIND_DIALOG
-E_EDITOR_FIND_DIALOG_CLASS
-E_IS_EDITOR_FIND_DIALOG_CLASS
-E_EDITOR_FIND_DIALOG_GET_CLASS
-EEditorFindDialogClass
-e_editor_find_dialog_get_type
-<SUBSECTION Private>
-EEditorFindDialogPrivate
+<FILE>e-html-editor-find-dialog</FILE>
+<TITLE>EHTMLEditorFindDialog</TITLE>
+e_html_editor_find_dialog_new
+e_html_editor_find_dialog_find_next
+<SUBSECTION Standard>
+E_HTML_EDITOR_FIND_DIALOG
+E_IS_HTML_EDITOR_FIND_DIALOG
+E_TYPE_HTML_EDITOR_FIND_DIALOG
+E_HTML_EDITOR_FIND_DIALOG_CLASS
+E_IS_HTML_EDITOR_FIND_DIALOG_CLASS
+E_HTML_EDITOR_FIND_DIALOG_GET_CLASS
+EHTMLEditorFindDialogClass
+e_html_editor_find_dialog_get_type
+<SUBSECTION Private>
+EHTMLEditorFindDialogPrivate
 </SECTION>
 
 <SECTION>
diff --git a/doc/reference/evolution-util/evolution-util.types 
b/doc/reference/evolution-util/evolution-util.types
index 0d33cd8..0696836 100644
--- a/doc/reference/evolution-util/evolution-util.types
+++ b/doc/reference/evolution-util/evolution-util.types
@@ -63,9 +63,6 @@ e_contact_store_get_type
 e_data_capture_get_type
 e_date_edit_get_type
 e_destination_store_get_type
-e_editor_cell_dialog_get_type
-e_editor_dialog_get_type
-e_editor_find_dialog_get_type
 e_editor_hrule_dialog_get_type
 e_editor_image_dialog_get_type
 e_editor_link_dialog_get_type
@@ -76,6 +73,9 @@ e_editor_spell_check_dialog_get_type
 e_editor_table_dialog_get_type
 e_editor_text_dialog_get_type
 e_html_editor_get_type
+e_html_editor_cell_dialog_get_type
+e_html_editor_dialog_get_type
+e_html_editor_find_dialog_get_type
 e_html_editor_selection_get_type
 e_html_editor_view_get_type
 e_emoticon_action_get_type
diff --git a/e-util/Makefile.am b/e-util/Makefile.am
index 0e8e04d..f63c577 100644
--- a/e-util/Makefile.am
+++ b/e-util/Makefile.am
@@ -176,7 +176,6 @@ evolution_util_include_HEADERS =  \
        e-destination-store.h \
        e-dialog-utils.h \
        e-dialog-widgets.h \
-       e-editor-find-dialog.h \
        e-editor-hrule-dialog.h \
        e-editor-image-dialog.h \
        e-editor-link-dialog.h \
@@ -208,6 +207,7 @@ evolution_util_include_HEADERS =  \
        e-html-editor-actions.h \
        e-html-editor-cell-dialog.h \
        e-html-editor-dialog.h \
+       e-html-editor-find-dialog.h \
        e-html-editor-selection.h \
        e-html-editor-utils.h \
        e-html-editor-view.h \
@@ -447,7 +447,6 @@ libevolution_util_la_SOURCES = \
        e-destination-store.c \
        e-dialog-utils.c \
        e-dialog-widgets.c \
-       e-editor-find-dialog.c \
        e-editor-hrule-dialog.c \
        e-editor-image-dialog.c \
        e-editor-link-dialog.c \
@@ -479,6 +478,7 @@ libevolution_util_la_SOURCES = \
        e-html-editor-actions.c \
        e-html-editor-cell-dialog.c \
        e-html-editor-dialog.c \
+       e-html-editor-find-dialog.c \
        e-html-editor-private.h \
        e-html-editor-selection.c \
        e-html-editor-utils.c \
diff --git a/e-util/e-html-editor-actions.c b/e-util/e-html-editor-actions.c
index cf382ab..9e6fb6b 100644
--- a/e-util/e-html-editor-actions.c
+++ b/e-util/e-html-editor-actions.c
@@ -837,7 +837,7 @@ action_show_find_cb (GtkAction *action,
                      EHTMLEditor *editor)
 {
        if (editor->priv->find_dialog == NULL) {
-               editor->priv->find_dialog = e_editor_find_dialog_new (editor);
+               editor->priv->find_dialog = e_html_editor_find_dialog_new (editor);
                gtk_action_set_sensitive (ACTION (FIND_AGAIN), TRUE);
        }
 
@@ -852,8 +852,8 @@ action_find_again_cb (GtkAction *action,
                return;
        }
 
-       e_editor_find_dialog_find_next (
-               E_EDITOR_FIND_DIALOG (editor->priv->find_dialog));
+       e_html_editor_find_dialog_find_next (
+               E_HTML_EDITOR_FIND_DIALOG (editor->priv->find_dialog));
 }
 
 static void
diff --git a/e-util/e-editor-find-dialog.c b/e-util/e-html-editor-find-dialog.c
similarity index 80%
rename from e-util/e-editor-find-dialog.c
rename to e-util/e-html-editor-find-dialog.c
index 58967b2..9f44cf8 100644
--- a/e-util/e-editor-find-dialog.c
+++ b/e-util/e-html-editor-find-dialog.c
@@ -1,5 +1,5 @@
 /*
- * e-editor-find-dialog.h
+ * e-html-editor-find-dialog.h
  *
  * Copyright (C) 2012 Dan Vrátil <dvratil redhat com>
  *
@@ -22,16 +22,16 @@
 #include <config.h>
 #endif
 
-#include "e-editor-find-dialog.h"
+#include "e-html-editor-find-dialog.h"
 
 #include <glib/gi18n-lib.h>
 #include <gdk/gdkkeysyms.h>
 
-#define E_EDITOR_FIND_DIALOG_GET_PRIVATE(obj) \
+#define E_HTML_EDITOR_FIND_DIALOG_GET_PRIVATE(obj) \
        (G_TYPE_INSTANCE_GET_PRIVATE \
-       ((obj), E_TYPE_EDITOR_FIND_DIALOG, EEditorFindDialogPrivate))
+       ((obj), E_TYPE_HTML_EDITOR_FIND_DIALOG, EHTMLEditorFindDialogPrivate))
 
-struct _EEditorFindDialogPrivate {
+struct _EHTMLEditorFindDialogPrivate {
        GtkWidget *entry;
        GtkWidget *backwards;
        GtkWidget *case_sensitive;
@@ -43,31 +43,31 @@ struct _EEditorFindDialogPrivate {
 };
 
 G_DEFINE_TYPE (
-       EEditorFindDialog,
-       e_editor_find_dialog,
+       EHTMLEditorFindDialog,
+       e_html_editor_find_dialog,
        E_TYPE_HTML_EDITOR_DIALOG);
 
 static void
-reset_dialog (EEditorFindDialog *dialog)
+reset_dialog (EHTMLEditorFindDialog *dialog)
 {
        gtk_widget_set_sensitive (dialog->priv->find_button, TRUE);
        gtk_widget_hide (dialog->priv->result_label);
 }
 
 static void
-editor_find_dialog_show (GtkWidget *widget)
+html_editor_find_dialog_show (GtkWidget *widget)
 {
-       EEditorFindDialog *dialog = E_EDITOR_FIND_DIALOG (widget);
+       EHTMLEditorFindDialog *dialog = E_HTML_EDITOR_FIND_DIALOG (widget);
 
        reset_dialog (dialog);
        gtk_widget_grab_focus (dialog->priv->entry);
 
        /* Chain up to parent's implementation */
-       GTK_WIDGET_CLASS (e_editor_find_dialog_parent_class)->show (widget);
+       GTK_WIDGET_CLASS (e_html_editor_find_dialog_parent_class)->show (widget);
 }
 
 static void
-editor_find_dialog_find_cb (EEditorFindDialog *dialog)
+html_editor_find_dialog_find_cb (EHTMLEditorFindDialog *dialog)
 {
        gboolean found;
        EHTMLEditor *editor;
@@ -112,10 +112,10 @@ entry_key_release_event (GtkWidget *widget,
                          gpointer user_data)
 {
        GdkEventKey *key = &event->key;
-       EEditorFindDialog *dialog = user_data;
+       EHTMLEditorFindDialog *dialog = user_data;
 
        if (key->keyval == GDK_KEY_Return) {
-               editor_find_dialog_find_cb (dialog);
+               html_editor_find_dialog_find_cb (dialog);
                return TRUE;
        }
 
@@ -124,24 +124,24 @@ entry_key_release_event (GtkWidget *widget,
 }
 
 static void
-e_editor_find_dialog_class_init (EEditorFindDialogClass *class)
+e_html_editor_find_dialog_class_init (EHTMLEditorFindDialogClass *class)
 {
        GtkWidgetClass *widget_class;
 
-       g_type_class_add_private (class, sizeof (EEditorFindDialogPrivate));
+       g_type_class_add_private (class, sizeof (EHTMLEditorFindDialogPrivate));
 
        widget_class = GTK_WIDGET_CLASS (class);
-       widget_class->show = editor_find_dialog_show;
+       widget_class->show = html_editor_find_dialog_show;
 }
 
 static void
-e_editor_find_dialog_init (EEditorFindDialog *dialog)
+e_html_editor_find_dialog_init (EHTMLEditorFindDialog *dialog)
 {
        GtkGrid *main_layout;
        GtkBox *box;
        GtkWidget *widget;
 
-       dialog->priv = E_EDITOR_FIND_DIALOG_GET_PRIVATE (dialog);
+       dialog->priv = E_HTML_EDITOR_FIND_DIALOG_GET_PRIVATE (dialog);
 
        main_layout = e_html_editor_dialog_get_container (E_HTML_EDITOR_DIALOG (dialog));
 
@@ -195,18 +195,18 @@ e_editor_find_dialog_init (EEditorFindDialog *dialog)
        gtk_box_pack_start (box, widget, FALSE, FALSE, 5);
        g_signal_connect_swapped (
                widget, "clicked",
-               G_CALLBACK (editor_find_dialog_find_cb), dialog);
+               G_CALLBACK (html_editor_find_dialog_find_cb), dialog);
        dialog->priv->find_button = widget;
 
        gtk_widget_show_all (GTK_WIDGET (main_layout));
 }
 
 GtkWidget *
-e_editor_find_dialog_new (EHTMLEditor *editor)
+e_html_editor_find_dialog_new (EHTMLEditor *editor)
 {
        return GTK_WIDGET (
                g_object_new (
-                       E_TYPE_EDITOR_FIND_DIALOG,
+                       E_TYPE_HTML_EDITOR_FIND_DIALOG,
                        "editor", editor,
                        "icon-name", GTK_STOCK_FIND,
                        "title", N_("Find"),
@@ -214,11 +214,11 @@ e_editor_find_dialog_new (EHTMLEditor *editor)
 }
 
 void
-e_editor_find_dialog_find_next (EEditorFindDialog *dialog)
+e_html_editor_find_dialog_find_next (EHTMLEditorFindDialog *dialog)
 {
        if (gtk_entry_get_text_length (GTK_ENTRY (dialog->priv->entry)) == 0) {
                return;
        }
 
-       editor_find_dialog_find_cb (dialog);
+       html_editor_find_dialog_find_cb (dialog);
 }
diff --git a/e-util/e-html-editor-find-dialog.h b/e-util/e-html-editor-find-dialog.h
new file mode 100644
index 0000000..60134f4
--- /dev/null
+++ b/e-util/e-html-editor-find-dialog.h
@@ -0,0 +1,73 @@
+/*
+ * e-html-editor-find-dialog.h
+ *
+ * Copyright (C) 2012 Dan Vrátil <dvratil redhat com>
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 of the License, or (at your option) version 3.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with the program; if not, see <http://www.gnu.org/licenses/>
+ *
+ */
+
+#if !defined (__E_UTIL_H_INSIDE__) && !defined (LIBEUTIL_COMPILATION)
+#error "Only <e-util/e-util.h> should be included directly."
+#endif
+
+#ifndef E_HTML_EDITOR_FIND_DIALOG_H
+#define E_HTML_EDITOR_FIND_DIALOG_H
+
+#include <e-util/e-html-editor-dialog.h>
+
+/* Standard GObject macros */
+#define E_TYPE_HTML_EDITOR_FIND_DIALOG \
+       (e_html_editor_find_dialog_get_type ())
+#define E_HTML_EDITOR_FIND_DIALOG(obj) \
+       (G_TYPE_CHECK_INSTANCE_CAST \
+       ((obj), E_TYPE_HTML_EDITOR_FIND_DIALOG, EHTMLEditorFindDialog))
+#define E_HTML_EDITOR_FIND_DIALOG_CLASS(cls) \
+       (G_TYPE_CHECK_CLASS_CAST \
+       ((cls), E_TYPE_HTML_EDITOR_FIND_DIALOG, EHTMLEditorFindDialogClass))
+#define E_IS_HTML_EDITOR_FIND_DIALOG(obj) \
+       (G_TYPE_CHECK_INSTANCE_TYPE \
+       ((obj), E_TYPE_HTML_EDITOR_FIND_DIALOG))
+#define E_IS_HTML_EDITOR_FIND_DIALOG_CLASS(cls) \
+       (G_TYPE_CHECK_CLASS_TYPE \
+       ((cls), E_TYPE_HTML_EDITOR_FIND_DIALOG))
+#define E_HTML_EDITOR_FIND_DIALOG_GET_CLASS(obj) \
+       (G_TYPE_INSTANCE_GET_CLASS \
+       ((obj), E_TYPE_HTML_EDITOR_FIND_DIALOG, EHTMLEditorFindDialogClass))
+
+G_BEGIN_DECLS
+
+typedef struct _EHTMLEditorFindDialog EHTMLEditorFindDialog;
+typedef struct _EHTMLEditorFindDialogClass EHTMLEditorFindDialogClass;
+typedef struct _EHTMLEditorFindDialogPrivate EHTMLEditorFindDialogPrivate;
+
+struct _EHTMLEditorFindDialog {
+       EHTMLEditorDialog parent;
+       EHTMLEditorFindDialogPrivate *priv;
+};
+
+struct _EHTMLEditorFindDialogClass {
+       EHTMLEditorDialogClass parent_class;
+};
+
+GType          e_html_editor_find_dialog_get_type
+                                               (void) G_GNUC_CONST;
+GtkWidget *    e_html_editor_find_dialog_new   (EHTMLEditor *editor);
+void           e_html_editor_find_dialog_find_next
+                                               (EHTMLEditorFindDialog *dialog);
+
+G_END_DECLS
+
+#endif /* E_HTML_EDITOR_FIND_DIALOG_H */
+
diff --git a/e-util/e-html-editor-private.h b/e-util/e-html-editor-private.h
index fb72087..472c088 100644
--- a/e-util/e-html-editor-private.h
+++ b/e-util/e-html-editor-private.h
@@ -26,8 +26,8 @@
 #include <e-html-editor.h>
 #include <e-html-editor-actions.h>
 #include <e-html-editor-cell-dialog.h>
+#include <e-html-editor-find-dialog.h>
 #include <e-html-editor-view.h>
-#include <e-editor-find-dialog.h>
 #include <e-editor-replace-dialog.h>
 #include <e-editor-link-dialog.h>
 #include <e-editor-hrule-dialog.h>
diff --git a/e-util/e-util.h b/e-util/e-util.h
index ecac003..4cea7f3 100644
--- a/e-util/e-util.h
+++ b/e-util/e-util.h
@@ -91,7 +91,6 @@
 #include <e-util/e-destination-store.h>
 #include <e-util/e-dialog-utils.h>
 #include <e-util/e-dialog-widgets.h>
-#include <e-util/e-editor-find-dialog.h>
 #include <e-util/e-editor-hrule-dialog.h>
 #include <e-util/e-editor-image-dialog.h>
 #include <e-util/e-editor-link-dialog.h>
@@ -123,6 +122,7 @@
 #include <e-util/e-html-editor-actions.h>
 #include <e-util/e-html-editor-cell-dialog.h>
 #include <e-util/e-html-editor-dialog.h>
+#include <e-util/e-html-editor-find-dialog.h>
 #include <e-util/e-html-editor-selection.h>
 #include <e-util/e-html-editor-utils.h>
 #include <e-util/e-html-editor-view.h>


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]