Git Product home page Git Product logo

Comments (4)

phazei avatar phazei commented on July 27, 2024

I took a look at the comments and it seems the GUID's changed for the later versions of Win11:

https://github.com/MScholtes/VirtualDesktop/blob/master/VirtualDesktop11-23H2.cs#L149-L190

I'm going to try switching those and see if it works or if it needs new win11 23h2 functions

from vd.ahk.

phazei avatar phazei commented on July 27, 2024

So, I'm really hoping the 23606 build I'm on matches the 23H2 build that has the new GUIDs. It took me a bit to understand, but I see now that the _vtable method is mapping the methods from the COMs. I updated the COM GUIDs to match the updated ones, but that didn't work by itself. I think the parameters for 23H2 so I changed the call back to:
DllCall(this.GetCurrentDesktop, "UPtr", this.IVirtualDesktopManagerInternal, "Ptr*", IVirtualDesktop_ofCurrentDesktop)

GetCurrentDesktop doesn't seem to return anything though, it seems to have been sharing the same _vtable 6 position so I didn't want to change that. But how exactly did you find out what # it was in the list? Is it possible to see the list of how the vtable looks like? I only have SciTE4AutoHotKey to debug this all and it only shows a long number for the values. Also, it seems GetCurrentDesktop returns an item of type IVirtualDesktop eg 3F07F4BE-B107-441A-AF0F-39D82529072C, so how does it get GetId() from it? I don't quite see where that comes from.

from vd.ahk.

phazei avatar phazei commented on July 27, 2024

So, it seems like the MScholtes/VirtualDesktop repo probably wouldn't work either. I'm not sure if this repo needed to be updated to match 23H2.

What I did find is a solution though. I found this https://github.com/itzjakm/VirtualDesktopAccessor (I'm guessing there's a typo and the submitter meant 23601). Seems to be a similar project but uses rust and compiles a DLL to be used with AHK. But they seem to have fixed it and found that there was an even more updated GUID. I updated that GUID and a couple others, then reverted the Win11 Insider build _vtable numbers back to stable Win11 numbers, and reverted a few Win11 method calls back to their Win10 equivalent, and it seems to be working now!

from vd.ahk.

JanChec avatar JanChec commented on July 27, 2024

The version from ↑ PR works! Thanks! 🥇

from vd.ahk.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.