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

Side by Side Diff: ui/compositor/layer.h

Issue 10919195: LayerAnimator must be prepared for its owning layer's deletion whenever it notifies observers. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixing the unit tests. Created 8 years, 3 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 | « no previous file | ui/compositor/layer.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 #ifndef UI_COMPOSITOR_LAYER_H_ 5 #ifndef UI_COMPOSITOR_LAYER_H_
6 #define UI_COMPOSITOR_LAYER_H_ 6 #define UI_COMPOSITOR_LAYER_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 357 matching lines...) Expand 10 before | Expand all | Expand 10 after
368 Layer* layer_mask_; 368 Layer* layer_mask_;
369 // The back link from the mask layer to it's associated masked layer. 369 // The back link from the mask layer to it's associated masked layer.
370 // We keep this reference for the case that if the mask layer gets deleted 370 // We keep this reference for the case that if the mask layer gets deleted
371 // while attached to the main layer before the main layer is deleted. 371 // while attached to the main layer before the main layer is deleted.
372 Layer* layer_mask_back_link_; 372 Layer* layer_mask_back_link_;
373 373
374 std::string name_; 374 std::string name_;
375 375
376 LayerDelegate* delegate_; 376 LayerDelegate* delegate_;
377 377
378 scoped_ptr<LayerAnimator> animator_; 378 scoped_refptr<LayerAnimator> animator_;
379 379
380 // Ownership of the layer is held through one of the strongly typed layer 380 // Ownership of the layer is held through one of the strongly typed layer
381 // pointers, depending on which sort of layer this is. 381 // pointers, depending on which sort of layer this is.
382 scoped_ptr<WebKit::WebContentLayer> content_layer_; 382 scoped_ptr<WebKit::WebContentLayer> content_layer_;
383 scoped_ptr<WebKit::WebExternalTextureLayer> texture_layer_; 383 scoped_ptr<WebKit::WebExternalTextureLayer> texture_layer_;
384 scoped_ptr<WebKit::WebSolidColorLayer> solid_color_layer_; 384 scoped_ptr<WebKit::WebSolidColorLayer> solid_color_layer_;
385 WebKit::WebLayer* web_layer_; 385 WebKit::WebLayer* web_layer_;
386 bool web_layer_is_accelerated_; 386 bool web_layer_is_accelerated_;
387 bool show_debug_borders_; 387 bool show_debug_borders_;
388 388
389 // If true, the layer scales the canvas and the texture with the device scale 389 // If true, the layer scales the canvas and the texture with the device scale
390 // factor as appropriate. When true, the texture size is in DIP. 390 // factor as appropriate. When true, the texture size is in DIP.
391 bool scale_content_; 391 bool scale_content_;
392 392
393 // A cached copy of |Compositor::device_scale_factor()|. 393 // A cached copy of |Compositor::device_scale_factor()|.
394 float device_scale_factor_; 394 float device_scale_factor_;
395 395
396 DISALLOW_COPY_AND_ASSIGN(Layer); 396 DISALLOW_COPY_AND_ASSIGN(Layer);
397 }; 397 };
398 398
399 } // namespace ui 399 } // namespace ui
400 400
401 #endif // UI_COMPOSITOR_LAYER_H_ 401 #endif // UI_COMPOSITOR_LAYER_H_
OLDNEW
« no previous file with comments | « no previous file | ui/compositor/layer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698