| OLD | NEW |
| 1 | |
| 2 /* | 1 /* |
| 3 * Copyright (C) 2009 Google Inc. All rights reserved. | 2 * Copyright (C) 2009 Google Inc. All rights reserved. |
| 4 * | 3 * |
| 5 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 7 * met: | 6 * met: |
| 8 * | 7 * |
| 9 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 10 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 11 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 26 matching lines...) Expand all Loading... |
| 38 #include "../platform/WebFrameTimingEvent.h" | 37 #include "../platform/WebFrameTimingEvent.h" |
| 39 #include "../platform/WebInputEventResult.h" | 38 #include "../platform/WebInputEventResult.h" |
| 40 #include "../platform/WebPoint.h" | 39 #include "../platform/WebPoint.h" |
| 41 #include "../platform/WebRect.h" | 40 #include "../platform/WebRect.h" |
| 42 #include "../platform/WebSize.h" | 41 #include "../platform/WebSize.h" |
| 43 #include "../platform/WebTopControlsState.h" | 42 #include "../platform/WebTopControlsState.h" |
| 44 #include "WebCompositionUnderline.h" | 43 #include "WebCompositionUnderline.h" |
| 45 #include "WebTextDirection.h" | 44 #include "WebTextDirection.h" |
| 46 #include "WebTextInputInfo.h" | 45 #include "WebTextInputInfo.h" |
| 47 | 46 |
| 47 #include <map> |
| 48 |
| 48 namespace blink { | 49 namespace blink { |
| 49 | 50 |
| 50 class WebCompositeAndReadbackAsyncCallback; | 51 class WebCompositeAndReadbackAsyncCallback; |
| 51 class WebInputEvent; | 52 class WebInputEvent; |
| 52 class WebLayoutAndPaintAsyncCallback; | 53 class WebLayoutAndPaintAsyncCallback; |
| 53 class WebPagePopup; | 54 class WebPagePopup; |
| 54 class WebString; | 55 class WebString; |
| 56 struct WebCompositorMutations; |
| 55 struct WebPoint; | 57 struct WebPoint; |
| 56 template <typename T> class WebVector; | 58 template <typename T> class WebVector; |
| 57 | 59 |
| 58 class WebWidget { | 60 class WebWidget { |
| 59 public: | 61 public: |
| 60 // This method closes and deletes the WebWidget. | 62 // This method closes and deletes the WebWidget. |
| 61 virtual void close() { } | 63 virtual void close() { } |
| 62 | 64 |
| 63 // Returns the current size of the WebWidget. | 65 // Returns the current size of the WebWidget. |
| 64 virtual WebSize size() { return WebSize(); } | 66 virtual WebSize size() { return WebSize(); } |
| (...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 141 float topControlsShownRatioDelta) { } | 143 float topControlsShownRatioDelta) { } |
| 142 | 144 |
| 143 // Records composite or render events for the Performance Timeline. | 145 // Records composite or render events for the Performance Timeline. |
| 144 // See http://w3c.github.io/frame-timing/ for definition of terms. | 146 // See http://w3c.github.io/frame-timing/ for definition of terms. |
| 145 enum FrameTimingEventType { | 147 enum FrameTimingEventType { |
| 146 CompositeEvent, | 148 CompositeEvent, |
| 147 RenderEvent, | 149 RenderEvent, |
| 148 }; | 150 }; |
| 149 virtual void recordFrameTimingEvent(FrameTimingEventType eventType, int64_t
RectId, const WebVector<WebFrameTimingEvent>& events) { } | 151 virtual void recordFrameTimingEvent(FrameTimingEventType eventType, int64_t
RectId, const WebVector<WebFrameTimingEvent>& events) { } |
| 150 | 152 |
| 153 // Called to notify the WebWidget about the mutations made to the elements f
rom a compositor worker. |
| 154 virtual void applyMutations(const WebCompositorMutations&) {} |
| 155 |
| 156 // Called to notify the WebWidget that a commit has completed so that post |
| 157 // commit work can be initiated. |
| 158 virtual void didCommit() { } |
| 159 |
| 151 // Called to inform the WebWidget that mouse capture was lost. | 160 // Called to inform the WebWidget that mouse capture was lost. |
| 152 virtual void mouseCaptureLost() { } | 161 virtual void mouseCaptureLost() { } |
| 153 | 162 |
| 154 // Called to inform the WebWidget that it has gained or lost keyboard focus. | 163 // Called to inform the WebWidget that it has gained or lost keyboard focus. |
| 155 virtual void setFocus(bool) { } | 164 virtual void setFocus(bool) { } |
| 156 | 165 |
| 157 // Called to inform the WebWidget of a new composition text. | 166 // Called to inform the WebWidget of a new composition text. |
| 158 // If selectionStart and selectionEnd has the same value, then it indicates | 167 // If selectionStart and selectionEnd has the same value, then it indicates |
| 159 // the input caret position. If the text is empty, then the existing | 168 // the input caret position. If the text is empty, then the existing |
| 160 // composition text will be cancelled. | 169 // composition text will be cancelled. |
| (...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 264 // control what are valid states for top controls and if it should animate. | 273 // control what are valid states for top controls and if it should animate. |
| 265 virtual void updateTopControlsState(WebTopControlsState constraints, WebTopC
ontrolsState current, bool animate) { } | 274 virtual void updateTopControlsState(WebTopControlsState constraints, WebTopC
ontrolsState current, bool animate) { } |
| 266 | 275 |
| 267 protected: | 276 protected: |
| 268 ~WebWidget() { } | 277 ~WebWidget() { } |
| 269 }; | 278 }; |
| 270 | 279 |
| 271 } // namespace blink | 280 } // namespace blink |
| 272 | 281 |
| 273 #endif | 282 #endif |
| OLD | NEW |