| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (c) 2013, Google Inc. All rights reserved. | 2 * Copyright (c) 2013, 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 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 98 if (value.isHTMLCanvasElement()) | 98 if (value.isHTMLCanvasElement()) |
| 99 return value.getAsHTMLCanvasElement(); | 99 return value.getAsHTMLCanvasElement(); |
| 100 if (value.isBlob()) | 100 if (value.isBlob()) |
| 101 return value.getAsBlob(); | 101 return value.getAsBlob(); |
| 102 if (value.isImageData()) | 102 if (value.isImageData()) |
| 103 return value.getAsImageData(); | 103 return value.getAsImageData(); |
| 104 if (value.isImageBitmap()) | 104 if (value.isImageBitmap()) |
| 105 return value.getAsImageBitmap(); | 105 return value.getAsImageBitmap(); |
| 106 if (value.isOffscreenCanvas()) | 106 if (value.isOffscreenCanvas()) |
| 107 return value.getAsOffscreenCanvas(); | 107 return value.getAsOffscreenCanvas(); |
| 108 ASSERT_NOT_REACHED(); | 108 NOTREACHED(); |
| 109 return nullptr; | 109 return nullptr; |
| 110 } | 110 } |
| 111 | 111 |
| 112 ScriptPromise ImageBitmapFactories::CreateImageBitmapFromBlob( | 112 ScriptPromise ImageBitmapFactories::CreateImageBitmapFromBlob( |
| 113 ScriptState* script_state, | 113 ScriptState* script_state, |
| 114 EventTarget& event_target, | 114 EventTarget& event_target, |
| 115 ImageBitmapSource* bitmap_source, | 115 ImageBitmapSource* bitmap_source, |
| 116 Optional<IntRect> crop_rect, | 116 Optional<IntRect> crop_rect, |
| 117 const ImageBitmapOptions& options, | 117 const ImageBitmapOptions& options, |
| 118 ExceptionState& exception_state) { | 118 ExceptionState& exception_state) { |
| (...skipping 202 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 321 } | 321 } |
| 322 factory_->DidFinishLoading(this); | 322 factory_->DidFinishLoading(this); |
| 323 } | 323 } |
| 324 | 324 |
| 325 DEFINE_TRACE(ImageBitmapFactories::ImageBitmapLoader) { | 325 DEFINE_TRACE(ImageBitmapFactories::ImageBitmapLoader) { |
| 326 visitor->Trace(factory_); | 326 visitor->Trace(factory_); |
| 327 visitor->Trace(resolver_); | 327 visitor->Trace(resolver_); |
| 328 } | 328 } |
| 329 | 329 |
| 330 } // namespace blink | 330 } // namespace blink |
| OLD | NEW |