getUI().addWindow with CDI

I am using vaadin 8 - java ee 7 and wildfly.

I want use a subwindow.

Until now i use the following working code:

I create a new Window

public class TitleDetailView extends Window {
	public TitleNewView() {

I call it with:

getUI().addWindow(new TitleDetailView())

My qestion is:
Is there a possibility to make it with CDI and Navigator?

Something like this:

@CDIView("TitleNewView")
public class TitleNewView extends Window {

And use then navigator like:

Button callButton = new Button("Call", e -> UI.getCurrent().getNavigator().navigateTo("TitleNewView"));

Navigator manages the container designated to it, so you cannot add the Window directly as a view I guess. But you could create a “proxy” view which opens the Window e.g. in enter() method when you navigate to it.

Ohhh.
Can you perhaps give me a code snipped what you mean with proxy view.

Something like in this pattern

public class TitleDetailWindow extends Window {
	public TitleDetailWindow() {
	   ...
    }
}

@CDIView("TitleNewView")
public class TitleNewView extends VerticalLayout implements View {
   ...
   @Override
   enter() {
      getUI().addWindow(new TitleDetailWindow())
   }
   
}

thanks