mirror of
https://github.com/DreamMaoMao/maomaowm.git
synced 2026-02-12 04:28:35 -05:00
opt: disable switch proportion action in some case
This commit is contained in:
parent
33a0fe2485
commit
f542d5d5e6
1 changed files with 15 additions and 0 deletions
|
|
@ -518,6 +518,14 @@ int setkeymode(const Arg *arg) {
|
|||
}
|
||||
|
||||
int set_proportion(const Arg *arg) {
|
||||
|
||||
if (selmon->isoverview || !is_scroller_layout(selmon))
|
||||
return 0;
|
||||
|
||||
if (selmon->visible_tiling_clients == 1 &&
|
||||
!scroller_ignore_proportion_single)
|
||||
return 0;
|
||||
|
||||
if (selmon->sel) {
|
||||
unsigned int max_client_width =
|
||||
selmon->w.width - 2 * scroller_structs - gappih;
|
||||
|
|
@ -919,6 +927,13 @@ int switch_proportion_preset(const Arg *arg) {
|
|||
return 0;
|
||||
}
|
||||
|
||||
if (selmon->isoverview || !is_scroller_layout(selmon))
|
||||
return 0;
|
||||
|
||||
if (selmon->visible_tiling_clients == 1 &&
|
||||
!scroller_ignore_proportion_single)
|
||||
return 0;
|
||||
|
||||
if (selmon->sel) {
|
||||
|
||||
for (int i = 0; i < config.scroller_proportion_preset_count; i++) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue