summaryrefslogtreecommitdiff
path: root/dbaccess
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2018-11-12 08:50:53 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-11-12 12:48:32 +0100
commitbf8c1e277159b82362ed8f3a83d1abd0460a25c8 (patch)
treebe1d711596e92fda83214ca9631b02d4e12ff5e4 /dbaccess
parent8cbe779fcbcfcd722a64f98f5cef3df63d02e037 (diff)
loplugin:singlevalfields in accessibility..extensions
Change-Id: Id3a3241af83f769fc60f67e01c9129d6f4b5c2af Reviewed-on: https://gerrit.libreoffice.org/63274 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'dbaccess')
-rw-r--r--dbaccess/source/ui/dlg/directsql.cxx7
-rw-r--r--dbaccess/source/ui/inc/JoinTableView.hxx2
-rw-r--r--dbaccess/source/ui/inc/directsql.hxx1
-rw-r--r--dbaccess/source/ui/querydesign/JoinTableView.cxx4
4 files changed, 5 insertions, 9 deletions
diff --git a/dbaccess/source/ui/dlg/directsql.cxx b/dbaccess/source/ui/dlg/directsql.cxx
index 16216f60315f..87f4d956ae63 100644
--- a/dbaccess/source/ui/dlg/directsql.cxx
+++ b/dbaccess/source/ui/dlg/directsql.cxx
@@ -38,10 +38,11 @@ namespace dbaui
using namespace ::com::sun::star::sdbc;
using namespace ::com::sun::star::lang;
+ constexpr sal_Int32 g_nHistoryLimit = 20;
+
// DirectSQLDialog
DirectSQLDialog::DirectSQLDialog( vcl::Window* _pParent, const Reference< XConnection >& _rxConn )
:ModalDialog(_pParent, "DirectSQLDialog" , "dbaccess/ui/directsqldialog.ui")
- ,m_nHistoryLimit(20)
,m_nStatusCount(1)
,m_xConnection(_rxConn)
{
@@ -128,11 +129,11 @@ namespace dbaui
{
CHECK_INVARIANTS("DirectSQLDialog::implEnsureHistoryLimit");
- if (getHistorySize() <= m_nHistoryLimit)
+ if (getHistorySize() <= g_nHistoryLimit)
// nothing to do
return;
- sal_Int32 nRemoveEntries = getHistorySize() - m_nHistoryLimit;
+ sal_Int32 nRemoveEntries = getHistorySize() - g_nHistoryLimit;
while (nRemoveEntries--)
{
m_aStatementHistory.pop_front();
diff --git a/dbaccess/source/ui/inc/JoinTableView.hxx b/dbaccess/source/ui/inc/JoinTableView.hxx
index a7b228d18fa4..ecd2dcd69d18 100644
--- a/dbaccess/source/ui/inc/JoinTableView.hxx
+++ b/dbaccess/source/ui/inc/JoinTableView.hxx
@@ -101,8 +101,6 @@ namespace dbaui
VclPtr<OTableConnection> m_pSelectedConn;
- bool m_bTrackingInitiallyMoved;
-
DECL_LINK(OnDragScrollTimer, Timer*, void);
protected:
diff --git a/dbaccess/source/ui/inc/directsql.hxx b/dbaccess/source/ui/inc/directsql.hxx
index 5b2e08edc982..03e31bb7e2ec 100644
--- a/dbaccess/source/ui/inc/directsql.hxx
+++ b/dbaccess/source/ui/inc/directsql.hxx
@@ -58,7 +58,6 @@ namespace dbaui
StringQueue m_aStatementHistory; // previous statements
StringQueue m_aNormalizedHistory; // previous statements, normalized to be used in the list box
- sal_Int32 m_nHistoryLimit;
sal_Int32 m_nStatusCount;
css::uno::Reference< css::sdbc::XConnection >
diff --git a/dbaccess/source/ui/querydesign/JoinTableView.cxx b/dbaccess/source/ui/querydesign/JoinTableView.cxx
index 51fd3d9ea4f5..5b8a74508786 100644
--- a/dbaccess/source/ui/querydesign/JoinTableView.cxx
+++ b/dbaccess/source/ui/querydesign/JoinTableView.cxx
@@ -164,7 +164,6 @@ OJoinTableView::OJoinTableView( vcl::Window* pParent, OJoinDesignView* pView )
,m_pDragWin( nullptr )
,m_pSizingWin( nullptr )
,m_pSelectedConn( nullptr )
- ,m_bTrackingInitiallyMoved(false)
,m_pLastFocusTabWin(nullptr)
,m_pView( pView )
,m_pAccessible(nullptr)
@@ -616,7 +615,6 @@ void OJoinTableView::BeginChildMove( OTableWindow* pTabWin, const Point& rMouseP
Point aMousePos = ScreenToOutputPixel( rMousePos );
m_aDragOffset = aMousePos - pTabWin->GetPosPixel();
m_pDragWin->SetZOrder(nullptr, ZOrderFlags::First);
- m_bTrackingInitiallyMoved = false;
StartTracking();
}
@@ -999,7 +997,7 @@ void OJoinTableView::ScrollWhileDragging()
Size aDragWinSize = m_pDragWin->GetSizePixel();
Point aLowerRight(aDragWinPos.X() + aDragWinSize.Width(), aDragWinPos.Y() + aDragWinSize.Height());
- if (!m_bTrackingInitiallyMoved && (aDragWinPos == m_pDragWin->GetPosPixel()))
+ if (aDragWinPos == m_pDragWin->GetPosPixel())
return;
// avoid illustration errors (when scrolling with active TrackingRect)