Patch proposal for Docomo 1339 bug.
authorWojciech Bielawski <w.bielawski@samsung.com>
Thu, 2 May 2013 11:56:49 +0000 (13:56 +0200)
committerGerrit Code Review <gerrit2@kim11>
Mon, 6 May 2013 11:51:31 +0000 (20:51 +0900)
Change-Id: I4f0fcb14361f8e80736507868f8c7d17c374b3fa

Source/WTF/wtf/Platform.h
Source/WebCore/editing/ReplaceSelectionCommand.cpp

index b856177..538ba03 100644 (file)
 #define ENABLE_TIZEN_DRAW_SCALED_PATTERN 1 /* Kyungjin Kim(gen.kim@samsung.com) : Scale image prior to draw it's pattern to enhance performance */
 #define ENABLE_TIZEN_PAINT_SELECTION_ANTIALIAS_NONE 1 /* Hyeonji Kim(hyeonji.kim@samsung.com) : Remove the line between the preceding text block and the next text block which are selected */
 #define ENABLE_TIZEN_USE_SETTINGS_FONT 1 /* Hyeonji Kim(hyeonji.kim@samsung.com) : When font-family is "Tizen", use system's setting font as default font-family */
+#define ENABLE_TIZEN_CONTENT_EDITABLE_BACKSPACE 1 /* Wojciech Bielawski(w.bielawski.com) : This is a quick fix for a bug where after pressing backspace image was moved not correctly */
 
 #if ENABLE(TEXT_AUTOSIZING)
 #define ENABLE_TIZEN_TEXT_AUTOSIZING 1 /* Jaehun Lim(ljaehun.lim@samsung.com) : for Tizen environment */
index 60772e8..39627a8 100644 (file)
@@ -935,7 +935,9 @@ void ReplaceSelectionCommand::doApply()
                 if (!splitStart)
                     splitStart = insertionPos.containerNode();
                 nodeToSplitTo = splitTreeToNode(splitStart, nodeToSplitTo->parentNode()).get();
-                insertionPos = positionInParentBeforeNode(nodeToSplitTo.get());
+#if !ENABLE(ENABLE_TIZEN_CONTENT_EDITABLE_BACKSPACE)
+                 insertionPos = positionInParentBeforeNode(nodeToSplitTo.get());
+#endif
             }
         }
     }