Framework::refresh_opener always refreshes the main window because the refresh is carried out by the framework object:
Only way to avoid that would be implementing an observer in your app.js:
If your observer returns true, the the frameworks refresh method is not called. Obviously your observer should carry out the wanted refresh, as it is not happening otherwise.
Be aware that observer methods get called for refresh requests of other apps too!
Ralf