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

Fix the get owner DockingManagerWindow and Update drag and drop #394

Merged
merged 5 commits into from
Nov 4, 2022

Conversation

Wenveo
Copy link
Contributor

@Wenveo Wenveo commented Nov 1, 2022

See: pull #350 | issue #349

Before:
image
this = FloatingWindow, GetWindow(this) = self.
but, where DockingManagerWindow ?🤣

Now:
image
Get DockingManagerWindow correctly

@Wenveo Wenveo changed the title Fix the get owner window in the CreateOverlayWindow Fix the get owner DockingManagerWindow in the CreateOverlayWindow Nov 1, 2022
@Wenveo Wenveo changed the title Fix the get owner DockingManagerWindow in the CreateOverlayWindow Fix the get owner DockingManagerWindow in the CreateOverlayWindow and Implement new drag and drop handling Nov 2, 2022
@Wenveo
Copy link
Contributor Author

Wenveo commented Nov 2, 2022

The beginning of the video is the default theme (OwnedByDockingManagerWindow = true).
Then I will switch the theme and OwnedByDockingManagerWindow set to false.

DragService now handles floating Windows with different owners correctly.

2022-11-02_23-21-31.mp4

@Wenveo Wenveo changed the title Fix the get owner DockingManagerWindow in the CreateOverlayWindow and Implement new drag and drop handling Fix the get owner DockingManagerWindow and Implement new drag and drop handling Nov 2, 2022
- Add **GetWindowZOrder** to Win32Helper
- Add **GetOverlayWindowHostsByZOrder** in order to get all the floating window and the child window
- Optimize the code in **DragService**
@Wenveo
Copy link
Contributor Author

Wenveo commented Nov 3, 2022

I tested different scenarios:

  • true and false
    AnchorableFloatingWindowControl (OwnedByDockingManagerWindow = true)
    DocumentFloatingWindowControl (OwnedByDockingManagerWindow = false)

  • false and true
    AnchorableFloatingWindowControl (OwnedByDockingManagerWindow = false)
    DocumentFloatingWindowControl (OwnedByDockingManagerWindow = true)

  • And true true or false false
    ......

I created a method to get the Z order of all Windows (floating window and DockingManager window).
Even floating Windows with different owners can drag and show correctly.

image
image

@Wenveo Wenveo changed the title Fix the get owner DockingManagerWindow and Implement new drag and drop handling Fix the get owner DockingManagerWindow and Update drag and drop Nov 4, 2022
@Dirkster99 Dirkster99 merged commit 9e5336d into Dirkster99:master Nov 4, 2022
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

Successfully merging this pull request may close these issues.

2 participants