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

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

Issue 14322023: Don't request missing favicon on every page request. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: sync up to r199996 Created 7 years, 7 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 | Annotate | Revision Log
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 410 matching lines...) Expand 10 before | Expand all | Expand 10 after
421 } 421 }
422 422
423 void MetroPinTabHelper::DidUpdateFaviconURL( 423 void MetroPinTabHelper::DidUpdateFaviconURL(
424 int32 page_id, 424 int32 page_id,
425 const std::vector<content::FaviconURL>& candidates) { 425 const std::vector<content::FaviconURL>& candidates) {
426 favicon_url_candidates_ = candidates; 426 favicon_url_candidates_ = candidates;
427 } 427 }
428 428
429 void MetroPinTabHelper::DidDownloadFavicon( 429 void MetroPinTabHelper::DidDownloadFavicon(
430 int id, 430 int id,
431 int http_status_code,
431 const GURL& image_url, 432 const GURL& image_url,
432 int requested_size, 433 int requested_size,
433 const std::vector<SkBitmap>& bitmaps) { 434 const std::vector<SkBitmap>& bitmaps) {
434 if (favicon_chooser_.get()) { 435 if (favicon_chooser_.get()) {
435 favicon_chooser_->UpdateCandidate(id, image_url, requested_size, bitmaps); 436 favicon_chooser_->UpdateCandidate(id, image_url, requested_size, bitmaps);
436 } 437 }
437 } 438 }
438 439
439 void MetroPinTabHelper::UnPinPageFromStartScreen() { 440 void MetroPinTabHelper::UnPinPageFromStartScreen() {
440 HMODULE metro_module = base::win::GetMetroModule(); 441 HMODULE metro_module = base::win::GetMetroModule();
(...skipping 10 matching lines...) Expand all
451 452
452 GURL url = web_contents()->GetURL(); 453 GURL url = web_contents()->GetURL();
453 string16 tile_id = GenerateTileId(UTF8ToUTF16(url.spec())); 454 string16 tile_id = GenerateTileId(UTF8ToUTF16(url.spec()));
454 metro_un_pin_from_start_screen(tile_id, 455 metro_un_pin_from_start_screen(tile_id,
455 base::Bind(&PinPageReportUmaCallback)); 456 base::Bind(&PinPageReportUmaCallback));
456 } 457 }
457 458
458 void MetroPinTabHelper::FaviconDownloaderFinished() { 459 void MetroPinTabHelper::FaviconDownloaderFinished() {
459 favicon_chooser_.reset(); 460 favicon_chooser_.reset();
460 } 461 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/metro_pin_tab_helper_win.h ('k') | chrome/browser/ui/views/create_application_shortcut_view.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698