| 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 #ifndef CONTENT_PUBLIC_BROWSER_PRESENTATION_SESSION_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_PRESENTATION_SESSION_H_ |
| 6 #define CONTENT_PUBLIC_BROWSER_PRESENTATION_SESSION_H_ | 6 #define CONTENT_PUBLIC_BROWSER_PRESENTATION_SESSION_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "content/common/content_export.h" | 10 #include "content/common/content_export.h" |
| (...skipping 16 matching lines...) Expand all Loading... |
| 27 }; | 27 }; |
| 28 | 28 |
| 29 // TODO(imcheng): Rename to PresentationConnectionInfo. | 29 // TODO(imcheng): Rename to PresentationConnectionInfo. |
| 30 // Represents a presentation session that has been established via either | 30 // Represents a presentation session that has been established via either |
| 31 // browser actions or Presentation API. | 31 // browser actions or Presentation API. |
| 32 struct CONTENT_EXPORT PresentationSessionInfo { | 32 struct CONTENT_EXPORT PresentationSessionInfo { |
| 33 PresentationSessionInfo(const std::string& presentation_url, | 33 PresentationSessionInfo(const std::string& presentation_url, |
| 34 const std::string& presentation_id); | 34 const std::string& presentation_id); |
| 35 ~PresentationSessionInfo(); | 35 ~PresentationSessionInfo(); |
| 36 | 36 |
| 37 const std::string presentation_url; | 37 std::string presentation_url; |
| 38 const std::string presentation_id; | 38 std::string presentation_id; |
| 39 }; | 39 }; |
| 40 | 40 |
| 41 // Possible reasons why an attempt to create a presentation session failed. | 41 // Possible reasons why an attempt to create a presentation session failed. |
| 42 enum PresentationErrorType { | 42 enum PresentationErrorType { |
| 43 PRESENTATION_ERROR_NO_AVAILABLE_SCREENS, | 43 PRESENTATION_ERROR_NO_AVAILABLE_SCREENS, |
| 44 PRESENTATION_ERROR_SESSION_REQUEST_CANCELLED, | 44 PRESENTATION_ERROR_SESSION_REQUEST_CANCELLED, |
| 45 PRESENTATION_ERROR_NO_PRESENTATION_FOUND, | 45 PRESENTATION_ERROR_NO_PRESENTATION_FOUND, |
| 46 PRESENTATION_ERROR_UNKNOWN, | 46 PRESENTATION_ERROR_UNKNOWN, |
| 47 }; | 47 }; |
| 48 | 48 |
| 49 // Struct returned when an attempt to create a presentation session failed. | 49 // Struct returned when an attempt to create a presentation session failed. |
| 50 struct CONTENT_EXPORT PresentationError { | 50 struct CONTENT_EXPORT PresentationError { |
| 51 PresentationError(PresentationErrorType error_type, | 51 PresentationError(PresentationErrorType error_type, |
| 52 const std::string& message); | 52 const std::string& message); |
| 53 ~PresentationError(); | 53 ~PresentationError(); |
| 54 | 54 |
| 55 const PresentationErrorType error_type; | 55 const PresentationErrorType error_type; |
| 56 const std::string message; | 56 const std::string message; |
| 57 }; | 57 }; |
| 58 | 58 |
| 59 } // namespace content | 59 } // namespace content |
| 60 | 60 |
| 61 #endif // CONTENT_PUBLIC_BROWSER_PRESENTATION_SESSION_H_ | 61 #endif // CONTENT_PUBLIC_BROWSER_PRESENTATION_SESSION_H_ |
| OLD | NEW |