| Index: chrome/common/localized_error.cc
|
| ===================================================================
|
| --- chrome/common/localized_error.cc (revision 193007)
|
| +++ chrome/common/localized_error.cc (working copy)
|
| @@ -4,6 +4,7 @@
|
|
|
| #include "chrome/common/localized_error.h"
|
|
|
| +#include "base/base64.h"
|
| #include "base/i18n/rtl.h"
|
| #include "base/logging.h"
|
| #include "base/string16.h"
|
| @@ -18,10 +19,12 @@
|
| #include "googleurl/src/gurl.h"
|
| #include "grit/chromium_strings.h"
|
| #include "grit/generated_resources.h"
|
| +#include "grit/theme_resources.h"
|
| #include "net/base/escape.h"
|
| #include "net/base/net_errors.h"
|
| #include "third_party/WebKit/Source/Platform/chromium/public/WebURLError.h"
|
| #include "ui/base/l10n/l10n_util.h"
|
| +#include "ui/base/resource/resource_bundle.h"
|
| #include "ui/webui/web_ui_util.h"
|
| #include "webkit/glue/webkit_glue.h"
|
|
|
| @@ -669,6 +672,16 @@
|
| }
|
|
|
| error_strings->Set("suggestions", suggestions);
|
| +
|
| + std::string resource_base64;
|
| + if (base::Base64Encode(
|
| + ResourceBundle::GetSharedInstance().GetRawDataResourceForScale(
|
| + IDR_ERROR_NETWORK_GENERIC, ui::GetMaxScaleFactor()),
|
| + &resource_base64)) {
|
| + base::StringValue* data_url =
|
| + new base::StringValue("data:image/png;base64," + resource_base64);
|
| + error_strings->Set("image", data_url);
|
| + }
|
| }
|
|
|
| string16 LocalizedError::GetErrorDetails(const WebKit::WebURLError& error) {
|
|
|