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

Side by Side Diff: chrome/browser/views/tabs/tab_renderer.cc

Issue 40124: Revert r9953 since it caused regressions like: (Closed) Base URL: svn://chrome-svn.corp.google.com/chrome/trunk/src/
Patch Set: Created 11 years, 9 months 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 unified diff | Download patch
« no previous file with comments | « no previous file | chrome/browser/views/tabs/tab_strip.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 <limits> 5 #include <limits>
6 6
7 #include "chrome/browser/views/tabs/tab_renderer.h" 7 #include "chrome/browser/views/tabs/tab_renderer.h"
8 8
9 #include "chrome/browser/browser.h" 9 #include "chrome/browser/browser.h"
10 #include "chrome/browser/profile.h" 10 #include "chrome/browser/profile.h"
(...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after
178 // TabCloseButton 178 // TabCloseButton
179 // 179 //
180 // This is a Button subclass that causes middle clicks to be forwarded to the 180 // This is a Button subclass that causes middle clicks to be forwarded to the
181 // parent View by explicitly not handling them in OnMousePressed. 181 // parent View by explicitly not handling them in OnMousePressed.
182 class TabCloseButton : public views::Button { 182 class TabCloseButton : public views::Button {
183 public: 183 public:
184 TabCloseButton() : Button() {} 184 TabCloseButton() : Button() {}
185 virtual ~TabCloseButton() {} 185 virtual ~TabCloseButton() {}
186 186
187 virtual bool OnMousePressed(const views::MouseEvent& event) { 187 virtual bool OnMousePressed(const views::MouseEvent& event) {
188 LOG(WARNING) << "MOUSE PRESSED";
188 return !event.IsOnlyMiddleMouseButton(); 189 return !event.IsOnlyMiddleMouseButton();
189 } 190 }
190 191
191 // We need to let the parent know about mouse state so that it 192 // We need to let the parent know about mouse state so that it
192 // can highlight itself appropriately. Note that Exit events 193 // can highlight itself appropriately. Note that Exit events
193 // fire before Enter events, so this works. 194 // fire before Enter events, so this works.
194 virtual void OnMouseEntered(const views::MouseEvent& event) { 195 virtual void OnMouseEntered(const views::MouseEvent& event) {
195 BaseButton::OnMouseEntered(event); 196 BaseButton::OnMouseEntered(event);
196 GetParent()->OnMouseEntered(event); 197 GetParent()->OnMouseEntered(event);
197 } 198 }
(...skipping 496 matching lines...) Expand 10 before | Expand all | Expand 10 after
694 } 695 }
695 696
696 void TabRenderer::DisplayCrashedFavIcon() { 697 void TabRenderer::DisplayCrashedFavIcon() {
697 should_display_crashed_favicon_ = true; 698 should_display_crashed_favicon_ = true;
698 } 699 }
699 700
700 void TabRenderer::ResetCrashedFavIcon() { 701 void TabRenderer::ResetCrashedFavIcon() {
701 should_display_crashed_favicon_ = false; 702 should_display_crashed_favicon_ = false;
702 } 703 }
703 704
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/views/tabs/tab_strip.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698