Kaydet (Commit) 6b8a2089 authored tarafından Noel Grandin's avatar Noel Grandin

convert include/svx/galtheme.hxx from String to OUString

Change-Id: I7a592768f85fd2bd95435a29ca8c368e5f2ca81a
üst 9a915d11
...@@ -50,8 +50,8 @@ struct GalleryObject ...@@ -50,8 +50,8 @@ struct GalleryObject
//UI visualization buffering //UI visualization buffering
BitmapEx maPreviewBitmapEx; BitmapEx maPreviewBitmapEx;
Size maPreparedSize; Size maPreparedSize;
String maTitle; OUString maTitle;
String maPath; OUString maPath;
}; };
typedef ::std::vector< GalleryObject* > GalleryObjectList; typedef ::std::vector< GalleryObject* > GalleryObjectList;
...@@ -96,7 +96,7 @@ class GalleryTheme : public SfxBroadcaster ...@@ -96,7 +96,7 @@ class GalleryTheme : public SfxBroadcaster
private: private:
GalleryObjectList aObjectList; GalleryObjectList aObjectList;
String m_aDestDir; OUString m_aDestDir;
bool m_bDestDirRelative; bool m_bDestDirRelative;
SotStorageRef aSvDrawStorageRef; SotStorageRef aSvDrawStorageRef;
Gallery* pParent; Gallery* pParent;
...@@ -148,8 +148,8 @@ public: ...@@ -148,8 +148,8 @@ public:
const OUString& GetRealName() const; const OUString& GetRealName() const;
// used for building gallery themes during compilation: // used for building gallery themes during compilation:
const String& GetDestDir() const { return m_aDestDir; } const OUString& GetDestDir() const { return m_aDestDir; }
void SetDestDir(const String& rDestDir, bool bRelative = true) void SetDestDir(const OUString& rDestDir, bool bRelative = true)
{ m_aDestDir = rDestDir; m_bDestDirRelative = bRelative; } { m_aDestDir = rDestDir; m_bDestDirRelative = bRelative; }
const INetURLObject& GetThmURL() const; const INetURLObject& GetThmURL() const;
...@@ -226,8 +226,8 @@ public: ...@@ -226,8 +226,8 @@ public:
static SVX_DLLPUBLIC void InsertAllThemes( ListBox& rListBox ); static SVX_DLLPUBLIC void InsertAllThemes( ListBox& rListBox );
// for buffering PreviewBitmaps and strings for object and path // for buffering PreviewBitmaps and strings for object and path
void GetPreviewBitmapExAndStrings(sal_uIntPtr nPos, BitmapEx& rBitmapEx, Size& rSize, String& rTitle, String& rPath) const; void GetPreviewBitmapExAndStrings(sal_uIntPtr nPos, BitmapEx& rBitmapEx, Size& rSize, OUString& rTitle, OUString& rPath) const;
void SetPreviewBitmapExAndStrings(sal_uIntPtr nPos, const BitmapEx& rBitmapEx, const Size& rSize, const String& rTitle, const String& rPath); void SetPreviewBitmapExAndStrings(sal_uIntPtr nPos, const BitmapEx& rBitmapEx, const Size& rSize, const OUString& rTitle, const OUString& rPath);
}; };
SvStream& operator<<( SvStream& rOut, const GalleryTheme& rTheme ); SvStream& operator<<( SvStream& rOut, const GalleryTheme& rTheme );
......
...@@ -329,14 +329,14 @@ void GalleryIconView::UserDraw( const UserDrawEvent& rUDEvt ) ...@@ -329,14 +329,14 @@ void GalleryIconView::UserDraw( const UserDrawEvent& rUDEvt )
const Size aSize(rRect.GetWidth(), rRect.GetHeight()); const Size aSize(rRect.GetWidth(), rRect.GetHeight());
BitmapEx aBitmapEx; BitmapEx aBitmapEx;
Size aPreparedSize; Size aPreparedSize;
String aItemTextTitle; OUString aItemTextTitle;
String aItemTextPath; OUString aItemTextPath;
mpTheme->GetPreviewBitmapExAndStrings(nId - 1, aBitmapEx, aPreparedSize, aItemTextTitle, aItemTextPath); mpTheme->GetPreviewBitmapExAndStrings(nId - 1, aBitmapEx, aPreparedSize, aItemTextTitle, aItemTextPath);
bool bNeedToCreate(aBitmapEx.IsEmpty()); bool bNeedToCreate(aBitmapEx.IsEmpty());
if(!bNeedToCreate && !aItemTextTitle.Len()) if(!bNeedToCreate && aItemTextTitle.isEmpty())
{ {
bNeedToCreate = true; bNeedToCreate = true;
} }
...@@ -629,19 +629,19 @@ void GalleryListView::PaintField( OutputDevice& rDev, const Rectangle& rRect, sa ...@@ -629,19 +629,19 @@ void GalleryListView::PaintField( OutputDevice& rDev, const Rectangle& rRect, sa
const Size aSize(rRect.GetHeight(), rRect.GetHeight()); const Size aSize(rRect.GetHeight(), rRect.GetHeight());
BitmapEx aBitmapEx; BitmapEx aBitmapEx;
Size aPreparedSize; Size aPreparedSize;
String aItemTextTitle; OUString aItemTextTitle;
String aItemTextPath; OUString aItemTextPath;
mpTheme->GetPreviewBitmapExAndStrings(mnCurRow, aBitmapEx, aPreparedSize, aItemTextTitle, aItemTextPath); mpTheme->GetPreviewBitmapExAndStrings(mnCurRow, aBitmapEx, aPreparedSize, aItemTextTitle, aItemTextPath);
bool bNeedToCreate(aBitmapEx.IsEmpty()); bool bNeedToCreate(aBitmapEx.IsEmpty());
if(!bNeedToCreate && GALLERY_BRWBOX_TITLE == nColumnId && !aItemTextTitle.Len()) if(!bNeedToCreate && GALLERY_BRWBOX_TITLE == nColumnId && aItemTextTitle.isEmpty())
{ {
bNeedToCreate = true; bNeedToCreate = true;
} }
if(!bNeedToCreate && GALLERY_BRWBOX_PATH == nColumnId && !aItemTextPath.Len()) if(!bNeedToCreate && GALLERY_BRWBOX_PATH == nColumnId && aItemTextPath.isEmpty())
{ {
bNeedToCreate = true; bNeedToCreate = true;
} }
......
...@@ -444,7 +444,7 @@ SgaObject* GalleryTheme::AcquireObject( size_t nPos ) ...@@ -444,7 +444,7 @@ SgaObject* GalleryTheme::AcquireObject( size_t nPos )
// ------------------------------------------------------------------------ // ------------------------------------------------------------------------
void GalleryTheme::GetPreviewBitmapExAndStrings(sal_uIntPtr nPos, BitmapEx& rBitmapEx, Size& rSize, String& rTitle, String& rPath) const void GalleryTheme::GetPreviewBitmapExAndStrings(sal_uIntPtr nPos, BitmapEx& rBitmapEx, Size& rSize, OUString& rTitle, OUString& rPath) const
{ {
const GalleryObject* pGalleryObject = nPos < aObjectList.size() ? aObjectList[ nPos ] : NULL; const GalleryObject* pGalleryObject = nPos < aObjectList.size() ? aObjectList[ nPos ] : NULL;
...@@ -463,7 +463,7 @@ void GalleryTheme::GetPreviewBitmapExAndStrings(sal_uIntPtr nPos, BitmapEx& rBit ...@@ -463,7 +463,7 @@ void GalleryTheme::GetPreviewBitmapExAndStrings(sal_uIntPtr nPos, BitmapEx& rBit
// ------------------------------------------------------------------------ // ------------------------------------------------------------------------
void GalleryTheme::SetPreviewBitmapExAndStrings(sal_uIntPtr nPos, const BitmapEx& rBitmapEx, const Size& rSize, const String& rTitle, const String& rPath) void GalleryTheme::SetPreviewBitmapExAndStrings(sal_uIntPtr nPos, const BitmapEx& rBitmapEx, const Size& rSize, const OUString& rTitle, const OUString& rPath)
{ {
GalleryObject* pGalleryObject = nPos < aObjectList.size() ? aObjectList[ nPos ] : NULL; GalleryObject* pGalleryObject = nPos < aObjectList.size() ? aObjectList[ nPos ] : NULL;
...@@ -1405,7 +1405,7 @@ SvStream& GalleryTheme::WriteData( SvStream& rOStm ) const ...@@ -1405,7 +1405,7 @@ SvStream& GalleryTheme::WriteData( SvStream& rOStm ) const
} }
} }
if ( m_aDestDir.Len() > 0 ) if ( !m_aDestDir.isEmpty() )
{ {
if ( aPath.SearchAndReplace(m_aDestDir, String()) != STRING_NOTFOUND ) if ( aPath.SearchAndReplace(m_aDestDir, String()) != STRING_NOTFOUND )
bRel = m_bDestDirRelative; bRel = m_bDestDirRelative;
......
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