Remove Chromium code from WebCore/editing
authorrniwa@webkit.org <rniwa@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 5 Apr 2013 08:02:32 +0000 (08:02 +0000)
committerrniwa@webkit.org <rniwa@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 5 Apr 2013 08:02:32 +0000 (08:02 +0000)
https://bugs.webkit.org/show_bug.cgi?id=114008

Reviewed by Benjamin Poulain.

Removed.

* editing/EditingBehavior.h:
(WebCore::EditingBehavior::shouldAllowSpellingSuggestionsWithoutSelection):
* editing/FrameSelection.h:
(WebCore):
* editing/chromium: Removed.
* editing/chromium/EditorChromium.cpp: Removed.
* editing/chromium/FrameSelectionChromium.cpp: Removed.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@147721 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/ChangeLog
Source/WebCore/editing/EditingBehavior.h
Source/WebCore/editing/FrameSelection.h
Source/WebCore/editing/chromium/EditorChromium.cpp [deleted file]
Source/WebCore/editing/chromium/FrameSelectionChromium.cpp [deleted file]

index 2114646..b0239d2 100644 (file)
@@ -1,3 +1,20 @@
+2013-04-05  Ryosuke Niwa  <rniwa@webkit.org>
+
+        Remove Chromium code from WebCore/editing
+        https://bugs.webkit.org/show_bug.cgi?id=114008
+
+        Reviewed by Benjamin Poulain.
+
+        Removed.
+
+        * editing/EditingBehavior.h:
+        (WebCore::EditingBehavior::shouldAllowSpellingSuggestionsWithoutSelection):
+        * editing/FrameSelection.h:
+        (WebCore):
+        * editing/chromium: Removed.
+        * editing/chromium/EditorChromium.cpp: Removed.
+        * editing/chromium/FrameSelectionChromium.cpp: Removed.
+
 2013-04-05  Benjamin Poulain  <benjamin@webkit.org>
 
         Remove the chromium code from the filesystem module
index 36b8956..5e7ba50 100644 (file)
@@ -64,14 +64,9 @@ public:
     bool shouldSelectOnContextualMenuClick() const { return m_type == EditingMacBehavior; }
 
     // On Linux, should be able to get and insert spelling suggestions without selecting the misspelled word.
-    // Skip this policy for Chromium, they require selection for the misspelled word.
     bool shouldAllowSpellingSuggestionsWithoutSelection() const
     {
-#if !PLATFORM(CHROMIUM)
         return m_type == EditingUnixBehavior || m_type == EditingAndroidBehavior;
-#else
-        return false;
-#endif
     }
     
     // On Mac and Windows, pressing backspace (when it isn't handled otherwise) should navigate back.
index 1fe0472..201e806 100644 (file)
@@ -329,7 +329,7 @@ inline void FrameSelection::setTypingStyle(PassRefPtr<EditingStyle> style)
     m_typingStyle = style;
 }
 
-#if !(PLATFORM(MAC) || PLATFORM(GTK) || PLATFORM(CHROMIUM) || PLATFORM(EFL))
+#if !(PLATFORM(MAC) || PLATFORM(GTK) || PLATFORM(EFL))
 inline void FrameSelection::notifyAccessibilityForSelectionChange()
 {
 }
diff --git a/Source/WebCore/editing/chromium/EditorChromium.cpp b/Source/WebCore/editing/chromium/EditorChromium.cpp
deleted file mode 100644 (file)
index 0c630a2..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * Copyright (c) 2008, 2009, Google Inc. All rights reserved.
- * 
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are
- * met:
- * 
- *     * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *     * Redistributions in binary form must reproduce the above
- * copyright notice, this list of conditions and the following disclaimer
- * in the documentation and/or other materials provided with the
- * distribution.
- *     * Neither the name of Google Inc. nor the names of its
- * contributors may be used to endorse or promote products derived from
- * this software without specific prior written permission.
- * 
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
- * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#include "config.h"
-#include "Editor.h"
-
-#include "ChromiumDataObject.h"
-#include "ClipboardChromium.h"
-#include "Frame.h"
-
-namespace WebCore {
-
-PassRefPtr<Clipboard> Editor::newGeneralClipboard(ClipboardAccessPolicy policy, Frame* frame)
-{
-    return ClipboardChromium::create(
-        Clipboard::CopyAndPaste,
-        policy == ClipboardWritable ? ChromiumDataObject::create() : ChromiumDataObject::createFromPasteboard(),
-        policy,
-        frame);
-
-}
-
-} // namespace WebCore
diff --git a/Source/WebCore/editing/chromium/FrameSelectionChromium.cpp b/Source/WebCore/editing/chromium/FrameSelectionChromium.cpp
deleted file mode 100644 (file)
index 2ef7bdf..0000000
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * Copyright (C) 2010 Google Inc. All rights reserved.
- * 
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are
- * met:
- * 
- *     * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *     * Redistributions in binary form must reproduce the above
- * copyright notice, this list of conditions and the following disclaimer
- * in the documentation and/or other materials provided with the
- * distribution.
- *     * Neither the name of Google Inc. nor the names of its
- * contributors may be used to endorse or promote products derived from
- * this software without specific prior written permission.
- * 
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
- * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#include "config.h"
-#include "FrameSelection.h"
-
-#include "AXObjectCache.h"
-#include "Document.h"
-#include "Frame.h"
-
-namespace WebCore {
-
-void FrameSelection::notifyAccessibilityForSelectionChange()
-{
-    // FIXME: Support editable text in chromium.
-    if (m_selection.start().isNotNull() && m_selection.end().isNotNull()) {
-        if (AXObjectCache* cache = m_frame->document()->existingAXObjectCache())
-            cache->postNotification(m_selection.start().deprecatedNode(), AXObjectCache::AXSelectedTextChanged, false);
-    }
-}
-
-} // namespace WebCore