aboutsummaryrefslogtreecommitdiff
path: root/engines/glk/frotz/windows.h
diff options
context:
space:
mode:
authorPaul Gilbert2019-03-05 18:49:53 -0800
committerPaul Gilbert2019-03-05 18:50:01 -0800
commitb8966ff1ad4fe95cdb7be33e94d18d757031f03a (patch)
tree6a235025dade32b64661b5820d510fcf83974be8 /engines/glk/frotz/windows.h
parenta15a39ab4fa17b0d556b474f5135c6b45e610ffb (diff)
downloadscummvm-rg350-b8966ff1ad4fe95cdb7be33e94d18d757031f03a.tar.gz
scummvm-rg350-b8966ff1ad4fe95cdb7be33e94d18d757031f03a.tar.bz2
scummvm-rg350-b8966ff1ad4fe95cdb7be33e94d18d757031f03a.zip
GLK: FROTZ: Moving updating colors and current window into Window class
Diffstat (limited to 'engines/glk/frotz/windows.h')
-rw-r--r--engines/glk/frotz/windows.h24
1 files changed, 23 insertions, 1 deletions
diff --git a/engines/glk/frotz/windows.h b/engines/glk/frotz/windows.h
index dce980b7c8..9d9af2aa00 100644
--- a/engines/glk/frotz/windows.h
+++ b/engines/glk/frotz/windows.h
@@ -119,6 +119,11 @@ public:
}
/**
+ * Equality operator
+ */
+ inline bool operator==(const Window &rhs) { return this == &rhs; }
+
+ /**
* Cast operator for testing if the window has a proper Glk window attached to it
*/
operator bool() const { return _win != nullptr; }
@@ -147,6 +152,16 @@ public:
* Clear the window
*/
void clear();
+
+ /**
+ * Update colors for the window
+ */
+ void updateColors();
+
+ /**
+ * Update colors for the window
+ */
+ void updateColors(uint fore, uint back);
};
/**
@@ -187,9 +202,16 @@ public:
void setWindow(int win);
/**
+ * Get the current window
+ */
+ Window &currWin() {
+ return _windows[_cwin];
+ }
+
+ /**
* Get the current window pointer
*/
- winid_t currWin() const {
+ winid_t glkWin() const {
assert(_windows[_cwin]._win);
return _windows[_cwin]._win;
}