summaryrefslogtreecommitdiff
path: root/connectivity
diff options
context:
space:
mode:
authorJulien Nabet <serval2412@yahoo.fr>2014-06-01 00:20:14 +0200
committerLionel Elie Mamane <lionel@mamane.lu>2014-06-03 01:42:41 +0000
commitf03c2bb813d87bc3c89af78f7f01c587db4c59de (patch)
treeef9f04614d9d6b4fb201af1408f5b8a83680f3ba /connectivity
parent3b41dc58dc3689d4506dec0825834fbec0d1ed60 (diff)
Resolves: fdo#79493 Refresh Tables option fails with Firebird
Comparing with hsqldb part, sdbcx::OCollection link wasn't present in Tables constructor Also include Catalog.hxx to be able to call "refreshTables" method (cherry picked from commit d7dd4bbf0a54cc780002052a370f835572035f51) Conflicts: connectivity/source/drivers/firebird/Tables.cxx Change-Id: I1d8f2b0b361f8fd90f3065c07b3224894a3700d6 Reviewed-on: https://gerrit.libreoffice.org/9601 Reviewed-by: Lionel Elie Mamane <lionel@mamane.lu> Tested-by: Lionel Elie Mamane <lionel@mamane.lu>
Diffstat (limited to 'connectivity')
-rw-r--r--connectivity/source/drivers/firebird/Tables.cxx18
-rw-r--r--connectivity/source/drivers/firebird/Tables.hxx7
2 files changed, 5 insertions, 20 deletions
diff --git a/connectivity/source/drivers/firebird/Tables.cxx b/connectivity/source/drivers/firebird/Tables.cxx
index fc55d2ae5d13..6a03d9ed4048 100644
--- a/connectivity/source/drivers/firebird/Tables.cxx
+++ b/connectivity/source/drivers/firebird/Tables.cxx
@@ -9,6 +9,7 @@
#include "Table.hxx"
#include "Tables.hxx"
+#include "Catalog.hxx"
#include <connectivity/dbtools.hxx>
@@ -29,24 +30,11 @@ using namespace ::com::sun::star::sdbc;
using namespace ::com::sun::star::uno;
-Tables::Tables(const uno::Reference< XDatabaseMetaData >& rMetaData,
- OWeakObject& rParent,
- Mutex& rMutex,
- TStringVector& rNames) :
- OCollection(rParent,
- sal_True,
- rMutex,
- rNames),
- m_rMutex(rMutex),
- m_xMetaData(rMetaData)
-{
-}
-
//----- OCollection -----------------------------------------------------------
void Tables::impl_refresh()
throw(RuntimeException)
{
- // TODO: IMPLEMENT ME
+ static_cast<Catalog&>(m_rParent).refreshTables();
}
ObjectType Tables::createObject(const OUString& rName)
@@ -117,4 +105,4 @@ void Tables::dropObject(sal_Int32 nPosition, const OUString sName)
}
}
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ \ No newline at end of file
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/connectivity/source/drivers/firebird/Tables.hxx b/connectivity/source/drivers/firebird/Tables.hxx
index b2e570f9ff92..438f3c18e3d9 100644
--- a/connectivity/source/drivers/firebird/Tables.hxx
+++ b/connectivity/source/drivers/firebird/Tables.hxx
@@ -25,9 +25,6 @@ namespace connectivity
*/
class Tables: public ::connectivity::sdbcx::OCollection
{
- private:
- ::osl::Mutex& m_rMutex;
-
protected:
::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XDatabaseMetaData >
m_xMetaData;
@@ -47,7 +44,7 @@ namespace connectivity
Tables(const ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XDatabaseMetaData >& rMetaData,
::cppu::OWeakObject& rParent,
::osl::Mutex& rMutex,
- ::connectivity::TStringVector& rNames);
+ ::connectivity::TStringVector& rNames) : sdbcx::OCollection(rParent, true, rMutex, rNames), m_xMetaData(rMetaData) {}
// TODO: we should also implement XDataDescriptorFactory, XRefreshable,
// XAppend, etc., but all are optional.
@@ -63,4 +60,4 @@ namespace connectivity
#endif // CONNECTIVITY_FIREBIRD_TABLES_HXX
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ \ No newline at end of file
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */