Files
Waybar/include/modules/dwl/window.hpp
T

39 lines
833 B
C++
Raw Normal View History

2024-03-14 23:07:45 +03:00
#pragma once
#include <fmt/format.h>
#include <string>
#include "AAppIconLabel.hpp"
#include "bar.hpp"
#include "dwl-ipc-unstable-v2-client-protocol.h"
2024-03-22 23:21:57 +01:00
#include "util/json.hpp"
2024-03-14 23:07:45 +03:00
namespace waybar::modules::dwl {
class Window : public AAppIconLabel, public sigc::trackable {
public:
2026-02-04 09:24:14 +01:00
Window(const std::string&, const waybar::Bar&, const Json::Value&);
~Window();
2024-03-14 23:07:45 +03:00
void handle_layout(const uint32_t layout);
2026-02-04 09:24:14 +01:00
void handle_title(const char* title);
void handle_appid(const char* ppid);
void handle_layout_symbol(const char* layout_symbol);
2024-03-14 23:07:45 +03:00
void handle_frame();
2026-02-04 09:24:14 +01:00
struct zdwl_ipc_manager_v2* status_manager_;
2024-03-22 23:21:57 +01:00
2024-03-14 23:07:45 +03:00
private:
2026-02-04 09:24:14 +01:00
const Bar& bar_;
2024-03-14 23:07:45 +03:00
std::string title_;
std::string appid_;
std::string layout_symbol_;
uint32_t layout_;
2026-02-04 09:24:14 +01:00
struct zdwl_ipc_output_v2* output_status_;
2024-03-14 23:07:45 +03:00
};
} // namespace waybar::modules::dwl