parent
bbfb6fc095
commit
f236c24b92
3 changed files with 13 additions and 3 deletions
|
@ -105,8 +105,9 @@ class Module(bumblebee.engine.Module):
|
|||
state.append("AC")
|
||||
else:
|
||||
charge = ""
|
||||
with open("{}/status".format(widget.name)) as f:
|
||||
charge = f.read().strip()
|
||||
try:
|
||||
with open("{}/status".format(widget.name)) as f:
|
||||
charge = f.read().strip()
|
||||
except IOError:
|
||||
pass
|
||||
if charge == "Discharging":
|
||||
|
|
|
@ -17,6 +17,9 @@ class Module(bumblebee.engine.Module):
|
|||
)
|
||||
self._text = self.parameter("text", "")
|
||||
|
||||
def update(self, widgets):
|
||||
raise Exception("test")
|
||||
|
||||
def text(self, widget):
|
||||
return self._text
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue