Index: Source/core/editing/DragCaretController.h |
diff --git a/Source/modules/filesystem/WorkerGlobalScopeFileSystem.h b/Source/core/editing/DragCaretController.h |
similarity index 54% |
copy from Source/modules/filesystem/WorkerGlobalScopeFileSystem.h |
copy to Source/core/editing/DragCaretController.h |
index 84a0d0f875dba8b3658f0194dfa2a514600d7f8b..c48c8046b704cee3b8972ed7aa6cc7c077fa4718 100644 |
--- a/Source/modules/filesystem/WorkerGlobalScopeFileSystem.h |
+++ b/Source/core/editing/DragCaretController.h |
@@ -1,5 +1,5 @@ |
/* |
tkent
2015/07/13 08:20:53
Couldn't you find --similarity= value so that this
yosin_UTC9
2015/07/13 12:20:06
It seems --similarity doesn't help this.
I commite
|
- * Copyright (C) 2008, 2009 Apple Inc. All rights reserved. |
+ * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserved. |
* |
* Redistribution and use in source and binary forms, with or without |
* modification, are permitted provided that the following conditions |
@@ -21,41 +21,42 @@ |
* 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. |
- * |
*/ |
-#ifndef WorkerGlobalScopeFileSystem_h |
-#define WorkerGlobalScopeFileSystem_h |
+#ifndef DragCaretController_h |
+#define DragCaretController_h |
-#include "modules/filesystem/DOMFileSystemSync.h" |
-#include "platform/heap/Handle.h" |
+#include "core/editing/Caret.h" |
namespace blink { |
-class EntryCallback; |
-class EntrySync; |
-class ErrorCallback; |
-class ExceptionState; |
-class FileSystemCallback; |
-class WorkerGlobalScope; |
- |
-class WorkerGlobalScopeFileSystem { |
+class DragCaretController final : public NoBaseWillBeGarbageCollected<DragCaretController>, private CaretBase { |
+ WTF_MAKE_NONCOPYABLE(DragCaretController); |
+ WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED(DragCaretController); |
public: |
- enum { |
- TEMPORARY, |
- PERSISTENT, |
- }; |
+ static PassOwnPtrWillBeRawPtr<DragCaretController> create(); |
+ |
+ LayoutBlock* caretLayoutObject() const { return CaretBase::caretPainter(); } |
+ void paintDragCaret(LocalFrame*, GraphicsContext*, const LayoutPoint&, const LayoutRect& clipRect) const; |
+ |
+ bool isContentEditable() const { return m_position.rootEditableElement(); } |
+ bool isContentRichlyEditable() const; |
- static void webkitRequestFileSystem(WorkerGlobalScope&, int type, long long size, FileSystemCallback* successCallback, ErrorCallback*); |
- static DOMFileSystemSync* webkitRequestFileSystemSync(WorkerGlobalScope&, int type, long long size, ExceptionState&); |
- static void webkitResolveLocalFileSystemURL(WorkerGlobalScope&, const String& url, EntryCallback* successCallback, ErrorCallback*); |
- static EntrySync* webkitResolveLocalFileSystemSyncURL(WorkerGlobalScope&, const String& url, ExceptionState&); |
+ bool hasCaret() const { return m_position.isNotNull(); } |
+ const VisiblePosition& caretPosition() { return m_position; } |
+ void setCaretPosition(const VisiblePosition&); |
+ void clear() { setCaretPosition(VisiblePosition()); } |
+ |
+ void nodeWillBeRemoved(Node&); |
+ |
+ DECLARE_TRACE(); |
private: |
- WorkerGlobalScopeFileSystem(); |
- ~WorkerGlobalScopeFileSystem(); |
+ DragCaretController(); |
+ |
+ VisiblePosition m_position; |
}; |
} // namespace blink |
-#endif // WorkerGlobalScopeFileSystem_h |
+#endif // DragCaretController_h |