/* Return whether the context's primary window is ordered in or not */
- (BOOL)isOrderedIn;
-/* Return whether the context's primary window is key */
+/*
+ * Return whether the context's primary window is the main window.
+ * Since the terminals other than terminal 0 are configured as panels in
+ * Hengband, this will only be true for terminal 0.
+ */
- (BOOL)isMainWindow;
+/*
+ * Return whether the context's primary window is the destination for key
+ * input.
+ */
+- (BOOL)isKeyWindow;
+
/* Invalidate the whole image */
- (void)setNeedsDisplay:(BOOL)val;
return [[self->angbandView window] isMainWindow];
}
+- (BOOL)isKeyWindow
+{
+ return [[self->angbandView window] isKeyWindow];
+}
+
- (void)setNeedsDisplay:(BOOL)val
{
[self->angbandView setNeedsDisplay:val];
for (i=0; i < ANGBAND_TERM_MAX; i++) {
AngbandContext *context =
(__bridge AngbandContext*) (angband_term[i]->data);
- if ([context isMainWindow]) {
+ if ([context isKeyWindow]) {
termFont = [context angbandViewFont];
break;
}
for (mainTerm=0; mainTerm < ANGBAND_TERM_MAX; mainTerm++) {
AngbandContext *context =
(__bridge AngbandContext*) (angband_term[mainTerm]->data);
- if ([context isMainWindow]) {
+ if ([context isKeyWindow]) {
break;
}
}