mirror of
https://github.com/kotatogram/kotatogram-desktop
synced 2025-09-18 14:00:09 +00:00
Split GTK integration into a singleton
This commit is contained in:
@@ -522,6 +522,11 @@ void ForceDisabled(QAction *action, bool disabled) {
|
||||
|
||||
MainWindow::MainWindow(not_null<Window::Controller*> controller)
|
||||
: Window::MainWindow(controller) {
|
||||
#ifndef DESKTOP_APP_DISABLE_DBUS_INTEGRATION
|
||||
qDBusRegisterMetaType<ToolTip>();
|
||||
qDBusRegisterMetaType<IconPixmap>();
|
||||
qDBusRegisterMetaType<IconPixmapList>();
|
||||
#endif // !DESKTOP_APP_DISABLE_DBUS_INTEGRATION
|
||||
}
|
||||
|
||||
void MainWindow::initHook() {
|
||||
@@ -911,14 +916,6 @@ void MainWindow::updateWaylandDecorationColors() {
|
||||
windowHandle()->resize(windowHandle()->size());
|
||||
}
|
||||
|
||||
void MainWindow::LibsLoaded() {
|
||||
#ifndef DESKTOP_APP_DISABLE_DBUS_INTEGRATION
|
||||
qDBusRegisterMetaType<ToolTip>();
|
||||
qDBusRegisterMetaType<IconPixmap>();
|
||||
qDBusRegisterMetaType<IconPixmapList>();
|
||||
#endif // !DESKTOP_APP_DISABLE_DBUS_INTEGRATION
|
||||
}
|
||||
|
||||
void MainWindow::initTrayMenuHook() {
|
||||
_trayIconMenuXEmbed.emplace(nullptr, trayIconMenu);
|
||||
_trayIconMenuXEmbed->deleteOnHide(false);
|
||||
|
Reference in New Issue
Block a user