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

Side by Side Diff: components/test_runner/test_runner.h

Issue 1989103006: Fix event warning crash when a listener is removed while dispatching event (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 months 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 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #ifndef COMPONENTS_TEST_RUNNER_TEST_RUNNER_H_ 5 #ifndef COMPONENTS_TEST_RUNNER_TEST_RUNNER_H_
6 #define COMPONENTS_TEST_RUNNER_TEST_RUNNER_H_ 6 #define COMPONENTS_TEST_RUNNER_TEST_RUNNER_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <deque> 10 #include <deque>
(...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after
154 void setToolTipText(const blink::WebString&); 154 void setToolTipText(const blink::WebString&);
155 void setDragImage(const blink::WebImage& drag_image); 155 void setDragImage(const blink::WebImage& drag_image);
156 bool shouldDumpNavigationPolicy() const; 156 bool shouldDumpNavigationPolicy() const;
157 157
158 bool midiAccessorResult(); 158 bool midiAccessorResult();
159 159
160 // Methods used by MockColorChooser: 160 // Methods used by MockColorChooser:
161 void DidOpenChooser(); 161 void DidOpenChooser();
162 void DidCloseChooser(); 162 void DidCloseChooser();
163 163
164 bool ShouldDumpConsoleMessages() const;
165
164 // A single item in the work queue. 166 // A single item in the work queue.
165 class WorkItem { 167 class WorkItem {
166 public: 168 public:
167 virtual ~WorkItem() {} 169 virtual ~WorkItem() {}
168 170
169 // Returns true if this started a load. 171 // Returns true if this started a load.
170 virtual bool Run(WebTestDelegate*, blink::WebView*) = 0; 172 virtual bool Run(WebTestDelegate*, blink::WebView*) = 0;
171 }; 173 };
172 174
173 private: 175 private:
(...skipping 270 matching lines...) Expand 10 before | Expand all | Expand 10 after
444 446
445 // This function sets a flag to dump the drag image when the next drag&drop is 447 // This function sets a flag to dump the drag image when the next drag&drop is
446 // initiated. It is equivalent to DumpAsTextWithPixelResults but the pixel 448 // initiated. It is equivalent to DumpAsTextWithPixelResults but the pixel
447 // results will be the drag image instead of a snapshot of the page. 449 // results will be the drag image instead of a snapshot of the page.
448 void DumpDragImage(); 450 void DumpDragImage();
449 451
450 // Sets a flag that tells the WebTestProxy to dump the default navigation 452 // Sets a flag that tells the WebTestProxy to dump the default navigation
451 // policy passed to the decidePolicyForNavigation callback. 453 // policy passed to the decidePolicyForNavigation callback.
452 void DumpNavigationPolicy(); 454 void DumpNavigationPolicy();
453 455
456 // Controls whether console messages produced by the page are dumped
457 // to test output.
458 void SetDumpConsoleMessages(bool value);
459
454 /////////////////////////////////////////////////////////////////////////// 460 ///////////////////////////////////////////////////////////////////////////
455 // Methods interacting with the WebTestProxy 461 // Methods interacting with the WebTestProxy
456 462
457 /////////////////////////////////////////////////////////////////////////// 463 ///////////////////////////////////////////////////////////////////////////
458 // Methods forwarding to the WebTestDelegate 464 // Methods forwarding to the WebTestDelegate
459 465
460 // Shows DevTools window. 466 // Shows DevTools window.
461 void ShowWebInspector(const std::string& str, 467 void ShowWebInspector(const std::string& str,
462 const std::string& frontend_url); 468 const std::string& frontend_url);
463 void CloseWebInspector(); 469 void CloseWebInspector();
(...skipping 169 matching lines...) Expand 10 before | Expand all | Expand 10 after
633 std::set<blink::WebWidget*> widgets_with_scheduled_animations_; 639 std::set<blink::WebWidget*> widgets_with_scheduled_animations_;
634 640
635 base::WeakPtrFactory<TestRunner> weak_factory_; 641 base::WeakPtrFactory<TestRunner> weak_factory_;
636 642
637 DISALLOW_COPY_AND_ASSIGN(TestRunner); 643 DISALLOW_COPY_AND_ASSIGN(TestRunner);
638 }; 644 };
639 645
640 } // namespace test_runner 646 } // namespace test_runner
641 647
642 #endif // COMPONENTS_TEST_RUNNER_TEST_RUNNER_H_ 648 #endif // COMPONENTS_TEST_RUNNER_TEST_RUNNER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698