- 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 (type_ == Type::kRemote)
    return;
  if (!enable_devtools_)
    return;
  std::string state;
  if (type_ == Type::kWebView || type_ == Type::kBackgroundPage ||
      !owner_window()) {
    state = "detach";
  }
  bool activate = true;
  if (args && args->Length() == 1) {
    gin_helper::Dictionary options;
    if (args->GetNext(&options)) {
      options.Get("mode", &state);
      options.Get("activate", &activate);
    }
  }
  DCHECK(inspectable_ontents_);
  inspectable_ontents_->SetDockState(state);
  inspectable_ontents_->ShowDevTools(activate);
}
void WebContents::CloseDevTools() {
  if (type_ == Type::kRemote)
    return;
  DCHECK(inspectable_ontents_);
  inspectable_ontents_->CloseDevTools();
}
bool WebContents::IsDevToolsOpened() {