Commit Graph

149 Commits (792a98e824c88a90473b8c011dd4a6bea1891f51)

Author SHA1 Message Date
Buginator 0064e7151b Get rid of scrap.c/h, no longer needed.
Noticed by dak180


git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/branches/qt-trunk@10834 4a71c877-e1ca-e34f-864e-861f7616d084
2010-07-10 21:10:47 +02:00
Buginator 0cf96267e6 MSVC fixes.
*NOTE* You *must* get the Qt: Framework, or Qt SDK, and set it up correctly!


git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/branches/qt-trunk@10824 4a71c877-e1ca-e34f-864e-861f7616d084
2010-07-10 21:10:46 +02:00
Buginator e65f2688e7 Stage two merge.
Add new files for Qt.
Remove old files
Update build system (linux).
Remove SDL.
Remove QuesoGLC.
Remove Fontconfig & other all dependencies it had.  

CC & mingw (windows) & MSVC build systems are *NOT* updated / working yet.

**NOTE** MSVC people check types.h, "bool" != "BOOL" ! "bool" is a byte, "BOOL" is a int.

r8503 - r10787 (from  Qt branch)


git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/branches/qt-trunk@10813 4a71c877-e1ca-e34f-864e-861f7616d084
2010-07-10 21:10:44 +02:00
Per Inge Mathisen 338bc9e322 Move all hard-coded colours (except map preview ones) into the palette file. Pass a PIELIGHT to widgSetColour() instead of RGB.
git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@10466 4a71c877-e1ca-e34f-864e-861f7616d084
2010-04-12 11:59:30 +02:00
Per Inge Mathisen 806268790f Move default form colours into external palette file.
git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@10457 4a71c877-e1ca-e34f-864e-861f7616d084
2010-04-12 11:59:29 +02:00
Cyp 05575109b5 Try to clean up includes, fix missing extern on declaration of DataHash[]. 2010-03-10 13:31:27 +01:00
Christian Ohm 3cea69221b Fix warning on Macs.
git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@10117 4a71c877-e1ca-e34f-864e-861f7616d084
2010-03-04 19:07:43 +01:00
Christian Ohm 0ec360cff8 Fix an uninitialized variable warning on Macs.
git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@10113 4a71c877-e1ca-e34f-864e-861f7616d084
2010-03-04 19:07:43 +01:00
Buginator c2fc183703 Fix a dangling pointer issue concerning the text input.
patch reviewed by vexed.

fixes ticket:1480
Thanks to the excellent detective work by Ai_Tak !


git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@9784 4a71c877-e1ca-e34f-864e-861f7616d084
2010-02-13 23:04:58 +01:00
Buginator 6a083086e2 Frontport r9650
"Add a error message about not being able to (re)allocate a string"

git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@9706 4a71c877-e1ca-e34f-864e-861f7616d084
2010-02-09 20:28:12 +01:00
Cyp a99ef4ba19 logical: Logical updates.
git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@9655 4a71c877-e1ca-e34f-864e-861f7616d084
2010-02-09 20:28:05 +01:00
Cyp 6ddb1eadb2 cpp: Add extern "C" {} in headers.
git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@9336 4a71c877-e1ca-e34f-864e-861f7616d084
2010-02-09 20:27:21 +01:00
Per Inge Mathisen d1ca417ef2 Remove redundant code and improve asserts.
git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@9321 4a71c877-e1ca-e34f-864e-861f7616d084
2010-02-09 20:27:19 +01:00
Guangcong Luo 1685f723be Fix two warnings in scrap.c in Mac OS X.
git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@9316 4a71c877-e1ca-e34f-864e-861f7616d084
2010-02-09 20:27:18 +01:00
Per Inge Mathisen baa0ac2188 Purely stylistic changes to make it easier to read this code for mistakes.
git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@9131 4a71c877-e1ca-e34f-864e-861f7616d084
2010-02-09 20:04:32 +01:00
Guangcong Luo 357de2a6cb Apply patch #1330 provided by Cyp - Add unicode support to text boxes and game-chat
git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@9101 4a71c877-e1ca-e34f-864e-861f7616d084
2010-02-09 20:04:29 +01:00
Christian Ohm 254f657427 Really fix #1338 (crash when joining IP).
git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@8997 4a71c877-e1ca-e34f-864e-861f7616d084
2010-02-09 20:04:08 +01:00
Guangcong Luo 8edc0bd26a Allow AI difficulty slider to be dragged for longer than 2 seconds.
git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@8600 4a71c877-e1ca-e34f-864e-861f7616d084
2010-01-30 17:12:48 +01:00
Buginator 0d2a13a119 Fix a strange issue on some laptops, that have mapped their numpad enter key to the normal "return/enter" key.
Either key can now be used to submit the text your typing.

This fixes ticket:1055
NOTE: We *still need* unicode support!
(Multibyte support, and we should NOT use char, we need to switch to wchar_t)

(r8425)

git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@8527 4a71c877-e1ca-e34f-864e-861f7616d084
2009-11-28 19:34:14 +01:00
Buginator d6261ced17 Add new debug flag "input" to be used for input (keyboard/ mouse) issues.
Add allot more debugging for the input routine(s) to help find keymap issues.
*Change* Add a user friendly (numpad) clarification to the keymap editor, and also color it yellow.
*Change* Rename "Multiplayer Options" to "Multiplayer Options / Alliance dialog" to clarify what this is used for.

(r8376)

git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@8518 4a71c877-e1ca-e34f-864e-861f7616d084
2009-11-28 19:34:13 +01:00
Buginator 0aff0b46cf Add a new debug flag type, LOG_FATAL.
This is used to differentiate LOG_ERROR (which is a *non* fatal error, but a error none the less) and fatal errors which result in program termination with no *visible* output (on windows/macs) on our end because of the crappy GUI functions so we usually dump it to stderr.txt and there is no clue that the program had to exit for whatever reason.

Hopefully, this will be helpful to windows people so they can differentiate between *our* exit/abort routines, and crashes that occur in drivers which look exactly the same since they get dumped back to the desktop with no visible clue why.

LOG_FATAL is *always* on in both debug & release builds.

On LOG_FATAL debug lines, on windows, we now throw up a modal dialog box with the current error message.  At this time, this only happens when we have a error, and we use abort() right after the error, which makes it fatal.

That explains why this touches ~60 files :)


git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@8320 4a71c877-e1ca-e34f-864e-861f7616d084
2009-11-22 16:19:51 +01:00
Per Inge Mathisen ae9bc582be As seen in http://forums.wz2100.net/viewtopic.php?f=30&t=3922 there is a
fake limitation on the cost of a droid in the design screen. This patch
fixes it by an ugly hack in the widget code. Closes ticket:994
Patch reviewed and approved by Buginator.


git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@8275 4a71c877-e1ca-e34f-864e-861f7616d084
2009-11-22 16:19:44 +01:00
i-nod f9cb87f05a Changed widget definition to a hex style.
git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@8070 4a71c877-e1ca-e34f-864e-861f7616d084
2009-09-28 22:20:54 +02:00
Christian Ohm d70c4a8de2 Initialize some possibly uninitalized variables to make optimized debug builds
easier.

git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@7853 4a71c877-e1ca-e34f-864e-861f7616d084
2009-09-27 19:06:32 +02:00
Buginator f0d0bd7ebe Fixes a dangling pointer issue with a global.
In certain circumstances, if you try to abort out of a MP game (maybe SP as well), it would crash after deleting the widget, since it was still referencing the pointer in the global.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6732 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-28 01:40:19 +00:00
Dennis Schridde aac41748dc Bump copyright
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6617 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-10 18:01:48 +00:00
Dennis Schridde cbbc58d1e9 Move files which extend a c std library header to a filename of similar name
Extension functions dealing with ...
 * strings are in string_ext.h
 * stdio (namely printf variants) are in stdio_ext.h
 * math are in math_ext.h

These headers are no longer included by frame.h

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6613 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-10 17:23:09 +00:00
Giel van Schijndel 810fac209b * Wrap all file lists in the automake and win32 makefiles across lines such that there's only one file on each line
* Alphabetically sort the file lists

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6144 4a71c877-e1ca-e34f-864e-861f7616d084
2008-10-13 13:04:37 +00:00
Per Inge Mathisen 704117f85c Fix various doxygen errors and warnings
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5992 4a71c877-e1ca-e34f-864e-861f7616d084
2008-09-11 18:25:34 +00:00
Giel van Schijndel 34b73dcdb5 Invert logically wrong assertion (i.e. assert a pointer to be non-null rather than null)
This fixes bug #12047 (assert failure as soon as you open one of the design/manufacture/construct/research windows)

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5583 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-19 14:28:36 +00:00
Giel van Schijndel 5554dbe695 * Move duplicated code to fetch a tabbed widget form by ID to a function of its own: widgGetTabbedFormById
* In widgSetTabs depend on functions widgGetNumTabMajor and widgGetNumTabMinor respectively instead of duplicating their code


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5573 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-18 15:17:29 +00:00
Dennis Schridde 022315eef0 Hardcode top_srcdir to make building from non-topdir possible, dont depend on the touch command, fix LDFLAGS to not depend on the removed TARGET variable
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5476 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-10 20:10:16 +00:00
Dennis Schridde 302a557478 Rename "raw" Makefiles to "win32" Makefiles
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5402 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-06 14:29:04 +00:00
Dennis Schridde 45f23a4926 Merge commit 'HEAD@{3}'
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5347 4a71c877-e1ca-e34f-864e-861f7616d084
2008-06-28 22:32:44 +00:00
Dennis Schridde 050ec39c11 Use the (also new in this commit) relative variants of the directories almost everywhere.
Exception is when generating the .wz files, where we need the path to the build directory and building a reverse relative path to $(srcdir) will be messy.
Also silence submake.mk a great deal.
Bug #11883 should be fixed now for the most part.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5325 4a71c877-e1ca-e34f-864e-861f7616d084
2008-06-24 23:41:52 +00:00
Dennis Schridde fd2bfb0e0f Prepare for another fix for parts of bug #11883: Issues with the improved raw Makefiles
- Rename Makefile.raw to lowercase


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5321 4a71c877-e1ca-e34f-864e-861f7616d084
2008-06-24 22:48:45 +00:00
Dennis Schridde 73b35ab8d6 Rename top_srcdir/top_builddir to abs_top_srcdir/abs_top_builddir, to make this more obvious.
Their use is currently flawed, since it will not work in directories with spaces in them... (


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5319 4a71c877-e1ca-e34f-864e-861f7616d084
2008-06-24 20:19:54 +00:00
Dennis Schridde 9bd8b24921 Boost raw Makefiles
- Use PACKAGE, PACKAGE_VERSION, remove VERSION
- Allow out-of-source-dir builds (mkdir build && cd build && make -f ../Makefile.raw)
- Move config.mk from $(top_srcdir)/makerules/config.mk to $(top_builddir)/config.mk
   When keeping current behaviour (srcdir=builddir), this means: Move it from makerules into the main directory


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5308 4a71c877-e1ca-e34f-864e-861f7616d084
2008-06-23 13:54:47 +00:00
Giel van Schijndel 13aeeafc97 Less ASSERT(false, ... crap, use ASSERT(!"description", ... instead
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5301 4a71c877-e1ca-e34f-864e-861f7616d084
2008-06-22 18:22:49 +00:00
Giel van Schijndel 855ec725d4 Use sstrcpy|sstrcat instead of strlcpy|strlcat for manipulation of statically sized strings
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5176 4a71c877-e1ca-e34f-864e-861f7616d084
2008-05-25 13:46:49 +00:00
Per Inge Mathisen 13fa22fcbf Revert r4932 and try a different fix instead, checking the number of tabs
actually allocated, and resetting the currently highlighted tab if it is
out of bounds.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@4998 4a71c877-e1ca-e34f-864e-861f7616d084
2008-05-09 20:32:31 +00:00
Giel van Schijndel 61c8bbc4b9 * Don't "Guarantee nul-termination" after snprintf as snprintf does that itself already (per the C99 spec)
* Use strlcpy for copying strings instead of snprintf "%s"
 * Don't cast the return value from vsnprintf to (void)
 * When we use va_start make sure to use va_end as well...
 * Fix indentation


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@4785 4a71c877-e1ca-e34f-864e-861f7616d084
2008-04-26 14:21:41 +00:00
Per Inge Mathisen cefef3651c Add doxygen markup to projectile code
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@4759 4a71c877-e1ca-e34f-864e-861f7616d084
2008-04-24 17:23:11 +00:00
Per Inge Mathisen 5533cf265a Add more doxygen markup, especially for widget code.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@4758 4a71c877-e1ca-e34f-864e-861f7616d084
2008-04-24 17:06:25 +00:00
Per Inge Mathisen e853c606f8 A little bit of indentation cleanup so that the code can be read.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@4733 4a71c877-e1ca-e34f-864e-861f7616d084
2008-04-21 17:12:56 +00:00
Per Inge Mathisen 650447d833 Fix crash when trying to delete text coming from a clipboard paste.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@4732 4a71c877-e1ca-e34f-864e-861f7616d084
2008-04-21 17:11:48 +00:00
Per Inge Mathisen 81c88dbf38 Purely cosmetic cleanup
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@4731 4a71c877-e1ca-e34f-864e-861f7616d084
2008-04-21 17:02:46 +00:00
Giel van Schijndel 4a17aeeec7 * Delete unused and empty function StartTacticalScroll()
* Mark the parameters for several functions as WZ_DECL_UNUSED (for those functions that require the parameter as part of their interface)


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@4701 4a71c877-e1ca-e34f-864e-861f7616d084
2008-04-20 17:17:50 +00:00
Per Inge Mathisen be566a7d6d Add -Wcast-align and -Wmissing-declarations to autoconf debug builds, and fix warnings.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@4403 4a71c877-e1ca-e34f-864e-861f7616d084
2008-03-28 23:28:44 +00:00
Per Inge Mathisen b58826bce4 Fix assert in widget code by simply increasing maximum major tabs that can be shown.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@4397 4a71c877-e1ca-e34f-864e-861f7616d084
2008-03-28 18:41:53 +00:00