Skip to content

Commit

Permalink
开启全屏时总是隐藏bar 关闭全屏时总是显示bar
Browse files Browse the repository at this point in the history
  • Loading branch information
yaocccc committed Oct 9, 2023
1 parent 43872d6 commit 46c5aa7
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 6 deletions.
2 changes: 1 addition & 1 deletion DEF/statusbar/packages/wifi.sh
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ update() {
[ "$wifi_text" = "" ] && wifi_text=$wifi_disconnected

icon=" $wifi_icon "
text=" $wifi_text "
text="$wifi_text "

sed -i '/^export '$this'=.*$/d' $tempfile
printf "export %s='%s%s%s%s%s'\n" $this "$signal" "$icon_color" "$icon" "$text_color" "$text" >> $tempfile
Expand Down
16 changes: 11 additions & 5 deletions dwm.c
Original file line number Diff line number Diff line change
Expand Up @@ -2439,13 +2439,19 @@ setfullscreen(Client *c, int fullscreen)
void
fullscreen(const Arg *arg)
{
if (selmon->sel) {
if (!selmon->sel) {
togglebar(arg);
return;
}
if (selmon->sel->isfullscreen) {
setfullscreen(selmon->sel, 0);
if (!selmon->showbar)
togglebar(arg);
} else {
setfullscreen(selmon->sel, 1);
if (selmon->showbar)
setfullscreen(selmon->sel, 1);
else
setfullscreen(selmon->sel, 0);
togglebar(arg);
}
togglebar(arg);
}

void
Expand Down

0 comments on commit 46c5aa7

Please sign in to comment.