- 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
v8::Isolate* isolate = JavascriptEnvironment::GetIsolate();
  gin_helper::Promise<v8::Local<v8::Value>> promise(isolate);
  v8::Local<v8::Promise> handle = promise.GetHandle();
  PrintPreviewMessageHandler::FromWebContents(ontents())
      ->PrintToPDF(std::move(settings), std::move(promise));
  return handle;
}
#endif
void WebContents::AddWorkSpace(gin::Arguments* args,
                               const base::FilePath& path) {
  if (path.empty()) {
    gin_helper::ErrorThrower(args->isolate())
        .ThrowError("path cannot be empty");
    return;
  }
  DevToolsAddFileSystem(std::string(), path);
}
void WebContents::RemoveWorkSpace(gin::Arguments* args,
                                  const base::FilePath& path) {
  if (path.empty()) {
    gin_helper::ErrorThrower(args->isolate())
        .ThrowError("path cannot be empty");
    return;
  }
  DevToolsRemoveFileSystem(path);
}
void WebContents::Undo() {
  ontents()->Undo();
}
void WebContents::Redo() {