refactor and shizz

This commit is contained in:
2025-12-25 21:13:00 +01:00
parent a06c96f648
commit 9b5db719cb
27 changed files with 286 additions and 312 deletions

View File

@@ -22,7 +22,7 @@ App::App() {
try {
hyprlandMonitor =
this->hyprlandService.getMonitorByIndex(i);
this->hyprlandService->getMonitorByIndex(i);
} catch (const std::exception &ex) {
std::cerr << "[App] Failed to fetch Hyprland monitor: "
<< ex.what() << std::endl;
@@ -31,8 +31,7 @@ App::App() {
auto bar = new Bar(monitor->gobj(), this->hyprlandService,
this->trayService, hyprlandMonitor->id);
auto bar = new Bar(monitor->gobj(), hyprlandMonitor->id);
bar->set_application(app);
bar->show();
@@ -47,16 +46,16 @@ App::App() {
}
bars.clear();
this->trayService.stop();
this->trayService->stop();
});
}
void App::setupServices() {
this->hyprlandService.socketEventSignal.connect(sigc::mem_fun(
this->hyprlandService, &HyprlandService::on_hyprland_event));
this->hyprlandService->socketEventSignal.connect(sigc::mem_fun(
*this->hyprlandService, &HyprlandService::on_hyprland_event));
this->hyprlandService.start();
this->trayService.start();
this->hyprlandService->start();
this->trayService->start();
}
int App::run() { return this->app->run(); }