summaryrefslogtreecommitdiff
path: root/linuxstatus/common.go
diff options
context:
space:
mode:
Diffstat (limited to 'linuxstatus/common.go')
-rw-r--r--linuxstatus/common.go34
1 files changed, 34 insertions, 0 deletions
diff --git a/linuxstatus/common.go b/linuxstatus/common.go
new file mode 100644
index 0000000..c4aea10
--- /dev/null
+++ b/linuxstatus/common.go
@@ -0,0 +1,34 @@
+// This creates a simple hello world window
+package linuxstatus
+
+import (
+ "go.wit.com/log"
+)
+
+func (hs *LinuxStatus) Show() {
+ log.Log(CHANGE, "linuxStatus.Show() window")
+ hs.window.Show()
+ hs.hidden = false
+}
+
+func (hs *LinuxStatus) Hide() {
+ log.Log(CHANGE, "linuxStatus.Hide() window")
+ hs.window.Hide()
+ hs.hidden = true
+}
+
+func (hs *LinuxStatus) Toggle() {
+ log.Log(CHANGE, "linuxStatus.Toggle() window")
+ if hs.hidden {
+ hs.window.Show()
+ } else {
+ hs.window.Hide()
+ }
+}
+
+func (hs *LinuxStatus) Ready() bool {
+ if me == nil {return false}
+ if hs == nil {return false}
+ if hs.window == nil {return false}
+ return me.ready
+}