| OLD | NEW |
| 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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/tabs/tab.h" | 5 #include "chrome/browser/views/tabs/tab.h" |
| 6 | 6 |
| 7 #include "app/gfx/canvas.h" | 7 #include "app/gfx/canvas.h" |
| 8 #include "app/gfx/font.h" | 8 #include "app/gfx/font.h" |
| 9 #include "app/gfx/path.h" | 9 #include "app/gfx/path.h" |
| 10 #include "app/l10n_util.h" | 10 #include "app/l10n_util.h" |
| (...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 74 tab_->delegate()->ExecuteCommandForTab( | 74 tab_->delegate()->ExecuteCommandForTab( |
| 75 static_cast<TabStripModel::ContextMenuCommand>(command_id), | 75 static_cast<TabStripModel::ContextMenuCommand>(command_id), |
| 76 tab_); | 76 tab_); |
| 77 } | 77 } |
| 78 | 78 |
| 79 private: | 79 private: |
| 80 void Build() { | 80 void Build() { |
| 81 AddItemWithStringId(TabStripModel::CommandNewTab, IDS_TAB_CXMENU_NEWTAB); | 81 AddItemWithStringId(TabStripModel::CommandNewTab, IDS_TAB_CXMENU_NEWTAB); |
| 82 AddSeparator(); | 82 AddSeparator(); |
| 83 AddItemWithStringId(TabStripModel::CommandReload, IDS_TAB_CXMENU_RELOAD); | 83 AddItemWithStringId(TabStripModel::CommandReload, IDS_TAB_CXMENU_RELOAD); |
| 84 AddItemWithStringId(TabStripModel::CommandReloadAll, |
| 85 IDS_TAB_CXMENU_RELOAD_ALL); |
| 84 AddItemWithStringId(TabStripModel::CommandDuplicate, | 86 AddItemWithStringId(TabStripModel::CommandDuplicate, |
| 85 IDS_TAB_CXMENU_DUPLICATE); | 87 IDS_TAB_CXMENU_DUPLICATE); |
| 86 AddSeparator(); | 88 AddSeparator(); |
| 87 AddItemWithStringId(TabStripModel::CommandCloseTab, | 89 AddItemWithStringId(TabStripModel::CommandCloseTab, |
| 88 IDS_TAB_CXMENU_CLOSETAB); | 90 IDS_TAB_CXMENU_CLOSETAB); |
| 89 AddItemWithStringId(TabStripModel::CommandCloseOtherTabs, | 91 AddItemWithStringId(TabStripModel::CommandCloseOtherTabs, |
| 90 IDS_TAB_CXMENU_CLOSEOTHERTABS); | 92 IDS_TAB_CXMENU_CLOSEOTHERTABS); |
| 91 AddItemWithStringId(TabStripModel::CommandCloseTabsToRight, | 93 AddItemWithStringId(TabStripModel::CommandCloseTabsToRight, |
| 92 IDS_TAB_CXMENU_CLOSETABSTORIGHT); | 94 IDS_TAB_CXMENU_CLOSETABSTORIGHT); |
| 93 AddItemWithStringId(TabStripModel::CommandCloseTabsOpenedBy, | 95 AddItemWithStringId(TabStripModel::CommandCloseTabsOpenedBy, |
| (...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 247 | 249 |
| 248 // Right end cap. | 250 // Right end cap. |
| 249 path->lineTo(w - kTabCapWidth + kTabTopCurveWidth, kTabTopCurveWidth); | 251 path->lineTo(w - kTabCapWidth + kTabTopCurveWidth, kTabTopCurveWidth); |
| 250 path->lineTo(w - kTabBottomCurveWidth, h - kTabBottomCurveWidth); | 252 path->lineTo(w - kTabBottomCurveWidth, h - kTabBottomCurveWidth); |
| 251 path->lineTo(w, h); | 253 path->lineTo(w, h); |
| 252 | 254 |
| 253 // Close out the path. | 255 // Close out the path. |
| 254 path->lineTo(0, h); | 256 path->lineTo(0, h); |
| 255 path->close(); | 257 path->close(); |
| 256 } | 258 } |
| OLD | NEW |