OLD | NEW |
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 "ui/compositor/compositor.h" | 5 #include "ui/compositor/compositor.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include <algorithm> | 9 #include <algorithm> |
10 #include <deque> | 10 #include <deque> |
(...skipping 366 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
377 context_factory_->SetDisplayColorSpace(this, color_space); | 377 context_factory_->SetDisplayColorSpace(this, color_space); |
378 } | 378 } |
379 | 379 |
380 void Compositor::SetBackgroundColor(SkColor color) { | 380 void Compositor::SetBackgroundColor(SkColor color) { |
381 host_->set_background_color(color); | 381 host_->set_background_color(color); |
382 ScheduleDraw(); | 382 ScheduleDraw(); |
383 } | 383 } |
384 | 384 |
385 void Compositor::SetVisible(bool visible) { | 385 void Compositor::SetVisible(bool visible) { |
386 host_->SetVisible(visible); | 386 host_->SetVisible(visible); |
| 387 context_factory_->SetDisplayVisible(this, visible); |
387 } | 388 } |
388 | 389 |
389 bool Compositor::IsVisible() { | 390 bool Compositor::IsVisible() { |
390 return host_->visible(); | 391 return host_->visible(); |
391 } | 392 } |
392 | 393 |
393 void Compositor::SetAuthoritativeVSyncInterval( | 394 void Compositor::SetAuthoritativeVSyncInterval( |
394 const base::TimeDelta& interval) { | 395 const base::TimeDelta& interval) { |
395 context_factory_->SetAuthoritativeVSyncInterval(this, interval); | 396 context_factory_->SetAuthoritativeVSyncInterval(this, interval); |
396 if (base::CommandLine::ForCurrentProcess()->HasSwitch( | 397 if (base::CommandLine::ForCurrentProcess()->HasSwitch( |
(...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
574 observer_list_, | 575 observer_list_, |
575 OnCompositingLockStateChanged(this)); | 576 OnCompositingLockStateChanged(this)); |
576 } | 577 } |
577 | 578 |
578 void Compositor::CancelCompositorLock() { | 579 void Compositor::CancelCompositorLock() { |
579 if (compositor_lock_) | 580 if (compositor_lock_) |
580 compositor_lock_->CancelLock(); | 581 compositor_lock_->CancelLock(); |
581 } | 582 } |
582 | 583 |
583 } // namespace ui | 584 } // namespace ui |
OLD | NEW |