summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
authorMaxime “pep” Buquet <pep@bouah.net>2020-08-14 22:12:16 +0200
committerMaxime “pep” Buquet <pep@bouah.net>2020-08-14 22:12:26 +0200
commit03ef9c8d547872ae7aa87ecec4779bca49309225 (patch)
tree547dca2f342f7f102ec1f6e2d20776ce78bc1974 /plugins
parent96f3bd72ac2704534388d993f644ec55abdf31b2 (diff)
downloadpoezio-03ef9c8d547872ae7aa87ecec4779bca49309225.tar.gz
poezio-03ef9c8d547872ae7aa87ecec4779bca49309225.tar.bz2
poezio-03ef9c8d547872ae7aa87ecec4779bca49309225.tar.xz
poezio-03ef9c8d547872ae7aa87ecec4779bca49309225.zip
move date and time SHORT_FORMAT and LONG_FORMAT to the theme
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
Diffstat (limited to 'plugins')
-rw-r--r--plugins/display_corrections.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/plugins/display_corrections.py b/plugins/display_corrections.py
index 69df154f..cf8107ce 100644
--- a/plugins/display_corrections.py
+++ b/plugins/display_corrections.py
@@ -26,7 +26,7 @@ from poezio.plugin import BasePlugin
from poezio.common import shell_split
from poezio import tabs
from poezio.ui.types import Message
-from poezio.ui.consts import SHORT_FORMAT
+from poezio.theming import get_theme
class Plugin(BasePlugin):
@@ -56,6 +56,7 @@ class Plugin(BasePlugin):
return None
def command_display_corrections(self, args):
+ theme = get_theme()
args = shell_split(args)
if len(args) == 1:
try:
@@ -68,7 +69,7 @@ class Plugin(BasePlugin):
if message:
display = []
while message:
- str_time = message.time.strftime(SHORT_FORMAT)
+ str_time = message.time.strftime(theme.SHORT_TIME_FORMAT)
display.append('%s %s%s%s %s' %
(str_time, '* '
if message.me else '', message.nickname, ''