[evolution/wip/tpopela/composer-dnd: 7/7] Be more verbose about some of the history events
- From: Tomas Popela <tpopela src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution/wip/tpopela/composer-dnd: 7/7] Be more verbose about some of the history events
- Date: Fri, 17 Mar 2017 14:52:48 +0000 (UTC)
commit f8113eb4b2f5334890d9504a1b0513a9a92e57c5
Author: Tomas Popela <tpopela redhat com>
Date: Fri Mar 17 13:54:26 2017 +0100
Be more verbose about some of the history events
.../web-extension/e-editor-undo-redo-manager.c | 22 +++++++++++++------
1 files changed, 15 insertions(+), 7 deletions(-)
---
diff --git a/src/modules/webkit-editor/web-extension/e-editor-undo-redo-manager.c
b/src/modules/webkit-editor/web-extension/e-editor-undo-redo-manager.c
index 2f4831a..9c8205b 100644
--- a/src/modules/webkit-editor/web-extension/e-editor-undo-redo-manager.c
+++ b/src/modules/webkit-editor/web-extension/e-editor-undo-redo-manager.c
@@ -117,13 +117,13 @@ print_node_inner_html (WebKitDOMNode *node)
gchar *inner_html;
if (!node) {
- printf (" none\n");
+ printf (" content: none\n");
return;
}
inner_html = dom_get_node_inner_html (node);
- printf (" '%s'\n", inner_html);
+ printf (" content: '%s'\n", inner_html);
g_free (inner_html);
}
@@ -133,14 +133,22 @@ print_history_event (EEditorHistoryEvent *event)
{
if (event->type != HISTORY_START && event->type != HISTORY_AND) {
printf (" %s\n", event_type_string[event->type]);
- printf (" before: start_x: %u ; start_y: %u ; end_x: %u ; end_y: %u ;\n",
+ printf (" before: start_x: %u ; start_y: %u ; end_x: %u ; end_y: %u\n",
event->before.start.x, event->before.start.y, event->before.end.x,
event->before.end.y);
- printf (" after: start_x: %u ; start_y: %u ; end_x: %u ; end_y: %u ;\n",
+ printf (" after: start_x: %u ; start_y: %u ; end_x: %u ; end_y: %u\n",
event->after.start.x, event->after.start.y, event->after.end.x, event->after.end.y);
}
switch (event->type) {
case HISTORY_DELETE:
+ if (g_object_get_data (G_OBJECT (event->data.fragment), "history-delete-key")) {
+ printf (" type: delete\n");
+ } else
+ printf (" type: backspace\n");
+ if (g_object_get_data (G_OBJECT (event->data.fragment), "history-control-key"))
+ printf (" control\n");
case HISTORY_INPUT:
+ if (g_object_get_data (G_OBJECT (event->data.fragment), "history-return-key"))
+ printf (" type: return\n");
case HISTORY_REMOVE_LINK:
case HISTORY_SMILEY:
case HISTORY_IMAGE:
@@ -157,13 +165,13 @@ print_history_event (EEditorHistoryEvent *event)
case HISTORY_UNDERLINE:
case HISTORY_STRIKETHROUGH:
case HISTORY_WRAP:
- printf (" from %d to %d ;\n", event->data.style.from, event->data.style.to);
+ printf (" from %d to %d\n", event->data.style.from, event->data.style.to);
break;
case HISTORY_PASTE:
case HISTORY_PASTE_AS_TEXT:
case HISTORY_PASTE_QUOTED:
case HISTORY_INSERT_HTML:
- printf (" pasting: '%s' ; \n", event->data.string.to);
+ printf (" pasting: '%s' \n", event->data.string.to);
break;
case HISTORY_HRULE_DIALOG:
case HISTORY_IMAGE_DIALOG:
@@ -178,7 +186,7 @@ print_history_event (EEditorHistoryEvent *event)
case HISTORY_FONT_COLOR:
case HISTORY_REPLACE:
case HISTORY_REPLACE_ALL:
- printf (" from '%s' to '%s';\n", event->data.string.from, event->data.string.to);
+ printf (" from '%s' to '%s'\n", event->data.string.from, event->data.string.to);
break;
case HISTORY_START:
printf (" HISTORY START\n");
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]