Revert "chore(deps): pin puregotk nil-signal fix"
This reverts commit a161e348e2093172038390b0906448f0ae979a0d.
- commit
- 40378d5e4fd2372d054e49168ab2a6f67aedd0fd
- author
- brice · · 2026-07-14 17:59 UTC
- parent
- 8d647bb
- signature
- GPG Verified
CD88F9E564E0102646FB6077A1A07C7C7C3E349D· arch-gpg Verified for the committer email
905 files · +25263 -27842
M go.mod +1 -1
| @@ -11,7 +11,7 @@ require ( | |||
| 11 | 11 | github.com/bnema/purego-pipewire v0.1.5-0.20260714124450-6504b9cdf02a | |
| 12 | 12 | github.com/bnema/purego-sqlite v0.1.4-0.20260714131321-3614fe683b9c | |
| 13 | 13 | github.com/bnema/purego-webp v0.2.1-0.20260714152238-7bc9c402fdf6 | |
| 14 | - | github.com/bnema/puregotk v0.7.1-0.20260714170452-0b6b9b901234 | |
| 14 | + | github.com/bnema/puregotk v0.7.0 | |
| 15 | 15 | github.com/charmbracelet/bubbles v1.0.0 | |
| 16 | 16 | github.com/charmbracelet/bubbletea v1.3.10 | |
| 17 | 17 | github.com/charmbracelet/lipgloss v1.1.0 | |
| @@ -11,7 +11,7 @@ require ( | |||||
| 11 | github.com/bnema/purego-pipewire v0.1.5-0.20260714124450-6504b9cdf02a | 11 | github.com/bnema/purego-pipewire v0.1.5-0.20260714124450-6504b9cdf02a | ||
| 12 | github.com/bnema/purego-sqlite v0.1.4-0.20260714131321-3614fe683b9c | 12 | github.com/bnema/purego-sqlite v0.1.4-0.20260714131321-3614fe683b9c | ||
| 13 | github.com/bnema/purego-webp v0.2.1-0.20260714152238-7bc9c402fdf6 | 13 | github.com/bnema/purego-webp v0.2.1-0.20260714152238-7bc9c402fdf6 | ||
| 14 | - | github.com/bnema/puregotk v0.7.1-0.20260714170452-0b6b9b901234 | 14 | + | github.com/bnema/puregotk v0.7.0 |
| 15 | github.com/charmbracelet/bubbles v1.0.0 | 15 | github.com/charmbracelet/bubbles v1.0.0 | ||
| 16 | github.com/charmbracelet/bubbletea v1.3.10 | 16 | github.com/charmbracelet/bubbletea v1.3.10 | ||
| 17 | github.com/charmbracelet/lipgloss v1.1.0 | 17 | github.com/charmbracelet/lipgloss v1.1.0 | ||
M go.sum +0 -4 generated file: collapsed
M vendor/github.com/bnema/puregotk/internal/core/core.go +4 -197 generated file: collapsed
M vendor/github.com/bnema/puregotk/pkg/core/core.go +0 -10 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-about-dialog.go +64 -99 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-about-window.go +62 -95 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-accent-color.go +15 -7 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-action-row.go +29 -33 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-alert-dialog.go +47 -66 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-animation-target.go +27 -10 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-animation-util.go +12 -4 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-animation.go +26 -24 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-application-window.go +22 -14 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-application.go +15 -3 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-avatar.go +25 -22 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-banner.go +26 -23 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-bin.go +16 -5 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-bottom-sheet.go +38 -47 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-breakpoint-bin.go +19 -10 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-breakpoint.go +37 -33 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-button-content.go +22 -18 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-button-row.go +18 -10 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-carousel-indicator-dots.go +16 -5 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-carousel-indicator-lines.go +16 -5 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-carousel.go +37 -47 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-clamp-layout.go +20 -14
| @@ -5,6 +5,7 @@ import ( | |||
| 5 | 5 | "structs" | |
| 6 | 6 | "unsafe" | |
| 7 | 7 | ||
| 8 | + | "github.com/bnema/purego" | |
| 8 | 9 | "github.com/bnema/puregotk/pkg/core" | |
| 9 | 10 | "github.com/bnema/puregotk/v4/gobject" | |
| 10 | 11 | "github.com/bnema/puregotk/v4/gobject/types" | |
| @@ -63,7 +64,6 @@ type ClampLayout struct { | |||
| 63 | 64 | var xClampLayoutGLibType func() types.GType | |
| 64 | 65 | ||
| 65 | 66 | func ClampLayoutGLibType() types.GType { | |
| 66 | - | core.LazyRegister(&xClampLayoutGLibType, "ADW", "adw_clamp_layout_get_type", false) | |
| 67 | 67 | return xClampLayoutGLibType() | |
| 68 | 68 | } | |
| 69 | 69 | ||
| @@ -77,7 +77,6 @@ var xNewClampLayout func() uintptr | |||
| 77 | 77 | ||
| 78 | 78 | // Creates a new `AdwClampLayout`. | |
| 79 | 79 | func NewClampLayout() *ClampLayout { | |
| 80 | - | core.LazyRegister(&xNewClampLayout, "ADW", "adw_clamp_layout_new", false) | |
| 81 | 80 | var cls *ClampLayout | |
| 82 | 81 | ||
| 83 | 82 | cret := xNewClampLayout() | |
| @@ -94,8 +93,6 @@ var xClampLayoutGetMaximumSize func(uintptr) int | |||
| 94 | 93 | ||
| 95 | 94 | // Gets the maximum size allocated to the children. | |
| 96 | 95 | func (x *ClampLayout) GetMaximumSize() int { | |
| 97 | - | core.LazyRegister(&xClampLayoutGetMaximumSize, "ADW", "adw_clamp_layout_get_maximum_size", false) | |
| 98 | - | ||
| 99 | 96 | cret := xClampLayoutGetMaximumSize(x.GoPointer()) | |
| 100 | 97 | return cret | |
| 101 | 98 | } | |
| @@ -104,8 +101,6 @@ var xClampLayoutGetTighteningThreshold func(uintptr) int | |||
| 104 | 101 | ||
| 105 | 102 | // Gets the size above which the children are clamped. | |
| 106 | 103 | func (x *ClampLayout) GetTighteningThreshold() int { | |
| 107 | - | core.LazyRegister(&xClampLayoutGetTighteningThreshold, "ADW", "adw_clamp_layout_get_tightening_threshold", false) | |
| 108 | - | ||
| 109 | 104 | cret := xClampLayoutGetTighteningThreshold(x.GoPointer()) | |
| 110 | 105 | return cret | |
| 111 | 106 | } | |
| @@ -114,8 +109,6 @@ var xClampLayoutGetUnit func(uintptr) LengthUnit | |||
| 114 | 109 | ||
| 115 | 110 | // Gets the length unit for maximum size and tightening threshold. | |
| 116 | 111 | func (x *ClampLayout) GetUnit() LengthUnit { | |
| 117 | - | core.LazyRegister(&xClampLayoutGetUnit, "ADW", "adw_clamp_layout_get_unit", false) | |
| 118 | - | ||
| 119 | 112 | cret := xClampLayoutGetUnit(x.GoPointer()) | |
| 120 | 113 | return cret | |
| 121 | 114 | } | |
| @@ -126,8 +119,6 @@ var xClampLayoutSetMaximumSize func(uintptr, int) | |||
| 126 | 119 | // | |
| 127 | 120 | // It is the width if the layout is horizontal, or the height if it is vertical. | |
| 128 | 121 | func (x *ClampLayout) SetMaximumSize(MaximumSizeVar int) { | |
| 129 | - | core.LazyRegister(&xClampLayoutSetMaximumSize, "ADW", "adw_clamp_layout_set_maximum_size", false) | |
| 130 | - | ||
| 131 | 122 | xClampLayoutSetMaximumSize(x.GoPointer(), MaximumSizeVar) | |
| 132 | 123 | } | |
| 133 | 124 | ||
| @@ -148,8 +139,6 @@ var xClampLayoutSetTighteningThreshold func(uintptr, int) | |||
| 148 | 139 | // Effectively, tightening the grip on a child before it reaches its maximum | |
| 149 | 140 | // size makes transitions to and from the maximum size smoother when resizing. | |
| 150 | 141 | func (x *ClampLayout) SetTighteningThreshold(TighteningThresholdVar int) { | |
| 151 | - | core.LazyRegister(&xClampLayoutSetTighteningThreshold, "ADW", "adw_clamp_layout_set_tightening_threshold", false) | |
| 152 | - | ||
| 153 | 142 | xClampLayoutSetTighteningThreshold(x.GoPointer(), TighteningThresholdVar) | |
| 154 | 143 | } | |
| 155 | 144 | ||
| @@ -159,8 +148,6 @@ var xClampLayoutSetUnit func(uintptr, LengthUnit) | |||
| 159 | 148 | // | |
| 160 | 149 | // Allows the sizes to vary depending on the text scale factor. | |
| 161 | 150 | func (x *ClampLayout) SetUnit(UnitVar LengthUnit) { | |
| 162 | - | core.LazyRegister(&xClampLayoutSetUnit, "ADW", "adw_clamp_layout_set_unit", false) | |
| 163 | - | ||
| 164 | 151 | xClampLayoutSetUnit(x.GoPointer(), UnitVar) | |
| 165 | 152 | } | |
| 166 | 153 | ||
| @@ -255,4 +242,23 @@ func (x *ClampLayout) SetOrientation(OrientationVar gtk.Orientation) { | |||
| 255 | 242 | func init() { | |
| 256 | 243 | core.SetPackageName("ADW", "libadwaita-1") | |
| 257 | 244 | core.SetSharedLibraries("ADW", []string{"libadwaita-1.so.0", "libadwaita-1.0.dylib"}) | |
| 245 | + | var libs []uintptr | |
| 246 | + | for _, libPath := range core.GetPaths("ADW") { | |
| 247 | + | lib, err := purego.Dlopen(libPath, purego.RTLD_NOW|purego.RTLD_GLOBAL) | |
| 248 | + | if err != nil { | |
| 249 | + | panic(err) | |
| 250 | + | } | |
| 251 | + | libs = append(libs, lib) | |
| 252 | + | } | |
| 253 | + | ||
| 254 | + | core.PuregoSafeRegister(&xClampLayoutGLibType, libs, "adw_clamp_layout_get_type") | |
| 255 | + | ||
| 256 | + | core.PuregoSafeRegister(&xNewClampLayout, libs, "adw_clamp_layout_new") | |
| 257 | + | ||
| 258 | + | core.PuregoSafeRegister(&xClampLayoutGetMaximumSize, libs, "adw_clamp_layout_get_maximum_size") | |
| 259 | + | core.PuregoSafeRegister(&xClampLayoutGetTighteningThreshold, libs, "adw_clamp_layout_get_tightening_threshold") | |
| 260 | + | core.PuregoSafeRegister(&xClampLayoutGetUnit, libs, "adw_clamp_layout_get_unit") | |
| 261 | + | core.PuregoSafeRegister(&xClampLayoutSetMaximumSize, libs, "adw_clamp_layout_set_maximum_size") | |
| 262 | + | core.PuregoSafeRegister(&xClampLayoutSetTighteningThreshold, libs, "adw_clamp_layout_set_tightening_threshold") | |
| 263 | + | core.PuregoSafeRegister(&xClampLayoutSetUnit, libs, "adw_clamp_layout_set_unit") | |
| 258 | 264 | } | |
| @@ -5,6 +5,7 @@ import ( | |||||
| 5 | "structs" | 5 | "structs" | ||
| 6 | "unsafe" | 6 | "unsafe" | ||
| 7 | 7 | ||||
| 8 | + | "github.com/bnema/purego" | |||
| 8 | "github.com/bnema/puregotk/pkg/core" | 9 | "github.com/bnema/puregotk/pkg/core" | ||
| 9 | "github.com/bnema/puregotk/v4/gobject" | 10 | "github.com/bnema/puregotk/v4/gobject" | ||
| 10 | "github.com/bnema/puregotk/v4/gobject/types" | 11 | "github.com/bnema/puregotk/v4/gobject/types" | ||
| @@ -63,7 +64,6 @@ type ClampLayout struct { | |||||
| 63 | var xClampLayoutGLibType func() types.GType | 64 | var xClampLayoutGLibType func() types.GType | ||
| 64 | 65 | ||||
| 65 | func ClampLayoutGLibType() types.GType { | 66 | func ClampLayoutGLibType() types.GType { | ||
| 66 | - | core.LazyRegister(&xClampLayoutGLibType, "ADW", "adw_clamp_layout_get_type", false) | |||
| 67 | return xClampLayoutGLibType() | 67 | return xClampLayoutGLibType() | ||
| 68 | } | 68 | } | ||
| 69 | 69 | ||||
| @@ -77,7 +77,6 @@ var xNewClampLayout func() uintptr | |||||
| 77 | 77 | ||||
| 78 | // Creates a new `AdwClampLayout`. | 78 | // Creates a new `AdwClampLayout`. | ||
| 79 | func NewClampLayout() *ClampLayout { | 79 | func NewClampLayout() *ClampLayout { | ||
| 80 | - | core.LazyRegister(&xNewClampLayout, "ADW", "adw_clamp_layout_new", false) | |||
| 81 | var cls *ClampLayout | 80 | var cls *ClampLayout | ||
| 82 | 81 | ||||
| 83 | cret := xNewClampLayout() | 82 | cret := xNewClampLayout() | ||
| @@ -94,8 +93,6 @@ var xClampLayoutGetMaximumSize func(uintptr) int | |||||
| 94 | 93 | ||||
| 95 | // Gets the maximum size allocated to the children. | 94 | // Gets the maximum size allocated to the children. | ||
| 96 | func (x *ClampLayout) GetMaximumSize() int { | 95 | func (x *ClampLayout) GetMaximumSize() int { | ||
| 97 | - | core.LazyRegister(&xClampLayoutGetMaximumSize, "ADW", "adw_clamp_layout_get_maximum_size", false) | |||
| 98 | - | ||||
| 99 | cret := xClampLayoutGetMaximumSize(x.GoPointer()) | 96 | cret := xClampLayoutGetMaximumSize(x.GoPointer()) | ||
| 100 | return cret | 97 | return cret | ||
| 101 | } | 98 | } | ||
| @@ -104,8 +101,6 @@ var xClampLayoutGetTighteningThreshold func(uintptr) int | |||||
| 104 | 101 | ||||
| 105 | // Gets the size above which the children are clamped. | 102 | // Gets the size above which the children are clamped. | ||
| 106 | func (x *ClampLayout) GetTighteningThreshold() int { | 103 | func (x *ClampLayout) GetTighteningThreshold() int { | ||
| 107 | - | core.LazyRegister(&xClampLayoutGetTighteningThreshold, "ADW", "adw_clamp_layout_get_tightening_threshold", false) | |||
| 108 | - | ||||
| 109 | cret := xClampLayoutGetTighteningThreshold(x.GoPointer()) | 104 | cret := xClampLayoutGetTighteningThreshold(x.GoPointer()) | ||
| 110 | return cret | 105 | return cret | ||
| 111 | } | 106 | } | ||
| @@ -114,8 +109,6 @@ var xClampLayoutGetUnit func(uintptr) LengthUnit | |||||
| 114 | 109 | ||||
| 115 | // Gets the length unit for maximum size and tightening threshold. | 110 | // Gets the length unit for maximum size and tightening threshold. | ||
| 116 | func (x *ClampLayout) GetUnit() LengthUnit { | 111 | func (x *ClampLayout) GetUnit() LengthUnit { | ||
| 117 | - | core.LazyRegister(&xClampLayoutGetUnit, "ADW", "adw_clamp_layout_get_unit", false) | |||
| 118 | - | ||||
| 119 | cret := xClampLayoutGetUnit(x.GoPointer()) | 112 | cret := xClampLayoutGetUnit(x.GoPointer()) | ||
| 120 | return cret | 113 | return cret | ||
| 121 | } | 114 | } | ||
| @@ -126,8 +119,6 @@ var xClampLayoutSetMaximumSize func(uintptr, int) | |||||
| 126 | // | 119 | // | ||
| 127 | // It is the width if the layout is horizontal, or the height if it is vertical. | 120 | // It is the width if the layout is horizontal, or the height if it is vertical. | ||
| 128 | func (x *ClampLayout) SetMaximumSize(MaximumSizeVar int) { | 121 | func (x *ClampLayout) SetMaximumSize(MaximumSizeVar int) { | ||
| 129 | - | core.LazyRegister(&xClampLayoutSetMaximumSize, "ADW", "adw_clamp_layout_set_maximum_size", false) | |||
| 130 | - | ||||
| 131 | xClampLayoutSetMaximumSize(x.GoPointer(), MaximumSizeVar) | 122 | xClampLayoutSetMaximumSize(x.GoPointer(), MaximumSizeVar) | ||
| 132 | } | 123 | } | ||
| 133 | 124 | ||||
| @@ -148,8 +139,6 @@ var xClampLayoutSetTighteningThreshold func(uintptr, int) | |||||
| 148 | // Effectively, tightening the grip on a child before it reaches its maximum | 139 | // Effectively, tightening the grip on a child before it reaches its maximum | ||
| 149 | // size makes transitions to and from the maximum size smoother when resizing. | 140 | // size makes transitions to and from the maximum size smoother when resizing. | ||
| 150 | func (x *ClampLayout) SetTighteningThreshold(TighteningThresholdVar int) { | 141 | func (x *ClampLayout) SetTighteningThreshold(TighteningThresholdVar int) { | ||
| 151 | - | core.LazyRegister(&xClampLayoutSetTighteningThreshold, "ADW", "adw_clamp_layout_set_tightening_threshold", false) | |||
| 152 | - | ||||
| 153 | xClampLayoutSetTighteningThreshold(x.GoPointer(), TighteningThresholdVar) | 142 | xClampLayoutSetTighteningThreshold(x.GoPointer(), TighteningThresholdVar) | ||
| 154 | } | 143 | } | ||
| 155 | 144 | ||||
| @@ -159,8 +148,6 @@ var xClampLayoutSetUnit func(uintptr, LengthUnit) | |||||
| 159 | // | 148 | // | ||
| 160 | // Allows the sizes to vary depending on the text scale factor. | 149 | // Allows the sizes to vary depending on the text scale factor. | ||
| 161 | func (x *ClampLayout) SetUnit(UnitVar LengthUnit) { | 150 | func (x *ClampLayout) SetUnit(UnitVar LengthUnit) { | ||
| 162 | - | core.LazyRegister(&xClampLayoutSetUnit, "ADW", "adw_clamp_layout_set_unit", false) | |||
| 163 | - | ||||
| 164 | xClampLayoutSetUnit(x.GoPointer(), UnitVar) | 151 | xClampLayoutSetUnit(x.GoPointer(), UnitVar) | ||
| 165 | } | 152 | } | ||
| 166 | 153 | ||||
| @@ -255,4 +242,23 @@ func (x *ClampLayout) SetOrientation(OrientationVar gtk.Orientation) { | |||||
| 255 | func init() { | 242 | func init() { | ||
| 256 | core.SetPackageName("ADW", "libadwaita-1") | 243 | core.SetPackageName("ADW", "libadwaita-1") | ||
| 257 | core.SetSharedLibraries("ADW", []string{"libadwaita-1.so.0", "libadwaita-1.0.dylib"}) | 244 | core.SetSharedLibraries("ADW", []string{"libadwaita-1.so.0", "libadwaita-1.0.dylib"}) | ||
| 245 | + | var libs []uintptr | |||
| 246 | + | for _, libPath := range core.GetPaths("ADW") { | |||
| 247 | + | lib, err := purego.Dlopen(libPath, purego.RTLD_NOW|purego.RTLD_GLOBAL) | |||
| 248 | + | if err != nil { | |||
| 249 | + | panic(err) | |||
| 250 | + | } | |||
| 251 | + | libs = append(libs, lib) | |||
| 252 | + | } | |||
| 253 | + | ||||
| 254 | + | core.PuregoSafeRegister(&xClampLayoutGLibType, libs, "adw_clamp_layout_get_type") | |||
| 255 | + | ||||
| 256 | + | core.PuregoSafeRegister(&xNewClampLayout, libs, "adw_clamp_layout_new") | |||
| 257 | + | ||||
| 258 | + | core.PuregoSafeRegister(&xClampLayoutGetMaximumSize, libs, "adw_clamp_layout_get_maximum_size") | |||
| 259 | + | core.PuregoSafeRegister(&xClampLayoutGetTighteningThreshold, libs, "adw_clamp_layout_get_tightening_threshold") | |||
| 260 | + | core.PuregoSafeRegister(&xClampLayoutGetUnit, libs, "adw_clamp_layout_get_unit") | |||
| 261 | + | core.PuregoSafeRegister(&xClampLayoutSetMaximumSize, libs, "adw_clamp_layout_set_maximum_size") | |||
| 262 | + | core.PuregoSafeRegister(&xClampLayoutSetTighteningThreshold, libs, "adw_clamp_layout_set_tightening_threshold") | |||
| 263 | + | core.PuregoSafeRegister(&xClampLayoutSetUnit, libs, "adw_clamp_layout_set_unit") | |||
| 258 | } | 264 | } | ||