Merge pull request #344 from bnema/chore/upstream-foundations
chore(deps): integrate approved upstream foundations
921 files · +28709 -25527
M docs/first-presentation.md +5 -2
| @@ -46,5 +46,8 @@ labels. Set `DUMBER_MACHINE_GPU_PROFILE` to one of `generic-gpu`, | |||
| 46 | 46 | `integrated-gpu`, `discrete-gpu`, `hybrid-gpu`, `virtual-gpu`, or `unknown-gpu`; | |
| 47 | 47 | do not use a device model or other identifier. Publish only the seven reviewed | |
| 48 | 48 | JSON files to an external Gist. Raw logs and temporary XDG homes are removed and | |
| 49 | - | must not be published. A missing or incomplete timeline, non-DMABUF backend, or | |
| 50 | - | invalid run fails collection. | |
| 49 | + | must not be published. `metadata.json` derives the selected | |
| 50 | + | `github.com/bnema/purego-cef2gtk` pseudo-version and its full immutable Git | |
| 51 | + | origin hash from Go module metadata; branch selectors or missing origin metadata | |
| 52 | + | fail collection. A missing or incomplete timeline, non-DMABUF backend, or invalid | |
| 53 | + | run also fails collection. | |
| @@ -46,5 +46,8 @@ labels. Set `DUMBER_MACHINE_GPU_PROFILE` to one of `generic-gpu`, | |||||
| 46 | `integrated-gpu`, `discrete-gpu`, `hybrid-gpu`, `virtual-gpu`, or `unknown-gpu`; | 46 | `integrated-gpu`, `discrete-gpu`, `hybrid-gpu`, `virtual-gpu`, or `unknown-gpu`; | ||
| 47 | do not use a device model or other identifier. Publish only the seven reviewed | 47 | do not use a device model or other identifier. Publish only the seven reviewed | ||
| 48 | JSON files to an external Gist. Raw logs and temporary XDG homes are removed and | 48 | JSON files to an external Gist. Raw logs and temporary XDG homes are removed and | ||
| 49 | - | must not be published. A missing or incomplete timeline, non-DMABUF backend, or | 49 | + | must not be published. `metadata.json` derives the selected |
| 50 | - | invalid run fails collection. | 50 | + | `github.com/bnema/purego-cef2gtk` pseudo-version and its full immutable Git |
| 51 | + | origin hash from Go module metadata; branch selectors or missing origin metadata | |||
| 52 | + | fail collection. A missing or incomplete timeline, non-DMABUF backend, or invalid | |||
| 53 | + | run also fails collection. | |||
M go.mod +5 -5
| @@ -6,11 +6,11 @@ require ( | |||
| 6 | 6 | github.com/a-h/templ v0.3.1020 | |
| 7 | 7 | github.com/andybalholm/brotli v1.2.2 | |
| 8 | 8 | github.com/bnema/purego v0.11.0-bnema.4 | |
| 9 | - | github.com/bnema/purego-cef v0.13.3 | |
| 10 | - | github.com/bnema/purego-cef2gtk v0.8.4 | |
| 11 | - | github.com/bnema/purego-pipewire v0.1.4 | |
| 12 | - | github.com/bnema/purego-sqlite v0.1.3 | |
| 13 | - | github.com/bnema/puregotk v0.7.0 | |
| 9 | + | github.com/bnema/purego-cef v0.13.4-0.20260714140305-f0b7414af67e | |
| 10 | + | github.com/bnema/purego-cef2gtk v0.8.4-0.20260714160309-bbd397409ebe | |
| 11 | + | github.com/bnema/purego-pipewire v0.1.5-0.20260714124450-6504b9cdf02a | |
| 12 | + | github.com/bnema/purego-sqlite v0.1.4-0.20260714131321-3614fe683b9c | |
| 13 | + | github.com/bnema/puregotk v0.7.1-0.20260714170452-0b6b9b901234 | |
| 14 | 14 | github.com/charmbracelet/bubbles v1.0.0 | |
| 15 | 15 | github.com/charmbracelet/bubbletea v1.3.10 | |
| 16 | 16 | github.com/charmbracelet/lipgloss v1.1.0 | |
| @@ -6,11 +6,11 @@ require ( | |||||
| 6 | github.com/a-h/templ v0.3.1020 | 6 | github.com/a-h/templ v0.3.1020 | ||
| 7 | github.com/andybalholm/brotli v1.2.2 | 7 | github.com/andybalholm/brotli v1.2.2 | ||
| 8 | github.com/bnema/purego v0.11.0-bnema.4 | 8 | github.com/bnema/purego v0.11.0-bnema.4 | ||
| 9 | - | github.com/bnema/purego-cef v0.13.3 | 9 | + | github.com/bnema/purego-cef v0.13.4-0.20260714140305-f0b7414af67e |
| 10 | - | github.com/bnema/purego-cef2gtk v0.8.4 | 10 | + | github.com/bnema/purego-cef2gtk v0.8.4-0.20260714160309-bbd397409ebe |
| 11 | - | github.com/bnema/purego-pipewire v0.1.4 | 11 | + | github.com/bnema/purego-pipewire v0.1.5-0.20260714124450-6504b9cdf02a |
| 12 | - | github.com/bnema/purego-sqlite v0.1.3 | 12 | + | github.com/bnema/purego-sqlite v0.1.4-0.20260714131321-3614fe683b9c |
| 13 | - | github.com/bnema/puregotk v0.7.0 | 13 | + | github.com/bnema/puregotk v0.7.1-0.20260714170452-0b6b9b901234 |
| 14 | github.com/charmbracelet/bubbles v1.0.0 | 14 | github.com/charmbracelet/bubbles v1.0.0 | ||
| 15 | github.com/charmbracelet/bubbletea v1.3.10 | 15 | github.com/charmbracelet/bubbletea v1.3.10 | ||
| 16 | github.com/charmbracelet/lipgloss v1.1.0 | 16 | github.com/charmbracelet/lipgloss v1.1.0 | ||
M go.sum +12 -0 generated file: collapsed
A internal/infrastructure/persistence/sqlite/history_repo_benchmark_test.go +71 -0
| @@ -0,0 +1,71 @@ | |||
| 1 | + | package sqlite_test | |
| 2 | + | ||
| 3 | + | import ( | |
| 4 | + | "fmt" | |
| 5 | + | "path/filepath" | |
| 6 | + | "testing" | |
| 7 | + | ||
| 8 | + | "github.com/bnema/dumber/internal/domain/entity" | |
| 9 | + | "github.com/bnema/dumber/internal/domain/repository" | |
| 10 | + | "github.com/bnema/dumber/internal/infrastructure/persistence/sqlite" | |
| 11 | + | ) | |
| 12 | + | ||
| 13 | + | // newHistoryBenchmarkRepository creates a representative local history corpus | |
| 14 | + | // outside the measured operation. Sidebar reads use GetRecent and omnibox | |
| 15 | + | // history suggestions use Search. | |
| 16 | + | func newHistoryBenchmarkRepository(b *testing.B) (repository.HistoryRepository, func()) { | |
| 17 | + | b.Helper() | |
| 18 | + | ||
| 19 | + | ctx := historyTestCtx() | |
| 20 | + | db, err := sqlite.NewConnection(ctx, filepath.Join(b.TempDir(), "dumber.db")) | |
| 21 | + | if err != nil { | |
| 22 | + | b.Fatal(err) | |
| 23 | + | } | |
| 24 | + | ||
| 25 | + | b.Cleanup(func() { | |
| 26 | + | if err := db.Close(); err != nil { | |
| 27 | + | b.Errorf("close benchmark database: %v", err) | |
| 28 | + | } | |
| 29 | + | }) | |
| 30 | + | ||
| 31 | + | repo := sqlite.NewHistoryRepository(db) | |
| 32 | + | for i := range 200 { | |
| 33 | + | entry := &entity.HistoryEntry{ | |
| 34 | + | URL: fmt.Sprintf("https://example%d.test/dumber/history/%d", i%20, i), | |
| 35 | + | Title: fmt.Sprintf("Dumber history entry %d", i), | |
| 36 | + | } | |
| 37 | + | if err := repo.Save(ctx, entry); err != nil { | |
| 38 | + | b.Fatal(err) | |
| 39 | + | } | |
| 40 | + | } | |
| 41 | + | ||
| 42 | + | return repo, func() {} | |
| 43 | + | } | |
| 44 | + | ||
| 45 | + | func BenchmarkHistorySQLiteSidebarRecent(b *testing.B) { | |
| 46 | + | repo, closeDB := newHistoryBenchmarkRepository(b) | |
| 47 | + | defer closeDB() | |
| 48 | + | ctx := historyTestCtx() | |
| 49 | + | ||
| 50 | + | b.ReportAllocs() | |
| 51 | + | b.ResetTimer() | |
| 52 | + | for range b.N { | |
| 53 | + | if _, err := repo.GetRecent(ctx, 50, 0); err != nil { | |
| 54 | + | b.Fatal(err) | |
| 55 | + | } | |
| 56 | + | } | |
| 57 | + | } | |
| 58 | + | ||
| 59 | + | func BenchmarkHistorySQLiteOmniboxSearch(b *testing.B) { | |
| 60 | + | repo, closeDB := newHistoryBenchmarkRepository(b) | |
| 61 | + | defer closeDB() | |
| 62 | + | ctx := historyTestCtx() | |
| 63 | + | ||
| 64 | + | b.ReportAllocs() | |
| 65 | + | b.ResetTimer() | |
| 66 | + | for range b.N { | |
| 67 | + | if _, err := repo.Search(ctx, "dumber history", 10); err != nil { | |
| 68 | + | b.Fatal(err) | |
| 69 | + | } | |
| 70 | + | } | |
| 71 | + | } | |
| @@ -0,0 +1,71 @@ | |||||
| 1 | + | package sqlite_test | |||
| 2 | + | ||||
| 3 | + | import ( | |||
| 4 | + | "fmt" | |||
| 5 | + | "path/filepath" | |||
| 6 | + | "testing" | |||
| 7 | + | ||||
| 8 | + | "github.com/bnema/dumber/internal/domain/entity" | |||
| 9 | + | "github.com/bnema/dumber/internal/domain/repository" | |||
| 10 | + | "github.com/bnema/dumber/internal/infrastructure/persistence/sqlite" | |||
| 11 | + | ) | |||
| 12 | + | ||||
| 13 | + | // newHistoryBenchmarkRepository creates a representative local history corpus | |||
| 14 | + | // outside the measured operation. Sidebar reads use GetRecent and omnibox | |||
| 15 | + | // history suggestions use Search. | |||
| 16 | + | func newHistoryBenchmarkRepository(b *testing.B) (repository.HistoryRepository, func()) { | |||
| 17 | + | b.Helper() | |||
| 18 | + | ||||
| 19 | + | ctx := historyTestCtx() | |||
| 20 | + | db, err := sqlite.NewConnection(ctx, filepath.Join(b.TempDir(), "dumber.db")) | |||
| 21 | + | if err != nil { | |||
| 22 | + | b.Fatal(err) | |||
| 23 | + | } | |||
| 24 | + | ||||
| 25 | + | b.Cleanup(func() { | |||
| 26 | + | if err := db.Close(); err != nil { | |||
| 27 | + | b.Errorf("close benchmark database: %v", err) | |||
| 28 | + | } | |||
| 29 | + | }) | |||
| 30 | + | ||||
| 31 | + | repo := sqlite.NewHistoryRepository(db) | |||
| 32 | + | for i := range 200 { | |||
| 33 | + | entry := &entity.HistoryEntry{ | |||
| 34 | + | URL: fmt.Sprintf("https://example%d.test/dumber/history/%d", i%20, i), | |||
| 35 | + | Title: fmt.Sprintf("Dumber history entry %d", i), | |||
| 36 | + | } | |||
| 37 | + | if err := repo.Save(ctx, entry); err != nil { | |||
| 38 | + | b.Fatal(err) | |||
| 39 | + | } | |||
| 40 | + | } | |||
| 41 | + | ||||
| 42 | + | return repo, func() {} | |||
| 43 | + | } | |||
| 44 | + | ||||
| 45 | + | func BenchmarkHistorySQLiteSidebarRecent(b *testing.B) { | |||
| 46 | + | repo, closeDB := newHistoryBenchmarkRepository(b) | |||
| 47 | + | defer closeDB() | |||
| 48 | + | ctx := historyTestCtx() | |||
| 49 | + | ||||
| 50 | + | b.ReportAllocs() | |||
| 51 | + | b.ResetTimer() | |||
| 52 | + | for range b.N { | |||
| 53 | + | if _, err := repo.GetRecent(ctx, 50, 0); err != nil { | |||
| 54 | + | b.Fatal(err) | |||
| 55 | + | } | |||
| 56 | + | } | |||
| 57 | + | } | |||
| 58 | + | ||||
| 59 | + | func BenchmarkHistorySQLiteOmniboxSearch(b *testing.B) { | |||
| 60 | + | repo, closeDB := newHistoryBenchmarkRepository(b) | |||
| 61 | + | defer closeDB() | |||
| 62 | + | ctx := historyTestCtx() | |||
| 63 | + | ||||
| 64 | + | b.ReportAllocs() | |||
| 65 | + | b.ResetTimer() | |||
| 66 | + | for range b.N { | |||
| 67 | + | if _, err := repo.Search(ctx, "dumber history", 10); err != nil { | |||
| 68 | + | b.Fatal(err) | |||
| 69 | + | } | |||
| 70 | + | } | |||
| 71 | + | } | |||
M internal/logging/first_presentation_collector_test.go +132 -1
| @@ -2,6 +2,7 @@ package logging | |||
| 2 | 2 | ||
| 3 | 3 | import ( | |
| 4 | 4 | "encoding/json" | |
| 5 | + | "fmt" | |
| 5 | 6 | "os" | |
| 6 | 7 | "os/exec" | |
| 7 | 8 | "path/filepath" | |
| @@ -143,8 +144,9 @@ func TestFirstPresentationCollectorSanitizesMachineLocalValues(t *testing.T) { | |||
| 143 | 144 | } | |
| 144 | 145 | for _, required := range []string{ | |
| 145 | 146 | `"measured_source_revision"`, | |
| 147 | + | `"version": "v0.8.4-0.20260714160309-bbd397409ebe"`, | |
| 146 | 148 | `"tag": "v0.8.4"`, | |
| 147 | - | `"revision": "f217ece342dea3ef2a3f98671fcd16a39ad0037d"`, | |
| 149 | + | `"revision": "bbd397409ebed75a5979c1e4566a2ef319f6a484"`, | |
| 148 | 150 | } { | |
| 149 | 151 | require.Contains(t, artifacts.String(), required) | |
| 150 | 152 | } | |
| @@ -166,6 +168,135 @@ func TestFirstPresentationCollectorSanitizesMachineLocalValues(t *testing.T) { | |||
| 166 | 168 | require.Equal(t, "integrated-gpu", metadata.Comparison.MachineGPUProfile) | |
| 167 | 169 | } | |
| 168 | 170 | ||
| 171 | + | func TestFirstPresentationCollectorDerivesSelectedImmutableModuleProvenance(t *testing.T) { | |
| 172 | + | repoRoot, err := filepath.Abs(filepath.Join("..", "..")) | |
| 173 | + | require.NoError(t, err) | |
| 174 | + | temp := t.TempDir() | |
| 175 | + | runtime := filepath.Join(temp, "cef-147-runtime") | |
| 176 | + | require.NoError(t, os.Mkdir(runtime, 0o755)) | |
| 177 | + | binary := filepath.Join(temp, "dumber") | |
| 178 | + | require.NoError(t, os.WriteFile(binary, collectorTestBinary(validFirstPresentationLog), 0o755)) | |
| 179 | + | ||
| 180 | + | // This exact pseudo-version is deliberately newer than the former v0.8.4 | |
| 181 | + | // hardcode; the collector must report what the selected module says. | |
| 182 | + | const version = "v0.8.5-0.20300102030405-bbd397409ebe" | |
| 183 | + | const revision = "bbd397409ebed75a5979c1e4566a2ef319f6a484" | |
| 184 | + | goBin := collectorProvenanceGo(t, temp, version, revision, "") | |
| 185 | + | output := filepath.Join(temp, "artifacts") | |
| 186 | + | cmd := exec.Command(filepath.Join(repoRoot, "scripts", "collect_first_presentation.sh")) | |
| 187 | + | cmd.Dir = repoRoot | |
| 188 | + | cmd.Env = append(os.Environ(), | |
| 189 | + | "DISPLAY=:test", | |
| 190 | + | "DUMBER_CEF_DIR="+runtime, | |
| 191 | + | "DUMBER_FIRST_PRESENTATION_BIN="+binary, | |
| 192 | + | "DUMBER_FIRST_PRESENTATION_OUTPUT="+output, | |
| 193 | + | "DUMBER_FIRST_PRESENTATION_TIMEOUT_SECONDS=1", | |
| 194 | + | "PATH="+filepath.Dir(goBin)+":"+os.Getenv("PATH"), | |
| 195 | + | ) | |
| 196 | + | result, err := cmd.CombinedOutput() | |
| 197 | + | require.NoErrorf(t, err, "collector failed: %s", result) | |
| 198 | + | ||
| 199 | + | var metadata struct { | |
| 200 | + | Upstream struct { | |
| 201 | + | Module string `json:"module"` | |
| 202 | + | Version string `json:"version"` | |
| 203 | + | Tag string `json:"tag"` | |
| 204 | + | Revision string `json:"revision"` | |
| 205 | + | } `json:"upstream"` | |
| 206 | + | } | |
| 207 | + | contents, err := os.ReadFile(filepath.Join(output, "metadata.json")) | |
| 208 | + | require.NoError(t, err) | |
| 209 | + | require.NoError(t, json.Unmarshal(contents, &metadata)) | |
| 210 | + | require.Equal(t, "github.com/bnema/purego-cef2gtk", metadata.Upstream.Module) | |
| 211 | + | require.Equal(t, version, metadata.Upstream.Version) | |
| 212 | + | require.Equal(t, "v0.8.5", metadata.Upstream.Tag) | |
| 213 | + | require.Equal(t, revision, metadata.Upstream.Revision) | |
| 214 | + | ||
| 215 | + | script, err := os.ReadFile(filepath.Join(repoRoot, "scripts", "collect_first_presentation.sh")) | |
| 216 | + | require.NoError(t, err) | |
| 217 | + | require.NotContains(t, string(script), "f217ece342dea3ef2a3f98671fcd16a39ad0037d") | |
| 218 | + | } | |
| 219 | + | ||
| 220 | + | func TestFirstPresentationCollectorRejectsNonImmutableModuleProvenanceWithoutLeaks(t *testing.T) { | |
| 221 | + | repoRoot, err := filepath.Abs(filepath.Join("..", "..")) | |
| 222 | + | require.NoError(t, err) | |
| 223 | + | ||
| 224 | + | for _, test := range []struct { | |
| 225 | + | name, version, revision, ref string | |
| 226 | + | }{ | |
| 227 | + | {name: "branch selector", version: "main", ref: "main"}, | |
| 228 | + | {name: "missing origin", version: "v0.8.5-0.20300102030405-bbd397409ebe"}, | |
| 229 | + | {name: "named origin ref", version: "v0.8.5-0.20300102030405-bbd397409ebe", revision: "bbd397409ebed75a5979c1e4566a2ef319f6a484", ref: "main"}, | |
| 230 | + | } { | |
| 231 | + | t.Run(test.name, func(t *testing.T) { | |
| 232 | + | temp := t.TempDir() | |
| 233 | + | runtime := filepath.Join(temp, "cef-147-runtime") | |
| 234 | + | require.NoError(t, os.Mkdir(runtime, 0o755)) | |
| 235 | + | binary := filepath.Join(temp, "dumber") | |
| 236 | + | require.NoError(t, os.WriteFile(binary, collectorTestBinary(validFirstPresentationLog), 0o755)) | |
| 237 | + | ||
| 238 | + | goBin := collectorProvenanceGo(t, temp, test.version, test.revision, test.ref) | |
| 239 | + | output := filepath.Join(temp, "artifacts") | |
| 240 | + | cmd := exec.Command(filepath.Join(repoRoot, "scripts", "collect_first_presentation.sh")) | |
| 241 | + | cmd.Dir = repoRoot | |
| 242 | + | cmd.Env = append(os.Environ(), | |
| 243 | + | "DISPLAY=:test", | |
| 244 | + | "DUMBER_CEF_DIR="+runtime, | |
| 245 | + | "DUMBER_FIRST_PRESENTATION_BIN="+binary, | |
| 246 | + | "DUMBER_FIRST_PRESENTATION_OUTPUT="+output, | |
| 247 | + | "PATH="+filepath.Dir(goBin)+":"+os.Getenv("PATH"), | |
| 248 | + | ) | |
| 249 | + | result, runErr := cmd.CombinedOutput() | |
| 250 | + | require.Errorf(t, runErr, "collector accepted nonimmutable module provenance: %s", result) | |
| 251 | + | require.Contains(t, string(result), "immutable module provenance is unavailable") | |
| 252 | + | require.NotContains(t, string(result), temp) | |
| 253 | + | require.NoFileExists(t, filepath.Join(output, "metadata.json")) | |
| 254 | + | for _, name := range runArtifactNames() { | |
| 255 | + | require.NoFileExists(t, filepath.Join(output, name)) | |
| 256 | + | } | |
| 257 | + | }) | |
| 258 | + | } | |
| 259 | + | } | |
| 260 | + | ||
| 261 | + | func collectorProvenanceGo(t *testing.T, temp, version, revision, ref string) string { | |
| 262 | + | t.Helper() | |
| 263 | + | infoPath := filepath.Join(temp, "module.info") | |
| 264 | + | info := map[string]any{"Version": version} | |
| 265 | + | if revision != "" { | |
| 266 | + | info["Origin"] = map[string]string{ | |
| 267 | + | "VCS": "git", "URL": "https://github.com/bnema/purego-cef2gtk", "Hash": revision, "Ref": ref, | |
| 268 | + | } | |
| 269 | + | } | |
| 270 | + | infoJSON, err := json.Marshal(info) | |
| 271 | + | require.NoError(t, err) | |
| 272 | + | require.NoError(t, os.WriteFile(infoPath, infoJSON, 0o600)) | |
| 273 | + | ||
| 274 | + | selectedJSON, err := json.Marshal(map[string]string{ | |
| 275 | + | "Path": "github.com/bnema/purego-cef2gtk", "Version": version, | |
| 276 | + | }) | |
| 277 | + | require.NoError(t, err) | |
| 278 | + | downloadedJSON, err := json.Marshal(map[string]string{ | |
| 279 | + | "Path": "github.com/bnema/purego-cef2gtk", "Version": version, "Info": infoPath, | |
| 280 | + | }) | |
| 281 | + | require.NoError(t, err) | |
| 282 | + | binDir := filepath.Join(temp, "bin") | |
| 283 | + | require.NoError(t, os.Mkdir(binDir, 0o755)) | |
| 284 | + | goBin := filepath.Join(binDir, "go") | |
| 285 | + | script := fmt.Sprintf(`#!/bin/sh | |
| 286 | + | if [ "$1" = "list" ] && [ "$2" = "-m" ] && [ "$3" = "-json" ] && [ "$4" = "github.com/bnema/purego-cef2gtk" ]; then | |
| 287 | + | printf '%%s\n' '%s' | |
| 288 | + | exit 0 | |
| 289 | + | fi | |
| 290 | + | if [ "$1" = "mod" ] && [ "$2" = "download" ] && [ "$3" = "-json" ] && [ "$4" = "github.com/bnema/purego-cef2gtk@%s" ]; then | |
| 291 | + | printf '%%s\n' '%s' | |
| 292 | + | exit 0 | |
| 293 | + | fi | |
| 294 | + | exit 1 | |
| 295 | + | `, selectedJSON, version, downloadedJSON) | |
| 296 | + | require.NoError(t, os.WriteFile(goBin, []byte(script), 0o755)) | |
| 297 | + | return goBin | |
| 298 | + | } | |
| 299 | + | ||
| 169 | 300 | func TestFirstPresentationCollectorDefaultsToXDGStateEvidenceDirectory(t *testing.T) { | |
| 170 | 301 | repoRoot, err := filepath.Abs(filepath.Join("..", "..")) | |
| 171 | 302 | require.NoError(t, err) | |
| @@ -2,6 +2,7 @@ package logging | |||||
| 2 | 2 | ||||
| 3 | import ( | 3 | import ( | ||
| 4 | "encoding/json" | 4 | "encoding/json" | ||
| 5 | + | "fmt" | |||
| 5 | "os" | 6 | "os" | ||
| 6 | "os/exec" | 7 | "os/exec" | ||
| 7 | "path/filepath" | 8 | "path/filepath" | ||
| @@ -143,8 +144,9 @@ func TestFirstPresentationCollectorSanitizesMachineLocalValues(t *testing.T) { | |||||
| 143 | } | 144 | } | ||
| 144 | for _, required := range []string{ | 145 | for _, required := range []string{ | ||
| 145 | `"measured_source_revision"`, | 146 | `"measured_source_revision"`, | ||
| 147 | + | `"version": "v0.8.4-0.20260714160309-bbd397409ebe"`, | |||
| 146 | `"tag": "v0.8.4"`, | 148 | `"tag": "v0.8.4"`, | ||
| 147 | - | `"revision": "f217ece342dea3ef2a3f98671fcd16a39ad0037d"`, | 149 | + | `"revision": "bbd397409ebed75a5979c1e4566a2ef319f6a484"`, |
| 148 | } { | 150 | } { | ||
| 149 | require.Contains(t, artifacts.String(), required) | 151 | require.Contains(t, artifacts.String(), required) | ||
| 150 | } | 152 | } | ||
| @@ -166,6 +168,135 @@ func TestFirstPresentationCollectorSanitizesMachineLocalValues(t *testing.T) { | |||||
| 166 | require.Equal(t, "integrated-gpu", metadata.Comparison.MachineGPUProfile) | 168 | require.Equal(t, "integrated-gpu", metadata.Comparison.MachineGPUProfile) | ||
| 167 | } | 169 | } | ||
| 168 | 170 | ||||
| 171 | + | func TestFirstPresentationCollectorDerivesSelectedImmutableModuleProvenance(t *testing.T) { | |||
| 172 | + | repoRoot, err := filepath.Abs(filepath.Join("..", "..")) | |||
| 173 | + | require.NoError(t, err) | |||
| 174 | + | temp := t.TempDir() | |||
| 175 | + | runtime := filepath.Join(temp, "cef-147-runtime") | |||
| 176 | + | require.NoError(t, os.Mkdir(runtime, 0o755)) | |||
| 177 | + | binary := filepath.Join(temp, "dumber") | |||
| 178 | + | require.NoError(t, os.WriteFile(binary, collectorTestBinary(validFirstPresentationLog), 0o755)) | |||
| 179 | + | ||||
| 180 | + | // This exact pseudo-version is deliberately newer than the former v0.8.4 | |||
| 181 | + | // hardcode; the collector must report what the selected module says. | |||
| 182 | + | const version = "v0.8.5-0.20300102030405-bbd397409ebe" | |||
| 183 | + | const revision = "bbd397409ebed75a5979c1e4566a2ef319f6a484" | |||
| 184 | + | goBin := collectorProvenanceGo(t, temp, version, revision, "") | |||
| 185 | + | output := filepath.Join(temp, "artifacts") | |||
| 186 | + | cmd := exec.Command(filepath.Join(repoRoot, "scripts", "collect_first_presentation.sh")) | |||
| 187 | + | cmd.Dir = repoRoot | |||
| 188 | + | cmd.Env = append(os.Environ(), | |||
| 189 | + | "DISPLAY=:test", | |||
| 190 | + | "DUMBER_CEF_DIR="+runtime, | |||
| 191 | + | "DUMBER_FIRST_PRESENTATION_BIN="+binary, | |||
| 192 | + | "DUMBER_FIRST_PRESENTATION_OUTPUT="+output, | |||
| 193 | + | "DUMBER_FIRST_PRESENTATION_TIMEOUT_SECONDS=1", | |||
| 194 | + | "PATH="+filepath.Dir(goBin)+":"+os.Getenv("PATH"), | |||
| 195 | + | ) | |||
| 196 | + | result, err := cmd.CombinedOutput() | |||
| 197 | + | require.NoErrorf(t, err, "collector failed: %s", result) | |||
| 198 | + | ||||
| 199 | + | var metadata struct { | |||
| 200 | + | Upstream struct { | |||
| 201 | + | Module string `json:"module"` | |||
| 202 | + | Version string `json:"version"` | |||
| 203 | + | Tag string `json:"tag"` | |||
| 204 | + | Revision string `json:"revision"` | |||
| 205 | + | } `json:"upstream"` | |||
| 206 | + | } | |||
| 207 | + | contents, err := os.ReadFile(filepath.Join(output, "metadata.json")) | |||
| 208 | + | require.NoError(t, err) | |||
| 209 | + | require.NoError(t, json.Unmarshal(contents, &metadata)) | |||
| 210 | + | require.Equal(t, "github.com/bnema/purego-cef2gtk", metadata.Upstream.Module) | |||
| 211 | + | require.Equal(t, version, metadata.Upstream.Version) | |||
| 212 | + | require.Equal(t, "v0.8.5", metadata.Upstream.Tag) | |||
| 213 | + | require.Equal(t, revision, metadata.Upstream.Revision) | |||
| 214 | + | ||||
| 215 | + | script, err := os.ReadFile(filepath.Join(repoRoot, "scripts", "collect_first_presentation.sh")) | |||
| 216 | + | require.NoError(t, err) | |||
| 217 | + | require.NotContains(t, string(script), "f217ece342dea3ef2a3f98671fcd16a39ad0037d") | |||
| 218 | + | } | |||
| 219 | + | ||||
| 220 | + | func TestFirstPresentationCollectorRejectsNonImmutableModuleProvenanceWithoutLeaks(t *testing.T) { | |||
| 221 | + | repoRoot, err := filepath.Abs(filepath.Join("..", "..")) | |||
| 222 | + | require.NoError(t, err) | |||
| 223 | + | ||||
| 224 | + | for _, test := range []struct { | |||
| 225 | + | name, version, revision, ref string | |||
| 226 | + | }{ | |||
| 227 | + | {name: "branch selector", version: "main", ref: "main"}, | |||
| 228 | + | {name: "missing origin", version: "v0.8.5-0.20300102030405-bbd397409ebe"}, | |||
| 229 | + | {name: "named origin ref", version: "v0.8.5-0.20300102030405-bbd397409ebe", revision: "bbd397409ebed75a5979c1e4566a2ef319f6a484", ref: "main"}, | |||
| 230 | + | } { | |||
| 231 | + | t.Run(test.name, func(t *testing.T) { | |||
| 232 | + | temp := t.TempDir() | |||
| 233 | + | runtime := filepath.Join(temp, "cef-147-runtime") | |||
| 234 | + | require.NoError(t, os.Mkdir(runtime, 0o755)) | |||
| 235 | + | binary := filepath.Join(temp, "dumber") | |||
| 236 | + | require.NoError(t, os.WriteFile(binary, collectorTestBinary(validFirstPresentationLog), 0o755)) | |||
| 237 | + | ||||
| 238 | + | goBin := collectorProvenanceGo(t, temp, test.version, test.revision, test.ref) | |||
| 239 | + | output := filepath.Join(temp, "artifacts") | |||
| 240 | + | cmd := exec.Command(filepath.Join(repoRoot, "scripts", "collect_first_presentation.sh")) | |||
| 241 | + | cmd.Dir = repoRoot | |||
| 242 | + | cmd.Env = append(os.Environ(), | |||
| 243 | + | "DISPLAY=:test", | |||
| 244 | + | "DUMBER_CEF_DIR="+runtime, | |||
| 245 | + | "DUMBER_FIRST_PRESENTATION_BIN="+binary, | |||
| 246 | + | "DUMBER_FIRST_PRESENTATION_OUTPUT="+output, | |||
| 247 | + | "PATH="+filepath.Dir(goBin)+":"+os.Getenv("PATH"), | |||
| 248 | + | ) | |||
| 249 | + | result, runErr := cmd.CombinedOutput() | |||
| 250 | + | require.Errorf(t, runErr, "collector accepted nonimmutable module provenance: %s", result) | |||
| 251 | + | require.Contains(t, string(result), "immutable module provenance is unavailable") | |||
| 252 | + | require.NotContains(t, string(result), temp) | |||
| 253 | + | require.NoFileExists(t, filepath.Join(output, "metadata.json")) | |||
| 254 | + | for _, name := range runArtifactNames() { | |||
| 255 | + | require.NoFileExists(t, filepath.Join(output, name)) | |||
| 256 | + | } | |||
| 257 | + | }) | |||
| 258 | + | } | |||
| 259 | + | } | |||
| 260 | + | ||||
| 261 | + | func collectorProvenanceGo(t *testing.T, temp, version, revision, ref string) string { | |||
| 262 | + | t.Helper() | |||
| 263 | + | infoPath := filepath.Join(temp, "module.info") | |||
| 264 | + | info := map[string]any{"Version": version} | |||
| 265 | + | if revision != "" { | |||
| 266 | + | info["Origin"] = map[string]string{ | |||
| 267 | + | "VCS": "git", "URL": "https://github.com/bnema/purego-cef2gtk", "Hash": revision, "Ref": ref, | |||
| 268 | + | } | |||
| 269 | + | } | |||
| 270 | + | infoJSON, err := json.Marshal(info) | |||
| 271 | + | require.NoError(t, err) | |||
| 272 | + | require.NoError(t, os.WriteFile(infoPath, infoJSON, 0o600)) | |||
| 273 | + | ||||
| 274 | + | selectedJSON, err := json.Marshal(map[string]string{ | |||
| 275 | + | "Path": "github.com/bnema/purego-cef2gtk", "Version": version, | |||
| 276 | + | }) | |||
| 277 | + | require.NoError(t, err) | |||
| 278 | + | downloadedJSON, err := json.Marshal(map[string]string{ | |||
| 279 | + | "Path": "github.com/bnema/purego-cef2gtk", "Version": version, "Info": infoPath, | |||
| 280 | + | }) | |||
| 281 | + | require.NoError(t, err) | |||
| 282 | + | binDir := filepath.Join(temp, "bin") | |||
| 283 | + | require.NoError(t, os.Mkdir(binDir, 0o755)) | |||
| 284 | + | goBin := filepath.Join(binDir, "go") | |||
| 285 | + | script := fmt.Sprintf(`#!/bin/sh | |||
| 286 | + | if [ "$1" = "list" ] && [ "$2" = "-m" ] && [ "$3" = "-json" ] && [ "$4" = "github.com/bnema/purego-cef2gtk" ]; then | |||
| 287 | + | printf '%%s\n' '%s' | |||
| 288 | + | exit 0 | |||
| 289 | + | fi | |||
| 290 | + | if [ "$1" = "mod" ] && [ "$2" = "download" ] && [ "$3" = "-json" ] && [ "$4" = "github.com/bnema/purego-cef2gtk@%s" ]; then | |||
| 291 | + | printf '%%s\n' '%s' | |||
| 292 | + | exit 0 | |||
| 293 | + | fi | |||
| 294 | + | exit 1 | |||
| 295 | + | `, selectedJSON, version, downloadedJSON) | |||
| 296 | + | require.NoError(t, os.WriteFile(goBin, []byte(script), 0o755)) | |||
| 297 | + | return goBin | |||
| 298 | + | } | |||
| 299 | + | ||||
| 169 | func TestFirstPresentationCollectorDefaultsToXDGStateEvidenceDirectory(t *testing.T) { | 300 | func TestFirstPresentationCollectorDefaultsToXDGStateEvidenceDirectory(t *testing.T) { | ||
| 170 | repoRoot, err := filepath.Abs(filepath.Join("..", "..")) | 301 | repoRoot, err := filepath.Abs(filepath.Join("..", "..")) | ||
| 171 | require.NoError(t, err) | 302 | require.NoError(t, err) | ||
M scripts/collect_first_presentation.sh +78 -9
| @@ -31,8 +31,78 @@ else | |||
| 31 | 31 | fi | |
| 32 | 32 | readonly output | |
| 33 | 33 | readonly upstream_module="github.com/bnema/purego-cef2gtk" | |
| 34 | - | readonly upstream_tag="v0.8.4" | |
| 35 | - | readonly upstream_revision="f217ece342dea3ef2a3f98671fcd16a39ad0037d" | |
| 34 | + | ||
| 35 | + | # Resolve the version selected by this checkout, then obtain its immutable VCS | |
| 36 | + | # origin from Go's cached module metadata. Do not infer a revision from a tag, | |
| 37 | + | # a branch, or a truncated pseudo-version suffix. | |
| 38 | + | resolve_upstream_provenance() { | |
| 39 | + | local selected_metadata selected_version downloaded_metadata | |
| 40 | + | ||
| 41 | + | selected_metadata="$(go list -m -json "$upstream_module" 2>/dev/null)" || { | |
| 42 | + | echo "first-presentation: immutable module provenance is unavailable" >&2 | |
| 43 | + | exit 2 | |
| 44 | + | } | |
| 45 | + | selected_version="$(python3 - "$upstream_module" "$selected_metadata" <<'PY' | |
| 46 | + | import json, sys | |
| 47 | + | try: | |
| 48 | + | metadata = json.loads(sys.argv[2]) | |
| 49 | + | if metadata.get("Path") != sys.argv[1] or not isinstance(metadata.get("Version"), str): | |
| 50 | + | raise ValueError | |
| 51 | + | print(metadata["Version"]) | |
| 52 | + | except (AttributeError, TypeError, ValueError, json.JSONDecodeError): | |
| 53 | + | raise SystemExit("first-presentation: immutable module provenance is unavailable") | |
| 54 | + | PY | |
| 55 | + | )" || exit $? | |
| 56 | + | downloaded_metadata="$(go mod download -json "$upstream_module@$selected_version" 2>/dev/null)" || { | |
| 57 | + | echo "first-presentation: immutable module provenance is unavailable" >&2 | |
| 58 | + | exit 2 | |
| 59 | + | } | |
| 60 | + | ||
| 61 | + | python3 - "$upstream_module" "$selected_metadata" "$downloaded_metadata" <<'PY' | |
| 62 | + | import json, re, sys | |
| 63 | + | ||
| 64 | + | module, selected_raw, downloaded_raw = sys.argv[1:] | |
| 65 | + | ||
| 66 | + | def fail(): | |
| 67 | + | # Do not expose Go cache locations or other machine-local values. | |
| 68 | + | raise SystemExit("first-presentation: immutable module provenance is unavailable") | |
| 69 | + | ||
| 70 | + | try: | |
| 71 | + | selected = json.loads(selected_raw) | |
| 72 | + | downloaded = json.loads(downloaded_raw) | |
| 73 | + | version = selected["Version"] | |
| 74 | + | if selected.get("Path") != module or downloaded.get("Path") != module: | |
| 75 | + | fail() | |
| 76 | + | if downloaded.get("Version") != version: | |
| 77 | + | fail() | |
| 78 | + | # A selected pseudo-version is an exact immutable selector, never a branch. | |
| 79 | + | match = re.fullmatch(r"(v\d+\.\d+\.\d+)-0\.\d{14}-([0-9a-f]{12})", version) | |
| 80 | + | if not match: | |
| 81 | + | fail() | |
| 82 | + | info_path = downloaded.get("Info") | |
| 83 | + | if not isinstance(info_path, str) or not info_path: | |
| 84 | + | fail() | |
| 85 | + | with open(info_path, encoding="utf-8") as info_file: | |
| 86 | + | info = json.load(info_file) | |
| 87 | + | origin = info.get("Origin") or downloaded.get("Origin") | |
| 88 | + | if info.get("Version") != version or not isinstance(origin, dict): | |
| 89 | + | fail() | |
| 90 | + | revision = origin.get("Hash") | |
| 91 | + | if origin.get("VCS") != "git" or origin.get("URL") != "https://github.com/bnema/purego-cef2gtk": | |
| 92 | + | fail() | |
| 93 | + | if not isinstance(revision, str) or not re.fullmatch(r"[0-9a-f]{40}", revision): | |
| 94 | + | fail() | |
| 95 | + | if not revision.startswith(match.group(2)): | |
| 96 | + | fail() | |
| 97 | + | # A named ref can move. Only the immutable hash itself is acceptable. | |
| 98 | + | if origin.get("Ref") not in (None, "", revision): | |
| 99 | + | fail() | |
| 100 | + | except (AttributeError, KeyError, OSError, TypeError, ValueError, json.JSONDecodeError): | |
| 101 | + | fail() | |
| 102 | + | ||
| 103 | + | print("\t".join((version, match.group(1), revision))) | |
| 104 | + | PY | |
| 105 | + | } | |
| 36 | 106 | ||
| 37 | 107 | # The artifact destination is caller-controlled. Never empty or recursively | |
| 38 | 108 | # clear it: collection only writes to a newly-created directory whose parent is | |
| @@ -66,10 +136,9 @@ prepare_output | |||
| 66 | 136 | [[ -x "$binary" ]] || { echo "first-presentation: executable not found: $binary" >&2; exit 2; } | |
| 67 | 137 | [[ -d "$runtime" ]] || { echo "first-presentation: CEF runtime not found: $runtime" >&2; exit 2; } | |
| 68 | 138 | [[ -n "${WAYLAND_DISPLAY:-}${DISPLAY:-}" ]] || { echo "first-presentation: a current Wayland/X11 display is required" >&2; exit 2; } | |
| 69 | - | [[ "$(go list -m -f '{{.Version}}' "$upstream_module")" == "$upstream_tag" ]] || { | |
| 70 | - | echo "first-presentation: expected $upstream_module@$upstream_tag" >&2 | |
| 71 | - | exit 2 | |
| 72 | - | } | |
| 139 | + | upstream_provenance="$(resolve_upstream_provenance)" || exit $? | |
| 140 | + | IFS=$'\t' read -r upstream_version upstream_tag upstream_revision <<<"$upstream_provenance" | |
| 141 | + | readonly upstream_version upstream_tag upstream_revision | |
| 73 | 142 | ||
| 74 | 143 | # Raw logs and temporary XDG homes may contain machine-local paths. Keep them | |
| 75 | 144 | # outside the committed artifact directory and always remove them. | |
| @@ -80,9 +149,9 @@ cleanup_work_root() { | |||
| 80 | 149 | rm -rf -- "$work_root" | |
| 81 | 150 | } | |
| 82 | 151 | trap cleanup_work_root EXIT | |
| 83 | - | python3 - "$output/metadata.json" "$binary" "$timeout_seconds" "$upstream_module" "$upstream_tag" "$upstream_revision" <<'PY' | |
| 152 | + | python3 - "$output/metadata.json" "$binary" "$timeout_seconds" "$upstream_module" "$upstream_version" "$upstream_tag" "$upstream_revision" <<'PY' | |
| 84 | 153 | import hashlib, json, os, platform, subprocess, sys | |
| 85 | - | path, binary, timeout, upstream_module, upstream_tag, upstream_revision = sys.argv[1:] | |
| 154 | + | path, binary, timeout, upstream_module, upstream_version, upstream_tag, upstream_revision = sys.argv[1:] | |
| 86 | 155 | with open(binary, "rb") as candidate: | |
| 87 | 156 | binary_sha256 = hashlib.file_digest(candidate, "sha256").hexdigest() | |
| 88 | 157 | ||
| @@ -102,7 +171,7 @@ json.dump({ | |||
| 102 | 171 | "binary": {"label": "dumber", "sha256": binary_sha256}, | |
| 103 | 172 | "timeout_seconds": int(timeout), | |
| 104 | 173 | "measured_source_revision": subprocess.check_output(["git", "-c", f"safe.directory={os.getcwd()}", "rev-parse", "HEAD"], text=True).strip(), | |
| 105 | - | "upstream": {"module": upstream_module, "tag": upstream_tag, "revision": upstream_revision}, | |
| 174 | + | "upstream": {"module": upstream_module, "version": upstream_version, "tag": upstream_tag, "revision": upstream_revision}, | |
| 106 | 175 | "comparison": {"os": os_label, "architecture": architecture, "display_protocol": display_protocol, "machine_gpu_profile": gpu_profile}, | |
| 107 | 176 | "render_configuration": {"backend": "gdk-dmabuf", "buffer_sharing": "dmabuf", "renderer": "vulkan"} | |
| 108 | 177 | }, open(path, "w"), indent=2, sort_keys=True) | |
| @@ -31,8 +31,78 @@ else | |||||
| 31 | fi | 31 | fi | ||
| 32 | readonly output | 32 | readonly output | ||
| 33 | readonly upstream_module="github.com/bnema/purego-cef2gtk" | 33 | readonly upstream_module="github.com/bnema/purego-cef2gtk" | ||
| 34 | - | readonly upstream_tag="v0.8.4" | 34 | + | |
| 35 | - | readonly upstream_revision="f217ece342dea3ef2a3f98671fcd16a39ad0037d" | 35 | + | # Resolve the version selected by this checkout, then obtain its immutable VCS |
| 36 | + | # origin from Go's cached module metadata. Do not infer a revision from a tag, | |||
| 37 | + | # a branch, or a truncated pseudo-version suffix. | |||
| 38 | + | resolve_upstream_provenance() { | |||
| 39 | + | local selected_metadata selected_version downloaded_metadata | |||
| 40 | + | ||||
| 41 | + | selected_metadata="$(go list -m -json "$upstream_module" 2>/dev/null)" || { | |||
| 42 | + | echo "first-presentation: immutable module provenance is unavailable" >&2 | |||
| 43 | + | exit 2 | |||
| 44 | + | } | |||
| 45 | + | selected_version="$(python3 - "$upstream_module" "$selected_metadata" <<'PY' | |||
| 46 | + | import json, sys | |||
| 47 | + | try: | |||
| 48 | + | metadata = json.loads(sys.argv[2]) | |||
| 49 | + | if metadata.get("Path") != sys.argv[1] or not isinstance(metadata.get("Version"), str): | |||
| 50 | + | raise ValueError | |||
| 51 | + | print(metadata["Version"]) | |||
| 52 | + | except (AttributeError, TypeError, ValueError, json.JSONDecodeError): | |||
| 53 | + | raise SystemExit("first-presentation: immutable module provenance is unavailable") | |||
| 54 | + | PY | |||
| 55 | + | )" || exit $? | |||
| 56 | + | downloaded_metadata="$(go mod download -json "$upstream_module@$selected_version" 2>/dev/null)" || { | |||
| 57 | + | echo "first-presentation: immutable module provenance is unavailable" >&2 | |||
| 58 | + | exit 2 | |||
| 59 | + | } | |||
| 60 | + | ||||
| 61 | + | python3 - "$upstream_module" "$selected_metadata" "$downloaded_metadata" <<'PY' | |||
| 62 | + | import json, re, sys | |||
| 63 | + | ||||
| 64 | + | module, selected_raw, downloaded_raw = sys.argv[1:] | |||
| 65 | + | ||||
| 66 | + | def fail(): | |||
| 67 | + | # Do not expose Go cache locations or other machine-local values. | |||
| 68 | + | raise SystemExit("first-presentation: immutable module provenance is unavailable") | |||
| 69 | + | ||||
| 70 | + | try: | |||
| 71 | + | selected = json.loads(selected_raw) | |||
| 72 | + | downloaded = json.loads(downloaded_raw) | |||
| 73 | + | version = selected["Version"] | |||
| 74 | + | if selected.get("Path") != module or downloaded.get("Path") != module: | |||
| 75 | + | fail() | |||
| 76 | + | if downloaded.get("Version") != version: | |||
| 77 | + | fail() | |||
| 78 | + | # A selected pseudo-version is an exact immutable selector, never a branch. | |||
| 79 | + | match = re.fullmatch(r"(v\d+\.\d+\.\d+)-0\.\d{14}-([0-9a-f]{12})", version) | |||
| 80 | + | if not match: | |||
| 81 | + | fail() | |||
| 82 | + | info_path = downloaded.get("Info") | |||
| 83 | + | if not isinstance(info_path, str) or not info_path: | |||
| 84 | + | fail() | |||
| 85 | + | with open(info_path, encoding="utf-8") as info_file: | |||
| 86 | + | info = json.load(info_file) | |||
| 87 | + | origin = info.get("Origin") or downloaded.get("Origin") | |||
| 88 | + | if info.get("Version") != version or not isinstance(origin, dict): | |||
| 89 | + | fail() | |||
| 90 | + | revision = origin.get("Hash") | |||
| 91 | + | if origin.get("VCS") != "git" or origin.get("URL") != "https://github.com/bnema/purego-cef2gtk": | |||
| 92 | + | fail() | |||
| 93 | + | if not isinstance(revision, str) or not re.fullmatch(r"[0-9a-f]{40}", revision): | |||
| 94 | + | fail() | |||
| 95 | + | if not revision.startswith(match.group(2)): | |||
| 96 | + | fail() | |||
| 97 | + | # A named ref can move. Only the immutable hash itself is acceptable. | |||
| 98 | + | if origin.get("Ref") not in (None, "", revision): | |||
| 99 | + | fail() | |||
| 100 | + | except (AttributeError, KeyError, OSError, TypeError, ValueError, json.JSONDecodeError): | |||
| 101 | + | fail() | |||
| 102 | + | ||||
| 103 | + | print("\t".join((version, match.group(1), revision))) | |||
| 104 | + | PY | |||
| 105 | + | } | |||
| 36 | 106 | ||||
| 37 | # The artifact destination is caller-controlled. Never empty or recursively | 107 | # The artifact destination is caller-controlled. Never empty or recursively | ||
| 38 | # clear it: collection only writes to a newly-created directory whose parent is | 108 | # clear it: collection only writes to a newly-created directory whose parent is | ||
| @@ -66,10 +136,9 @@ prepare_output | |||||
| 66 | [[ -x "$binary" ]] || { echo "first-presentation: executable not found: $binary" >&2; exit 2; } | 136 | [[ -x "$binary" ]] || { echo "first-presentation: executable not found: $binary" >&2; exit 2; } | ||
| 67 | [[ -d "$runtime" ]] || { echo "first-presentation: CEF runtime not found: $runtime" >&2; exit 2; } | 137 | [[ -d "$runtime" ]] || { echo "first-presentation: CEF runtime not found: $runtime" >&2; exit 2; } | ||
| 68 | [[ -n "${WAYLAND_DISPLAY:-}${DISPLAY:-}" ]] || { echo "first-presentation: a current Wayland/X11 display is required" >&2; exit 2; } | 138 | [[ -n "${WAYLAND_DISPLAY:-}${DISPLAY:-}" ]] || { echo "first-presentation: a current Wayland/X11 display is required" >&2; exit 2; } | ||
| 69 | - | [[ "$(go list -m -f '{{.Version}}' "$upstream_module")" == "$upstream_tag" ]] || { | 139 | + | upstream_provenance="$(resolve_upstream_provenance)" || exit $? |
| 70 | - | echo "first-presentation: expected $upstream_module@$upstream_tag" >&2 | 140 | + | IFS=$'\t' read -r upstream_version upstream_tag upstream_revision <<<"$upstream_provenance" |
| 71 | - | exit 2 | 141 | + | readonly upstream_version upstream_tag upstream_revision |
| 72 | - | } | |||
| 73 | 142 | ||||
| 74 | # Raw logs and temporary XDG homes may contain machine-local paths. Keep them | 143 | # Raw logs and temporary XDG homes may contain machine-local paths. Keep them | ||
| 75 | # outside the committed artifact directory and always remove them. | 144 | # outside the committed artifact directory and always remove them. | ||
| @@ -80,9 +149,9 @@ cleanup_work_root() { | |||||
| 80 | rm -rf -- "$work_root" | 149 | rm -rf -- "$work_root" | ||
| 81 | } | 150 | } | ||
| 82 | trap cleanup_work_root EXIT | 151 | trap cleanup_work_root EXIT | ||
| 83 | - | python3 - "$output/metadata.json" "$binary" "$timeout_seconds" "$upstream_module" "$upstream_tag" "$upstream_revision" <<'PY' | 152 | + | python3 - "$output/metadata.json" "$binary" "$timeout_seconds" "$upstream_module" "$upstream_version" "$upstream_tag" "$upstream_revision" <<'PY' |
| 84 | import hashlib, json, os, platform, subprocess, sys | 153 | import hashlib, json, os, platform, subprocess, sys | ||
| 85 | - | path, binary, timeout, upstream_module, upstream_tag, upstream_revision = sys.argv[1:] | 154 | + | path, binary, timeout, upstream_module, upstream_version, upstream_tag, upstream_revision = sys.argv[1:] |
| 86 | with open(binary, "rb") as candidate: | 155 | with open(binary, "rb") as candidate: | ||
| 87 | binary_sha256 = hashlib.file_digest(candidate, "sha256").hexdigest() | 156 | binary_sha256 = hashlib.file_digest(candidate, "sha256").hexdigest() | ||
| 88 | 157 | ||||
| @@ -102,7 +171,7 @@ json.dump({ | |||||
| 102 | "binary": {"label": "dumber", "sha256": binary_sha256}, | 171 | "binary": {"label": "dumber", "sha256": binary_sha256}, | ||
| 103 | "timeout_seconds": int(timeout), | 172 | "timeout_seconds": int(timeout), | ||
| 104 | "measured_source_revision": subprocess.check_output(["git", "-c", f"safe.directory={os.getcwd()}", "rev-parse", "HEAD"], text=True).strip(), | 173 | "measured_source_revision": subprocess.check_output(["git", "-c", f"safe.directory={os.getcwd()}", "rev-parse", "HEAD"], text=True).strip(), | ||
| 105 | - | "upstream": {"module": upstream_module, "tag": upstream_tag, "revision": upstream_revision}, | 174 | + | "upstream": {"module": upstream_module, "version": upstream_version, "tag": upstream_tag, "revision": upstream_revision}, |
| 106 | "comparison": {"os": os_label, "architecture": architecture, "display_protocol": display_protocol, "machine_gpu_profile": gpu_profile}, | 175 | "comparison": {"os": os_label, "architecture": architecture, "display_protocol": display_protocol, "machine_gpu_profile": gpu_profile}, | ||
| 107 | "render_configuration": {"backend": "gdk-dmabuf", "buffer_sharing": "dmabuf", "renderer": "vulkan"} | 176 | "render_configuration": {"backend": "gdk-dmabuf", "buffer_sharing": "dmabuf", "renderer": "vulkan"} | ||
| 108 | }, open(path, "w"), indent=2, sort_keys=True) | 177 | }, open(path, "w"), indent=2, sort_keys=True) | ||
M vendor/github.com/bnema/purego-cef/cef/bridge.go +8 -13 generated file: collapsed
M vendor/github.com/bnema/purego-cef2gtk/internal/cefadapter/accelerated_paint.go +34 -37 generated file: collapsed
M vendor/github.com/bnema/purego-cef2gtk/internal/dmabuf/frame.go +38 -19 generated file: collapsed
M vendor/github.com/bnema/purego-cef2gtk/internal/gtkgdk/renderer.go +89 -69 generated file: collapsed
M vendor/github.com/bnema/purego-pipewire/internal/core/player.go +5 -0 generated file: collapsed
M vendor/github.com/bnema/purego-pipewire/internal/core/player_rt.go +10 -6 generated file: collapsed
M vendor/github.com/bnema/purego-pipewire/internal/core/pwbuffer.go +66 -32 generated file: collapsed
M vendor/github.com/bnema/purego-sqlite/driver/driver.go +268 -63 generated file: collapsed
M vendor/github.com/bnema/purego-sqlite/internal/core/db.go +8 -0 generated file: collapsed
M vendor/github.com/bnema/purego-sqlite/internal/core/rows.go +13 -0 generated file: collapsed
M vendor/github.com/bnema/purego-sqlite/internal/loader/loader.go +23 -5 generated file: collapsed
M vendor/github.com/bnema/purego-sqlite/internal/ports/in/ports_gen.go +3 -0 generated file: collapsed
M vendor/github.com/bnema/puregotk/internal/core/core.go +197 -4 generated file: collapsed
M vendor/github.com/bnema/puregotk/pkg/core/core.go +10 -0 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-about-dialog.go +99 -64 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-about-window.go +95 -62 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-accent-color.go +7 -15 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-action-row.go +33 -29 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-alert-dialog.go +66 -47 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-animation-target.go +10 -27 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-animation-util.go +4 -12 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-animation.go +24 -26 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-application-window.go +14 -22 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-application.go +3 -15 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-avatar.go +22 -25 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-banner.go +23 -26 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-bin.go +5 -16 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-bottom-sheet.go +47 -38 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-breakpoint-bin.go +10 -19 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-breakpoint.go +33 -37 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-button-content.go +18 -22 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-button-row.go +10 -18 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-carousel-indicator-dots.go +5 -16 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-carousel-indicator-lines.go +5 -16 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-carousel.go +47 -37 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-clamp-layout.go +14 -20 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-clamp-scrollable.go +17 -22 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-clamp.go +17 -22 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-combo-row.go +34 -33 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-dialog.go +45 -38 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-easing.go +3 -13 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-entry-row.go +40 -33 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-enum-list-model.go +13 -22 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-expander-row.go +40 -33 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-flap.go +61 -48 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-fold-threshold-policy.go +10 -1 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-header-bar.go +36 -33 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-inline-view-switcher.go +18 -24 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-layout-slot.go +4 -15 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-layout.go +7 -17 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-leaflet.go +69 -56 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-length-unit.go +5 -14 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-main.go +5 -15 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-message-dialog.go +63 -44 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-multi-layout-view.go +17 -23 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-navigation-direction.go +10 -1 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-navigation-split-view.go +36 -32 generated file: collapsed
M vendor/github.com/bnema/puregotk/v4/adw/adw-navigation-view.go +60 -49
| @@ -186,6 +186,7 @@ type NavigationPage struct { | |||
| 186 | 186 | var xNavigationPageGLibType func() types.GType | |
| 187 | 187 | ||
| 188 | 188 | func NavigationPageGLibType() types.GType { | |
| 189 | + | core.LazyRegister(&xNavigationPageGLibType, "ADW", "adw_navigation_page_get_type", false) | |
| 189 | 190 | return xNavigationPageGLibType() | |
| 190 | 191 | } | |
| 191 | 192 | ||
| @@ -199,6 +200,7 @@ var xNewNavigationPage func(uintptr, string) uintptr | |||
| 199 | 200 | ||
| 200 | 201 | // Creates a new `AdwNavigationPage`. | |
| 201 | 202 | func NewNavigationPage(ChildVar *gtk.Widget, TitleVar string) *NavigationPage { | |
| 203 | + | core.LazyRegister(&xNewNavigationPage, "ADW", "adw_navigation_page_new", false) | |
| 202 | 204 | var cls *NavigationPage | |
| 203 | 205 | ||
| 204 | 206 | cret := xNewNavigationPage(ChildVar.GoPointer(), TitleVar) | |
| @@ -216,6 +218,7 @@ var xNewNavigationPageWithTag func(uintptr, string, string) uintptr | |||
| 216 | 218 | ||
| 217 | 219 | // Creates a new `AdwNavigationPage` with provided tag. | |
| 218 | 220 | func NewNavigationPageWithTag(ChildVar *gtk.Widget, TitleVar string, TagVar string) *NavigationPage { | |
| 221 | + | core.LazyRegister(&xNewNavigationPageWithTag, "ADW", "adw_navigation_page_new_with_tag", false) | |
| 219 | 222 | var cls *NavigationPage | |
| 220 | 223 | ||
| 221 | 224 | cret := xNewNavigationPageWithTag(ChildVar.GoPointer(), TitleVar, TagVar) | |
| @@ -233,6 +236,8 @@ var xNavigationPageGetCanPop func(uintptr) bool | |||
| 233 | 236 | ||
| 234 | 237 | // Gets whether @self can be popped from navigation stack. | |
| 235 | 238 | func (x *NavigationPage) GetCanPop() bool { | |
| 239 | + | core.LazyRegister(&xNavigationPageGetCanPop, "ADW", "adw_navigation_page_get_can_pop", false) | |
| 240 | + | ||
| 236 | 241 | cret := xNavigationPageGetCanPop(x.GoPointer()) | |
| 237 | 242 | return cret | |
| 238 | 243 | } | |
| @@ -241,6 +246,7 @@ var xNavigationPageGetChild func(uintptr) uintptr | |||
| 241 | 246 | ||
| 242 | 247 | // Gets the child widget of @self. | |
| 243 | 248 | func (x *NavigationPage) GetChild() *gtk.Widget { | |
| 249 | + | core.LazyRegister(&xNavigationPageGetChild, "ADW", "adw_navigation_page_get_child", false) | |
| 244 | 250 | var cls *gtk.Widget | |
| 245 | 251 | ||
| 246 | 252 | cret := xNavigationPageGetChild(x.GoPointer()) | |
| @@ -258,6 +264,8 @@ var xNavigationPageGetTag func(uintptr) string | |||
| 258 | 264 | ||
| 259 | 265 | // Gets the tag of @self. | |
| 260 | 266 | func (x *NavigationPage) GetTag() string { | |
| 267 | + | core.LazyRegister(&xNavigationPageGetTag, "ADW", "adw_navigation_page_get_tag", false) | |
| 268 | + | ||
| 261 | 269 | cret := xNavigationPageGetTag(x.GoPointer()) | |
| 262 | 270 | return cret | |
| 263 | 271 | } | |
| @@ -266,6 +274,8 @@ var xNavigationPageGetTitle func(uintptr) string | |||
| 266 | 274 | ||
| 267 | 275 | // Gets the title of @self. | |
| 268 | 276 | func (x *NavigationPage) GetTitle() string { | |
| 277 | + | core.LazyRegister(&xNavigationPageGetTitle, "ADW", "adw_navigation_page_get_title", false) | |
| 278 | + | ||
| 269 | 279 | cret := xNavigationPageGetTitle(x.GoPointer()) | |
| 270 | 280 | return cret | |
| 271 | 281 | } | |
| @@ -283,6 +293,8 @@ var xNavigationPageSetCanPop func(uintptr, bool) | |||
| 283 | 293 | // See [property@HeaderBar:show-back-button] for removing only the back button, | |
| 284 | 294 | // but not shortcuts. | |
| 285 | 295 | func (x *NavigationPage) SetCanPop(CanPopVar bool) { | |
| 296 | + | core.LazyRegister(&xNavigationPageSetCanPop, "ADW", "adw_navigation_page_set_can_pop", false) | |
| 297 | + | ||
| 286 | 298 | xNavigationPageSetCanPop(x.GoPointer(), CanPopVar) | |
| 287 | 299 | } | |
| 288 | 300 | ||
| @@ -290,6 +302,8 @@ var xNavigationPageSetChild func(uintptr, uintptr) | |||
| 290 | 302 | ||
| 291 | 303 | // Sets the child widget of @self. | |
| 292 | 304 | func (x *NavigationPage) SetChild(ChildVar *gtk.Widget) { | |
| 305 | + | core.LazyRegister(&xNavigationPageSetChild, "ADW", "adw_navigation_page_set_child", false) | |
| 306 | + | ||
| 293 | 307 | xNavigationPageSetChild(x.GoPointer(), ChildVar.GoPointer()) | |
| 294 | 308 | } | |
| 295 | 309 | ||
| @@ -306,6 +320,8 @@ var xNavigationPageSetTag func(uintptr, uintptr) | |||
| 306 | 320 | // | |
| 307 | 321 | // The tag also must be set to use the `navigation.push` action. | |
| 308 | 322 | func (x *NavigationPage) SetTag(TagVar *string) { | |
| 323 | + | core.LazyRegister(&xNavigationPageSetTag, "ADW", "adw_navigation_page_set_tag", false) | |
| 324 | + | ||
| 309 | 325 | TagVarPtr := core.GStrdupNullable(TagVar) | |
| 310 | 326 | defer core.GFreeNullable(TagVarPtr) | |
| 311 | 327 | ||
| @@ -319,6 +335,8 @@ var xNavigationPageSetTitle func(uintptr, string) | |||
| 319 | 335 | // It's displayed in [class@HeaderBar] instead of the window title, and used as | |
| 320 | 336 | // the tooltip on the next page's back button, as well as by screen reader. | |
| 321 | 337 | func (x *NavigationPage) SetTitle(TitleVar string) { | |
| 338 | + | core.LazyRegister(&xNavigationPageSetTitle, "ADW", "adw_navigation_page_set_title", false) | |
| 339 | + | ||
| 322 | 340 | xNavigationPageSetTitle(x.GoPointer(), TitleVar) | |
| 323 | 341 | } | |
| 324 | 342 | ||
| @@ -964,6 +982,7 @@ type NavigationView struct { | |||
| 964 | 982 | var xNavigationViewGLibType func() types.GType | |
| 965 | 983 | ||
| 966 | 984 | func NavigationViewGLibType() types.GType { | |
| 985 | + | core.LazyRegister(&xNavigationViewGLibType, "ADW", "adw_navigation_view_get_type", false) | |
| 967 | 986 | return xNavigationViewGLibType() | |
| 968 | 987 | } | |
| 969 | 988 | ||
| @@ -977,6 +996,7 @@ var xNewNavigationView func() uintptr | |||
| 977 | 996 | ||
| 978 | 997 | // Creates a new `AdwNavigationView`. | |
| 979 | 998 | func NewNavigationView() *NavigationView { | |
| 999 | + | core.LazyRegister(&xNewNavigationView, "ADW", "adw_navigation_view_new", false) | |
| 980 | 1000 | var cls *NavigationView | |
| 981 | 1001 | ||
| 982 | 1002 | cret := xNewNavigationView() | |
| @@ -1002,6 +1022,8 @@ var xNavigationViewAdd func(uintptr, uintptr) | |||
| 1002 | 1022 | // | |
| 1003 | 1023 | // See [method@NavigationView.remove]. | |
| 1004 | 1024 | func (x *NavigationView) Add(PageVar *NavigationPage) { | |
| 1025 | + | core.LazyRegister(&xNavigationViewAdd, "ADW", "adw_navigation_view_add", false) | |
| 1026 | + | ||
| 1005 | 1027 | xNavigationViewAdd(x.GoPointer(), PageVar.GoPointer()) | |
| 1006 | 1028 | } | |
| 1007 | 1029 | ||
| @@ -1011,6 +1033,7 @@ var xNavigationViewFindPage func(uintptr, string) uintptr | |||
| 1011 | 1033 | // | |
| 1012 | 1034 | // See [property@NavigationPage:tag]. | |
| 1013 | 1035 | func (x *NavigationView) FindPage(TagVar string) *NavigationPage { | |
| 1036 | + | core.LazyRegister(&xNavigationViewFindPage, "ADW", "adw_navigation_view_find_page", false) | |
| 1014 | 1037 | var cls *NavigationPage | |
| 1015 | 1038 | ||
| 1016 | 1039 | cret := xNavigationViewFindPage(x.GoPointer(), TagVar) | |
| @@ -1028,6 +1051,8 @@ var xNavigationViewGetAnimateTransitions func(uintptr) bool | |||
| 1028 | 1051 | ||
| 1029 | 1052 | // Gets whether @self animates page transitions. | |
| 1030 | 1053 | func (x *NavigationView) GetAnimateTransitions() bool { | |
| 1054 | + | core.LazyRegister(&xNavigationViewGetAnimateTransitions, "ADW", "adw_navigation_view_get_animate_transitions", false) | |
| 1055 | + | ||
| 1031 | 1056 | cret := xNavigationViewGetAnimateTransitions(x.GoPointer()) | |
| 1032 | 1057 | return cret | |
| 1033 | 1058 | } | |
| @@ -1036,6 +1061,8 @@ var xNavigationViewGetHhomogeneous func(uintptr) bool | |||
| 1036 | 1061 | ||
| 1037 | 1062 | // Gets whether @self is horizontally homogeneous. | |
| 1038 | 1063 | func (x *NavigationView) GetHhomogeneous() bool { | |
| 1064 | + | core.LazyRegister(&xNavigationViewGetHhomogeneous, "ADW", "adw_navigation_view_get_hhomogeneous", false) | |
| 1065 | + | ||
| 1039 | 1066 | cret := xNavigationViewGetHhomogeneous(x.GoPointer()) | |
| 1040 | 1067 | return cret | |
| 1041 | 1068 | } | |
| @@ -1048,6 +1075,7 @@ var xNavigationViewGetNavigationStack func(uintptr) uintptr | |||
| 1048 | 1075 | // | |
| 1049 | 1076 | // This can be used to keep an up-to-date view. | |
| 1050 | 1077 | func (x *NavigationView) GetNavigationStack() *gio.ListModelBase { | |
| 1078 | + | core.LazyRegister(&xNavigationViewGetNavigationStack, "ADW", "adw_navigation_view_get_navigation_stack", false) | |
| 1051 | 1079 | var cls *gio.ListModelBase | |
| 1052 | 1080 | ||
| 1053 | 1081 | cret := xNavigationViewGetNavigationStack(x.GoPointer()) | |
| @@ -1064,6 +1092,8 @@ var xNavigationViewGetPopOnEscape func(uintptr) bool | |||
| 1064 | 1092 | ||
| 1065 | 1093 | // Gets whether pressing Escape pops the current page on @self. | |
| 1066 | 1094 | func (x *NavigationView) GetPopOnEscape() bool { | |
| 1095 | + | core.LazyRegister(&xNavigationViewGetPopOnEscape, "ADW", "adw_navigation_view_get_pop_on_escape", false) | |
| 1096 | + | ||
| 1067 | 1097 | cret := xNavigationViewGetPopOnEscape(x.GoPointer()) | |
| 1068 | 1098 | return cret | |
| 1069 | 1099 | } | |
| @@ -1077,6 +1107,7 @@ var xNavigationViewGetPreviousPage func(uintptr, uintptr) uintptr | |||
| 1077 | 1107 | // | |
| 1078 | 1108 | // If @page is the root page or is not in the navigation stack, returns `NULL`. | |
| 1079 | 1109 | func (x *NavigationView) GetPreviousPage(PageVar *NavigationPage) *NavigationPage { | |
| 1110 | + | core.LazyRegister(&xNavigationViewGetPreviousPage, "ADW", "adw_navigation_view_get_previous_page", false) | |
| 1080 | 1111 | var cls *NavigationPage | |
| 1081 | 1112 | ||
| 1082 | 1113 | cret := xNavigationViewGetPreviousPage(x.GoPointer(), PageVar.GoPointer()) | |
| @@ -1094,6 +1125,8 @@ var xNavigationViewGetVhomogeneous func(uintptr) bool | |||
| 1094 | 1125 | ||
| 1095 | 1126 | // Gets whether @self is vertically homogeneous. | |
| 1096 | 1127 | func (x *NavigationView) GetVhomogeneous() bool { | |
| 1128 | + | core.LazyRegister(&xNavigationViewGetVhomogeneous, "ADW", "adw_navigation_view_get_vhomogeneous", false) | |
| 1129 | + | ||
| 1097 | 1130 | cret := xNavigationViewGetVhomogeneous(x.GoPointer()) | |
| 1098 | 1131 | return cret | |
| 1099 | 1132 | } | |
| @@ -1102,6 +1135,7 @@ var xNavigationViewGetVisiblePage func(uintptr) uintptr | |||
| 1102 | 1135 | ||
| 1103 | 1136 | // Gets the currently visible page in @self. | |
| 1104 | 1137 | func (x *NavigationView) GetVisiblePage() *NavigationPage { | |
| 1138 | + | core.LazyRegister(&xNavigationViewGetVisiblePage, "ADW", "adw_navigation_view_get_visible_page", false) | |
| 1105 | 1139 | var cls *NavigationPage | |
| 1106 | 1140 | ||
| 1107 | 1141 | cret := xNavigationViewGetVisiblePage(x.GoPointer()) | |
| @@ -1119,6 +1153,8 @@ var xNavigationViewGetVisiblePageTag func(uintptr) string | |||
| 1119 | 1153 | ||
| 1120 | 1154 | // Gets the tag of the currently visible page in @self. | |
| 1121 | 1155 | func (x *NavigationView) GetVisiblePageTag() string { | |
| 1156 | + | core.LazyRegister(&xNavigationViewGetVisiblePageTag, "ADW", "adw_navigation_view_get_visible_page_tag", false) | |
| 1157 | + | ||
| 1122 | 1158 | cret := xNavigationViewGetVisiblePageTag(x.GoPointer()) | |
| 1123 | 1159 | return cret | |
| 1124 | 1160 | } | |
| @@ -1137,6 +1173,8 @@ var xNavigationViewPop func(uintptr) bool | |||
| 1137 | 1173 | // See [method@NavigationView.pop_to_page] and | |
| 1138 | 1174 | // [method@NavigationView.pop_to_tag]. | |
| 1139 | 1175 | func (x *NavigationView) Pop() bool { | |
| 1176 | + | core.LazyRegister(&xNavigationViewPop, "ADW", "adw_navigation_view_pop", false) | |
| 1177 | + | ||
| 1140 | 1178 | cret := xNavigationViewPop(x.GoPointer()) | |
| 1141 | 1179 | return cret | |
| 1142 | 1180 | } | |
| @@ -1155,6 +1193,8 @@ var xNavigationViewPopToPage func(uintptr, uintptr) bool | |||
| 1155 | 1193 | // | |
| 1156 | 1194 | // See [method@NavigationView.pop] and [method@NavigationView.pop_to_tag]. | |
| 1157 | 1195 | func (x *NavigationView) PopToPage(PageVar *NavigationPage) bool { | |
| 1196 | + | core.LazyRegister(&xNavigationViewPopToPage, "ADW", "adw_navigation_view_pop_to_page", false) | |
| 1197 | + | ||
| 1158 | 1198 | cret := xNavigationViewPopToPage(x.GoPointer(), PageVar.GoPointer()) | |
| 1159 | 1199 | return cret | |
| 1160 | 1200 | } | |
| @@ -1172,6 +1212,8 @@ var xNavigationViewPopToTag func(uintptr, string) bool | |||
| 1172 | 1212 | // | |
| 1173 | 1213 | // See [method@NavigationView.pop_to_page] and [property@NavigationPage:tag]. | |
| 1174 | 1214 | func (x *NavigationView) PopToTag(TagVar string) bool { | |
| 1215 | + | core.LazyRegister(&xNavigationViewPopToTag, "ADW", "adw_navigation_view_pop_to_tag", false) | |
| 1216 | + | ||
| 1175 | 1217 | cret := xNavigationViewPopToTag(x.GoPointer(), TagVar) | |
| 1176 | 1218 | return cret | |
| 1177 | 1219 | } | |
| @@ -1187,6 +1229,8 @@ var xNavigationViewPush func(uintptr, uintptr) | |||
| 1187 | 1229 | // | |
| 1188 | 1230 | // See [method@NavigationView.push_by_tag]. | |
| 1189 | 1231 | func (x *NavigationView) Push(PageVar *NavigationPage) { | |
| 1232 | + | core.LazyRegister(&xNavigationViewPush, "ADW", "adw_navigation_view_push", false) | |
| 1233 | + | ||
| 1190 | 1234 | xNavigationViewPush(x.GoPointer(), PageVar.GoPointer()) | |
| 1191 | 1235 | } | |
| 1192 | 1236 | ||
| @@ -1201,6 +1245,8 @@ var xNavigationViewPushByTag func(uintptr, string) | |||
| 1201 | 1245 | // | |
| 1202 | 1246 | // See [method@NavigationView.push] and [property@NavigationPage:tag]. | |
| 1203 | 1247 | func (x *NavigationView) PushByTag(TagVar string) { | |
| 1248 | + | core.LazyRegister(&xNavigationViewPushByTag, "ADW", "adw_navigation_view_push_by_tag", false) | |
| 1249 | + | ||
| 1204 | 1250 | xNavigationViewPushByTag(x.GoPointer(), TagVar) | |
| 1205 | 1251 | } | |
| 1206 | 1252 | ||
| @@ -1213,6 +1259,8 @@ var xNavigationViewRemove func(uintptr, uintptr) | |||
| 1213 | 1259 | // | |
| 1214 | 1260 | // See [method@NavigationView.add]. | |
| 1215 | 1261 | func (x *NavigationView) Remove(PageVar *NavigationPage) { | |
| 1262 | + | core.LazyRegister(&xNavigationViewRemove, "ADW", "adw_navigation_view_remove", false) | |
| 1263 | + | ||
| 1216 | 1264 | xNavigationViewRemove(x.GoPointer(), PageVar.GoPointer()) | |
| 1217 | 1265 | } | |
| 1218 | 1266 | ||
| @@ -1234,6 +1282,8 @@ var xNavigationViewReplace func(uintptr, uintptr, int) | |||
| 1234 | 1282 | // | |
| 1235 | 1283 | // See [method@NavigationView.replace_with_tags]. | |
| 1236 | 1284 | func (x *NavigationView) Replace(PagesVar uintptr, NPagesVar int) { | |
| 1285 | + | core.LazyRegister(&xNavigationViewReplace, "ADW", "adw_navigation_view_replace", false) | |
| 1286 | + | ||
| 1237 | 1287 | xNavigationViewReplace(x.GoPointer(), PagesVar, NPagesVar) | |
| 1238 | 1288 | } | |
| 1239 | 1289 | ||
| @@ -1255,6 +1305,8 @@ var xNavigationViewReplaceWithTags func(uintptr, []string, int) | |||
| 1255 | 1305 | // | |
| 1256 | 1306 | // See [method@NavigationView.replace] and [property@NavigationPage:tag]. | |
| 1257 | 1307 | func (x *NavigationView) ReplaceWithTags(TagsVar []string, NTagsVar int) { | |
| 1308 | + | core.LazyRegister(&xNavigationViewReplaceWithTags, "ADW", "adw_navigation_view_replace_with_tags", false) | |
| 1309 | + | ||
| 1258 | 1310 | xNavigationViewReplaceWithTags(x.GoPointer(), TagsVar, NTagsVar) | |
| 1259 | 1311 | } | |
| 1260 | 1312 | ||
| @@ -1264,6 +1316,8 @@ var xNavigationViewSetAnimateTransitions func(uintptr, bool) | |||
| 1264 | 1316 | // | |
| 1265 | 1317 | // Gesture-based transitions are always animated. | |
| 1266 | 1318 | func (x *NavigationView) SetAnimateTransitions(AnimateTransitionsVar bool) { | |
| 1319 | + | core.LazyRegister(&xNavigationViewSetAnimateTransitions, "ADW", "adw_navigation_view_set_animate_transitions", false) | |
| 1320 | + | ||
| 1267 | 1321 | xNavigationViewSetAnimateTransitions(x.GoPointer(), AnimateTransitionsVar) | |
| 1268 | 1322 | } | |
| 1269 | 1323 | ||
| @@ -1276,6 +1330,8 @@ var xNavigationViewSetHhomogeneous func(uintptr, bool) | |||
| 1276 | 1330 | // | |
| 1277 | 1331 | // If it's not, the view may change width when a different page becomes visible. | |
| 1278 | 1332 | func (x *NavigationView) SetHhomogeneous(HhomogeneousVar bool) { | |
| 1333 | + | core.LazyRegister(&xNavigationViewSetHhomogeneous, "ADW", "adw_navigation_view_set_hhomogeneous", false) | |
| 1334 | + | ||
| 1279 | 1335 | xNavigationViewSetHhomogeneous(x.GoPointer(), HhomogeneousVar) | |
| 1280 | 1336 | } | |
| 1281 | 1337 | ||
| @@ -1286,6 +1342,8 @@ var xNavigationViewSetPopOnEscape func(uintptr, bool) | |||
| 1286 | 1342 | // Applications using `AdwNavigationView` to implement a browser may want to | |
| 1287 | 1343 | // disable it. | |
| 1288 | 1344 | func (x *NavigationView) SetPopOnEscape(PopOnEscapeVar bool) { | |
| 1345 | + | core.LazyRegister(&xNavigationViewSetPopOnEscape, "ADW", "adw_navigation_view_set_pop_on_escape", false) | |
| 1346 | + | ||
| 1289 | 1347 | xNavigationViewSetPopOnEscape(x.GoPointer(), PopOnEscapeVar) | |
| 1290 | 1348 | } | |
| 1291 | 1349 | ||
| @@ -1299,6 +1357,8 @@ var xNavigationViewSetVhomogeneous func(uintptr, bool) | |||
| 1299 | 1357 | // If it's not, the view may change height when a different page becomes | |
| 1300 | 1358 | // visible. | |
| 1301 | 1359 | func (x *NavigationView) SetVhomogeneous(VhomogeneousVar bool) { | |
| 1360 | + | core.LazyRegister(&xNavigationViewSetVhomogeneous, "ADW", "adw_navigation_view_set_vhomogeneous", false) | |
| 1361 | + | ||
| 1302 | 1362 | xNavigationViewSetVhomogeneous(x.GoPointer(), VhomogeneousVar) | |
| 1303 | 1363 | } | |
| 1304 | 1364 | ||
| @@ -1843,53 +1903,4 @@ func (x *NavigationView) GetBuildableId() string { | |||
| 1843 | 1903 | func init() { | |
| 1844 | 1904 | core.SetPackageName("ADW", "libadwaita-1") | |
| 1845 | 1905 | core.SetSharedLibraries("ADW", []string{"libadwaita-1.so.0", "libadwaita-1.0.dylib"}) | |
| 1846 | - | var libs []uintptr | |
| 1847 | - | for _, libPath := range core.GetPaths("ADW") { | |
| 1848 | - | lib, err := purego.Dlopen(libPath, purego.RTLD_NOW|purego.RTLD_GLOBAL) | |
| 1849 | - | if err != nil { | |
| 1850 | - | panic(err) | |
| 1851 | - | } | |
| 1852 | - | libs = append(libs, lib) | |
| 1853 | - | } | |
| 1854 | - | ||
| 1855 | - | core.PuregoSafeRegister(&xNavigationPageGLibType, libs, "adw_navigation_page_get_type") | |
| 1856 | - | ||
| 1857 | - | core.PuregoSafeRegister(&xNewNavigationPage, libs, "adw_navigation_page_new") | |
| 1858 | - | core.PuregoSafeRegister(&xNewNavigationPageWithTag, libs, "adw_navigation_page_new_with_tag") | |
| 1859 | - | ||
| 1860 | - | core.PuregoSafeRegister(&xNavigationPageGetCanPop, libs, "adw_navigation_page_get_can_pop") | |
| 1861 | - | core.PuregoSafeRegister(&xNavigationPageGetChild, libs, "adw_navigation_page_get_child") | |
| 1862 | - | core.PuregoSafeRegister(&xNavigationPageGetTag, libs, "adw_navigation_page_get_tag") | |
| 1863 | - | core.PuregoSafeRegister(&xNavigationPageGetTitle, libs, "adw_navigation_page_get_title") | |
| 1864 | - | core.PuregoSafeRegister(&xNavigationPageSetCanPop, libs, "adw_navigation_page_set_can_pop") | |
| 1865 | - | core.PuregoSafeRegister(&xNavigationPageSetChild, libs, "adw_navigation_page_set_child") | |
| 1866 | - | core.PuregoSafeRegister(&xNavigationPageSetTag, libs, "adw_navigation_page_set_tag") | |
| 1867 | - | core.PuregoSafeRegister(&xNavigationPageSetTitle, libs, "adw_navigation_page_set_title") | |
| 1868 | - | ||
| 1869 | - | core.PuregoSafeRegister(&xNavigationViewGLibType, libs, "adw_navigation_view_get_type") | |
| 1870 | - | ||
| 1871 | - | core.PuregoSafeRegister(&xNewNavigationView, libs, "adw_navigation_view_new") | |
| 1872 | - | ||
| 1873 | - | core.PuregoSafeRegister(&xNavigationViewAdd, libs, "adw_navigation_view_add") | |
| 1874 | - | core.PuregoSafeRegister(&xNavigationViewFindPage, libs, "adw_navigation_view_find_page") | |
| 1875 | - | core.PuregoSafeRegister(&xNavigationViewGetAnimateTransitions, libs, "adw_navigation_view_get_animate_transitions") | |
| 1876 | - | core.PuregoSafeRegister(&xNavigationViewGetHhomogeneous, libs, "adw_navigation_view_get_hhomogeneous") | |
| 1877 | - | core.PuregoSafeRegister(&xNavigationViewGetNavigationStack, libs, "adw_navigation_view_get_navigation_stack") | |
| 1878 | - | core.PuregoSafeRegister(&xNavigationViewGetPopOnEscape, libs, "adw_navigation_view_get_pop_on_escape") | |
| 1879 | - | core.PuregoSafeRegister(&xNavigationViewGetPreviousPage, libs, "adw_navigation_view_get_previous_page") | |
| 1880 | - | core.PuregoSafeRegister(&xNavigationViewGetVhomogeneous, libs, "adw_navigation_view_get_vhomogeneous") | |
| 1881 | - | core.PuregoSafeRegister(&xNavigationViewGetVisiblePage, libs, "adw_navigation_view_get_visible_page") | |
| 1882 | - | core.PuregoSafeRegister(&xNavigationViewGetVisiblePageTag, libs, "adw_navigation_view_get_visible_page_tag") | |
| 1883 | - | core.PuregoSafeRegister(&xNavigationViewPop, libs, "adw_navigation_view_pop") | |
| 1884 | - | core.PuregoSafeRegister(&xNavigationViewPopToPage, libs, "adw_navigation_view_pop_to_page") | |
| 1885 | - | core.PuregoSafeRegister(&xNavigationViewPopToTag, libs, "adw_navigation_view_pop_to_tag") | |
| 1886 | - | core.PuregoSafeRegister(&xNavigationViewPush, libs, "adw_navigation_view_push") | |
| 1887 | - | core.PuregoSafeRegister(&xNavigationViewPushByTag, libs, "adw_navigation_view_push_by_tag") | |
| 1888 | - | core.PuregoSafeRegister(&xNavigationViewRemove, libs, "adw_navigation_view_remove") | |
| 1889 | - | core.PuregoSafeRegister(&xNavigationViewReplace, libs, "adw_navigation_view_replace") | |
| 1890 | - | core.PuregoSafeRegister(&xNavigationViewReplaceWithTags, libs, "adw_navigation_view_replace_with_tags") | |
| 1891 | - | core.PuregoSafeRegister(&xNavigationViewSetAnimateTransitions, libs, "adw_navigation_view_set_animate_transitions") | |
| 1892 | - | core.PuregoSafeRegister(&xNavigationViewSetHhomogeneous, libs, "adw_navigation_view_set_hhomogeneous") | |
| 1893 | - | core.PuregoSafeRegister(&xNavigationViewSetPopOnEscape, libs, "adw_navigation_view_set_pop_on_escape") | |
| 1894 | - | core.PuregoSafeRegister(&xNavigationViewSetVhomogeneous, libs, "adw_navigation_view_set_vhomogeneous") | |
| 1895 | 1906 | } | |
| @@ -186,6 +186,7 @@ type NavigationPage struct { | |||||
| 186 | var xNavigationPageGLibType func() types.GType | 186 | var xNavigationPageGLibType func() types.GType | ||
| 187 | 187 | ||||
| 188 | func NavigationPageGLibType() types.GType { | 188 | func NavigationPageGLibType() types.GType { | ||
| 189 | + | core.LazyRegister(&xNavigationPageGLibType, "ADW", "adw_navigation_page_get_type", false) | |||
| 189 | return xNavigationPageGLibType() | 190 | return xNavigationPageGLibType() | ||
| 190 | } | 191 | } | ||
| 191 | 192 | ||||
| @@ -199,6 +200,7 @@ var xNewNavigationPage func(uintptr, string) uintptr | |||||
| 199 | 200 | ||||
| 200 | // Creates a new `AdwNavigationPage`. | 201 | // Creates a new `AdwNavigationPage`. | ||
| 201 | func NewNavigationPage(ChildVar *gtk.Widget, TitleVar string) *NavigationPage { | 202 | func NewNavigationPage(ChildVar *gtk.Widget, TitleVar string) *NavigationPage { | ||
| 203 | + | core.LazyRegister(&xNewNavigationPage, "ADW", "adw_navigation_page_new", false) | |||
| 202 | var cls *NavigationPage | 204 | var cls *NavigationPage | ||
| 203 | 205 | ||||
| 204 | cret := xNewNavigationPage(ChildVar.GoPointer(), TitleVar) | 206 | cret := xNewNavigationPage(ChildVar.GoPointer(), TitleVar) | ||
| @@ -216,6 +218,7 @@ var xNewNavigationPageWithTag func(uintptr, string, string) uintptr | |||||
| 216 | 218 | ||||
| 217 | // Creates a new `AdwNavigationPage` with provided tag. | 219 | // Creates a new `AdwNavigationPage` with provided tag. | ||
| 218 | func NewNavigationPageWithTag(ChildVar *gtk.Widget, TitleVar string, TagVar string) *NavigationPage { | 220 | func NewNavigationPageWithTag(ChildVar *gtk.Widget, TitleVar string, TagVar string) *NavigationPage { | ||
| 221 | + | core.LazyRegister(&xNewNavigationPageWithTag, "ADW", "adw_navigation_page_new_with_tag", false) | |||
| 219 | var cls *NavigationPage | 222 | var cls *NavigationPage | ||
| 220 | 223 | ||||
| 221 | cret := xNewNavigationPageWithTag(ChildVar.GoPointer(), TitleVar, TagVar) | 224 | cret := xNewNavigationPageWithTag(ChildVar.GoPointer(), TitleVar, TagVar) | ||
| @@ -233,6 +236,8 @@ var xNavigationPageGetCanPop func(uintptr) bool | |||||
| 233 | 236 | ||||
| 234 | // Gets whether @self can be popped from navigation stack. | 237 | // Gets whether @self can be popped from navigation stack. | ||
| 235 | func (x *NavigationPage) GetCanPop() bool { | 238 | func (x *NavigationPage) GetCanPop() bool { | ||
| 239 | + | core.LazyRegister(&xNavigationPageGetCanPop, "ADW", "adw_navigation_page_get_can_pop", false) | |||
| 240 | + | ||||
| 236 | cret := xNavigationPageGetCanPop(x.GoPointer()) | 241 | cret := xNavigationPageGetCanPop(x.GoPointer()) | ||
| 237 | return cret | 242 | return cret | ||
| 238 | } | 243 | } | ||
| @@ -241,6 +246,7 @@ var xNavigationPageGetChild func(uintptr) uintptr | |||||
| 241 | 246 | ||||
| 242 | // Gets the child widget of @self. | 247 | // Gets the child widget of @self. | ||
| 243 | func (x *NavigationPage) GetChild() *gtk.Widget { | 248 | func (x *NavigationPage) GetChild() *gtk.Widget { | ||
| 249 | + | core.LazyRegister(&xNavigationPageGetChild, "ADW", "adw_navigation_page_get_child", false) | |||
| 244 | var cls *gtk.Widget | 250 | var cls *gtk.Widget | ||
| 245 | 251 | ||||
| 246 | cret := xNavigationPageGetChild(x.GoPointer()) | 252 | cret := xNavigationPageGetChild(x.GoPointer()) | ||
| @@ -258,6 +264,8 @@ var xNavigationPageGetTag func(uintptr) string | |||||
| 258 | 264 | ||||
| 259 | // Gets the tag of @self. | 265 | // Gets the tag of @self. | ||
| 260 | func (x *NavigationPage) GetTag() string { | 266 | func (x *NavigationPage) GetTag() string { | ||
| 267 | + | core.LazyRegister(&xNavigationPageGetTag, "ADW", "adw_navigation_page_get_tag", false) | |||
| 268 | + | ||||
| 261 | cret := xNavigationPageGetTag(x.GoPointer()) | 269 | cret := xNavigationPageGetTag(x.GoPointer()) | ||
| 262 | return cret | 270 | return cret | ||
| 263 | } | 271 | } | ||
| @@ -266,6 +274,8 @@ var xNavigationPageGetTitle func(uintptr) string | |||||
| 266 | 274 | ||||
| 267 | // Gets the title of @self. | 275 | // Gets the title of @self. | ||
| 268 | func (x *NavigationPage) GetTitle() string { | 276 | func (x *NavigationPage) GetTitle() string { | ||
| 277 | + | core.LazyRegister(&xNavigationPageGetTitle, "ADW", "adw_navigation_page_get_title", false) | |||
| 278 | + | ||||
| 269 | cret := xNavigationPageGetTitle(x.GoPointer()) | 279 | cret := xNavigationPageGetTitle(x.GoPointer()) | ||
| 270 | return cret | 280 | return cret | ||
| 271 | } | 281 | } | ||
| @@ -283,6 +293,8 @@ var xNavigationPageSetCanPop func(uintptr, bool) | |||||
| 283 | // See [property@HeaderBar:show-back-button] for removing only the back button, | 293 | // See [property@HeaderBar:show-back-button] for removing only the back button, | ||
| 284 | // but not shortcuts. | 294 | // but not shortcuts. | ||
| 285 | func (x *NavigationPage) SetCanPop(CanPopVar bool) { | 295 | func (x *NavigationPage) SetCanPop(CanPopVar bool) { | ||
| 296 | + | core.LazyRegister(&xNavigationPageSetCanPop, "ADW", "adw_navigation_page_set_can_pop", false) | |||
| 297 | + | ||||
| 286 | xNavigationPageSetCanPop(x.GoPointer(), CanPopVar) | 298 | xNavigationPageSetCanPop(x.GoPointer(), CanPopVar) | ||
| 287 | } | 299 | } | ||
| 288 | 300 | ||||
| @@ -290,6 +302,8 @@ var xNavigationPageSetChild func(uintptr, uintptr) | |||||
| 290 | 302 | ||||
| 291 | // Sets the child widget of @self. | 303 | // Sets the child widget of @self. | ||
| 292 | func (x *NavigationPage) SetChild(ChildVar *gtk.Widget) { | 304 | func (x *NavigationPage) SetChild(ChildVar *gtk.Widget) { | ||
| 305 | + | core.LazyRegister(&xNavigationPageSetChild, "ADW", "adw_navigation_page_set_child", false) | |||
| 306 | + | ||||
| 293 | xNavigationPageSetChild(x.GoPointer(), ChildVar.GoPointer()) | 307 | xNavigationPageSetChild(x.GoPointer(), ChildVar.GoPointer()) | ||
| 294 | } | 308 | } | ||
| 295 | 309 | ||||
| @@ -306,6 +320,8 @@ var xNavigationPageSetTag func(uintptr, uintptr) | |||||
| 306 | // | 320 | // | ||
| 307 | // The tag also must be set to use the `navigation.push` action. | 321 | // The tag also must be set to use the `navigation.push` action. | ||
| 308 | func (x *NavigationPage) SetTag(TagVar *string) { | 322 | func (x *NavigationPage) SetTag(TagVar *string) { | ||
| 323 | + | core.LazyRegister(&xNavigationPageSetTag, "ADW", "adw_navigation_page_set_tag", false) | |||
| 324 | + | ||||
| 309 | TagVarPtr := core.GStrdupNullable(TagVar) | 325 | TagVarPtr := core.GStrdupNullable(TagVar) | ||
| 310 | defer core.GFreeNullable(TagVarPtr) | 326 | defer core.GFreeNullable(TagVarPtr) | ||
| 311 | 327 | ||||
| @@ -319,6 +335,8 @@ var xNavigationPageSetTitle func(uintptr, string) | |||||
| 319 | // It's displayed in [class@HeaderBar] instead of the window title, and used as | 335 | // It's displayed in [class@HeaderBar] instead of the window title, and used as | ||
| 320 | // the tooltip on the next page's back button, as well as by screen reader. | 336 | // the tooltip on the next page's back button, as well as by screen reader. | ||
| 321 | func (x *NavigationPage) SetTitle(TitleVar string) { | 337 | func (x *NavigationPage) SetTitle(TitleVar string) { | ||
| 338 | + | core.LazyRegister(&xNavigationPageSetTitle, "ADW", "adw_navigation_page_set_title", false) | |||
| 339 | + | ||||
| 322 | xNavigationPageSetTitle(x.GoPointer(), TitleVar) | 340 | xNavigationPageSetTitle(x.GoPointer(), TitleVar) | ||
| 323 | } | 341 | } | ||
| 324 | 342 | ||||
| @@ -964,6 +982,7 @@ type NavigationView struct { | |||||
| 964 | var xNavigationViewGLibType func() types.GType | 982 | var xNavigationViewGLibType func() types.GType | ||
| 965 | 983 | ||||
| 966 | func NavigationViewGLibType() types.GType { | 984 | func NavigationViewGLibType() types.GType { | ||
| 985 | + | core.LazyRegister(&xNavigationViewGLibType, "ADW", "adw_navigation_view_get_type", false) | |||
| 967 | return xNavigationViewGLibType() | 986 | return xNavigationViewGLibType() | ||
| 968 | } | 987 | } | ||
| 969 | 988 | ||||
| @@ -977,6 +996,7 @@ var xNewNavigationView func() uintptr | |||||
| 977 | 996 | ||||
| 978 | // Creates a new `AdwNavigationView`. | 997 | // Creates a new `AdwNavigationView`. | ||
| 979 | func NewNavigationView() *NavigationView { | 998 | func NewNavigationView() *NavigationView { | ||
| 999 | + | core.LazyRegister(&xNewNavigationView, "ADW", "adw_navigation_view_new", false) | |||
| 980 | var cls *NavigationView | 1000 | var cls *NavigationView | ||
| 981 | 1001 | ||||
| 982 | cret := xNewNavigationView() | 1002 | cret := xNewNavigationView() | ||
| @@ -1002,6 +1022,8 @@ var xNavigationViewAdd func(uintptr, uintptr) | |||||
| 1002 | // | 1022 | // | ||
| 1003 | // See [method@NavigationView.remove]. | 1023 | // See [method@NavigationView.remove]. | ||
| 1004 | func (x *NavigationView) Add(PageVar *NavigationPage) { | 1024 | func (x *NavigationView) Add(PageVar *NavigationPage) { | ||
| 1025 | + | core.LazyRegister(&xNavigationViewAdd, "ADW", "adw_navigation_view_add", false) | |||
| 1026 | + | ||||
| 1005 | xNavigationViewAdd(x.GoPointer(), PageVar.GoPointer()) | 1027 | xNavigationViewAdd(x.GoPointer(), PageVar.GoPointer()) | ||
| 1006 | } | 1028 | } | ||
| 1007 | 1029 | ||||
| @@ -1011,6 +1033,7 @@ var xNavigationViewFindPage func(uintptr, string) uintptr | |||||
| 1011 | // | 1033 | // | ||
| 1012 | // See [property@NavigationPage:tag]. | 1034 | // See [property@NavigationPage:tag]. | ||
| 1013 | func (x *NavigationView) FindPage(TagVar string) *NavigationPage { | 1035 | func (x *NavigationView) FindPage(TagVar string) *NavigationPage { | ||
| 1036 | + | core.LazyRegister(&xNavigationViewFindPage, "ADW", "adw_navigation_view_find_page", false) | |||
| 1014 | var cls *NavigationPage | 1037 | var cls *NavigationPage | ||
| 1015 | 1038 | ||||
| 1016 | cret := xNavigationViewFindPage(x.GoPointer(), TagVar) | 1039 | cret := xNavigationViewFindPage(x.GoPointer(), TagVar) | ||
| @@ -1028,6 +1051,8 @@ var xNavigationViewGetAnimateTransitions func(uintptr) bool | |||||
| 1028 | 1051 | ||||
| 1029 | // Gets whether @self animates page transitions. | 1052 | // Gets whether @self animates page transitions. | ||
| 1030 | func (x *NavigationView) GetAnimateTransitions() bool { | 1053 | func (x *NavigationView) GetAnimateTransitions() bool { | ||
| 1054 | + | core.LazyRegister(&xNavigationViewGetAnimateTransitions, "ADW", "adw_navigation_view_get_animate_transitions", false) | |||
| 1055 | + | ||||
| 1031 | cret := xNavigationViewGetAnimateTransitions(x.GoPointer()) | 1056 | cret := xNavigationViewGetAnimateTransitions(x.GoPointer()) | ||
| 1032 | return cret | 1057 | return cret | ||
| 1033 | } | 1058 | } | ||
| @@ -1036,6 +1061,8 @@ var xNavigationViewGetHhomogeneous func(uintptr) bool | |||||
| 1036 | 1061 | ||||
| 1037 | // Gets whether @self is horizontally homogeneous. | 1062 | // Gets whether @self is horizontally homogeneous. | ||
| 1038 | func (x *NavigationView) GetHhomogeneous() bool { | 1063 | func (x *NavigationView) GetHhomogeneous() bool { | ||
| 1064 | + | core.LazyRegister(&xNavigationViewGetHhomogeneous, "ADW", "adw_navigation_view_get_hhomogeneous", false) | |||
| 1065 | + | ||||
| 1039 | cret := xNavigationViewGetHhomogeneous(x.GoPointer()) | 1066 | cret := xNavigationViewGetHhomogeneous(x.GoPointer()) | ||
| 1040 | return cret | 1067 | return cret | ||
| 1041 | } | 1068 | } | ||
| @@ -1048,6 +1075,7 @@ var xNavigationViewGetNavigationStack func(uintptr) uintptr | |||||
| 1048 | // | 1075 | // | ||
| 1049 | // This can be used to keep an up-to-date view. | 1076 | // This can be used to keep an up-to-date view. | ||
| 1050 | func (x *NavigationView) GetNavigationStack() *gio.ListModelBase { | 1077 | func (x *NavigationView) GetNavigationStack() *gio.ListModelBase { | ||
| 1078 | + | core.LazyRegister(&xNavigationViewGetNavigationStack, "ADW", "adw_navigation_view_get_navigation_stack", false) | |||
| 1051 | var cls *gio.ListModelBase | 1079 | var cls *gio.ListModelBase | ||
| 1052 | 1080 | ||||
| 1053 | cret := xNavigationViewGetNavigationStack(x.GoPointer()) | 1081 | cret := xNavigationViewGetNavigationStack(x.GoPointer()) | ||
| @@ -1064,6 +1092,8 @@ var xNavigationViewGetPopOnEscape func(uintptr) bool | |||||
| 1064 | 1092 | ||||
| 1065 | // Gets whether pressing Escape pops the current page on @self. | 1093 | // Gets whether pressing Escape pops the current page on @self. | ||
| 1066 | func (x *NavigationView) GetPopOnEscape() bool { | 1094 | func (x *NavigationView) GetPopOnEscape() bool { | ||
| 1095 | + | core.LazyRegister(&xNavigationViewGetPopOnEscape, "ADW", "adw_navigation_view_get_pop_on_escape", false) | |||
| 1096 | + | ||||
| 1067 | cret := xNavigationViewGetPopOnEscape(x.GoPointer()) | 1097 | cret := xNavigationViewGetPopOnEscape(x.GoPointer()) | ||
| 1068 | return cret | 1098 | return cret | ||
| 1069 | } | 1099 | } | ||
| @@ -1077,6 +1107,7 @@ var xNavigationViewGetPreviousPage func(uintptr, uintptr) uintptr | |||||
| 1077 | // | 1107 | // | ||
| 1078 | // If @page is the root page or is not in the navigation stack, returns `NULL`. | 1108 | // If @page is the root page or is not in the navigation stack, returns `NULL`. | ||
| 1079 | func (x *NavigationView) GetPreviousPage(PageVar *NavigationPage) *NavigationPage { | 1109 | func (x *NavigationView) GetPreviousPage(PageVar *NavigationPage) *NavigationPage { | ||
| 1110 | + | core.LazyRegister(&xNavigationViewGetPreviousPage, "ADW", "adw_navigation_view_get_previous_page", false) | |||
| 1080 | var cls *NavigationPage | 1111 | var cls *NavigationPage | ||
| 1081 | 1112 | ||||
| 1082 | cret := xNavigationViewGetPreviousPage(x.GoPointer(), PageVar.GoPointer()) | 1113 | cret := xNavigationViewGetPreviousPage(x.GoPointer(), PageVar.GoPointer()) | ||
| @@ -1094,6 +1125,8 @@ var xNavigationViewGetVhomogeneous func(uintptr) bool | |||||
| 1094 | 1125 | ||||
| 1095 | // Gets whether @self is vertically homogeneous. | 1126 | // Gets whether @self is vertically homogeneous. | ||
| 1096 | func (x *NavigationView) GetVhomogeneous() bool { | 1127 | func (x *NavigationView) GetVhomogeneous() bool { | ||
| 1128 | + | core.LazyRegister(&xNavigationViewGetVhomogeneous, "ADW", "adw_navigation_view_get_vhomogeneous", false) | |||
| 1129 | + | ||||
| 1097 | cret := xNavigationViewGetVhomogeneous(x.GoPointer()) | 1130 | cret := xNavigationViewGetVhomogeneous(x.GoPointer()) | ||
| 1098 | return cret | 1131 | return cret | ||
| 1099 | } | 1132 | } | ||
| @@ -1102,6 +1135,7 @@ var xNavigationViewGetVisiblePage func(uintptr) uintptr | |||||
| 1102 | 1135 | ||||
| 1103 | // Gets the currently visible page in @self. | 1136 | // Gets the currently visible page in @self. | ||
| 1104 | func (x *NavigationView) GetVisiblePage() *NavigationPage { | 1137 | func (x *NavigationView) GetVisiblePage() *NavigationPage { | ||
| 1138 | + | core.LazyRegister(&xNavigationViewGetVisiblePage, "ADW", "adw_navigation_view_get_visible_page", false) | |||
| 1105 | var cls *NavigationPage | 1139 | var cls *NavigationPage | ||
| 1106 | 1140 | ||||
| 1107 | cret := xNavigationViewGetVisiblePage(x.GoPointer()) | 1141 | cret := xNavigationViewGetVisiblePage(x.GoPointer()) | ||
| @@ -1119,6 +1153,8 @@ var xNavigationViewGetVisiblePageTag func(uintptr) string | |||||
| 1119 | 1153 | ||||
| 1120 | // Gets the tag of the currently visible page in @self. | 1154 | // Gets the tag of the currently visible page in @self. | ||
| 1121 | func (x *NavigationView) GetVisiblePageTag() string { | 1155 | func (x *NavigationView) GetVisiblePageTag() string { | ||
| 1156 | + | core.LazyRegister(&xNavigationViewGetVisiblePageTag, "ADW", "adw_navigation_view_get_visible_page_tag", false) | |||
| 1157 | + | ||||
| 1122 | cret := xNavigationViewGetVisiblePageTag(x.GoPointer()) | 1158 | cret := xNavigationViewGetVisiblePageTag(x.GoPointer()) | ||
| 1123 | return cret | 1159 | return cret | ||
| 1124 | } | 1160 | } | ||
| @@ -1137,6 +1173,8 @@ var xNavigationViewPop func(uintptr) bool | |||||
| 1137 | // See [method@NavigationView.pop_to_page] and | 1173 | // See [method@NavigationView.pop_to_page] and | ||
| 1138 | // [method@NavigationView.pop_to_tag]. | 1174 | // [method@NavigationView.pop_to_tag]. | ||
| 1139 | func (x *NavigationView) Pop() bool { | 1175 | func (x *NavigationView) Pop() bool { | ||
| 1176 | + | core.LazyRegister(&xNavigationViewPop, "ADW", "adw_navigation_view_pop", false) | |||
| 1177 | + | ||||
| 1140 | cret := xNavigationViewPop(x.GoPointer()) | 1178 | cret := xNavigationViewPop(x.GoPointer()) | ||
| 1141 | return cret | 1179 | return cret | ||
| 1142 | } | 1180 | } | ||
| @@ -1155,6 +1193,8 @@ var xNavigationViewPopToPage func(uintptr, uintptr) bool | |||||
| 1155 | // | 1193 | // | ||
| 1156 | // See [method@NavigationView.pop] and [method@NavigationView.pop_to_tag]. | 1194 | // See [method@NavigationView.pop] and [method@NavigationView.pop_to_tag]. | ||
| 1157 | func (x *NavigationView) PopToPage(PageVar *NavigationPage) bool { | 1195 | func (x *NavigationView) PopToPage(PageVar *NavigationPage) bool { | ||
| 1196 | + | core.LazyRegister(&xNavigationViewPopToPage, "ADW", "adw_navigation_view_pop_to_page", false) | |||
| 1197 | + | ||||
| 1158 | cret := xNavigationViewPopToPage(x.GoPointer(), PageVar.GoPointer()) | 1198 | cret := xNavigationViewPopToPage(x.GoPointer(), PageVar.GoPointer()) | ||
| 1159 | return cret | 1199 | return cret | ||
| 1160 | } | 1200 | } | ||
| @@ -1172,6 +1212,8 @@ var xNavigationViewPopToTag func(uintptr, string) bool | |||||
| 1172 | // | 1212 | // | ||
| 1173 | // See [method@NavigationView.pop_to_page] and [property@NavigationPage:tag]. | 1213 | // See [method@NavigationView.pop_to_page] and [property@NavigationPage:tag]. | ||
| 1174 | func (x *NavigationView) PopToTag(TagVar string) bool { | 1214 | func (x *NavigationView) PopToTag(TagVar string) bool { | ||
| 1215 | + | core.LazyRegister(&xNavigationViewPopToTag, "ADW", "adw_navigation_view_pop_to_tag", false) | |||
| 1216 | + | ||||
| 1175 | cret := xNavigationViewPopToTag(x.GoPointer(), TagVar) | 1217 | cret := xNavigationViewPopToTag(x.GoPointer(), TagVar) | ||
| 1176 | return cret | 1218 | return cret | ||
| 1177 | } | 1219 | } | ||
| @@ -1187,6 +1229,8 @@ var xNavigationViewPush func(uintptr, uintptr) | |||||
| 1187 | // | 1229 | // | ||
| 1188 | // See [method@NavigationView.push_by_tag]. | 1230 | // See [method@NavigationView.push_by_tag]. | ||
| 1189 | func (x *NavigationView) Push(PageVar *NavigationPage) { | 1231 | func (x *NavigationView) Push(PageVar *NavigationPage) { | ||
| 1232 | + | core.LazyRegister(&xNavigationViewPush, "ADW", "adw_navigation_view_push", false) | |||
| 1233 | + | ||||
| 1190 | xNavigationViewPush(x.GoPointer(), PageVar.GoPointer()) | 1234 | xNavigationViewPush(x.GoPointer(), PageVar.GoPointer()) | ||
| 1191 | } | 1235 | } | ||
| 1192 | 1236 | ||||
| @@ -1201,6 +1245,8 @@ var xNavigationViewPushByTag func(uintptr, string) | |||||
| 1201 | // | 1245 | // | ||
| 1202 | // See [method@NavigationView.push] and [property@NavigationPage:tag]. | 1246 | // See [method@NavigationView.push] and [property@NavigationPage:tag]. | ||
| 1203 | func (x *NavigationView) PushByTag(TagVar string) { | 1247 | func (x *NavigationView) PushByTag(TagVar string) { | ||
| 1248 | + | core.LazyRegister(&xNavigationViewPushByTag, "ADW", "adw_navigation_view_push_by_tag", false) | |||
| 1249 | + | ||||
| 1204 | xNavigationViewPushByTag(x.GoPointer(), TagVar) | 1250 | xNavigationViewPushByTag(x.GoPointer(), TagVar) | ||
| 1205 | } | 1251 | } | ||
| 1206 | 1252 | ||||
| @@ -1213,6 +1259,8 @@ var xNavigationViewRemove func(uintptr, uintptr) | |||||
| 1213 | // | 1259 | // | ||
| 1214 | // See [method@NavigationView.add]. | 1260 | // See [method@NavigationView.add]. | ||
| 1215 | func (x *NavigationView) Remove(PageVar *NavigationPage) { | 1261 | func (x *NavigationView) Remove(PageVar *NavigationPage) { | ||
| 1262 | + | core.LazyRegister(&xNavigationViewRemove, "ADW", "adw_navigation_view_remove", false) | |||
| 1263 | + | ||||
| 1216 | xNavigationViewRemove(x.GoPointer(), PageVar.GoPointer()) | 1264 | xNavigationViewRemove(x.GoPointer(), PageVar.GoPointer()) | ||
| 1217 | } | 1265 | } | ||
| 1218 | 1266 | ||||
| @@ -1234,6 +1282,8 @@ var xNavigationViewReplace func(uintptr, uintptr, int) | |||||
| 1234 | // | 1282 | // | ||
| 1235 | // See [method@NavigationView.replace_with_tags]. | 1283 | // See [method@NavigationView.replace_with_tags]. | ||
| 1236 | func (x *NavigationView) Replace(PagesVar uintptr, NPagesVar int) { | 1284 | func (x *NavigationView) Replace(PagesVar uintptr, NPagesVar int) { | ||
| 1285 | + | core.LazyRegister(&xNavigationViewReplace, "ADW", "adw_navigation_view_replace", false) | |||
| 1286 | + | ||||
| 1237 | xNavigationViewReplace(x.GoPointer(), PagesVar, NPagesVar) | 1287 | xNavigationViewReplace(x.GoPointer(), PagesVar, NPagesVar) | ||
| 1238 | } | 1288 | } | ||
| 1239 | 1289 | ||||
| @@ -1255,6 +1305,8 @@ var xNavigationViewReplaceWithTags func(uintptr, []string, int) | |||||
| 1255 | // | 1305 | // | ||
| 1256 | // See [method@NavigationView.replace] and [property@NavigationPage:tag]. | 1306 | // See [method@NavigationView.replace] and [property@NavigationPage:tag]. | ||
| 1257 | func (x *NavigationView) ReplaceWithTags(TagsVar []string, NTagsVar int) { | 1307 | func (x *NavigationView) ReplaceWithTags(TagsVar []string, NTagsVar int) { | ||
| 1308 | + | core.LazyRegister(&xNavigationViewReplaceWithTags, "ADW", "adw_navigation_view_replace_with_tags", false) | |||
| 1309 | + | ||||
| 1258 | xNavigationViewReplaceWithTags(x.GoPointer(), TagsVar, NTagsVar) | 1310 | xNavigationViewReplaceWithTags(x.GoPointer(), TagsVar, NTagsVar) | ||
| 1259 | } | 1311 | } | ||
| 1260 | 1312 | ||||
| @@ -1264,6 +1316,8 @@ var xNavigationViewSetAnimateTransitions func(uintptr, bool) | |||||
| 1264 | // | 1316 | // | ||
| 1265 | // Gesture-based transitions are always animated. | 1317 | // Gesture-based transitions are always animated. | ||
| 1266 | func (x *NavigationView) SetAnimateTransitions(AnimateTransitionsVar bool) { | 1318 | func (x *NavigationView) SetAnimateTransitions(AnimateTransitionsVar bool) { | ||
| 1319 | + | core.LazyRegister(&xNavigationViewSetAnimateTransitions, "ADW", "adw_navigation_view_set_animate_transitions", false) | |||
| 1320 | + | ||||
| 1267 | xNavigationViewSetAnimateTransitions(x.GoPointer(), AnimateTransitionsVar) | 1321 | xNavigationViewSetAnimateTransitions(x.GoPointer(), AnimateTransitionsVar) | ||
| 1268 | } | 1322 | } | ||
| 1269 | 1323 | ||||
| @@ -1276,6 +1330,8 @@ var xNavigationViewSetHhomogeneous func(uintptr, bool) | |||||
| 1276 | // | 1330 | // | ||
| 1277 | // If it's not, the view may change width when a different page becomes visible. | 1331 | // If it's not, the view may change width when a different page becomes visible. | ||
| 1278 | func (x *NavigationView) SetHhomogeneous(HhomogeneousVar bool) { | 1332 | func (x *NavigationView) SetHhomogeneous(HhomogeneousVar bool) { | ||
| 1333 | + | core.LazyRegister(&xNavigationViewSetHhomogeneous, "ADW", "adw_navigation_view_set_hhomogeneous", false) | |||
| 1334 | + | ||||
| 1279 | xNavigationViewSetHhomogeneous(x.GoPointer(), HhomogeneousVar) | 1335 | xNavigationViewSetHhomogeneous(x.GoPointer(), HhomogeneousVar) | ||
| 1280 | } | 1336 | } | ||
| 1281 | 1337 | ||||
| @@ -1286,6 +1342,8 @@ var xNavigationViewSetPopOnEscape func(uintptr, bool) | |||||
| 1286 | // Applications using `AdwNavigationView` to implement a browser may want to | 1342 | // Applications using `AdwNavigationView` to implement a browser may want to | ||
| 1287 | // disable it. | 1343 | // disable it. | ||
| 1288 | func (x *NavigationView) SetPopOnEscape(PopOnEscapeVar bool) { | 1344 | func (x *NavigationView) SetPopOnEscape(PopOnEscapeVar bool) { | ||
| 1345 | + | core.LazyRegister(&xNavigationViewSetPopOnEscape, "ADW", "adw_navigation_view_set_pop_on_escape", false) | |||
| 1346 | + | ||||
| 1289 | xNavigationViewSetPopOnEscape(x.GoPointer(), PopOnEscapeVar) | 1347 | xNavigationViewSetPopOnEscape(x.GoPointer(), PopOnEscapeVar) | ||
| 1290 | } | 1348 | } | ||
| 1291 | 1349 | ||||
| @@ -1299,6 +1357,8 @@ var xNavigationViewSetVhomogeneous func(uintptr, bool) | |||||
| 1299 | // If it's not, the view may change height when a different page becomes | 1357 | // If it's not, the view may change height when a different page becomes | ||
| 1300 | // visible. | 1358 | // visible. | ||
| 1301 | func (x *NavigationView) SetVhomogeneous(VhomogeneousVar bool) { | 1359 | func (x *NavigationView) SetVhomogeneous(VhomogeneousVar bool) { | ||
| 1360 | + | core.LazyRegister(&xNavigationViewSetVhomogeneous, "ADW", "adw_navigation_view_set_vhomogeneous", false) | |||
| 1361 | + | ||||
| 1302 | xNavigationViewSetVhomogeneous(x.GoPointer(), VhomogeneousVar) | 1362 | xNavigationViewSetVhomogeneous(x.GoPointer(), VhomogeneousVar) | ||
| 1303 | } | 1363 | } | ||
| 1304 | 1364 | ||||
| @@ -1843,53 +1903,4 @@ func (x *NavigationView) GetBuildableId() string { | |||||
| 1843 | func init() { | 1903 | func init() { | ||
| 1844 | core.SetPackageName("ADW", "libadwaita-1") | 1904 | core.SetPackageName("ADW", "libadwaita-1") | ||
| 1845 | core.SetSharedLibraries("ADW", []string{"libadwaita-1.so.0", "libadwaita-1.0.dylib"}) | 1905 | core.SetSharedLibraries("ADW", []string{"libadwaita-1.so.0", "libadwaita-1.0.dylib"}) | ||
| 1846 | - | var libs []uintptr | |||
| 1847 | - | for _, libPath := range core.GetPaths("ADW") { | |||
| 1848 | - | lib, err := purego.Dlopen(libPath, purego.RTLD_NOW|purego.RTLD_GLOBAL) | |||
| 1849 | - | if err != nil { | |||
| 1850 | - | panic(err) | |||
| 1851 | - | } | |||
| 1852 | - | libs = append(libs, lib) | |||
| 1853 | - | } | |||
| 1854 | - | ||||
| 1855 | - | core.PuregoSafeRegister(&xNavigationPageGLibType, libs, "adw_navigation_page_get_type") | |||
| 1856 | - | ||||
| 1857 | - | core.PuregoSafeRegister(&xNewNavigationPage, libs, "adw_navigation_page_new") | |||
| 1858 | - | core.PuregoSafeRegister(&xNewNavigationPageWithTag, libs, "adw_navigation_page_new_with_tag") | |||
| 1859 | - | ||||
| 1860 | - | core.PuregoSafeRegister(&xNavigationPageGetCanPop, libs, "adw_navigation_page_get_can_pop") | |||
| 1861 | - | core.PuregoSafeRegister(&xNavigationPageGetChild, libs, "adw_navigation_page_get_child") | |||
| 1862 | - | core.PuregoSafeRegister(&xNavigationPageGetTag, libs, "adw_navigation_page_get_tag") | |||
| 1863 | - | core.PuregoSafeRegister(&xNavigationPageGetTitle, libs, "adw_navigation_page_get_title") | |||
| 1864 | - | core.PuregoSafeRegister(&xNavigationPageSetCanPop, libs, "adw_navigation_page_set_can_pop") | |||
| 1865 | - | core.PuregoSafeRegister(&xNavigationPageSetChild, libs, "adw_navigation_page_set_child") | |||
| 1866 | - | core.PuregoSafeRegister(&xNavigationPageSetTag, libs, "adw_navigation_page_set_tag") | |||
| 1867 | - | core.PuregoSafeRegister(&xNavigationPageSetTitle, libs, "adw_navigation_page_set_title") | |||
| 1868 | - | ||||
| 1869 | - | core.PuregoSafeRegister(&xNavigationViewGLibType, libs, "adw_navigation_view_get_type") | |||
| 1870 | - | ||||
| 1871 | - | core.PuregoSafeRegister(&xNewNavigationView, libs, "adw_navigation_view_new") | |||
| 1872 | - | ||||
| 1873 | - | core.PuregoSafeRegister(&xNavigationViewAdd, libs, "adw_navigation_view_add") | |||
| 1874 | - | core.PuregoSafeRegister(&xNavigationViewFindPage, libs, "adw_navigation_view_find_page") | |||
| 1875 | - | core.PuregoSafeRegister(&xNavigationViewGetAnimateTransitions, libs, "adw_navigation_view_get_animate_transitions") | |||
| 1876 | - | core.PuregoSafeRegister(&xNavigationViewGetHhomogeneous, libs, "adw_navigation_view_get_hhomogeneous") | |||
| 1877 | - | core.PuregoSafeRegister(&xNavigationViewGetNavigationStack, libs, "adw_navigation_view_get_navigation_stack") | |||
| 1878 | - | core.PuregoSafeRegister(&xNavigationViewGetPopOnEscape, libs, "adw_navigation_view_get_pop_on_escape") | |||
| 1879 | - | core.PuregoSafeRegister(&xNavigationViewGetPreviousPage, libs, "adw_navigation_view_get_previous_page") | |||
| 1880 | - | core.PuregoSafeRegister(&xNavigationViewGetVhomogeneous, libs, "adw_navigation_view_get_vhomogeneous") | |||
| 1881 | - | core.PuregoSafeRegister(&xNavigationViewGetVisiblePage, libs, "adw_navigation_view_get_visible_page") | |||
| 1882 | - | core.PuregoSafeRegister(&xNavigationViewGetVisiblePageTag, libs, "adw_navigation_view_get_visible_page_tag") | |||
| 1883 | - | core.PuregoSafeRegister(&xNavigationViewPop, libs, "adw_navigation_view_pop") | |||
| 1884 | - | core.PuregoSafeRegister(&xNavigationViewPopToPage, libs, "adw_navigation_view_pop_to_page") | |||
| 1885 | - | core.PuregoSafeRegister(&xNavigationViewPopToTag, libs, "adw_navigation_view_pop_to_tag") | |||
| 1886 | - | core.PuregoSafeRegister(&xNavigationViewPush, libs, "adw_navigation_view_push") | |||
| 1887 | - | core.PuregoSafeRegister(&xNavigationViewPushByTag, libs, "adw_navigation_view_push_by_tag") | |||
| 1888 | - | core.PuregoSafeRegister(&xNavigationViewRemove, libs, "adw_navigation_view_remove") | |||
| 1889 | - | core.PuregoSafeRegister(&xNavigationViewReplace, libs, "adw_navigation_view_replace") | |||
| 1890 | - | core.PuregoSafeRegister(&xNavigationViewReplaceWithTags, libs, "adw_navigation_view_replace_with_tags") | |||
| 1891 | - | core.PuregoSafeRegister(&xNavigationViewSetAnimateTransitions, libs, "adw_navigation_view_set_animate_transitions") | |||
| 1892 | - | core.PuregoSafeRegister(&xNavigationViewSetHhomogeneous, libs, "adw_navigation_view_set_hhomogeneous") | |||
| 1893 | - | core.PuregoSafeRegister(&xNavigationViewSetPopOnEscape, libs, "adw_navigation_view_set_pop_on_escape") | |||
| 1894 | - | core.PuregoSafeRegister(&xNavigationViewSetVhomogeneous, libs, "adw_navigation_view_set_vhomogeneous") | |||
| 1895 | } | 1906 | } | ||