mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 12:37:44 +00:00

- Fix inverted mouse event hit test z-ordering. - Let the RootWidget backing store simply be the display framebuffer.
26 lines
649 B
C++
26 lines
649 B
C++
#pragma once
|
|
|
|
#include "Size.h"
|
|
#include <AK/Retainable.h>
|
|
#include <AK/RetainPtr.h>
|
|
|
|
class GraphicsBitmap : public Retainable<GraphicsBitmap> {
|
|
public:
|
|
static RetainPtr<GraphicsBitmap> create(const Size&);
|
|
static RetainPtr<GraphicsBitmap> create_wrapper(const Size&, byte*);
|
|
~GraphicsBitmap();
|
|
|
|
dword* scanline(int y);
|
|
|
|
Size size() const { return m_size; }
|
|
int width() const { return m_size.width(); }
|
|
int height() const { return m_size.height(); }
|
|
|
|
private:
|
|
explicit GraphicsBitmap(const Size&);
|
|
GraphicsBitmap(const Size&, byte*);
|
|
|
|
Size m_size;
|
|
byte* m_data { nullptr };
|
|
bool m_owned { false };
|
|
};
|