summaryrefslogtreecommitdiffstats
path: root/framework
diff options
context:
space:
mode:
authorsb <sb@openoffice.org>2010-12-14 13:24:25 +0100
committersb <sb@openoffice.org>2010-12-14 13:24:25 +0100
commit1b45846965a8516d9e7934e4fee7734c20b45cc8 (patch)
tree588020dbe1b50fd2efd9c655f0b69196cdb49d4f /framework
parentsb135: merged in DEV300_m95 (diff)
downloadcore-1b45846965a8516d9e7934e4fee7734c20b45cc8.tar.gz
core-1b45846965a8516d9e7934e4fee7734c20b45cc8.zip
sb135: #i116121# framework::UIElement::operator= does not check for self-assignment
Diffstat (limited to 'framework')
-rwxr-xr-xframework/source/layoutmanager/uielement.cxx39
1 files changed, 21 insertions, 18 deletions
diff --git a/framework/source/layoutmanager/uielement.cxx b/framework/source/layoutmanager/uielement.cxx
index dda5aa352a08..722ca164f2b5 100755
--- a/framework/source/layoutmanager/uielement.cxx
+++ b/framework/source/layoutmanager/uielement.cxx
@@ -132,24 +132,27 @@ namespace framework
UIElement& UIElement::operator= ( const UIElement& rUIElement )
{
- m_aType = rUIElement.m_aType;
- m_aName = rUIElement.m_aName;
- m_aUIName = rUIElement.m_aUIName;
- m_xUIElement = rUIElement.m_xUIElement;
- m_bFloating = rUIElement.m_bFloating;
- m_bVisible = rUIElement.m_bVisible;
- m_bUserActive = rUIElement.m_bUserActive;
- m_bCreateNewRowCol0 = rUIElement.m_bCreateNewRowCol0;
- m_bDeactiveHide = rUIElement.m_bDeactiveHide;
- m_bMasterHide = rUIElement.m_bMasterHide;
- m_bContextSensitive = rUIElement.m_bContextSensitive;
- m_bContextActive = rUIElement.m_bContextActive;
- m_bNoClose = rUIElement.m_bNoClose;
- m_bSoftClose = rUIElement.m_bSoftClose;
- m_bStateRead = rUIElement.m_bStateRead;
- m_nStyle = rUIElement.m_nStyle;
- m_aDockedData = rUIElement.m_aDockedData;
- m_aFloatingData = rUIElement.m_aFloatingData;
+ if (&rUIElement != this)
+ {
+ m_aType = rUIElement.m_aType;
+ m_aName = rUIElement.m_aName;
+ m_aUIName = rUIElement.m_aUIName;
+ m_xUIElement = rUIElement.m_xUIElement;
+ m_bFloating = rUIElement.m_bFloating;
+ m_bVisible = rUIElement.m_bVisible;
+ m_bUserActive = rUIElement.m_bUserActive;
+ m_bCreateNewRowCol0 = rUIElement.m_bCreateNewRowCol0;
+ m_bDeactiveHide = rUIElement.m_bDeactiveHide;
+ m_bMasterHide = rUIElement.m_bMasterHide;
+ m_bContextSensitive = rUIElement.m_bContextSensitive;
+ m_bContextActive = rUIElement.m_bContextActive;
+ m_bNoClose = rUIElement.m_bNoClose;
+ m_bSoftClose = rUIElement.m_bSoftClose;
+ m_bStateRead = rUIElement.m_bStateRead;
+ m_nStyle = rUIElement.m_nStyle;
+ m_aDockedData = rUIElement.m_aDockedData;
+ m_aFloatingData = rUIElement.m_aFloatingData;
+ }
return *this;
}