// static
mate::Handle<WebContents> 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
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;
}