57801 Commits

Author SHA1 Message Date
Chris Beck
da41bf9968 rename "main" compilation unit "wesnoth.cpp" to match executable 2014-06-29 09:39:40 -04:00
Boldizsár Lipka
d577938307 Don't ignore txt files. 2014-06-29 14:14:08 +02:00
Turuk
f9cad251d0 LoW S10: Use alternate objective macro
{ALTERNATIVE_OBJECTIVE_CAPTION} used instead to remove translation
issues.
2014-06-29 08:11:26 -04:00
Elvish_Hunter
b0b40ebe86 Lua: added wesnoth.get_all_vars() function 2014-06-29 11:15:46 +02:00
Ignacio R. Morelle
37a8e25b60 Demote "skipping textdomain" error to warning level
The "no location found for '<path>', skipping textdomain" error message
is usually inoffensive and merely means that there is a textdomain
declaration pointing to a directory that doesn't exist, so it shouldn't
really be an error. Since we don't have anything midway between warning
and info messages, this should remain in place as a warning for WML
coders typoing textdomain declarations or forgetting to include their
add-on's translations with it.
2014-06-28 21:43:14 -04:00
Chris Beck
9e2563a5cf Merge branch 'more_wmi_menu_items' 2014-06-28 21:38:15 -04:00
Chris Beck
c11ba80a53 Keep context menu open after selecting "more" or "earlier items"
We remember the last location of the context menu, and in this
case rebuild the menu and relaunch in the same place.
2014-06-28 21:37:05 -04:00
Ignacio R. Morelle
8ebc3bcd0d Fix missing images in the test scenario context menu
Both instances refer to the "All" editor palette's icon in 1.10.x, moved
and redrawn during 1.11.x so it doesn't really fit in this menu anymore.
So my logic is, why not put the BLEND() IPF to test?
2014-06-28 21:31:17 -04:00
David Mikos
dc050f9731 Merge branch 'master' of https://github.com/wesnoth/wesnoth 2014-06-29 10:37:03 +09:30
David Mikos
36d7a5b0f0 Pause whiteboard recruit animation. 2014-06-29 10:36:31 +09:30
Chris Beck
d684826446 Merge branch 'wmi_pager' 2014-06-28 20:53:26 -04:00
Chris Beck
f24f6adee1 add wmi pager class, to allow unlimited wml menu items
The pager is held by the play_controller and wraps around the
wmi_container, if there are too many items it adds "More Items"
or "Earlier Items" entries. These entries have special reserved
ids, if they are selected the pager traps them.

Future work might be to allow the page_size_ to be selected in
the preferences, that is currently left as a variable to make
it easy to support this.
2014-06-28 20:47:12 -04:00
Ignacio R. Morelle
0441ad9d66 Add missing field to constructor initializer list
Issue found by Coverity.
2014-06-28 19:16:24 -04:00
Ignacio R. Morelle
2ac434dd2c campaignd: Catch boost::bad_function_call exception
Isssue found by Coverity.

This exception is thrown if an empty boost::function object is called.
Theoretically should never happen unless the request handlers table
wasn't initialized correctly/was tampered with.
2014-06-28 18:32:09 -04:00
Ignacio R. Morelle
786789b2d7 campaignd: Log errno to stderr if deleting an add-on archive failed
Unhandled remove() return value issue found by coverity.

This is about the most we can do about this here since internal server
errors like this shouldn't matter to clients (remove() failing is only
an issue if write_config() somehow fails or the same add-on is
reuploaded later).

Note to self: sanitize campaignd logging later so we can actually
distinguish between informational and error messages without including
the word "error" or "failure" and variations thereof in each line.
2014-06-28 18:13:22 -04:00
Boldizsár Lipka
f46eaebad4 Don't ignore CMakeLists. 2014-06-28 14:17:49 +02:00
David Mikos
23a3d15b66 Fix bug 22231: movement continuation in whiteboard.\n\nProblem was that the whiteboard was not initialized and the select or action function that is called with the hotkey for select/move/attack couldn't see the partial whiteboard movements. 2014-06-28 18:01:19 +09:30
Mark de Wever
34126ca66a Fix compilation with CMake. 2014-06-28 10:21:59 +02:00
Chris Beck
089f9e9239 add copyright notice 2014-06-28 00:17:08 -04:00
Ignacio R. Morelle
559e03c071 Add missing include guards 2014-06-27 22:30:36 -04:00
Ignacio R. Morelle
fc13d09019 notifications.cpp uses _(), include gettext.hpp
Fixes Windows builds.
2014-06-27 22:30:35 -04:00
Ignacio R. Morelle
0050fdda65 Readd copyright notices
Apparently lost in commit cb5a9a0d28ed4761272fcad65001c376445cc7d6.
2014-06-27 22:30:34 -04:00
Ignacio R. Morelle
fc1afefccb Resort wesnoth-main_SRC in CMakeLists.txt 2014-06-27 21:59:27 -04:00
Ignacio R. Morelle
fc834885e2 Resort CodeBlocks project file 2014-06-27 21:56:07 -04:00
Chris Beck
ed3453f742 move some utility files to utils folder 2014-06-27 19:06:18 -04:00
Chris Beck
10a6f4bf38 cleanup notifications preprocessor instructions, for readability 2014-06-27 18:26:36 -04:00
Chris Beck
d2edec5921 move notifications files to their own folder 2014-06-27 18:14:45 -04:00
Chris Beck
14fc744d9e fixup SDL2 notifications
fixes up series of commits:
cb5a9a0d28ed4761272fcad65001c376445cc7d6
fafb03bafb72b16572e2a794fbd0210879c8d26f
2014-06-27 18:05:53 -04:00
Chris Beck
33ae8d7398 move bar drawing code from display to unit_drawer
That's the only place it is used.
2014-06-27 17:53:48 -04:00
Chris Beck
6fd7845597 Merge branch 'master' of git://github.com/wesnoth/wesnoth 2014-06-27 16:35:10 -04:00
Chris Beck
fafb03bafb fixup SDL2 compilation 2014-06-27 16:34:51 -04:00
gfgtdf
ea61f1759b Merge pull request #226 from gfgtdf/config_comparision
add operators ==,!= (attribute_value, std::string)

