[Libreoffice-commits] core.git: 2 commits - sc/inc sc/source vcl/source
Caolán McNamara (via logerrit)
logerrit at kemper.freedesktop.org
Tue Dec 3 21:16:51 UTC 2019
sc/inc/markdata.hxx | 1 +
sc/inc/markmulti.hxx | 7 ++++---
sc/source/core/data/markmulti.cxx | 15 ---------------
vcl/source/window/builder.cxx | 10 ++++++----
4 files changed, 11 insertions(+), 22 deletions(-)
New commits:
commit 41b8d8eb67a6f19ae1e19e74d055ba4c7869af8d
Author: Caolán McNamara <caolanm at redhat.com>
AuthorDate: Mon Dec 2 17:08:58 2019 +0000
Commit: Caolán McNamara <caolanm at redhat.com>
CommitDate: Tue Dec 3 22:14:56 2019 +0100
cid#1456145 Missing move assignment operator
Change-Id: I55ed7d87def93a66668f5cf4f90fed1e1e5bcbee
Reviewed-on: https://gerrit.libreoffice.org/84256
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
Tested-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/sc/inc/markdata.hxx b/sc/inc/markdata.hxx
index 10403066e5e8..485dcfbf9b12 100644
--- a/sc/inc/markdata.hxx
+++ b/sc/inc/markdata.hxx
@@ -68,6 +68,7 @@ public:
ScMarkData(const ScMarkData& rData) = default;
ScMarkData(ScMarkData&& rData) = default;
ScMarkData& operator=(const ScMarkData& rData) = default;
+ ScMarkData& operator=(ScMarkData&& rData) = default;
~ScMarkData();
void ResetMark();
diff --git a/sc/inc/markmulti.hxx b/sc/inc/markmulti.hxx
index c6ae44701059..ac43e73cbdd5 100644
--- a/sc/inc/markmulti.hxx
+++ b/sc/inc/markmulti.hxx
@@ -40,11 +40,12 @@ friend class ScMultiSelIter;
public:
ScMultiSel(SCROW nMaxRow);
- ScMultiSel( const ScMultiSel& rMultiSel );
+ ScMultiSel(const ScMultiSel& rMultiSel) = default;
+ ScMultiSel(ScMultiSel&& rMultiSel) = default;
~ScMultiSel();
- ScMultiSel& operator=(const ScMultiSel& rMultiSel);
- ScMultiSel& operator=(const ScMultiSel&& rMultiSel) = delete;
+ ScMultiSel& operator=(const ScMultiSel& rMultiSel) = default;
+ ScMultiSel& operator=(ScMultiSel&& rMultiSel) = default;
SCCOL GetMultiSelectionCount() const;
bool HasMarks( SCCOL nCol ) const;
diff --git a/sc/source/core/data/markmulti.cxx b/sc/source/core/data/markmulti.cxx
index fa9262024339..1c8c38cc3584 100644
--- a/sc/source/core/data/markmulti.cxx
+++ b/sc/source/core/data/markmulti.cxx
@@ -32,25 +32,10 @@ ScMultiSel::ScMultiSel(SCROW nMaxRow)
{
}
-ScMultiSel::ScMultiSel( const ScMultiSel& rOther )
- : aRowSel(rOther.aRowSel)
-{
- aMultiSelContainer = rOther.aMultiSelContainer;
- mnMaxRow = rOther.mnMaxRow;
-}
-
ScMultiSel::~ScMultiSel()
{
}
-ScMultiSel& ScMultiSel::operator=(const ScMultiSel& rOther)
-{
- aRowSel = rOther.aRowSel;
- aMultiSelContainer = rOther.aMultiSelContainer;
- mnMaxRow = rOther.mnMaxRow;
- return *this;
-}
-
void ScMultiSel::Clear()
{
aMultiSelContainer.clear();
commit c10182573e2d29cb43fe763ec4e97e04a7d55d9b
Author: Caolán McNamara <caolanm at redhat.com>
AuthorDate: Tue Dec 3 15:13:47 2019 +0000
Commit: Caolán McNamara <caolanm at redhat.com>
CommitDate: Tue Dec 3 22:14:34 2019 +0100
toolbar item visibilty defaults to false in GtkBuilder but true in vcl
Change-Id: I91152db48fee77b95fa542790839a574b87161db
Reviewed-on: https://gerrit.libreoffice.org/84361
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
Tested-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/vcl/source/window/builder.cxx b/vcl/source/window/builder.cxx
index e7c4e17d7c65..6f59df71ded5 100644
--- a/vcl/source/window/builder.cxx
+++ b/vcl/source/window/builder.cxx
@@ -1111,12 +1111,14 @@ namespace
bool extractVisible(VclBuilder::stringmap &rMap)
{
+ bool bRet = false;
VclBuilder::stringmap::iterator aFind = rMap.find(OString("visible"));
if (aFind != rMap.end())
{
- return toBool(aFind->second);
+ bRet = toBool(aFind->second);
+ rMap.erase(aFind);
}
- return false;
+ return bRet;
}
Size extractSizeRequest(VclBuilder::stringmap &rMap)
@@ -3643,6 +3645,8 @@ void VclBuilder::insertMenuObject(Menu *pParent, PopupMenu *pSubMenu, const OStr
if (nOldCount != pParent->GetItemCount())
{
pParent->SetHelpId(nNewId, m_sHelpRoot + rID);
+ if (!extractVisible(rProps))
+ pParent->HideItem(nNewId);
for (auto const& prop : rProps)
{
@@ -3653,8 +3657,6 @@ void VclBuilder::insertMenuObject(Menu *pParent, PopupMenu *pSubMenu, const OStr
pParent->SetTipHelpText(nNewId, rValue);
else if (rKey == "tooltip-text")
pParent->SetTipHelpText(nNewId, rValue);
- else if (rKey == "visible")
- pParent->ShowItem(nNewId, toBool(rValue));
else
SAL_INFO("vcl.layout", "unhandled property: " << rKey);
}
More information about the Libreoffice-commits
mailing list