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

Side by Side Diff: chrome/browser/ui/metro_pin_tab_helper_win.cc

Issue 934693002: Reload favicon from HTTP cache on Ctrl+Refresh (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/ui/metro_pin_tab_helper_win.h" 5 #include "chrome/browser/ui/metro_pin_tab_helper_win.h"
6 6
7 #include <set> 7 #include <set>
8 8
9 #include "base/base_paths.h" 9 #include "base/base_paths.h"
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 382 matching lines...) Expand 10 before | Expand all | Expand 10 after
393 // Request all the candidates. 393 // Request all the candidates.
394 int max_image_size = 0; // Do not resize images. 394 int max_image_size = 0; // Do not resize images.
395 for (std::vector<content::FaviconURL>::const_iterator iter = 395 for (std::vector<content::FaviconURL>::const_iterator iter =
396 favicon_url_candidates_.begin(); 396 favicon_url_candidates_.begin();
397 iter != favicon_url_candidates_.end(); 397 iter != favicon_url_candidates_.end();
398 ++iter) { 398 ++iter) {
399 favicon_chooser_->AddPendingRequest( 399 favicon_chooser_->AddPendingRequest(
400 web_contents()->DownloadImage(iter->icon_url, 400 web_contents()->DownloadImage(iter->icon_url,
401 true, 401 true,
402 max_image_size, 402 max_image_size,
403 false,
403 base::Bind(&MetroPinTabHelper::DidDownloadFavicon, 404 base::Bind(&MetroPinTabHelper::DidDownloadFavicon,
404 base::Unretained(this)))); 405 base::Unretained(this))));
405 } 406 }
406 407
407 } 408 }
408 409
409 void MetroPinTabHelper::DidNavigateMainFrame( 410 void MetroPinTabHelper::DidNavigateMainFrame(
410 const content::LoadCommittedDetails& /*details*/, 411 const content::LoadCommittedDetails& /*details*/,
411 const content::FrameNavigateParams& /*params*/) { 412 const content::FrameNavigateParams& /*params*/) {
412 // Cancel any outstanding pin operations once the user navigates away from 413 // Cancel any outstanding pin operations once the user navigates away from
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
448 449
449 GURL url = web_contents()->GetURL(); 450 GURL url = web_contents()->GetURL();
450 base::string16 tile_id = GenerateTileId(base::UTF8ToUTF16(url.spec())); 451 base::string16 tile_id = GenerateTileId(base::UTF8ToUTF16(url.spec()));
451 metro_un_pin_from_start_screen(tile_id, 452 metro_un_pin_from_start_screen(tile_id,
452 base::Bind(&PinPageReportUmaCallback)); 453 base::Bind(&PinPageReportUmaCallback));
453 } 454 }
454 455
455 void MetroPinTabHelper::FaviconDownloaderFinished() { 456 void MetroPinTabHelper::FaviconDownloaderFinished() {
456 favicon_chooser_.reset(); 457 favicon_chooser_.reset();
457 } 458 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/ash/launcher/launcher_favicon_loader.cc ('k') | chrome/browser/ui/views/create_application_shortcut_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698