Lines Matching refs:resource
40 void LoadImage(const ExtensionResource& resource,
46 NewRunnableMethod(this, &ImageLoader::LoadOnFileThread, resource,
50 void LoadOnFileThread(const ExtensionResource& resource,
57 FilePath path = resource.GetFilePath();
59 ReportBack(NULL, resource, gfx::Size(), id);
70 ReportBack(NULL, resource, gfx::Size(), id);
84 ReportBack(decoded.release(), resource, original_size, id);
87 void ReportBack(SkBitmap* image, const ExtensionResource& resource,
94 image, resource, original_size, id));
97 void ReportOnUIThread(SkBitmap* image, const ExtensionResource& resource,
102 tracker_->OnImageLoaded(image, resource, original_size, id);
136 const ExtensionResource& resource,
142 if (resource.relative_path().empty()) {
143 OnImageLoaded(NULL, resource, max_size, id);
147 DCHECK(extension->path() == resource.extension_root());
150 if (extension->HasCachedImage(resource, max_size)) {
151 SkBitmap image = extension->GetCachedImage(resource, max_size);
152 OnImageLoaded(&image, resource, max_size, id);
164 loader_->LoadImage(resource, max_size, id);
169 const ExtensionResource& resource,
174 i->second->SetCachedImage(resource, image ? *image : SkBitmap(),
179 observer_->OnImageLoaded(image, resource, id);