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

Side by Side Diff: Source/core/platform/chromium/ChromiumDataObject.cpp

Issue 24469004: Amusingly deprecate the generic version of 'ExceptionState::throwDOMException'. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 2 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2008, 2009, 2012 Google Inc. All rights reserved. 2 * Copyright (c) 2008, 2009, 2012 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
87 87
88 void ChromiumDataObject::clearAll() 88 void ChromiumDataObject::clearAll()
89 { 89 {
90 m_itemList.clear(); 90 m_itemList.clear();
91 } 91 }
92 92
93 PassRefPtr<ChromiumDataObjectItem> ChromiumDataObject::add(const String& data, c onst String& type, ExceptionState& es) 93 PassRefPtr<ChromiumDataObjectItem> ChromiumDataObject::add(const String& data, c onst String& type, ExceptionState& es)
94 { 94 {
95 RefPtr<ChromiumDataObjectItem> item = ChromiumDataObjectItem::createFromStri ng(type, data); 95 RefPtr<ChromiumDataObjectItem> item = ChromiumDataObjectItem::createFromStri ng(type, data);
96 if (!internalAddStringItem(item)) { 96 if (!internalAddStringItem(item)) {
97 es.throwDOMException(NotSupportedError); 97 es.throwUninformativeAndGenericDOMException(NotSupportedError);
98 return 0; 98 return 0;
99 } 99 }
100 return item; 100 return item;
101 } 101 }
102 102
103 PassRefPtr<ChromiumDataObjectItem> ChromiumDataObject::add(PassRefPtr<File> file , ScriptExecutionContext* context) 103 PassRefPtr<ChromiumDataObjectItem> ChromiumDataObject::add(PassRefPtr<File> file , ScriptExecutionContext* context)
104 { 104 {
105 if (!file) 105 if (!file)
106 return 0; 106 return 0;
107 107
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after
255 return true; 255 return true;
256 } 256 }
257 257
258 void ChromiumDataObject::internalAddFileItem(PassRefPtr<ChromiumDataObjectItem> item) 258 void ChromiumDataObject::internalAddFileItem(PassRefPtr<ChromiumDataObjectItem> item)
259 { 259 {
260 ASSERT(item->kind() == DataTransferItem::kindFile); 260 ASSERT(item->kind() == DataTransferItem::kindFile);
261 m_itemList.append(item); 261 m_itemList.append(item);
262 } 262 }
263 263
264 } // namespace WebCore 264 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/core/inspector/InspectorStyleSheet.cpp ('k') | Source/core/platform/chromium/ClipboardChromium.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698