49870 Commits

Author SHA1 Message Date
J. Tyne
597fcf49d7 Stop sending invalid actions between the redo and undo stacks.
If an action could not be undone, it makes no sense to "redo" it, and
vice-versa.

(In particular, certain movement undos produce a message stating
"Possible abuse of [allow_undo]" without crashing, but then redoing
that move caused an assertion failure before this change.)
2012-05-20 21:56:37 +00:00
Ignacio R. Morelle
28b20f8aaf addon/mg: New add-on installation prompt for add-ons with VCS/.pbl files
Until now there was only a single, verbose prompt for the .pbl case.
Since people may use a VCS to contribute to an add-on without having a
.pbl file, that case is also now covered by this commit.

There's a single prompt with a list of sensible content that might be
"permanently lost" on installation. The list may contain VCS or .pbl
files for now, but perhaps at some point in the future someone might
want to make it into a full list of extra files or something.
2012-05-20 21:37:17 +00:00
Alexander van Gessel
ef19b2586a Add a case for pulling from non-initialized repositories 2012-05-20 22:05:42 +01:00
Ignacio R. Morelle
e0e55682c0 addon/mg: Consider local untracked add-ons as installed for the main list...
...and elaborate on their state in gui2::taddon_description instead

This means they get both the "Installed" (or "Published") line, and the
green highlight. gui2::taddon_description displays their detailed status
as "not tracking local version". This approach seems sensible since we
have limited space for the status line in the GUI1 Add-ons Manager
dialog.

As a side effect there's a hypothetical "Unknown" status line that's
only there to keep gcc 4.7 happy.
2012-05-20 20:42:55 +00:00
Ignacio R. Morelle
2b85532aef addon/mg: Greatly simplify describe_addon_status() 2012-05-20 20:42:31 +00:00
Sergey Popov
7c866fce16 Add simpler scons commands to examples in INSTALL. 2012-05-20 19:55:04 +00:00
Mark de Wever
3912e88b54 Remove some unneeded headers. 2012-05-20 19:19:32 +00:00
Mark de Wever
6eb1781c80 Remove some unneeded headers. 2012-05-20 19:19:29 +00:00
Mark de Wever
d1a96e91a2 Add the .tpp files to Doxygen. 2012-05-20 19:19:24 +00:00
Ignacio R. Morelle
109b644f5b addon/mg: Merge get_addon_status_gui1_color_markup()...
...into describe_addon_status()

Also moved describe_addon_status() around so it can be used for the
dependency prompt dialog later as well.
2012-05-20 18:38:18 +00:00
Anonymissimus
6b56c96ab0 mute MSVC warnings C4099 and disable them globally
according to mordante's suggestion
2012-05-20 16:30:10 +00:00
Anonymissimus
25eefaedea VC9 projectfile update
- add new files

