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

Side by Side Diff: Source/core/dom/DOMException.cpp

Issue 1532413002: Added Dartium changes onto 45.0.2454.104 (Closed) Base URL: http://src.chromium.org/blink/branches/chromium/2454
Patch Set: Created 5 years 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
« no previous file with comments | « Source/core/core.gypi ('k') | Source/core/dom/ScriptLoader.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Google Inc. All rights reserved. 2 * Copyright (C) 2011 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 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. 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 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 // File system 72 // File system
73 { "NotReadableError", "The requested file could not be read, typically due t o permission problems that have occurred after a reference to a file was acquire d.", 0 }, 73 { "NotReadableError", "The requested file could not be read, typically due t o permission problems that have occurred after a reference to a file was acquire d.", 0 },
74 { "EncodingError", "A URI supplied to the API was malformed, or the resultin g Data URL has exceeded the URL length limitations for Data URLs.", 0 }, 74 { "EncodingError", "A URI supplied to the API was malformed, or the resultin g Data URL has exceeded the URL length limitations for Data URLs.", 0 },
75 { "PathExistsError", "An attempt was made to create a file or directory wher e an element already exists.", 0 }, 75 { "PathExistsError", "An attempt was made to create a file or directory wher e an element already exists.", 0 },
76 76
77 // SQL 77 // SQL
78 { "DatabaseError", "The operation failed for some reason related to the data base.", 0 }, 78 { "DatabaseError", "The operation failed for some reason related to the data base.", 0 },
79 79
80 // Web Crypto 80 // Web Crypto
81 { "OperationError", "The operation failed for an operation-specific reason", 0 }, 81 { "OperationError", "The operation failed for an operation-specific reason", 0 },
82
83 // Type
84 // FIXMEDART: remove TypeError from this list and dispatch type errors as
85 // native Dart TypeError exceptions instead.
86 { "TypeError", "The operation failed for some reason related to types", 0 }
82 }; 87 };
83 88
84 static const CoreException* getErrorEntry(ExceptionCode ec) 89 static const CoreException* getErrorEntry(ExceptionCode ec)
85 { 90 {
86 size_t tableSize = WTF_ARRAY_LENGTH(coreExceptions); 91 size_t tableSize = WTF_ARRAY_LENGTH(coreExceptions);
87 size_t tableIndex = ec - IndexSizeError; 92 size_t tableIndex = ec - IndexSizeError;
88 93
89 return tableIndex < tableSize ? &coreExceptions[tableIndex] : 0; 94 return tableIndex < tableSize ? &coreExceptions[tableIndex] : 0;
90 } 95 }
91 96
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
132 { 137 {
133 const CoreException* entry = getErrorEntry(ec); 138 const CoreException* entry = getErrorEntry(ec);
134 ASSERT(entry); 139 ASSERT(entry);
135 if (!entry) 140 if (!entry)
136 return "Unknown error."; 141 return "Unknown error.";
137 142
138 return entry->message; 143 return entry->message;
139 } 144 }
140 145
141 } // namespace blink 146 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/core.gypi ('k') | Source/core/dom/ScriptLoader.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698