Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1030)

Unified Diff: Source/core/html/ime/Composition.h

Issue 23604053: Implement Composition interface for IME API (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: consistent quotation usage in layouttest html. Created 7 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/core/html/ime/Composition.h
diff --git a/Source/core/html/ime/Composition.h b/Source/core/html/ime/Composition.h
index a180c867ee04b86b3d343b4a05b3ef05f78ae4ab..0069969dbdb6fafef288c5a6499fa3f9613b79e4 100644
--- a/Source/core/html/ime/Composition.h
+++ b/Source/core/html/ime/Composition.h
@@ -39,29 +39,22 @@
namespace WebCore {
+class InputMethodContext;
+
class Composition : public RefCounted<Composition>, public ScriptWrappable {
public:
- static PassRefPtr<Composition> create();
+ static PassRefPtr<Composition> create(InputMethodContext*);
~Composition();
- String text() const { return m_text; }
- void setText(const String& text) { m_text = text; }
-
- int selectionStart() const { return m_selectionStart; }
- void setSelectionStart(int selectionStart) { selectionStart = m_selectionStart; }
-
- int selectionEnd() const { return m_selectionEnd; }
- void setSelectionEnd(int selectionEnd) { selectionEnd = m_selectionEnd; }
-
+ String text() const;
+ int selectionStart() const;
+ int selectionEnd() const;
const Vector<unsigned>& getSegments() const;
private:
- Composition();
+ explicit Composition(InputMethodContext*);
- String m_text;
- int m_selectionStart;
- int m_selectionEnd;
- Vector<unsigned> m_segments;
+ InputMethodContext* m_inputMethodContext;
};
} // namespace WebCore
« no previous file with comments | « LayoutTests/fast/ime/inputmethodcontext-composition-expected.txt ('k') | Source/core/html/ime/Composition.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698