xbmc/xbmc — pull request #2882 by garbear (2013-06-14 20:23:30+00:00)
Title: Remove conflicted parameter from IAddon::Clone()

There is some inconsistency in how IAddon::Clone(const AddonPtr&) and its overridden brethren are used. Half the time the parameter is called "self", half the time it's called "parent". If you trace the execution to CAddon's copy constructor, you find the actual usage should be "parent". Which means that every use of Clone() (see the diff - MusicDatabase.cpp, GUIWindowMusicNav.cpp, GUIDialogContentSettings.cpp, and VideoDatabase.cpp) is incorrect, as it interprets the parameter as "self" instead of "parent".

This PR removes the conflicted identity-crisis-prone parameter entirely and makes setting the parent the responsibility of the parent class (CAddon).