68335 Commits

Author SHA1 Message Date
ln-zookeeper
478c75bdb5 Fixed [item]s not receiving ToD lighting 2017-04-15 21:13:46 +03:00
Charles Dang
1ff3f7e251 Story Viewer: allow returning to the previous part during text fade-in 2017-04-16 00:39:11 +11:00
Charles Dang
120aa0e6ca Story Viewer Label: ensure sufficient top padding for text
[ci skip]
2017-04-16 00:31:32 +11:00
Charles Dang
e3e0320ff0 Story Viewer: use consistent variables for scaling calculations (fixup e150c7c) 2017-04-16 00:14:58 +11:00
Charles Dang
5b08c1f37b Story Viewer: fix background images with no scaling specified being scaled 2017-04-16 00:13:23 +11:00
Charles Dang
e150c7c070 Story Viewer: fix situational incorrect scaling of background images 2017-04-15 23:36:16 +11:00
Charles Dang
63403c90a5 Story Viewer: made text fade smoother 2017-04-15 22:32:53 +11:00
Charles Dang
61992429d0 Avoid copy initialization of colors when possible 2017-04-15 21:10:42 +11:00
Charles Dang
3c4e6f0f71 Unit: code cleanup 2017-04-15 20:56:02 +11:00
Jyrki Vesterinen
d1df341371 Fix: with --new-widgets advanced preferences may not shrink on deselect
Partial relayout does not make a grid yield more space to its parent grid.
Thus, only firing partial relayout as a result of hiding a widget is *not*
safe.

