File: box.go

package info (click to toggle)
golang-github-twstrike-gotk3adapter 0.0~git20170505.0.901a95d%2Bds-3
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 1,232 kB
  • sloc: ruby: 478; makefile: 4
file content (41 lines) | stat: -rw-r--r-- 851 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
package gtka

import (
	"github.com/gotk3/gotk3/gtk"
	"github.com/twstrike/gotk3adapter/gtki"
)

type box struct {
	*container
	internal *gtk.Box
}

func wrapBoxSimple(v *gtk.Box) *box {
	if v == nil {
		return nil
	}
	return &box{wrapContainerSimple(&v.Container), v}
}

func wrapBox(v *gtk.Box, e error) (*box, error) {
	return wrapBoxSimple(v), e
}

func unwrapBox(v gtki.Box) *gtk.Box {
	if v == nil {
		return nil
	}
	return v.(*box).internal
}

func (v *box) PackEnd(v1 gtki.Widget, v2, v3 bool, v4 uint) {
	v.internal.PackEnd(unwrapWidget(v1), v2, v3, v4)
}

func (v *box) PackStart(v1 gtki.Widget, v2, v3 bool, v4 uint) {
	v.internal.PackStart(unwrapWidget(v1), v2, v3, v4)
}

func (v *box) SetChildPacking(v1 gtki.Widget, v2, v3 bool, v4 uint, v5 gtki.PackType) {
	v.internal.SetChildPacking(unwrapWidget(v1), v2, v3, v4, gtk.PackType(v5))
}