mirror of
https://github.com/rad4day/Waybar.git
synced 2025-07-16 16:02:39 +02:00
refactor(bar): use Gtk enums for position and orientation
Ensure that the position and the corresponding CSS class on window are always set.
This commit is contained in:
@@ -277,7 +277,7 @@ Task::Task(const waybar::Bar &bar, const Json::Value &config, Taskbar *tbar,
|
||||
handle_{tl_handle},
|
||||
seat_{seat},
|
||||
id_{global_id++},
|
||||
content_{bar.vertical ? Gtk::ORIENTATION_VERTICAL : Gtk::ORIENTATION_HORIZONTAL, 0} {
|
||||
content_{bar.orientation, 0} {
|
||||
zwlr_foreign_toplevel_handle_v1_add_listener(handle_, &toplevel_handle_impl, this);
|
||||
|
||||
button.set_relief(Gtk::RELIEF_NONE);
|
||||
@@ -730,7 +730,7 @@ static const wl_registry_listener registry_listener_impl = {.global = handle_glo
|
||||
Taskbar::Taskbar(const std::string &id, const waybar::Bar &bar, const Json::Value &config)
|
||||
: waybar::AModule(config, "taskbar", id, false, false),
|
||||
bar_(bar),
|
||||
box_{bar.vertical ? Gtk::ORIENTATION_VERTICAL : Gtk::ORIENTATION_HORIZONTAL, 0},
|
||||
box_{bar.orientation, 0},
|
||||
manager_{nullptr},
|
||||
seat_{nullptr} {
|
||||
box_.set_name("taskbar");
|
||||
|
Reference in New Issue
Block a user