* Electron version: 1.7.1
* Operating system: MacOS

### Expected behavior

The popup should have `window.opener` set

### Actual behavior

I was using native `window.open` in sandbox mode until this PR was merged : https://github.com/electron/electron/pull/8963

I switched to non-sandbox mode using the version 1.7.1 and what happen is that, if your main app is embedded in an iframe and if it open a new window using `window.open`, the new window won't have `window.opener` set

If I load the same app directly in the main window and not using the iframe, it is working as expected

I am using the code from https://github.com/electron/electron/blob/master/docs/api/window-open.md

### How to reproduce

In the main window load in an iframe your app.

In the app open a popup with `window.open`

The new popup does not have `window.opener` set
atom/browser/atom_browser_client.cc
static const char* const kCommonSwitchNames[] = {
    switches::kStandardSchemes,
    switches::kEnableSandbox,
    switches::kSecureSchemes
  };
  command_line->CopySwitchesFrom(
      *base::CommandLine::ForCurrentProcess(),
      kCommonSwitchNames, arraysize(kCommonSwitchNames));
  
  if (!g_custom_service_worker_schemes.empty())
    command_line->AppendSwitchASCII(switches::kRegisterServiceWorkerSchemes,
                                    g_custom_service_worker_schemes);
#if defined(OS_WIN)
  
  PWSTR current_app_id;
  if (SUCCEEDED(GetCurrentProcessExplicitAppUserModelID(&current_app_id))) {
    command_line->AppendSwitchNative(switches::kAppUserModelId, current_app_id);
    CoTaskMemFree(current_app_id);
  }
#endif
  if (delegate_) {
    auto app_path = static_cast<api::App*>(delegate_)->GetAppPath();
    command_line->AppendSwitchPath(switches::kAppPath, app_path);
  }
  content::WebContents* web_contents = GetWebContentsFromProcessID(process_id);
  if (web_contents)
    WebContentsPreferences::AppendExtraCommandLineSwitches(
        web_contents, command_line);
}
void AtomBrowserClient::DidCreatePpapiPlugin(