From 795e23c05d81ca40f46f38bac0872272de6f9851 Mon Sep 17 00:00:00 2001 From: Paul Gilbert Date: Wed, 16 Jan 2019 21:12:03 -0800 Subject: GLK: Constifying attribute, width calc methods --- engines/glk/windows.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'engines/glk/windows.h') diff --git a/engines/glk/windows.h b/engines/glk/windows.h index c905556f9e..c917d2f04b 100644 --- a/engines/glk/windows.h +++ b/engines/glk/windows.h @@ -328,7 +328,7 @@ struct Attributes { /** * Equality comparison */ - bool operator==(const Attributes &src) { + bool operator==(const Attributes &src) const { return fgset == src.fgset && bgset == src.bgset && reverse == src.reverse && style == src.style && fgcolor == src.fgcolor && bgcolor == src.bgcolor && hyper == src.hyper; @@ -336,7 +336,7 @@ struct Attributes { /** * Inequality comparison */ - bool operator!=(const Attributes &src) { + bool operator!=(const Attributes &src) const { return fgset != src.fgset || bgset != src.bgset || reverse != src.reverse || style != src.style || fgcolor != src.fgcolor || bgcolor != src.bgcolor || hyper != src.hyper; @@ -345,17 +345,17 @@ struct Attributes { /** * Return the background color for the current font style */ - byte *attrBg(WindowStyle *styles); + const byte *attrBg(const WindowStyle *styles); /** * Return the foreground color for the current font style */ - byte *attrFg(WindowStyle *styles); + const byte *attrFg(const WindowStyle *styles); /** * Get the font for the current font style */ - FACES attrFont(WindowStyle *styles) const { + FACES attrFont(const WindowStyle *styles) const { return styles[style].font; } }; -- cgit v1.2.3