Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error with multiple monitors #2

Closed
bentobit8 opened this issue Jan 26, 2022 · 2 comments
Closed

error with multiple monitors #2

bentobit8 opened this issue Jan 26, 2022 · 2 comments

Comments

@bentobit8
Copy link

bentobit8 commented Jan 26, 2022

it show this error with multiple monitors;

Traceback (most recent call last):
  File "/home/ben/.local/bin/Qminimize", line 97, in <module>
    main()
  File "/home/ben/.local/bin/Qminimize", line 84, in main
    string = minimized_windows_list(minimized_icons)
  File "/home/ben/.local/bin/Qminimize", line 68, in minimized_windows_list
    if c.window[i].info()["minimized"] is True:
KeyError: 'minimized'

there is no error when unplugged external monitor and reboot.

@bentobit8
Copy link
Author

bentobit8 commented Jan 27, 2022

i've found the solution;
line 35 change

for i in range (0, len("/usr/share/applications"), 1):

to

for i in range (0, len([item for item in os.listdir("/usr/share/applications")]), 1):

and put this ontop

import os

@emanuelep57
Copy link
Owner

Fixed this, thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants