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

Side by Side Diff: ppapi/tests/test_flash_fullscreen.cc

Issue 8982006: Add GetLiveVars to PPB_Testing_Dev. Fix leaks it uncovered. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merged Created 9 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 | Annotate | Revision Log
« no previous file with comments | « ppapi/tests/test_file_system.cc ('k') | ppapi/tests/test_fullscreen.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #include "ppapi/tests/test_flash_fullscreen.h" 5 #include "ppapi/tests/test_flash_fullscreen.h"
6 6
7 #include <stdio.h> 7 #include <stdio.h>
8 #include <string.h> 8 #include <string.h>
9 #include <string> 9 #include <string>
10 10
(...skipping 28 matching lines...) Expand all
39 : TestCase(instance), 39 : TestCase(instance),
40 screen_mode_(instance), 40 screen_mode_(instance),
41 fullscreen_pending_(false), 41 fullscreen_pending_(false),
42 normal_pending_(false), 42 normal_pending_(false),
43 fullscreen_callback_(instance->pp_instance()), 43 fullscreen_callback_(instance->pp_instance()),
44 normal_callback_(instance->pp_instance()) { 44 normal_callback_(instance->pp_instance()) {
45 screen_mode_.GetScreenSize(&screen_size_); 45 screen_mode_.GetScreenSize(&screen_size_);
46 } 46 }
47 47
48 bool TestFlashFullscreen::Init() { 48 bool TestFlashFullscreen::Init() {
49 return InitTestingInterface(); 49 return CheckTestingInterface();
50 } 50 }
51 51
52 void TestFlashFullscreen::RunTests(const std::string& filter) { 52 void TestFlashFullscreen::RunTests(const std::string& filter) {
53 RUN_TEST(GetScreenSize, filter); 53 RUN_TEST(GetScreenSize, filter);
54 RUN_TEST(NormalToFullscreenToNormal, filter); 54 RUN_TEST(NormalToFullscreenToNormal, filter);
55 } 55 }
56 56
57 std::string TestFlashFullscreen::TestGetScreenSize() { 57 std::string TestFlashFullscreen::TestGetScreenSize() {
58 if (screen_size_.width() < 320 || screen_size_.width() > 2560) 58 if (screen_size_.width() < 320 || screen_size_.width() > 2560)
59 return ReportError("screen_size.width()", screen_size_.width()); 59 return ReportError("screen_size.width()", screen_size_.width());
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
136 if (fullscreen_pending_ && IsFullscreenView(position, clip, screen_size_)) { 136 if (fullscreen_pending_ && IsFullscreenView(position, clip, screen_size_)) {
137 fullscreen_pending_ = false; 137 fullscreen_pending_ = false;
138 pp::Module::Get()->core()->CallOnMainThread(0, fullscreen_callback_); 138 pp::Module::Get()->core()->CallOnMainThread(0, fullscreen_callback_);
139 } else if (normal_pending_ && 139 } else if (normal_pending_ &&
140 !IsFullscreenView(position, clip, screen_size_)) { 140 !IsFullscreenView(position, clip, screen_size_)) {
141 normal_pending_ = false; 141 normal_pending_ = false;
142 if (testing_interface_->IsOutOfProcess()) 142 if (testing_interface_->IsOutOfProcess())
143 pp::Module::Get()->core()->CallOnMainThread(0, normal_callback_); 143 pp::Module::Get()->core()->CallOnMainThread(0, normal_callback_);
144 } 144 }
145 } 145 }
OLDNEW
« no previous file with comments | « ppapi/tests/test_file_system.cc ('k') | ppapi/tests/test_fullscreen.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698