summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2014-03-30 20:57:35 +0100
committerCaolán McNamara <caolanm@redhat.com>2014-03-30 21:21:30 +0100
commit85ed65f83981ac07215cb01024e8e66d705f1267 (patch)
tree3123162eb8cdbe0bfbf6ac962cb2666f6e4ccc4f /sc
parenta1b352a8da7394dfce580ccd0ae5de4e00275e71 (diff)
coverity#1194921 Overflowed return value
Change-Id: I872835c3a20eda807d571fa27794dbe2bf858e7a
Diffstat (limited to 'sc')
-rw-r--r--sc/inc/scabstdlg.hxx6
-rw-r--r--sc/source/ui/attrdlg/scdlgfact.cxx6
-rw-r--r--sc/source/ui/attrdlg/scdlgfact.hxx6
-rw-r--r--sc/source/ui/inc/shtabdlg.hxx6
-rw-r--r--sc/source/ui/miscdlgs/shtabdlg.cxx10
5 files changed, 15 insertions, 19 deletions
diff --git a/sc/inc/scabstdlg.hxx b/sc/inc/scabstdlg.hxx
index e28fdbf9147e..04e0a4ebf595 100644
--- a/sc/inc/scabstdlg.hxx
+++ b/sc/inc/scabstdlg.hxx
@@ -286,10 +286,10 @@ class AbstractScShowTabDlg : public VclAbstractDialog
{
public:
virtual void Insert( const OUString& rString, bool bSelected ) = 0;
- virtual sal_uInt16 GetSelectEntryCount() const = 0;
+ virtual sal_Int32 GetSelectEntryCount() const = 0;
virtual void SetDescription(const OUString& rTitle, const OUString& rFixedText, const OString& nDlgHelpId, const OString& nLbHelpId ) = 0;
- virtual OUString GetSelectEntry(sal_uInt16 nPos) const = 0;
- virtual sal_uInt16 GetSelectEntryPos(sal_uInt16 nPos) const = 0;
+ virtual OUString GetSelectEntry(sal_Int32 nPos) const = 0;
+ virtual sal_Int32 GetSelectEntryPos(sal_Int32 nPos) const = 0;
};
class AbstractScSortWarningDlg : public VclAbstractDialog
diff --git a/sc/source/ui/attrdlg/scdlgfact.cxx b/sc/source/ui/attrdlg/scdlgfact.cxx
index 5685b928793d..bc4928de8887 100644
--- a/sc/source/ui/attrdlg/scdlgfact.cxx
+++ b/sc/source/ui/attrdlg/scdlgfact.cxx
@@ -555,7 +555,7 @@ void AbstractScShowTabDlg_Impl::Insert( const OUString& rString, bool bSelected
pDlg->Insert( rString, bSelected);
}
-sal_uInt16 AbstractScShowTabDlg_Impl::GetSelectEntryCount() const
+sal_Int32 AbstractScShowTabDlg_Impl::GetSelectEntryCount() const
{
return pDlg->GetSelectEntryCount();
}
@@ -567,12 +567,12 @@ void AbstractScShowTabDlg_Impl::SetDescription(
pDlg->SetDescription( rTitle, rFixedText, sDlgHelpId, sLbHelpId );
}
-sal_uInt16 AbstractScShowTabDlg_Impl::GetSelectEntryPos(sal_uInt16 nPos) const
+sal_Int32 AbstractScShowTabDlg_Impl::GetSelectEntryPos(sal_Int32 nPos) const
{
return pDlg->GetSelectEntryPos( nPos);
}
-OUString AbstractScShowTabDlg_Impl::GetSelectEntry(sal_uInt16 nPos) const
+OUString AbstractScShowTabDlg_Impl::GetSelectEntry(sal_Int32 nPos) const
{
return pDlg->GetSelectEntry(nPos);
}
diff --git a/sc/source/ui/attrdlg/scdlgfact.hxx b/sc/source/ui/attrdlg/scdlgfact.hxx
index 1796a82d9307..9b5625bb6ee0 100644
--- a/sc/source/ui/attrdlg/scdlgfact.hxx
+++ b/sc/source/ui/attrdlg/scdlgfact.hxx
@@ -338,10 +338,10 @@ class AbstractScShowTabDlg_Impl : public AbstractScShowTabDlg
{
DECL_ABSTDLG_BASE(AbstractScShowTabDlg_Impl,ScShowTabDlg)
virtual void Insert( const OUString& rString, bool bSelected ) SAL_OVERRIDE;
- virtual sal_uInt16 GetSelectEntryCount() const SAL_OVERRIDE;
+ virtual sal_Int32 GetSelectEntryCount() const SAL_OVERRIDE;
virtual void SetDescription(const OUString& rTitle, const OUString& rFixedText, const OString& sDlgHelpId, const OString& sLbHelpId ) SAL_OVERRIDE;
- virtual OUString GetSelectEntry(sal_uInt16 nPos) const SAL_OVERRIDE;
- virtual sal_uInt16 GetSelectEntryPos(sal_uInt16 nPos) const SAL_OVERRIDE;
+ virtual OUString GetSelectEntry(sal_Int32 nPos) const SAL_OVERRIDE;
+ virtual sal_Int32 GetSelectEntryPos(sal_Int32 nPos) const SAL_OVERRIDE;
};
class AbstractScSortWarningDlg_Impl : public AbstractScSortWarningDlg
diff --git a/sc/source/ui/inc/shtabdlg.hxx b/sc/source/ui/inc/shtabdlg.hxx
index ce4994b48847..db8fe9a3baae 100644
--- a/sc/source/ui/inc/shtabdlg.hxx
+++ b/sc/source/ui/inc/shtabdlg.hxx
@@ -46,9 +46,9 @@ public:
/** Inserts a string into the ListBox. */
void Insert( const OUString& rString, bool bSelected );
- sal_uInt16 GetSelectEntryCount() const;
- OUString GetSelectEntry(sal_uInt16 nPos) const;
- sal_uInt16 GetSelectEntryPos(sal_uInt16 nPos) const;
+ sal_Int32 GetSelectEntryCount() const;
+ OUString GetSelectEntry(sal_Int32 nPos) const;
+ sal_Int32 GetSelectEntryPos(sal_Int32 nPos) const;
};
diff --git a/sc/source/ui/miscdlgs/shtabdlg.cxx b/sc/source/ui/miscdlgs/shtabdlg.cxx
index 6f511c5139fa..1f04f4f30649 100644
--- a/sc/source/ui/miscdlgs/shtabdlg.cxx
+++ b/sc/source/ui/miscdlgs/shtabdlg.cxx
@@ -64,25 +64,21 @@ void ScShowTabDlg::Insert( const OUString& rString, bool bSelected )
m_pLb->SelectEntryPos( m_pLb->GetEntryCount() - 1 );
}
-
-
-sal_uInt16 ScShowTabDlg::GetSelectEntryCount() const
+sal_Int32 ScShowTabDlg::GetSelectEntryCount() const
{
return m_pLb->GetSelectEntryCount();
}
-OUString ScShowTabDlg::GetSelectEntry(sal_uInt16 nPos) const
+OUString ScShowTabDlg::GetSelectEntry(sal_Int32 nPos) const
{
return m_pLb->GetSelectEntry(nPos);
}
-sal_uInt16 ScShowTabDlg::GetSelectEntryPos(sal_uInt16 nPos) const
+sal_Int32 ScShowTabDlg::GetSelectEntryPos(sal_Int32 nPos) const
{
return m_pLb->GetSelectEntryPos(nPos);
}
-
-
IMPL_LINK_NOARG_INLINE_START(ScShowTabDlg, DblClkHdl)
{
EndDialog( RET_OK );