bernard/deps 629c786

#1 build(deps): update 5 dependencies

state
merged · 629c786 · fast-forward
branch
bernard/deps → main
opened
bernard ·
updated
  • github.com/bnema/wlturbo v0.3.0 → v0.6.2
  • golang.org/x/sys v0.33.0 → v0.49.0
  • github.com/bnema/libwldevices-go v0.1.4 → v0.3.0 (test/consumer)
  • github.com/bnema/wlturbo v0.3.0 → v0.6.2 (test/consumer)
  • golang.org/x/sys v0.33.0 → v0.49.0 (test/consumer)

Bernard: update failed

dependency command failed (exit 1)
go: upgraded github.com/bnema/wlturbo v0.3.0 => v0.6.2
go: upgraded golang.org/x/sys v0.33.0 => v0.49.0
go: github.com/bnema/libwldevices-go/examples/pointer_constraints imports
github.com/bnema/wlturbo/protocol/core: module github.com/bnema/wlturbo@latest found (v0.7.0), but does not contain package github.com/bnema/wlturbo/protocol/core

Reproduce locally:

go get 'github.com/bnema/wlturbo@v0.6.2'
go get 'golang.org/x/sys@v0.49.0'
go mod tidy
cd "$(git rev-parse --show-toplevel)"
cd -- 'test/consumer'
go get 'github.com/bnema/libwldevices-go@v0.3.0'
go get 'github.com/bnema/wlturbo@v0.6.2'
go get 'golang.org/x/sys@v0.49.0'
go mod tidy

This branch was changed by hand: Bernard no longer rewrites it.

CommitSubjectAuthorDateSignatureStatus
629c786build(deps): migrate to bnema.dev wlturbo and go-wayland-bindingsbrice GPG Verified
4df7e7bbuild(deps): update 5 dependenciesBernard SSH Verified

Checks 2

