Function XdgSurface.getPopup

assign the xdg_popup surface role

XdgPopup getPopup (
  XdgSurface parent,
  XdgPositioner positioner
);

This creates an xdg_popup object for the given xdg_surface and gives the associated wl_surface the xdg_popup role.

If null is passed as a parent, a parent surface must be specified using some other protocol, before committing the initial state.

See the documentation of xdg_popup for more details about what an xdg_popup is and how it is used.