refactor: make savePath a property on DownloadItem (#18677)

This commit is contained in:
Shelley Vohr 2019-06-20 10:04:57 -07:00 committed by GitHub
parent e95d2129be
commit 536327151d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 30 additions and 15 deletions

View file

@ -209,6 +209,8 @@ void DownloadItem::BuildPrototype(v8::Isolate* isolate,
.SetMethod("isDone", &DownloadItem::IsDone)
.SetMethod("setSavePath", &DownloadItem::SetSavePath)
.SetMethod("getSavePath", &DownloadItem::GetSavePath)
.SetProperty("savePath", &DownloadItem::GetSavePath,
&DownloadItem::SetSavePath)
.SetMethod("setSaveDialogOptions", &DownloadItem::SetSaveDialogOptions)
.SetMethod("getSaveDialogOptions", &DownloadItem::GetSaveDialogOptions)
.SetMethod("getLastModifiedTime", &DownloadItem::GetLastModifiedTime)