21 files · +212 -93
2/2
M examples/pointer_constraints/main.go +1 -1
@@ -9,8 +9,8 @@ import (
99 "fmt"
1010 "log"
1111
12+ core "bnema.dev/go-wayland-bindings/client/wayland"
1213 "github.com/bnema/libwldevices-go/pointer_constraints"
13- "github.com/bnema/wlturbo/protocol/core"
1414 )
1515
1616 // Application represents your Wayland application
@@ -9,8 +9,8 @@ import (
9 "fmt"9 "fmt"
10 "log"10 "log"
11 11
12+ core "bnema.dev/go-wayland-bindings/client/wayland"
12 "github.com/bnema/libwldevices-go/pointer_constraints"13 "github.com/bnema/libwldevices-go/pointer_constraints"
13- "github.com/bnema/wlturbo/protocol/core"
14 )14 )
15 15
16 // Application represents your Wayland application16 // Application represents your Wayland application
M go.mod +3 -2
@@ -3,6 +3,7 @@ module github.com/bnema/libwldevices-go
33 go 1.27
44
55 require (
6- github.com/bnema/wlturbo v0.3.0
7- golang.org/x/sys v0.33.0
6+ bnema.dev/go-wayland-bindings v0.2.0
7+ bnema.dev/wlturbo v0.7.0
8+ golang.org/x/sys v0.49.0
89 )
@@ -3,6 +3,7 @@ module github.com/bnema/libwldevices-go
3 go 1.273 go 1.27
4 4
5 require (5 require (
6- github.com/bnema/wlturbo v0.3.06+ bnema.dev/go-wayland-bindings v0.2.0
7- golang.org/x/sys v0.33.07+ bnema.dev/wlturbo v0.7.0
8+ golang.org/x/sys v0.49.0
8 )9 )
M go.sum +6 -4 generated file: collapsed
M internal/client/client.go +2 -2
@@ -5,8 +5,8 @@ import (
55 "fmt"
66 "sync"
77
8- "github.com/bnema/wlturbo/protocol/core"
9- "github.com/bnema/wlturbo/wl"
8+ core "bnema.dev/go-wayland-bindings/client/wayland"
9+ "bnema.dev/wlturbo/wl"
1010 )
1111
1212 // Client manages the Wayland connection and protocol objects
@@ -5,8 +5,8 @@ import (
5 "fmt"5 "fmt"
6 "sync"6 "sync"
7 7
8- "github.com/bnema/wlturbo/protocol/core"8+ core "bnema.dev/go-wayland-bindings/client/wayland"
9- "github.com/bnema/wlturbo/wl"9+ "bnema.dev/wlturbo/wl"
10 )10 )
11 11
12 // Client manages the Wayland connection and protocol objects12 // Client manages the Wayland connection and protocol objects
M internal/protocols/generate.go +6 -6
@@ -1,8 +1,8 @@
1-// Package protocols contains device-specific Wayland bindings generated by WLTurbo.
1+// Package protocols contains device-specific Wayland bindings generated by wlbgen.
22 package protocols
33
4-//go:generate go run github.com/bnema/wlturbo/cmd/wlturbo-scanner -p protocols -o virtual_keyboard_generated.go -import wl_seat=github.com/bnema/wlturbo/protocol/core ../../protocol/virtual-keyboard-unstable-v1.xml
5-//go:generate go run github.com/bnema/wlturbo/cmd/wlturbo-scanner -p protocols -o virtual_pointer_generated.go -import wl_seat=github.com/bnema/wlturbo/protocol/core -import wl_output=github.com/bnema/wlturbo/protocol/core ../../protocol/wlr-virtual-pointer-unstable-v1.xml
6-//go:generate go run github.com/bnema/wlturbo/cmd/wlturbo-scanner -p protocols -o pointer_constraints_generated.go -import wl_surface=github.com/bnema/wlturbo/protocol/core -import wl_pointer=github.com/bnema/wlturbo/protocol/core -import wl_region=github.com/bnema/wlturbo/protocol/core ../../protocol/pointer-constraints-unstable-v1.xml
7-//go:generate go run github.com/bnema/wlturbo/cmd/wlturbo-scanner -p protocols -o output_management_generated.go ../../protocol/wlr-output-management-unstable-v1.xml
8-//go:generate go run github.com/bnema/wlturbo/cmd/wlturbo-scanner -p protocols -o keyboard_shortcuts_inhibitor_generated.go -import wl_surface=github.com/bnema/wlturbo/protocol/core -import wl_seat=github.com/bnema/wlturbo/protocol/core ../../protocol/keyboard-shortcuts-inhibit-unstable-v1.xml
4+//go:generate go run bnema.dev/go-wayland-bindings/cmd/wlbgen@v0.2.0 -side client -package protocols -out virtual_keyboard_generated.go ../../protocol/virtual-keyboard-unstable-v1.xml
5+//go:generate go run bnema.dev/go-wayland-bindings/cmd/wlbgen@v0.2.0 -side client -package protocols -out virtual_pointer_generated.go ../../protocol/wlr-virtual-pointer-unstable-v1.xml
6+//go:generate go run bnema.dev/go-wayland-bindings/cmd/wlbgen@v0.2.0 -side client -package protocols -out pointer_constraints_generated.go ../../protocol/pointer-constraints-unstable-v1.xml
7+//go:generate go run bnema.dev/go-wayland-bindings/cmd/wlbgen@v0.2.0 -side client -package protocols -out output_management_generated.go ../../protocol/wlr-output-management-unstable-v1.xml
8+//go:generate go run bnema.dev/go-wayland-bindings/cmd/wlbgen@v0.2.0 -side client -package protocols -out keyboard_shortcuts_inhibitor_generated.go ../../protocol/keyboard-shortcuts-inhibit-unstable-v1.xml
@@ -1,8 +1,8 @@
1-// Package protocols contains device-specific Wayland bindings generated by WLTurbo.1+// Package protocols contains device-specific Wayland bindings generated by wlbgen.
2 package protocols2 package protocols
3 3
4-//go:generate go run github.com/bnema/wlturbo/cmd/wlturbo-scanner -p protocols -o virtual_keyboard_generated.go -import wl_seat=github.com/bnema/wlturbo/protocol/core ../../protocol/virtual-keyboard-unstable-v1.xml4+//go:generate go run bnema.dev/go-wayland-bindings/cmd/wlbgen@v0.2.0 -side client -package protocols -out virtual_keyboard_generated.go ../../protocol/virtual-keyboard-unstable-v1.xml
5-//go:generate go run github.com/bnema/wlturbo/cmd/wlturbo-scanner -p protocols -o virtual_pointer_generated.go -import wl_seat=github.com/bnema/wlturbo/protocol/core -import wl_output=github.com/bnema/wlturbo/protocol/core ../../protocol/wlr-virtual-pointer-unstable-v1.xml5+//go:generate go run bnema.dev/go-wayland-bindings/cmd/wlbgen@v0.2.0 -side client -package protocols -out virtual_pointer_generated.go ../../protocol/wlr-virtual-pointer-unstable-v1.xml
6-//go:generate go run github.com/bnema/wlturbo/cmd/wlturbo-scanner -p protocols -o pointer_constraints_generated.go -import wl_surface=github.com/bnema/wlturbo/protocol/core -import wl_pointer=github.com/bnema/wlturbo/protocol/core -import wl_region=github.com/bnema/wlturbo/protocol/core ../../protocol/pointer-constraints-unstable-v1.xml6+//go:generate go run bnema.dev/go-wayland-bindings/cmd/wlbgen@v0.2.0 -side client -package protocols -out pointer_constraints_generated.go ../../protocol/pointer-constraints-unstable-v1.xml
7-//go:generate go run github.com/bnema/wlturbo/cmd/wlturbo-scanner -p protocols -o output_management_generated.go ../../protocol/wlr-output-management-unstable-v1.xml7+//go:generate go run bnema.dev/go-wayland-bindings/cmd/wlbgen@v0.2.0 -side client -package protocols -out output_management_generated.go ../../protocol/wlr-output-management-unstable-v1.xml
8-//go:generate go run github.com/bnema/wlturbo/cmd/wlturbo-scanner -p protocols -o keyboard_shortcuts_inhibitor_generated.go -import wl_surface=github.com/bnema/wlturbo/protocol/core -import wl_seat=github.com/bnema/wlturbo/protocol/core ../../protocol/keyboard-shortcuts-inhibit-unstable-v1.xml8+//go:generate go run bnema.dev/go-wayland-bindings/cmd/wlbgen@v0.2.0 -side client -package protocols -out keyboard_shortcuts_inhibitor_generated.go ../../protocol/keyboard-shortcuts-inhibit-unstable-v1.xml
M internal/protocols/keyboard_shortcuts_inhibitor_generated.go +29 -7
@@ -1,15 +1,37 @@
1-// Code generated by wlturbo-scanner. DO NOT EDIT.
1+// Code generated by wlbgen. DO NOT EDIT.
22 // Protocol: keyboard_shortcuts_inhibit_unstable_v1
33 // Source: keyboard-shortcuts-inhibit-unstable-v1.xml
44
5+// Upstream protocol copyright and license:
6+// Copyright © 2017 Red Hat Inc.
7+//
8+// Permission is hereby granted, free of charge, to any person obtaining a
9+// copy of this software and associated documentation files (the "Software"),
10+// to deal in the Software without restriction, including without limitation
11+// the rights to use, copy, modify, merge, publish, distribute, sublicense,
12+// and/or sell copies of the Software, and to permit persons to whom the
13+// Software is furnished to do so, subject to the following conditions:
14+//
15+// The above copyright notice and this permission notice (including the next
16+// paragraph) shall be included in all copies or substantial portions of the
17+// Software.
18+//
19+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
20+// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
21+// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
22+// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
23+// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
24+// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
25+// DEALINGS IN THE SOFTWARE.
26+
527 package protocols
628
729 import (
830 "sync"
931
10- cross_wl_seat "github.com/bnema/wlturbo/protocol/core"
11- cross_wl_surface "github.com/bnema/wlturbo/protocol/core"
12- "github.com/bnema/wlturbo/wl"
32+ cross_wl_seat "bnema.dev/go-wayland-bindings/client/wayland"
33+ cross_wl_surface "bnema.dev/go-wayland-bindings/client/wayland"
34+ "bnema.dev/wlturbo/wl"
1335 )
1436
1537 // ERROR_ALREADY_INHIBITED is the error already_inhibited value.
@@ -33,7 +55,7 @@ func NewKeyboardShortcutsInhibitManager(ctx *wl.Context) *KeyboardShortcutsInhib
3355
3456 // Destroy the keyboard shortcuts inhibitor manager.
3557 func (o *KeyboardShortcutsInhibitManager) Destroy() error {
36- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_keyboard_shortcuts_inhibit_manager_v1.destroy", Destructor: true}); err != nil {
58+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_keyboard_shortcuts_inhibit_manager_v1.destroy", Destructor: true}); err != nil {
3759 return err
3860 }
3961 return nil
@@ -51,7 +73,7 @@ func (o *KeyboardShortcutsInhibitManager) InhibitShortcuts(surface *cross_wl_sur
5173 }
5274 child := &KeyboardShortcutsInhibitor{}
5375 child.SetContext(o.Context())
54- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 1, Name: "zwp_keyboard_shortcuts_inhibit_manager_v1.inhibit_shortcuts", Child: child}, child, arg1, arg2); err != nil {
76+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 1, Name: "zwp_keyboard_shortcuts_inhibit_manager_v1.inhibit_shortcuts", Child: child}, wl.ArgObject(child), wl.ArgObject(arg1), wl.ArgObject(arg2)); err != nil {
5577 return nil, err
5678 }
5779 return child, nil
@@ -95,7 +117,7 @@ func NewKeyboardShortcutsInhibitor(ctx *wl.Context) *KeyboardShortcutsInhibitor
95117
96118 // Remove the keyboard shortcuts inhibitor from the associated wl_surface.
97119 func (o *KeyboardShortcutsInhibitor) Destroy() error {
98- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_keyboard_shortcuts_inhibitor_v1.destroy", Destructor: true}); err != nil {
120+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_keyboard_shortcuts_inhibitor_v1.destroy", Destructor: true}); err != nil {
99121 return err
100122 }
101123 return nil
@@ -1,15 +1,37 @@
1-// Code generated by wlturbo-scanner. DO NOT EDIT.1+// Code generated by wlbgen. DO NOT EDIT.
2 // Protocol: keyboard_shortcuts_inhibit_unstable_v12 // Protocol: keyboard_shortcuts_inhibit_unstable_v1
3 // Source: keyboard-shortcuts-inhibit-unstable-v1.xml3 // Source: keyboard-shortcuts-inhibit-unstable-v1.xml
4 4
5+// Upstream protocol copyright and license:
6+// Copyright © 2017 Red Hat Inc.
7+//
8+// Permission is hereby granted, free of charge, to any person obtaining a
9+// copy of this software and associated documentation files (the "Software"),
10+// to deal in the Software without restriction, including without limitation
11+// the rights to use, copy, modify, merge, publish, distribute, sublicense,
12+// and/or sell copies of the Software, and to permit persons to whom the
13+// Software is furnished to do so, subject to the following conditions:
14+//
15+// The above copyright notice and this permission notice (including the next
16+// paragraph) shall be included in all copies or substantial portions of the
17+// Software.
18+//
19+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
20+// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
21+// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
22+// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
23+// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
24+// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
25+// DEALINGS IN THE SOFTWARE.
26+
5 package protocols27 package protocols
6 28
7 import (29 import (
8 "sync"30 "sync"
9 31
10- cross_wl_seat "github.com/bnema/wlturbo/protocol/core"32+ cross_wl_seat "bnema.dev/go-wayland-bindings/client/wayland"
11- cross_wl_surface "github.com/bnema/wlturbo/protocol/core"33+ cross_wl_surface "bnema.dev/go-wayland-bindings/client/wayland"
12- "github.com/bnema/wlturbo/wl"34+ "bnema.dev/wlturbo/wl"
13 )35 )
14 36
15 // ERROR_ALREADY_INHIBITED is the error already_inhibited value.37 // ERROR_ALREADY_INHIBITED is the error already_inhibited value.
@@ -33,7 +55,7 @@ func NewKeyboardShortcutsInhibitManager(ctx *wl.Context) *KeyboardShortcutsInhib
33 55
34 // Destroy the keyboard shortcuts inhibitor manager.56 // Destroy the keyboard shortcuts inhibitor manager.
35 func (o *KeyboardShortcutsInhibitManager) Destroy() error {57 func (o *KeyboardShortcutsInhibitManager) Destroy() error {
36- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_keyboard_shortcuts_inhibit_manager_v1.destroy", Destructor: true}); err != nil {58+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_keyboard_shortcuts_inhibit_manager_v1.destroy", Destructor: true}); err != nil {
37 return err59 return err
38 }60 }
39 return nil61 return nil
@@ -51,7 +73,7 @@ func (o *KeyboardShortcutsInhibitManager) InhibitShortcuts(surface *cross_wl_sur
51 }73 }
52 child := &KeyboardShortcutsInhibitor{}74 child := &KeyboardShortcutsInhibitor{}
53 child.SetContext(o.Context())75 child.SetContext(o.Context())
54- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 1, Name: "zwp_keyboard_shortcuts_inhibit_manager_v1.inhibit_shortcuts", Child: child}, child, arg1, arg2); err != nil {76+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 1, Name: "zwp_keyboard_shortcuts_inhibit_manager_v1.inhibit_shortcuts", Child: child}, wl.ArgObject(child), wl.ArgObject(arg1), wl.ArgObject(arg2)); err != nil {
55 return nil, err77 return nil, err
56 }78 }
57 return child, nil79 return child, nil
@@ -95,7 +117,7 @@ func NewKeyboardShortcutsInhibitor(ctx *wl.Context) *KeyboardShortcutsInhibitor
95 117
96 // Remove the keyboard shortcuts inhibitor from the associated wl_surface.118 // Remove the keyboard shortcuts inhibitor from the associated wl_surface.
97 func (o *KeyboardShortcutsInhibitor) Destroy() error {119 func (o *KeyboardShortcutsInhibitor) Destroy() error {
98- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_keyboard_shortcuts_inhibitor_v1.destroy", Destructor: true}); err != nil {120+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_keyboard_shortcuts_inhibitor_v1.destroy", Destructor: true}); err != nil {
99 return err121 return err
100 }122 }
101 return nil123 return nil
M internal/protocols/output_management_generated.go +41 -17
@@ -1,13 +1,37 @@
1-// Code generated by wlturbo-scanner. DO NOT EDIT.
1+// Code generated by wlbgen. DO NOT EDIT.
22 // Protocol: wlr_output_management_unstable_v1
33 // Source: wlr-output-management-unstable-v1.xml
44
5+// Upstream protocol copyright and license:
6+// Copyright © 2019 Purism SPC
7+//
8+// Permission to use, copy, modify, distribute, and sell this
9+// software and its documentation for any purpose is hereby granted
10+// without fee, provided that the above copyright notice appear in
11+// all copies and that both that copyright notice and this permission
12+// notice appear in supporting documentation, and that the name of
13+// the copyright holders not be used in advertising or publicity
14+// pertaining to distribution of the software without specific,
15+// written prior permission. The copyright holders make no
16+// representations about the suitability of this software for any
17+// purpose. It is provided "as is" without express or implied
18+// warranty.
19+//
20+// THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS
21+// SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
22+// FITNESS, IN NO EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY
23+// SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
24+// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
25+// AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
26+// ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
27+// THIS SOFTWARE.
28+
529 package protocols
630
731 import (
832 "sync"
933
10- "github.com/bnema/wlturbo/wl"
34+ "bnema.dev/wlturbo/wl"
1135 )
1236
1337 // ADAPTIVE_SYNC_STATE_DISABLED is the adaptive_sync_state disabled value.
@@ -69,7 +93,7 @@ func NewOutputManager(ctx *wl.Context) *OutputManager {
6993 func (o *OutputManager) CreateConfiguration(serial uint32) (*OutputConfiguration, error) {
7094 child := &OutputConfiguration{}
7195 child.SetContext(o.Context())
72- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_output_manager_v1.create_configuration", Child: child}, child, serial); err != nil {
96+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_output_manager_v1.create_configuration", Child: child}, wl.ArgObject(child), wl.ArgUint(serial)); err != nil {
7397 return nil, err
7498 }
7599 return child, nil
@@ -77,7 +101,7 @@ func (o *OutputManager) CreateConfiguration(serial uint32) (*OutputConfiguration
77101
78102 // Indicates the client no longer wishes to receive events for output configuration changes. However the compositor may emit further events, until the finished event is emitted. The client must not send any more requests after this one.
79103 func (o *OutputManager) Stop() error {
80- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 1, Name: "zwlr_output_manager_v1.stop"}); err != nil {
104+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 1, Name: "zwlr_output_manager_v1.stop"}); err != nil {
81105 return err
82106 }
83107 return nil
@@ -231,7 +255,7 @@ func NewOutputHead(ctx *wl.Context) *OutputHead {
231255
232256 // This request indicates that the client will no longer use this head object.
233257 func (o *OutputHead) Release() error {
234- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_output_head_v1.release", Since: 3, Destructor: true}); err != nil {
258+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_output_head_v1.release", Since: 3, Destructor: true}); err != nil {
235259 return err
236260 }
237261 return nil
@@ -717,7 +741,7 @@ func NewOutputMode(ctx *wl.Context) *OutputMode {
717741
718742 // This request indicates that the client will no longer use this mode object.
719743 func (o *OutputMode) Release() error {
720- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_output_mode_v1.release", Since: 3, Destructor: true}); err != nil {
744+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_output_mode_v1.release", Since: 3, Destructor: true}); err != nil {
721745 return err
722746 }
723747 return nil
@@ -891,7 +915,7 @@ func (o *OutputConfiguration) EnableHead(head *OutputHead) (*OutputConfiguration
891915 }
892916 child := &OutputConfigurationHead{}
893917 child.SetContext(o.Context())
894- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_output_configuration_v1.enable_head", Child: child}, child, arg1); err != nil {
918+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_output_configuration_v1.enable_head", Child: child}, wl.ArgObject(child), wl.ArgObject(arg1)); err != nil {
895919 return nil, err
896920 }
897921 return child, nil
@@ -903,7 +927,7 @@ func (o *OutputConfiguration) DisableHead(head *OutputHead) error {
903927 if head != nil {
904928 arg0 = head
905929 }
906- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 1, Name: "zwlr_output_configuration_v1.disable_head"}, arg0); err != nil {
930+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 1, Name: "zwlr_output_configuration_v1.disable_head"}, wl.ArgObject(arg0)); err != nil {
907931 return err
908932 }
909933 return nil
@@ -911,7 +935,7 @@ func (o *OutputConfiguration) DisableHead(head *OutputHead) error {
911935
912936 // Apply the new output configuration. In case the configuration is successfully applied, there is no guarantee that the new output state matches completely the requested configuration. For instance, a compositor might round the scale if it doesn't support fractional scaling. After this request has been sent, the compositor must respond with an succeeded, failed or cancelled event. Sending a request that isn't the destructor is a protocol error.
913937 func (o *OutputConfiguration) Apply() error {
914- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 2, Name: "zwlr_output_configuration_v1.apply"}); err != nil {
938+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 2, Name: "zwlr_output_configuration_v1.apply"}); err != nil {
915939 return err
916940 }
917941 return nil
@@ -919,7 +943,7 @@ func (o *OutputConfiguration) Apply() error {
919943
920944 // Test the new output configuration. The configuration won't be applied, but will only be validated. Even if the compositor succeeds to test a configuration, applying it may fail. After this request has been sent, the compositor must respond with an succeeded, failed or cancelled event. Sending a request that isn't the destructor is a protocol error.
921945 func (o *OutputConfiguration) Test() error {
922- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 3, Name: "zwlr_output_configuration_v1.test"}); err != nil {
946+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 3, Name: "zwlr_output_configuration_v1.test"}); err != nil {
923947 return err
924948 }
925949 return nil
@@ -927,7 +951,7 @@ func (o *OutputConfiguration) Test() error {
927951
928952 // Using this request a client can tell the compositor that it is not going to use the configuration object anymore. Any changes to the outputs that have not been applied will be discarded. This request also destroys wlr_output_configuration_head objects created via this object.
929953 func (o *OutputConfiguration) Destroy() error {
930- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 4, Name: "zwlr_output_configuration_v1.destroy", Destructor: true}); err != nil {
954+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 4, Name: "zwlr_output_configuration_v1.destroy", Destructor: true}); err != nil {
931955 return err
932956 }
933957 return nil
@@ -1060,7 +1084,7 @@ func (o *OutputConfigurationHead) SetMode(mode *OutputMode) error {
10601084 if mode != nil {
10611085 arg0 = mode
10621086 }
1063- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_output_configuration_head_v1.set_mode"}, arg0); err != nil {
1087+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_output_configuration_head_v1.set_mode"}, wl.ArgObject(arg0)); err != nil {
10641088 return err
10651089 }
10661090 return nil
@@ -1068,7 +1092,7 @@ func (o *OutputConfigurationHead) SetMode(mode *OutputMode) error {
10681092
10691093 // This request assigns a custom mode to the head. The size is given in physical hardware units of the output device. If set to zero, the refresh rate is unspecified. It is a protocol error to set both a mode and a custom mode.
10701094 func (o *OutputConfigurationHead) SetCustomMode(width int32, height int32, refresh int32) error {
1071- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 1, Name: "zwlr_output_configuration_head_v1.set_custom_mode"}, width, height, refresh); err != nil {
1095+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 1, Name: "zwlr_output_configuration_head_v1.set_custom_mode"}, wl.ArgInt(width), wl.ArgInt(height), wl.ArgInt(refresh)); err != nil {
10721096 return err
10731097 }
10741098 return nil
@@ -1076,7 +1100,7 @@ func (o *OutputConfigurationHead) SetCustomMode(width int32, height int32, refre
10761100
10771101 // This request sets the head's position in the global compositor space.
10781102 func (o *OutputConfigurationHead) SetPosition(x int32, y int32) error {
1079- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 2, Name: "zwlr_output_configuration_head_v1.set_position"}, x, y); err != nil {
1103+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 2, Name: "zwlr_output_configuration_head_v1.set_position"}, wl.ArgInt(x), wl.ArgInt(y)); err != nil {
10801104 return err
10811105 }
10821106 return nil
@@ -1084,7 +1108,7 @@ func (o *OutputConfigurationHead) SetPosition(x int32, y int32) error {
10841108
10851109 // This request sets the head's transform.
10861110 func (o *OutputConfigurationHead) SetTransform(transform int32) error {
1087- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 3, Name: "zwlr_output_configuration_head_v1.set_transform"}, transform); err != nil {
1111+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 3, Name: "zwlr_output_configuration_head_v1.set_transform"}, wl.ArgInt(transform)); err != nil {
10881112 return err
10891113 }
10901114 return nil
@@ -1092,7 +1116,7 @@ func (o *OutputConfigurationHead) SetTransform(transform int32) error {
10921116
10931117 // This request sets the head's scale.
10941118 func (o *OutputConfigurationHead) SetScale(scale wl.Fixed) error {
1095- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 4, Name: "zwlr_output_configuration_head_v1.set_scale"}, scale); err != nil {
1119+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 4, Name: "zwlr_output_configuration_head_v1.set_scale"}, wl.ArgFixed(scale)); err != nil {
10961120 return err
10971121 }
10981122 return nil
@@ -1100,7 +1124,7 @@ func (o *OutputConfigurationHead) SetScale(scale wl.Fixed) error {
11001124
11011125 // This request enables/disables adaptive sync. Adaptive sync is also known as Variable Refresh Rate or VRR.
11021126 func (o *OutputConfigurationHead) SetAdaptiveSync(state uint32) error {
1103- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 5, Name: "zwlr_output_configuration_head_v1.set_adaptive_sync", Since: 4}, state); err != nil {
1127+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 5, Name: "zwlr_output_configuration_head_v1.set_adaptive_sync", Since: 4}, wl.ArgUint(state)); err != nil {
11041128 return err
11051129 }
11061130 return nil
@@ -1,13 +1,37 @@
1-// Code generated by wlturbo-scanner. DO NOT EDIT.1+// Code generated by wlbgen. DO NOT EDIT.
2 // Protocol: wlr_output_management_unstable_v12 // Protocol: wlr_output_management_unstable_v1
3 // Source: wlr-output-management-unstable-v1.xml3 // Source: wlr-output-management-unstable-v1.xml
4 4
5+// Upstream protocol copyright and license:
6+// Copyright © 2019 Purism SPC
7+//
8+// Permission to use, copy, modify, distribute, and sell this
9+// software and its documentation for any purpose is hereby granted
10+// without fee, provided that the above copyright notice appear in
11+// all copies and that both that copyright notice and this permission
12+// notice appear in supporting documentation, and that the name of
13+// the copyright holders not be used in advertising or publicity
14+// pertaining to distribution of the software without specific,
15+// written prior permission. The copyright holders make no
16+// representations about the suitability of this software for any
17+// purpose. It is provided "as is" without express or implied
18+// warranty.
19+//
20+// THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS
21+// SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
22+// FITNESS, IN NO EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY
23+// SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
24+// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
25+// AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
26+// ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
27+// THIS SOFTWARE.
28+
5 package protocols29 package protocols
6 30
7 import (31 import (
8 "sync"32 "sync"
9 33
10- "github.com/bnema/wlturbo/wl"34+ "bnema.dev/wlturbo/wl"
11 )35 )
12 36
13 // ADAPTIVE_SYNC_STATE_DISABLED is the adaptive_sync_state disabled value.37 // ADAPTIVE_SYNC_STATE_DISABLED is the adaptive_sync_state disabled value.
@@ -69,7 +93,7 @@ func NewOutputManager(ctx *wl.Context) *OutputManager {
69 func (o *OutputManager) CreateConfiguration(serial uint32) (*OutputConfiguration, error) {93 func (o *OutputManager) CreateConfiguration(serial uint32) (*OutputConfiguration, error) {
70 child := &OutputConfiguration{}94 child := &OutputConfiguration{}
71 child.SetContext(o.Context())95 child.SetContext(o.Context())
72- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_output_manager_v1.create_configuration", Child: child}, child, serial); err != nil {96+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_output_manager_v1.create_configuration", Child: child}, wl.ArgObject(child), wl.ArgUint(serial)); err != nil {
73 return nil, err97 return nil, err
74 }98 }
75 return child, nil99 return child, nil
@@ -77,7 +101,7 @@ func (o *OutputManager) CreateConfiguration(serial uint32) (*OutputConfiguration
77 101
78 // Indicates the client no longer wishes to receive events for output configuration changes. However the compositor may emit further events, until the finished event is emitted. The client must not send any more requests after this one.102 // Indicates the client no longer wishes to receive events for output configuration changes. However the compositor may emit further events, until the finished event is emitted. The client must not send any more requests after this one.
79 func (o *OutputManager) Stop() error {103 func (o *OutputManager) Stop() error {
80- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 1, Name: "zwlr_output_manager_v1.stop"}); err != nil {104+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 1, Name: "zwlr_output_manager_v1.stop"}); err != nil {
81 return err105 return err
82 }106 }
83 return nil107 return nil
@@ -231,7 +255,7 @@ func NewOutputHead(ctx *wl.Context) *OutputHead {
231 255
232 // This request indicates that the client will no longer use this head object.256 // This request indicates that the client will no longer use this head object.
233 func (o *OutputHead) Release() error {257 func (o *OutputHead) Release() error {
234- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_output_head_v1.release", Since: 3, Destructor: true}); err != nil {258+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_output_head_v1.release", Since: 3, Destructor: true}); err != nil {
235 return err259 return err
236 }260 }
237 return nil261 return nil
@@ -717,7 +741,7 @@ func NewOutputMode(ctx *wl.Context) *OutputMode {
717 741
718 // This request indicates that the client will no longer use this mode object.742 // This request indicates that the client will no longer use this mode object.
719 func (o *OutputMode) Release() error {743 func (o *OutputMode) Release() error {
720- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_output_mode_v1.release", Since: 3, Destructor: true}); err != nil {744+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_output_mode_v1.release", Since: 3, Destructor: true}); err != nil {
721 return err745 return err
722 }746 }
723 return nil747 return nil
@@ -891,7 +915,7 @@ func (o *OutputConfiguration) EnableHead(head *OutputHead) (*OutputConfiguration
891 }915 }
892 child := &OutputConfigurationHead{}916 child := &OutputConfigurationHead{}
893 child.SetContext(o.Context())917 child.SetContext(o.Context())
894- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_output_configuration_v1.enable_head", Child: child}, child, arg1); err != nil {918+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_output_configuration_v1.enable_head", Child: child}, wl.ArgObject(child), wl.ArgObject(arg1)); err != nil {
895 return nil, err919 return nil, err
896 }920 }
897 return child, nil921 return child, nil
@@ -903,7 +927,7 @@ func (o *OutputConfiguration) DisableHead(head *OutputHead) error {
903 if head != nil {927 if head != nil {
904 arg0 = head928 arg0 = head
905 }929 }
906- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 1, Name: "zwlr_output_configuration_v1.disable_head"}, arg0); err != nil {930+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 1, Name: "zwlr_output_configuration_v1.disable_head"}, wl.ArgObject(arg0)); err != nil {
907 return err931 return err
908 }932 }
909 return nil933 return nil
@@ -911,7 +935,7 @@ func (o *OutputConfiguration) DisableHead(head *OutputHead) error {
911 935
912 // Apply the new output configuration. In case the configuration is successfully applied, there is no guarantee that the new output state matches completely the requested configuration. For instance, a compositor might round the scale if it doesn't support fractional scaling. After this request has been sent, the compositor must respond with an succeeded, failed or cancelled event. Sending a request that isn't the destructor is a protocol error.936 // Apply the new output configuration. In case the configuration is successfully applied, there is no guarantee that the new output state matches completely the requested configuration. For instance, a compositor might round the scale if it doesn't support fractional scaling. After this request has been sent, the compositor must respond with an succeeded, failed or cancelled event. Sending a request that isn't the destructor is a protocol error.
913 func (o *OutputConfiguration) Apply() error {937 func (o *OutputConfiguration) Apply() error {
914- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 2, Name: "zwlr_output_configuration_v1.apply"}); err != nil {938+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 2, Name: "zwlr_output_configuration_v1.apply"}); err != nil {
915 return err939 return err
916 }940 }
917 return nil941 return nil
@@ -919,7 +943,7 @@ func (o *OutputConfiguration) Apply() error {
919 943
920 // Test the new output configuration. The configuration won't be applied, but will only be validated. Even if the compositor succeeds to test a configuration, applying it may fail. After this request has been sent, the compositor must respond with an succeeded, failed or cancelled event. Sending a request that isn't the destructor is a protocol error.944 // Test the new output configuration. The configuration won't be applied, but will only be validated. Even if the compositor succeeds to test a configuration, applying it may fail. After this request has been sent, the compositor must respond with an succeeded, failed or cancelled event. Sending a request that isn't the destructor is a protocol error.
921 func (o *OutputConfiguration) Test() error {945 func (o *OutputConfiguration) Test() error {
922- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 3, Name: "zwlr_output_configuration_v1.test"}); err != nil {946+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 3, Name: "zwlr_output_configuration_v1.test"}); err != nil {
923 return err947 return err
924 }948 }
925 return nil949 return nil
@@ -927,7 +951,7 @@ func (o *OutputConfiguration) Test() error {
927 951
928 // Using this request a client can tell the compositor that it is not going to use the configuration object anymore. Any changes to the outputs that have not been applied will be discarded. This request also destroys wlr_output_configuration_head objects created via this object.952 // Using this request a client can tell the compositor that it is not going to use the configuration object anymore. Any changes to the outputs that have not been applied will be discarded. This request also destroys wlr_output_configuration_head objects created via this object.
929 func (o *OutputConfiguration) Destroy() error {953 func (o *OutputConfiguration) Destroy() error {
930- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 4, Name: "zwlr_output_configuration_v1.destroy", Destructor: true}); err != nil {954+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 4, Name: "zwlr_output_configuration_v1.destroy", Destructor: true}); err != nil {
931 return err955 return err
932 }956 }
933 return nil957 return nil
@@ -1060,7 +1084,7 @@ func (o *OutputConfigurationHead) SetMode(mode *OutputMode) error {
1060 if mode != nil {1084 if mode != nil {
1061 arg0 = mode1085 arg0 = mode
1062 }1086 }
1063- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_output_configuration_head_v1.set_mode"}, arg0); err != nil {1087+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_output_configuration_head_v1.set_mode"}, wl.ArgObject(arg0)); err != nil {
1064 return err1088 return err
1065 }1089 }
1066 return nil1090 return nil
@@ -1068,7 +1092,7 @@ func (o *OutputConfigurationHead) SetMode(mode *OutputMode) error {
1068 1092
1069 // This request assigns a custom mode to the head. The size is given in physical hardware units of the output device. If set to zero, the refresh rate is unspecified. It is a protocol error to set both a mode and a custom mode.1093 // This request assigns a custom mode to the head. The size is given in physical hardware units of the output device. If set to zero, the refresh rate is unspecified. It is a protocol error to set both a mode and a custom mode.
1070 func (o *OutputConfigurationHead) SetCustomMode(width int32, height int32, refresh int32) error {1094 func (o *OutputConfigurationHead) SetCustomMode(width int32, height int32, refresh int32) error {
1071- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 1, Name: "zwlr_output_configuration_head_v1.set_custom_mode"}, width, height, refresh); err != nil {1095+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 1, Name: "zwlr_output_configuration_head_v1.set_custom_mode"}, wl.ArgInt(width), wl.ArgInt(height), wl.ArgInt(refresh)); err != nil {
1072 return err1096 return err
1073 }1097 }
1074 return nil1098 return nil
@@ -1076,7 +1100,7 @@ func (o *OutputConfigurationHead) SetCustomMode(width int32, height int32, refre
1076 1100
1077 // This request sets the head's position in the global compositor space.1101 // This request sets the head's position in the global compositor space.
1078 func (o *OutputConfigurationHead) SetPosition(x int32, y int32) error {1102 func (o *OutputConfigurationHead) SetPosition(x int32, y int32) error {
1079- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 2, Name: "zwlr_output_configuration_head_v1.set_position"}, x, y); err != nil {1103+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 2, Name: "zwlr_output_configuration_head_v1.set_position"}, wl.ArgInt(x), wl.ArgInt(y)); err != nil {
1080 return err1104 return err
1081 }1105 }
1082 return nil1106 return nil
@@ -1084,7 +1108,7 @@ func (o *OutputConfigurationHead) SetPosition(x int32, y int32) error {
1084 1108
1085 // This request sets the head's transform.1109 // This request sets the head's transform.
1086 func (o *OutputConfigurationHead) SetTransform(transform int32) error {1110 func (o *OutputConfigurationHead) SetTransform(transform int32) error {
1087- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 3, Name: "zwlr_output_configuration_head_v1.set_transform"}, transform); err != nil {1111+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 3, Name: "zwlr_output_configuration_head_v1.set_transform"}, wl.ArgInt(transform)); err != nil {
1088 return err1112 return err
1089 }1113 }
1090 return nil1114 return nil
@@ -1092,7 +1116,7 @@ func (o *OutputConfigurationHead) SetTransform(transform int32) error {
1092 1116
1093 // This request sets the head's scale.1117 // This request sets the head's scale.
1094 func (o *OutputConfigurationHead) SetScale(scale wl.Fixed) error {1118 func (o *OutputConfigurationHead) SetScale(scale wl.Fixed) error {
1095- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 4, Name: "zwlr_output_configuration_head_v1.set_scale"}, scale); err != nil {1119+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 4, Name: "zwlr_output_configuration_head_v1.set_scale"}, wl.ArgFixed(scale)); err != nil {
1096 return err1120 return err
1097 }1121 }
1098 return nil1122 return nil
@@ -1100,7 +1124,7 @@ func (o *OutputConfigurationHead) SetScale(scale wl.Fixed) error {
1100 1124
1101 // This request enables/disables adaptive sync. Adaptive sync is also known as Variable Refresh Rate or VRR.1125 // This request enables/disables adaptive sync. Adaptive sync is also known as Variable Refresh Rate or VRR.
1102 func (o *OutputConfigurationHead) SetAdaptiveSync(state uint32) error {1126 func (o *OutputConfigurationHead) SetAdaptiveSync(state uint32) error {
1103- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 5, Name: "zwlr_output_configuration_head_v1.set_adaptive_sync", Since: 4}, state); err != nil {1127+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 5, Name: "zwlr_output_configuration_head_v1.set_adaptive_sync", Since: 4}, wl.ArgUint(state)); err != nil {
1104 return err1128 return err
1105 }1129 }
1106 return nil1130 return nil
M internal/protocols/pointer_constraints_generated.go +36 -13
@@ -1,16 +1,39 @@
1-// Code generated by wlturbo-scanner. DO NOT EDIT.
1+// Code generated by wlbgen. DO NOT EDIT.
22 // Protocol: pointer_constraints_unstable_v1
33 // Source: pointer-constraints-unstable-v1.xml
44
5+// Upstream protocol copyright and license:
6+// Copyright © 2014 Jonas Ådahl
7+// Copyright © 2015 Red Hat Inc.
8+//
9+// Permission is hereby granted, free of charge, to any person obtaining a
10+// copy of this software and associated documentation files (the "Software"),
11+// to deal in the Software without restriction, including without limitation
12+// the rights to use, copy, modify, merge, publish, distribute, sublicense,
13+// and/or sell copies of the Software, and to permit persons to whom the
14+// Software is furnished to do so, subject to the following conditions:
15+//
16+// The above copyright notice and this permission notice (including the next
17+// paragraph) shall be included in all copies or substantial portions of the
18+// Software.
19+//
20+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
21+// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
22+// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
23+// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
24+// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
25+// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
26+// DEALINGS IN THE SOFTWARE.
27+
528 package protocols
629
730 import (
831 "sync"
932
10- cross_wl_pointer "github.com/bnema/wlturbo/protocol/core"
11- cross_wl_region "github.com/bnema/wlturbo/protocol/core"
12- cross_wl_surface "github.com/bnema/wlturbo/protocol/core"
13- "github.com/bnema/wlturbo/wl"
33+ cross_wl_pointer "bnema.dev/go-wayland-bindings/client/wayland"
34+ cross_wl_region "bnema.dev/go-wayland-bindings/client/wayland"
35+ cross_wl_surface "bnema.dev/go-wayland-bindings/client/wayland"
36+ "bnema.dev/wlturbo/wl"
1437 )
1538
1639 // ERROR_ALREADY_CONSTRAINED is the error already_constrained value.
@@ -40,7 +63,7 @@ func NewPointerConstraints(ctx *wl.Context) *PointerConstraints {
4063
4164 // Used by the client to notify the server that it will no longer use this pointer constraints object.
4265 func (o *PointerConstraints) Destroy() error {
43- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_pointer_constraints_v1.destroy", Destructor: true}); err != nil {
66+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_pointer_constraints_v1.destroy", Destructor: true}); err != nil {
4467 return err
4568 }
4669 return nil
@@ -62,7 +85,7 @@ func (o *PointerConstraints) LockPointer(surface *cross_wl_surface.Surface, poin
6285 }
6386 child := &LockedPointer{}
6487 child.SetContext(o.Context())
65- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 1, Name: "zwp_pointer_constraints_v1.lock_pointer", Child: child}, child, arg1, arg2, arg3, lifetime); err != nil {
88+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 1, Name: "zwp_pointer_constraints_v1.lock_pointer", Child: child}, wl.ArgObject(child), wl.ArgObject(arg1), wl.ArgObject(arg2), wl.ArgObject(arg3), wl.ArgUint(lifetime)); err != nil {
6689 return nil, err
6790 }
6891 return child, nil
@@ -84,7 +107,7 @@ func (o *PointerConstraints) ConfinePointer(surface *cross_wl_surface.Surface, p
84107 }
85108 child := &ConfinedPointer{}
86109 child.SetContext(o.Context())
87- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 2, Name: "zwp_pointer_constraints_v1.confine_pointer", Child: child}, child, arg1, arg2, arg3, lifetime); err != nil {
110+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 2, Name: "zwp_pointer_constraints_v1.confine_pointer", Child: child}, wl.ArgObject(child), wl.ArgObject(arg1), wl.ArgObject(arg2), wl.ArgObject(arg3), wl.ArgUint(lifetime)); err != nil {
88111 return nil, err
89112 }
90113 return child, nil
@@ -128,7 +151,7 @@ func NewLockedPointer(ctx *wl.Context) *LockedPointer {
128151
129152 // Destroy the locked pointer object. If applicable, the compositor will unlock the pointer.
130153 func (o *LockedPointer) Destroy() error {
131- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_locked_pointer_v1.destroy", Destructor: true}); err != nil {
154+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_locked_pointer_v1.destroy", Destructor: true}); err != nil {
132155 return err
133156 }
134157 return nil
@@ -136,7 +159,7 @@ func (o *LockedPointer) Destroy() error {
136159
137160 // Set the cursor position hint relative to the top left corner of the surface. If the client is drawing its own cursor, it should update the position hint to the position of its own cursor. A compositor may use this information to warp the pointer upon unlock in order to avoid pointer jumps. The cursor position hint is double-buffered state, see wl_surface.commit.
138161 func (o *LockedPointer) SetCursorPositionHint(surfaceX wl.Fixed, surfaceY wl.Fixed) error {
139- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 1, Name: "zwp_locked_pointer_v1.set_cursor_position_hint"}, surfaceX, surfaceY); err != nil {
162+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 1, Name: "zwp_locked_pointer_v1.set_cursor_position_hint"}, wl.ArgFixed(surfaceX), wl.ArgFixed(surfaceY)); err != nil {
140163 return err
141164 }
142165 return nil
@@ -148,7 +171,7 @@ func (o *LockedPointer) SetRegion(region *cross_wl_region.Region) error {
148171 if region != nil {
149172 arg0 = region
150173 }
151- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 2, Name: "zwp_locked_pointer_v1.set_region"}, arg0); err != nil {
174+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 2, Name: "zwp_locked_pointer_v1.set_region"}, wl.ArgObject(arg0)); err != nil {
152175 return err
153176 }
154177 return nil
@@ -252,7 +275,7 @@ func NewConfinedPointer(ctx *wl.Context) *ConfinedPointer {
252275
253276 // Destroy the confined pointer object. If applicable, the compositor will unconfine the pointer.
254277 func (o *ConfinedPointer) Destroy() error {
255- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_confined_pointer_v1.destroy", Destructor: true}); err != nil {
278+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_confined_pointer_v1.destroy", Destructor: true}); err != nil {
256279 return err
257280 }
258281 return nil
@@ -264,7 +287,7 @@ func (o *ConfinedPointer) SetRegion(region *cross_wl_region.Region) error {
264287 if region != nil {
265288 arg0 = region
266289 }
267- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 1, Name: "zwp_confined_pointer_v1.set_region"}, arg0); err != nil {
290+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 1, Name: "zwp_confined_pointer_v1.set_region"}, wl.ArgObject(arg0)); err != nil {
268291 return err
269292 }
270293 return nil
@@ -1,16 +1,39 @@
1-// Code generated by wlturbo-scanner. DO NOT EDIT.1+// Code generated by wlbgen. DO NOT EDIT.
2 // Protocol: pointer_constraints_unstable_v12 // Protocol: pointer_constraints_unstable_v1
3 // Source: pointer-constraints-unstable-v1.xml3 // Source: pointer-constraints-unstable-v1.xml
4 4
5+// Upstream protocol copyright and license:
6+// Copyright © 2014 Jonas Ådahl
7+// Copyright © 2015 Red Hat Inc.
8+//
9+// Permission is hereby granted, free of charge, to any person obtaining a
10+// copy of this software and associated documentation files (the "Software"),
11+// to deal in the Software without restriction, including without limitation
12+// the rights to use, copy, modify, merge, publish, distribute, sublicense,
13+// and/or sell copies of the Software, and to permit persons to whom the
14+// Software is furnished to do so, subject to the following conditions:
15+//
16+// The above copyright notice and this permission notice (including the next
17+// paragraph) shall be included in all copies or substantial portions of the
18+// Software.
19+//
20+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
21+// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
22+// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
23+// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
24+// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
25+// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
26+// DEALINGS IN THE SOFTWARE.
27+
5 package protocols28 package protocols
6 29
7 import (30 import (
8 "sync"31 "sync"
9 32
10- cross_wl_pointer "github.com/bnema/wlturbo/protocol/core"33+ cross_wl_pointer "bnema.dev/go-wayland-bindings/client/wayland"
11- cross_wl_region "github.com/bnema/wlturbo/protocol/core"34+ cross_wl_region "bnema.dev/go-wayland-bindings/client/wayland"
12- cross_wl_surface "github.com/bnema/wlturbo/protocol/core"35+ cross_wl_surface "bnema.dev/go-wayland-bindings/client/wayland"
13- "github.com/bnema/wlturbo/wl"36+ "bnema.dev/wlturbo/wl"
14 )37 )
15 38
16 // ERROR_ALREADY_CONSTRAINED is the error already_constrained value.39 // ERROR_ALREADY_CONSTRAINED is the error already_constrained value.
@@ -40,7 +63,7 @@ func NewPointerConstraints(ctx *wl.Context) *PointerConstraints {
40 63
41 // Used by the client to notify the server that it will no longer use this pointer constraints object.64 // Used by the client to notify the server that it will no longer use this pointer constraints object.
42 func (o *PointerConstraints) Destroy() error {65 func (o *PointerConstraints) Destroy() error {
43- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_pointer_constraints_v1.destroy", Destructor: true}); err != nil {66+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_pointer_constraints_v1.destroy", Destructor: true}); err != nil {
44 return err67 return err
45 }68 }
46 return nil69 return nil
@@ -62,7 +85,7 @@ func (o *PointerConstraints) LockPointer(surface *cross_wl_surface.Surface, poin
62 }85 }
63 child := &LockedPointer{}86 child := &LockedPointer{}
64 child.SetContext(o.Context())87 child.SetContext(o.Context())
65- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 1, Name: "zwp_pointer_constraints_v1.lock_pointer", Child: child}, child, arg1, arg2, arg3, lifetime); err != nil {88+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 1, Name: "zwp_pointer_constraints_v1.lock_pointer", Child: child}, wl.ArgObject(child), wl.ArgObject(arg1), wl.ArgObject(arg2), wl.ArgObject(arg3), wl.ArgUint(lifetime)); err != nil {
66 return nil, err89 return nil, err
67 }90 }
68 return child, nil91 return child, nil
@@ -84,7 +107,7 @@ func (o *PointerConstraints) ConfinePointer(surface *cross_wl_surface.Surface, p
84 }107 }
85 child := &ConfinedPointer{}108 child := &ConfinedPointer{}
86 child.SetContext(o.Context())109 child.SetContext(o.Context())
87- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 2, Name: "zwp_pointer_constraints_v1.confine_pointer", Child: child}, child, arg1, arg2, arg3, lifetime); err != nil {110+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 2, Name: "zwp_pointer_constraints_v1.confine_pointer", Child: child}, wl.ArgObject(child), wl.ArgObject(arg1), wl.ArgObject(arg2), wl.ArgObject(arg3), wl.ArgUint(lifetime)); err != nil {
88 return nil, err111 return nil, err
89 }112 }
90 return child, nil113 return child, nil
@@ -128,7 +151,7 @@ func NewLockedPointer(ctx *wl.Context) *LockedPointer {
128 151
129 // Destroy the locked pointer object. If applicable, the compositor will unlock the pointer.152 // Destroy the locked pointer object. If applicable, the compositor will unlock the pointer.
130 func (o *LockedPointer) Destroy() error {153 func (o *LockedPointer) Destroy() error {
131- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_locked_pointer_v1.destroy", Destructor: true}); err != nil {154+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_locked_pointer_v1.destroy", Destructor: true}); err != nil {
132 return err155 return err
133 }156 }
134 return nil157 return nil
@@ -136,7 +159,7 @@ func (o *LockedPointer) Destroy() error {
136 159
137 // Set the cursor position hint relative to the top left corner of the surface. If the client is drawing its own cursor, it should update the position hint to the position of its own cursor. A compositor may use this information to warp the pointer upon unlock in order to avoid pointer jumps. The cursor position hint is double-buffered state, see wl_surface.commit.160 // Set the cursor position hint relative to the top left corner of the surface. If the client is drawing its own cursor, it should update the position hint to the position of its own cursor. A compositor may use this information to warp the pointer upon unlock in order to avoid pointer jumps. The cursor position hint is double-buffered state, see wl_surface.commit.
138 func (o *LockedPointer) SetCursorPositionHint(surfaceX wl.Fixed, surfaceY wl.Fixed) error {161 func (o *LockedPointer) SetCursorPositionHint(surfaceX wl.Fixed, surfaceY wl.Fixed) error {
139- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 1, Name: "zwp_locked_pointer_v1.set_cursor_position_hint"}, surfaceX, surfaceY); err != nil {162+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 1, Name: "zwp_locked_pointer_v1.set_cursor_position_hint"}, wl.ArgFixed(surfaceX), wl.ArgFixed(surfaceY)); err != nil {
140 return err163 return err
141 }164 }
142 return nil165 return nil
@@ -148,7 +171,7 @@ func (o *LockedPointer) SetRegion(region *cross_wl_region.Region) error {
148 if region != nil {171 if region != nil {
149 arg0 = region172 arg0 = region
150 }173 }
151- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 2, Name: "zwp_locked_pointer_v1.set_region"}, arg0); err != nil {174+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 2, Name: "zwp_locked_pointer_v1.set_region"}, wl.ArgObject(arg0)); err != nil {
152 return err175 return err
153 }176 }
154 return nil177 return nil
@@ -252,7 +275,7 @@ func NewConfinedPointer(ctx *wl.Context) *ConfinedPointer {
252 275
253 // Destroy the confined pointer object. If applicable, the compositor will unconfine the pointer.276 // Destroy the confined pointer object. If applicable, the compositor will unconfine the pointer.
254 func (o *ConfinedPointer) Destroy() error {277 func (o *ConfinedPointer) Destroy() error {
255- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_confined_pointer_v1.destroy", Destructor: true}); err != nil {278+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_confined_pointer_v1.destroy", Destructor: true}); err != nil {
256 return err279 return err
257 }280 }
258 return nil281 return nil
@@ -264,7 +287,7 @@ func (o *ConfinedPointer) SetRegion(region *cross_wl_region.Region) error {
264 if region != nil {287 if region != nil {
265 arg0 = region288 arg0 = region
266 }289 }
267- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 1, Name: "zwp_confined_pointer_v1.set_region"}, arg0); err != nil {290+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 1, Name: "zwp_confined_pointer_v1.set_region"}, wl.ArgObject(arg0)); err != nil {
268 return err291 return err
269 }292 }
270 return nil293 return nil
M internal/protocols/virtual_keyboard_generated.go +33 -8
@@ -1,12 +1,37 @@
1-// Code generated by wlturbo-scanner. DO NOT EDIT.
1+// Code generated by wlbgen. DO NOT EDIT.
22 // Protocol: virtual_keyboard_unstable_v1
33 // Source: virtual-keyboard-unstable-v1.xml
44
5+// Upstream protocol copyright and license:
6+// Copyright © 2008-2011 Kristian Høgsberg
7+// Copyright © 2010-2013 Intel Corporation
8+// Copyright © 2012-2013 Collabora, Ltd.
9+// Copyright © 2018 Purism SPC
10+//
11+// Permission is hereby granted, free of charge, to any person obtaining a
12+// copy of this software and associated documentation files (the "Software"),
13+// to deal in the Software without restriction, including without limitation
14+// the rights to use, copy, modify, merge, publish, distribute, sublicense,
15+// and/or sell copies of the Software, and to permit persons to whom the
16+// Software is furnished to do so, subject to the following conditions:
17+//
18+// The above copyright notice and this permission notice (including the next
19+// paragraph) shall be included in all copies or substantial portions of the
20+// Software.
21+//
22+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
23+// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
24+// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
25+// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
26+// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
27+// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
28+// DEALINGS IN THE SOFTWARE.
29+
530 package protocols
631
732 import (
8- cross_wl_seat "github.com/bnema/wlturbo/protocol/core"
9- "github.com/bnema/wlturbo/wl"
33+ cross_wl_seat "bnema.dev/go-wayland-bindings/client/wayland"
34+ "bnema.dev/wlturbo/wl"
1035 )
1136
1237 // ERROR_NO_KEYMAP is the error no_keymap value.
@@ -33,7 +58,7 @@ func NewVirtualKeyboard(ctx *wl.Context) *VirtualKeyboard {
3358
3459 // Provide a file descriptor to the compositor which can be memory-mapped to provide a keyboard mapping description. Format carries a value from the keymap_format enumeration.
3560 func (o *VirtualKeyboard) Keymap(format uint32, fd int, size uint32) error {
36- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_virtual_keyboard_v1.keymap", FDs: []int{fd}}, format, uintptr(fd), size); err != nil {
61+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_virtual_keyboard_v1.keymap", FDs: []int{fd}}, wl.ArgUint(format), wl.ArgFD(), wl.ArgUint(size)); err != nil {
3762 return err
3863 }
3964 return nil
@@ -41,7 +66,7 @@ func (o *VirtualKeyboard) Keymap(format uint32, fd int, size uint32) error {
4166
4267 // A key was pressed or released. The time argument is a timestamp with millisecond granularity, with an undefined base. All requests regarding a single object must share the same clock. Keymap must be set before issuing this request. State carries a value from the key_state enumeration.
4368 func (o *VirtualKeyboard) Key(time uint32, key uint32, state uint32) error {
44- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 1, Name: "zwp_virtual_keyboard_v1.key"}, time, key, state); err != nil {
69+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 1, Name: "zwp_virtual_keyboard_v1.key"}, wl.ArgUint(time), wl.ArgUint(key), wl.ArgUint(state)); err != nil {
4570 return err
4671 }
4772 return nil
@@ -49,7 +74,7 @@ func (o *VirtualKeyboard) Key(time uint32, key uint32, state uint32) error {
4974
5075 // Notifies the compositor that the modifier and/or group state has changed, and it should update state. The client should use wl_keyboard.modifiers event to synchronize its internal state with seat state. Keymap must be set before issuing this request.
5176 func (o *VirtualKeyboard) Modifiers(modsDepressed uint32, modsLatched uint32, modsLocked uint32, group uint32) error {
52- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 2, Name: "zwp_virtual_keyboard_v1.modifiers"}, modsDepressed, modsLatched, modsLocked, group); err != nil {
77+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 2, Name: "zwp_virtual_keyboard_v1.modifiers"}, wl.ArgUint(modsDepressed), wl.ArgUint(modsLatched), wl.ArgUint(modsLocked), wl.ArgUint(group)); err != nil {
5378 return err
5479 }
5580 return nil
@@ -57,7 +82,7 @@ func (o *VirtualKeyboard) Modifiers(modsDepressed uint32, modsLatched uint32, mo
5782
5883 // destroy the virtual keyboard keyboard object
5984 func (o *VirtualKeyboard) Destroy() error {
60- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 3, Name: "zwp_virtual_keyboard_v1.destroy", Destructor: true}); err != nil {
85+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 3, Name: "zwp_virtual_keyboard_v1.destroy", Destructor: true}); err != nil {
6186 return err
6287 }
6388 return nil
@@ -102,7 +127,7 @@ func (o *VirtualKeyboardManager) CreateVirtualKeyboard(seat *cross_wl_seat.Seat)
102127 }
103128 child := &VirtualKeyboard{}
104129 child.SetContext(o.Context())
105- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_virtual_keyboard_manager_v1.create_virtual_keyboard", Child: child}, arg0, child); err != nil {
130+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_virtual_keyboard_manager_v1.create_virtual_keyboard", Child: child}, wl.ArgObject(arg0), wl.ArgObject(child)); err != nil {
106131 return nil, err
107132 }
108133 return child, nil
@@ -1,12 +1,37 @@
1-// Code generated by wlturbo-scanner. DO NOT EDIT.1+// Code generated by wlbgen. DO NOT EDIT.
2 // Protocol: virtual_keyboard_unstable_v12 // Protocol: virtual_keyboard_unstable_v1
3 // Source: virtual-keyboard-unstable-v1.xml3 // Source: virtual-keyboard-unstable-v1.xml
4 4
5+// Upstream protocol copyright and license:
6+// Copyright © 2008-2011 Kristian Høgsberg
7+// Copyright © 2010-2013 Intel Corporation
8+// Copyright © 2012-2013 Collabora, Ltd.
9+// Copyright © 2018 Purism SPC
10+//
11+// Permission is hereby granted, free of charge, to any person obtaining a
12+// copy of this software and associated documentation files (the "Software"),
13+// to deal in the Software without restriction, including without limitation
14+// the rights to use, copy, modify, merge, publish, distribute, sublicense,
15+// and/or sell copies of the Software, and to permit persons to whom the
16+// Software is furnished to do so, subject to the following conditions:
17+//
18+// The above copyright notice and this permission notice (including the next
19+// paragraph) shall be included in all copies or substantial portions of the
20+// Software.
21+//
22+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
23+// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
24+// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
25+// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
26+// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
27+// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
28+// DEALINGS IN THE SOFTWARE.
29+
5 package protocols30 package protocols
6 31
7 import (32 import (
8- cross_wl_seat "github.com/bnema/wlturbo/protocol/core"33+ cross_wl_seat "bnema.dev/go-wayland-bindings/client/wayland"
9- "github.com/bnema/wlturbo/wl"34+ "bnema.dev/wlturbo/wl"
10 )35 )
11 36
12 // ERROR_NO_KEYMAP is the error no_keymap value.37 // ERROR_NO_KEYMAP is the error no_keymap value.
@@ -33,7 +58,7 @@ func NewVirtualKeyboard(ctx *wl.Context) *VirtualKeyboard {
33 58
34 // Provide a file descriptor to the compositor which can be memory-mapped to provide a keyboard mapping description. Format carries a value from the keymap_format enumeration.59 // Provide a file descriptor to the compositor which can be memory-mapped to provide a keyboard mapping description. Format carries a value from the keymap_format enumeration.
35 func (o *VirtualKeyboard) Keymap(format uint32, fd int, size uint32) error {60 func (o *VirtualKeyboard) Keymap(format uint32, fd int, size uint32) error {
36- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_virtual_keyboard_v1.keymap", FDs: []int{fd}}, format, uintptr(fd), size); err != nil {61+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_virtual_keyboard_v1.keymap", FDs: []int{fd}}, wl.ArgUint(format), wl.ArgFD(), wl.ArgUint(size)); err != nil {
37 return err62 return err
38 }63 }
39 return nil64 return nil
@@ -41,7 +66,7 @@ func (o *VirtualKeyboard) Keymap(format uint32, fd int, size uint32) error {
41 66
42 // A key was pressed or released. The time argument is a timestamp with millisecond granularity, with an undefined base. All requests regarding a single object must share the same clock. Keymap must be set before issuing this request. State carries a value from the key_state enumeration.67 // A key was pressed or released. The time argument is a timestamp with millisecond granularity, with an undefined base. All requests regarding a single object must share the same clock. Keymap must be set before issuing this request. State carries a value from the key_state enumeration.
43 func (o *VirtualKeyboard) Key(time uint32, key uint32, state uint32) error {68 func (o *VirtualKeyboard) Key(time uint32, key uint32, state uint32) error {
44- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 1, Name: "zwp_virtual_keyboard_v1.key"}, time, key, state); err != nil {69+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 1, Name: "zwp_virtual_keyboard_v1.key"}, wl.ArgUint(time), wl.ArgUint(key), wl.ArgUint(state)); err != nil {
45 return err70 return err
46 }71 }
47 return nil72 return nil
@@ -49,7 +74,7 @@ func (o *VirtualKeyboard) Key(time uint32, key uint32, state uint32) error {
49 74
50 // Notifies the compositor that the modifier and/or group state has changed, and it should update state. The client should use wl_keyboard.modifiers event to synchronize its internal state with seat state. Keymap must be set before issuing this request.75 // Notifies the compositor that the modifier and/or group state has changed, and it should update state. The client should use wl_keyboard.modifiers event to synchronize its internal state with seat state. Keymap must be set before issuing this request.
51 func (o *VirtualKeyboard) Modifiers(modsDepressed uint32, modsLatched uint32, modsLocked uint32, group uint32) error {76 func (o *VirtualKeyboard) Modifiers(modsDepressed uint32, modsLatched uint32, modsLocked uint32, group uint32) error {
52- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 2, Name: "zwp_virtual_keyboard_v1.modifiers"}, modsDepressed, modsLatched, modsLocked, group); err != nil {77+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 2, Name: "zwp_virtual_keyboard_v1.modifiers"}, wl.ArgUint(modsDepressed), wl.ArgUint(modsLatched), wl.ArgUint(modsLocked), wl.ArgUint(group)); err != nil {
53 return err78 return err
54 }79 }
55 return nil80 return nil
@@ -57,7 +82,7 @@ func (o *VirtualKeyboard) Modifiers(modsDepressed uint32, modsLatched uint32, mo
57 82
58 // destroy the virtual keyboard keyboard object83 // destroy the virtual keyboard keyboard object
59 func (o *VirtualKeyboard) Destroy() error {84 func (o *VirtualKeyboard) Destroy() error {
60- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 3, Name: "zwp_virtual_keyboard_v1.destroy", Destructor: true}); err != nil {85+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 3, Name: "zwp_virtual_keyboard_v1.destroy", Destructor: true}); err != nil {
61 return err86 return err
62 }87 }
63 return nil88 return nil
@@ -102,7 +127,7 @@ func (o *VirtualKeyboardManager) CreateVirtualKeyboard(seat *cross_wl_seat.Seat)
102 }127 }
103 child := &VirtualKeyboard{}128 child := &VirtualKeyboard{}
104 child.SetContext(o.Context())129 child.SetContext(o.Context())
105- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_virtual_keyboard_manager_v1.create_virtual_keyboard", Child: child}, arg0, child); err != nil {130+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwp_virtual_keyboard_manager_v1.create_virtual_keyboard", Child: child}, wl.ArgObject(arg0), wl.ArgObject(child)); err != nil {
106 return nil, err131 return nil, err
107 }132 }
108 return child, nil133 return child, nil
M internal/protocols/virtual_pointer_generated.go +38 -16
@@ -1,13 +1,35 @@
1-// Code generated by wlturbo-scanner. DO NOT EDIT.
1+// Code generated by wlbgen. DO NOT EDIT.
22 // Protocol: wlr_virtual_pointer_unstable_v1
33 // Source: wlr-virtual-pointer-unstable-v1.xml
44
5+// Upstream protocol copyright and license:
6+// Copyright © 2019 Josef Gajdusek
7+//
8+// Permission is hereby granted, free of charge, to any person obtaining a
9+// copy of this software and associated documentation files (the "Software"),
10+// to deal in the Software without restriction, including without limitation
11+// the rights to use, copy, modify, merge, publish, distribute, sublicense,
12+// and/or sell copies of the Software, and to permit persons to whom the
13+// Software is furnished to do so, subject to the following conditions:
14+//
15+// The above copyright notice and this permission notice (including the next
16+// paragraph) shall be included in all copies or substantial portions of the
17+// Software.
18+//
19+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
20+// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
21+// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
22+// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
23+// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
24+// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
25+// DEALINGS IN THE SOFTWARE.
26+
527 package protocols
628
729 import (
8- cross_wl_output "github.com/bnema/wlturbo/protocol/core"
9- cross_wl_seat "github.com/bnema/wlturbo/protocol/core"
10- "github.com/bnema/wlturbo/wl"
30+ cross_wl_output "bnema.dev/go-wayland-bindings/client/wayland"
31+ cross_wl_seat "bnema.dev/go-wayland-bindings/client/wayland"
32+ "bnema.dev/wlturbo/wl"
1133 )
1234
1335 // ERROR_INVALID_AXIS is the error invalid_axis value.
@@ -34,7 +56,7 @@ func NewVirtualPointer(ctx *wl.Context) *VirtualPointer {
3456
3557 // The pointer has moved by a relative amount to the previous request. Values are in the global compositor space.
3658 func (o *VirtualPointer) Motion(time uint32, dx wl.Fixed, dy wl.Fixed) error {
37- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_virtual_pointer_v1.motion"}, time, dx, dy); err != nil {
59+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_virtual_pointer_v1.motion"}, wl.ArgUint(time), wl.ArgFixed(dx), wl.ArgFixed(dy)); err != nil {
3860 return err
3961 }
4062 return nil
@@ -42,7 +64,7 @@ func (o *VirtualPointer) Motion(time uint32, dx wl.Fixed, dy wl.Fixed) error {
4264
4365 // The pointer has moved in an absolute coordinate frame. Value of x can range from 0 to x_extent, value of y can range from 0 to y_extent.
4466 func (o *VirtualPointer) MotionAbsolute(time uint32, x uint32, y uint32, xExtent uint32, yExtent uint32) error {
45- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 1, Name: "zwlr_virtual_pointer_v1.motion_absolute"}, time, x, y, xExtent, yExtent); err != nil {
67+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 1, Name: "zwlr_virtual_pointer_v1.motion_absolute"}, wl.ArgUint(time), wl.ArgUint(x), wl.ArgUint(y), wl.ArgUint(xExtent), wl.ArgUint(yExtent)); err != nil {
4668 return err
4769 }
4870 return nil
@@ -50,7 +72,7 @@ func (o *VirtualPointer) MotionAbsolute(time uint32, x uint32, y uint32, xExtent
5072
5173 // A button was pressed or released.
5274 func (o *VirtualPointer) Button(time uint32, button uint32, state uint32) error {
53- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 2, Name: "zwlr_virtual_pointer_v1.button"}, time, button, state); err != nil {
75+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 2, Name: "zwlr_virtual_pointer_v1.button"}, wl.ArgUint(time), wl.ArgUint(button), wl.ArgUint(state)); err != nil {
5476 return err
5577 }
5678 return nil
@@ -58,7 +80,7 @@ func (o *VirtualPointer) Button(time uint32, button uint32, state uint32) error
5880
5981 // Scroll and other axis requests.
6082 func (o *VirtualPointer) Axis(time uint32, axis uint32, value wl.Fixed) error {
61- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 3, Name: "zwlr_virtual_pointer_v1.axis"}, time, axis, value); err != nil {
83+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 3, Name: "zwlr_virtual_pointer_v1.axis"}, wl.ArgUint(time), wl.ArgUint(axis), wl.ArgFixed(value)); err != nil {
6284 return err
6385 }
6486 return nil
@@ -66,7 +88,7 @@ func (o *VirtualPointer) Axis(time uint32, axis uint32, value wl.Fixed) error {
6688
6789 // Indicates the set of events that logically belong together.
6890 func (o *VirtualPointer) Frame() error {
69- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 4, Name: "zwlr_virtual_pointer_v1.frame"}); err != nil {
91+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 4, Name: "zwlr_virtual_pointer_v1.frame"}); err != nil {
7092 return err
7193 }
7294 return nil
@@ -74,7 +96,7 @@ func (o *VirtualPointer) Frame() error {
7496
7597 // Source information for scroll and other axis.
7698 func (o *VirtualPointer) AxisSource(axisSource uint32) error {
77- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 5, Name: "zwlr_virtual_pointer_v1.axis_source"}, axisSource); err != nil {
99+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 5, Name: "zwlr_virtual_pointer_v1.axis_source"}, wl.ArgUint(axisSource)); err != nil {
78100 return err
79101 }
80102 return nil
@@ -82,7 +104,7 @@ func (o *VirtualPointer) AxisSource(axisSource uint32) error {
82104
83105 // Stop notification for scroll and other axes.
84106 func (o *VirtualPointer) AxisStop(time uint32, axis uint32) error {
85- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 6, Name: "zwlr_virtual_pointer_v1.axis_stop"}, time, axis); err != nil {
107+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 6, Name: "zwlr_virtual_pointer_v1.axis_stop"}, wl.ArgUint(time), wl.ArgUint(axis)); err != nil {
86108 return err
87109 }
88110 return nil
@@ -90,7 +112,7 @@ func (o *VirtualPointer) AxisStop(time uint32, axis uint32) error {
90112
91113 // Discrete step information for scroll and other axes. This event allows the client to extend data normally sent using the axis event with discrete value.
92114 func (o *VirtualPointer) AxisDiscrete(time uint32, axis uint32, value wl.Fixed, discrete int32) error {
93- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 7, Name: "zwlr_virtual_pointer_v1.axis_discrete"}, time, axis, value, discrete); err != nil {
115+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 7, Name: "zwlr_virtual_pointer_v1.axis_discrete"}, wl.ArgUint(time), wl.ArgUint(axis), wl.ArgFixed(value), wl.ArgInt(discrete)); err != nil {
94116 return err
95117 }
96118 return nil
@@ -98,7 +120,7 @@ func (o *VirtualPointer) AxisDiscrete(time uint32, axis uint32, value wl.Fixed,
98120
99121 // destroy the virtual pointer object
100122 func (o *VirtualPointer) Destroy() error {
101- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 8, Name: "zwlr_virtual_pointer_v1.destroy", Destructor: true}); err != nil {
123+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 8, Name: "zwlr_virtual_pointer_v1.destroy", Destructor: true}); err != nil {
102124 return err
103125 }
104126 return nil
@@ -143,7 +165,7 @@ func (o *VirtualPointerManager) CreateVirtualPointer(seat *cross_wl_seat.Seat) (
143165 }
144166 child := &VirtualPointer{}
145167 child.SetContext(o.Context())
146- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_virtual_pointer_manager_v1.create_virtual_pointer", Child: child}, arg0, child); err != nil {
168+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_virtual_pointer_manager_v1.create_virtual_pointer", Child: child}, wl.ArgObject(arg0), wl.ArgObject(child)); err != nil {
147169 return nil, err
148170 }
149171 return child, nil
@@ -151,7 +173,7 @@ func (o *VirtualPointerManager) CreateVirtualPointer(seat *cross_wl_seat.Seat) (
151173
152174 // destroy the virtual pointer manager
153175 func (o *VirtualPointerManager) Destroy() error {
154- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 1, Name: "zwlr_virtual_pointer_manager_v1.destroy", Destructor: true}); err != nil {
176+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 1, Name: "zwlr_virtual_pointer_manager_v1.destroy", Destructor: true}); err != nil {
155177 return err
156178 }
157179 return nil
@@ -169,7 +191,7 @@ func (o *VirtualPointerManager) CreateVirtualPointerWithOutput(seat *cross_wl_se
169191 }
170192 child := &VirtualPointer{}
171193 child.SetContext(o.Context())
172- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 2, Name: "zwlr_virtual_pointer_manager_v1.create_virtual_pointer_with_output", Since: 2, Child: child}, arg0, arg1, child); err != nil {
194+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 2, Name: "zwlr_virtual_pointer_manager_v1.create_virtual_pointer_with_output", Since: 2, Child: child}, wl.ArgObject(arg0), wl.ArgObject(arg1), wl.ArgObject(child)); err != nil {
173195 return nil, err
174196 }
175197 return child, nil
@@ -1,13 +1,35 @@
1-// Code generated by wlturbo-scanner. DO NOT EDIT.1+// Code generated by wlbgen. DO NOT EDIT.
2 // Protocol: wlr_virtual_pointer_unstable_v12 // Protocol: wlr_virtual_pointer_unstable_v1
3 // Source: wlr-virtual-pointer-unstable-v1.xml3 // Source: wlr-virtual-pointer-unstable-v1.xml
4 4
5+// Upstream protocol copyright and license:
6+// Copyright © 2019 Josef Gajdusek
7+//
8+// Permission is hereby granted, free of charge, to any person obtaining a
9+// copy of this software and associated documentation files (the "Software"),
10+// to deal in the Software without restriction, including without limitation
11+// the rights to use, copy, modify, merge, publish, distribute, sublicense,
12+// and/or sell copies of the Software, and to permit persons to whom the
13+// Software is furnished to do so, subject to the following conditions:
14+//
15+// The above copyright notice and this permission notice (including the next
16+// paragraph) shall be included in all copies or substantial portions of the
17+// Software.
18+//
19+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
20+// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
21+// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
22+// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
23+// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
24+// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
25+// DEALINGS IN THE SOFTWARE.
26+
5 package protocols27 package protocols
6 28
7 import (29 import (
8- cross_wl_output "github.com/bnema/wlturbo/protocol/core"30+ cross_wl_output "bnema.dev/go-wayland-bindings/client/wayland"
9- cross_wl_seat "github.com/bnema/wlturbo/protocol/core"31+ cross_wl_seat "bnema.dev/go-wayland-bindings/client/wayland"
10- "github.com/bnema/wlturbo/wl"32+ "bnema.dev/wlturbo/wl"
11 )33 )
12 34
13 // ERROR_INVALID_AXIS is the error invalid_axis value.35 // ERROR_INVALID_AXIS is the error invalid_axis value.
@@ -34,7 +56,7 @@ func NewVirtualPointer(ctx *wl.Context) *VirtualPointer {
34 56
35 // The pointer has moved by a relative amount to the previous request. Values are in the global compositor space.57 // The pointer has moved by a relative amount to the previous request. Values are in the global compositor space.
36 func (o *VirtualPointer) Motion(time uint32, dx wl.Fixed, dy wl.Fixed) error {58 func (o *VirtualPointer) Motion(time uint32, dx wl.Fixed, dy wl.Fixed) error {
37- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_virtual_pointer_v1.motion"}, time, dx, dy); err != nil {59+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_virtual_pointer_v1.motion"}, wl.ArgUint(time), wl.ArgFixed(dx), wl.ArgFixed(dy)); err != nil {
38 return err60 return err
39 }61 }
40 return nil62 return nil
@@ -42,7 +64,7 @@ func (o *VirtualPointer) Motion(time uint32, dx wl.Fixed, dy wl.Fixed) error {
42 64
43 // The pointer has moved in an absolute coordinate frame. Value of x can range from 0 to x_extent, value of y can range from 0 to y_extent.65 // The pointer has moved in an absolute coordinate frame. Value of x can range from 0 to x_extent, value of y can range from 0 to y_extent.
44 func (o *VirtualPointer) MotionAbsolute(time uint32, x uint32, y uint32, xExtent uint32, yExtent uint32) error {66 func (o *VirtualPointer) MotionAbsolute(time uint32, x uint32, y uint32, xExtent uint32, yExtent uint32) error {
45- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 1, Name: "zwlr_virtual_pointer_v1.motion_absolute"}, time, x, y, xExtent, yExtent); err != nil {67+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 1, Name: "zwlr_virtual_pointer_v1.motion_absolute"}, wl.ArgUint(time), wl.ArgUint(x), wl.ArgUint(y), wl.ArgUint(xExtent), wl.ArgUint(yExtent)); err != nil {
46 return err68 return err
47 }69 }
48 return nil70 return nil
@@ -50,7 +72,7 @@ func (o *VirtualPointer) MotionAbsolute(time uint32, x uint32, y uint32, xExtent
50 72
51 // A button was pressed or released.73 // A button was pressed or released.
52 func (o *VirtualPointer) Button(time uint32, button uint32, state uint32) error {74 func (o *VirtualPointer) Button(time uint32, button uint32, state uint32) error {
53- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 2, Name: "zwlr_virtual_pointer_v1.button"}, time, button, state); err != nil {75+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 2, Name: "zwlr_virtual_pointer_v1.button"}, wl.ArgUint(time), wl.ArgUint(button), wl.ArgUint(state)); err != nil {
54 return err76 return err
55 }77 }
56 return nil78 return nil
@@ -58,7 +80,7 @@ func (o *VirtualPointer) Button(time uint32, button uint32, state uint32) error
58 80
59 // Scroll and other axis requests.81 // Scroll and other axis requests.
60 func (o *VirtualPointer) Axis(time uint32, axis uint32, value wl.Fixed) error {82 func (o *VirtualPointer) Axis(time uint32, axis uint32, value wl.Fixed) error {
61- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 3, Name: "zwlr_virtual_pointer_v1.axis"}, time, axis, value); err != nil {83+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 3, Name: "zwlr_virtual_pointer_v1.axis"}, wl.ArgUint(time), wl.ArgUint(axis), wl.ArgFixed(value)); err != nil {
62 return err84 return err
63 }85 }
64 return nil86 return nil
@@ -66,7 +88,7 @@ func (o *VirtualPointer) Axis(time uint32, axis uint32, value wl.Fixed) error {
66 88
67 // Indicates the set of events that logically belong together.89 // Indicates the set of events that logically belong together.
68 func (o *VirtualPointer) Frame() error {90 func (o *VirtualPointer) Frame() error {
69- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 4, Name: "zwlr_virtual_pointer_v1.frame"}); err != nil {91+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 4, Name: "zwlr_virtual_pointer_v1.frame"}); err != nil {
70 return err92 return err
71 }93 }
72 return nil94 return nil
@@ -74,7 +96,7 @@ func (o *VirtualPointer) Frame() error {
74 96
75 // Source information for scroll and other axis.97 // Source information for scroll and other axis.
76 func (o *VirtualPointer) AxisSource(axisSource uint32) error {98 func (o *VirtualPointer) AxisSource(axisSource uint32) error {
77- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 5, Name: "zwlr_virtual_pointer_v1.axis_source"}, axisSource); err != nil {99+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 5, Name: "zwlr_virtual_pointer_v1.axis_source"}, wl.ArgUint(axisSource)); err != nil {
78 return err100 return err
79 }101 }
80 return nil102 return nil
@@ -82,7 +104,7 @@ func (o *VirtualPointer) AxisSource(axisSource uint32) error {
82 104
83 // Stop notification for scroll and other axes.105 // Stop notification for scroll and other axes.
84 func (o *VirtualPointer) AxisStop(time uint32, axis uint32) error {106 func (o *VirtualPointer) AxisStop(time uint32, axis uint32) error {
85- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 6, Name: "zwlr_virtual_pointer_v1.axis_stop"}, time, axis); err != nil {107+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 6, Name: "zwlr_virtual_pointer_v1.axis_stop"}, wl.ArgUint(time), wl.ArgUint(axis)); err != nil {
86 return err108 return err
87 }109 }
88 return nil110 return nil
@@ -90,7 +112,7 @@ func (o *VirtualPointer) AxisStop(time uint32, axis uint32) error {
90 112
91 // Discrete step information for scroll and other axes. This event allows the client to extend data normally sent using the axis event with discrete value.113 // Discrete step information for scroll and other axes. This event allows the client to extend data normally sent using the axis event with discrete value.
92 func (o *VirtualPointer) AxisDiscrete(time uint32, axis uint32, value wl.Fixed, discrete int32) error {114 func (o *VirtualPointer) AxisDiscrete(time uint32, axis uint32, value wl.Fixed, discrete int32) error {
93- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 7, Name: "zwlr_virtual_pointer_v1.axis_discrete"}, time, axis, value, discrete); err != nil {115+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 7, Name: "zwlr_virtual_pointer_v1.axis_discrete"}, wl.ArgUint(time), wl.ArgUint(axis), wl.ArgFixed(value), wl.ArgInt(discrete)); err != nil {
94 return err116 return err
95 }117 }
96 return nil118 return nil
@@ -98,7 +120,7 @@ func (o *VirtualPointer) AxisDiscrete(time uint32, axis uint32, value wl.Fixed,
98 120
99 // destroy the virtual pointer object121 // destroy the virtual pointer object
100 func (o *VirtualPointer) Destroy() error {122 func (o *VirtualPointer) Destroy() error {
101- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 8, Name: "zwlr_virtual_pointer_v1.destroy", Destructor: true}); err != nil {123+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 8, Name: "zwlr_virtual_pointer_v1.destroy", Destructor: true}); err != nil {
102 return err124 return err
103 }125 }
104 return nil126 return nil
@@ -143,7 +165,7 @@ func (o *VirtualPointerManager) CreateVirtualPointer(seat *cross_wl_seat.Seat) (
143 }165 }
144 child := &VirtualPointer{}166 child := &VirtualPointer{}
145 child.SetContext(o.Context())167 child.SetContext(o.Context())
146- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_virtual_pointer_manager_v1.create_virtual_pointer", Child: child}, arg0, child); err != nil {168+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 0, Name: "zwlr_virtual_pointer_manager_v1.create_virtual_pointer", Child: child}, wl.ArgObject(arg0), wl.ArgObject(child)); err != nil {
147 return nil, err169 return nil, err
148 }170 }
149 return child, nil171 return child, nil
@@ -151,7 +173,7 @@ func (o *VirtualPointerManager) CreateVirtualPointer(seat *cross_wl_seat.Seat) (
151 173
152 // destroy the virtual pointer manager174 // destroy the virtual pointer manager
153 func (o *VirtualPointerManager) Destroy() error {175 func (o *VirtualPointerManager) Destroy() error {
154- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 1, Name: "zwlr_virtual_pointer_manager_v1.destroy", Destructor: true}); err != nil {176+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 1, Name: "zwlr_virtual_pointer_manager_v1.destroy", Destructor: true}); err != nil {
155 return err177 return err
156 }178 }
157 return nil179 return nil
@@ -169,7 +191,7 @@ func (o *VirtualPointerManager) CreateVirtualPointerWithOutput(seat *cross_wl_se
169 }191 }
170 child := &VirtualPointer{}192 child := &VirtualPointer{}
171 child.SetContext(o.Context())193 child.SetContext(o.Context())
172- if err := o.Context().Request(wl.Request{Proxy: o, Opcode: 2, Name: "zwlr_virtual_pointer_manager_v1.create_virtual_pointer_with_output", Since: 2, Child: child}, arg0, arg1, child); err != nil {194+ if err := o.Context().RequestArgs(wl.Request{Proxy: o, Opcode: 2, Name: "zwlr_virtual_pointer_manager_v1.create_virtual_pointer_with_output", Since: 2, Child: child}, wl.ArgObject(arg0), wl.ArgObject(arg1), wl.ArgObject(child)); err != nil {
173 return nil, err195 return nil, err
174 }196 }
175 return child, nil197 return child, nil
M keyboard_shortcuts_inhibitor/keyboard_shortcuts_inhibitor.go +1 -1
@@ -35,9 +35,9 @@ import (
3535 "fmt"
3636 "sync"
3737
38+ core "bnema.dev/go-wayland-bindings/client/wayland"
3839 "github.com/bnema/libwldevices-go/internal/client"
3940 "github.com/bnema/libwldevices-go/internal/protocols"
40- "github.com/bnema/wlturbo/protocol/core"
4141 )
4242
4343 // Error constants for keyboard shortcuts inhibitor
@@ -35,9 +35,9 @@ import (
35 "fmt"35 "fmt"
36 "sync"36 "sync"
37 37
38+ core "bnema.dev/go-wayland-bindings/client/wayland"
38 "github.com/bnema/libwldevices-go/internal/client"39 "github.com/bnema/libwldevices-go/internal/client"
39 "github.com/bnema/libwldevices-go/internal/protocols"40 "github.com/bnema/libwldevices-go/internal/protocols"
40- "github.com/bnema/wlturbo/protocol/core"
41 )41 )
42 42
43 // Error constants for keyboard shortcuts inhibitor43 // Error constants for keyboard shortcuts inhibitor
M keyboard_shortcuts_inhibitor/keyboard_shortcuts_inhibitor_test.go +2 -2
@@ -7,10 +7,10 @@ import (
77 "testing"
88 "time"
99
10+ core "bnema.dev/go-wayland-bindings/client/wayland"
11+ "bnema.dev/wlturbo"
1012 "github.com/bnema/libwldevices-go/internal/protocols"
1113 "github.com/bnema/libwldevices-go/internal/testcompositor"
12- "github.com/bnema/wlturbo"
13- "github.com/bnema/wlturbo/protocol/core"
1414 )
1515
1616 // Globals announced by the test compositor. The manager name mirrors the value
@@ -7,10 +7,10 @@ import (
7 "testing"7 "testing"
8 "time"8 "time"
9 9
10+ core "bnema.dev/go-wayland-bindings/client/wayland"
11+ "bnema.dev/wlturbo"
10 "github.com/bnema/libwldevices-go/internal/protocols"12 "github.com/bnema/libwldevices-go/internal/protocols"
11 "github.com/bnema/libwldevices-go/internal/testcompositor"13 "github.com/bnema/libwldevices-go/internal/testcompositor"
12- "github.com/bnema/wlturbo"
13- "github.com/bnema/wlturbo/protocol/core"
14 )14 )
15 15
16 // Globals announced by the test compositor. The manager name mirrors the value16 // Globals announced by the test compositor. The manager name mirrors the value
M output_management/output_management.go +1 -1
@@ -10,9 +10,9 @@ import (
1010 "sync"
1111 "time"
1212
13+ "bnema.dev/wlturbo/wl"
1314 "github.com/bnema/libwldevices-go/internal/client"
1415 "github.com/bnema/libwldevices-go/internal/protocols"
15- "github.com/bnema/wlturbo/wl"
1616 )
1717
1818 // OutputManager manages output configuration and monitoring
@@ -10,9 +10,9 @@ import (
10 "sync"10 "sync"
11 "time"11 "time"
12 12
13+ "bnema.dev/wlturbo/wl"
13 "github.com/bnema/libwldevices-go/internal/client"14 "github.com/bnema/libwldevices-go/internal/client"
14 "github.com/bnema/libwldevices-go/internal/protocols"15 "github.com/bnema/libwldevices-go/internal/protocols"
15- "github.com/bnema/wlturbo/wl"
16 )16 )
17 17
18 // OutputManager manages output configuration and monitoring18 // OutputManager manages output configuration and monitoring
M output_management/output_management_test.go +2 -2
@@ -10,11 +10,11 @@ import (
1010 "testing"
1111 "time"
1212
13+ "bnema.dev/wlturbo"
14+ "bnema.dev/wlturbo/wl"
1315 "github.com/bnema/libwldevices-go/internal/client"
1416 "github.com/bnema/libwldevices-go/internal/protocols"
1517 "github.com/bnema/libwldevices-go/internal/testcompositor"
16- "github.com/bnema/wlturbo"
17- "github.com/bnema/wlturbo/wl"
1818 )
1919
2020 // Unit tests that don't require a compositor
@@ -10,11 +10,11 @@ import (
10 "testing"10 "testing"
11 "time"11 "time"
12 12
13+ "bnema.dev/wlturbo"
14+ "bnema.dev/wlturbo/wl"
13 "github.com/bnema/libwldevices-go/internal/client"15 "github.com/bnema/libwldevices-go/internal/client"
14 "github.com/bnema/libwldevices-go/internal/protocols"16 "github.com/bnema/libwldevices-go/internal/protocols"
15 "github.com/bnema/libwldevices-go/internal/testcompositor"17 "github.com/bnema/libwldevices-go/internal/testcompositor"
16- "github.com/bnema/wlturbo"
17- "github.com/bnema/wlturbo/wl"
18 )18 )
19 19
20 // Unit tests that don't require a compositor20 // Unit tests that don't require a compositor
M pointer_constraints/pointer_constraints.go +2 -2
@@ -24,10 +24,10 @@ import (
2424 "context"
2525 "fmt"
2626
27+ core "bnema.dev/go-wayland-bindings/client/wayland"
28+ "bnema.dev/wlturbo/wl"
2729 "github.com/bnema/libwldevices-go/internal/client"
2830 "github.com/bnema/libwldevices-go/internal/protocols"
29- "github.com/bnema/wlturbo/protocol/core"
30- "github.com/bnema/wlturbo/wl"
3131 )
3232
3333 // Lifetime constants for pointer constraints
@@ -24,10 +24,10 @@ import (
24 "context"24 "context"
25 "fmt"25 "fmt"
26 26
27+ core "bnema.dev/go-wayland-bindings/client/wayland"
28+ "bnema.dev/wlturbo/wl"
27 "github.com/bnema/libwldevices-go/internal/client"29 "github.com/bnema/libwldevices-go/internal/client"
28 "github.com/bnema/libwldevices-go/internal/protocols"30 "github.com/bnema/libwldevices-go/internal/protocols"
29- "github.com/bnema/wlturbo/protocol/core"
30- "github.com/bnema/wlturbo/wl"
31 )31 )
32 32
33 // Lifetime constants for pointer constraints33 // Lifetime constants for pointer constraints
M pointer_constraints/pointer_constraints_test.go +2 -2
@@ -6,10 +6,10 @@ import (
66 "testing"
77 "time"
88
9+ core "bnema.dev/go-wayland-bindings/client/wayland"
10+ "bnema.dev/wlturbo"
911 "github.com/bnema/libwldevices-go/internal/protocols"
1012 "github.com/bnema/libwldevices-go/internal/testcompositor"
11- "github.com/bnema/wlturbo"
12- "github.com/bnema/wlturbo/protocol/core"
1313 )
1414
1515 // Global name announced by the test compositor.
@@ -6,10 +6,10 @@ import (
6 "testing"6 "testing"
7 "time"7 "time"
8 8
9+ core "bnema.dev/go-wayland-bindings/client/wayland"
10+ "bnema.dev/wlturbo"
9 "github.com/bnema/libwldevices-go/internal/protocols"11 "github.com/bnema/libwldevices-go/internal/protocols"
10 "github.com/bnema/libwldevices-go/internal/testcompositor"12 "github.com/bnema/libwldevices-go/internal/testcompositor"
11- "github.com/bnema/wlturbo"
12- "github.com/bnema/wlturbo/protocol/core"
13 )13 )
14 14
15 // Global name announced by the test compositor.15 // Global name announced by the test compositor.
M test/consumer/go.mod +3 -3
@@ -3,8 +3,8 @@ module github.com/bnema/libwldevices-go/test/consumer
33 go 1.27
44
55 require (
6- github.com/bnema/libwldevices-go v0.1.4
7- github.com/bnema/wlturbo v0.3.0
6+ github.com/bnema/libwldevices-go v0.3.0
7+ github.com/bnema/wlturbo v0.6.2
88 )
99
10-require golang.org/x/sys v0.33.0 // indirect
10+require golang.org/x/sys v0.49.0 // indirect
@@ -3,8 +3,8 @@ module github.com/bnema/libwldevices-go/test/consumer
3 go 1.273 go 1.27
4 4
5 require (5 require (
6- github.com/bnema/libwldevices-go v0.1.46+ github.com/bnema/libwldevices-go v0.3.0
7- github.com/bnema/wlturbo v0.3.07+ github.com/bnema/wlturbo v0.6.2
8 )8 )
9 9
10-require golang.org/x/sys v0.33.0 // indirect10+require golang.org/x/sys v0.49.0 // indirect
M virtual_keyboard/keymap.go +1 -1
@@ -1,8 +1,8 @@
11 package virtual_keyboard
22
33 import (
4+ "bnema.dev/wlturbo/wl"
45 "fmt"
5- "github.com/bnema/wlturbo/wl"
66 "syscall"
77 )
88
@@ -1,8 +1,8 @@
1 package virtual_keyboard1 package virtual_keyboard
2 2
3 import (3 import (
4+ "bnema.dev/wlturbo/wl"
4 "fmt"5 "fmt"
5- "github.com/bnema/wlturbo/wl"
6 "syscall"6 "syscall"
7 )7 )
8 8
M virtual_keyboard/virtual_keyboard_test.go +1 -1
@@ -6,9 +6,9 @@ import (
66 "testing"
77 "time"
88
9+ "bnema.dev/wlturbo"
910 "github.com/bnema/libwldevices-go/internal/protocols"
1011 "github.com/bnema/libwldevices-go/internal/testcompositor"
11- "github.com/bnema/wlturbo"
1212 )
1313
1414 // Global names announced by the test compositor.
@@ -6,9 +6,9 @@ import (
6 "testing"6 "testing"
7 "time"7 "time"
8 8
9+ "bnema.dev/wlturbo"
9 "github.com/bnema/libwldevices-go/internal/protocols"10 "github.com/bnema/libwldevices-go/internal/protocols"
10 "github.com/bnema/libwldevices-go/internal/testcompositor"11 "github.com/bnema/libwldevices-go/internal/testcompositor"
11- "github.com/bnema/wlturbo"
12 )12 )
13 13
14 // Global names announced by the test compositor.14 // Global names announced by the test compositor.
M virtual_pointer/virtual_pointer.go +1 -1
@@ -47,9 +47,9 @@ import (
4747 "fmt"
4848 "time"
4949
50+ "bnema.dev/wlturbo/wl"
5051 "github.com/bnema/libwldevices-go/internal/client"
5152 "github.com/bnema/libwldevices-go/internal/protocols"
52- "github.com/bnema/wlturbo/wl"
5353 )
5454
5555 // Button constants for mouse buttons
@@ -47,9 +47,9 @@ import (
47 "fmt"47 "fmt"
48 "time"48 "time"
49 49
50+ "bnema.dev/wlturbo/wl"
50 "github.com/bnema/libwldevices-go/internal/client"51 "github.com/bnema/libwldevices-go/internal/client"
51 "github.com/bnema/libwldevices-go/internal/protocols"52 "github.com/bnema/libwldevices-go/internal/protocols"
52- "github.com/bnema/wlturbo/wl"
53 )53 )
54 54
55 // Button constants for mouse buttons55 // Button constants for mouse buttons
M virtual_pointer/virtual_pointer_test.go +1 -1
@@ -6,9 +6,9 @@ import (
66 "testing"
77 "time"
88
9+ "bnema.dev/wlturbo"
910 "github.com/bnema/libwldevices-go/internal/protocols"
1011 "github.com/bnema/libwldevices-go/internal/testcompositor"
11- "github.com/bnema/wlturbo"
1212 )
1313
1414 // Global names announced by the test compositor.
@@ -6,9 +6,9 @@ import (
6 "testing"6 "testing"
7 "time"7 "time"
8 8
9+ "bnema.dev/wlturbo"
9 "github.com/bnema/libwldevices-go/internal/protocols"10 "github.com/bnema/libwldevices-go/internal/protocols"
10 "github.com/bnema/libwldevices-go/internal/testcompositor"11 "github.com/bnema/libwldevices-go/internal/testcompositor"
11- "github.com/bnema/wlturbo"
12 )12 )
13 13
14 // Global names announced by the test compositor.14 // Global names announced by the test compositor.

