Introducce AAppIconLabel class

Implemented for hyprland
This commit is contained in:
MisterPine
2023-07-10 22:50:58 +02:00
parent 6e9ba3fc01
commit 00e143d47e
5 changed files with 156 additions and 112 deletions

View File

@ -1,13 +1,13 @@
#include <fmt/format.h>
#include "AIconLabel.hpp"
#include "AAppIconLabel.hpp"
#include "bar.hpp"
#include "modules/hyprland/backend.hpp"
#include "util/json.hpp"
namespace waybar::modules::hyprland {
class Window : public waybar::AIconLabel, public EventHandler {
class Window : public waybar::AAppIconLabel, public EventHandler {
public:
Window(const std::string&, const waybar::Bar&, const Json::Value&);
virtual ~Window();
@ -40,8 +40,6 @@ class Window : public waybar::AIconLabel, public EventHandler {
void onEvent(const std::string&) override;
void queryActiveWorkspace();
void setClass(const std::string&, bool enable);
void updateAppIconName();
void updateAppIcon();
bool separate_outputs;
std::mutex mutex_;
@ -55,9 +53,6 @@ class Window : public waybar::AIconLabel, public EventHandler {
bool all_floating_;
bool hidden_;
bool fullscreen_;
unsigned app_icon_size_{24};
bool update_app_icon_{true};
std::string app_icon_name_;
};
} // namespace waybar::modules::hyprland