| Index: ui/gfx/compositor/layer.h
|
| ===================================================================
|
| --- ui/gfx/compositor/layer.h (revision 100773)
|
| +++ ui/gfx/compositor/layer.h (working copy)
|
| @@ -60,6 +60,10 @@
|
| void SetBounds(const gfx::Rect& bounds);
|
| const gfx::Rect& bounds() const { return bounds_; }
|
|
|
| + // Sets |visible_|. The Layer is drawn by Draw() only when visible_ is true.
|
| + bool visible() const { return visible_; }
|
| + void set_visible(bool visible) { visible_ = visible; }
|
| +
|
| // Converts a point from the coordinates of |source| to the coordinates of
|
| // |target|. Necessarily, |source| and |target| must inhabit the same Layer
|
| // tree.
|
| @@ -89,25 +93,29 @@
|
| // repaint.
|
| void SchedulePaint(const gfx::Rect& invalid_rect);
|
|
|
| -// Draws the layer with hole if hole is non empty.
|
| -// hole looks like:
|
| -//
|
| -// layer____________________________
|
| -// |xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx|
|
| -// |xxxxxxxxxxxxx top xxxxxxxxxxxxxx|
|
| -// |________________________________|
|
| -// |xxxxx| |xxxxx|
|
| -// |xxxxx| Hole Rect |xxxxx|
|
| -// |left | (not composited) |right|
|
| -// |_____|____________________|_____|
|
| -// |xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx|
|
| -// |xxxxxxxxxx bottom xxxxxxxxxxxxxx|
|
| -// |________________________________|
|
| -//
|
| -// Legend:
|
| -// composited area: x
|
| + // Draws the layer with hole if hole is non empty.
|
| + // hole looks like:
|
| + //
|
| + // layer____________________________
|
| + // |xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx|
|
| + // |xxxxxxxxxxxxx top xxxxxxxxxxxxxx|
|
| + // |________________________________|
|
| + // |xxxxx| |xxxxx|
|
| + // |xxxxx| Hole Rect |xxxxx|
|
| + // |left | (not composited) |right|
|
| + // |_____|____________________|_____|
|
| + // |xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx|
|
| + // |xxxxxxxxxx bottom xxxxxxxxxxxxxx|
|
| + // |________________________________|
|
| + //
|
| + // Legend:
|
| + // composited area: x
|
| void Draw();
|
|
|
| + // Draws a tree of Layers, by calling Draw() on each in the hierarchy starting
|
| + // with the receiver.
|
| + void DrawTree();
|
| +
|
| private:
|
| // calls Texture::Draw only if the region to be drawn is non empty
|
| void DrawRegion(const ui::TextureDrawParams& params,
|
| @@ -144,6 +152,8 @@
|
|
|
| gfx::Rect bounds_;
|
|
|
| + bool visible_;
|
| +
|
| bool fills_bounds_opaquely_;
|
|
|
| gfx::Rect hole_rect_;
|
|
|