0ad/source/gui
elexis 3028551b91 MOVABLE idiom, const CGUI struct maps, in place move construction instead of copying temporaries during CGUI XML loading and GenerateText.
Introduce MOVABLE idiom indicating that a class can use move semantics.
Make values of CGUI struct maps holding XML data const to ensure at the
root that the data is not modified.
Use NONCOPYABLE and MOVABLE for SGUIIcon and SGUIStyle to enforce the
non-copy policy on the compiler level (until someone changes the GUI
design to make modifications needed).

As indicated by that:
  Replace copy operations by in place move operations for these CGUI
struct maps in the CGUI Xeromyces XML loading functions.
  Replace copy operations by const references for CSize and SGUIIcon in
CGUIString::GenerateTextCall and CGUI::GenerateText.
  This avoids copying of non primitive members, such as the strings and
containers of strings.

Further related cleanup to be kept separated for auditability.

Differential Revision: https://code.wildfiregames.com/D2163
Few comments on IRC by: wraitii, Itms
Tested on: gcc 9, Jenkins, partially VS2015

Refs #1984,
  NONCOPYABLE CGUISpriteInstances: 0a7d0ecdde, 8f4f8e240f, c19f3608a5
  NONCOPYABLE Image, Sprite: fb8032043b
  NONCOPYABLE GUI page: 94c57085e9
  NONCOPYABLE GUIManager: 7c2e9027c2
  NONCOPYABLE macro: 16ccae10cd

