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

Side by Side Diff: chrome/browser/installable/installable_logging.cc

Issue 2791923005: Fails InstallableManager if a selected badge icon cannot be fetched. (Closed)
Patch Set: Addressing comments Created 3 years, 8 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
« no previous file with comments | « no previous file | chrome/browser/installable/installable_manager.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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/installable/installable_logging.h" 5 #include "chrome/browser/installable/installable_logging.h"
6 6
7 #include "base/macros.h" 7 #include "base/macros.h"
8 #include "base/strings/stringprintf.h" 8 #include "base/strings/stringprintf.h"
9 #include "content/public/browser/render_frame_host.h" 9 #include "content/public/browser/render_frame_host.h"
10 #include "content/public/browser/web_contents.h" 10 #include "content/public/browser/web_contents.h"
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 "%spx is required, the sizes attribute must be set, and the purpose " 43 "%spx is required, the sizes attribute must be set, and the purpose "
44 "attribute, if set, must include \"any\"."; 44 "attribute, if set, must include \"any\".";
45 static const char kNoMatchingServiceWorkerMessage[] = 45 static const char kNoMatchingServiceWorkerMessage[] =
46 "no matching service worker detected. You may need to reload the page, or " 46 "no matching service worker detected. You may need to reload the page, or "
47 "check that the service worker for the current page also controls the " 47 "check that the service worker for the current page also controls the "
48 "start URL from the manifest"; 48 "start URL from the manifest";
49 static const char kNoAcceptableIconMessage[] = 49 static const char kNoAcceptableIconMessage[] =
50 "a %spx square icon is required, but no supplied icon meets this " 50 "a %spx square icon is required, but no supplied icon meets this "
51 "requirement"; 51 "requirement";
52 static const char kCannotDownloadIconMessage[] = 52 static const char kCannotDownloadIconMessage[] =
53 "could not download the specified icon"; 53 "could not download a required icon from the manifest";
54 static const char kNoIconAvailableMessage[] = 54 static const char kNoIconAvailableMessage[] =
55 "no icon available to display"; 55 "icon downloaded from the manifest was empty or corrupted";
56 static const char kPlatformNotSupportedOnAndroidMessage[] = 56 static const char kPlatformNotSupportedOnAndroidMessage[] =
57 "the specified application platform is not supported on Android"; 57 "the specified application platform is not supported on Android";
58 static const char kNoIdSpecifiedMessage[] = 58 static const char kNoIdSpecifiedMessage[] =
59 "no Play store ID provided"; 59 "no Play store ID provided";
60 static const char kIdsDoNotMatchMessage[] = 60 static const char kIdsDoNotMatchMessage[] =
61 "a Play Store app URL and Play Store ID were specified in the manifest, " 61 "a Play Store app URL and Play Store ID were specified in the manifest, "
62 "but they do not match"; 62 "but they do not match";
63 static const char kUrlNotSupportedForWebApkMessage[] = 63 static const char kUrlNotSupportedForWebApkMessage[] =
64 "a URL in the web manifest contains a username, password, or port"; 64 "a URL in the web manifest contains a username, password, or port";
65 static const char kInIncognitoMessage[] = 65 static const char kInIncognitoMessage[] =
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
156 break; 156 break;
157 } 157 }
158 158
159 if (!pattern) 159 if (!pattern)
160 return; 160 return;
161 std::string message = param.empty() ? 161 std::string message = param.empty() ?
162 pattern : base::StringPrintf(pattern, param.c_str()); 162 pattern : base::StringPrintf(pattern, param.c_str());
163 web_contents->GetMainFrame()->AddMessageToConsole( 163 web_contents->GetMainFrame()->AddMessageToConsole(
164 severity, GetMessagePrefix() + message); 164 severity, GetMessagePrefix() + message);
165 } 165 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/installable/installable_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698