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

Unified Diff: chrome/browser/media_galleries/media_galleries_preferences.cc

Issue 167863002: Update media galleries scan results, even when zero. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix up test Created 6 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
« no previous file with comments | « no previous file | chrome/browser/media_galleries/media_galleries_scan_result_dialog_controller_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/media_galleries/media_galleries_preferences.cc
diff --git a/chrome/browser/media_galleries/media_galleries_preferences.cc b/chrome/browser/media_galleries/media_galleries_preferences.cc
index 013cad74784c287f25d63843b00f458450c8ea2f..7fe1a349353c3120ac8c2a09cb9eb678ffdcd191 100644
--- a/chrome/browser/media_galleries/media_galleries_preferences.cc
+++ b/chrome/browser/media_galleries/media_galleries_preferences.cc
@@ -825,7 +825,8 @@ MediaGalleryPrefId MediaGalleriesPreferences::AddGalleryInternal(
bool update_scan_counts =
new_type != MediaGalleryPrefInfo::kRemovedScan &&
new_type != MediaGalleryPrefInfo::kBlackListed &&
- (audio_count > 0 || image_count > 0 || video_count > 0);
+ (audio_count > 0 || image_count > 0 || video_count > 0 ||
+ existing.audio_count || existing.image_count || existing.video_count);
if (!update_gallery_name && !update_gallery_type &&
!update_gallery_metadata && !update_scan_counts)
« no previous file with comments | « no previous file | chrome/browser/media_galleries/media_galleries_scan_result_dialog_controller_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698