ddcec84ace
* chore: bump chromium in DEPS to 116.0.5791.0 * 4504298: Relax checks in BlobDataBuilder::AppendBlob. https://chromium-review.googlesource.com/c/chromium/src/+/4504298 * chore: fixup patch indices --------- Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com> Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
34 lines
1.6 KiB
Diff
34 lines
1.6 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Cheng Zhao <zcbenz@gmail.com>
|
|
Date: Thu, 20 Sep 2018 17:45:00 -0700
|
|
Subject: blink_file_path.patch
|
|
|
|
This is used by editors to obtain the filesystem path from a dragged file. See
|
|
documentation at https://electronjs.org/docs/api/file-object
|
|
|
|
diff --git a/third_party/blink/renderer/core/fileapi/file.h b/third_party/blink/renderer/core/fileapi/file.h
|
|
index 2cc436a725f13d3fdf5b5eed6af73695d3c19953..b11c146fc86e55324b61a057d45b96e8c96b304b 100644
|
|
--- a/third_party/blink/renderer/core/fileapi/file.h
|
|
+++ b/third_party/blink/renderer/core/fileapi/file.h
|
|
@@ -206,6 +206,9 @@ class CORE_EXPORT File final : public Blob {
|
|
}
|
|
const String& name() const { return name_; }
|
|
|
|
+ // Getter for the path IDL attribute.
|
|
+ const String& path() const { return GetPath(); }
|
|
+
|
|
// Getter for the lastModified IDL attribute,
|
|
// http://dev.w3.org/2006/webapi/FileAPI/#file-attrs
|
|
// This method calls CaptureSnapshotIfNeeded, and thus can involve synchronous
|
|
diff --git a/third_party/blink/renderer/core/fileapi/file.idl b/third_party/blink/renderer/core/fileapi/file.idl
|
|
index 4339a27e87c12279b2a2f08a7c3d181e7265a986..6aebb1ba4f74a4cfdc546fe5903032f4bc23dd30 100644
|
|
--- a/third_party/blink/renderer/core/fileapi/file.idl
|
|
+++ b/third_party/blink/renderer/core/fileapi/file.idl
|
|
@@ -31,6 +31,7 @@
|
|
] interface File : Blob {
|
|
[CallWith=ExecutionContext] constructor(sequence<BlobPart> fileBits, USVString fileName, optional FilePropertyBag options = {});
|
|
readonly attribute DOMString name;
|
|
+ readonly attribute DOMString path;
|
|
readonly attribute long long lastModified;
|
|
|
|
// Non-standard APIs
|