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

Side by Side Diff: sky/engine/public/web/WebWidgetClient.h

Issue 770223002: Remove lots of code from the WebWidget/WebView/WebFrame layer. (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years 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 unified diff | Download patch
OLDNEW
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 115 matching lines...) Expand 10 before | Expand all | Expand 10 after
126 // displayed. 126 // displayed.
127 virtual WebScreenInfo screenInfo() { return WebScreenInfo(); } 127 virtual WebScreenInfo screenInfo() { return WebScreenInfo(); }
128 128
129 // Called to get the scale factor of the display. 129 // Called to get the scale factor of the display.
130 virtual float deviceScaleFactor() { return 1; } 130 virtual float deviceScaleFactor() { return 1; }
131 131
132 // When this method gets called, WebWidgetClient implementation should 132 // When this method gets called, WebWidgetClient implementation should
133 // reset the input method by cancelling any ongoing composition. 133 // reset the input method by cancelling any ongoing composition.
134 virtual void resetInputMethod() { } 134 virtual void resetInputMethod() { }
135 135
136 // Requests to lock the mouse cursor. If true is returned, the success
137 // result will be asynchronously returned via a single call to
138 // WebWidget::didAcquirePointerLock() or
139 // WebWidget::didNotAcquirePointerLock().
140 // If false, the request has been denied synchronously.
141 virtual bool requestPointerLock() { return false; }
142
143 // Cause the pointer lock to be released. This may be called at any time,
144 // including when a lock is pending but not yet acquired.
145 // WebWidget::didLosePointerLock() is called when unlock is complete.
146 virtual void requestPointerUnlock() { }
147
148 // Returns true iff the pointer is locked to this widget.
149 virtual bool isPointerLocked() { return false; }
150
151 // Called when a gesture event is handled. 136 // Called when a gesture event is handled.
152 virtual void didHandleGestureEvent(const WebGestureEvent& event, bool eventC ancelled) { } 137 virtual void didHandleGestureEvent(const WebGestureEvent& event, bool eventC ancelled) { }
153 138
154 // Called during WebWidget::HandleInputEvent for a TouchStart event to infor m the embedder 139 // Called during WebWidget::HandleInputEvent for a TouchStart event to infor m the embedder
155 // of the touch actions that are permitted for this touch. 140 // of the touch actions that are permitted for this touch.
156 virtual void setTouchAction(WebTouchAction touchAction) { } 141 virtual void setTouchAction(WebTouchAction touchAction) { }
157 142
158 // 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
159 // modified by script, not by user input. 144 // modified by script, not by user input.
160 virtual void didUpdateTextOfFocusedElementByNonUserInput() { } 145 virtual void didUpdateTextOfFocusedElementByNonUserInput() { }
161 146
162 // Request the browser to show the IME for current input type. 147 // Request the browser to show the IME for current input type.
163 virtual void showImeIfNeeded() { } 148 virtual void showImeIfNeeded() { }
164 149
165 protected: 150 protected:
166 ~WebWidgetClient() { } 151 ~WebWidgetClient() { }
167 }; 152 };
168 153
169 } // namespace blink 154 } // namespace blink
170 155
171 #endif // SKY_ENGINE_PUBLIC_WEB_WEBWIDGETCLIENT_H_ 156 #endif // SKY_ENGINE_PUBLIC_WEB_WEBWIDGETCLIENT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698