Skip to content

Commit

Permalink
chore: remove redundant else statement
Browse files Browse the repository at this point in the history
  • Loading branch information
Syndelis committed Oct 14, 2023
1 parent 5e44cb6 commit 5a380da
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/group.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -107,17 +107,15 @@ auto Group::update() -> void {
Gtk::Box& Group::getBox() { return is_drawer ? (is_first_widget ? box : revealer_box) : box; }

void Group::addWidget(Gtk::Widget& widget) {
if (is_drawer) {
getBox().pack_start(widget, false, false);
getBox().pack_start(widget, false, false);

if (is_drawer) {
if (is_first_widget) {
// Necessary because of GTK's hitbox detection
addHoverHandlerTo(widget);
} else {
widget.get_style_context()->add_class(add_class_to_drawer_children);
}
} else {
getBox().pack_start(widget, false, false);
}

is_first_widget = false;
Expand Down

0 comments on commit 5a380da

Please sign in to comment.