Comments00 unresolved

    no comments yet.

    Keyboard shortcuts

    Single-key shortcuts are on. ctrl k and esc work whatever this says.

    ctrl k :
    go to a section, branch, tag, file or repository
    ?
    this list
    j k
    move the row cursor down / up
    enter
    open the row under the cursor; on Files, a directory opens or closes in place
    ↑ ↓ ← → home end
    in the file tree (focus on a row): previous / next row, close / open a directory or go to its parent / first entry, first / last row. They never open a file
    l h
    on Files: open a directory or a file / close a directory or go up to its parent, then to the parent page. On pages with a side panel: into the panel (on a merge request, its files) / back to the content; there j k move between its controls
    g g G
    first / last row
    /
    filter the list; on Files, find a file anywhere in the repository (esc clears, enter opens the best match)
    b
    switch branch or tag
    g s g f g c g b g m g i g r g a
    tabs: summary, files, commits, branches & tags, merge requests, issues, releases, actions (when available)
    g h
    home
    w
    wide mode: use the whole width of the screen, or not (remembered)
    y
    copy a permalink pinned to the commit; in a file, click a line number to select it, shift-click for a range
    d u x
    diff: split / unified / collapse or expand all
    e E
    diff: the whole file in view / every file, with the lines the hunks hide
    n
    merge request: next note in the diff
    l
    merge request: the list of files (j k move, enter opens, esc back)
    M
    merge request: the merge menu; there 1–3 pick the mode, D deletes the branch, enter merges
    R
    merge request: mark the head read
    esc
    close a dialog, leave a field

    Branches 2

    Tags 7

    ↑↓ moveenter openesc close