Files
Custom-Operating-System/userland/system/homescreen/AppDelegate.cpp

24 lines
713 B
C++
Raw Normal View History

2025-02-12 09:54:05 -05:00
#include "HomeScreenView.h"
#include "HomeScreenViewController.h"
#include "HomeScreenWindow.h"
#include <libui/AppDelegate.h>
class AppDelegate : public UI::AppDelegate {
public:
AppDelegate() = default;
virtual ~AppDelegate() = default;
LG::Size preferred_desktop_window_size() const override { return LG::Size(400, 300); }
bool application() override
{
auto& window = std::xos::construct<HomeScreenWindow>(window_size());
window.set_bitmap_format(LG::PixelBitmapFormat::RGBA); // Turning on Alpha channel
auto& dock_view = window.create_superview<HomeScreenView, HomeScreenViewController>();
return true;
}
private:
};
SET_APP_DELEGATE(AppDelegate);