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

Side by Side Diff: Source/WebCore/html/canvas/DataView.h

Issue 6469012: Merge 77433 (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/648/
Patch Set: Created 9 years, 10 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
« no previous file with comments | « LayoutTests/fast/canvas/webgl/data-view-test-expected.txt ('k') | no next file » | 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) 2010 Google Inc. All rights reserved. 2 * Copyright (C) 2010 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 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 void setUint32(unsigned byteOffset, uint32_t value, bool littleEndian, Excep tionCode&); 68 void setUint32(unsigned byteOffset, uint32_t value, bool littleEndian, Excep tionCode&);
69 void setFloat32(unsigned byteOffset, float value, ExceptionCode& ec) { setFl oat32(byteOffset, value, false, ec); } 69 void setFloat32(unsigned byteOffset, float value, ExceptionCode& ec) { setFl oat32(byteOffset, value, false, ec); }
70 void setFloat32(unsigned byteOffset, float value, bool littleEndian, Excepti onCode&); 70 void setFloat32(unsigned byteOffset, float value, bool littleEndian, Excepti onCode&);
71 void setFloat64(unsigned byteOffset, double value, ExceptionCode& ec) { setF loat64(byteOffset, value, false, ec); } 71 void setFloat64(unsigned byteOffset, double value, ExceptionCode& ec) { setF loat64(byteOffset, value, false, ec); }
72 void setFloat64(unsigned byteOffset, double value, bool littleEndian, Except ionCode&); 72 void setFloat64(unsigned byteOffset, double value, bool littleEndian, Except ionCode&);
73 73
74 private: 74 private:
75 DataView(PassRefPtr<ArrayBuffer>, unsigned byteOffset, unsigned byteLength); 75 DataView(PassRefPtr<ArrayBuffer>, unsigned byteOffset, unsigned byteLength);
76 76
77 template<typename T> 77 template<typename T>
78 inline bool beyondRange(unsigned byteOffset) const { return byteOffset + siz eof(T) > m_byteLength; } 78 inline bool beyondRange(unsigned byteOffset) const { return byteOffset >= m_ byteLength || byteOffset + sizeof(T) > m_byteLength; }
79 79
80 template<typename T> 80 template<typename T>
81 T getData(unsigned byteOffset, bool littleEndian, ExceptionCode&) const; 81 T getData(unsigned byteOffset, bool littleEndian, ExceptionCode&) const;
82 82
83 template<typename T> 83 template<typename T>
84 void setData(unsigned byteOffset, T value, bool littleEndian, ExceptionCode& ); 84 void setData(unsigned byteOffset, T value, bool littleEndian, ExceptionCode& );
85 85
86 unsigned m_byteLength; 86 unsigned m_byteLength;
87 }; 87 };
88 88
89 89
90 } // namespace WebCore 90 } // namespace WebCore
91 91
92 #endif // DataView_h 92 #endif // DataView_h
OLDNEW
« no previous file with comments | « LayoutTests/fast/canvas/webgl/data-view-test-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698