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

Side by Side Diff: remoting/host/resizing_host_observer_unittest.cc

Issue 12813004: Chromium style checker cleanup (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased Created 7 years, 9 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 | Annotate | Revision Log
« no previous file with comments | « net/quic/test_tools/simple_quic_framer.cc ('k') | ui/compositor/compositor.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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 <list> 5 #include <list>
6 6
7 #include "base/compiler_specific.h" 7 #include "base/compiler_specific.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "remoting/host/desktop_resizer.h" 9 #include "remoting/host/desktop_resizer.h"
10 #include "remoting/host/resizing_host_observer.h" 10 #include "remoting/host/resizing_host_observer.h"
(...skipping 12 matching lines...) Expand all
23 const SkISize* supported_sizes, int num_supported_sizes) 23 const SkISize* supported_sizes, int num_supported_sizes)
24 : initial_size_(initial_size), 24 : initial_size_(initial_size),
25 current_size_(initial_size), 25 current_size_(initial_size),
26 exact_size_supported_(exact_size_supported), 26 exact_size_supported_(exact_size_supported),
27 set_size_call_count_(0) { 27 set_size_call_count_(0) {
28 for (int i = 0; i < num_supported_sizes; ++i) { 28 for (int i = 0; i < num_supported_sizes; ++i) {
29 supported_sizes_.push_back(supported_sizes[i]); 29 supported_sizes_.push_back(supported_sizes[i]);
30 } 30 }
31 } 31 }
32 32
33 ~FakeDesktopResizer() { 33 virtual ~FakeDesktopResizer() {
34 EXPECT_EQ(initial_size_, GetCurrentSize()); 34 EXPECT_EQ(initial_size_, GetCurrentSize());
35 } 35 }
36 36
37 int set_size_call_count() { return set_size_call_count_; } 37 int set_size_call_count() { return set_size_call_count_; }
38 38
39 // remoting::DesktopResizer interface 39 // remoting::DesktopResizer interface
40 virtual SkISize GetCurrentSize() OVERRIDE { 40 virtual SkISize GetCurrentSize() OVERRIDE {
41 return current_size_; 41 return current_size_;
42 } 42 }
43 virtual std::list<SkISize> GetSupportedSizes( 43 virtual std::list<SkISize> GetSupportedSizes(
(...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after
179 supported_sizes, arraysize(supported_sizes)); 179 supported_sizes, arraysize(supported_sizes));
180 SetDesktopResizer(scoped_ptr<FakeDesktopResizer>(desktop_resizer)); 180 SetDesktopResizer(scoped_ptr<FakeDesktopResizer>(desktop_resizer));
181 181
182 SkISize client_sizes[] = { { 640, 640 }, { 1024, 768 }, { 640, 480 } }; 182 SkISize client_sizes[] = { { 640, 640 }, { 1024, 768 }, { 640, 480 } };
183 SkISize expected_sizes[] = { { 640, 480 }, { 640, 480 }, { 640, 480 } }; 183 SkISize expected_sizes[] = { { 640, 480 }, { 640, 480 }, { 640, 480 } };
184 VerifySizes(client_sizes, expected_sizes, arraysize(client_sizes)); 184 VerifySizes(client_sizes, expected_sizes, arraysize(client_sizes));
185 EXPECT_EQ(desktop_resizer->set_size_call_count(), 0); 185 EXPECT_EQ(desktop_resizer->set_size_call_count(), 0);
186 } 186 }
187 187
188 } // namespace remoting 188 } // namespace remoting
OLDNEW
« no previous file with comments | « net/quic/test_tools/simple_quic_framer.cc ('k') | ui/compositor/compositor.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698