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 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 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-clamp-scrollable.go +22 -17 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-clamp.go +22 -17 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-combo-row.go +33 -34 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-dialog.go +38 -45 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-easing.go +13 -3 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-entry-row.go +33 -40 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-enum-list-model.go +22 -13 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-expander-row.go +33 -40 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-flap.go +48 -61 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-fold-threshold-policy.go +1 -10 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-header-bar.go +33 -36 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-inline-view-switcher.go +24 -18 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-layout-slot.go +15 -4 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-layout.go +17 -7 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-leaflet.go +56 -69 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-length-unit.go +14 -5 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-main.go +15 -5 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-message-dialog.go +44 -63 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-multi-layout-view.go +23 -17 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-navigation-direction.go +1 -10 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-navigation-split-view.go +32 -36 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-navigation-view.go +49 -60 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-overlay-split-view.go +38 -48 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-password-entry-row.go +13 -2 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-preferences-dialog.go +25 -23 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-preferences-group.go +26 -24 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-preferences-page.go +33 -38 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-preferences-row.go +22 -18 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-preferences-window.go +29 -31 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-shortcut-label.go +18 -10 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-shortcuts-dialog.go +15 -4 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-shortcuts-item.go +25 -23 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-shortcuts-section.go +17 -8 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-sidebar-item.go +37 -45 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-sidebar-section.go +27 -24 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-sidebar.go +39 -41 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-spin-row.go +34 -40 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-spinner-paintable.go +16 -5 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-spinner.go +13 -2 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-split-button.go +34 -39 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-spring-animation.go +30 -34 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-spring-params.go +21 -17 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-squeezer.go +44 -49 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-status-page.go +24 -20 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-style-manager.go +28 -25 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-swipe-tracker.go +30 -33 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-swipeable.go +21 -33 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-switch-row.go +16 -6 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-tab-bar.go +32 -35 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-tab-button.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/glib" | |
| 10 | 11 | "github.com/bnema/puregotk/v4/gobject" | |
| @@ -69,7 +70,6 @@ type TabButton struct { | |||
| 69 | 70 | var xTabButtonGLibType func() types.GType | |
| 70 | 71 | ||
| 71 | 72 | func TabButtonGLibType() types.GType { | |
| 72 | - | core.LazyRegister(&xTabButtonGLibType, "ADW", "adw_tab_button_get_type", false) | |
| 73 | 73 | return xTabButtonGLibType() | |
| 74 | 74 | } | |
| 75 | 75 | ||
| @@ -83,7 +83,6 @@ var xNewTabButton func() uintptr | |||
| 83 | 83 | ||
| 84 | 84 | // Creates a new `AdwTabButton`. | |
| 85 | 85 | func NewTabButton() *TabButton { | |
| 86 | - | core.LazyRegister(&xNewTabButton, "ADW", "adw_tab_button_new", false) | |
| 87 | 86 | var cls *TabButton | |
| 88 | 87 | ||
| 89 | 88 | cret := xNewTabButton() | |
| @@ -101,7 +100,6 @@ var xTabButtonGetView func(uintptr) uintptr | |||
| 101 | 100 | ||
| 102 | 101 | // Gets the tab view @self displays. | |
| 103 | 102 | func (x *TabButton) GetView() *TabView { | |
| 104 | - | core.LazyRegister(&xTabButtonGetView, "ADW", "adw_tab_button_get_view", false) | |
| 105 | 103 | var cls *TabView | |
| 106 | 104 | ||
| 107 | 105 | cret := xTabButtonGetView(x.GoPointer()) | |
| @@ -119,8 +117,6 @@ var xTabButtonSetView func(uintptr, uintptr) | |||
| 119 | 117 | ||
| 120 | 118 | // Sets the tab view to display. | |
| 121 | 119 | func (x *TabButton) SetView(ViewVar *TabView) { | |
| 122 | - | core.LazyRegister(&xTabButtonSetView, "ADW", "adw_tab_button_set_view", false) | |
| 123 | - | ||
| 124 | 120 | xTabButtonSetView(x.GoPointer(), ViewVar.GoPointer()) | |
| 125 | 121 | } | |
| 126 | 122 | ||
| @@ -526,4 +522,19 @@ func (x *TabButton) GetBuildableId() string { | |||
| 526 | 522 | func init() { | |
| 527 | 523 | core.SetPackageName("ADW", "libadwaita-1") | |
| 528 | 524 | core.SetSharedLibraries("ADW", []string{"libadwaita-1.so.0", "libadwaita-1.0.dylib"}) | |
| 525 | + | var libs []uintptr | |
| 526 | + | for _, libPath := range core.GetPaths("ADW") { | |
| 527 | + | lib, err := purego.Dlopen(libPath, purego.RTLD_NOW|purego.RTLD_GLOBAL) | |
| 528 | + | if err != nil { | |
| 529 | + | panic(err) | |
| 530 | + | } | |
| 531 | + | libs = append(libs, lib) | |
| 532 | + | } | |
| 533 | + | ||
| 534 | + | core.PuregoSafeRegister(&xTabButtonGLibType, libs, "adw_tab_button_get_type") | |
| 535 | + | ||
| 536 | + | core.PuregoSafeRegister(&xNewTabButton, libs, "adw_tab_button_new") | |
| 537 | + | ||
| 538 | + | core.PuregoSafeRegister(&xTabButtonGetView, libs, "adw_tab_button_get_view") | |
| 539 | + | core.PuregoSafeRegister(&xTabButtonSetView, libs, "adw_tab_button_set_view") | |
| 529 | 540 | } | |
| @@ -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/glib" | 10 | "github.com/bnema/puregotk/v4/glib" | ||
| 10 | "github.com/bnema/puregotk/v4/gobject" | 11 | "github.com/bnema/puregotk/v4/gobject" | ||
| @@ -69,7 +70,6 @@ type TabButton struct { | |||||
| 69 | var xTabButtonGLibType func() types.GType | 70 | var xTabButtonGLibType func() types.GType | ||
| 70 | 71 | ||||
| 71 | func TabButtonGLibType() types.GType { | 72 | func TabButtonGLibType() types.GType { | ||
| 72 | - | core.LazyRegister(&xTabButtonGLibType, "ADW", "adw_tab_button_get_type", false) | |||
| 73 | return xTabButtonGLibType() | 73 | return xTabButtonGLibType() | ||
| 74 | } | 74 | } | ||
| 75 | 75 | ||||
| @@ -83,7 +83,6 @@ var xNewTabButton func() uintptr | |||||
| 83 | 83 | ||||
| 84 | // Creates a new `AdwTabButton`. | 84 | // Creates a new `AdwTabButton`. | ||
| 85 | func NewTabButton() *TabButton { | 85 | func NewTabButton() *TabButton { | ||
| 86 | - | core.LazyRegister(&xNewTabButton, "ADW", "adw_tab_button_new", false) | |||
| 87 | var cls *TabButton | 86 | var cls *TabButton | ||
| 88 | 87 | ||||
| 89 | cret := xNewTabButton() | 88 | cret := xNewTabButton() | ||
| @@ -101,7 +100,6 @@ var xTabButtonGetView func(uintptr) uintptr | |||||
| 101 | 100 | ||||
| 102 | // Gets the tab view @self displays. | 101 | // Gets the tab view @self displays. | ||
| 103 | func (x *TabButton) GetView() *TabView { | 102 | func (x *TabButton) GetView() *TabView { | ||
| 104 | - | core.LazyRegister(&xTabButtonGetView, "ADW", "adw_tab_button_get_view", false) | |||
| 105 | var cls *TabView | 103 | var cls *TabView | ||
| 106 | 104 | ||||
| 107 | cret := xTabButtonGetView(x.GoPointer()) | 105 | cret := xTabButtonGetView(x.GoPointer()) | ||
| @@ -119,8 +117,6 @@ var xTabButtonSetView func(uintptr, uintptr) | |||||
| 119 | 117 | ||||
| 120 | // Sets the tab view to display. | 118 | // Sets the tab view to display. | ||
| 121 | func (x *TabButton) SetView(ViewVar *TabView) { | 119 | func (x *TabButton) SetView(ViewVar *TabView) { | ||
| 122 | - | core.LazyRegister(&xTabButtonSetView, "ADW", "adw_tab_button_set_view", false) | |||
| 123 | - | ||||
| 124 | xTabButtonSetView(x.GoPointer(), ViewVar.GoPointer()) | 120 | xTabButtonSetView(x.GoPointer(), ViewVar.GoPointer()) | ||
| 125 | } | 121 | } | ||
| 126 | 122 | ||||
| @@ -526,4 +522,19 @@ func (x *TabButton) GetBuildableId() string { | |||||
| 526 | func init() { | 522 | func init() { | ||
| 527 | core.SetPackageName("ADW", "libadwaita-1") | 523 | core.SetPackageName("ADW", "libadwaita-1") | ||
| 528 | core.SetSharedLibraries("ADW", []string{"libadwaita-1.so.0", "libadwaita-1.0.dylib"}) | 524 | core.SetSharedLibraries("ADW", []string{"libadwaita-1.so.0", "libadwaita-1.0.dylib"}) | ||
| 525 | + | var libs []uintptr | |||
| 526 | + | for _, libPath := range core.GetPaths("ADW") { | |||
| 527 | + | lib, err := purego.Dlopen(libPath, purego.RTLD_NOW|purego.RTLD_GLOBAL) | |||
| 528 | + | if err != nil { | |||
| 529 | + | panic(err) | |||
| 530 | + | } | |||
| 531 | + | libs = append(libs, lib) | |||
| 532 | + | } | |||
| 533 | + | ||||
| 534 | + | core.PuregoSafeRegister(&xTabButtonGLibType, libs, "adw_tab_button_get_type") | |||
| 535 | + | ||||
| 536 | + | core.PuregoSafeRegister(&xNewTabButton, libs, "adw_tab_button_new") | |||
| 537 | + | ||||
| 538 | + | core.PuregoSafeRegister(&xTabButtonGetView, libs, "adw_tab_button_get_view") | |||
| 539 | + | core.PuregoSafeRegister(&xTabButtonSetView, libs, "adw_tab_button_set_view") | |||
| 529 | } | 540 | } | ||