- remove HAS_ITERATOR_DEBUGGING=0 define, since the functionality is
too useful and it should be _HAS_ITERATOR_DEBUGGING with a leading _
2012-05-20 16:30:00 +00:00
Anonymissimus
7edc7677b9 CB projectfile update 2012-05-20 16:29:51 +00:00
Mark de Wever
202e833210 Replace tconst_duplicator with tconst_clone.
Both did about the same, so removed one of them.
2012-05-20 14:00:17 +00:00
Mark de Wever
cbc0cf5827 Move the enumerate file to utils.
Seems to fit better in that directory.
Also set the properties of the new file.
2012-05-20 13:50:25 +00:00
Mark de Wever
50bc28dedb Add some logging when a WML child is not found.
This happens rather often in valid code as well, so make it debug
messages. But at least in debug mode it's possible to get more
information regarding the missing child.
2012-05-20 09:56:20 +00:00
Mark de Wever
eb165d1885 Allow better error messages for missing children.
The caller's code still need to be changed but at least gives the option
to create better error messages.
2012-05-20 09:56:17 +00:00
Mark de Wever
9ebb260d01 Add config::has_child().
This allows to easily query whether a certain child exists.
2012-05-20 09:56:13 +00:00
Mark de Wever
018ff27c62 Fixes a GCC warning in a better way.
It replaces 2012-05-19T21:30:22Z!shadowm@wesnoth.org. It also adds a generic warning for unreachable code.
2012-05-20 09:56:10 +00:00
Mark de Wever
0ef2b762ef Add clang 3.0 compiler fixes.
The clang compiler was not happy with the uages of the enumerate stream
operator macros. This minor change makes clang happy again.
2012-05-20 09:56:07 +00:00
Mark de Wever
cefb8ee330 Add hint for the compiler that FAIL is a failure.
In some contexts the compiler may warn since the wml_exception has no
attribute indicating it will never return. The answer is throwing a
dummy exception.
2012-05-20 09:56:05 +00:00
Elvish_Hunter
276faf7956 Removed the remaining instances of 'okay' and lower-caps 'ok'...
...from mainline campaigns, as pointed by Espreon
2012-05-20 09:53:12 +00:00
Mark de Wever
4ed714ea78 Move tconst_clone to its own file.
This allows code outside of the gui code to use it as well.
2012-05-20 09:26:19 +00:00
Ignacio R. Morelle
a46cc6ed2a Various indentation/spacing fixes for the players_changelog 2012-05-20 08:33:08 +00:00
Ignacio R. Morelle
071bd055bd Add changelog entries for the Add-ons help section,
...and update players_changelog

All of the add-on client changes mentioned in the full changelog affect
the UI, so all of them have been copied over.
2012-05-20 08:25:08 +00:00
Ignacio R. Morelle
7d44fc73b5 addon/mg: Update changelog 2012-05-20 08:14:19 +00:00
Ignacio R. Morelle
f4e5f7b1da addon/mg: Improve display of long add-on titles and authors in the main list
* Long titles now can get word-wrapped up to a limit of two lines (after
   which they are truncated). This allows to display "Invasion from the
   Unknown" at 800x480 without truncating it at "Un" (20 characters).
   The horizontal limit for word-wrapping is 150 pixels.

 * Author names are now truncated at 14 characters instead of 16, adding
   an ellipsis if necessary to suggest the possibility of reading the
   full name elsewhere (in this case, in the Description window).
2012-05-19 23:03:49 +00:00
Ignacio R. Morelle
c5b9288dda addon/mg: Include add-on status lines below their titles in the add-ons list
This replaces the previous color-keyed items approach with color-keyed
status lines, as well.

Additionally, tweaked the color-keying logic.
2012-05-19 21:30:59 +00:00
Ignacio R. Morelle
c5c5993e1f gui2: Prevent "control reaches end of non-void function" warning on gcc 4.7
This is a quick fix and mordante should review it later.

gcc 4.7 doesn't seem to be happy with gui2::tplacer_::build()'s switch
statement and appears to expect more cases despite
gui2::tplacer_::tgrow_direction doesn't have more members. The warning
in question:

  src/gui/auxiliary/placer.cpp:43:1: error: control reaches end of non-void function [-Werror=return-type]
2012-05-19 21:30:22 +00:00
Nils Kneuper
2e813ed5b3 updated Galician translation 2012-05-19 21:02:12 +00:00
Steven Panek
0d84d6028a Pass two for improvements on the add-ons help section.
Thanks to Alarantalara for suggestions and input.
2012-05-19 21:00:54 +00:00
Ignacio R. Morelle
e7756f5766 gui2/taddon_description: "Outdated in the server" -> "Outdated on server" 2012-05-19 20:33:42 +00:00
Ignacio R. Morelle
eff649a7cf gui2/taddon_description: Tweak status lines for Published add-ons
Instead of displaying just "Published" for a published add-on regardless
of whether it is installed or not, display "Published, not installed"
when it isn't. This is a rarer situation than a published add-on being
installed, hence we don't need a "Published, installed" status line.
2012-05-19 20:33:22 +00:00
Mark de Wever
72126809c1 Use the new tplacer_ class in the pane.
Used for both placement and size. The value is hard-coded at the moment,
but other settings have been tested.

