-
Notifications
You must be signed in to change notification settings - Fork 32
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
Restoring positions after redocking does not work #10
Comments
Reading the config will not solve anything now. The app is now different. But I have tested it and it is very strange that it doesn't works for you. I don't have any Windows machine at home (I'm a Linux guy) and have to do this at work, but obviously I'm limited to my laptop and screens, and it works on mine so... I can't do more without help. Thank you for your time and help! |
Sure, just give me the link to the logging version. |
I've created a branch to solve this issue: I0010-restoring-positions-doesnt-work Sorry, I forgot to give instructions. Just stop you current app, start this one in maximum screen size (two or more monitors), wait a second, undock, wait until you see the windows appear, dock and wait until windows are moved to their (theoretical) position (it should take a few seconds until Windows sends screen resolution change messages) and stop it. There should be a wm.log file: attach it here. Again thank you for your help. |
Well... I understand why it doesn't works for you. When you undock the screen size doesn't changes. I don't know why. This is before undocking, 1920x1080
After undocking:
As you may see there is no resolution change: always 1920x1080. |
Oh, this might me connected: The screens are connected via a docking station. So you might need another way to access information about the screens. |
Ok. I've found related windows info:
So I have to EnumDisplayMonitors and act upon that information. Meanwhile, could you try the new version connecting the screens without the docking station? (Just to confirm the problem, not to take as a solution.) |
Edit: sorry, will reupload in a second |
wm.log |
Ok, I've managed to reproduce the failure. I'm going to work on this. It may take some time as I can't work on this just now. |
I've updated the loggin zip. Now it works in my laptop when:
Hope it works for you now. Tell me if it is OK or not. |
Nope, sorry... After undocking and redocking 2 monitors, still same behavior: Also I now cannot open desktop overview anymore (WIN+TAB)... |
I'm going to take the laptop at home and work on thins over the weekend. |
Well... I am not going to hold you off :) But I'll be able to test again on monday. |
Another logging version uploaded. There should be no behavior changes, just more log. I've seen there are two ways to obtain the screen/s resolution. Let's check the second one. |
This time most windows were restored (it took more time than in previous versions). Some windows were moved to other desktops and were not maximized. But they did not all stay on the same screen this time after redocking. Could you please anonymize window names and app names in the next version? It takes quite some time to go through the logs and fix this. |
On second try it did not work again... All windows were restored to the same screen. |
Yes. Sorry for the anonymization. I should have thought about that before asking for help. Sorry. Looking into the logs, it seems the resolution is: width: 5760, height: 1080.
Plus, there is a moment when there is only 3 monitors attached, and it reports 4:
When screen size increments (3mon. => 4) I get the new positions. This fourth monitor must be a virtual one to draw or prepare to draw windows on it. Then, when I get the positions they are already for one monitor:
As you can see, the position isn't negative anymore. It was left -1548, right -74. So I have to ignore the positions when... the system resolution is the same as the max resolution detected until now (5760x1080) and there are more monitors than there were when that resolution was first detected. Clearer: if I have 5760 with two monitors, I have to ignore positions when I have 5760 with three or more monitors. Unfortunately I don't have a system doing those things with screen resolution and positioning, so I'm going to try several algorithms that may be activated by an app parameter to see if I can fix it. |
I've uploaded a new version. It now takes in account not only the monitor count but also the virtual screen size (with all monitors.) I think this should work, so no parameters and one algorithm only. |
Nope, sorry: All windows are restored to one screen
|
Also, to make sure that we are on the same page: I talk about Desktops and Screens.
And there are two issues:
We are currently trying to fix issue 1. |
Hi, Now the difference with your machine: your machine gives the resolution changes before the dock or undock messages (which they aren't, BTW, I will receive that message when there is a network change (e.g. wired to wifi)) so I have to do everything in three steps. I've tested those steps and they work, again, in my computer. Thank you. |
Some windows were restored, some were not. Some windows changed desktops. I'll be on vacation for a month so you can take your time :D |
Another try to solve the issue. It works like a charm for me. |
Build from 5 days ago: Same old :( |
Hey, welcome back! |
Just fell over this handy utility after I for god-knows-what time redocked my Win10-Thinkpad-Onelink+ and had to re-sort all my windows. Unfortunately it doesn't seem to work for me. I downloaded the bin, extracted and ran. Tried clicking around with the get/save/read buttons both before and after redocking (several times) but nothing seems to happen. Don't know if I am missing a crucial step? Pity though, it's a good idea!! |
Hi, Try branch restoring-positions-doesnt-works or something like that. In that branch you don't need to use the menu, all is done automatically (when it works.) |
Fair enough, I can understand that. No worries, I'll keep looking. |
The version in the I0010-restoring-positions-doesnt-work branch works for me. Perhaps this should be merged to master so that this is the version people find by default? |
Yes. Absolutely. |
Done. |
And I'm glad it works for you man! I'm quite happy with it even when some windows (mostly MS) refuse to play fair. |
Thank you!
I just started using it, so I am crossing my fingers.
/Hans
…On Wed, Nov 13, 2019 at 1:49 PM Manuel ***@***.***> wrote:
And I'm glad it works for you man! I'm quite happy with it even when some
windows (mostly MS) refuse to play fair.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#10?email_source=notifications&email_token=AALESWTGL2IM2MKM7NDHWQTQTPZW3A5CNFSM4GGA55Z2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOED6BBZY#issuecomment-553390311>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AALESWXOUMTPYOP27CADO33QTPZW3ANCNFSM4GGA55ZQ>
.
|
The text was updated successfully, but these errors were encountered: