mirror of
https://github.com/rad4day/Waybar.git
synced 2023-12-21 10:22:59 +01:00
fix: don't a warning for a width/height of 0
This commit is contained in:
parent
27f89bdcc3
commit
e3fdd6d94a
@ -121,7 +121,7 @@ void waybar::Bar::onConfigure(GdkEventConfigure* ev) {
|
|||||||
auto tmp_width = width_;
|
auto tmp_width = width_;
|
||||||
if (ev->height > static_cast<int>(height_)) {
|
if (ev->height > static_cast<int>(height_)) {
|
||||||
// Default minimal value
|
// Default minimal value
|
||||||
if (height_ != 1) {
|
if (height_ > 1) {
|
||||||
spdlog::warn(MIN_HEIGHT_MSG, height_, ev->height);
|
spdlog::warn(MIN_HEIGHT_MSG, height_, ev->height);
|
||||||
}
|
}
|
||||||
if (config["height"].isUInt()) {
|
if (config["height"].isUInt()) {
|
||||||
@ -132,7 +132,7 @@ void waybar::Bar::onConfigure(GdkEventConfigure* ev) {
|
|||||||
}
|
}
|
||||||
if (ev->width > static_cast<int>(width_)) {
|
if (ev->width > static_cast<int>(width_)) {
|
||||||
// Default minimal value
|
// Default minimal value
|
||||||
if (width_ != 1) {
|
if (width_ > 1) {
|
||||||
spdlog::warn(MIN_WIDTH_MSG, width_, ev->width);
|
spdlog::warn(MIN_WIDTH_MSG, width_, ev->width);
|
||||||
}
|
}
|
||||||
if (config["width"].isUInt()) {
|
if (config["width"].isUInt()) {
|
||||||
|
Loading…
Reference in New Issue
Block a user