summaryrefslogtreecommitdiff
path: root/svx/source/form/formcontroller.cxx
diff options
context:
space:
mode:
authorMatthew Nicholls <matthew.nicholls95@hotmail.co.uk>2015-04-19 17:12:43 +0100
committerDavid Tardon <dtardon@redhat.com>2015-04-22 07:25:17 +0000
commita1a25f4c6c99c0c519cc60d842041d56ae8a6f1c (patch)
treeb673a96ed3bf88c107b4a6049b9373af772026fb /svx/source/form/formcontroller.cxx
parent81f9281de0b5b42d5f4e8f1c4ecb3a780c74ff95 (diff)
tdf#88710 Cleanup after removing dbtoolsclient
Removes "virtualdbtools" and its implementation under "simpledbt", which are mostly wrappers around various dbtools functions and classes, previously aiding the now removed dynamic loading logic. Removes IDataAccessTools, IDataAccessTypeConversion and IDataAccessToolsFactory interfaces and their accompanying implementations which are completely unused. Removes IDataAccessCharSet (implemented by ODataAccessCharSet) and moves the implementation into a function which replaces ODataAccessCharsetHelper. Removes ISQLParseNode and ISQLParser and their implementation in OSimpleParseNode and OSimpleSQLParser, which simply wrap around OSQLParseNode and OSQLParser respectively. To avoid including "sqlbison.hxx" unnecessarily, includes to "sqlbison.hxx" are now only used where needed. Change-Id: Id882dfbf43514d84a1eaffc1f916d627830c8cd6 Reviewed-on: https://gerrit.libreoffice.org/15450 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: David Tardon <dtardon@redhat.com>
Diffstat (limited to 'svx/source/form/formcontroller.cxx')
-rw-r--r--svx/source/form/formcontroller.cxx20
1 files changed, 10 insertions, 10 deletions
diff --git a/svx/source/form/formcontroller.cxx b/svx/source/form/formcontroller.cxx
index 90daba66ed28..ab7a51f2339e 100644
--- a/svx/source/form/formcontroller.cxx
+++ b/svx/source/form/formcontroller.cxx
@@ -77,6 +77,7 @@
#include <cppuhelper/typeprovider.hxx>
#include <connectivity/IParseContext.hxx>
#include <connectivity/dbtools.hxx>
+#include <connectivity/sqlparse.hxx>
#include <toolkit/controls/unocontrol.hxx>
#include <toolkit/helper/vclunohelper.hxx>
#include <tools/debug.hxx>
@@ -93,7 +94,6 @@
using namespace ::com::sun::star;
using namespace ::comphelper;
using namespace ::connectivity;
-using namespace ::connectivity::simple;
using namespace ::dbtools;
@@ -821,13 +821,13 @@ void FormController::getFastPropertyValue( Any& rValue, sal_Int32 nHandle ) cons
OUString sFilterValue( condition->second );
OUString sErrorMsg, sCriteria;
- const ::rtl::Reference< ISQLParseNode > xParseNode =
+ const std::shared_ptr< OSQLParseNode > pParseNode =
predicateTree( sErrorMsg, sFilterValue, xFormatter, xField );
- OSL_ENSURE( xParseNode.is(), "FormController::getFastPropertyValue: could not parse the field value predicate!" );
- if ( xParseNode.is() )
+ OSL_ENSURE( pParseNode != nullptr, "FormController::getFastPropertyValue: could not parse the field value predicate!" );
+ if ( pParseNode != nullptr )
{
// don't use a parse context here, we need it unlocalized
- xParseNode->parseNodeToStr( sCriteria, xConnection, NULL );
+ pParseNode->parseNodeToStr( sCriteria, xConnection, NULL );
if ( condition != rRow.begin() )
aRowFilter.appendAscii( " AND " );
aRowFilter.append( sCriteria );
@@ -3109,7 +3109,7 @@ void FormController::setFilter(::std::vector<FmFieldInfo>& rFieldInfos)
const LocaleDataWrapper& rLocaleWrapper( Application::GetSettings().GetUILocaleDataWrapper() );
/* FIXME: casting this to sal_Char is plain wrong and of course only
* works for ASCII separators, but
- * xParseNode->parseNodeToPredicateStr() expects a sal_Char. Fix it
+ * pParseNode->parseNodeToPredicateStr() expects a sal_Char. Fix it
* there. */
sal_Char cDecimalSeparator = (sal_Char)rLocaleWrapper.getNumDecimalSep()[0];
SAL_WARN_IF( (sal_Unicode)cDecimalSeparator != rLocaleWrapper.getNumDecimalSep()[0],
@@ -3180,7 +3180,7 @@ void FormController::setFilter(::std::vector<FmFieldInfo>& rFieldInfos)
{
OUString aCompText = aRow[(*iter).xText];
aCompText += " ";
- OString aVal = m_xParser->getContext().getIntlKeywordAscii(IParseContext::KEY_AND);
+ OString aVal = m_pParser->getContext().getIntlKeywordAscii(IParseContext::KEY_AND);
aCompText += OUString(aVal.getStr(),aVal.getLength(),RTL_TEXTENCODING_ASCII_US);
aCompText += " ";
aCompText += ::comphelper::getString(pRefValues[j].Value);
@@ -3190,11 +3190,11 @@ void FormController::setFilter(::std::vector<FmFieldInfo>& rFieldInfos)
{
OUString sPredicate,sErrorMsg;
pRefValues[j].Value >>= sPredicate;
- ::rtl::Reference< ISQLParseNode > xParseNode = predicateTree(sErrorMsg, sPredicate, xFormatter, xField);
- if ( xParseNode.is() )
+ std::shared_ptr< OSQLParseNode > pParseNode = predicateTree(sErrorMsg, sPredicate, xFormatter, xField);
+ if ( pParseNode != nullptr )
{
OUString sCriteria;
- xParseNode->parseNodeToPredicateStr( sCriteria
+ pParseNode->parseNodeToPredicateStr( sCriteria
,xConnection
,xFormatter
,xField