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

Unified Diff: chrome/browser/ui/views/frame/opaque_browser_frame_view.h

Issue 8772060: Refactor window frame painting into a window background class (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: final cleanup of PaintRestored Created 9 years 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/views/frame/opaque_browser_frame_view.h
diff --git a/chrome/browser/ui/views/frame/opaque_browser_frame_view.h b/chrome/browser/ui/views/frame/opaque_browser_frame_view.h
index 0af7cbd236592ab03601a39ab30673bf3d10f228..650edf0478d1a7c7ff78a73354e255a96f3c1ae1 100644
--- a/chrome/browser/ui/views/frame/opaque_browser_frame_view.h
+++ b/chrome/browser/ui/views/frame/opaque_browser_frame_view.h
@@ -18,6 +18,7 @@
class BrowserView;
namespace views {
class ImageButton;
+class FrameBackground;
}
class OpaqueBrowserFrameView : public BrowserNonClientFrameView,
@@ -131,10 +132,11 @@ class OpaqueBrowserFrameView : public BrowserNonClientFrameView,
void PaintToolbarBackground(gfx::Canvas* canvas);
void PaintRestoredClientEdge(gfx::Canvas* canvas);
- // Returns the properly themed bitmap and frame color, given various
- // attributes of this view (normal browser or not, OTR or not, active or not).
- SkBitmap* GetFrameBitmap() const;
+ // Compute aspects of the frame needed to paint the frame background.
SkColor GetFrameColor() const;
+ SkBitmap* GetFrameBitmap() const;
+ SkBitmap* GetFrameOverlayBitmap() const;
+ int GetTopAreaHeight() const;
// Layout various sub-components of this view.
void LayoutWindowControls();
@@ -164,6 +166,9 @@ class OpaqueBrowserFrameView : public BrowserNonClientFrameView,
content::NotificationRegistrar registrar_;
+ // Background painter for the window frame.
+ scoped_ptr<views::FrameBackground> frame_background_;
+
DISALLOW_COPY_AND_ASSIGN(OpaqueBrowserFrameView);
};

Powered by Google App Engine
This is Rietveld 408576698