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

Ability to bring a floating-window in the Dock-Manager to the foreground #59

Closed
D-Biela opened this issue Jan 24, 2023 · 3 comments
Closed
Assignees

Comments

@D-Biela
Copy link

D-Biela commented Jan 24, 2023

Is your feature request related to a problem? Please describe.

Id like to have the possibility to bring a floating window, hidden behind other floating windows, to the foreground. Its essential for our new app, which relies heavily on a windows-like ui with potentially multiple simultaneous floating windows.

Describe the solution you'd like

A Method to focus / bring a floating pane to the foreground.
Something like this:

this.dockingComponent!.layout.floatingPanes?.find((pane) => ...).focus();

Describe alternatives you've considered

An alternative would be to dig in the dockmanager shadow-dom with JS and set the z-index of the desired floatingPane to 1. This is an ugly workaround we prefer not to use.

@ChronosSF ChronosSF transferred this issue from IgniteUI/igniteui-angular Jan 25, 2023
@onlyexeption
Copy link
Contributor

@D-Biela In order to address the problem accurately, I would appreciate if you could provide some additional information regarding your requirements. We can implement a method that takes a pane's contentId and focus it's parent, thus bringing it on top. Could you please confirm if this approach would be sufficient for your specific use case?

@D-Biela
Copy link
Author

D-Biela commented May 23, 2023

Hey @onlyexeption
Thanks for the response!

Lets take this layout as an example:

{
  "rootPane": {
    "type": "splitPane",
    "orientation": "horizontal",
    "panes": [
    ],
    "id": "befe5d33-6e41-448c-ac52-e069a8cdf4d2"
  },
  "floatingPanes": [
    {
      "type": "splitPane",
      "orientation": "horizontal",
      "floatingHeight": 919.46484375,
      "floatingWidth": 813.5078125,
      "floatingLocation": {
        "x": 829.87109375,
        "y": 204.9921875
      },
      "panes": [
        {
          "allowPinning": false,
          "type": "contentPane",
          "contentId": "debug",
          "header": "Todo & Debug-Window",
          "id": "53e7cd31-7e24-4e9d-8b45-17b6de0e5f72"
        }
      ],
      "id": "294a90f2-1b6c-43ed-b705-9736cb42643c"
    },
    {
      "type": "splitPane",
      "orientation": "vertical",
      "panes": [
        {
          "allowPinning": false,
          "type": "contentPane",
          "contentId": "auction-details",
          "header": "Auktion - Details",
          "id": "9ffe9829-432f-49a2-b21b-aa9a1c62a9e5"
        }
      ],
      "floatingLocation": {
        "x": 143.375,
        "y": 250.3125
      },
      "floatingWidth": 590.671875,
      "floatingHeight": 418.875,
      "id": "811cbd48-c7c9-4dc7-806b-925715f7e9fc"
    }
  ]

}

Assume that the current layout with the example above looks like this:

image

I would like to focus and bring the floating split-pane to the foreground which is atm nearly completely covered by the "ToDo & Debug-Window"-floating-pane (as seen in the screenshot), without actively clicking ON the specific floating-pane.

Another use case would be when an event, triggered by a websocket connection, subsequently triggers the focusing of the relevant floating window for the user. This would bring it to the foreground, enabling the user to immediately notice that there is something that needs attention.

As I mentioned earlier, an approach like this would be cool: this.dockingComponent!.layout.floatingPanes?.find((pane) => ...).focus();

Alternatively, as you suggested, we could have a method that accepts the contentId as a parameter: this.dockingComponent.focusPane(contentId)

@igdmdimitrov
Copy link
Contributor

Added method focusPane in v1.13.0

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

No branches or pull requests

4 participants