Fix typo in code
Change-Id: I3a4bfbd84735ddcc8d2d0754973f73a98e06c303 Reviewed-on: https://gerrit.libreoffice.org/65652 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
This commit is contained in:
committed by
Julien Nabet
parent
8394ca86e8
commit
cc88570fe3
@@ -194,7 +194,7 @@ public:
|
||||
|| name == "g_aWindowList"
|
||||
//vcl/unx/gtk/a11y/atkutil.cxx, asserted empty at exit
|
||||
|| name == "aLogger" // FormulaLogger& FormulaLogger::get() in sc/source/core/tool/formulalogger.cxx
|
||||
|| name == "m_aUncommitedRegistrations" // sw/source/uibase/dbui/dbmgr.cxx
|
||||
|| name == "m_aUncommittedRegistrations" // sw/source/uibase/dbui/dbmgr.cxx
|
||||
|| (loplugin::DeclCheck(pVarDecl).Var("aAllListeners")
|
||||
.Class("ScAddInListener").GlobalNamespace()) // not owning
|
||||
|| (loplugin::DeclCheck(pVarDecl).Var("maThreadSpecific")
|
||||
|
||||
+1
-1
@@ -254,7 +254,7 @@ class SW_DLLPUBLIC SwDBManager
|
||||
OUString m_sEmbeddedName;
|
||||
|
||||
/// Store last registrations to revoke or commit
|
||||
static std::vector<std::pair<SwDocShell*, OUString>> m_aUncommitedRegistrations;
|
||||
static std::vector<std::pair<SwDocShell*, OUString>> m_aUncommittedRegistrations;
|
||||
|
||||
/// Not used connections.
|
||||
std::vector<OUString> m_aNotUsedConnections;
|
||||
|
||||
@@ -166,7 +166,7 @@ void lcl_emitEvent(SfxEventHintId nEventId, sal_Int32 nStrId, SfxObjectShell* pD
|
||||
|
||||
}
|
||||
|
||||
std::vector<std::pair<SwDocShell*, OUString>> SwDBManager::m_aUncommitedRegistrations;
|
||||
std::vector<std::pair<SwDocShell*, OUString>> SwDBManager::m_aUncommittedRegistrations;
|
||||
|
||||
enum class SwDBNextRecord { NEXT, FIRST };
|
||||
static bool lcl_ToNextRecord( SwDSParam* pParam, const SwDBNextRecord action = SwDBNextRecord::NEXT );
|
||||
@@ -2926,7 +2926,7 @@ OUString SwDBManager::LoadAndRegisterDataSource(weld::Window* pParent, SwDocShel
|
||||
}
|
||||
sFind = LoadAndRegisterDataSource_Impl( type, DBConnURIType::FLAT == type ? &aSettings : nullptr, aURL, nullptr, pDocShell );
|
||||
|
||||
m_aUncommitedRegistrations.push_back(std::pair<SwDocShell*, OUString>(pDocShell, sFind));
|
||||
m_aUncommittedRegistrations.push_back(std::pair<SwDocShell*, OUString>(pDocShell, sFind));
|
||||
}
|
||||
return sFind;
|
||||
}
|
||||
@@ -3005,7 +3005,7 @@ void SwDBManager::LoadAndRegisterEmbeddedDataSource(const SwDBData& rData, const
|
||||
|
||||
// temp file - don't remember connection
|
||||
if (rData.sDataSource.isEmpty())
|
||||
m_aUncommitedRegistrations.push_back(std::pair<SwDocShell*, OUString>(nullptr, sDataSource));
|
||||
m_aUncommittedRegistrations.push_back(std::pair<SwDocShell*, OUString>(nullptr, sDataSource));
|
||||
}
|
||||
|
||||
void SwDBManager::ExecuteFormLetter( SwWrtShell& rSh,
|
||||
@@ -3318,7 +3318,7 @@ std::shared_ptr<SwMailMergeConfigItem> SwDBManager::PerformMailMerge(SwView cons
|
||||
|
||||
void SwDBManager::RevokeLastRegistrations()
|
||||
{
|
||||
if (!m_aUncommitedRegistrations.empty())
|
||||
if (!m_aUncommittedRegistrations.empty())
|
||||
{
|
||||
SwView* pView = ( m_pDoc && m_pDoc->GetDocShell() ) ? m_pDoc->GetDocShell()->GetView() : nullptr;
|
||||
if (pView)
|
||||
@@ -3331,12 +3331,12 @@ void SwDBManager::RevokeLastRegistrations()
|
||||
}
|
||||
}
|
||||
|
||||
for (auto it = m_aUncommitedRegistrations.begin(); it != m_aUncommitedRegistrations.end();)
|
||||
for (auto it = m_aUncommittedRegistrations.begin(); it != m_aUncommittedRegistrations.end();)
|
||||
{
|
||||
if ((m_pDoc && it->first == m_pDoc->GetDocShell()) || it->first == nullptr)
|
||||
{
|
||||
RevokeDataSource(it->second);
|
||||
it = m_aUncommitedRegistrations.erase(it);
|
||||
it = m_aUncommittedRegistrations.erase(it);
|
||||
}
|
||||
else
|
||||
++it;
|
||||
@@ -3346,12 +3346,12 @@ void SwDBManager::RevokeLastRegistrations()
|
||||
|
||||
void SwDBManager::CommitLastRegistrations()
|
||||
{
|
||||
for (auto aIt = m_aUncommitedRegistrations.begin(); aIt != m_aUncommitedRegistrations.end();)
|
||||
for (auto aIt = m_aUncommittedRegistrations.begin(); aIt != m_aUncommittedRegistrations.end();)
|
||||
{
|
||||
if (aIt->first == m_pDoc->GetDocShell() || aIt->first == nullptr)
|
||||
{
|
||||
m_aNotUsedConnections.push_back(aIt->second);
|
||||
aIt = m_aUncommitedRegistrations.erase(aIt);
|
||||
aIt = m_aUncommittedRegistrations.erase(aIt);
|
||||
}
|
||||
else
|
||||
aIt++;
|
||||
|
||||
Reference in New Issue
Block a user