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

Unified Diff: chrome/browser/ui/webui/chromeos/image_source.h

Issue 780203002: Fix threading bugs in product label UI. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix ImageSource Created 6 years 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
Index: chrome/browser/ui/webui/chromeos/image_source.h
diff --git a/chrome/browser/ui/webui/chromeos/image_source.h b/chrome/browser/ui/webui/chromeos/image_source.h
index 3db5d9bec90b5d153c3e278a1df6efe19d752ad8..ac19037acc88e716b5c58e18da9536e2ba1373c6 100644
--- a/chrome/browser/ui/webui/chromeos/image_source.h
+++ b/chrome/browser/ui/webui/chromeos/image_source.h
@@ -38,18 +38,21 @@ class ImageSource : public content::URLDataSource {
const std::string& path,
int render_process_id,
int render_frame_id,
- const content::URLDataSource::GotDataCallback& callback) override;
+ const content::URLDataSource::GotDataCallback& got_data_callback)
+ override;
+
std::string GetMimeType(const std::string& path) const override;
private:
- void StartOnFileThread(
- const std::string& path,
- const content::URLDataSource::GotDataCallback& callback);
+ // Callback after attempting to start loading the image.
+ void LoadImageAttempted(
+ const content::URLDataSource::GotDataCallback& got_data_callback,
+ bool load_started);
// Callback for user_manager::UserImageLoader.
void ImageLoaded(
- const content::URLDataSource::GotDataCallback& callback,
- const user_manager::UserImage& user_image) const;
+ const content::URLDataSource::GotDataCallback& got_data_callback,
+ const user_manager::UserImage& user_image) const;
// Checks whether we have allowed the image to be loaded.
bool IsWhitelisted(const std::string& path) const;
« no previous file with comments | « no previous file | chrome/browser/ui/webui/chromeos/image_source.cc » ('j') | chrome/browser/ui/webui/chromeos/image_source.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698