Files
bar/include/widgets/controlCenter/controlCenter.hpp
2026-02-04 15:52:31 +01:00

32 lines
963 B
C++

#pragma once
#include "components/popover.hpp"
#include "gtkmm/box.h"
#include "gtkmm/button.h"
#include "gtkmm/label.h"
#include "gtkmm/stack.h"
#include "widgets/controlCenter/mediaControl.hpp"
#include "widgets/weather.hpp"
#include <unordered_map>
class ControlCenter : public Popover {
public:
ControlCenter(std::string icon, std::string name);
private:
Gtk::Box container;
Gtk::Box tabRow;
Gtk::Stack contentStack;
Gtk::Box controlCenterContainer;
WeatherWidget weatherWidget;
Gtk::Button mediaControl;
Gtk::Button testTabButton;
std::shared_ptr<MprisController> mprisController = MprisController::getInstance();
std::unordered_map<std::string, MediaControlWidget*> mediaWidgets;
void addPlayerWidget(const std::string &bus_name);
void removePlayerWidget(const std::string &bus_name);
void setActiveTab(const std::string &tab_name);
};