forked from mirror/OpenTTD
(svn r1082) Feature: Chat toolbar
- to chat with all players press Return (or Shift-T) and type in the message - Press Return again to send the message
This commit is contained in:
4
window.c
4
window.c
@@ -554,6 +554,7 @@ Window *AllocateWindowDesc(const WindowDesc *desc)
|
||||
} else {
|
||||
if (pt.x == WDP_CENTER) pt.x = (_screen.width - desc->width) >> 1;
|
||||
if (pt.y == WDP_CENTER) pt.y = (_screen.height - desc->height) >> 1;
|
||||
else if(pt.y < 0) pt.y = _screen.height + pt.y; // if y is negative, it's from the bottom of the screen
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1366,6 +1367,9 @@ void RelocateAllWindows(int neww, int newh)
|
||||
} else if (w->window_class == WC_STATUS_BAR) {
|
||||
top = newh - w->height;
|
||||
left = (neww - w->width) >> 1;
|
||||
} else if (w->window_class == WC_SEND_NETWORK_MSG) {
|
||||
top = (newh - 26); // 26 = height of status bar + height of chat bar
|
||||
left = (neww - w->width) >> 1;
|
||||
} else {
|
||||
left = w->left;
|
||||
if (left + (w->width>>1) >= neww) left = neww - w->width;
|
||||
|
Reference in New Issue
Block a user