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

Unified Diff: chrome/browser/ui/views/bookmarks/bookmark_bar_view.cc

Issue 2687893002: Clear the text cache when the tooltip text is updated. (Closed)
Patch Set: . Created 3 years, 10 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/views/bookmarks/bookmark_bar_view.cc
diff --git a/chrome/browser/ui/views/bookmarks/bookmark_bar_view.cc b/chrome/browser/ui/views/bookmarks/bookmark_bar_view.cc
index 3010e8e8cff7dfca71a7306a42b9b3695d5d18ed..e08d72093b589fbd6a5b1c832530d3ed079ecb60 100644
--- a/chrome/browser/ui/views/bookmarks/bookmark_bar_view.cc
+++ b/chrome/browser/ui/views/bookmarks/bookmark_bar_view.cc
@@ -279,6 +279,7 @@ class BookmarkButton : public BookmarkButtonBase {
// it may be elided differently.
int max_tooltip_width = tooltip_manager->GetMaxWidth(location);
if (tooltip_text_.empty() || max_tooltip_width != max_tooltip_width_) {
+ LOG(ERROR) << "New Tooltip:" << tooltip_text_;
sky 2017/02/09 20:30:40 Remove this.
oshima 2017/02/13 04:37:24 Done.
max_tooltip_width_ = max_tooltip_width;
tooltip_text_ = BookmarkBarView::CreateToolTipForURLAndTitle(
max_tooltip_width_, tooltip_manager->GetFontList(), url_, GetText());
@@ -289,7 +290,7 @@ class BookmarkButton : public BookmarkButtonBase {
void SetText(const base::string16& text) override {
BookmarkButtonBase::SetText(text);
- tooltip_text_.empty();
+ tooltip_text_.clear();
}
const char* GetClassName() const override { return kViewClassName; }

Powered by Google App Engine
This is Rietveld 408576698