summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArkadiy Illarionov <qarkai@gmail.com>2018-06-01 22:59:47 +0300
committerTor Lillqvist <tml@collabora.com>2018-06-03 09:38:42 +0200
commit62667aac83bd743fa98a5eaa946cc8088335f66c (patch)
treeaf4442622bdf7d417a55e69c72d2fe44bfd18f17
parent10da3d817afd3f5d5c4f84cb814d56efc0678d43 (diff)
tdf#96099 Remove some trivial std::vector typedefs
Change-Id: I21171bd90b5e19fe8e5b8f2d125b6dfcb9a8b766 Reviewed-on: https://gerrit.libreoffice.org/55198 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tor Lillqvist <tml@collabora.com>
-rw-r--r--dbaccess/source/core/api/KeySet.cxx2
-rw-r--r--dbaccess/source/core/api/KeySet.hxx3
-rw-r--r--dtrans/source/win32/dtobj/FmtFilter.cxx9
-rw-r--r--extensions/source/bibliography/general.cxx6
-rw-r--r--filter/source/flash/swfwriter.hxx3
-rw-r--r--forms/source/component/EventThread.cxx2
-rw-r--r--forms/source/component/EventThread.hxx3
-rw-r--r--forms/source/solar/control/navtoolbar.cxx3
8 files changed, 12 insertions, 19 deletions
diff --git a/dbaccess/source/core/api/KeySet.cxx b/dbaccess/source/core/api/KeySet.cxx
index 66bd473612e2..78c10485df14 100644
--- a/dbaccess/source/core/api/KeySet.cxx
+++ b/dbaccess/source/core/api/KeySet.cxx
@@ -333,7 +333,7 @@ void OKeySet::ensureStatement( )
{
// do we already have a statement for the current combination of NULLness
// of key & foreign columns?
- FilterColumnsNULL_t FilterColumnsNULL;
+ std::vector<bool> FilterColumnsNULL;
FilterColumnsNULL.reserve(m_aKeyIter->second.first->get().size());
for (auto const& elem : m_aKeyIter->second.first->get())
FilterColumnsNULL.push_back(elem.isNull());
diff --git a/dbaccess/source/core/api/KeySet.hxx b/dbaccess/source/core/api/KeySet.hxx
index 59c6dfccd5cb..0bd8a681beaa 100644
--- a/dbaccess/source/core/api/KeySet.hxx
+++ b/dbaccess/source/core/api/KeySet.hxx
@@ -93,8 +93,7 @@ namespace dbaccess
// of NULLness of key & foreign columns;
// each subclause is either "colName = ?" or "colName IS NULL"
// (we avoid the standard "colName IS NOT DISTINCT FROM ?" because it is not widely supported)
- typedef std::vector< bool > FilterColumnsNULL_t;
- typedef std::map< FilterColumnsNULL_t,
+ typedef std::map< std::vector<bool>,
css::uno::Reference< css::sdbc::XPreparedStatement > >
vStatements_t;
vStatements_t m_vStatements;
diff --git a/dtrans/source/win32/dtobj/FmtFilter.cxx b/dtrans/source/win32/dtobj/FmtFilter.cxx
index f8d04091a368..ee3d4f12cb2d 100644
--- a/dtrans/source/win32/dtobj/FmtFilter.cxx
+++ b/dtrans/source/win32/dtobj/FmtFilter.cxx
@@ -336,12 +336,11 @@ std::wstring getShellLinkTarget(const std::wstring& aLnkFile)
return target;
}
-typedef std::vector<std::wstring> FileList_t;
typedef Sequence<sal_Int8> ByteSequence_t;
/* Calculate the size required for turning a string list into
a double '\0' terminated string buffer */
-size_t CalcSizeForStringListBuffer(const FileList_t& fileList)
+size_t CalcSizeForStringListBuffer(const std::vector<std::wstring>& fileList)
{
if ( fileList.empty() )
return 0;
@@ -351,10 +350,10 @@ size_t CalcSizeForStringListBuffer(const FileList_t& fileList)
{
size += elem.length() + 1; // length including terminating '\0'
}
- return (size * sizeof(FileList_t::value_type::value_type));
+ return (size * sizeof(std::vector<std::wstring>::value_type::value_type));
}
-ByteSequence_t FileListToByteSequence(const FileList_t& fileList)
+ByteSequence_t FileListToByteSequence(const std::vector<std::wstring>& fileList)
{
ByteSequence_t bseq;
size_t size = CalcSizeForStringListBuffer(fileList);
@@ -377,7 +376,7 @@ ByteSequence_t FileListToByteSequence(const FileList_t& fileList)
ByteSequence_t CF_HDROPToFileList(HGLOBAL hGlobal)
{
UINT nFiles = DragQueryFileW(static_cast<HDROP>(hGlobal), 0xFFFFFFFF, nullptr, 0);
- FileList_t files;
+ std::vector<std::wstring> files;
for (UINT i = 0; i < nFiles; i++)
{
diff --git a/extensions/source/bibliography/general.cxx b/extensions/source/bibliography/general.cxx
index bc86e4fa9d35..8bb6a9262f3e 100644
--- a/extensions/source/bibliography/general.cxx
+++ b/extensions/source/bibliography/general.cxx
@@ -635,12 +635,10 @@ bool BibGeneralPage::HandleShortCutKey( const KeyEvent& rKeyEvent )
sal_Int16 i;
- typedef std::vector< sal_Int16 > sal_Int16_vector;
-
- sal_Int16_vector::size_type nFocused = 0xFFFF; // index of focused in vector, no one focused initial
+ std::vector<sal_Int16>::size_type nFocused = 0xFFFF; // index of focused in vector, no one focused initial
DBG_ASSERT( nFocused > 0, "*BibGeneralPage::HandleShortCutKey(): size_type works not as expected!" );
- sal_Int16_vector aMatchList;
+ std::vector<sal_Int16> aMatchList;
for( i = 0 ; i < FIELD_COUNT ; ++i )
{
diff --git a/filter/source/flash/swfwriter.hxx b/filter/source/flash/swfwriter.hxx
index e5453c6b5882..da781c2cf4da 100644
--- a/filter/source/flash/swfwriter.hxx
+++ b/filter/source/flash/swfwriter.hxx
@@ -381,8 +381,7 @@ private:
/** holds the information of the objects defined in the movie stream
while executing defineShape
*/
- typedef std::vector<sal_uInt16> CharacterIdVector;
- CharacterIdVector maShapeIds;
+ std::vector<sal_uInt16> maShapeIds;
std::unique_ptr<Tag> mpTag;
std::unique_ptr<Sprite> mpSprite;
diff --git a/forms/source/component/EventThread.cxx b/forms/source/component/EventThread.cxx
index dd3e16c951bd..821f2b63e77e 100644
--- a/forms/source/component/EventThread.cxx
+++ b/forms/source/component/EventThread.cxx
@@ -161,7 +161,7 @@ void OComponentEventThread::run()
Reference<XAdapter> xControlAdapter = *firstControl;
m_aControls.erase( firstControl );
- ThreadBools::iterator firstFlag( m_aFlags.begin() );
+ auto firstFlag( m_aFlags.begin() );
bool bFlag = *firstFlag;
m_aFlags.erase( firstFlag );
diff --git a/forms/source/component/EventThread.hxx b/forms/source/component/EventThread.hxx
index 607db4956b26..efb9e20fc4dc 100644
--- a/forms/source/component/EventThread.hxx
+++ b/forms/source/component/EventThread.hxx
@@ -50,13 +50,12 @@ class OComponentEventThread
{
typedef std::vector<css::lang::EventObject*> ThreadEvents;
typedef std::vector< css::uno::Reference< css::uno::XAdapter> > ThreadObjects;
- typedef std::vector<bool> ThreadBools;
::osl::Mutex m_aMutex;
::osl::Condition m_aCond; // Queue filled?
ThreadEvents m_aEvents; // EventQueue
ThreadObjects m_aControls; // Control for Submit
- ThreadBools m_aFlags; // Flags for Submit/Reset
+ std::vector<bool> m_aFlags; // Flags for Submit/Reset
rtl::Reference<::cppu::OComponentHelper> m_xComp; // Implementation of the Control
diff --git a/forms/source/solar/control/navtoolbar.cxx b/forms/source/solar/control/navtoolbar.cxx
index 1eea34edd9b4..af5428305c70 100644
--- a/forms/source/solar/control/navtoolbar.cxx
+++ b/forms/source/solar/control/navtoolbar.cxx
@@ -345,8 +345,7 @@ namespace frm
const ToolBox::ImplToolItems::size_type nItemCount = m_pToolbar->GetItemCount();
// collect the FormFeatures in the toolbar
- typedef ::std::vector< sal_Int16 > FormFeatures;
- FormFeatures aFormFeatures;
+ std::vector<sal_Int16> aFormFeatures;
aFormFeatures.reserve( nItemCount );
for ( ToolBox::ImplToolItems::size_type i=0; i<nItemCount; ++i )