blob: 379ed0d193f7601f3d30ad01d0064427b9efce52 [file] [log] [blame]
// Copyright 2014 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef UI_OZONE_PLATFORM_DRI_CHROMEOS_DISPLAY_SNAPSHOT_DRI_H_
#define UI_OZONE_PLATFORM_DRI_CHROMEOS_DISPLAY_SNAPSHOT_DRI_H_
#include "ui/display/types/display_snapshot.h"
#include "ui/ozone/platform/dri/scoped_drm_types.h"
namespace ui {
class DriWrapper;
class DisplaySnapshotDri : public DisplaySnapshot {
public:
DisplaySnapshotDri(DriWrapper* drm,
drmModeConnector* connector,
drmModeCrtc* crtc,
uint32_t index);
virtual ~DisplaySnapshotDri();
// Native properties of a display used by the DRI implementation in
// configuring this display.
uint32_t connector() const { return connector_; }
uint32_t crtc() const { return crtc_; }
drmModePropertyRes* dpms_property() const { return dpms_property_.get(); }
// DisplaySnapshot overrides:
virtual std::string ToString() const OVERRIDE;
private:
uint32_t connector_;
uint32_t crtc_;
ScopedDrmPropertyPtr dpms_property_;
std::string name_;
bool overscan_flag_;
DISALLOW_COPY_AND_ASSIGN(DisplaySnapshotDri);
};
} // namespace ui
#endif // UI_OZONE_PLATFORM_DRI_CHROMEOS_DISPLAY_SNAPSHOT_DRI_H_