summaryrefslogtreecommitdiff
path: root/settings.go
diff options
context:
space:
mode:
Diffstat (limited to 'settings.go')
-rw-r--r--settings.go22
1 files changed, 15 insertions, 7 deletions
diff --git a/settings.go b/settings.go
index 2bc252a..776bd28 100644
--- a/settings.go
+++ b/settings.go
@@ -1,14 +1,16 @@
package logsettings
-import (
- "go.wit.com/log"
+import (
"go.wit.com/gui/gui"
+ "go.wit.com/log"
)
// This initializes the main object
// You can only have one of these
func New(p *gui.Node) *LogSettings {
- if myLogGui != nil {return myLogGui}
+ if myLogGui != nil {
+ return myLogGui
+ }
myLogGui = new(LogSettings)
myLogGui.parent = p
myLogGui.groups = make(map[string]*flagGroup)
@@ -19,16 +21,22 @@ func New(p *gui.Node) *LogSettings {
// Returns true if the status is valid
func (d *LogSettings) Ready() bool {
- if d == nil {return false}
- if ! d.parent.Ready() {return false}
- if (d.win == nil) {
+ if d == nil {
+ return false
+ }
+ if !d.parent.Ready() {
+ return false
+ }
+ if d.win == nil {
d.draw()
}
return d.ready
}
func (d *LogSettings) Update() bool {
- if ! d.Ready() {return false}
+ if !d.Ready() {
+ return false
+ }
return true
}