summaryrefslogtreecommitdiff
path: root/windowGeneric.go
diff options
context:
space:
mode:
Diffstat (limited to 'windowGeneric.go')
-rw-r--r--windowGeneric.go21
1 files changed, 16 insertions, 5 deletions
diff --git a/windowGeneric.go b/windowGeneric.go
index 7daae01..967ca0a 100644
--- a/windowGeneric.go
+++ b/windowGeneric.go
@@ -11,9 +11,14 @@ import (
)
type genericWindow struct {
- win *gadgets.BasicWindow // the window widget itself
- box *gui.Node // the top box of the repolist window
- group *gui.Node // the default group
+ win *gadgets.BasicWindow // the window widget itself
+ box *gui.Node // the overall shelf
+ shelf *gui.Node // the overall shelf
+ stack *gui.Node // the first box is a shelf
+ top *gui.Node // the first item in the stack is always a box
+ group *gui.Node // the first item top box is always a group
+ middle *gui.Node // the middle box
+ bottom *gui.Node // the bottom box of the repolist window
}
func (r *genericWindow) Hidden() bool {
@@ -79,13 +84,19 @@ func initGenericWindow(title string, grouptxt string) *genericWindow {
gw.win = gadgets.RawBasicWindow(title)
gw.win.Make()
- gw.box = gw.win.Box().Vertical() // a vertical box (like a stack of books)
gw.win.Custom = func() {
log.Warn("Found Window close. setting hidden=true")
// sets the hidden flag to false so Toggle() works
gw.win.Hide()
}
- gw.group = gw.box.NewGroup(grouptxt)
+ gw.box = gw.win.Box()
+ gw.shelf = gw.box
+ gw.stack = gw.shelf.NewVerticalBox("STACKBOX") // a vertical box (like a stack of books)
+ gw.top = gw.stack.Box()
+ gw.group = gw.top.NewGroup(grouptxt)
+ gw.middle = gw.stack.Box()
+ gw.middle.Vertical()
+ gw.bottom = gw.stack.Box()
gw.Show()
return gw