The code is used to experiment with a different approach of the
implementation of a listbox.
2012-05-19 20:33:10 +00:00
Steven Panek
57a8fab097 Pass one for improvements on the add-ons help section. 2012-05-19 20:07:20 +00:00
Mark de Wever
3c66f576d4 Adds helper code to assist in widget placement.
The code is used to experiment with a different approach of the
implementation of a listbox.
2012-05-19 20:06:35 +00:00
Mark de Wever
2d9f94398d Adds code for writing enumerate stream operators.
The code has been copy-pasted from another project I've been working on, with
some minor adaptions to compile with Wesnoth:

- Removed dependency on C++11 and use the support in boost instead.

- Changed the error reporting to use the Wesnoth code.
2012-05-19 20:02:59 +00:00
Ignacio R. Morelle
4282b64c43 Remove declaration of an external that isn't defined anywhere 2012-05-19 20:01:40 +00:00
Mark de Wever
cd5bc7f11a Added FAIL and FAIL_WITH_DEV_MESSAGE macros.
These macros allow to throw an wml_exception without any condition. This
can be used when a code path is reached that should be unreachable with
valid WML.
2012-05-19 19:35:44 +00:00
Fabian Müller
050cff18a7 patch #3270 Fix for bug #19120 2012-05-19 15:57:33 +00:00
Steven Panek
11254903b9 Updated the Ukrainian translation. 2012-05-19 15:03:35 +00:00
Ignacio R. Morelle
3037876524 addons/help: Mention the possibility of sorting the add-on list...
...by clicking on the column headers

Evidence suggests that either this has never been an obvious feature or
people have a strange obsession with downloading the first entries
before trying out the rest. It's not visually obvious, anyway, so we
might as well mention it.
2012-05-19 11:02:25 +00:00
Silas Brill
653fa89d7a Made unit_mover and animation_unit_placer inherit from boost::noncopyable 2012-05-19 10:50:42 +00:00
Ignacio R. Morelle
36e9fd78cc addon/mg: Horrible, horrible hack to ensure the add-ons list (GUI1)...
...is naturally sorted by titles rather than case-sensitive ids

This is quite a hack and it's only here in case I don't figure out a
better solution later before 1.11.0 (or get hit by a truck). It works
and that's all that matters here nowadays, anyway.

The problem this solves is basically the following:

 * The internal add-ons list is sorted by id (case-sensitively)

 * The add-ons list in GUI1 is unsorted by default, following the row
   insertion order

 * The row insertion order is that of the internal add-ons list iterator order

 * Sorting rows by title isn't possible because of the Publish/Delete entries

 * Many add-ons have titles that don't reflect their ids at all, not to
   mention that users obviously would prefer case-insensitive sorting.

A quite better solution would be to have the add-ons list take care of
all this by itself, but I haven't figured out a way yet short of
implementing a whole custom class for it (which could actually turn out
to be more efficient by getting rid of the id duplication) with
specialized iterators.
2012-05-19 10:44:14 +00:00
Ignacio R. Morelle
feceecb5e2 addon/client: Mark addons_client class as noncopyable 2012-05-19 09:13:41 +00:00
Ignacio R. Morelle
64a34fb5b7 addon/info: Remove trivial copy constructor, make remaining single-argument constructor explicit 2012-05-19 09:13:28 +00:00
Elvish_Hunter
a129e14874 [find_path]: fixed this_unit not being restored in certain situations 2012-05-19 08:49:45 +00:00
Mark de Wever
283653b31b Fix a bug in the new tcontrol constructor.
The constructor called a virtual function in it's constructor, which is
not a good idea, even worse it was pure virtual in the control class.
2012-05-19 08:46:20 +00:00
Mark de Wever
77e6286c0a Let the tcontrol use the new twidget constructor. 2012-05-19 08:46:17 +00:00
Mark de Wever
ff08f9dd5b Add a second constructor for twidget.
This constructor takes a builder object to do its building.
2012-05-19 08:46:15 +00:00