Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(362)

Unified Diff: Source/core/clipboard/DataObject.h

Issue 193803002: Prevent web content from forging File entries in drag and drop. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | Source/core/page/DragController.cpp » ('j') | Source/core/page/DragData.cpp » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/clipboard/DataObject.h
diff --git a/Source/core/clipboard/DataObject.h b/Source/core/clipboard/DataObject.h
index 6c5e1cf10d82ade22630d2fcb25a0a2ec90ccbf9..247ca0f5bc62444928d015ec407cf0c27f4e9a95 100644
--- a/Source/core/clipboard/DataObject.h
+++ b/Source/core/clipboard/DataObject.h
@@ -91,6 +91,10 @@ public:
int modifierKeyState() const { return m_modifierKeyState; }
void setModifierKeyState(int modifierKeyState) { m_modifierKeyState = modifierKeyState; }
+ // The accessor should only ever be called by DragData.
+ const String& filenameForNavigation() const { return m_filenameForNavigation; }
+ void setFilenameForNavigation(const String& filename) { m_filenameForNavigation = filename; }
+
// FIXME: oilpan: This trace() has to trace Supplementable.
void trace(Visitor*);
@@ -104,6 +108,8 @@ private:
WillBeHeapVector<RefPtrWillBeMember<DataObjectItem> > m_itemList;
+ String m_filenameForNavigation;
+
// State of Shift/Ctrl/Alt/Meta keys.
int m_modifierKeyState;
};
« no previous file with comments | « no previous file | Source/core/page/DragController.cpp » ('j') | Source/core/page/DragData.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698