Index: chromeos/display/real_output_configurator_delegate.h |
diff --git a/chromeos/display/real_output_configurator_delegate.h b/chromeos/display/real_output_configurator_delegate.h |
index 2753ae55ffb19c778613eab77193abb8467c1699..95bedd273ccf6bb57ea97e3c951289b778f8b07e 100644 |
--- a/chromeos/display/real_output_configurator_delegate.h |
+++ b/chromeos/display/real_output_configurator_delegate.h |
@@ -5,11 +5,13 @@ |
#ifndef CHROMEOS_DISPLAY_REAL_OUTPUT_CONFIGURATOR_DELEGATE_H_ |
#define CHROMEOS_DISPLAY_REAL_OUTPUT_CONFIGURATOR_DELEGATE_H_ |
+#include <map> |
#include <vector> |
#include "base/basictypes.h" |
#include "base/compiler_specific.h" |
#include "chromeos/display/output_configurator.h" |
+#include "ppapi/c/private/ppb_output_protection_private.h" |
kcwu
2013/09/06 15:12:16
I included this for enums.
But presubmit error on
|
typedef XID Window; |
@@ -20,6 +22,10 @@ typedef _XRROutputInfo XRROutputInfo; |
struct _XRRScreenResources; |
typedef _XRRScreenResources XRRScreenResources; |
+namespace chrome { |
+class PepperOutputProtectionHost; |
+} // namespace chrome |
+ |
namespace chromeos { |
class RealOutputConfiguratorDelegate : public OutputConfigurator::Delegate { |
@@ -53,8 +59,24 @@ class RealOutputConfiguratorDelegate : public OutputConfigurator::Delegate { |
int touch_device_id, |
const OutputConfigurator::CoordinateTransformation& ctm) OVERRIDE; |
virtual void SendProjectingStateToPowerManager(bool projecting) OVERRIDE; |
+ virtual bool QueryOutputProtectionStatus( |
+ chrome::PepperOutputProtectionHost* client, |
+ uint32_t* link_mask, |
+ uint32_t* protection_mask) OVERRIDE; |
+ virtual bool EnableOutputProtection( |
+ chrome::PepperOutputProtectionHost* client, |
+ uint32_t desired_method_mask) OVERRIDE; |
private: |
+ typedef std::map<chrome::PepperOutputProtectionHost*, uint32_t> |
+ ProtectionRequests; |
+ |
+ enum HDCPState { |
+ HDCP_State_Undesired, |
+ HDCP_State_Desired, |
+ HDCP_State_Enabled |
+ }; |
+ |
// Gets details corresponding to |mode|. Parameters may be NULL. Returns |
// true on success. |
bool GetModeDetails(RRMode mode, int* width, int* height, bool* interlaced); |
@@ -105,6 +127,20 @@ class RealOutputConfiguratorDelegate : public OutputConfigurator::Delegate { |
void GetTouchscreens( |
std::vector<OutputConfigurator::OutputSnapshot>* outputs); |
+ // Get HDCP state of output. |
+ bool GetHDCPState(RROutput id, HDCPState* state); |
+ // Set HDCP state of output. |
+ bool SetHDCPState(RROutput id, HDCPState state); |
+ // Get types of connected output links. |
+ bool GetOutputLinkType( |
+ std::vector<PP_OutputProtectionLinkType_Private>& link_type); |
+ // Get the bit-mask of connected output links. |
+ bool GetOutputLinkMask(uint32_t* link_mask); |
+ // Get the bit-mask of enabled protection methods. |
+ bool GetProtectionMethods(uint32_t* protection_mask); |
+ // Get the bit-mask of all requested protection methods. |
+ uint32_t GetCombinedProtectionRequest(); |
+ |
Display* display_; |
Window window_; |
@@ -114,6 +150,9 @@ class RealOutputConfiguratorDelegate : public OutputConfigurator::Delegate { |
// Used to enable modes which rely on panel fitting. |
bool is_panel_fitting_enabled_; |
+ // Output protection requests of each client. |
+ ProtectionRequests client_protection_request_; |
+ |
DISALLOW_COPY_AND_ASSIGN(RealOutputConfiguratorDelegate); |
}; |