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

Side by Side Diff: webkit/tools/test_shell/test_webview_delegate.h

Issue 5363002: Revert 67248 - TestShell: Backported EventSender.contextClick() improvement t... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 10 years, 1 month 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // TestWebViewDelegate class: 5 // TestWebViewDelegate class:
6 // This class implements the WebViewDelegate methods for the test shell. One 6 // This class implements the WebViewDelegate methods for the test shell. One
7 // instance is owned by each TestShell. 7 // instance is owned by each TestShell.
8 8
9 #ifndef WEBKIT_TOOLS_TEST_SHELL_TEST_WEBVIEW_DELEGATE_H_ 9 #ifndef WEBKIT_TOOLS_TEST_SHELL_TEST_WEBVIEW_DELEGATE_H_
10 #define WEBKIT_TOOLS_TEST_SHELL_TEST_WEBVIEW_DELEGATE_H_ 10 #define WEBKIT_TOOLS_TEST_SHELL_TEST_WEBVIEW_DELEGATE_H_
(...skipping 307 matching lines...) Expand 10 before | Expand all | Expand 10 after
318 edit_command_value_ = value; 318 edit_command_value_ = value;
319 } 319 }
320 320
321 void ClearEditCommand() { 321 void ClearEditCommand() {
322 edit_command_name_.clear(); 322 edit_command_name_.clear();
323 edit_command_value_.clear(); 323 edit_command_value_.clear();
324 } 324 }
325 325
326 void SetGeolocationPermission(bool allowed); 326 void SetGeolocationPermission(bool allowed);
327 327
328 void ClearContextMenuData();
329
330 const WebKit::WebContextMenuData* last_context_menu_data() const {
331 return last_context_menu_data_.get();
332 }
333
334 MockSpellCheck* mock_spellcheck() {
335 return &mock_spellcheck_;
336 }
337
338 private: 328 private:
339 329
340 // Called the title of the page changes. 330 // Called the title of the page changes.
341 // Can be used to update the title of the window. 331 // Can be used to update the title of the window.
342 void SetPageTitle(const std::wstring& title); 332 void SetPageTitle(const std::wstring& title);
343 333
344 // Called when the URL of the page changes. 334 // Called when the URL of the page changes.
345 // Extracts the URL and forwards on to SetAddressBarURL(). 335 // Extracts the URL and forwards on to SetAddressBarURL().
346 void UpdateAddressBar(WebKit::WebView* webView); 336 void UpdateAddressBar(WebKit::WebView* webView);
347 337
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
405 int last_page_id_updated_; 395 int last_page_id_updated_;
406 396
407 scoped_ptr<TestShellExtraData> pending_extra_data_; 397 scoped_ptr<TestShellExtraData> pending_extra_data_;
408 398
409 // Maps resource identifiers to a descriptive string. 399 // Maps resource identifiers to a descriptive string.
410 typedef std::map<uint32, std::string> ResourceMap; 400 typedef std::map<uint32, std::string> ResourceMap;
411 ResourceMap resource_identifier_map_; 401 ResourceMap resource_identifier_map_;
412 std::string GetResourceDescription(uint32 identifier); 402 std::string GetResourceDescription(uint32 identifier);
413 403
414 CapturedContextMenuEvents captured_context_menu_events_; 404 CapturedContextMenuEvents captured_context_menu_events_;
415 scoped_ptr<WebKit::WebContextMenuData> last_context_menu_data_;
416 405
417 WebCursor current_cursor_; 406 WebCursor current_cursor_;
418 407
419 WebKit::WebRect fake_rect_; 408 WebKit::WebRect fake_rect_;
420 bool using_fake_rect_; 409 bool using_fake_rect_;
421 410
422 #if defined(OS_WIN) 411 #if defined(OS_WIN)
423 // Classes needed by drag and drop. 412 // Classes needed by drag and drop.
424 scoped_refptr<TestDragDelegate> drag_delegate_; 413 scoped_refptr<TestDragDelegate> drag_delegate_;
425 scoped_refptr<TestDropDelegate> drop_delegate_; 414 scoped_refptr<TestDropDelegate> drop_delegate_;
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
458 447
459 // The mock spellchecker used in TestWebViewDelegate::spellCheck(). 448 // The mock spellchecker used in TestWebViewDelegate::spellCheck().
460 MockSpellCheck mock_spellcheck_; 449 MockSpellCheck mock_spellcheck_;
461 450
462 scoped_ptr<TestGeolocationService> test_geolocation_service_; 451 scoped_ptr<TestGeolocationService> test_geolocation_service_;
463 452
464 DISALLOW_COPY_AND_ASSIGN(TestWebViewDelegate); 453 DISALLOW_COPY_AND_ASSIGN(TestWebViewDelegate);
465 }; 454 };
466 455
467 #endif // WEBKIT_TOOLS_TEST_SHELL_TEST_WEBVIEW_DELEGATE_H_ 456 #endif // WEBKIT_TOOLS_TEST_SHELL_TEST_WEBVIEW_DELEGATE_H_
OLDNEW
« no previous file with comments | « webkit/tools/test_shell/mock_spellcheck.cc ('k') | webkit/tools/test_shell/test_webview_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698