summaryrefslogtreecommitdiffstats
path: root/chrome/browser/views
diff options
context:
space:
mode:
authorrahulk@google.com <rahulk@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-08-21 18:18:30 +0000
committerrahulk@google.com <rahulk@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-08-21 18:18:30 +0000
commit025a16feb0c23574585de20a7bc6524a9a6a1e06 (patch)
tree6199c376b691b50a4b31436a16e9e198a60e8931 /chrome/browser/views
parentd862fd9d396126f3f06a8061412def6d61d156fd (diff)
downloadchromium_src-025a16feb0c23574585de20a7bc6524a9a6a1e06.zip
chromium_src-025a16feb0c23574585de20a7bc6524a9a6a1e06.tar.gz
chromium_src-025a16feb0c23574585de20a7bc6524a9a6a1e06.tar.bz2
Revert 1158 as it is breaking ui_tests
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1165 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/views')
-rw-r--r--chrome/browser/views/frame/aero_glass_non_client_view.cc14
-rw-r--r--chrome/browser/views/frame/opaque_non_client_view.cc13
2 files changed, 6 insertions, 21 deletions
diff --git a/chrome/browser/views/frame/aero_glass_non_client_view.cc b/chrome/browser/views/frame/aero_glass_non_client_view.cc
index d5d8472..0e05ab9 100644
--- a/chrome/browser/views/frame/aero_glass_non_client_view.cc
+++ b/chrome/browser/views/frame/aero_glass_non_client_view.cc
@@ -248,10 +248,8 @@ int AeroGlassNonClientView::CalculateNonClientTopHeight() const {
}
void AeroGlassNonClientView::PaintDistributorLogo(ChromeCanvas* canvas) {
- // The distributor logo is only painted when the frame is not maximized and
- // when we actually have a logo.
- if (!frame_->IsMaximized() && !frame_->IsMinimized() &&
- !distributor_logo_.empty()) {
+ // The distributor logo is only painted when the frame is not maximized.
+ if (!frame_->IsMaximized() && !frame_->IsMinimized()) {
canvas->DrawBitmapInt(distributor_logo_, logo_bounds_.x(),
logo_bounds_.y());
}
@@ -321,9 +319,6 @@ void AeroGlassNonClientView::PaintClientEdge(ChromeCanvas* canvas) {
}
void AeroGlassNonClientView::LayoutDistributorLogo() {
- if (distributor_logo_.empty())
- return;
-
int logo_w = distributor_logo_.width();
int logo_h = distributor_logo_.height();
@@ -347,10 +342,7 @@ void AeroGlassNonClientView::InitClass() {
if (!initialized) {
resources_ = new AeroGlassWindowResources;
ResourceBundle& rb = ResourceBundle::GetSharedInstance();
- SkBitmap* image = rb.GetBitmapNamed(IDR_DISTRIBUTOR_LOGO);
- if (!image->isNull())
- distributor_logo_ = *image;
-
+ distributor_logo_ = *rb.GetBitmapNamed(IDR_DISTRIBUTOR_LOGO);
initialized = true;
}
}
diff --git a/chrome/browser/views/frame/opaque_non_client_view.cc b/chrome/browser/views/frame/opaque_non_client_view.cc
index 116b9cb..74ee8b1 100644
--- a/chrome/browser/views/frame/opaque_non_client_view.cc
+++ b/chrome/browser/views/frame/opaque_non_client_view.cc
@@ -812,10 +812,8 @@ void OpaqueNonClientView::PaintOTRAvatar(ChromeCanvas* canvas) {
}
void OpaqueNonClientView::PaintDistributorLogo(ChromeCanvas* canvas) {
- // The distributor logo is only painted when the frame is not maximized and
- // when we actually have a logo.
- if (!frame_->IsMaximized() && !frame_->IsMinimized() &&
- !distributor_logo_.empty()) {
+ // The distributor logo is only painted when the frame is not maximized.
+ if (!frame_->IsMaximized() && !frame_->IsMinimized()) {
canvas->DrawBitmapInt(distributor_logo_, logo_bounds_.x(),
logo_bounds_.y());
}
@@ -1009,9 +1007,6 @@ void OpaqueNonClientView::LayoutOTRAvatar() {
}
void OpaqueNonClientView::LayoutDistributorLogo() {
- if (distributor_logo_.empty())
- return;
-
int logo_w = distributor_logo_.width();
int logo_h = distributor_logo_.height();
@@ -1068,9 +1063,7 @@ void OpaqueNonClientView::InitClass() {
inactive_resources_ = new InactiveWindowResources;
ResourceBundle& rb = ResourceBundle::GetSharedInstance();
- SkBitmap* image = rb.GetBitmapNamed(IDR_DISTRIBUTOR_LOGO_LIGHT);
- if (!image->isNull())
- distributor_logo_ = *image;
+ distributor_logo_ = *rb.GetBitmapNamed(IDR_DISTRIBUTOR_LOGO_LIGHT);
initialized = true;
}