Fixed by triggering full relayout instead, like the code already does
without --new-widgets.
2017-04-15 12:19:31 +03:00
Jyrki Vesterinen
efb857a319 Fix build with Visual Studio 2013 2017-04-15 10:40:01 +03:00
Charles Dang
41e0e21d5d Unit: implemented a todo for a bool state count variable 2017-04-15 17:14:03 +11:00
Charles Dang
3f8d3cca78 Added more documentation to the unit class 2017-04-15 17:13:09 +11:00
Charles Dang
6addb2e12f Cleaned up some comments and an include related to intrusive_ptr
The include in attack_type is no longer needed since I changed its management to use shared_ptrs
2017-04-15 15:34:36 +11:00
gfgtdf
c4625197d7 less unit copying 2017-04-14 23:45:13 +02:00
Charles Dang
2349296836 Small improvement to ebeeae3 2017-04-15 03:19:20 +11:00
Charles Dang
ebeeae3872 Unit: refactor upkeep handling to use a visitor pattern 2017-04-15 01:30:16 +11:00
Wedge009
ade221e303 Merge pull request #981 from mbrickn/patch-1
Updated links to wesnoth.org to use https
2017-04-14 22:52:06 +10:00
gfgtdf
25d7110c8c use std::scoped_ptr where appropriate 3 (filesystem code) 2017-04-14 13:48:37 +02:00
gfgtdf
4bdfc41c06 use std::scoped_ptr where appropriate 2 (gui2 code) 2017-04-14 13:48:36 +02:00
gfgtdf
e4926328f9 use std::scoped_ptr where appropriate 1 2017-04-14 13:48:35 +02:00
Charles Dang
8a1263c8b5 Don't exit to desktop if using debug unit command with invalid type name (FR #25619) 2017-04-14 21:47:45 +11:00
Charles Dang
1310dc62f3 Removed alpha key from unit and unit_type
This appears to be an unused relic from before the animation system was more fleshed out, and doesn't appear
to currently have any purpose, nor is it documented anywhere.
2017-04-14 18:10:09 +11:00
Charles Dang
f9004970c4 Story Viewer: don't only validate presence of [part] tags under [story]
I forgot control tags like [switch] are allowed under [story]. This should hopefully fix bug #25655
2017-04-14 13:47:12 +11:00
gfgtdf
1adeb98dd8 attempt to fix assertion in connect_engine
http://gna.org/bugs/?25656
2017-04-14 03:49:11 +02:00
Nils Kneuper
ed1aa0d4a1 fixed changelog sorting order 2017-04-13 22:56:51 +02:00
Nils Kneuper
084c4c5f44 updated Lithuanian translation 2017-04-13 22:56:18 +02:00
gfgtdf
59ceddf917 improve listbox::clear() performance. (#982)
previously listbox::clear() removed all elements one by one.
This was quite ineffective since due to the listbox always-one-element-selected behviour this required calculating which is the next element in this list in the current order. Which then again requires resorting of the whole list since due to the list content change (removal) the order cache is cleared.

this could also fix https://gna.org/bugs/?25504

this also fixed a bug in generator::clear()
2017-04-13 16:53:40 +02:00
Charles Dang
ada84d6aaf Unit: removed an unimplemented function and renamed two others for clarity 2017-04-13 23:29:07 +11:00
Charles Dang
d0dda79a68 WIP effort to document the unit class
This commit only contains formatting and documentation changes.
2017-04-13 23:29:06 +11:00
Celtic Minstrel
c97adacfa7 Re-fix poison not being shown 2017-04-13 00:58:52 -04:00
Celtic Minstrel
f6b4917027 Some cleanup to the unit frame code
Explanations:
- Removed all the redundant constructor initializers
- Don't initialize the color members.
  (Otherwise what's the point of it being an optional?)
- Some collapsing of stuff like ? true : false and similar cases
- Use operator* and operator-> instead of get() for optionals
-
2017-04-13 00:05:23 -04:00
Celtic Minstrel
f3a574da46 Fix for GNA584 2017-04-12 23:37:39 -04:00
Maxwell Paul Brickner
de76ba017f Updated links to wesnoth.org to use https
I just changed URLs to the wesnoth.org webpages to use https instead of http.

This will make users go directly to the webpages linked, instead of automatically being redirected to the https version by the website. 

Should be very slightly better for user experience! 😊

Please note: http://manual.wesnoth.org/ redirects to https://wiki.wesnoth.org/WesnothManual, but https://manual.wesnoth.org/ breaks, so I left it unchanged.

PS: Thank you for making an awesome game!
2017-04-12 19:30:01 -04:00
Celtic Minstrel
a8361986e9 Rename namespace util -> utils
This is because there was already a namespace utils, and having two namespaces with almost the same name is confusing.
2017-04-12 13:49:50 -04:00
Jyrki Vesterinen
f93353bebb Add an override specifier
Thanks to @matthiaskrgr for the compiler run.
2017-04-12 20:45:13 +03:00
Jyrki Vesterinen
48142dd821 Fix advanced preferences not shrinking when the player deselects them
It turns out that I had misunderstood the purpose of widget::layout_size_.
It's not a cache, it's an override. It's only set for widgets which have
been shrunk or whose sizes have otherwise been changed from the preferred
size.

As a result, commit c4be6a7ec881d74a0d46f3b068053b86bc1c7e17 ended up skipping relayout way too often.
2017-04-12 20:33:53 +03:00
Charles Dang
c57b58628c Story Viewer: implement text alpha fade-in/fade-out between screens 2017-04-13 04:01:02 +11:00
Charles Dang
e0751c1f54 GUI2: implement ability to set label alpha 2017-04-13 04:01:01 +11:00
ln-zookeeper
2f7f9a3f71 UtBS: Prevents Kaleh and Nym having purple XP bars while choices remain
This is pretty hacky and you can see the bars and numbers flicker purple during advancement, so this can be removed if a better way to achieve the same thing is implemented.
2017-04-12 19:05:04 +03:00
gfgtdf
289cf35aa2 add a comment 2017-04-12 15:31:49 +02:00
gfgtdf
75c21815f6 allow multi_page to contain differnt types of pages
although stacked_widget supports similar functionality this is currently
not easily doable from the lua gui2 api. In particular
1) stacked_widget cannot add pages dynamically
2) multi_page can only contain one type of widget.
3) a stacked_widget inside a multi_page is ineffective since it
generates many unused widgets
4) a multi_page inside a stacked_widget is just unhandy to use
2017-04-12 15:14:58 +02:00
gfgtdf
4908124f6f some clenaups
mainly adding backets to one-line if bodies
2017-04-12 15:14:58 +02:00
gfgtdf
c44de30a09 remove unused bool return value 2017-04-12 15:14:58 +02:00
Charles Dang
de8419deb7 Preferences Dialog: removed a hack related to the grid listbox usage 2017-04-12 23:40:13 +11:00
Charles Dang
c834d99556 Preferences: convert hotkey category list to a dropdown w/ checkboxes
This allows more space for the hotkey list.
2017-04-12 21:12:47 +11:00
Charles Dang
4f76c90d5c Revert erroneous change in 7d8380cd8781
These functions don't inherit from the dialog classes, they're part of MVC-style implementations.
2017-04-12 17:56:52 +11:00
Charles Dang
7d8380cd87 GUI2: marked inherited dialog functions (pre_show, etc) as virtual override
The virtual is for style consistency, the override because it should be done.
2017-04-12 17:44:51 +11:00
Charles Dang
f0dffab55a Tree View Node: rename tree_view_node_icon to tree_view_node_toggle
This better reflect its function
2017-04-12 17:00:03 +11:00
Charles Dang
da5f00c2b6 GUI2/Spacer: delegate size caluclations to the widget instead of the builder
This allows size formulae that rely on screen size variables, which can change, to correctly
update the size of the widget.
2017-04-12 16:13:43 +11:00