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

Unified Diff: ui/views/widget/widget.cc

Issue 10993087: Handle titlebar text updates properly (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Odd - build machine failed to update patch (which I updated successfully) Re-uploading Created 8 years, 3 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
« no previous file with comments | « ui/views/bubble/bubble_frame_view.h ('k') | ui/views/window/custom_frame_view.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/widget/widget.cc
diff --git a/ui/views/widget/widget.cc b/ui/views/widget/widget.cc
index bcee50154b5b61a5aebddce87bb39cac04535f7d..14aade85eba307d3e8f52d941e1e2a2d8e153322 100644
--- a/ui/views/widget/widget.cc
+++ b/ui/views/widget/widget.cc
@@ -736,10 +736,6 @@ void Widget::UpdateWindowTitle() {
if (!non_client_view_)
return;
- // If the non-client view is rendering its own title, it'll need to relayout
- // now.
- non_client_view_->Layout();
-
// Update the native frame's text. We do this regardless of whether or not
// the native frame is being used, since this also updates the taskbar, etc.
string16 window_title;
@@ -750,6 +746,11 @@ void Widget::UpdateWindowTitle() {
}
base::i18n::AdjustStringForLocaleDirection(&window_title);
native_widget_->SetWindowTitle(window_title);
+ non_client_view_->UpdateWindowTitle();
+
+ // If the non-client view is rendering its own title, it'll need to relayout
+ // now and to get a paint update later on.
+ non_client_view_->Layout();
}
void Widget::UpdateWindowIcon() {
« no previous file with comments | « ui/views/bubble/bubble_frame_view.h ('k') | ui/views/window/custom_frame_view.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698