diff options
Diffstat (limited to 'structs.go')
| -rw-r--r-- | structs.go | 39 |
1 files changed, 29 insertions, 10 deletions
@@ -15,16 +15,17 @@ var me *gusconf // this app's variables type gusconf struct { - myGui *gui.Node // the base of the gui - portmaps *Portmaps // the portmap window - events *Events // the event log - portwin *stdTableWin // the portwin window - urlbase string // the dns name for the zookeeper - hostname string // my hostname - pollDelay time.Duration // how often to report our status - dog *time.Ticker // the watchdog timer - failcount int // how many times we've failed to contact the zookeeper - failcountmax int // after this, exit and let systemd restart the daemon + myGui *gui.Node // the base of the gui + portmaps *Portmaps // the portmap window + events *Events // the event log + portwin *stdTableWin // the portwin window + eventswin *stdEventTableWin // the event window + urlbase string // the dns name for the zookeeper + hostname string // my hostname + pollDelay time.Duration // how often to report our status + dog *time.Ticker // the watchdog timer + failcount int // how many times we've failed to contact the zookeeper + failcountmax int // after this, exit and let systemd restart the daemon } type stdTableWin struct { @@ -44,3 +45,21 @@ func (w *stdTableWin) Toggle() { } w.win.Toggle() } + +type stdEventTableWin struct { + sync.Mutex + win *gadgets.GenericWindow // the machines gui window + box *gui.Node // the machines gui parent box widget + TB *EventsTable // the gui table buffer + update bool // if the window should be updated +} + +func (w *stdEventTableWin) Toggle() { + if w == nil { + return + } + if w.win == nil { + return + } + w.win.Toggle() +} |
