| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2014 Google Inc. All rights reserved. | 2 * Copyright (C) 2014 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 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 15 matching lines...) Expand all Loading... |
| 26 #include "config.h" | 26 #include "config.h" |
| 27 | 27 |
| 28 #include "modules/mediastream/MediaDevicesRequest.h" | 28 #include "modules/mediastream/MediaDevicesRequest.h" |
| 29 | 29 |
| 30 #include "bindings/core/v8/ExceptionState.h" | 30 #include "bindings/core/v8/ExceptionState.h" |
| 31 #include "core/dom/Document.h" | 31 #include "core/dom/Document.h" |
| 32 #include "modules/mediastream/UserMediaController.h" | 32 #include "modules/mediastream/UserMediaController.h" |
| 33 | 33 |
| 34 namespace blink { | 34 namespace blink { |
| 35 | 35 |
| 36 MediaDevicesRequest* MediaDevicesRequest::create(ExecutionContext* context, User
MediaController* controller, PassOwnPtrWillBeRawPtr<MediaDeviceInfoCallback> cal
lback, ExceptionState& exceptionState) | 36 MediaDevicesRequest* MediaDevicesRequest::create(ExecutionContext* context, User
MediaController* controller, MediaDeviceInfoCallback* callback, ExceptionState&
exceptionState) |
| 37 { | 37 { |
| 38 MediaDevicesRequest* request = new MediaDevicesRequest(context, controller,
callback); | 38 MediaDevicesRequest* request = new MediaDevicesRequest(context, controller,
callback); |
| 39 request->suspendIfNeeded(); | 39 request->suspendIfNeeded(); |
| 40 return request; | 40 return request; |
| 41 } | 41 } |
| 42 | 42 |
| 43 MediaDevicesRequest::MediaDevicesRequest(ExecutionContext* context, UserMediaCon
troller* controller, PassOwnPtrWillBeRawPtr<MediaDeviceInfoCallback> callback) | 43 MediaDevicesRequest::MediaDevicesRequest(ExecutionContext* context, UserMediaCon
troller* controller, MediaDeviceInfoCallback* callback) |
| 44 : ActiveDOMObject(context) | 44 : ActiveDOMObject(context) |
| 45 , m_controller(controller) | 45 , m_controller(controller) |
| 46 , m_callback(callback) | 46 , m_callback(callback) |
| 47 { | 47 { |
| 48 } | 48 } |
| 49 | 49 |
| 50 MediaDevicesRequest::~MediaDevicesRequest() | 50 MediaDevicesRequest::~MediaDevicesRequest() |
| 51 { | 51 { |
| 52 } | 52 } |
| 53 | 53 |
| (...skipping 25 matching lines...) Expand all Loading... |
| 79 m_callback.clear(); | 79 m_callback.clear(); |
| 80 m_controller = 0; | 80 m_controller = 0; |
| 81 } | 81 } |
| 82 | 82 |
| 83 void MediaDevicesRequest::trace(Visitor* visitor) | 83 void MediaDevicesRequest::trace(Visitor* visitor) |
| 84 { | 84 { |
| 85 visitor->trace(m_callback); | 85 visitor->trace(m_callback); |
| 86 } | 86 } |
| 87 | 87 |
| 88 } // namespace blink | 88 } // namespace blink |
| OLD | NEW |