Flutter Engine
flutter::Display Class Reference

#include <display.h>

Inheritance diagram for flutter::Display:
flutter::AndroidDisplay

Public Member Functions

 Display (DisplayId display_id, double refresh_rate)
 Construct a new Display object in case where the display id of the display is known. In cases where there is more than one display, every display is expected to have a display id. More...
 
 Display (double refresh_rate)
 Construct a new Display object when there is only a single display. When there are multiple displays, every display must have a display id. More...
 
virtual ~Display ()=default
 
virtual double GetRefreshRate () const
 
std::optional< DisplayIdGetDisplayId () const
 Returns the DisplayId of the display. More...
 

Detailed Description

Display refers to a graphics hardware system consisting of a framebuffer, typically a monitor or a screen. This class holds the various display settings.

Definition at line 24 of file display.h.

Constructor & Destructor Documentation

◆ Display() [1/2]

flutter::Display::Display ( DisplayId  display_id,
double  refresh_rate 
)
inline

Construct a new Display object in case where the display id of the display is known. In cases where there is more than one display, every display is expected to have a display id.

Definition at line 31 of file display.h.

32  : display_id_(display_id), refresh_rate_(refresh_rate) {}

◆ Display() [2/2]

flutter::Display::Display ( double  refresh_rate)
inlineexplicit

Construct a new Display object when there is only a single display. When there are multiple displays, every display must have a display id.

Definition at line 38 of file display.h.

References GetRefreshRate(), and ~Display().

39  : display_id_({}), refresh_rate_(refresh_rate) {}

◆ ~Display()

virtual flutter::Display::~Display ( )
virtualdefault

Referenced by Display().

Member Function Documentation

◆ GetDisplayId()

std::optional<DisplayId> flutter::Display::GetDisplayId ( ) const
inline

Returns the DisplayId of the display.

Definition at line 48 of file display.h.

48 { return display_id_; }

◆ GetRefreshRate()

double flutter::Display::GetRefreshRate ( ) const
virtual

Reimplemented in flutter::AndroidDisplay.

Definition at line 8 of file display.cc.

Referenced by Display().

8  {
9  return refresh_rate_;
10 }

The documentation for this class was generated from the following files: