Merged r13124 (#16755).

git-svn-id: http://svn.redmine.org/redmine/branches/2.5-stable@13161 e93f8b46-1217-0410-a6f0-8f06a7374b81
Merged r13140 and r13142 (#16795).

git-svn-id: http://svn.redmine.org/redmine/branches/2.5-stable@13162 e93f8b46-1217-0410-a6f0-8f06a7374b81
Merged r13141 (#16926).

git-svn-id: http://svn.redmine.org/redmine/branches/2.5-stable@13163 e93f8b46-1217-0410-a6f0-8f06a7374b81
Merged r13125 (#16700).

git-svn-id: http://svn.redmine.org/redmine/branches/2.5-stable@13164 e93f8b46-1217-0410-a6f0-8f06a7374b81
Merged r13107 (#16710).

git-svn-id: http://svn.redmine.org/redmine/branches/2.5-stable@13165 e93f8b46-1217-0410-a6f0-8f06a7374b81