Merge pull request #349 from bnema/fix/rollback-lazy-puregotk
fix(deps): emergency rollback puregotk lazy registration regression
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
| @@ -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" | |
| @@ -55,7 +56,6 @@ type CarouselIndicatorLines struct { | |||
| 55 | 56 | var xCarouselIndicatorLinesGLibType func() types.GType | |
| 56 | 57 | ||
| 57 | 58 | func CarouselIndicatorLinesGLibType() types.GType { | |
| 58 | - | core.LazyRegister(&xCarouselIndicatorLinesGLibType, "ADW", "adw_carousel_indicator_lines_get_type", false) | |
| 59 | 59 | return xCarouselIndicatorLinesGLibType() | |
| 60 | 60 | } | |
| 61 | 61 | ||
| @@ -69,7 +69,6 @@ var xNewCarouselIndicatorLines func() uintptr | |||
| 69 | 69 | ||
| 70 | 70 | // Creates a new `AdwCarouselIndicatorLines`. | |
| 71 | 71 | func NewCarouselIndicatorLines() *CarouselIndicatorLines { | |
| 72 | - | core.LazyRegister(&xNewCarouselIndicatorLines, "ADW", "adw_carousel_indicator_lines_new", false) | |
| 73 | 72 | var cls *CarouselIndicatorLines | |
| 74 | 73 | ||
| 75 | 74 | cret := xNewCarouselIndicatorLines() | |
| @@ -87,7 +86,6 @@ var xCarouselIndicatorLinesGetCarousel func(uintptr) uintptr | |||
| 87 | 86 | ||
| 88 | 87 | // Gets the displayed carousel. | |
| 89 | 88 | func (x *CarouselIndicatorLines) GetCarousel() *Carousel { | |
| 90 | - | core.LazyRegister(&xCarouselIndicatorLinesGetCarousel, "ADW", "adw_carousel_indicator_lines_get_carousel", false) | |
| 91 | 89 | var cls *Carousel | |
| 92 | 90 | ||
| 93 | 91 | cret := xCarouselIndicatorLinesGetCarousel(x.GoPointer()) | |
| @@ -105,8 +103,6 @@ var xCarouselIndicatorLinesSetCarousel func(uintptr, uintptr) | |||
| 105 | 103 | ||
| 106 | 104 | // Sets the displayed carousel. | |
| 107 | 105 | func (x *CarouselIndicatorLines) SetCarousel(CarouselVar *Carousel) { | |
| 108 | - | core.LazyRegister(&xCarouselIndicatorLinesSetCarousel, "ADW", "adw_carousel_indicator_lines_set_carousel", false) | |
| 109 | - | ||
| 110 | 106 | xCarouselIndicatorLinesSetCarousel(x.GoPointer(), CarouselVar.GoPointer()) | |
| 111 | 107 | } | |
| 112 | 108 | ||
| @@ -395,4 +391,19 @@ func (x *CarouselIndicatorLines) SetOrientation(OrientationVar gtk.Orientation) | |||
| 395 | 391 | func init() { | |
| 396 | 392 | core.SetPackageName("ADW", "libadwaita-1") | |
| 397 | 393 | core.SetSharedLibraries("ADW", []string{"libadwaita-1.so.0", "libadwaita-1.0.dylib"}) | |
| 394 | + | var libs []uintptr | |
| 395 | + | for _, libPath := range core.GetPaths("ADW") { | |
| 396 | + | lib, err := purego.Dlopen(libPath, purego.RTLD_NOW|purego.RTLD_GLOBAL) | |
| 397 | + | if err != nil { | |
| 398 | + | panic(err) | |
| 399 | + | } | |
| 400 | + | libs = append(libs, lib) | |
| 401 | + | } | |
| 402 | + | ||
| 403 | + | core.PuregoSafeRegister(&xCarouselIndicatorLinesGLibType, libs, "adw_carousel_indicator_lines_get_type") | |
| 404 | + | ||
| 405 | + | core.PuregoSafeRegister(&xNewCarouselIndicatorLines, libs, "adw_carousel_indicator_lines_new") | |
| 406 | + | ||
| 407 | + | core.PuregoSafeRegister(&xCarouselIndicatorLinesGetCarousel, libs, "adw_carousel_indicator_lines_get_carousel") | |
| 408 | + | core.PuregoSafeRegister(&xCarouselIndicatorLinesSetCarousel, libs, "adw_carousel_indicator_lines_set_carousel") | |
| 398 | 409 | } | |
| @@ -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" | ||
| @@ -55,7 +56,6 @@ type CarouselIndicatorLines struct { | |||||
| 55 | var xCarouselIndicatorLinesGLibType func() types.GType | 56 | var xCarouselIndicatorLinesGLibType func() types.GType | ||
| 56 | 57 | ||||
| 57 | func CarouselIndicatorLinesGLibType() types.GType { | 58 | func CarouselIndicatorLinesGLibType() types.GType { | ||
| 58 | - | core.LazyRegister(&xCarouselIndicatorLinesGLibType, "ADW", "adw_carousel_indicator_lines_get_type", false) | |||
| 59 | return xCarouselIndicatorLinesGLibType() | 59 | return xCarouselIndicatorLinesGLibType() | ||
| 60 | } | 60 | } | ||
| 61 | 61 | ||||
| @@ -69,7 +69,6 @@ var xNewCarouselIndicatorLines func() uintptr | |||||
| 69 | 69 | ||||
| 70 | // Creates a new `AdwCarouselIndicatorLines`. | 70 | // Creates a new `AdwCarouselIndicatorLines`. | ||
| 71 | func NewCarouselIndicatorLines() *CarouselIndicatorLines { | 71 | func NewCarouselIndicatorLines() *CarouselIndicatorLines { | ||
| 72 | - | core.LazyRegister(&xNewCarouselIndicatorLines, "ADW", "adw_carousel_indicator_lines_new", false) | |||
| 73 | var cls *CarouselIndicatorLines | 72 | var cls *CarouselIndicatorLines | ||
| 74 | 73 | ||||
| 75 | cret := xNewCarouselIndicatorLines() | 74 | cret := xNewCarouselIndicatorLines() | ||
| @@ -87,7 +86,6 @@ var xCarouselIndicatorLinesGetCarousel func(uintptr) uintptr | |||||
| 87 | 86 | ||||
| 88 | // Gets the displayed carousel. | 87 | // Gets the displayed carousel. | ||
| 89 | func (x *CarouselIndicatorLines) GetCarousel() *Carousel { | 88 | func (x *CarouselIndicatorLines) GetCarousel() *Carousel { | ||
| 90 | - | core.LazyRegister(&xCarouselIndicatorLinesGetCarousel, "ADW", "adw_carousel_indicator_lines_get_carousel", false) | |||
| 91 | var cls *Carousel | 89 | var cls *Carousel | ||
| 92 | 90 | ||||
| 93 | cret := xCarouselIndicatorLinesGetCarousel(x.GoPointer()) | 91 | cret := xCarouselIndicatorLinesGetCarousel(x.GoPointer()) | ||
| @@ -105,8 +103,6 @@ var xCarouselIndicatorLinesSetCarousel func(uintptr, uintptr) | |||||
| 105 | 103 | ||||
| 106 | // Sets the displayed carousel. | 104 | // Sets the displayed carousel. | ||
| 107 | func (x *CarouselIndicatorLines) SetCarousel(CarouselVar *Carousel) { | 105 | func (x *CarouselIndicatorLines) SetCarousel(CarouselVar *Carousel) { | ||
| 108 | - | core.LazyRegister(&xCarouselIndicatorLinesSetCarousel, "ADW", "adw_carousel_indicator_lines_set_carousel", false) | |||
| 109 | - | ||||
| 110 | xCarouselIndicatorLinesSetCarousel(x.GoPointer(), CarouselVar.GoPointer()) | 106 | xCarouselIndicatorLinesSetCarousel(x.GoPointer(), CarouselVar.GoPointer()) | ||
| 111 | } | 107 | } | ||
| 112 | 108 | ||||
| @@ -395,4 +391,19 @@ func (x *CarouselIndicatorLines) SetOrientation(OrientationVar gtk.Orientation) | |||||
| 395 | func init() { | 391 | func init() { | ||
| 396 | core.SetPackageName("ADW", "libadwaita-1") | 392 | core.SetPackageName("ADW", "libadwaita-1") | ||
| 397 | core.SetSharedLibraries("ADW", []string{"libadwaita-1.so.0", "libadwaita-1.0.dylib"}) | 393 | core.SetSharedLibraries("ADW", []string{"libadwaita-1.so.0", "libadwaita-1.0.dylib"}) | ||
| 394 | + | var libs []uintptr | |||
| 395 | + | for _, libPath := range core.GetPaths("ADW") { | |||
| 396 | + | lib, err := purego.Dlopen(libPath, purego.RTLD_NOW|purego.RTLD_GLOBAL) | |||
| 397 | + | if err != nil { | |||
| 398 | + | panic(err) | |||
| 399 | + | } | |||
| 400 | + | libs = append(libs, lib) | |||
| 401 | + | } | |||
| 402 | + | ||||
| 403 | + | core.PuregoSafeRegister(&xCarouselIndicatorLinesGLibType, libs, "adw_carousel_indicator_lines_get_type") | |||
| 404 | + | ||||
| 405 | + | core.PuregoSafeRegister(&xNewCarouselIndicatorLines, libs, "adw_carousel_indicator_lines_new") | |||
| 406 | + | ||||
| 407 | + | core.PuregoSafeRegister(&xCarouselIndicatorLinesGetCarousel, libs, "adw_carousel_indicator_lines_get_carousel") | |||
| 408 | + | core.PuregoSafeRegister(&xCarouselIndicatorLinesSetCarousel, libs, "adw_carousel_indicator_lines_set_carousel") | |||
| 398 | } | 409 | } | ||