diff options
Diffstat (limited to 'nexgb/randr/randr.go')
-rw-r--r-- | nexgb/randr/randr.go | 182 |
1 files changed, 181 insertions, 1 deletions
diff --git a/nexgb/randr/randr.go b/nexgb/randr/randr.go index 83e7035..9a6e89f 100644 --- a/nexgb/randr/randr.go +++ b/nexgb/randr/randr.go @@ -2,7 +2,7 @@ package randr /* - This file was generated by randr.xml on May 11 2012 1:58:36am EDT. + This file was generated by randr.xml on May 11 2012 11:57:19pm EDT. This file is automatically generated. Edit at your peril! */ @@ -1221,6 +1221,9 @@ type QueryVersionCookie struct { // QueryVersion sends a checked request. // If an error occurs, it will be returned with the reply by calling QueryVersionCookie.Reply() func QueryVersion(c *xgb.Conn, MajorVersion uint32, MinorVersion uint32) QueryVersionCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'QueryVersion' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, true) c.NewRequest(queryVersionRequest(c, MajorVersion, MinorVersion), cookie) return QueryVersionCookie{cookie} @@ -1229,6 +1232,9 @@ func QueryVersion(c *xgb.Conn, MajorVersion uint32, MinorVersion uint32) QueryVe // QueryVersionUnchecked sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func QueryVersionUnchecked(c *xgb.Conn, MajorVersion uint32, MinorVersion uint32) QueryVersionCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'QueryVersion' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, true) c.NewRequest(queryVersionRequest(c, MajorVersion, MinorVersion), cookie) return QueryVersionCookie{cookie} @@ -1313,6 +1319,9 @@ type SetScreenConfigCookie struct { // SetScreenConfig sends a checked request. // If an error occurs, it will be returned with the reply by calling SetScreenConfigCookie.Reply() func SetScreenConfig(c *xgb.Conn, Window xproto.Window, Timestamp xproto.Timestamp, ConfigTimestamp xproto.Timestamp, SizeID uint16, Rotation uint16, Rate uint16) SetScreenConfigCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'SetScreenConfig' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, true) c.NewRequest(setScreenConfigRequest(c, Window, Timestamp, ConfigTimestamp, SizeID, Rotation, Rate), cookie) return SetScreenConfigCookie{cookie} @@ -1321,6 +1330,9 @@ func SetScreenConfig(c *xgb.Conn, Window xproto.Window, Timestamp xproto.Timesta // SetScreenConfigUnchecked sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func SetScreenConfigUnchecked(c *xgb.Conn, Window xproto.Window, Timestamp xproto.Timestamp, ConfigTimestamp xproto.Timestamp, SizeID uint16, Rotation uint16, Rate uint16) SetScreenConfigCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'SetScreenConfig' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, true) c.NewRequest(setScreenConfigRequest(c, Window, Timestamp, ConfigTimestamp, SizeID, Rotation, Rate), cookie) return SetScreenConfigCookie{cookie} @@ -1428,6 +1440,9 @@ type SelectInputCookie struct { // SelectInput sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func SelectInput(c *xgb.Conn, Window xproto.Window, Enable uint16) SelectInputCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'SelectInput' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, false) c.NewRequest(selectInputRequest(c, Window, Enable), cookie) return SelectInputCookie{cookie} @@ -1436,6 +1451,9 @@ func SelectInput(c *xgb.Conn, Window xproto.Window, Enable uint16) SelectInputCo // SelectInputChecked sends a checked request. // If an error occurs, it can be retrieved using SelectInputCookie.Check() func SelectInputChecked(c *xgb.Conn, Window xproto.Window, Enable uint16) SelectInputCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'SelectInput' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, false) c.NewRequest(selectInputRequest(c, Window, Enable), cookie) return SelectInputCookie{cookie} @@ -1482,6 +1500,9 @@ type GetScreenInfoCookie struct { // GetScreenInfo sends a checked request. // If an error occurs, it will be returned with the reply by calling GetScreenInfoCookie.Reply() func GetScreenInfo(c *xgb.Conn, Window xproto.Window) GetScreenInfoCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetScreenInfo' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, true) c.NewRequest(getScreenInfoRequest(c, Window), cookie) return GetScreenInfoCookie{cookie} @@ -1490,6 +1511,9 @@ func GetScreenInfo(c *xgb.Conn, Window xproto.Window) GetScreenInfoCookie { // GetScreenInfoUnchecked sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func GetScreenInfoUnchecked(c *xgb.Conn, Window xproto.Window) GetScreenInfoCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetScreenInfo' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, true) c.NewRequest(getScreenInfoRequest(c, Window), cookie) return GetScreenInfoCookie{cookie} @@ -1604,6 +1628,9 @@ type GetScreenSizeRangeCookie struct { // GetScreenSizeRange sends a checked request. // If an error occurs, it will be returned with the reply by calling GetScreenSizeRangeCookie.Reply() func GetScreenSizeRange(c *xgb.Conn, Window xproto.Window) GetScreenSizeRangeCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetScreenSizeRange' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, true) c.NewRequest(getScreenSizeRangeRequest(c, Window), cookie) return GetScreenSizeRangeCookie{cookie} @@ -1612,6 +1639,9 @@ func GetScreenSizeRange(c *xgb.Conn, Window xproto.Window) GetScreenSizeRangeCoo // GetScreenSizeRangeUnchecked sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func GetScreenSizeRangeUnchecked(c *xgb.Conn, Window xproto.Window) GetScreenSizeRangeCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetScreenSizeRange' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, true) c.NewRequest(getScreenSizeRangeRequest(c, Window), cookie) return GetScreenSizeRangeCookie{cookie} @@ -1701,6 +1731,9 @@ type SetScreenSizeCookie struct { // SetScreenSize sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func SetScreenSize(c *xgb.Conn, Window xproto.Window, Width uint16, Height uint16, MmWidth uint32, MmHeight uint32) SetScreenSizeCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'SetScreenSize' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, false) c.NewRequest(setScreenSizeRequest(c, Window, Width, Height, MmWidth, MmHeight), cookie) return SetScreenSizeCookie{cookie} @@ -1709,6 +1742,9 @@ func SetScreenSize(c *xgb.Conn, Window xproto.Window, Width uint16, Height uint1 // SetScreenSizeChecked sends a checked request. // If an error occurs, it can be retrieved using SetScreenSizeCookie.Check() func SetScreenSizeChecked(c *xgb.Conn, Window xproto.Window, Width uint16, Height uint16, MmWidth uint32, MmHeight uint32) SetScreenSizeCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'SetScreenSize' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, false) c.NewRequest(setScreenSizeRequest(c, Window, Width, Height, MmWidth, MmHeight), cookie) return SetScreenSizeCookie{cookie} @@ -1762,6 +1798,9 @@ type GetScreenResourcesCookie struct { // GetScreenResources sends a checked request. // If an error occurs, it will be returned with the reply by calling GetScreenResourcesCookie.Reply() func GetScreenResources(c *xgb.Conn, Window xproto.Window) GetScreenResourcesCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetScreenResources' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, true) c.NewRequest(getScreenResourcesRequest(c, Window), cookie) return GetScreenResourcesCookie{cookie} @@ -1770,6 +1809,9 @@ func GetScreenResources(c *xgb.Conn, Window xproto.Window) GetScreenResourcesCoo // GetScreenResourcesUnchecked sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func GetScreenResourcesUnchecked(c *xgb.Conn, Window xproto.Window) GetScreenResourcesCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetScreenResources' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, true) c.NewRequest(getScreenResourcesRequest(c, Window), cookie) return GetScreenResourcesCookie{cookie} @@ -1892,6 +1934,9 @@ type GetOutputInfoCookie struct { // GetOutputInfo sends a checked request. // If an error occurs, it will be returned with the reply by calling GetOutputInfoCookie.Reply() func GetOutputInfo(c *xgb.Conn, Output Output, ConfigTimestamp xproto.Timestamp) GetOutputInfoCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetOutputInfo' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, true) c.NewRequest(getOutputInfoRequest(c, Output, ConfigTimestamp), cookie) return GetOutputInfoCookie{cookie} @@ -1900,6 +1945,9 @@ func GetOutputInfo(c *xgb.Conn, Output Output, ConfigTimestamp xproto.Timestamp) // GetOutputInfoUnchecked sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func GetOutputInfoUnchecked(c *xgb.Conn, Output Output, ConfigTimestamp xproto.Timestamp) GetOutputInfoCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetOutputInfo' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, true) c.NewRequest(getOutputInfoRequest(c, Output, ConfigTimestamp), cookie) return GetOutputInfoCookie{cookie} @@ -2047,6 +2095,9 @@ type ListOutputPropertiesCookie struct { // ListOutputProperties sends a checked request. // If an error occurs, it will be returned with the reply by calling ListOutputPropertiesCookie.Reply() func ListOutputProperties(c *xgb.Conn, Output Output) ListOutputPropertiesCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'ListOutputProperties' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, true) c.NewRequest(listOutputPropertiesRequest(c, Output), cookie) return ListOutputPropertiesCookie{cookie} @@ -2055,6 +2106,9 @@ func ListOutputProperties(c *xgb.Conn, Output Output) ListOutputPropertiesCookie // ListOutputPropertiesUnchecked sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func ListOutputPropertiesUnchecked(c *xgb.Conn, Output Output) ListOutputPropertiesCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'ListOutputProperties' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, true) c.NewRequest(listOutputPropertiesRequest(c, Output), cookie) return ListOutputPropertiesCookie{cookie} @@ -2140,6 +2194,9 @@ type QueryOutputPropertyCookie struct { // QueryOutputProperty sends a checked request. // If an error occurs, it will be returned with the reply by calling QueryOutputPropertyCookie.Reply() func QueryOutputProperty(c *xgb.Conn, Output Output, Property xproto.Atom) QueryOutputPropertyCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'QueryOutputProperty' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, true) c.NewRequest(queryOutputPropertyRequest(c, Output, Property), cookie) return QueryOutputPropertyCookie{cookie} @@ -2148,6 +2205,9 @@ func QueryOutputProperty(c *xgb.Conn, Output Output, Property xproto.Atom) Query // QueryOutputPropertyUnchecked sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func QueryOutputPropertyUnchecked(c *xgb.Conn, Output Output, Property xproto.Atom) QueryOutputPropertyCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'QueryOutputProperty' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, true) c.NewRequest(queryOutputPropertyRequest(c, Output, Property), cookie) return QueryOutputPropertyCookie{cookie} @@ -2256,6 +2316,9 @@ type ConfigureOutputPropertyCookie struct { // ConfigureOutputProperty sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func ConfigureOutputProperty(c *xgb.Conn, Output Output, Property xproto.Atom, Pending bool, Range bool, Values []int32) ConfigureOutputPropertyCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'ConfigureOutputProperty' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, false) c.NewRequest(configureOutputPropertyRequest(c, Output, Property, Pending, Range, Values), cookie) return ConfigureOutputPropertyCookie{cookie} @@ -2264,6 +2327,9 @@ func ConfigureOutputProperty(c *xgb.Conn, Output Output, Property xproto.Atom, P // ConfigureOutputPropertyChecked sends a checked request. // If an error occurs, it can be retrieved using ConfigureOutputPropertyCookie.Check() func ConfigureOutputPropertyChecked(c *xgb.Conn, Output Output, Property xproto.Atom, Pending bool, Range bool, Values []int32) ConfigureOutputPropertyCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'ConfigureOutputProperty' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, false) c.NewRequest(configureOutputPropertyRequest(c, Output, Property, Pending, Range, Values), cookie) return ConfigureOutputPropertyCookie{cookie} @@ -2330,6 +2396,9 @@ type ChangeOutputPropertyCookie struct { // ChangeOutputProperty sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func ChangeOutputProperty(c *xgb.Conn, Output Output, Property xproto.Atom, Type xproto.Atom, Format byte, Mode byte, NumUnits uint32, Data []byte) ChangeOutputPropertyCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'ChangeOutputProperty' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, false) c.NewRequest(changeOutputPropertyRequest(c, Output, Property, Type, Format, Mode, NumUnits, Data), cookie) return ChangeOutputPropertyCookie{cookie} @@ -2338,6 +2407,9 @@ func ChangeOutputProperty(c *xgb.Conn, Output Output, Property xproto.Atom, Type // ChangeOutputPropertyChecked sends a checked request. // If an error occurs, it can be retrieved using ChangeOutputPropertyCookie.Check() func ChangeOutputPropertyChecked(c *xgb.Conn, Output Output, Property xproto.Atom, Type xproto.Atom, Format byte, Mode byte, NumUnits uint32, Data []byte) ChangeOutputPropertyCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'ChangeOutputProperty' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, false) c.NewRequest(changeOutputPropertyRequest(c, Output, Property, Type, Format, Mode, NumUnits, Data), cookie) return ChangeOutputPropertyCookie{cookie} @@ -2399,6 +2471,9 @@ type DeleteOutputPropertyCookie struct { // DeleteOutputProperty sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func DeleteOutputProperty(c *xgb.Conn, Output Output, Property xproto.Atom) DeleteOutputPropertyCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'DeleteOutputProperty' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, false) c.NewRequest(deleteOutputPropertyRequest(c, Output, Property), cookie) return DeleteOutputPropertyCookie{cookie} @@ -2407,6 +2482,9 @@ func DeleteOutputProperty(c *xgb.Conn, Output Output, Property xproto.Atom) Dele // DeleteOutputPropertyChecked sends a checked request. // If an error occurs, it can be retrieved using DeleteOutputPropertyCookie.Check() func DeleteOutputPropertyChecked(c *xgb.Conn, Output Output, Property xproto.Atom) DeleteOutputPropertyCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'DeleteOutputProperty' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, false) c.NewRequest(deleteOutputPropertyRequest(c, Output, Property), cookie) return DeleteOutputPropertyCookie{cookie} @@ -2451,6 +2529,9 @@ type GetOutputPropertyCookie struct { // GetOutputProperty sends a checked request. // If an error occurs, it will be returned with the reply by calling GetOutputPropertyCookie.Reply() func GetOutputProperty(c *xgb.Conn, Output Output, Property xproto.Atom, Type xproto.Atom, LongOffset uint32, LongLength uint32, Delete bool, Pending bool) GetOutputPropertyCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetOutputProperty' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, true) c.NewRequest(getOutputPropertyRequest(c, Output, Property, Type, LongOffset, LongLength, Delete, Pending), cookie) return GetOutputPropertyCookie{cookie} @@ -2459,6 +2540,9 @@ func GetOutputProperty(c *xgb.Conn, Output Output, Property xproto.Atom, Type xp // GetOutputPropertyUnchecked sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func GetOutputPropertyUnchecked(c *xgb.Conn, Output Output, Property xproto.Atom, Type xproto.Atom, LongOffset uint32, LongLength uint32, Delete bool, Pending bool) GetOutputPropertyCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetOutputProperty' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, true) c.NewRequest(getOutputPropertyRequest(c, Output, Property, Type, LongOffset, LongLength, Delete, Pending), cookie) return GetOutputPropertyCookie{cookie} @@ -2578,6 +2662,9 @@ type CreateModeCookie struct { // CreateMode sends a checked request. // If an error occurs, it will be returned with the reply by calling CreateModeCookie.Reply() func CreateMode(c *xgb.Conn, Window xproto.Window, ModeInfo ModeInfo, Name string) CreateModeCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'CreateMode' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, true) c.NewRequest(createModeRequest(c, Window, ModeInfo, Name), cookie) return CreateModeCookie{cookie} @@ -2586,6 +2673,9 @@ func CreateMode(c *xgb.Conn, Window xproto.Window, ModeInfo ModeInfo, Name strin // CreateModeUnchecked sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func CreateModeUnchecked(c *xgb.Conn, Window xproto.Window, ModeInfo ModeInfo, Name string) CreateModeCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'CreateMode' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, true) c.NewRequest(createModeRequest(c, Window, ModeInfo, Name), cookie) return CreateModeCookie{cookie} @@ -2672,6 +2762,9 @@ type DestroyModeCookie struct { // DestroyMode sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func DestroyMode(c *xgb.Conn, Mode Mode) DestroyModeCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'DestroyMode' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, false) c.NewRequest(destroyModeRequest(c, Mode), cookie) return DestroyModeCookie{cookie} @@ -2680,6 +2773,9 @@ func DestroyMode(c *xgb.Conn, Mode Mode) DestroyModeCookie { // DestroyModeChecked sends a checked request. // If an error occurs, it can be retrieved using DestroyModeCookie.Check() func DestroyModeChecked(c *xgb.Conn, Mode Mode) DestroyModeCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'DestroyMode' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, false) c.NewRequest(destroyModeRequest(c, Mode), cookie) return DestroyModeCookie{cookie} @@ -2721,6 +2817,9 @@ type AddOutputModeCookie struct { // AddOutputMode sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func AddOutputMode(c *xgb.Conn, Output Output, Mode Mode) AddOutputModeCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'AddOutputMode' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, false) c.NewRequest(addOutputModeRequest(c, Output, Mode), cookie) return AddOutputModeCookie{cookie} @@ -2729,6 +2828,9 @@ func AddOutputMode(c *xgb.Conn, Output Output, Mode Mode) AddOutputModeCookie { // AddOutputModeChecked sends a checked request. // If an error occurs, it can be retrieved using AddOutputModeCookie.Check() func AddOutputModeChecked(c *xgb.Conn, Output Output, Mode Mode) AddOutputModeCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'AddOutputMode' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, false) c.NewRequest(addOutputModeRequest(c, Output, Mode), cookie) return AddOutputModeCookie{cookie} @@ -2773,6 +2875,9 @@ type DeleteOutputModeCookie struct { // DeleteOutputMode sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func DeleteOutputMode(c *xgb.Conn, Output Output, Mode Mode) DeleteOutputModeCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'DeleteOutputMode' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, false) c.NewRequest(deleteOutputModeRequest(c, Output, Mode), cookie) return DeleteOutputModeCookie{cookie} @@ -2781,6 +2886,9 @@ func DeleteOutputMode(c *xgb.Conn, Output Output, Mode Mode) DeleteOutputModeCoo // DeleteOutputModeChecked sends a checked request. // If an error occurs, it can be retrieved using DeleteOutputModeCookie.Check() func DeleteOutputModeChecked(c *xgb.Conn, Output Output, Mode Mode) DeleteOutputModeCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'DeleteOutputMode' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, false) c.NewRequest(deleteOutputModeRequest(c, Output, Mode), cookie) return DeleteOutputModeCookie{cookie} @@ -2825,6 +2933,9 @@ type GetCrtcInfoCookie struct { // GetCrtcInfo sends a checked request. // If an error occurs, it will be returned with the reply by calling GetCrtcInfoCookie.Reply() func GetCrtcInfo(c *xgb.Conn, Crtc Crtc, ConfigTimestamp xproto.Timestamp) GetCrtcInfoCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetCrtcInfo' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, true) c.NewRequest(getCrtcInfoRequest(c, Crtc, ConfigTimestamp), cookie) return GetCrtcInfoCookie{cookie} @@ -2833,6 +2944,9 @@ func GetCrtcInfo(c *xgb.Conn, Crtc Crtc, ConfigTimestamp xproto.Timestamp) GetCr // GetCrtcInfoUnchecked sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func GetCrtcInfoUnchecked(c *xgb.Conn, Crtc Crtc, ConfigTimestamp xproto.Timestamp) GetCrtcInfoCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetCrtcInfo' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, true) c.NewRequest(getCrtcInfoRequest(c, Crtc, ConfigTimestamp), cookie) return GetCrtcInfoCookie{cookie} @@ -2963,6 +3077,9 @@ type SetCrtcConfigCookie struct { // SetCrtcConfig sends a checked request. // If an error occurs, it will be returned with the reply by calling SetCrtcConfigCookie.Reply() func SetCrtcConfig(c *xgb.Conn, Crtc Crtc, Timestamp xproto.Timestamp, ConfigTimestamp xproto.Timestamp, X int16, Y int16, Mode Mode, Rotation uint16, Outputs []Output) SetCrtcConfigCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'SetCrtcConfig' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, true) c.NewRequest(setCrtcConfigRequest(c, Crtc, Timestamp, ConfigTimestamp, X, Y, Mode, Rotation, Outputs), cookie) return SetCrtcConfigCookie{cookie} @@ -2971,6 +3088,9 @@ func SetCrtcConfig(c *xgb.Conn, Crtc Crtc, Timestamp xproto.Timestamp, ConfigTim // SetCrtcConfigUnchecked sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func SetCrtcConfigUnchecked(c *xgb.Conn, Crtc Crtc, Timestamp xproto.Timestamp, ConfigTimestamp xproto.Timestamp, X int16, Y int16, Mode Mode, Rotation uint16, Outputs []Output) SetCrtcConfigCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'SetCrtcConfig' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, true) c.NewRequest(setCrtcConfigRequest(c, Crtc, Timestamp, ConfigTimestamp, X, Y, Mode, Rotation, Outputs), cookie) return SetCrtcConfigCookie{cookie} @@ -3075,6 +3195,9 @@ type GetCrtcGammaSizeCookie struct { // GetCrtcGammaSize sends a checked request. // If an error occurs, it will be returned with the reply by calling GetCrtcGammaSizeCookie.Reply() func GetCrtcGammaSize(c *xgb.Conn, Crtc Crtc) GetCrtcGammaSizeCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetCrtcGammaSize' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, true) c.NewRequest(getCrtcGammaSizeRequest(c, Crtc), cookie) return GetCrtcGammaSizeCookie{cookie} @@ -3083,6 +3206,9 @@ func GetCrtcGammaSize(c *xgb.Conn, Crtc Crtc) GetCrtcGammaSizeCookie { // GetCrtcGammaSizeUnchecked sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func GetCrtcGammaSizeUnchecked(c *xgb.Conn, Crtc Crtc) GetCrtcGammaSizeCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetCrtcGammaSize' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, true) c.NewRequest(getCrtcGammaSizeRequest(c, Crtc), cookie) return GetCrtcGammaSizeCookie{cookie} @@ -3160,6 +3286,9 @@ type GetCrtcGammaCookie struct { // GetCrtcGamma sends a checked request. // If an error occurs, it will be returned with the reply by calling GetCrtcGammaCookie.Reply() func GetCrtcGamma(c *xgb.Conn, Crtc Crtc) GetCrtcGammaCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetCrtcGamma' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, true) c.NewRequest(getCrtcGammaRequest(c, Crtc), cookie) return GetCrtcGammaCookie{cookie} @@ -3168,6 +3297,9 @@ func GetCrtcGamma(c *xgb.Conn, Crtc Crtc) GetCrtcGammaCookie { // GetCrtcGammaUnchecked sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func GetCrtcGammaUnchecked(c *xgb.Conn, Crtc Crtc) GetCrtcGammaCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetCrtcGamma' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, true) c.NewRequest(getCrtcGammaRequest(c, Crtc), cookie) return GetCrtcGammaCookie{cookie} @@ -3269,6 +3401,9 @@ type SetCrtcGammaCookie struct { // SetCrtcGamma sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func SetCrtcGamma(c *xgb.Conn, Crtc Crtc, Size uint16, Red []uint16, Green []uint16, Blue []uint16) SetCrtcGammaCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'SetCrtcGamma' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, false) c.NewRequest(setCrtcGammaRequest(c, Crtc, Size, Red, Green, Blue), cookie) return SetCrtcGammaCookie{cookie} @@ -3277,6 +3412,9 @@ func SetCrtcGamma(c *xgb.Conn, Crtc Crtc, Size uint16, Red []uint16, Green []uin // SetCrtcGammaChecked sends a checked request. // If an error occurs, it can be retrieved using SetCrtcGammaCookie.Check() func SetCrtcGammaChecked(c *xgb.Conn, Crtc Crtc, Size uint16, Red []uint16, Green []uint16, Blue []uint16) SetCrtcGammaCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'SetCrtcGamma' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, false) c.NewRequest(setCrtcGammaRequest(c, Crtc, Size, Red, Green, Blue), cookie) return SetCrtcGammaCookie{cookie} @@ -3341,6 +3479,9 @@ type GetScreenResourcesCurrentCookie struct { // GetScreenResourcesCurrent sends a checked request. // If an error occurs, it will be returned with the reply by calling GetScreenResourcesCurrentCookie.Reply() func GetScreenResourcesCurrent(c *xgb.Conn, Window xproto.Window) GetScreenResourcesCurrentCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetScreenResourcesCurrent' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, true) c.NewRequest(getScreenResourcesCurrentRequest(c, Window), cookie) return GetScreenResourcesCurrentCookie{cookie} @@ -3349,6 +3490,9 @@ func GetScreenResourcesCurrent(c *xgb.Conn, Window xproto.Window) GetScreenResou // GetScreenResourcesCurrentUnchecked sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func GetScreenResourcesCurrentUnchecked(c *xgb.Conn, Window xproto.Window) GetScreenResourcesCurrentCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetScreenResourcesCurrent' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, true) c.NewRequest(getScreenResourcesCurrentRequest(c, Window), cookie) return GetScreenResourcesCurrentCookie{cookie} @@ -3471,6 +3615,9 @@ type SetCrtcTransformCookie struct { // SetCrtcTransform sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func SetCrtcTransform(c *xgb.Conn, Crtc Crtc, Transform render.Transform, FilterLen uint16, FilterName string, FilterParams []render.Fixed) SetCrtcTransformCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'SetCrtcTransform' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, false) c.NewRequest(setCrtcTransformRequest(c, Crtc, Transform, FilterLen, FilterName, FilterParams), cookie) return SetCrtcTransformCookie{cookie} @@ -3479,6 +3626,9 @@ func SetCrtcTransform(c *xgb.Conn, Crtc Crtc, Transform render.Transform, Filter // SetCrtcTransformChecked sends a checked request. // If an error occurs, it can be retrieved using SetCrtcTransformCookie.Check() func SetCrtcTransformChecked(c *xgb.Conn, Crtc Crtc, Transform render.Transform, FilterLen uint16, FilterName string, FilterParams []render.Fixed) SetCrtcTransformCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'SetCrtcTransform' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, false) c.NewRequest(setCrtcTransformRequest(c, Crtc, Transform, FilterLen, FilterName, FilterParams), cookie) return SetCrtcTransformCookie{cookie} @@ -3540,6 +3690,9 @@ type GetCrtcTransformCookie struct { // GetCrtcTransform sends a checked request. // If an error occurs, it will be returned with the reply by calling GetCrtcTransformCookie.Reply() func GetCrtcTransform(c *xgb.Conn, Crtc Crtc) GetCrtcTransformCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetCrtcTransform' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, true) c.NewRequest(getCrtcTransformRequest(c, Crtc), cookie) return GetCrtcTransformCookie{cookie} @@ -3548,6 +3701,9 @@ func GetCrtcTransform(c *xgb.Conn, Crtc Crtc) GetCrtcTransformCookie { // GetCrtcTransformUnchecked sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func GetCrtcTransformUnchecked(c *xgb.Conn, Crtc Crtc) GetCrtcTransformCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetCrtcTransform' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, true) c.NewRequest(getCrtcTransformRequest(c, Crtc), cookie) return GetCrtcTransformCookie{cookie} @@ -3688,6 +3844,9 @@ type GetPanningCookie struct { // GetPanning sends a checked request. // If an error occurs, it will be returned with the reply by calling GetPanningCookie.Reply() func GetPanning(c *xgb.Conn, Crtc Crtc) GetPanningCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetPanning' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, true) c.NewRequest(getPanningRequest(c, Crtc), cookie) return GetPanningCookie{cookie} @@ -3696,6 +3855,9 @@ func GetPanning(c *xgb.Conn, Crtc Crtc) GetPanningCookie { // GetPanningUnchecked sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func GetPanningUnchecked(c *xgb.Conn, Crtc Crtc) GetPanningCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetPanning' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, true) c.NewRequest(getPanningRequest(c, Crtc), cookie) return GetPanningCookie{cookie} @@ -3819,6 +3981,9 @@ type SetPanningCookie struct { // SetPanning sends a checked request. // If an error occurs, it will be returned with the reply by calling SetPanningCookie.Reply() func SetPanning(c *xgb.Conn, Crtc Crtc, Timestamp xproto.Timestamp, Left uint16, Top uint16, Width uint16, Height uint16, TrackLeft uint16, TrackTop uint16, TrackWidth uint16, TrackHeight uint16, BorderLeft int16, BorderTop int16, BorderRight int16, BorderBottom int16) SetPanningCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'SetPanning' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, true) c.NewRequest(setPanningRequest(c, Crtc, Timestamp, Left, Top, Width, Height, TrackLeft, TrackTop, TrackWidth, TrackHeight, BorderLeft, BorderTop, BorderRight, BorderBottom), cookie) return SetPanningCookie{cookie} @@ -3827,6 +3992,9 @@ func SetPanning(c *xgb.Conn, Crtc Crtc, Timestamp xproto.Timestamp, Left uint16, // SetPanningUnchecked sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func SetPanningUnchecked(c *xgb.Conn, Crtc Crtc, Timestamp xproto.Timestamp, Left uint16, Top uint16, Width uint16, Height uint16, TrackLeft uint16, TrackTop uint16, TrackWidth uint16, TrackHeight uint16, BorderLeft int16, BorderTop int16, BorderRight int16, BorderBottom int16) SetPanningCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'SetPanning' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, true) c.NewRequest(setPanningRequest(c, Crtc, Timestamp, Left, Top, Width, Height, TrackLeft, TrackTop, TrackWidth, TrackHeight, BorderLeft, BorderTop, BorderRight, BorderBottom), cookie) return SetPanningCookie{cookie} @@ -3941,6 +4109,9 @@ type SetOutputPrimaryCookie struct { // SetOutputPrimary sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func SetOutputPrimary(c *xgb.Conn, Window xproto.Window, Output Output) SetOutputPrimaryCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'SetOutputPrimary' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, false) c.NewRequest(setOutputPrimaryRequest(c, Window, Output), cookie) return SetOutputPrimaryCookie{cookie} @@ -3949,6 +4120,9 @@ func SetOutputPrimary(c *xgb.Conn, Window xproto.Window, Output Output) SetOutpu // SetOutputPrimaryChecked sends a checked request. // If an error occurs, it can be retrieved using SetOutputPrimaryCookie.Check() func SetOutputPrimaryChecked(c *xgb.Conn, Window xproto.Window, Output Output) SetOutputPrimaryCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'SetOutputPrimary' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, false) c.NewRequest(setOutputPrimaryRequest(c, Window, Output), cookie) return SetOutputPrimaryCookie{cookie} @@ -3993,6 +4167,9 @@ type GetOutputPrimaryCookie struct { // GetOutputPrimary sends a checked request. // If an error occurs, it will be returned with the reply by calling GetOutputPrimaryCookie.Reply() func GetOutputPrimary(c *xgb.Conn, Window xproto.Window) GetOutputPrimaryCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetOutputPrimary' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(true, true) c.NewRequest(getOutputPrimaryRequest(c, Window), cookie) return GetOutputPrimaryCookie{cookie} @@ -4001,6 +4178,9 @@ func GetOutputPrimary(c *xgb.Conn, Window xproto.Window) GetOutputPrimaryCookie // GetOutputPrimaryUnchecked sends an unchecked request. // If an error occurs, it can only be retrieved using xgb.WaitForEvent or xgb.PollForEvent. func GetOutputPrimaryUnchecked(c *xgb.Conn, Window xproto.Window) GetOutputPrimaryCookie { + if _, ok := c.Extensions["RANDR"]; !ok { + panic("Cannot issue request 'GetOutputPrimary' using the uninitialized extension 'RANDR'. randr.Init(connObj) must be called first.") + } cookie := c.NewCookie(false, true) c.NewRequest(getOutputPrimaryRequest(c, Window), cookie) return GetOutputPrimaryCookie{cookie} |