diff options
author | Jens-Heiner Rechtien <hr@openoffice.org> | 2004-09-08 13:24:55 +0000 |
---|---|---|
committer | Jens-Heiner Rechtien <hr@openoffice.org> | 2004-09-08 13:24:55 +0000 |
commit | 4013665f67dba9b1ebbe99af140918b14571ed17 (patch) | |
tree | e6eecf353bbf1b16929f425e7fb4a3bf44e0fa8c /shell/inc | |
parent | 7b471958a7f98da7c64d4c71770c4fb902728426 (diff) |
INTEGRATION: CWS desktintgr02 (1.2.8); FILE MERGED
2004/07/29 09:14:04 deuce 1.2.8.1: Issue number: 21110
Submitted by: Gorden Lin {gorden.lin@sun.com}
Reviewed by: Tino Rachui {tino.rachui@sun.com}
Diffstat (limited to 'shell/inc')
-rw-r--r-- | shell/inc/internal/propsheets.hxx | 10 | ||||
-rw-r--r-- | shell/inc/internal/types.hxx | 49 | ||||
-rw-r--r-- | shell/inc/internal/utilities.hxx | 29 |
3 files changed, 78 insertions, 10 deletions
diff --git a/shell/inc/internal/propsheets.hxx b/shell/inc/internal/propsheets.hxx index f9c047a2fc56..84b812b3529f 100644 --- a/shell/inc/internal/propsheets.hxx +++ b/shell/inc/internal/propsheets.hxx @@ -2,9 +2,9 @@ * * $RCSfile: propsheets.hxx,v $ * - * $Revision: 1.2 $ + * $Revision: 1.3 $ * - * last change: $Author: hr $ $Date: 2004-04-07 10:53:32 $ + * last change: $Author: hr $ $Date: 2004-09-08 14:23:50 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -62,8 +62,8 @@ #ifndef PROPSHEETS_HXX_INCLUDED #define PROPSHEETS_HXX_INCLUDED -#ifndef METAINFO_HXX_INCLUDED -#include "internal/metainfo.hxx" +#ifndef METAINFOREADER_HXX_INCLUDED +#include "internal/metainforeader.hxx" #endif #include <shlobj.h> @@ -119,7 +119,7 @@ private: private: long m_RefCnt; char m_szFileName[MAX_PATH]; - std::auto_ptr<COpenOfficeMetaInformation> m_pMetaInfo; + std::auto_ptr<CMetaInfoReader> m_pMetaInfo; }; #endif diff --git a/shell/inc/internal/types.hxx b/shell/inc/internal/types.hxx index 0476f3155e3e..61cb4cb13b66 100644 --- a/shell/inc/internal/types.hxx +++ b/shell/inc/internal/types.hxx @@ -2,9 +2,9 @@ * * $RCSfile: types.hxx,v $ * - * $Revision: 1.2 $ + * $Revision: 1.3 $ * - * last change: $Author: hr $ $Date: 2004-04-07 10:54:21 $ + * last change: $Author: hr $ $Date: 2004-09-08 14:24:41 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -70,6 +70,15 @@ typedef std::vector<std::wstring> StringList_t; +//+------------------------------------------------------------------------- +// +// Declare: XmlTagAttributes_t, xml tag attribute struct +// XmlTag_t, xml tag including content and attributes. +// XmlTags_t, tags defined with tag name and xml tag. +// +// Contents: Definitions of xml tag used in parser. +// +//-------------------------------------------------------------------------- typedef std::wstring Name_t; typedef std::wstring Value_t; typedef std::wstring Characters_t; @@ -78,6 +87,40 @@ typedef std::map<Name_t, Value_t> XmlTagAttributes_t; typedef std::pair<Characters_t, XmlTagAttributes_t> XmlTag_t; typedef std::map<Name_t, XmlTag_t> XmlTags_t; -#define EMPTY_XML_TAG std::make_pair(std::wstring(), XmlTagAttributes_t()) +const XmlTag_t EMPTY_XML_TAG = std::make_pair(std::wstring(), XmlTagAttributes_t()); + +//+------------------------------------------------------------------------- +// +// Declare: Language_t, language of the Locale pair +// Country_t, country of the Local pair +// LocaleSet_t, Local pair +// +// Contents: Definitions of Chunk properties. +// +//-------------------------------------------------------------------------- +typedef ::std::wstring Language_t; +typedef ::std::wstring Country_t; +typedef ::std::pair<Language_t, Country_t > LocaleSet_t; + +typedef ::std::wstring Content_t; +typedef ::std::pair<LocaleSet_t, Content_t > Chunk_t; +typedef ::std::vector< Chunk_t > ChunkBuffer_t; + +const LocaleSet_t EMPTY_LOCALE = ::std::make_pair(::std::wstring(), ::std::wstring()); +const Chunk_t EMPTY_CHUNK = ::std::make_pair( EMPTY_LOCALE, ::std::wstring()); + +//+------------------------------------------------------------------------- +// +// Declare: StyleName_t, style name of a style-locale pair. +// StyleLocaleMap, the map of Styple-Locale pair. +// +// Contents: Definitions of Style Names. +// +//-------------------------------------------------------------------------- +typedef ::std::wstring StyleName_t; +typedef ::std::pair <StyleName_t, LocaleSet_t> StyleLocalePair_t; +typedef ::std::map<StyleName_t, LocaleSet_t> StyleLocaleMap_t; + +const StyleLocalePair_t EMPTY_STYLELOCALE_PAIR = ::std::make_pair(::std::wstring(), EMPTY_LOCALE ); #endif diff --git a/shell/inc/internal/utilities.hxx b/shell/inc/internal/utilities.hxx index 1e9e7085cc51..11493e643077 100644 --- a/shell/inc/internal/utilities.hxx +++ b/shell/inc/internal/utilities.hxx @@ -2,9 +2,9 @@ * * $RCSfile: utilities.hxx,v $ * - * $Revision: 1.2 $ + * $Revision: 1.3 $ * - * last change: $Author: hr $ $Date: 2004-04-07 10:54:36 $ + * last change: $Author: hr $ $Date: 2004-09-08 14:24:55 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -62,6 +62,16 @@ #ifndef UTILITIES_HXX_INCLUDED #define UTILITIES_HXX_INCLUDED +#include <malloc.h> +#include <windows.h> +#include <stdio.h> +#include <fcntl.h> +#include <io.h> + +#ifndef TYPES_HXX_INCLUDED +#include "internal/types.hxx" +#endif + #include <string> //--------------------------------- @@ -88,4 +98,19 @@ std::wstring GetResString(int ResId); */ bool is_windows_xp(); +//--------------------------------- +/** helper function to judge if the string is only has spaces. + @returns + <TRUE>if the provided string contains only but at least one space + character else <FALSE/>. +*/ +bool HasOnlySpaces(const std::wstring& String); + +/** convert LocaleSet pair into Windows LCID identifier. + @returns + Windows Locale Identifier corresponding to input LocaleSet. +*/ + +LCID LocaleSetToLCID( const LocaleSet_t & Locale ); + #endif |