| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 // Base class for MediaPermission implementations in content. This class allows | 5 // Base class for MediaPermission implementations in content. This class allows |
| 6 // multiple pending PermissionService calls by managing callbacks for its | 6 // multiple pending PermissionService calls by managing callbacks for its |
| 7 // subclasses. This class is not thread safe and should only be used on one | 7 // subclasses. This class is not thread safe and should only be used on one |
| 8 // thread. | 8 // thread. |
| 9 | 9 |
| 10 #ifndef CONTENT_RENDERER_MEDIA_MEDIA_PERMISSION_DISPATCHER_H_ | 10 #ifndef CONTENT_RENDERER_MEDIA_MEDIA_PERMISSION_DISPATCHER_H_ |
| 11 #define CONTENT_RENDERER_MEDIA_MEDIA_PERMISSION_DISPATCHER_H_ | 11 #define CONTENT_RENDERER_MEDIA_MEDIA_PERMISSION_DISPATCHER_H_ |
| 12 | 12 |
| 13 #include <stdint.h> |
| 14 |
| 13 #include <map> | 15 #include <map> |
| 14 | 16 |
| 17 #include "base/macros.h" |
| 15 #include "base/memory/weak_ptr.h" | 18 #include "base/memory/weak_ptr.h" |
| 16 #include "base/threading/thread_checker.h" | 19 #include "base/threading/thread_checker.h" |
| 17 #include "content/common/content_export.h" | 20 #include "content/common/content_export.h" |
| 18 #include "media/base/media_permission.h" | 21 #include "media/base/media_permission.h" |
| 19 | 22 |
| 20 namespace content { | 23 namespace content { |
| 21 | 24 |
| 22 class CONTENT_EXPORT MediaPermissionDispatcher : public media::MediaPermission { | 25 class CONTENT_EXPORT MediaPermissionDispatcher : public media::MediaPermission { |
| 23 public: | 26 public: |
| 24 MediaPermissionDispatcher(); | 27 MediaPermissionDispatcher(); |
| (...skipping 17 matching lines...) Expand all Loading... |
| 42 | 45 |
| 43 uint32_t next_request_id_; | 46 uint32_t next_request_id_; |
| 44 RequestMap requests_; | 47 RequestMap requests_; |
| 45 | 48 |
| 46 DISALLOW_COPY_AND_ASSIGN(MediaPermissionDispatcher); | 49 DISALLOW_COPY_AND_ASSIGN(MediaPermissionDispatcher); |
| 47 }; | 50 }; |
| 48 | 51 |
| 49 } // namespace content | 52 } // namespace content |
| 50 | 53 |
| 51 #endif // CONTENT_RENDERER_MEDIA_MEDIA_PERMISSION_DISPATCHER_H_ | 54 #endif // CONTENT_RENDERER_MEDIA_MEDIA_PERMISSION_DISPATCHER_H_ |
| OLD | NEW |