I tried different ways to close the popup:
- The dialog shows closeIcon which closes the popup
- A button next to the inlineFrame with partialSubmit resets the url and closes the popup
- Autoclose enabled
Finally i had to avoid the whole popup to have a good result.
Instead of using a real popup i created a BTF based on pages with one page in it:
<f:view>
<af:document id="d1"
title="Online Postfach Mitteilung">
<af:form id="f1">
<af:panelStretchLayout id="psl1" bottomHeight="40px">
<f:facet name="center">
<af:inlineFrame id="if1" sizing="preferred"
source="#{myBean.URL}"/>
</f:facet>
</af:panelStretchLayout>
</af:form>
</af:document>
</f:view>
I embed this BTF as TF-Call in my BTF of the application and set the option to run as dialog:
Finally i had the exact same result but my close "X" from dialog avoids the second download of the pdf via the servlet in my inlineFrame.