| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 "chrome/browser/views/toolbar_view.h" | 5 #include "chrome/browser/views/toolbar_view.h" |
| 6 | 6 |
| 7 #include "app/l10n_util.h" | 7 #include "app/l10n_util.h" |
| 8 #include "app/resource_bundle.h" | 8 #include "app/resource_bundle.h" |
| 9 #include "chrome/app/chrome_command_ids.h" | 9 #include "chrome/app/chrome_command_ids.h" |
| 10 #include "chrome/browser/accessibility/browser_accessibility_state.h" | 10 #include "chrome/browser/accessibility/browser_accessibility_state.h" |
| (...skipping 309 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 320 cleanup: | 320 cleanup: |
| 321 #endif | 321 #endif |
| 322 if (destroyed_flag) | 322 if (destroyed_flag) |
| 323 return; | 323 return; |
| 324 destroyed_flag_ = NULL; | 324 destroyed_flag_ = NULL; |
| 325 } | 325 } |
| 326 | 326 |
| 327 //////////////////////////////////////////////////////////////////////////////// | 327 //////////////////////////////////////////////////////////////////////////////// |
| 328 // ToolbarView, LocationBarView::Delegate implementation: | 328 // ToolbarView, LocationBarView::Delegate implementation: |
| 329 | 329 |
| 330 TabContents* ToolbarView::GetTabContents() { | 330 TabContentsWrapper* ToolbarView::GetTabContentsWrapper() { |
| 331 return browser_->GetSelectedTabContents(); | 331 return browser_->GetSelectedTabContentsWrapper(); |
| 332 } | 332 } |
| 333 | 333 |
| 334 InstantController* ToolbarView::GetInstant() { | 334 InstantController* ToolbarView::GetInstant() { |
| 335 return browser_->instant(); | 335 return browser_->instant(); |
| 336 } | 336 } |
| 337 | 337 |
| 338 void ToolbarView::OnInputInProgress(bool in_progress) { | 338 void ToolbarView::OnInputInProgress(bool in_progress) { |
| 339 // The edit should make sure we're only notified when something changes. | 339 // The edit should make sure we're only notified when something changes. |
| 340 DCHECK(model_->input_in_progress() != in_progress); | 340 DCHECK(model_->input_in_progress() != in_progress); |
| 341 | 341 |
| (...skipping 337 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 679 } | 679 } |
| 680 | 680 |
| 681 static const int kBadgeRightMargin = 2; | 681 static const int kBadgeRightMargin = 2; |
| 682 static const int kBadgeTopMargin = 2; | 682 static const int kBadgeTopMargin = 2; |
| 683 canvas->DrawBitmapInt(*badge, | 683 canvas->DrawBitmapInt(*badge, |
| 684 icon.width() - badge->width() - kBadgeRightMargin, | 684 icon.width() - badge->width() - kBadgeRightMargin, |
| 685 kBadgeTopMargin); | 685 kBadgeTopMargin); |
| 686 | 686 |
| 687 return canvas->ExtractBitmap(); | 687 return canvas->ExtractBitmap(); |
| 688 } | 688 } |
| OLD | NEW |