summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2020-05-12 17:16:22 +0100
committerCaolán McNamara <caolanm@redhat.com>2020-05-13 09:57:56 +0200
commit7c831c94ceaf7f48383315216573b1f5691c10bc (patch)
tree4da2b8643698fbdc5826914a2fc6697d1e67c522
parent1ffe59ef31186e36ad0aa7bbcdd32e407ee8d26c (diff)
the returned awt::XControlModel is just used as a flag
Change-Id: I4167be9e6b14b6a3454652fed86e785c1ea0d4b9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/94074 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r--extensions/source/bibliography/general.cxx8
-rw-r--r--extensions/source/bibliography/general.hxx2
2 files changed, 5 insertions, 5 deletions
diff --git a/extensions/source/bibliography/general.cxx b/extensions/source/bibliography/general.cxx
index d1141afe76a6..c1963ae322ea 100644
--- a/extensions/source/bibliography/general.cxx
+++ b/extensions/source/bibliography/general.cxx
@@ -423,8 +423,8 @@ void BibGeneralPage::AddControlWithError( const OUString& rColumnName, FixedText
// adds also the XControl and creates a map entry in nFT2CtrlMap[] for mapping between control and FT
sal_Int16 nIndex = -1;
- uno::Reference< awt::XControlModel > xTmp = AddXControl(rColumnName, rLabel, sHelpId, nIndex, rChildren);
- if( xTmp.is() )
+ bool bSuccess = AddXControl(rColumnName, rLabel, sHelpId, nIndex, rChildren);
+ if (bSuccess)
{
DBG_ASSERT( nIndexInFTArray < FIELD_COUNT, "*BibGeneralPage::AddControlWithError(): wrong array index!" );
DBG_ASSERT( nFT2CtrlMap[ nIndexInFTArray ] < 0, "+BibGeneralPage::AddControlWithError(): index already in use!" );
@@ -440,7 +440,7 @@ void BibGeneralPage::AddControlWithError( const OUString& rColumnName, FixedText
}
}
-uno::Reference< awt::XControlModel > BibGeneralPage::AddXControl(
+bool BibGeneralPage::AddXControl(
const OUString& rName,
FixedText& rLabel, const OString& sHelpId, sal_Int16& rIndex,
std::vector<vcl::Window*>& rChildren)
@@ -520,7 +520,7 @@ uno::Reference< awt::XControlModel > BibGeneralPage::AddXControl(
{
OSL_FAIL("BibGeneralPage::AddXControl: something went wrong!");
}
- return xCtrModel;
+ return xCtrModel.is();
}
void BibGeneralPage::InitFixedTexts()
diff --git a/extensions/source/bibliography/general.hxx b/extensions/source/bibliography/general.hxx
index f48573fa5eb4..8c95e6dad42f 100644
--- a/extensions/source/bibliography/general.hxx
+++ b/extensions/source/bibliography/general.hxx
@@ -121,7 +121,7 @@ class BibGeneralPage : public TabPage, public BibShortCutHandler
BibDataManager* pDatMan;
- css::uno::Reference< css::awt::XControlModel >
+ bool
AddXControl( const OUString& rName, FixedText& rLabel, const OString& sHelpId,
sal_Int16& rIndex, std::vector<vcl::Window*>& rChildren );