Yoda/src/app/browser.cpp

47 lines
887 B
C++
Raw Normal View History

2024-08-05 03:15:41 +03:00
#include "browser.h"
namespace app
{
// Construct
Browser::Browser(
GtkApplication *application
) {
2024-08-05 23:43:42 +03:00
// Init dependencies
this->application = application;
2024-08-05 03:15:41 +03:00
// Init GTK
this->gtk = gtk_application_window_new(
GTK_APPLICATION(
2024-08-05 23:43:42 +03:00
this->application
2024-08-05 03:15:41 +03:00
)
);
gtk_window_set_default_size(
GTK_WINDOW(
this->gtk
),
Browser::WIDTH,
Browser::HEIGHT
);
// Init requirements
this->header = new browser::Header(
this
);
gtk_window_set_titlebar(
GTK_WINDOW(
this->gtk
),
this->header->gtk
);
// Render
gtk_widget_show(
GTK_WIDGET(
this->gtk
)
);
}
}