b7da3b2c2ce5a8b9dea43837bfa85a03ee447073
[kiosk.git] / gcal_trigger.py
1 #!/usr/bin/env python3
2
3 from typing import Tuple
4
5 import constants
6 import globals
7 import trigger
8
9
10 class gcal_trigger(trigger.trigger):
11     def get_triggered_page_list(self) -> Tuple[str, int]:
12         if globals.get("gcal_triggered"):
13             print("****** gcal has an imminent upcoming event. ******")
14             return (constants.gcal_imminent_pagename, trigger.trigger.PRIORITY_HIGH)
15         else:
16             return None
17
18
19 # globals.put('gcal_triggered', True)
20 # x = gcal_trigger()
21 # x.get_triggered_page_list()