Age | Commit message (Collapse) | Author |
|
and shuffle around
some code for SetupColorsAndInitialWindow. Because we know that after a successful
load all windows are removed we can setup default windows in this function, and
show ShowJoinStatusWindow in PACKET_SERVER_MAP.
-Setup the global _network_join_status for ShowJoinStatusWindow in the only two
places where the function is called, instead of inside it.
-Turn the join status window into a modal window of the network window so it
stays on top.
|
|
parent. If the
query has no parent (eg give money, rename waypoint), the global function
HandleOnEditText is used.
|
|
-(re)set _rename_[id/what] to -1 to catch invalid calls (main_gui.c)
-Only invalidate widget of pause/ff instead of whole window (main_gui.c)
-Remove numbering from WE_ and WC_ as it's not needed, also remove
non-existing windowclasses (window.h, openttd.h)
-Give names to some of the enums (window.h)
-In UninitWindowSystem not only free malloc'd widgets, but also reset the z-array (window.c)
-Some coding style, comments, etc.
|
|
when it is raised (Maedhros)
|
|
of a running game.
This is only possible in SP (or in the intro menu). During game play you will
get a confirmation window when applying the changes as some actions can crash
OpenTTD and/or make your current game unplayable.
|
|
chat message was for the wrong player (off by one)
|
|
of NewGRF settings.
|
|
i++)'-type for loops with 'for (i = 0; i < w->widget_count; i++)'-type for loops
|
|
|
|
Just provide the number of tiles per side, a pointer to a test function, the tile to start searching and voila.
Fixes [FS#364] by removing a lengthy and suboptimal random search pattern.
Thanks Rubidium.
|
|
'disable electrified railways'.
(original patch by maedhros, ideas: peter1138, Darkvater, Rubidium, Patrick, Eddi|zuHause, ..)
|
|
Unicode/UTF-8 and the option for fonts rendered by FreeType. Language changes to come.
|
|
patch setting instead of
always sending to teammate if the patch is on even if you do not have any allies. So
with setting off you always send to 'all players', with setting on you send to teammates
if you have any, otherwise to all players.
|
|
chat-destination when chatting with <ENTER> or 'T' instead of the game choosing one for you automatically.
|
|
positioning WDP_AUTO = -1)
|
|
random size. So to get a size
you need it between 1 and 3 and therefore there is no one-on-one correspondence between
widget-numbers and town-size. Based on a patch by Maedhros
|
|
a new/loaded game. The
good thing is, we got rid of even more magic code (tm)
|
|
to MaxZoomInOut
with a zoom parameter and a pointer to the window which's viewport we want to zoom.
|
|
DoZoomInOutWindow (enable, disable
buttons depending on calling window, game-mode); handle it by broadcasting messages
to the calling window, because that knows how and what buttons to set.
|
|
and rewrite the function
a bit more sensibly.
|
|
keypress event was sent
twice. due to e->we.keypress.cont not being set to false. Also indent the switch
statements for some coding style bonus points.
|
|
information from
invalid players (eg spectators) which could lead to crashes.
|
|
This didn't cause any
bugs so far because the 'click' element was at the same position in the union for both
events.
|
|
-Codechange: member color_map is more related to random color, rename it as such
|
|
is only plain panel,
WWT_IMGBTN must contain an image for drawing. Renamed WWT_PANEL_2 to WWT_IMGBTN_2
because that is what it is. Added WWT_PUSHBTN that is either just a pushable button,
or a textbutton, which text's drawn dynamically independent of widget.
|
|
The last parameter should point to the end of the buffer (eg lastof(buf))
Courtesy of Tron.
|
|
|
|
|
|
|
|
SHIFT+ENTER (SHIFT+T)
sends a message to all players, CTRL+ENTER (CTRL+T) sends a message to all
team mates and ENTER (T) sends a message to teammates if you have any, otherwise
to all players.
The chat-window now also shows what kind of message is being sent. Shortcut
functionality has not been changed (ENTER sends message, ESC closes window)
|
|
PLAYER_SPECTATOR and
put it into player.h where it belongs (instead of map.h)
|
|
With networking
disabled hardcode _networking/_network_available to zero and let the compiler
handle all optimizations.
|
|
|
|
items. While
here have a little go at the MenuWndProc() function for a little cleanup.
|
|
toolbar. So
normally they will start at the left side of the parent button except when
they would stick out, then align with the top toolbar's right side. This
also means the extra parameter 'x' is not needed, it is deducted from the
widget position.
|
|
on the length of the strings in that list.
|
|
drop downs when there are no companies
|
|
down when pressing shift.
The _fastforward and _pause bool are not exactly used as bool.
So, when doing test with them, amek it so that the will appear as such
|
|
Another step toward merging XTDwidget.
The only two files not converted (window.h and widget.c) will be done at the very last commit)
|
|
Another step toward merging XTDwidget.
The only two files not converted (window.h and widget.c) will be done at the very last commit)
|
|
It made no sense to maintain 8 nearly identically arrays when a single one can do the job
Also made the two buttons always use half of the bottom width each, even when resizing
|
|
WindowEvent, which is now a struct
|
|
This means that in the intro menu the 'Quit' button immediatelly quits
and the 'Quit' in the menu of the normal game and scenario editor
immediatelly quits when the 'autosave_on_exit' patch is turned on.
This is the same way as the OS/window manager initiated quits, like
alt-F4 and the 'x' in the (OS/window manager drawn) title bar of OTTD.
|
|
called or have no effect.
|
|
network game password handling somewhere were it belongs to
|
|
plain confusing
All the struct holds is a simple colour gradient, so using a simple array with 8 entries is more clear
Also add the names of colour the gradients as enum
|
|
{' -> '} else {', tabs between code and comment, etc.
|
|
parameter of FillDrawPixelInfo() and simplify some expressions
|
|
functions and variables all match eachother
|
|
invalid ones
-Codechange: use IsValidXXX where ever possible
Note: both changes to prepare for new pool system, which needs those changes.
For every pool there are 2 ugly lines, which will be removed when done
implementing new pool system.
Based on FS#13 by blathijs, partly implemented.
|