Hello, this patch is in pending status, is there any way I can improve it?
IMO there is no way to 'correctly' implement OpenInputDesktop before implementing SwitchDesktop, as far as SwitchDesktop is a stub, it is safe to assume that OpenInputDesktop will always return either NULL or Winsta0/Default, that is what the patch does and what the tests in [PATCH 3/5] shows..
It is not trivial to implement SwitchDesktop, also I don't know any real world app needing SwitchDesktop except some virtual desktop manager, so I'm not sure it is worth to spend time on implementing SwitchDesktop. However, OpenInputDesktop is needed by multiple apps (TeamViewer, QQ International, Inspect tool from Windows Platform SDK as bug 12067), is it acceptable to submit such a 'better stub' to Wine and leaving SwitchDesktop as a stub?
Any comment is great appreciated!
On Tue, Oct 8, 2013 at 11:41 AM, Qian Hong qhong@codeweavers.com wrote:
Fixed http://bugs.winehq.org/show_bug.cgi?id=12067 , let QQ users happy :)
dlls/user32/tests/winstation.c | 22 ---------------------- dlls/user32/winstation.c | 22 +++++++++++++++++++--- 2 files changed, 19 insertions(+), 25 deletions(-)
I don't think it's possible to properly implement SwitchDesktop in either the X11 or Mac driver. There's just nothing sensible for it to do.
One possible strategy would be to implement SwitchDesktop in user32 and wineserver. Wineserver could logically track the input desktop, and OpenInputDesktop would return the "correct" desktop, but SwitchDesktop wouldn't really do anything. If in the future we decide there's something SwitchDesktop can do that makes sense, we can add a function for it to the user driver, and OpenInputDesktop probably won't need to change.
Hi Vincent,
Thanks a lot for the advice, I'll try that.
On Thu, Oct 10, 2013 at 12:41 AM, Vincent Povirk madewokherd@gmail.com wrote:
I don't think it's possible to properly implement SwitchDesktop in either the X11 or Mac driver. There's just nothing sensible for it to do.
That's one reason that I didn't try to implement SwitchDesktop, I was not very sure about this, thanks for confirming.
One possible strategy would be to implement SwitchDesktop in user32 and wineserver. Wineserver could logically track the input desktop, and OpenInputDesktop would return the "correct" desktop, but SwitchDesktop wouldn't really do anything. If in the future we decide there's something SwitchDesktop can do that makes sense, we can add a function for it to the user driver, and OpenInputDesktop probably won't need to change.
I ever though about this, but gave up. After more thought, I agree that this is a better approach, thanks again!