| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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 #include "chrome/browser/ui/omnibox/alternate_nav_infobar_delegate.h" | 5 #include "chrome/browser/ui/omnibox/alternate_nav_infobar_delegate.h" |
| 6 | 6 |
| 7 #include "base/utf_string_conversions.h" | 7 #include "base/utf_string_conversions.h" |
| 8 #include "chrome/browser/infobars/infobar_service.h" | 8 #include "chrome/browser/infobars/infobar_service.h" |
| 9 #include "content/public/browser/web_contents.h" | 9 #include "content/public/browser/web_contents.h" |
| 10 #include "grit/generated_resources.h" | 10 #include "grit/generated_resources.h" |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 49 // the future. | 49 // the future. |
| 50 content::PAGE_TRANSITION_TYPED, | 50 content::PAGE_TRANSITION_TYPED, |
| 51 false); | 51 false); |
| 52 web_contents()->OpenURL(params); | 52 web_contents()->OpenURL(params); |
| 53 | 53 |
| 54 // We should always close, even if the navigation did not occur within this | 54 // We should always close, even if the navigation did not occur within this |
| 55 // WebContents. | 55 // WebContents. |
| 56 return true; | 56 return true; |
| 57 } | 57 } |
| 58 | 58 |
| 59 gfx::Image* AlternateNavInfoBarDelegate::GetIcon() const { | 59 int AlternateNavInfoBarDelegate::GetIconID() const { |
| 60 return &ui::ResourceBundle::GetSharedInstance().GetNativeImageNamed( | 60 return IDR_INFOBAR_ALT_NAV_URL; |
| 61 IDR_INFOBAR_ALT_NAV_URL); | |
| 62 } | 61 } |
| 63 | 62 |
| 64 InfoBarDelegate::Type AlternateNavInfoBarDelegate::GetInfoBarType() const { | 63 InfoBarDelegate::Type AlternateNavInfoBarDelegate::GetInfoBarType() const { |
| 65 return PAGE_ACTION_TYPE; | 64 return PAGE_ACTION_TYPE; |
| 66 } | 65 } |
| OLD | NEW |