Commit Graph

80 Commits (ebda8193ef6855e6df19332b75380d8061e889e7)

Author SHA1 Message Date
Sven Eberhardt ebda8193ef Replace NULL by nullptr in C++ sources
We don't support pre-C++0x any more, so nullptr should be fine everywhere (except in the plain C source files)
2016-11-02 19:58:02 -04:00
Julius Michaelis 8d2f2846b5 Fix mac build
Also move some stuff around once again…
2016-10-21 01:25:48 +02:00
Julius Michaelis 34a9a1de8d Twiddle with header organization: lib{misc,c4script} do no longer include GL/glew.h
(Yes, it is just that complicated.)
2016-10-20 18:46:32 +02:00
Sven Eberhardt 4869eff787 Allow joining to editor games through startup network dialogue 2016-08-10 19:35:39 -04:00
Nicolas Hake eabca223f5 Update all copyright notices for 2016 2016-04-03 20:24:42 +02:00
Nicolas Hake 493c276126 Rewrite header inclusions to #include "path/to/file.h" style 2016-04-03 20:24:42 +02:00
Lukas Werling 8811356141 Make C4GamePadControl manage all controllers
The available gamepads are distributed automatically among players.

This also implements controller hot-plugging: It is possible to start a
game without a controller and plug it in later, and to reconnect a
controller after plugging it out.
2016-02-23 17:06:59 +01:00
Lukas Werling 9f69c650d6 Use icons for all controller buttons
The icons currently only show Xbox 360 controller labeling. The icon set
also includes icons for PlayStation controllers, so we could extend this
in the future.
2016-02-21 18:27:02 +01:00
Nicolas Hake d737dc1b05 Remove C4Video, StdVideo
Video recording and playback only worked on Windows, and recording only
handled video, not game audio. As such, it was of fairly limited use,
and there's lots of software available these days that handle both.
2015-12-28 11:43:41 +01:00
Sven Eberhardt 019cc0d583 Enable immediate tooltips on mouse-over-event for unlabeled icons in lobby and scenario selection (#1132). 2015-12-06 21:03:54 -05:00
Sven Eberhardt d6751bff84 Fix crash on context or dropdown menu in GUI dialogues in editor mode (#856). 2015-09-12 02:51:55 -04:00
Sven Eberhardt 3edcc2b043 GUI: Readded "using Window::MouseInput;" in Screen to make the overload clear.
It got lost when moving some functions from protected to public.
2015-09-03 23:04:26 -04:00
Sven Eberhardt 9e6f7896ac Make MouseInput, MouseEnter and MouseLeave public in GUI elements.
They were public in some and protected in other classes and they're also called from several places outside the GUI.
2015-09-03 22:42:29 -04:00
David Dormagen 196f528201 Merge branch 'master' into Controls
Conflicts:
	planet/Objects.ocd/HUD.ocd/FancyGridMenu.ocd/DefCore.txt
	planet/Objects.ocd/HUD.ocd/GridMenu.ocd/DefCore.txt
	planet/Objects.ocd/Helpers.ocd/Dummy.ocd/Graphics.png
	planet/Objects.ocd/Items.ocd/Tools.ocd/WindBag.ocd/Script.c
	planet/Objects.ocd/Items.ocd/Weapons.ocd/Javelin.ocd/Script.c
	planet/Objects.ocd/Libraries.ocd/ClonkControl.ocd/Script.c
	planet/Objects.ocd/Libraries.ocd/Constructor.ocd/ConstructionMenu.ocd/Script.c
	planet/Objects.ocd/Libraries.ocd/Constructor.ocd/Script.c
	planet/Objects.ocd/Libraries.ocd/Flag.ocd/Marker.ocd/Script.c
	planet/Objects.ocd/Libraries.ocd/Producer.ocd/Script.c
	planet/Objects.ocd/Structures.ocd/Flagpole.ocd/Script.c
	planet/Objects.ocd/Structures.ocd/Pump.ocd/Script.c
	src/game/C4Game.cpp
	src/gamescript/C4GameScript.cpp
	src/gui/C4GameMessage.cpp
	src/landscape/C4Landscape.cpp
2015-06-03 22:32:36 +02:00
Nicolas Hake e21a5bdd44 Rename BoundBy to Clamp
"BoundBy" sounds like a predicate. "Clamp" is a common function name for
the operation in graphics processing, so it should be familiar to users.
2015-02-12 23:05:55 +01:00
Günther Brammer 5bcedb5bbf Remove some redundant #includes 2015-01-25 18:53:48 +01:00
David Dormagen 8146e3e748 C4GUI::C4Scrollbar: corrected friend-declaration (ck)
This was no error on VS 2013, though..
2015-01-15 21:06:58 +01:00
Günther Brammer 69f8ca27ec Move C4ApplicationSec1Timer to StdScheduler.h
There is nothing "Application" specific about this class.
2015-01-03 21:06:25 +01:00
David Dormagen c42d94e3cf Script GUI: fixed a bug where a GUI's rectangle was incorrect 2015-01-03 15:30:30 +01:00
David Dormagen 6476b0b026 Script GUIs: fixed saving & loading 2014-10-23 23:29:14 +02:00
David Dormagen 2a78b77bda renamed C4GuiWindow to C4ScriptGuiWindow to increase expressivness and reduce similarity with C4Gui* 2014-10-13 18:48:03 +02:00
David Dormagen 049088be78 CustomGUIs: major rework of layouting & controls; better integration of C4GUI 2014-10-11 11:29:02 +02:00
David Dormagen 7319f7b3cc rewrite of C4GuiWindow to use C4GUI stuff wherever possible 2014-10-05 16:46:14 +02:00
David Dormagen 5722339e83 Merge branch 'master' into Controls
Conflicts:
	planet/Objects.ocd/HUD.ocd/Controller.ocd/Script.c
	planet/Objects.ocd/Libraries.ocd/Structure.ocd/Script.c
	src/gamescript/C4GameScript.cpp
	src/gui/C4GameMessage.cpp
	src/gui/C4Gui.h
	src/gui/C4GuiDialogs.cpp
	src/gui/C4GuiWindow.cpp
2014-08-13 11:52:41 +02:00
Nicolas Hake 4a3ece5f5d Don't split UTF8 when handling accelerators (#983)
Marking up accelerator keys still assumed all characters were one byte
wide. Change this to accept multi-byte characters.
2014-03-11 00:25:38 +01:00
Nicolas Hake e0dc30c59a Update copyright notices
As discussed in http://forum.openclonk.org/topic_show.pl?tid=2917, I
have merged all copyright notices into a single file and referenced that
merged file from each source file.

For the updated source files, the timeline has been split into three
parts:
 1. Pre-RWD code (before 2001)
 2. RWD code (2001 through 2009)
 3. OpenClonk code (2009 and later)
All pre-RWD copyright notices have been left intact, as have RWD-era
copyright notices where the file did not have a RedWolf design copyright
notice but only individual author ones. All copyright notices of the
OpenClonk era have been replaced by a single notice ranging from the
first recorded year to the current year (2013). Mape code did not get a
OpenClonk Team copyright notice because it is somewhat separate from the
main OpenClonk codebase and has only been touched by Armin Burgmeier.
2013-12-23 13:03:19 +01:00
Tobias Zwick dd3de2f0c9 Merge branch 'issue-251' 2013-12-09 21:45:54 +07:00
Tobias Zwick fe2a400c02 replace global function GetTime() with class function C4TimeMilliseconds::Now() 2013-12-07 21:27:01 +07:00
Tobias Zwick 3c4ba7f494 do not lazy-initialize C4GUI::tLastChange time 2013-12-07 14:04:35 +07:00
Tobias Zwick 95c3b0b75a fix scrollbar drawing and remove code duplication (#1004) 2013-12-05 10:40:17 +07:00
Tobias Zwick 94c618d153 add new type C4TimeMilliseconds for time measurements to solve problems when GetTime() overflows (#251)
The new type C4TimeMilliseconds behaves for the most part like a uint32_t but is overflow-proof in comparisons.
In some places, a 0-value (or uint_max) of the variable storing the time had the special meaning "not set yet". This has been resolved by having it as a pointer to C4TimeMilliseconds with NULL meaning that it has not been set yet.
2013-12-04 19:35:07 +07:00
Tobias Zwick 7b9c1d5a9e refactor: consistently use time_t t... variables for times in network system, scheduler, gui
The network used to cast GetTime() to int, but GetTime() is an unsigned long. This might cause problems if GetTime() returns big integers (see #251). To solve this, the StdSchedulerProc interface had to be extended with another function in order to eliminate the magic return value -1 of GetNextTick for "no scheduled execution".
2013-11-29 17:28:04 +07:00
Nicolas Hake e753bf8168 Replace ResTable with a proper dictionary
ResTable (the main system string table) was a home-grown hashmap that
did not cope with collisions at all. Since we already have a proper
dictionary in C4LangStringTable, use that instead.
2013-10-19 19:28:54 +02:00
Sven Eberhardt d976802ca8 Allow copying of message boxes (Ctrl+C). 2013-09-22 16:30:55 +02:00
Günther Brammer 7967d94a59 Merge StdFont.cpp and C4Fonts.cpp 2012-11-12 02:30:16 +01:00
Tobias Zwick ba1a2cbdad add missing strings for localisation of controls definition dialogue 2012-10-07 18:45:50 +02:00
Tobias Zwick 46156e3f1c show tooltip for C4D_MouseSelect using the property "Tooltip"
+ remove references to the old and obsolete "help mode"
2012-04-15 12:09:54 +02:00
Günther Brammer 15ebf70ab1 win32: Move C4GUI::DialogWindow platform code to C4WindowWin32.cpp 2012-04-01 22:16:59 +02:00
Günther Brammer c865021716 gtk: Fold C4GtkWindow into C4Window 2012-04-11 04:15:33 +02:00
Günther Brammer feb13288fa gtk: Replace C4GUI::DialogWindow XLib with gtk calls 2012-04-04 03:42:33 +02:00
Günther Brammer 40de33ca3c win32: Make sdl-mainloop option work
As it doesn't have the editor, this is only useful for compiling
more of our code on more platforms.
2012-03-23 22:53:56 +01:00
Günther Brammer ae322aa847 Remove some dead code 2012-03-04 21:44:20 +01:00
Günther Brammer 1cafba4be8 Rename files implementing C4AbstractApp and C4Window 2011-10-03 17:19:24 +02:00
Günther Brammer 2b6f4432de Rename lpDDraw to pDraw 2011-10-03 16:30:18 +02:00
Günther Brammer d835ab002a Rename CStdWindow to C4Window 2011-08-27 23:12:01 +02:00
Günther Brammer 8039a35791 Rename CStdApp to C4AbstractApp 2011-08-27 16:20:39 +02:00
Nicolas Hake e0610576bd Return NULL instead of ((T*)false) from some functions 2011-09-28 00:48:46 +02:00
Günther Brammer 9bc61db360 copyright notices update 2011 2011-09-01 16:58:52 +02:00
Nicolas Hake fe747db554 Clean up copyright notices
Use real names for copyright attribution wherever they are known,
drop duplicates
2011-09-01 12:47:54 +02:00
Günther Brammer 3f7e879ffe win32: Use Unicode APIs for the user interface 2011-04-03 15:47:02 +02:00