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 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
58 // Called when a region of the WebWidget needs to be re-painted. | 58 // Called when a region of the WebWidget needs to be re-painted. |
59 virtual void didInvalidateRect(const WebRect&) {} | 59 virtual void didInvalidateRect(const WebRect&) {} |
60 | 60 |
61 // Attempt to initialize compositing for this widget. If this is successful, | 61 // Attempt to initialize compositing for this widget. If this is successful, |
62 // layerTreeView() will return a valid WebLayerTreeView. | 62 // layerTreeView() will return a valid WebLayerTreeView. |
63 virtual void initializeLayerTreeView() {} | 63 virtual void initializeLayerTreeView() {} |
64 | 64 |
65 // Return a compositing view used for this widget. This is owned by the | 65 // Return a compositing view used for this widget. This is owned by the |
66 // WebWidgetClient. | 66 // WebWidgetClient. |
67 virtual WebLayerTreeView* layerTreeView() { return 0; } | 67 virtual WebLayerTreeView* layerTreeView() { return 0; } |
68 // FIXME: Remove all overrides of this and change layerTreeView() above to ASS
ERT_NOT_REACHED. | 68 // FIXME: Remove all overrides of this and change layerTreeView() above to |
| 69 // ASSERT_NOT_REACHED. |
69 virtual bool allowsBrokenNullLayerTreeView() const { return false; } | 70 virtual bool allowsBrokenNullLayerTreeView() const { return false; } |
70 | 71 |
71 // Called when a call to WebWidget::animate is required | 72 // Called when a call to WebWidget::animate is required |
72 virtual void scheduleAnimation() {} | 73 virtual void scheduleAnimation() {} |
73 | 74 |
74 // Called immediately following the first compositor-driven (frame-generating)
layout that | 75 // Called immediately following the first compositor-driven (frame-generating) |
75 // happened after an interesting document lifecyle change (see WebMeaningfulLa
yout for details.) | 76 // layout that happened after an interesting document lifecyle change (see |
| 77 // WebMeaningfulLayout for details.) |
76 virtual void didMeaningfulLayout(WebMeaningfulLayout) {} | 78 virtual void didMeaningfulLayout(WebMeaningfulLayout) {} |
77 | 79 |
78 virtual void didFirstLayoutAfterFinishedParsing() {} | 80 virtual void didFirstLayoutAfterFinishedParsing() {} |
79 | 81 |
80 // Called when the cursor for the widget changes. | 82 // Called when the cursor for the widget changes. |
81 virtual void didChangeCursor(const WebCursorInfo&) {} | 83 virtual void didChangeCursor(const WebCursorInfo&) {} |
82 | 84 |
83 // Called when the widget should be closed. WebWidget::close() should | 85 // Called when the widget should be closed. WebWidget::close() should |
84 // be called asynchronously as a result of this notification. | 86 // be called asynchronously as a result of this notification. |
85 virtual void closeWidgetSoon() {} | 87 virtual void closeWidgetSoon() {} |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
127 // Called when overscrolled on main thread. All parameters are in | 129 // Called when overscrolled on main thread. All parameters are in |
128 // viewport-space. | 130 // viewport-space. |
129 virtual void didOverscroll(const WebFloatSize& overscrollDelta, | 131 virtual void didOverscroll(const WebFloatSize& overscrollDelta, |
130 const WebFloatSize& accumulatedOverscroll, | 132 const WebFloatSize& accumulatedOverscroll, |
131 const WebFloatPoint& positionInViewport, | 133 const WebFloatPoint& positionInViewport, |
132 const WebFloatSize& velocityInViewport) {} | 134 const WebFloatSize& velocityInViewport) {} |
133 | 135 |
134 // Called to update if touch events should be sent. | 136 // Called to update if touch events should be sent. |
135 virtual void hasTouchEventHandlers(bool) {} | 137 virtual void hasTouchEventHandlers(bool) {} |
136 | 138 |
137 // Called during WebWidget::HandleInputEvent for a TouchStart event to inform
the embedder | 139 // Called during WebWidget::HandleInputEvent for a TouchStart event to inform |
138 // of the touch actions that are permitted for this touch. | 140 // the embedder of the touch actions that are permitted for this touch. |
139 virtual void setTouchAction(WebTouchAction touchAction) {} | 141 virtual void setTouchAction(WebTouchAction touchAction) {} |
140 | 142 |
141 // Called when value of focused text field gets dirty, e.g. value is | 143 // Called when value of focused text field gets dirty, e.g. value is |
142 // modified by script, not by user input. | 144 // modified by script, not by user input. |
143 virtual void didUpdateTextOfFocusedElementByNonUserInput() {} | 145 virtual void didUpdateTextOfFocusedElementByNonUserInput() {} |
144 | 146 |
145 // Request the browser to show the IME for current input type. | 147 // Request the browser to show the IME for current input type. |
146 virtual void showImeIfNeeded() {} | 148 virtual void showImeIfNeeded() {} |
147 | 149 |
148 // Request that the browser show a UI for an unhandled tap, if needed. | 150 // Request that the browser show a UI for an unhandled tap, if needed. |
(...skipping 27 matching lines...) Expand all Loading... |
176 // migration is completed. | 178 // migration is completed. |
177 virtual void convertWindowToViewport(WebFloatRect* rect) {} | 179 virtual void convertWindowToViewport(WebFloatRect* rect) {} |
178 | 180 |
179 protected: | 181 protected: |
180 ~WebWidgetClient() {} | 182 ~WebWidgetClient() {} |
181 }; | 183 }; |
182 | 184 |
183 } // namespace blink | 185 } // namespace blink |
184 | 186 |
185 #endif | 187 #endif |
OLD | NEW |