Kaydet (Commit) 132e7c45 authored tarafından Thomas Arnhold's avatar Thomas Arnhold

writerfilter: remove using namespace from headers

Change-Id: Ibbb234a15de9ddb71552ef083ade72d2ac724ee0
üst 4f6e3433
...@@ -1045,7 +1045,7 @@ void TableManager<T, PropertiesPointer>::resolveCurrentTable() ...@@ -1045,7 +1045,7 @@ void TableManager<T, PropertiesPointer>::resolveCurrentTable()
mpTableDataHandler->endTable(mTableDataStack.size() - 1); mpTableDataHandler->endTable(mTableDataStack.size() - 1);
} }
catch (uno::Exception const& e) catch (css::uno::Exception const& e)
{ {
(void) e; (void) e;
#if OSL_DEBUG_LEVEL > 0 #if OSL_DEBUG_LEVEL > 0
......
...@@ -19,21 +19,20 @@ ...@@ -19,21 +19,20 @@
#ifndef INCLUDED_WRITERFILTER_INC_RESOURCEMODEL_UTIL_HXX #ifndef INCLUDED_WRITERFILTER_INC_RESOURCEMODEL_UTIL_HXX
#define INCLUDED_WRITERFILTER_INC_RESOURCEMODEL_UTIL_HXX #define INCLUDED_WRITERFILTER_INC_RESOURCEMODEL_UTIL_HXX
#include <com/sun/star/beans/XPropertySet.hpp> #include <com/sun/star/beans/XPropertySet.hpp>
#include <com/sun/star/text/XTextRange.hpp> #include <com/sun/star/text/XTextRange.hpp>
#include <string> #include <string>
namespace writerfilter namespace writerfilter
{ {
using namespace ::std; std::string xmlify(const std::string & str);
using namespace ::com::sun::star;
string xmlify(const string & str);
#if OSL_DEBUG_LEVEL > 1 #if OSL_DEBUG_LEVEL > 1
string toString(uno::Reference< text::XTextRange > textRange); std::string toString(css::uno::Reference< css::text::XTextRange > textRange);
#endif #endif
} }
#endif // INCLUDED_WRITERFILTER_INC_RESOURCEMODEL_UTIL_HXX #endif // INCLUDED_WRITERFILTER_INC_RESOURCEMODEL_UTIL_HXX
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
...@@ -83,7 +83,7 @@ class DomainMapperTableHandler : public TableDataHandler<Handle_t , TablePropert ...@@ -83,7 +83,7 @@ class DomainMapperTableHandler : public TableDataHandler<Handle_t , TablePropert
sal_Int32 m_nCellIndex; sal_Int32 m_nCellIndex;
sal_Int32 m_nRowIndex; sal_Int32 m_nRowIndex;
TableStyleSheetEntry * endTableGetTableStyle(TableInfo & rInfo, uno::Sequence<beans::PropertyValue>& rFrameProperties); TableStyleSheetEntry * endTableGetTableStyle(TableInfo & rInfo, css::uno::Sequence<css::beans::PropertyValue>& rFrameProperties);
CellPropertyValuesSeq_t endTableGetCellProperties(TableInfo & rInfo, std::vector<HorizontallyMergedCell>& rMerges); CellPropertyValuesSeq_t endTableGetCellProperties(TableInfo & rInfo, std::vector<HorizontallyMergedCell>& rMerges);
RowPropertyValuesSeq_t endTableGetRowProperties(); RowPropertyValuesSeq_t endTableGetRowProperties();
......
...@@ -50,7 +50,7 @@ enum StyleType ...@@ -50,7 +50,7 @@ enum StyleType
struct StyleSheetTable_Impl; struct StyleSheetTable_Impl;
class StyleSheetEntry class StyleSheetEntry
{ {
std::vector<beans::PropertyValue> m_aInteropGrabBag; std::vector<css::beans::PropertyValue> m_aInteropGrabBag;
public: public:
OUString sStyleIdentifierI; OUString sStyleIdentifierI;
OUString sStyleIdentifierD; OUString sStyleIdentifierD;
...@@ -64,13 +64,13 @@ public: ...@@ -64,13 +64,13 @@ public:
OUString sStyleName1; OUString sStyleName1;
PropertyMapPtr pProperties; PropertyMapPtr pProperties;
OUString sConvertedStyleName; OUString sConvertedStyleName;
std::vector<beans::PropertyValue> aLatentStyles; ///< Attributes of latentStyles std::vector<css::beans::PropertyValue> aLatentStyles; ///< Attributes of latentStyles
std::vector<beans::PropertyValue> aLsdExceptions; ///< List of lsdException attribute lists std::vector<css::beans::PropertyValue> aLsdExceptions; ///< List of lsdException attribute lists
bool bAutoRedefine; ///< Writer calls this auto-update. bool bAutoRedefine; ///< Writer calls this auto-update.
void AppendInteropGrabBag(beans::PropertyValue aValue); void AppendInteropGrabBag(css::beans::PropertyValue aValue);
beans::PropertyValue GetInteropGrabBag(); ///< Used for table styles, has a name. css::beans::PropertyValue GetInteropGrabBag(); ///< Used for table styles, has a name.
beans::PropertyValues GetInteropGrabBagSeq(); ///< Used for existing styles, just a list of properties. css::beans::PropertyValues GetInteropGrabBagSeq(); ///< Used for existing styles, just a list of properties.
StyleSheetEntry(); StyleSheetEntry();
virtual ~StyleSheetEntry(); virtual ~StyleSheetEntry();
......
...@@ -39,9 +39,9 @@ typedef TableManager<Handle_t , TablePropertyMapPtr > DomainMapperTableManager_B ...@@ -39,9 +39,9 @@ typedef TableManager<Handle_t , TablePropertyMapPtr > DomainMapperTableManager_B
class TablePropertiesHandler class TablePropertiesHandler
{ {
private: private:
vector< PropertyMapPtr > m_rPropertiesStack; std::vector< PropertyMapPtr > m_rPropertiesStack;
PropertyMapPtr m_pCurrentProperties; PropertyMapPtr m_pCurrentProperties;
std::vector<beans::PropertyValue>* m_pCurrentInteropGrabBag; std::vector<css::beans::PropertyValue>* m_pCurrentInteropGrabBag;
DomainMapperTableManager_Base_t *m_pTableManager; DomainMapperTableManager_Base_t *m_pTableManager;
bool m_bOOXML; bool m_bOOXML;
...@@ -61,7 +61,7 @@ public: ...@@ -61,7 +61,7 @@ public:
m_pCurrentProperties = pProperties; m_pCurrentProperties = pProperties;
}; };
void SetInteropGrabBag(std::vector<beans::PropertyValue>& rValue); void SetInteropGrabBag(std::vector<css::beans::PropertyValue>& rValue);
private: private:
......
...@@ -25,6 +25,8 @@ ...@@ -25,6 +25,8 @@
#include "dmapperLoggers.hxx" #include "dmapperLoggers.hxx"
using namespace css;
namespace writerfilter { namespace writerfilter {
namespace dmapper { namespace dmapper {
......
...@@ -57,7 +57,7 @@ private: ...@@ -57,7 +57,7 @@ private:
TblStyleType m_nType; TblStyleType m_nType;
PropertyMapPtr m_pProperties; PropertyMapPtr m_pProperties;
std::vector<beans::PropertyValue> m_aInteropGrabBag; std::vector<css::beans::PropertyValue> m_aInteropGrabBag;
// Properties // Properties
virtual void lcl_attribute(Id Name, Value & val) SAL_OVERRIDE; virtual void lcl_attribute(Id Name, Value & val) SAL_OVERRIDE;
...@@ -71,7 +71,7 @@ public: ...@@ -71,7 +71,7 @@ public:
inline TblStyleType getType() { return m_nType; }; inline TblStyleType getType() { return m_nType; };
OUString getTypeString(); OUString getTypeString();
void appendInteropGrabBag(const OUString& aKey, const OUString& aValue); void appendInteropGrabBag(const OUString& aKey, const OUString& aValue);
beans::PropertyValue getInteropGrabBag(const OUString& aName); css::beans::PropertyValue getInteropGrabBag(const OUString& aName);
private: private:
......
...@@ -24,6 +24,8 @@ ...@@ -24,6 +24,8 @@
#include <resourcemodel/QNameToString.hxx> #include <resourcemodel/QNameToString.hxx>
#include <boost/unordered_map.hpp> #include <boost/unordered_map.hpp>
using namespace css;
namespace writerfilter namespace writerfilter
{ {
TagLogger::TagLogger(const char* name) TagLogger::TagLogger(const char* name)
...@@ -38,12 +40,12 @@ namespace writerfilter ...@@ -38,12 +40,12 @@ namespace writerfilter
} }
#ifdef DEBUG_IMPORT #ifdef DEBUG_IMPORT
void TagLogger::setFileName( const string & filename ) void TagLogger::setFileName( const std::string & filename )
{ {
if ( pWriter ) if ( pWriter )
endDocument(); endDocument();
string fileName; std::string fileName;
char * temp = getenv("TAGLOGGERTMP"); char * temp = getenv("TAGLOGGERTMP");
if (temp != NULL) if (temp != NULL)
...@@ -51,7 +53,7 @@ namespace writerfilter ...@@ -51,7 +53,7 @@ namespace writerfilter
else else
fileName += "/tmp"; fileName += "/tmp";
string sPrefix = filename; std::string sPrefix = filename;
size_t nLastSlash = sPrefix.find_last_of('/'); size_t nLastSlash = sPrefix.find_last_of('/');
size_t nLastBackslash = sPrefix.find_last_of('\\'); size_t nLastBackslash = sPrefix.find_last_of('\\');
size_t nCutPos = nLastSlash; size_t nCutPos = nLastSlash;
...@@ -87,19 +89,19 @@ namespace writerfilter ...@@ -87,19 +89,19 @@ namespace writerfilter
TagLogger::Pointer_t TagLogger::getInstance(const char * name) TagLogger::Pointer_t TagLogger::getInstance(const char * name)
{ {
typedef boost::unordered_map<string, TagLogger::Pointer_t> TagLoggerHashMap_t; typedef boost::unordered_map<std::string, TagLogger::Pointer_t> TagLoggerHashMap_t;
static TagLoggerHashMap_t tagLoggers; static TagLoggerHashMap_t tagLoggers;
TagLoggerHashMap_t::iterator aIt = tagLoggers.end(); TagLoggerHashMap_t::iterator aIt = tagLoggers.end();
string sName = name; std::string sName = name;
if (! tagLoggers.empty()) if (! tagLoggers.empty())
aIt = tagLoggers.find(sName); aIt = tagLoggers.find(sName);
if (aIt == tagLoggers.end()) if (aIt == tagLoggers.end())
{ {
TagLogger::Pointer_t pTagLogger(new TagLogger(name)); TagLogger::Pointer_t pTagLogger(new TagLogger(name));
pair<string, TagLogger::Pointer_t> entry(sName, pTagLogger); std::pair<std::string, TagLogger::Pointer_t> entry(sName, pTagLogger);
aIt = tagLoggers.insert(entry).first; aIt = tagLoggers.insert(entry).first;
} }
...@@ -107,7 +109,7 @@ namespace writerfilter ...@@ -107,7 +109,7 @@ namespace writerfilter
} }
#ifdef DEBUG_DOMAINMAPPER #ifdef DEBUG_DOMAINMAPPER
void TagLogger::element(const string & name) void TagLogger::element(const std::string & name)
{ {
startElement(name); startElement(name);
endElement(); endElement();
...@@ -148,7 +150,7 @@ namespace writerfilter ...@@ -148,7 +150,7 @@ namespace writerfilter
#endif #endif
#if OSL_DEBUG_LEVEL > 1 #if OSL_DEBUG_LEVEL > 1
void TagLogger::startElement(const string & name) void TagLogger::startElement(const std::string & name)
{ {
xmlChar* xmlName = xmlCharStrdup( name.c_str() ); xmlChar* xmlName = xmlCharStrdup( name.c_str() );
xmlTextWriterStartElement( pWriter, xmlName ); xmlTextWriterStartElement( pWriter, xmlName );
...@@ -156,7 +158,7 @@ namespace writerfilter ...@@ -156,7 +158,7 @@ namespace writerfilter
} }
#endif #endif
void TagLogger::attribute(const string & name, const string & value) void TagLogger::attribute(const std::string & name, const std::string & value)
{ {
xmlChar* xmlName = xmlCharStrdup( name.c_str() ); xmlChar* xmlName = xmlCharStrdup( name.c_str() );
xmlChar* xmlValue = xmlCharStrdup( value.c_str() ); xmlChar* xmlValue = xmlCharStrdup( value.c_str() );
...@@ -167,12 +169,12 @@ namespace writerfilter ...@@ -167,12 +169,12 @@ namespace writerfilter
} }
#if OSL_DEBUG_LEVEL > 1 #if OSL_DEBUG_LEVEL > 1
void TagLogger::attribute(const string & name, const OUString & value) void TagLogger::attribute(const std::string & name, const OUString & value)
{ {
attribute( name, OUStringToOString( value, RTL_TEXTENCODING_ASCII_US ).getStr() ); attribute( name, OUStringToOString( value, RTL_TEXTENCODING_ASCII_US ).getStr() );
} }
void TagLogger::attribute(const string & name, sal_uInt32 value) void TagLogger::attribute(const std::string & name, sal_uInt32 value)
{ {
xmlChar* xmlName = xmlCharStrdup( name.c_str() ); xmlChar* xmlName = xmlCharStrdup( name.c_str() );
xmlTextWriterWriteFormatAttribute( pWriter, xmlName, xmlTextWriterWriteFormatAttribute( pWriter, xmlName,
...@@ -180,11 +182,11 @@ namespace writerfilter ...@@ -180,11 +182,11 @@ namespace writerfilter
xmlFree( xmlName ); xmlFree( xmlName );
} }
void TagLogger::attribute(const string & name, const uno::Any aAny) void TagLogger::attribute(const std::string & name, const uno::Any aAny)
{ {
string aTmpStrInt; std::string aTmpStrInt;
string aTmpStrFloat; std::string aTmpStrFloat;
string aTmpStrString; std::string aTmpStrString;
sal_Int32 nInt = 0; sal_Int32 nInt = 0;
float nFloat = 0.0; float nFloat = 0.0;
...@@ -208,7 +210,7 @@ namespace writerfilter ...@@ -208,7 +210,7 @@ namespace writerfilter
xmlFree( xmlName ); xmlFree( xmlName );
} }
void TagLogger::chars(const string & rChars) void TagLogger::chars(const std::string & rChars)
{ {
xmlChar* xmlChars = xmlCharStrdup( rChars.c_str() ); xmlChar* xmlChars = xmlCharStrdup( rChars.c_str() );
xmlTextWriterWriteString( pWriter, xmlChars ); xmlTextWriterWriteString( pWriter, xmlChars );
...@@ -277,7 +279,7 @@ namespace writerfilter ...@@ -277,7 +279,7 @@ namespace writerfilter
{ {
m_pLogger->startElement( "sprm" ); m_pLogger->startElement( "sprm" );
string sName; std::string sName;
if (mpIdToString != IdToString::Pointer_t()) if (mpIdToString != IdToString::Pointer_t())
sName = mpIdToString->toString(rSprm.getId()); sName = mpIdToString->toString(rSprm.getId());
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment