From: Cheng Zhao Date: Tue, 29 Apr 2014 03:39:31 +0000 (+0800) Subject: Fix compilation error on Windows. X-Git-Tag: v0.12.0~3 X-Git-Url: http://git.khamidou.com/?a=commitdiff_plain;h=dc9778f0f2dfe037778410bc36cf55a05946023a;p=electron.git Fix compilation error on Windows. --- diff --git a/atom/browser/api/atom_api_web_contents.cc b/atom/browser/api/atom_api_web_contents.cc index 8195a336..fcc0ea2e 100644 --- a/atom/browser/api/atom_api_web_contents.cc +++ b/atom/browser/api/atom_api_web_contents.cc @@ -198,7 +198,7 @@ void WebContents::OnRendererMessageSync(const string16& channel, // static mate::Handle WebContents::Create( v8::Isolate* isolate, content::WebContents* web_contents) { - return CreateHandle(isolate, new WebContents(web_contents)); + return mate::CreateHandle(isolate, new WebContents(web_contents)); } } // namespace api diff --git a/atom/browser/native_window.cc b/atom/browser/native_window.cc index ed1e7afe..c9cba5a9 100644 --- a/atom/browser/native_window.cc +++ b/atom/browser/native_window.cc @@ -515,7 +515,8 @@ void NativeWindow::DevToolsSaveToFile(const std::string& url, if (it != saved_files_.end() && !save_as) { path = it->second; } else { - if (!file_dialog::ShowSaveDialog(this, url, base::FilePath(url), &path)) + base::FilePath default_path(base::FilePath::FromUTF8Unsafe(url)); + if (!file_dialog::ShowSaveDialog(this, url, default_path, &path)) return; }