OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2009 Google Inc. All rights reserved. | 2 * Copyright (C) 2009 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
60 class WebPerformance; | 60 class WebPerformance; |
61 class WebRange; | 61 class WebRange; |
62 class WebSecurityOrigin; | 62 class WebSecurityOrigin; |
63 class WebString; | 63 class WebString; |
64 class WebURL; | 64 class WebURL; |
65 class WebURLLoader; | 65 class WebURLLoader; |
66 class WebURLRequest; | 66 class WebURLRequest; |
67 class WebView; | 67 class WebView; |
68 struct WebConsoleMessage; | 68 struct WebConsoleMessage; |
69 struct WebFindOptions; | 69 struct WebFindOptions; |
| 70 struct WebPoint; |
70 struct WebRect; | 71 struct WebRect; |
71 struct WebScriptSource; | 72 struct WebScriptSource; |
72 struct WebSize; | 73 struct WebSize; |
73 template <typename T> class WebVector; | 74 template <typename T> class WebVector; |
74 | 75 |
75 // FIXME(jam): take this out once Chromium has this | 76 // FIXME(jam): take this out once Chromium has this |
76 #define WEBFRAME_PRINTBEGIN_TAKES_NODE | 77 #define WEBFRAME_PRINTBEGIN_TAKES_NODE |
77 | 78 |
78 class WebFrame { | 79 class WebFrame { |
79 public: | 80 public: |
(...skipping 292 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
372 virtual void replaceSelection(const WebString& text) = 0; | 373 virtual void replaceSelection(const WebString& text) = 0; |
373 | 374 |
374 virtual void insertText(const WebString& text) = 0; | 375 virtual void insertText(const WebString& text) = 0; |
375 | 376 |
376 virtual void setMarkedText(const WebString& text, unsigned location, unsigne
d length) = 0; | 377 virtual void setMarkedText(const WebString& text, unsigned location, unsigne
d length) = 0; |
377 virtual void unmarkText() = 0; | 378 virtual void unmarkText() = 0; |
378 virtual bool hasMarkedText() const = 0; | 379 virtual bool hasMarkedText() const = 0; |
379 | 380 |
380 virtual WebRange markedRange() const = 0; | 381 virtual WebRange markedRange() const = 0; |
381 | 382 |
| 383 // Returns the frame rectangle in window coordinate space of the given text |
| 384 // range. |
382 virtual bool firstRectForCharacterRange(unsigned location, unsigned length,
WebRect&) const = 0; | 385 virtual bool firstRectForCharacterRange(unsigned location, unsigned length,
WebRect&) const = 0; |
383 | 386 |
| 387 // Returns the index of a character in the Frame's text stream at the given |
| 388 // point. The point is in the window coordinate space. Will return |
| 389 // WTF::notFound if the point is invalid. |
| 390 virtual unsigned characterIndexForPoint(const WebPoint&) const = 0; |
| 391 |
384 // Supports commands like Undo, Redo, Cut, Copy, Paste, SelectAll, | 392 // Supports commands like Undo, Redo, Cut, Copy, Paste, SelectAll, |
385 // Unselect, etc. See EditorCommand.cpp for the full list of supported | 393 // Unselect, etc. See EditorCommand.cpp for the full list of supported |
386 // commands. | 394 // commands. |
387 virtual bool executeCommand(const WebString&) = 0; | 395 virtual bool executeCommand(const WebString&) = 0; |
388 virtual bool executeCommand(const WebString&, const WebString& value) = 0; | 396 virtual bool executeCommand(const WebString&, const WebString& value) = 0; |
389 virtual bool isCommandEnabled(const WebString&) const = 0; | 397 virtual bool isCommandEnabled(const WebString&) const = 0; |
390 | 398 |
391 // Spell-checking support. | 399 // Spell-checking support. |
392 virtual void enableContinuousSpellChecking(bool) = 0; | 400 virtual void enableContinuousSpellChecking(bool) = 0; |
393 virtual bool isContinuousSpellCheckingEnabled() const = 0; | 401 virtual bool isContinuousSpellCheckingEnabled() const = 0; |
(...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
580 // text form. This is used only by layout tests. | 588 // text form. This is used only by layout tests. |
581 virtual WebString layerTreeAsText() const = 0; | 589 virtual WebString layerTreeAsText() const = 0; |
582 | 590 |
583 protected: | 591 protected: |
584 ~WebFrame() { } | 592 ~WebFrame() { } |
585 }; | 593 }; |
586 | 594 |
587 } // namespace WebKit | 595 } // namespace WebKit |
588 | 596 |
589 #endif | 597 #endif |
OLD | NEW |