* Electron Version 6.0.0-beta.12
* Operating System Windows 10 64 bit

Expected Behavior
webContents.print() should send print a job to the specified printer

Actual behavior
Nothing happens. Callback gets called much latter, for example on program exit.

To Reproduce
let print_options = { 
    silent: true,
    printBackground: true,
    deviceName: barcode_device_name 
}
print_window.webContents.print(print_options, (data) => {
    console.log(`print result: ${data}`)
})

Related to #17260
shell/browser/api/atom_api_web_contents.cc
Emit("activate");
}
void WebContents::UpdateTargetURL(content::WebContents* source,
                                  const GURL& url) {
  Emit("update-target-url", url);
}
bool WebContents::HandleKeyboardEvent(
    content::WebContents* source,
    const content::NativeWebKeyboardEvent& event) {
  if (type_ == Type::WEB_VIEW && embedder_) {
    
    return embedder_->HandleKeyboardEvent(source, event);
  } else {
    
    return CommonWebContentsDelegate::HandleKeyboardEvent(source, event);
  }
}
content::KeyboardEventProcessingResult WebContents::PreHandleKeyboardEvent(
    content::WebContents* source,
    const content::NativeWebKeyboardEvent& event) {
  if (event.GetType() == blink::WebInputEvent::Type::kRawKeyDown ||
      event.GetType() == blink::WebInputEvent::Type::kKeyUp) {
    bool prevent_default = Emit("before-input-event", event);
    if (prevent_default) {
      return content::KeyboardEventProcessingResult::HANDLED;
    }
  }
  return content::KeyboardEventProcessingResult::NOT_HANDLED;
}
void WebContents::ContentsZoomChange(bool zoom_in) {