ladybird/Libraries/LibHTML/ResourceLoader.h
Andreas Kling a1c8c754eb LibHTML: Fire the file:// load completion callback asynchronously
This makes it consistent with how http:// callbacks are fired.
It would probably be fine to have file:// be synchronous, but at the
same time it's nice to have consistency.
2019-10-08 19:40:48 +02:00

16 lines
300 B
C++

#pragma once
#include <AK/Function.h>
#include <AK/URL.h>
#include <LibCore/CObject.h>
class ResourceLoader : public CObject {
C_OBJECT(ResourceLoader)
public:
static ResourceLoader& the();
void load(const URL&, Function<void(const ByteBuffer&)>);
private:
ResourceLoader() {}
};