OLD | NEW |
(Empty) | |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef CC_TEST_FAKE_SCROLLBAR_LAYER_H_ |
| 6 #define CC_TEST_FAKE_SCROLLBAR_LAYER_H_ |
| 7 |
| 8 #include "base/memory/scoped_ptr.h" |
| 9 #include "cc/scrollbar_layer.h" |
| 10 |
| 11 namespace cc { |
| 12 |
| 13 class FakeScrollbarLayer : public ScrollbarLayer { |
| 14 public: |
| 15 static scoped_refptr<FakeScrollbarLayer> Create( |
| 16 bool paint_during_update, int scrolling_layer_id) { |
| 17 return make_scoped_refptr(new FakeScrollbarLayer( |
| 18 paint_during_update, scrolling_layer_id)); |
| 19 } |
| 20 |
| 21 int update_count() { return update_count_; } |
| 22 void reset_update_count() { update_count_ = 0; } |
| 23 |
| 24 virtual void update( |
| 25 ResourceUpdateQueue& queue, |
| 26 const OcclusionTracker* occlusion, |
| 27 RenderingStats& stats) OVERRIDE; |
| 28 |
| 29 private: |
| 30 FakeScrollbarLayer(bool paint_during_update, int scrolling_layer_id); |
| 31 virtual ~FakeScrollbarLayer(); |
| 32 |
| 33 int update_count_; |
| 34 }; |
| 35 |
| 36 } // namespace cc |
| 37 |
| 38 #endif // CC_TEST_FAKE_SCROLLBAR_LAYER_H_ |
OLD | NEW |