previously comparisions like c["a"] = "b" were evaluated by 
inline bool operator==(const std::string &a, const t_string &b) 
by casting atribute_value to std::string, and const char * to t_string

we fix this by adding explicit equality operator for these cases.

Not creating t_string also results in significant preformance improvements in some cases.
2014-06-27 22:33:42 +02:00
Chris Beck
cb5a9a0d28 add display chat manager, notifications support outside game_display
The functionality of tracking observers and displaying chat messages
is moved to a manager class, which the gui owns.

The functionality of displaying notifications is similarly moved out
of the game_display and to a private namespace. (Static singleton
pattern seems okay here since there really won't need to be more
than one of these for a single application, it seems.)
2014-06-27 15:57:57 -04:00
gfgtdf
5089669eb9 extend attibute_value unit test 2014-06-27 21:05:43 +02:00
gfgtdf
606becd24b fix unit(_type)::resistance_filter_matches
fix use of operator == (atribute_value, char*)
2014-06-27 19:21:10 +02:00
gfgtdf
484d926c30 fixup use of operator !=(attribute_value, const char*)
since we don't use t_string's == operator anymore in this case, c["a"]
!= "" will evaluate to true in case of "a" beeing not existent. To get
the desired behaviour we need to use the .empty() method.

I also add an assert in map_generation for a possible segfault that i
noticed during fixing this.
2014-06-27 19:16:35 +02:00
gfgtdf
852b698132 add operators !=(attribute_value, std::string) 2014-06-27 17:56:06 +02:00
gfgtdf
8d8248f369 fixup 'add operators == (attribute_value, std::string)'
we need to keep the code form using these functions in case of c["a"] ==
0
2014-06-27 16:36:46 +02:00
gfgtdf
4d73031680 add operators == (attribute_value, std::string) 2014-06-27 16:36:45 +02:00
Chris Beck
b0e407ac66 move halo::manager from play_controller to display
Also this removes the need to have it in the editor.
2014-06-27 10:36:15 -04:00
Chris Beck
1010fbee77 pass halo::manager as an argument to unit frame redraw fcn 2014-06-27 09:52:31 -04:00
Chris Beck
2b42441214 Merge branch 'master' of git://github.com/wesnoth/wesnoth 2014-06-27 00:03:36 -04:00
Chris Beck
6666dca651 fixup safebool syntax in halo::handle
There was a subtle flaw introduced by using safebool in halo_record,
but defining the handle as a pointer to this -- the pointer also
is castable to bool so it makes mistakes very easy. We replace the
safe bool stuff with a function "valid" of halo_record, and fixup
the places that were supposed to be using this test.

Also move the NO_HALO variable back to the header.

fixes up commit 82c6b98907d9709aef0d23a3846c1e75ac48e1d5
2014-06-27 00:03:15 -04:00
gfgtdf
06a3a859fa remove unneeded variable 2014-06-27 05:17:42 +02:00
gfgtdf
5739429c39 remove unneeded variable 2014-06-27 05:17:41 +02:00
gfgtdf
8f9b5414b5 make a variable const 2014-06-27 05:17:40 +02:00
gfgtdf
139d6252dd add update_label function to saved_game 2014-06-27 05:17:39 +02:00
Chris Beck
83d9976526 Merge branch 'master' of git://github.com/wesnoth/wesnoth 2014-06-26 22:22:06 -04:00
Chris Beck
a226e6dc10 fixup halos segfaulting
fixes up commit 82c6b98907d9709aef0d23a3846c1e75ac48e1d5

Use smart "handles" for halos which have been added to a halo
manager. The handles remember what manager they came from, and
delete themselves automatically on destruction.

This wasn't an issue when haloes were basically managed by a
C library, but if we want to get rid of the static singleton
system, the handles need to be smarter than just int's.
2014-06-26 22:18:57 -04:00
Ignacio R. Morelle
9e447d1e3a gui2/taddon_filter_options: Allow filtering TC core add-ons 2014-06-26 20:54:37 -04:00