This was SVN commit r22637.
2019-08-09 17:25:55 +00:00
..
scripting Upgrade SpiderMonkey to version 45.0.2, refs #4893. 2019-08-07 22:37:43 +00:00
tests Remove trailing whitespace and whitespace in empty lines of source/ except source/third_party/. 2016-11-23 11:18:37 +00:00
CButton.cpp Implement IGUIObject settings as a template class and IGUIObject::AddSetting as a template function. 2019-08-04 02:20:08 +00:00
CButton.h Pass the GUI page pointer CGUI* to the IGUIObject and derived classes upon construction, instead of on stray cases. 2019-08-01 20:20:24 +00:00
CChart.cpp Move GetDefaultGuiMatrix to a separate file. 2019-08-04 03:52:00 +00:00
CChart.h Pass the GUI page pointer CGUI* to the IGUIObject and derived classes upon construction, instead of on stray cases. 2019-08-01 20:20:24 +00:00
CCheckBox.cpp Implement IGUIObject settings as a template class and IGUIObject::AddSetting as a template function. 2019-08-04 02:20:08 +00:00
CCheckBox.h Pass the GUI page pointer CGUI* to the IGUIObject and derived classes upon construction, instead of on stray cases. 2019-08-01 20:20:24 +00:00
CDropDown.cpp Implement IGUIObject settings as a template class and IGUIObject::AddSetting as a template function. 2019-08-04 02:20:08 +00:00
CDropDown.h Pass the GUI page pointer CGUI* to the IGUIObject and derived classes upon construction, instead of on stray cases. 2019-08-01 20:20:24 +00:00
CGUI.cpp MOVABLE idiom, const CGUI struct maps, in place move construction instead of copying temporaries during CGUI XML loading and GenerateText. 2019-08-09 17:25:55 +00:00
CGUI.h MOVABLE idiom, const CGUI struct maps, in place move construction instead of copying temporaries during CGUI XML loading and GenerateText. 2019-08-09 17:25:55 +00:00
CGUIColor.h Fix failure of the CGUIColor constructor author to call the base constructor following f236c07a56, refs 415939b59b. 2019-08-09 14:54:14 +00:00
CGUIList.h Add GPL header 2009-04-18 17:00:33 +00:00
CGUIScrollBarVertical.cpp Pass the GUI page pointer CGUI* to the IGUIObject and derived classes upon construction, instead of on stray cases. 2019-08-01 20:20:24 +00:00
CGUIScrollBarVertical.h Pass the GUI page pointer CGUI* to the IGUIObject and derived classes upon construction, instead of on stray cases. 2019-08-01 20:20:24 +00:00
CGUISeries.h Fix [19027] by using generic code for conversions and fixing a few other issues. Refs #3403. Reviewed by leper. 2017-01-06 11:14:03 +00:00
CGUISprite.cpp MOVABLE idiom, const CGUI struct maps, in place move construction instead of copying temporaries during CGUI XML loading and GenerateText. 2019-08-09 17:25:55 +00:00
CGUISprite.h MOVABLE idiom, const CGUI struct maps, in place move construction instead of copying temporaries during CGUI XML loading and GenerateText. 2019-08-09 17:25:55 +00:00
CImage.cpp Implement IGUIObject settings as a template class and IGUIObject::AddSetting as a template function. 2019-08-04 02:20:08 +00:00
CImage.h Pass the GUI page pointer CGUI* to the IGUIObject and derived classes upon construction, instead of on stray cases. 2019-08-01 20:20:24 +00:00
CInput.cpp Implement IGUIObject settings as a template class and IGUIObject::AddSetting as a template function. 2019-08-04 02:20:08 +00:00
CInput.h Pass the GUI page pointer CGUI* to the IGUIObject and derived classes upon construction, instead of on stray cases. 2019-08-01 20:20:24 +00:00
CList.cpp Implement IGUIObject settings as a template class and IGUIObject::AddSetting as a template function. 2019-08-04 02:20:08 +00:00
CList.h Pass the GUI page pointer CGUI* to the IGUIObject and derived classes upon construction, instead of on stray cases. 2019-08-01 20:20:24 +00:00
COList.cpp Implement IGUIObject settings as a template class and IGUIObject::AddSetting as a template function. 2019-08-04 02:20:08 +00:00
COList.h Pass the GUI page pointer CGUI* to the IGUIObject and derived classes upon construction, instead of on stray cases. 2019-08-01 20:20:24 +00:00
CProgressBar.cpp Implement IGUIObject settings as a template class and IGUIObject::AddSetting as a template function. 2019-08-04 02:20:08 +00:00
CProgressBar.h Pass the GUI page pointer CGUI* to the IGUIObject and derived classes upon construction, instead of on stray cases. 2019-08-01 20:20:24 +00:00
CRadioButton.cpp Pass the GUI page pointer CGUI* to the IGUIObject and derived classes upon construction, instead of on stray cases. 2019-08-01 20:20:24 +00:00
CRadioButton.h Pass the GUI page pointer CGUI* to the IGUIObject and derived classes upon construction, instead of on stray cases. 2019-08-01 20:20:24 +00:00
CSlider.cpp Implement IGUIObject settings as a template class and IGUIObject::AddSetting as a template function. 2019-08-04 02:20:08 +00:00
CSlider.h Pass the GUI page pointer CGUI* to the IGUIObject and derived classes upon construction, instead of on stray cases. 2019-08-01 20:20:24 +00:00
CText.cpp Implement IGUIObject settings as a template class and IGUIObject::AddSetting as a template function. 2019-08-04 02:20:08 +00:00
CText.h Pass the GUI page pointer CGUI* to the IGUIObject and derived classes upon construction, instead of on stray cases. 2019-08-01 20:20:24 +00:00
CTooltip.cpp Implement IGUIObject settings as a template class and IGUIObject::AddSetting as a template function. 2019-08-04 02:20:08 +00:00
CTooltip.h Pass the GUI page pointer CGUI* to the IGUIObject and derived classes upon construction, instead of on stray cases. 2019-08-01 20:20:24 +00:00
GUI.h Add C++ GUI code for drawing charts. Patch by vladislavbelov. JS will come later. Refs #3403 2016-12-07 19:03:54 +00:00
GUIbase.cpp Move CClientArea ToJSVal / FromJSVal conversion from JSI_IGUIObject (since that should be agnostic of the conversion) to CClientArea (since that defines the properties). 2019-07-26 14:47:27 +00:00
GUIbase.h MOVABLE idiom, const CGUI struct maps, in place move construction instead of copying temporaries during CGUI XML loading and GenerateText. 2019-08-09 17:25:55 +00:00
GUIManager.cpp Move CGUIManager::LoadPage to CGUIManager::SGUIPage::LoadPage, because it only operates only on that struct. 2019-08-01 20:48:05 +00:00
GUIManager.h Move CGUIManager::LoadPage to CGUIManager::SGUIPage::LoadPage, because it only operates only on that struct. 2019-08-01 20:48:05 +00:00
GUIMatrix.cpp Move GetDefaultGuiMatrix to a separate file. 2019-08-04 03:52:00 +00:00
GUIMatrix.h Move GetDefaultGuiMatrix to a separate file. 2019-08-04 03:52:00 +00:00
GUIRenderer.cpp MOVABLE idiom, const CGUI struct maps, in place move construction instead of copying temporaries during CGUI XML loading and GenerateText. 2019-08-09 17:25:55 +00:00
GUIRenderer.h MOVABLE idiom, const CGUI struct maps, in place move construction instead of copying temporaries during CGUI XML loading and GenerateText. 2019-08-09 17:25:55 +00:00
GUItext.cpp MOVABLE idiom, const CGUI struct maps, in place move construction instead of copying temporaries during CGUI XML loading and GenerateText. 2019-08-09 17:25:55 +00:00
GUItext.h Introduce CGUIColor type inheriting Color type and switch the GUI to exclusively use that. 2019-07-26 18:57:28 +00:00
GUITooltip.cpp Tooltip GUI engine cleanup. 2016-06-15 15:40:05 +00:00
GUITooltip.h GUI code cleanup. Fixes #3354. 2015-08-21 17:08:41 +00:00
GUItypes.h Implement IGUIObject settings as a template class and IGUIObject::AddSetting as a template function. 2019-08-04 02:20:08 +00:00
GUIutil.cpp Move GetDefaultGuiMatrix to a separate file. 2019-08-04 03:52:00 +00:00
GUIutil.h Move GetDefaultGuiMatrix to a separate file. 2019-08-04 03:52:00 +00:00
IGUIButtonBehavior.cpp Add virtual base initialization missing in 2c47fbd66a. 2019-08-01 23:55:10 +00:00
IGUIButtonBehavior.h Add virtual base initialization missing in 2c47fbd66a. 2019-08-01 23:55:10 +00:00
IGUIObject.cpp Revert use of the isRunOnce flag after removal in 64b477625d of compile'n go, refs #4893. 2019-08-08 09:05:42 +00:00
IGUIObject.h Upgrade SpiderMonkey to version 45.0.2, refs #4893. 2019-08-07 22:37:43 +00:00
IGUIScrollBar.cpp Add virtual base initialization missing in 2c47fbd66a. 2019-08-01 23:55:10 +00:00
IGUIScrollBar.h MOVABLE idiom, const CGUI struct maps, in place move construction instead of copying temporaries during CGUI XML loading and GenerateText. 2019-08-09 17:25:55 +00:00
IGUIScrollBarOwner.cpp Pass the GUI page pointer CGUI* to the IGUIObject and derived classes upon construction, instead of on stray cases. 2019-08-01 20:20:24 +00:00
IGUIScrollBarOwner.h Pass the GUI page pointer CGUI* to the IGUIObject and derived classes upon construction, instead of on stray cases. 2019-08-01 20:20:24 +00:00
IGUITextOwner.cpp Introduce a JSInterface_IGUITextOwner to encapsulate JSI_IGUIObject::getTextSize from 9c5062147a / D844. 2019-08-02 16:55:15 +00:00
IGUITextOwner.h Fix JSInterface_IGUITextOwner build on VS2015 following 3d07327837 (which works on gcc, clang and Jenkins), reported by minohaka. 2019-08-03 17:52:56 +00:00
MiniMap.cpp Refactor renderer options. 2019-08-04 08:28:30 +00:00
MiniMap.h Move GetDefaultGuiMatrix to a separate file. 2019-08-04 03:52:00 +00:00