- Electron version: 1.2.2
- Operating system: Linux

This is a problem only in linux. It works in OSX.

``` javascript
win.hide()
win.capturePage(function(img){
 // never called
})
```

shell/browser/api/electron_api_web_contents.cc
if (!inspectable_ontents_) {
    WebContentsDestroyed();
    return;
  }
  if (guest_delegate_)
    guest_delegate_->WillDestroy();
  
  
  Emit("will-destroy");
  
  
  bool not_owned_by_this = IsGuest() && attached_;
#if BUILDFLAG(ENABLE_ELECTRON_EXTENSIONS)
  
  if (type_ == Type::kBackgroundPage)
    not_owned_by_this = true;
#endif
  if (not_owned_by_this) {
    inspectable_ontents_->ReleaseWebContents();
    WebContentsDestroyed();
  }
  
}
void WebContents::Destroy() {