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
| @@ -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/gdk" | |
| 10 | 11 | "github.com/bnema/puregotk/v4/gobject" | |
| @@ -70,7 +71,6 @@ type StatusPage struct { | |||
| 70 | 71 | var xStatusPageGLibType func() types.GType | |
| 71 | 72 | ||
| 72 | 73 | func StatusPageGLibType() types.GType { | |
| 73 | - | core.LazyRegister(&xStatusPageGLibType, "ADW", "adw_status_page_get_type", false) | |
| 74 | 74 | return xStatusPageGLibType() | |
| 75 | 75 | } | |
| 76 | 76 | ||
| @@ -84,7 +84,6 @@ var xNewStatusPage func() uintptr | |||
| 84 | 84 | ||
| 85 | 85 | // Creates a new `AdwStatusPage`. | |
| 86 | 86 | func NewStatusPage() *StatusPage { | |
| 87 | - | core.LazyRegister(&xNewStatusPage, "ADW", "adw_status_page_new", false) | |
| 88 | 87 | var cls *StatusPage | |
| 89 | 88 | ||
| 90 | 89 | cret := xNewStatusPage() | |
| @@ -102,7 +101,6 @@ var xStatusPageGetChild func(uintptr) uintptr | |||
| 102 | 101 | ||
| 103 | 102 | // Gets the child widget of @self. | |
| 104 | 103 | func (x *StatusPage) GetChild() *gtk.Widget { | |
| 105 | - | core.LazyRegister(&xStatusPageGetChild, "ADW", "adw_status_page_get_child", false) | |
| 106 | 104 | var cls *gtk.Widget | |
| 107 | 105 | ||
| 108 | 106 | cret := xStatusPageGetChild(x.GoPointer()) | |
| @@ -120,8 +118,6 @@ var xStatusPageGetDescription func(uintptr) string | |||
| 120 | 118 | ||
| 121 | 119 | // Gets the description markup for @self. | |
| 122 | 120 | func (x *StatusPage) GetDescription() string { | |
| 123 | - | core.LazyRegister(&xStatusPageGetDescription, "ADW", "adw_status_page_get_description", false) | |
| 124 | - | ||
| 125 | 121 | cret := xStatusPageGetDescription(x.GoPointer()) | |
| 126 | 122 | return cret | |
| 127 | 123 | } | |
| @@ -130,8 +126,6 @@ var xStatusPageGetIconName func(uintptr) string | |||
| 130 | 126 | ||
| 131 | 127 | // Gets the icon name for @self. | |
| 132 | 128 | func (x *StatusPage) GetIconName() string { | |
| 133 | - | core.LazyRegister(&xStatusPageGetIconName, "ADW", "adw_status_page_get_icon_name", false) | |
| 134 | - | ||
| 135 | 129 | cret := xStatusPageGetIconName(x.GoPointer()) | |
| 136 | 130 | return cret | |
| 137 | 131 | } | |
| @@ -140,7 +134,6 @@ var xStatusPageGetPaintable func(uintptr) uintptr | |||
| 140 | 134 | ||
| 141 | 135 | // Gets the paintable for @self. | |
| 142 | 136 | func (x *StatusPage) GetPaintable() *gdk.PaintableBase { | |
| 143 | - | core.LazyRegister(&xStatusPageGetPaintable, "ADW", "adw_status_page_get_paintable", false) | |
| 144 | 137 | var cls *gdk.PaintableBase | |
| 145 | 138 | ||
| 146 | 139 | cret := xStatusPageGetPaintable(x.GoPointer()) | |
| @@ -158,8 +151,6 @@ var xStatusPageGetTitle func(uintptr) string | |||
| 158 | 151 | ||
| 159 | 152 | // Gets the title for @self. | |
| 160 | 153 | func (x *StatusPage) GetTitle() string { | |
| 161 | - | core.LazyRegister(&xStatusPageGetTitle, "ADW", "adw_status_page_get_title", false) | |
| 162 | - | ||
| 163 | 154 | cret := xStatusPageGetTitle(x.GoPointer()) | |
| 164 | 155 | return cret | |
| 165 | 156 | } | |
| @@ -168,8 +159,6 @@ var xStatusPageSetChild func(uintptr, uintptr) | |||
| 168 | 159 | ||
| 169 | 160 | // Sets the child widget of @self. | |
| 170 | 161 | func (x *StatusPage) SetChild(ChildVar *gtk.Widget) { | |
| 171 | - | core.LazyRegister(&xStatusPageSetChild, "ADW", "adw_status_page_set_child", false) | |
| 172 | - | ||
| 173 | 162 | xStatusPageSetChild(x.GoPointer(), ChildVar.GoPointer()) | |
| 174 | 163 | } | |
| 175 | 164 | ||
| @@ -179,8 +168,6 @@ var xStatusPageSetDescription func(uintptr, uintptr) | |||
| 179 | 168 | // | |
| 180 | 169 | // The description is displayed below the title. It is parsed as Pango markup. | |
| 181 | 170 | func (x *StatusPage) SetDescription(DescriptionVar *string) { | |
| 182 | - | core.LazyRegister(&xStatusPageSetDescription, "ADW", "adw_status_page_set_description", false) | |
| 183 | - | ||
| 184 | 171 | DescriptionVarPtr := core.GStrdupNullable(DescriptionVar) | |
| 185 | 172 | defer core.GFreeNullable(DescriptionVarPtr) | |
| 186 | 173 | ||
| @@ -193,8 +180,6 @@ var xStatusPageSetIconName func(uintptr, uintptr) | |||
| 193 | 180 | // | |
| 194 | 181 | // Changing this will set [property@StatusPage:paintable] to `NULL`. | |
| 195 | 182 | func (x *StatusPage) SetIconName(IconNameVar *string) { | |
| 196 | - | core.LazyRegister(&xStatusPageSetIconName, "ADW", "adw_status_page_set_icon_name", false) | |
| 197 | - | ||
| 198 | 183 | IconNameVarPtr := core.GStrdupNullable(IconNameVar) | |
| 199 | 184 | defer core.GFreeNullable(IconNameVarPtr) | |
| 200 | 185 | ||
| @@ -207,8 +192,6 @@ var xStatusPageSetPaintable func(uintptr, uintptr) | |||
| 207 | 192 | // | |
| 208 | 193 | // Changing this will set [property@StatusPage:icon-name] to `NULL`. | |
| 209 | 194 | func (x *StatusPage) SetPaintable(PaintableVar gdk.Paintable) { | |
| 210 | - | core.LazyRegister(&xStatusPageSetPaintable, "ADW", "adw_status_page_set_paintable", false) | |
| 211 | - | ||
| 212 | 195 | xStatusPageSetPaintable(x.GoPointer(), PaintableVar.GoPointer()) | |
| 213 | 196 | } | |
| 214 | 197 | ||
| @@ -218,8 +201,6 @@ var xStatusPageSetTitle func(uintptr, string) | |||
| 218 | 201 | // | |
| 219 | 202 | // The title is displayed below the icon. It is not parsed as Pango markup. | |
| 220 | 203 | func (x *StatusPage) SetTitle(TitleVar string) { | |
| 221 | - | core.LazyRegister(&xStatusPageSetTitle, "ADW", "adw_status_page_set_title", false) | |
| 222 | - | ||
| 223 | 204 | xStatusPageSetTitle(x.GoPointer(), TitleVar) | |
| 224 | 205 | } | |
| 225 | 206 | ||
| @@ -556,4 +537,27 @@ func (x *StatusPage) GetBuildableId() string { | |||
| 556 | 537 | func init() { | |
| 557 | 538 | core.SetPackageName("ADW", "libadwaita-1") | |
| 558 | 539 | core.SetSharedLibraries("ADW", []string{"libadwaita-1.so.0", "libadwaita-1.0.dylib"}) | |
| 540 | + | var libs []uintptr | |
| 541 | + | for _, libPath := range core.GetPaths("ADW") { | |
| 542 | + | lib, err := purego.Dlopen(libPath, purego.RTLD_NOW|purego.RTLD_GLOBAL) | |
| 543 | + | if err != nil { | |
| 544 | + | panic(err) | |
| 545 | + | } | |
| 546 | + | libs = append(libs, lib) | |
| 547 | + | } | |
| 548 | + | ||
| 549 | + | core.PuregoSafeRegister(&xStatusPageGLibType, libs, "adw_status_page_get_type") | |
| 550 | + | ||
| 551 | + | core.PuregoSafeRegister(&xNewStatusPage, libs, "adw_status_page_new") | |
| 552 | + | ||
| 553 | + | core.PuregoSafeRegister(&xStatusPageGetChild, libs, "adw_status_page_get_child") | |
| 554 | + | core.PuregoSafeRegister(&xStatusPageGetDescription, libs, "adw_status_page_get_description") | |
| 555 | + | core.PuregoSafeRegister(&xStatusPageGetIconName, libs, "adw_status_page_get_icon_name") | |
| 556 | + | core.PuregoSafeRegister(&xStatusPageGetPaintable, libs, "adw_status_page_get_paintable") | |
| 557 | + | core.PuregoSafeRegister(&xStatusPageGetTitle, libs, "adw_status_page_get_title") | |
| 558 | + | core.PuregoSafeRegister(&xStatusPageSetChild, libs, "adw_status_page_set_child") | |
| 559 | + | core.PuregoSafeRegister(&xStatusPageSetDescription, libs, "adw_status_page_set_description") | |
| 560 | + | core.PuregoSafeRegister(&xStatusPageSetIconName, libs, "adw_status_page_set_icon_name") | |
| 561 | + | core.PuregoSafeRegister(&xStatusPageSetPaintable, libs, "adw_status_page_set_paintable") | |
| 562 | + | core.PuregoSafeRegister(&xStatusPageSetTitle, libs, "adw_status_page_set_title") | |
| 559 | 563 | } | |
| @@ -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/gdk" | 10 | "github.com/bnema/puregotk/v4/gdk" | ||
| 10 | "github.com/bnema/puregotk/v4/gobject" | 11 | "github.com/bnema/puregotk/v4/gobject" | ||
| @@ -70,7 +71,6 @@ type StatusPage struct { | |||||
| 70 | var xStatusPageGLibType func() types.GType | 71 | var xStatusPageGLibType func() types.GType | ||
| 71 | 72 | ||||
| 72 | func StatusPageGLibType() types.GType { | 73 | func StatusPageGLibType() types.GType { | ||
| 73 | - | core.LazyRegister(&xStatusPageGLibType, "ADW", "adw_status_page_get_type", false) | |||
| 74 | return xStatusPageGLibType() | 74 | return xStatusPageGLibType() | ||
| 75 | } | 75 | } | ||
| 76 | 76 | ||||
| @@ -84,7 +84,6 @@ var xNewStatusPage func() uintptr | |||||
| 84 | 84 | ||||
| 85 | // Creates a new `AdwStatusPage`. | 85 | // Creates a new `AdwStatusPage`. | ||
| 86 | func NewStatusPage() *StatusPage { | 86 | func NewStatusPage() *StatusPage { | ||
| 87 | - | core.LazyRegister(&xNewStatusPage, "ADW", "adw_status_page_new", false) | |||
| 88 | var cls *StatusPage | 87 | var cls *StatusPage | ||
| 89 | 88 | ||||
| 90 | cret := xNewStatusPage() | 89 | cret := xNewStatusPage() | ||
| @@ -102,7 +101,6 @@ var xStatusPageGetChild func(uintptr) uintptr | |||||
| 102 | 101 | ||||
| 103 | // Gets the child widget of @self. | 102 | // Gets the child widget of @self. | ||
| 104 | func (x *StatusPage) GetChild() *gtk.Widget { | 103 | func (x *StatusPage) GetChild() *gtk.Widget { | ||
| 105 | - | core.LazyRegister(&xStatusPageGetChild, "ADW", "adw_status_page_get_child", false) | |||
| 106 | var cls *gtk.Widget | 104 | var cls *gtk.Widget | ||
| 107 | 105 | ||||
| 108 | cret := xStatusPageGetChild(x.GoPointer()) | 106 | cret := xStatusPageGetChild(x.GoPointer()) | ||
| @@ -120,8 +118,6 @@ var xStatusPageGetDescription func(uintptr) string | |||||
| 120 | 118 | ||||
| 121 | // Gets the description markup for @self. | 119 | // Gets the description markup for @self. | ||
| 122 | func (x *StatusPage) GetDescription() string { | 120 | func (x *StatusPage) GetDescription() string { | ||
| 123 | - | core.LazyRegister(&xStatusPageGetDescription, "ADW", "adw_status_page_get_description", false) | |||
| 124 | - | ||||
| 125 | cret := xStatusPageGetDescription(x.GoPointer()) | 121 | cret := xStatusPageGetDescription(x.GoPointer()) | ||
| 126 | return cret | 122 | return cret | ||
| 127 | } | 123 | } | ||
| @@ -130,8 +126,6 @@ var xStatusPageGetIconName func(uintptr) string | |||||
| 130 | 126 | ||||
| 131 | // Gets the icon name for @self. | 127 | // Gets the icon name for @self. | ||
| 132 | func (x *StatusPage) GetIconName() string { | 128 | func (x *StatusPage) GetIconName() string { | ||
| 133 | - | core.LazyRegister(&xStatusPageGetIconName, "ADW", "adw_status_page_get_icon_name", false) | |||
| 134 | - | ||||
| 135 | cret := xStatusPageGetIconName(x.GoPointer()) | 129 | cret := xStatusPageGetIconName(x.GoPointer()) | ||
| 136 | return cret | 130 | return cret | ||
| 137 | } | 131 | } | ||
| @@ -140,7 +134,6 @@ var xStatusPageGetPaintable func(uintptr) uintptr | |||||
| 140 | 134 | ||||
| 141 | // Gets the paintable for @self. | 135 | // Gets the paintable for @self. | ||
| 142 | func (x *StatusPage) GetPaintable() *gdk.PaintableBase { | 136 | func (x *StatusPage) GetPaintable() *gdk.PaintableBase { | ||
| 143 | - | core.LazyRegister(&xStatusPageGetPaintable, "ADW", "adw_status_page_get_paintable", false) | |||
| 144 | var cls *gdk.PaintableBase | 137 | var cls *gdk.PaintableBase | ||
| 145 | 138 | ||||
| 146 | cret := xStatusPageGetPaintable(x.GoPointer()) | 139 | cret := xStatusPageGetPaintable(x.GoPointer()) | ||
| @@ -158,8 +151,6 @@ var xStatusPageGetTitle func(uintptr) string | |||||
| 158 | 151 | ||||
| 159 | // Gets the title for @self. | 152 | // Gets the title for @self. | ||
| 160 | func (x *StatusPage) GetTitle() string { | 153 | func (x *StatusPage) GetTitle() string { | ||
| 161 | - | core.LazyRegister(&xStatusPageGetTitle, "ADW", "adw_status_page_get_title", false) | |||
| 162 | - | ||||
| 163 | cret := xStatusPageGetTitle(x.GoPointer()) | 154 | cret := xStatusPageGetTitle(x.GoPointer()) | ||
| 164 | return cret | 155 | return cret | ||
| 165 | } | 156 | } | ||
| @@ -168,8 +159,6 @@ var xStatusPageSetChild func(uintptr, uintptr) | |||||
| 168 | 159 | ||||
| 169 | // Sets the child widget of @self. | 160 | // Sets the child widget of @self. | ||
| 170 | func (x *StatusPage) SetChild(ChildVar *gtk.Widget) { | 161 | func (x *StatusPage) SetChild(ChildVar *gtk.Widget) { | ||
| 171 | - | core.LazyRegister(&xStatusPageSetChild, "ADW", "adw_status_page_set_child", false) | |||
| 172 | - | ||||
| 173 | xStatusPageSetChild(x.GoPointer(), ChildVar.GoPointer()) | 162 | xStatusPageSetChild(x.GoPointer(), ChildVar.GoPointer()) | ||
| 174 | } | 163 | } | ||
| 175 | 164 | ||||
| @@ -179,8 +168,6 @@ var xStatusPageSetDescription func(uintptr, uintptr) | |||||
| 179 | // | 168 | // | ||
| 180 | // The description is displayed below the title. It is parsed as Pango markup. | 169 | // The description is displayed below the title. It is parsed as Pango markup. | ||
| 181 | func (x *StatusPage) SetDescription(DescriptionVar *string) { | 170 | func (x *StatusPage) SetDescription(DescriptionVar *string) { | ||
| 182 | - | core.LazyRegister(&xStatusPageSetDescription, "ADW", "adw_status_page_set_description", false) | |||
| 183 | - | ||||
| 184 | DescriptionVarPtr := core.GStrdupNullable(DescriptionVar) | 171 | DescriptionVarPtr := core.GStrdupNullable(DescriptionVar) | ||
| 185 | defer core.GFreeNullable(DescriptionVarPtr) | 172 | defer core.GFreeNullable(DescriptionVarPtr) | ||
| 186 | 173 | ||||
| @@ -193,8 +180,6 @@ var xStatusPageSetIconName func(uintptr, uintptr) | |||||
| 193 | // | 180 | // | ||
| 194 | // Changing this will set [property@StatusPage:paintable] to `NULL`. | 181 | // Changing this will set [property@StatusPage:paintable] to `NULL`. | ||
| 195 | func (x *StatusPage) SetIconName(IconNameVar *string) { | 182 | func (x *StatusPage) SetIconName(IconNameVar *string) { | ||
| 196 | - | core.LazyRegister(&xStatusPageSetIconName, "ADW", "adw_status_page_set_icon_name", false) | |||
| 197 | - | ||||
| 198 | IconNameVarPtr := core.GStrdupNullable(IconNameVar) | 183 | IconNameVarPtr := core.GStrdupNullable(IconNameVar) | ||
| 199 | defer core.GFreeNullable(IconNameVarPtr) | 184 | defer core.GFreeNullable(IconNameVarPtr) | ||
| 200 | 185 | ||||
| @@ -207,8 +192,6 @@ var xStatusPageSetPaintable func(uintptr, uintptr) | |||||
| 207 | // | 192 | // | ||
| 208 | // Changing this will set [property@StatusPage:icon-name] to `NULL`. | 193 | // Changing this will set [property@StatusPage:icon-name] to `NULL`. | ||
| 209 | func (x *StatusPage) SetPaintable(PaintableVar gdk.Paintable) { | 194 | func (x *StatusPage) SetPaintable(PaintableVar gdk.Paintable) { | ||
| 210 | - | core.LazyRegister(&xStatusPageSetPaintable, "ADW", "adw_status_page_set_paintable", false) | |||
| 211 | - | ||||
| 212 | xStatusPageSetPaintable(x.GoPointer(), PaintableVar.GoPointer()) | 195 | xStatusPageSetPaintable(x.GoPointer(), PaintableVar.GoPointer()) | ||
| 213 | } | 196 | } | ||
| 214 | 197 | ||||
| @@ -218,8 +201,6 @@ var xStatusPageSetTitle func(uintptr, string) | |||||
| 218 | // | 201 | // | ||
| 219 | // The title is displayed below the icon. It is not parsed as Pango markup. | 202 | // The title is displayed below the icon. It is not parsed as Pango markup. | ||
| 220 | func (x *StatusPage) SetTitle(TitleVar string) { | 203 | func (x *StatusPage) SetTitle(TitleVar string) { | ||
| 221 | - | core.LazyRegister(&xStatusPageSetTitle, "ADW", "adw_status_page_set_title", false) | |||
| 222 | - | ||||
| 223 | xStatusPageSetTitle(x.GoPointer(), TitleVar) | 204 | xStatusPageSetTitle(x.GoPointer(), TitleVar) | ||
| 224 | } | 205 | } | ||
| 225 | 206 | ||||
| @@ -556,4 +537,27 @@ func (x *StatusPage) GetBuildableId() string { | |||||
| 556 | func init() { | 537 | func init() { | ||
| 557 | core.SetPackageName("ADW", "libadwaita-1") | 538 | core.SetPackageName("ADW", "libadwaita-1") | ||
| 558 | core.SetSharedLibraries("ADW", []string{"libadwaita-1.so.0", "libadwaita-1.0.dylib"}) | 539 | core.SetSharedLibraries("ADW", []string{"libadwaita-1.so.0", "libadwaita-1.0.dylib"}) | ||
| 540 | + | var libs []uintptr | |||
| 541 | + | for _, libPath := range core.GetPaths("ADW") { | |||
| 542 | + | lib, err := purego.Dlopen(libPath, purego.RTLD_NOW|purego.RTLD_GLOBAL) | |||
| 543 | + | if err != nil { | |||
| 544 | + | panic(err) | |||
| 545 | + | } | |||
| 546 | + | libs = append(libs, lib) | |||
| 547 | + | } | |||
| 548 | + | ||||
| 549 | + | core.PuregoSafeRegister(&xStatusPageGLibType, libs, "adw_status_page_get_type") | |||
| 550 | + | ||||
| 551 | + | core.PuregoSafeRegister(&xNewStatusPage, libs, "adw_status_page_new") | |||
| 552 | + | ||||
| 553 | + | core.PuregoSafeRegister(&xStatusPageGetChild, libs, "adw_status_page_get_child") | |||
| 554 | + | core.PuregoSafeRegister(&xStatusPageGetDescription, libs, "adw_status_page_get_description") | |||
| 555 | + | core.PuregoSafeRegister(&xStatusPageGetIconName, libs, "adw_status_page_get_icon_name") | |||
| 556 | + | core.PuregoSafeRegister(&xStatusPageGetPaintable, libs, "adw_status_page_get_paintable") | |||
| 557 | + | core.PuregoSafeRegister(&xStatusPageGetTitle, libs, "adw_status_page_get_title") | |||
| 558 | + | core.PuregoSafeRegister(&xStatusPageSetChild, libs, "adw_status_page_set_child") | |||
| 559 | + | core.PuregoSafeRegister(&xStatusPageSetDescription, libs, "adw_status_page_set_description") | |||
| 560 | + | core.PuregoSafeRegister(&xStatusPageSetIconName, libs, "adw_status_page_set_icon_name") | |||
| 561 | + | core.PuregoSafeRegister(&xStatusPageSetPaintable, libs, "adw_status_page_set_paintable") | |||
| 562 | + | core.PuregoSafeRegister(&xStatusPageSetTitle, libs, "adw_status_page_set_title") | |||
| 559 | } | 563 | } | ||