rubidium
310be2e5be
(svn r17843) -Codechange: move the details drawing code of the content window to a separate function
2009-10-22 14:26:18 +00:00
rubidium
0501bd1325
(svn r17842) -Fix: DrawStringMultiLine would in some corner case, top = bottom + 1, draw the string
2009-10-22 14:24:11 +00:00
rubidium
c90885a17e
(svn r17841) -Codechange: move state changes from OnPaint to OnInvalidate for the content gui.
2009-10-22 13:57:39 +00:00
rubidium
547677a782
(svn r17840) -Codechange: use the new pool's concepts (caching + not zeroing). Improves average CargoPacket con/destruction time by ~20%, MoveTo/Append by 5-10% and application performance by up to 2%.
2009-10-21 19:42:49 +00:00
rubidium
1528b64a68
(svn r17839) -Codechange: implement the concept of 'caching' pool items to pools, that is instead of 'free' push the unused items in a linked list and use them on 'malloc'. Also add the concept of zeroing, or actually not zeroing, on new for pool items.
2009-10-21 19:38:50 +00:00
rubidium
0ebe525e5b
(svn r17838) -Document: the Pool struct's template parameters
2009-10-21 15:40:50 +00:00
rubidium
a4d054eabc
(svn r17837) -Fix (r17812): comment erroneously mentioned feeder share
2009-10-21 10:05:22 +00:00
rubidium
69b8e8e755
(svn r17836) -Codechange: split the CargoPacket constructor for creating 'real' new CargoPackets and saveload. For saveload we do not need to set anything except two variables (the rest is always overwritten by the load), for new 'real' cargo also pass the source_xy; dereferencing st before calling is easier than resolving st->index back to st and then dereferencing. Also don't set loaded_at_xy because that is of no importance when not loaded in a vehicle.
2009-10-20 22:24:34 +00:00
smatz
79906f7ffe
(svn r17835) -Codechange: constify few variables
2009-10-20 22:17:39 +00:00
rubidium
f4e0b3642b
(svn r17834) -Fix [FS#3274] (r17808): you got paid a bit too much... ofcourse the index of the source station generally doesn't equal the location of said station.
2009-10-20 22:06:33 +00:00
alberth
fe717d033e
(svn r17833) -Codechange: Depot gui should use relative widget coordinates for clicking.
2009-10-20 21:41:44 +00:00
smatz
396d16e2ec
(svn r17832) -Codechange: make Alberth happier
2009-10-20 21:27:44 +00:00
smatz
232d7bc4f4
(svn r17831) -Codechange: move code used for adding map indicators of the smallmap to separate functions
2009-10-20 21:26:56 +00:00
frosch
21fdc65ce4
(svn r17830) -Fix [FS#3276]: Some windows already need their window_number when setting up smallest size (e.g. for DParams). So assign it earlier in Window::InitializeData instead of dealing with each window separately.
2009-10-20 21:25:25 +00:00
smatz
b06da82c62
(svn r17829) -Codechange: move code used for adding vehicles and town names to minimap to separate functions
2009-10-20 20:57:30 +00:00
alberth
af9c76eb6f
(svn r17828) -Codechange: Variable declaration code style, and a few comment typo-ish fixes.
2009-10-20 20:06:25 +00:00
frosch
ffb729ac9e
(svn r17827) -Codechange: Deduplicate some lines of code.
2009-10-20 20:01:56 +00:00
frosch
8df61c0fc0
(svn r17826) -Codechange: GetRoadVehLength() is only used in one file, make it static.
2009-10-20 19:55:09 +00:00
smatz
30ebe379c7
(svn r17825) -Change: 'animate' the 'center to current position' button in SmallMapWindow when pressed
2009-10-20 19:38:51 +00:00
frosch
a138f604ee
(svn r17824) -Fix (r4594): _date_fract runs from 0 to 73 since r2041. Variable 0x09 should not.
2009-10-20 19:30:50 +00:00
alberth
7658bac2b5
(svn r17823) -Codechange: Use top of the matrix widget as offset for row calculation in autoreplace window.
2009-10-20 18:39:45 +00:00
smatz
bfedac1166
(svn r17822) -Codechange: move 'extra viewport' code from smallmap_gui.cpp to viewport_gui.cpp
2009-10-20 18:38:38 +00:00
smatz
cfbf57a54f
(svn r17821) -Codechange: make more mathods of SmallMapWindow private
2009-10-20 18:15:42 +00:00
translators
d4888b103e
(svn r17820) -Update from WebTranslator v3.0:
...
traditional_chinese - 6 changes by josesun
indonesian - 1 changes by prof
2009-10-20 17:45:11 +00:00
smatz
49d0db19a4
(svn r17819) -Codechange: replace magic constant by symbolic constant
2009-10-20 17:36:06 +00:00
rubidium
86031d434d
(svn r17818) -Codechange: iterate the cargo list from the back when trying to merge packets. Chances are higher that the last packet (in the FIFO-ish queue) is mergeable with the to be added package. If a train gets loaded packets get split up and put into the different carriages, at unload they are unloaded in the same order so the last in the FIFO-ish queue is likely the packet it can merge with.
...
This results in a 5-10% performance improvement of CargoList's Append/MoveTo without performance degradation of AgeCargo.
2009-10-20 16:36:35 +00:00
rubidium
06c55863ca
(svn r17817) -Codechange: MakeWater actually made sea tiles, so rename it to MakeSea and unduplicate the code to make sea, rivers and canals.
2009-10-20 12:31:11 +00:00
rubidium
9696e3e39b
(svn r17816) -Codechange: move the CargoList invalidation-after-saveload to the function that handles the CargoPackets instead of spreading it around over the saveload files. Also add some code to validate whether the caches are valid; to be removed later when no problems turn up
2009-10-20 12:20:53 +00:00
rubidium
cfcf3159b2
(svn r17815) -Fix [SDL]: asynchronious drawing caused extra unresponsiveness during map generation; disable the threading while generating a map
2009-10-19 20:32:05 +00:00
rubidium
7f6d9d8c11
(svn r17814) -Codechange: there's no need to invalidate the cache in the constructor of a CargoList; the list is empty, the CargoList is calloc-ed so all caches are 0.
2009-10-19 15:36:35 +00:00
rubidium
08ac51fada
(svn r17813) -Codechange: unify the CargoPacket related coding style
2009-10-19 09:15:47 +00:00
rubidium
2cca30d2e3
(svn r17812) -Codechange: move the feeder_share cache from CargoList to VehicleCargoList; saves 512 bytes per station and 1-2% on CargoList::MoveTo.
2009-10-19 01:12:51 +00:00
rubidium
40a32bb976
(svn r17811) -Codechange: make HasEditBoxFocus a private function of QueryString because it's not meant to be used for determining whether the given widget actually has focus (it also checks the OSK edit box)
2009-10-18 20:56:38 +00:00
frosch
b8f8c60839
(svn r17810) -Codechange/Fix: Add assert_tcompile() and use it.
...
OTTD's traditional assert_compile() does not work inside templates for gcc compilers, static_assert() does though.
The new assert_tcompile() resolves into static_assert() if present, or into a runtime assert() else.
2009-10-18 20:26:29 +00:00
frosch
fea06c5755
(svn r17809) -Fix: MSVC compilation.
2009-10-18 18:47:43 +00:00
rubidium
e613107e02
(svn r17808) -Codechange: remove write 'access' from all of CargoPacket's variables
2009-10-18 17:53:34 +00:00
rubidium
f11cebfe9b
(svn r17807) -Codechange: move all 'updates' just after the 'load' constructor of CargoPackets to the constructor call itself
2009-10-18 17:52:44 +00:00
rubidium
4ad30fecde
(svn r17806) -Codechange: split CargoPacket's 'afterload' to a separate function
2009-10-18 17:47:38 +00:00
translators
8a34641f48
(svn r17805) -Update from WebTranslator v3.0:
...
norwegian_bokmal - 1 changes by Utvik
norwegian_nynorsk - 1 changes by Utvik
2009-10-18 17:45:10 +00:00
rubidium
62a6e9509b
(svn r17804) -Codechange: move the CargoPacket 'invalidation' when stations get removed to CargoPacket.
2009-10-18 17:26:10 +00:00
frosch
41037308c0
(svn r17803) -Codechange: Remove update_(left|right) in favour of the rebuild flag of GUIList.
2009-10-18 16:31:27 +00:00
frosch
60188f496d
(svn r17802) -Feature(ette) [FS#1862]: [NewGRF] Textstack support for CB 37.
2009-10-18 15:36:30 +00:00
rubidium
f76de82679
(svn r17801) -Codechange: for StationCargoLists the 'loaded_at_xy' does not matter when merging CargoPackets
2009-10-18 14:30:37 +00:00
rubidium
138e7233bc
(svn r17800) -Codechange: first steps into making CargoList a template
2009-10-18 14:28:26 +00:00
alberth
c52a26a73f
(svn r17799) -Codechange: industry view window uses pure nested widgets.
2009-10-18 14:10:59 +00:00
alberth
f1e885e0d2
(svn r17798) -Codechange: Introduce new constant WD_PAR_VSEP_WIDE for large amount of space between text.
2009-10-18 13:59:25 +00:00
alberth
00723e694f
(svn r17797) -Codechange: Use parameters of new function, introduce constants for hardcoded numbers.
2009-10-18 13:56:09 +00:00
alberth
29028b3f8a
(svn r17796) -Codechange: Move drawing of the industry info to its own function.
2009-10-18 13:40:11 +00:00
rubidium
2e766884f6
(svn r17795) -Codechange: split cargolist into one for vehicles and one for stations.
2009-10-18 13:39:00 +00:00
michi_cc
94003b455c
(svn r17794) -Feature: [OSX] Implement automatic fallback font selection for OSX.
2009-10-17 22:36:43 +00:00