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

Side by Side Diff: chrome/browser/ui/views/frame/browser_view.cc

Issue 5111002: Fixes bug where instant dim was not removed correctly if you pressed (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/chrome
Patch Set: Created 10 years, 1 month 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | 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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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/frame/browser_view.h" 5 #include "chrome/browser/views/frame/browser_view.h"
6 6
7 #if defined(OS_LINUX) 7 #if defined(OS_LINUX)
8 #include <gtk/gtk.h> 8 #include <gtk/gtk.h>
9 #endif 9 #endif
10 10
(...skipping 1347 matching lines...) Expand 10 before | Expand all | Expand 10 after
1358 // Removing the fade is instant (on windows). We need to force the preview to 1358 // Removing the fade is instant (on windows). We need to force the preview to
1359 // draw, otherwise the current page flickers before the new page appears. 1359 // draw, otherwise the current page flickers before the new page appears.
1360 RedrawWindow(preview_contents->view()->GetContentNativeView(), NULL, NULL, 1360 RedrawWindow(preview_contents->view()->GetContentNativeView(), NULL, NULL,
1361 RDW_INVALIDATE | RDW_UPDATENOW | RDW_NOCHILDREN); 1361 RDW_INVALIDATE | RDW_UPDATENOW | RDW_NOCHILDREN);
1362 #endif 1362 #endif
1363 1363
1364 contents_->RemoveFade(); 1364 contents_->RemoveFade();
1365 } 1365 }
1366 1366
1367 void BrowserView::HideInstant() { 1367 void BrowserView::HideInstant() {
1368 if (!preview_container_) 1368 if (!preview_container_) {
1369 contents_->RemoveFade();
1369 return; 1370 return;
1371 }
1370 1372
1371 // The contents must be changed before SetPreview is invoked. 1373 // The contents must be changed before SetPreview is invoked.
1372 preview_container_->ChangeTabContents(NULL); 1374 preview_container_->ChangeTabContents(NULL);
1373 contents_->SetPreview(NULL, NULL); 1375 contents_->SetPreview(NULL, NULL);
1374 delete preview_container_; 1376 delete preview_container_;
1375 preview_container_ = NULL; 1377 preview_container_ = NULL;
1376 contents_->RemoveFade(); 1378 contents_->RemoveFade();
1377 } 1379 }
1378 1380
1379 gfx::Rect BrowserView::GetInstantBounds() { 1381 gfx::Rect BrowserView::GetInstantBounds() {
(...skipping 1119 matching lines...) Expand 10 before | Expand all | Expand 10 after
2499 SetAccessibleName(l10n_util::GetString(IDS_PRODUCT_NAME)); 2501 SetAccessibleName(l10n_util::GetString(IDS_PRODUCT_NAME));
2500 2502
2501 return view; 2503 return view;
2502 } 2504 }
2503 #endif 2505 #endif
2504 2506
2505 // static 2507 // static
2506 FindBar* BrowserWindow::CreateFindBar(Browser* browser) { 2508 FindBar* BrowserWindow::CreateFindBar(Browser* browser) {
2507 return browser::CreateFindBar(static_cast<BrowserView*>(browser->window())); 2509 return browser::CreateFindBar(static_cast<BrowserView*>(browser->window()));
2508 } 2510 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698