summaryrefslogtreecommitdiff
path: root/Libraries/LibGUI/GDesktop.h
blob: 73bdca506f0d514521aeb53b976ee735900a6ed6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#pragma once

#include <AK/String.h>
#include <AK/Badge.h>
#include <AK/Function.h>
#include <LibDraw/Rect.h>

class GWindowServerConnection;

class GDesktop {
public:
    static GDesktop& the();
    GDesktop();

    String wallpaper() const;
    bool set_wallpaper(const StringView& path);

    Rect rect() const { return m_rect; }
    void did_receive_screen_rect(Badge<GWindowServerConnection>, const Rect&);

    Function<void(const Rect&)> on_rect_change;

private:
    Rect m_rect;
};