Skip to content

feat: add window.set_visible_on_all_workspaces() #185

@srsholmes

Description

@srsholmes

As discussed here.

It would be great to have the ability to have some sort of API, possibly window.set_visible_on_all_workspaces() to allow apps made with tao the ability to be shown on all spaces, regardless of what space they were created on.

I have achieved this in a local copy of tao by adding the following in src/platform_impl/macos/window.rs line 195.

      ns_window.setCollectionBehavior_(NSWindowCollectionBehavior::NSWindowCollectionBehaviorCanJoinAllSpaces);
      ns_window.setCollectionBehavior_(NSWindowCollectionBehavior::NSWindowCollectionBehaviorMoveToActiveSpace);
       // TODO: get a real level?
      ns_window.setLevel_(10000);

I hope that helps. Please let me know if you need a hand implementing or testing.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions