[Libreoffice-commits] .: Branch 'libreoffice-4-0' - 6 commits - sfx2/inc sfx2/Library_sfx.mk sfx2/Package_inc.mk sfx2/source svtools/inc svtools/source svtools/uiconfig
Libreoffice Gerrit user
logerrit at kemper.freedesktop.org
Tue Dec 18 00:35:53 PST 2012
sfx2/Library_sfx.mk | 3
sfx2/Package_inc.mk | 4
sfx2/inc/sfx2/templateabstractview.hxx | 4
sfx2/inc/sfx2/templatecontaineritem.hxx | 38 ++++
sfx2/inc/sfx2/templatelocalview.hxx | 6
sfx2/inc/sfx2/templatelocalviewitem.hxx | 40 ----
sfx2/inc/sfx2/templateremoteview.hxx | 19 --
sfx2/inc/sfx2/templateremoteviewitem.hxx | 42 ----
sfx2/inc/sfx2/templaterepository.hxx | 46 +++++
sfx2/inc/templatedlg.hxx | 15 +
sfx2/source/control/templatecontaineritem.cxx | 148 +++++++++++++++++
sfx2/source/control/templatelocalview.cxx | 58 +++---
sfx2/source/control/templatelocalviewitem.cxx | 148 -----------------
sfx2/source/control/templateremoteview.cxx | 116 -------------
sfx2/source/control/templateremoteviewitem.cxx | 21 --
sfx2/source/doc/templatedlg.cxx | 125 +++++++++++++-
svtools/inc/svtools/ServerDetailsControls.hxx | 1
svtools/source/dialogs/ServerDetailsControls.cxx | 7
svtools/uiconfig/ui/placeedit.ui | 194 +++++++++++++----------
19 files changed, 523 insertions(+), 512 deletions(-)
New commits:
commit 5bc25a24a7ea11d0954ba2b76efb162befb5c5cb
Author: Cédric Bosdonnat <cedric.bosdonnat at free.fr>
Date: Mon Dec 17 22:28:22 2012 +0100
sfx2 renamed templatelocalviewitem.hxx to templatecontaineritem.hxx
Change-Id: I7133c5b1ba41b01e695d006af8e5e3bb29997ec6
diff --git a/sfx2/Library_sfx.mk b/sfx2/Library_sfx.mk
index 6496e38..f252e5b 100644
--- a/sfx2/Library_sfx.mk
+++ b/sfx2/Library_sfx.mk
@@ -141,7 +141,7 @@ $(eval $(call gb_Library_add_exception_objects,sfx,\
sfx2/source/control/templateview \
sfx2/source/control/templateviewitem \
sfx2/source/control/templatelocalview \
- sfx2/source/control/templatelocalviewitem \
+ sfx2/source/control/templatecontaineritem \
sfx2/source/control/templateremoteview \
sfx2/source/control/templatesearchview \
sfx2/source/control/thumbnailviewitem \
diff --git a/sfx2/Package_inc.mk b/sfx2/Package_inc.mk
index 39aafac..05727d4 100644
--- a/sfx2/Package_inc.mk
+++ b/sfx2/Package_inc.mk
@@ -123,7 +123,7 @@ $(eval $(call gb_Package_add_file,sfx2_inc,inc/sfx2/templateabstractview.hxx,sfx
$(eval $(call gb_Package_add_file,sfx2_inc,inc/sfx2/templateinfodlg.hxx,sfx2/templateinfodlg.hxx))
$(eval $(call gb_Package_add_file,sfx2_inc,inc/sfx2/templateview.hxx,sfx2/templateview.hxx))
$(eval $(call gb_Package_add_file,sfx2_inc,inc/sfx2/templatelocalview.hxx,sfx2/templatelocalview.hxx))
-$(eval $(call gb_Package_add_file,sfx2_inc,inc/sfx2/templatelocalviewitem.hxx,sfx2/templatelocalviewitem.hxx))
+$(eval $(call gb_Package_add_file,sfx2_inc,inc/sfx2/templatecontaineritem.hxx,sfx2/templatecontaineritem.hxx))
$(eval $(call gb_Package_add_file,sfx2_inc,inc/sfx2/templateremoteview.hxx,sfx2/templateremoteview.hxx))
$(eval $(call gb_Package_add_file,sfx2_inc,inc/sfx2/templaterepository.hxx,sfx2/templaterepository.hxx))
$(eval $(call gb_Package_add_file,sfx2_inc,inc/sfx2/thumbnailview.hxx,sfx2/thumbnailview.hxx))
diff --git a/sfx2/inc/sfx2/templatecontaineritem.hxx b/sfx2/inc/sfx2/templatecontaineritem.hxx
new file mode 100644
index 0000000..2c2d18b
--- /dev/null
+++ b/sfx2/inc/sfx2/templatecontaineritem.hxx
@@ -0,0 +1,38 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * Copyright 2012 LibreOffice contributors.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ */
+
+#ifndef TEMPLATEFOLDERVIEWITEM_HXX
+#define TEMPLATEFOLDERVIEWITEM_HXX
+
+#include <sfx2/templateproperties.hxx>
+#include <sfx2/thumbnailviewitem.hxx>
+
+class TemplateContainerItem : public ThumbnailViewItem
+{
+public:
+
+ BitmapEx maPreview2;
+ std::vector<TemplateItemProperties> maTemplates;
+
+ TemplateContainerItem (ThumbnailView &rView);
+
+ virtual ~TemplateContainerItem ();
+
+ const Point& getPrev2Pos () const { return maPrev2Pos; }
+
+ virtual void Paint (drawinglayer::processor2d::BaseProcessor2D *pProcessor,
+ const ThumbnailItemAttributes *pAttrs);
+private:
+
+ Point maPrev2Pos;
+};
+
+#endif // TEMPLATEFOLDERVIEWITEM_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sfx2/inc/sfx2/templatelocalviewitem.hxx b/sfx2/inc/sfx2/templatelocalviewitem.hxx
deleted file mode 100644
index 2c2d18b..0000000
--- a/sfx2/inc/sfx2/templatelocalviewitem.hxx
+++ /dev/null
@@ -1,38 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * Copyright 2012 LibreOffice contributors.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- */
-
-#ifndef TEMPLATEFOLDERVIEWITEM_HXX
-#define TEMPLATEFOLDERVIEWITEM_HXX
-
-#include <sfx2/templateproperties.hxx>
-#include <sfx2/thumbnailviewitem.hxx>
-
-class TemplateContainerItem : public ThumbnailViewItem
-{
-public:
-
- BitmapEx maPreview2;
- std::vector<TemplateItemProperties> maTemplates;
-
- TemplateContainerItem (ThumbnailView &rView);
-
- virtual ~TemplateContainerItem ();
-
- const Point& getPrev2Pos () const { return maPrev2Pos; }
-
- virtual void Paint (drawinglayer::processor2d::BaseProcessor2D *pProcessor,
- const ThumbnailItemAttributes *pAttrs);
-private:
-
- Point maPrev2Pos;
-};
-
-#endif // TEMPLATEFOLDERVIEWITEM_HXX
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sfx2/source/control/templatecontaineritem.cxx b/sfx2/source/control/templatecontaineritem.cxx
new file mode 100644
index 0000000..d63ce8a
--- /dev/null
+++ b/sfx2/source/control/templatecontaineritem.cxx
@@ -0,0 +1,148 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * Copyright 2012 LibreOffice contributors.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ */
+
+#include <sfx2/templatecontaineritem.hxx>
+
+#include <basegfx/matrix/b2dhommatrixtools.hxx>
+#include <basegfx/polygon/b2dpolygon.hxx>
+#include <drawinglayer/attribute/fillbitmapattribute.hxx>
+#include <drawinglayer/primitive2d/fillbitmapprimitive2d.hxx>
+#include <drawinglayer/primitive2d/polygonprimitive2d.hxx>
+#include <drawinglayer/primitive2d/polypolygonprimitive2d.hxx>
+#include <drawinglayer/primitive2d/textlayoutdevice.hxx>
+#include <drawinglayer/primitive2d/textprimitive2d.hxx>
+#include <drawinglayer/processor2d/baseprocessor2d.hxx>
+#include <sfx2/templateviewitem.hxx>
+#include <vcl/button.hxx>
+
+using namespace basegfx;
+using namespace basegfx::tools;
+using namespace drawinglayer::attribute;
+using namespace drawinglayer::primitive2d;
+
+TemplateContainerItem::TemplateContainerItem (ThumbnailView &rView)
+ : ThumbnailViewItem(rView)
+{
+}
+
+TemplateContainerItem::~TemplateContainerItem ()
+{
+}
+
+void TemplateContainerItem::Paint (drawinglayer::processor2d::BaseProcessor2D *pProcessor,
+ const ThumbnailItemAttributes *pAttrs)
+{
+ int nCount = 0;
+ int nSeqSize = 2;
+
+ if (!maPreview1.IsEmpty())
+ nSeqSize += 3;
+
+ if (!maPreview2.IsEmpty())
+ nSeqSize += 3;
+
+ BColor aFillColor = pAttrs->aFillColor;
+ Primitive2DSequence aSeq(nSeqSize);
+
+ // Draw background
+ if ( mbSelected || mbHover )
+ aFillColor = pAttrs->aHighlightColor;
+
+ aSeq[nCount++] = Primitive2DReference( new PolyPolygonColorPrimitive2D(
+ B2DPolyPolygon(Polygon(maDrawArea,5,5).getB2DPolygon()),
+ aFillColor));
+
+ // Draw thumbnail
+ Point aPos = maPrev1Pos;
+ Size aImageSize = maPreview1.GetSizePixel();
+
+ float fScaleX = 1.0f;
+ float fScaleY = 1.0f;
+
+ if (!maPreview2.IsEmpty())
+ {
+ fScaleX = 0.8f;
+ fScaleY = 0.8f;
+
+ float fWidth = aImageSize.Width()*fScaleX;
+ float fHeight = aImageSize.Height()*fScaleY;
+ float fPosX = aPos.getX()+35*fScaleX;
+ float fPosY = aPos.getY()+20*fScaleY;
+
+ B2DPolygon aBounds;
+ aBounds.append(B2DPoint(fPosX,fPosY));
+ aBounds.append(B2DPoint(fPosX+fWidth,fPosY));
+ aBounds.append(B2DPoint(fPosX+fWidth,fPosY+fHeight));
+ aBounds.append(B2DPoint(fPosX,fPosY+fHeight));
+ aBounds.setClosed(true);
+
+ aSeq[nCount++] = Primitive2DReference( new PolyPolygonColorPrimitive2D(
+ B2DPolyPolygon(aBounds), Color(COL_WHITE).getBColor()));
+ aSeq[nCount++] = Primitive2DReference( new FillBitmapPrimitive2D(
+ createScaleTranslateB2DHomMatrix(fScaleX,fScaleY,aPos.X(),aPos.Y()),
+ FillBitmapAttribute(maPreview2,
+ B2DPoint(35,20),
+ B2DVector(aImageSize.Width(),aImageSize.Height()),
+ false)
+ ));
+
+ // draw thumbnail borders
+ aSeq[nCount++] = Primitive2DReference(createBorderLine(aBounds));
+ }
+
+ if (!maPreview1.IsEmpty())
+ {
+ // draw thumbnail borders
+ float fWidth = aImageSize.Width()*fScaleX;
+ float fHeight = aImageSize.Height()*fScaleY;
+ float fPosX = aPos.getX();
+ float fPosY = aPos.getY();
+
+ B2DPolygon aBounds;
+ aBounds.append(B2DPoint(fPosX,fPosY));
+ aBounds.append(B2DPoint(fPosX+fWidth,fPosY));
+ aBounds.append(B2DPoint(fPosX+fWidth,fPosY+fHeight));
+ aBounds.append(B2DPoint(fPosX,fPosY+fHeight));
+ aBounds.setClosed(true);
+
+ aSeq[nCount++] = Primitive2DReference( new PolyPolygonColorPrimitive2D(
+ B2DPolyPolygon(aBounds), Color(COL_WHITE).getBColor()));
+ aSeq[nCount++] = Primitive2DReference( new FillBitmapPrimitive2D(
+ createScaleTranslateB2DHomMatrix(fScaleX,fScaleY,aPos.X(),aPos.Y()),
+ FillBitmapAttribute(maPreview1,
+ B2DPoint(0,0),
+ B2DVector(aImageSize.Width(),aImageSize.Height()),
+ false)
+ ));
+
+ aSeq[nCount++] = Primitive2DReference(createBorderLine(aBounds));
+ }
+
+ // Draw centered text below thumbnail
+ aPos = maTextPos;
+
+ // Create the text primitive
+ basegfx::B2DHomMatrix aTextMatrix( createScaleTranslateB2DHomMatrix(
+ pAttrs->aFontSize.getX(), pAttrs->aFontSize.getY(),
+ double( aPos.X() ), double( aPos.Y() ) ) );
+
+ aSeq[nCount++] = Primitive2DReference(
+ new TextSimplePortionPrimitive2D(aTextMatrix,
+ maTitle,0,maTitle.getLength(),
+ std::vector< double >( ),
+ pAttrs->aFontAttr,
+ com::sun::star::lang::Locale(),
+ Color(COL_BLACK).getBColor() ) );
+
+ pProcessor->process(aSeq);
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
+
+
diff --git a/sfx2/source/control/templatelocalview.cxx b/sfx2/source/control/templatelocalview.cxx
index 5da77d6..241020a 100644
--- a/sfx2/source/control/templatelocalview.cxx
+++ b/sfx2/source/control/templatelocalview.cxx
@@ -11,7 +11,7 @@
#include <comphelper/processfactory.hxx>
#include <sfx2/doctempl.hxx>
-#include <sfx2/templatelocalviewitem.hxx>
+#include <sfx2/templatecontaineritem.hxx>
#include <sfx2/templateview.hxx>
#include <sfx2/templateviewitem.hxx>
#include <svl/inettype.hxx>
diff --git a/sfx2/source/control/templatelocalviewitem.cxx b/sfx2/source/control/templatelocalviewitem.cxx
deleted file mode 100644
index f8d24c5..0000000
--- a/sfx2/source/control/templatelocalviewitem.cxx
+++ /dev/null
@@ -1,148 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * Copyright 2012 LibreOffice contributors.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- */
-
-#include <sfx2/templatelocalviewitem.hxx>
-
-#include <basegfx/matrix/b2dhommatrixtools.hxx>
-#include <basegfx/polygon/b2dpolygon.hxx>
-#include <drawinglayer/attribute/fillbitmapattribute.hxx>
-#include <drawinglayer/primitive2d/fillbitmapprimitive2d.hxx>
-#include <drawinglayer/primitive2d/polygonprimitive2d.hxx>
-#include <drawinglayer/primitive2d/polypolygonprimitive2d.hxx>
-#include <drawinglayer/primitive2d/textlayoutdevice.hxx>
-#include <drawinglayer/primitive2d/textprimitive2d.hxx>
-#include <drawinglayer/processor2d/baseprocessor2d.hxx>
-#include <sfx2/templateviewitem.hxx>
-#include <vcl/button.hxx>
-
-using namespace basegfx;
-using namespace basegfx::tools;
-using namespace drawinglayer::attribute;
-using namespace drawinglayer::primitive2d;
-
-TemplateContainerItem::TemplateContainerItem (ThumbnailView &rView)
- : ThumbnailViewItem(rView)
-{
-}
-
-TemplateContainerItem::~TemplateContainerItem ()
-{
-}
-
-void TemplateContainerItem::Paint (drawinglayer::processor2d::BaseProcessor2D *pProcessor,
- const ThumbnailItemAttributes *pAttrs)
-{
- int nCount = 0;
- int nSeqSize = 2;
-
- if (!maPreview1.IsEmpty())
- nSeqSize += 3;
-
- if (!maPreview2.IsEmpty())
- nSeqSize += 3;
-
- BColor aFillColor = pAttrs->aFillColor;
- Primitive2DSequence aSeq(nSeqSize);
-
- // Draw background
- if ( mbSelected || mbHover )
- aFillColor = pAttrs->aHighlightColor;
-
- aSeq[nCount++] = Primitive2DReference( new PolyPolygonColorPrimitive2D(
- B2DPolyPolygon(Polygon(maDrawArea,5,5).getB2DPolygon()),
- aFillColor));
-
- // Draw thumbnail
- Point aPos = maPrev1Pos;
- Size aImageSize = maPreview1.GetSizePixel();
-
- float fScaleX = 1.0f;
- float fScaleY = 1.0f;
-
- if (!maPreview2.IsEmpty())
- {
- fScaleX = 0.8f;
- fScaleY = 0.8f;
-
- float fWidth = aImageSize.Width()*fScaleX;
- float fHeight = aImageSize.Height()*fScaleY;
- float fPosX = aPos.getX()+35*fScaleX;
- float fPosY = aPos.getY()+20*fScaleY;
-
- B2DPolygon aBounds;
- aBounds.append(B2DPoint(fPosX,fPosY));
- aBounds.append(B2DPoint(fPosX+fWidth,fPosY));
- aBounds.append(B2DPoint(fPosX+fWidth,fPosY+fHeight));
- aBounds.append(B2DPoint(fPosX,fPosY+fHeight));
- aBounds.setClosed(true);
-
- aSeq[nCount++] = Primitive2DReference( new PolyPolygonColorPrimitive2D(
- B2DPolyPolygon(aBounds), Color(COL_WHITE).getBColor()));
- aSeq[nCount++] = Primitive2DReference( new FillBitmapPrimitive2D(
- createScaleTranslateB2DHomMatrix(fScaleX,fScaleY,aPos.X(),aPos.Y()),
- FillBitmapAttribute(maPreview2,
- B2DPoint(35,20),
- B2DVector(aImageSize.Width(),aImageSize.Height()),
- false)
- ));
-
- // draw thumbnail borders
- aSeq[nCount++] = Primitive2DReference(createBorderLine(aBounds));
- }
-
- if (!maPreview1.IsEmpty())
- {
- // draw thumbnail borders
- float fWidth = aImageSize.Width()*fScaleX;
- float fHeight = aImageSize.Height()*fScaleY;
- float fPosX = aPos.getX();
- float fPosY = aPos.getY();
-
- B2DPolygon aBounds;
- aBounds.append(B2DPoint(fPosX,fPosY));
- aBounds.append(B2DPoint(fPosX+fWidth,fPosY));
- aBounds.append(B2DPoint(fPosX+fWidth,fPosY+fHeight));
- aBounds.append(B2DPoint(fPosX,fPosY+fHeight));
- aBounds.setClosed(true);
-
- aSeq[nCount++] = Primitive2DReference( new PolyPolygonColorPrimitive2D(
- B2DPolyPolygon(aBounds), Color(COL_WHITE).getBColor()));
- aSeq[nCount++] = Primitive2DReference( new FillBitmapPrimitive2D(
- createScaleTranslateB2DHomMatrix(fScaleX,fScaleY,aPos.X(),aPos.Y()),
- FillBitmapAttribute(maPreview1,
- B2DPoint(0,0),
- B2DVector(aImageSize.Width(),aImageSize.Height()),
- false)
- ));
-
- aSeq[nCount++] = Primitive2DReference(createBorderLine(aBounds));
- }
-
- // Draw centered text below thumbnail
- aPos = maTextPos;
-
- // Create the text primitive
- basegfx::B2DHomMatrix aTextMatrix( createScaleTranslateB2DHomMatrix(
- pAttrs->aFontSize.getX(), pAttrs->aFontSize.getY(),
- double( aPos.X() ), double( aPos.Y() ) ) );
-
- aSeq[nCount++] = Primitive2DReference(
- new TextSimplePortionPrimitive2D(aTextMatrix,
- maTitle,0,maTitle.getLength(),
- std::vector< double >( ),
- pAttrs->aFontAttr,
- com::sun::star::lang::Locale(),
- Color(COL_BLACK).getBColor() ) );
-
- pProcessor->process(aSeq);
-}
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
-
-
diff --git a/sfx2/source/doc/templatedlg.cxx b/sfx2/source/doc/templatedlg.cxx
index b0ef5a2..26cf58b 100644
--- a/sfx2/source/doc/templatedlg.cxx
+++ b/sfx2/source/doc/templatedlg.cxx
@@ -23,7 +23,7 @@
#include <sfx2/sfxresid.hxx>
#include <sfx2/templateinfodlg.hxx>
#include <sfx2/templatelocalview.hxx>
-#include <sfx2/templatelocalviewitem.hxx>
+#include <sfx2/templatecontaineritem.hxx>
#include <sfx2/templateremoteview.hxx>
#include <sfx2/templaterepository.hxx>
#include <sfx2/templateviewitem.hxx>
commit e913e9efdf2740505900cf7430523cf4fd33b4b3
Author: Cédric Bosdonnat <cedric.bosdonnat at free.fr>
Date: Mon Dec 17 22:23:46 2012 +0100
sfx2: renamed TemplateLocalViewItem into TemplateContainerItem
Change-Id: I8ff318a7bcad21c4fe8d5dda818fad5763a6ff02
diff --git a/sfx2/inc/sfx2/templatelocalview.hxx b/sfx2/inc/sfx2/templatelocalview.hxx
index dac7fed..c5a1f84 100644
--- a/sfx2/inc/sfx2/templatelocalview.hxx
+++ b/sfx2/inc/sfx2/templatelocalview.hxx
@@ -16,7 +16,7 @@
#include <sfx2/templateproperties.hxx>
class SfxDocumentTemplates;
-class TemplateLocalViewItem;
+class TemplateContainerItem;
namespace com {
namespace sun { namespace star { namespace frame {
@@ -59,7 +59,7 @@ public:
bool copyFrom (const sal_uInt16 nRegionItemId, const BitmapEx &rThumbnail, const OUString &rPath);
- bool copyFrom(TemplateLocalViewItem *pItem, const OUString &rPath);
+ bool copyFrom(TemplateContainerItem *pItem, const OUString &rPath);
bool exportTo (const sal_uInt16 nItemId, const sal_uInt16 nRegionItemId, const OUString &rName);
@@ -67,7 +67,7 @@ public:
com::sun::star::uno::Reference<com::sun::star::frame::XModel> &rModel,
const OUString &rName);
- bool saveTemplateAs (const TemplateLocalViewItem *pDstItem,
+ bool saveTemplateAs (const TemplateContainerItem *pDstItem,
com::sun::star::uno::Reference<com::sun::star::frame::XModel> &rModel,
const OUString &rName);
diff --git a/sfx2/inc/sfx2/templatelocalviewitem.hxx b/sfx2/inc/sfx2/templatelocalviewitem.hxx
index 739f70e..2c2d18b 100644
--- a/sfx2/inc/sfx2/templatelocalviewitem.hxx
+++ b/sfx2/inc/sfx2/templatelocalviewitem.hxx
@@ -13,18 +13,16 @@
#include <sfx2/templateproperties.hxx>
#include <sfx2/thumbnailviewitem.hxx>
-class TemplateViewItem;
-
-class TemplateLocalViewItem : public ThumbnailViewItem
+class TemplateContainerItem : public ThumbnailViewItem
{
public:
BitmapEx maPreview2;
std::vector<TemplateItemProperties> maTemplates;
- TemplateLocalViewItem (ThumbnailView &rView);
+ TemplateContainerItem (ThumbnailView &rView);
- virtual ~TemplateLocalViewItem ();
+ virtual ~TemplateContainerItem ();
const Point& getPrev2Pos () const { return maPrev2Pos; }
diff --git a/sfx2/source/control/templatelocalview.cxx b/sfx2/source/control/templatelocalview.cxx
index 749eaa0..5da77d6 100644
--- a/sfx2/source/control/templatelocalview.cxx
+++ b/sfx2/source/control/templatelocalview.cxx
@@ -30,7 +30,7 @@
using namespace ::com::sun::star;
using namespace ::com::sun::star::frame;
-static void lcl_updateThumbnails (TemplateLocalViewItem *pItem);
+static void lcl_updateThumbnails (TemplateContainerItem *pItem);
class FolderFilter_Application : public ViewFilter_Application
{
@@ -43,7 +43,7 @@ public:
bool operator () (const ThumbnailViewItem *pItem)
{
- TemplateLocalViewItem *pFolderItem = (TemplateLocalViewItem*)pItem;
+ TemplateContainerItem *pFolderItem = (TemplateContainerItem*)pItem;
std::vector<TemplateItemProperties> &rTemplates = pFolderItem->maTemplates;
@@ -109,7 +109,7 @@ void TemplateLocalView::Populate ()
aRegionName += "...";
}
- TemplateLocalViewItem* pItem = new TemplateLocalViewItem( *this );
+ TemplateContainerItem* pItem = new TemplateContainerItem( *this );
pItem->mnId = i+1;
pItem->maTitle = aRegionName;
pItem->setSelectClickHdl(LINK(this,ThumbnailView,OnItemSelected));
@@ -168,7 +168,7 @@ void TemplateLocalView::reload ()
if (mItemList[i]->mnId == nItemId)
{
mpItemView->Clear();
- mpItemView->InsertItems(static_cast<TemplateLocalViewItem*>(mItemList[i])->maTemplates);
+ mpItemView->InsertItems(static_cast<TemplateContainerItem*>(mItemList[i])->maTemplates);
break;
}
}
@@ -228,7 +228,7 @@ TemplateLocalView::getFilteredItems(const boost::function<bool (const TemplateIt
for (size_t i = 0; i < mItemList.size(); ++i)
{
- TemplateLocalViewItem *pFolderItem = static_cast<TemplateLocalViewItem*>(mItemList[i]);
+ TemplateContainerItem *pFolderItem = static_cast<TemplateContainerItem*>(mItemList[i]);
for (size_t j = 0; j < pFolderItem->maTemplates.size(); ++j)
{
@@ -255,7 +255,7 @@ sal_uInt16 TemplateLocalView::createRegion(const OUString &rName)
aRegionName += "...";
}
- TemplateLocalViewItem* pItem = new TemplateLocalViewItem( *this );
+ TemplateContainerItem* pItem = new TemplateContainerItem( *this );
pItem->mnId = nRegionId+1;
pItem->maTitle = aRegionName;
pItem->setSelectClickHdl(LINK(this,ThumbnailView,OnItemSelected));
@@ -290,7 +290,7 @@ bool TemplateLocalView::removeTemplate (const sal_uInt16 nItemId, const sal_uInt
{
if (mItemList[i]->mnId == nSrcItemId)
{
- TemplateLocalViewItem *pItem = static_cast<TemplateLocalViewItem*>(mItemList[i]);
+ TemplateContainerItem *pItem = static_cast<TemplateContainerItem*>(mItemList[i]);
std::vector<TemplateItemProperties>::iterator pIter;
for (pIter = pItem->maTemplates.begin(); pIter != pItem->maTemplates.end(); ++pIter)
{
@@ -328,15 +328,15 @@ bool TemplateLocalView::moveTemplate (const ThumbnailViewItem *pItem, const sal_
bool bRet = true;
bool bRefresh = false;
- TemplateLocalViewItem *pTarget = NULL;
- TemplateLocalViewItem *pSrc = NULL;
+ TemplateContainerItem *pTarget = NULL;
+ TemplateContainerItem *pSrc = NULL;
for (size_t i = 0, n = mItemList.size(); i < n; ++i)
{
if (mItemList[i]->mnId == nTargetItem)
- pTarget = static_cast<TemplateLocalViewItem*>(mItemList[i]);
+ pTarget = static_cast<TemplateContainerItem*>(mItemList[i]);
else if (mItemList[i]->mnId == nSrcItem)
- pSrc = static_cast<TemplateLocalViewItem*>(mItemList[i]);
+ pSrc = static_cast<TemplateContainerItem*>(mItemList[i]);
}
if (pTarget && pSrc)
@@ -417,15 +417,15 @@ bool TemplateLocalView::moveTemplates(std::set<const ThumbnailViewItem *> &rItem
sal_uInt16 nSrcRegionId = mpItemView->getId();
sal_uInt16 nSrcRegionItemId = nSrcRegionId + 1;
- TemplateLocalViewItem *pTarget = NULL;
- TemplateLocalViewItem *pSrc = NULL;
+ TemplateContainerItem *pTarget = NULL;
+ TemplateContainerItem *pSrc = NULL;
for (size_t i = 0, n = mItemList.size(); i < n; ++i)
{
if (mItemList[i]->mnId == nTargetItem)
- pTarget = static_cast<TemplateLocalViewItem*>(mItemList[i]);
+ pTarget = static_cast<TemplateContainerItem*>(mItemList[i]);
else if (mItemList[i]->mnId == nSrcRegionItemId)
- pSrc = static_cast<TemplateLocalViewItem*>(mItemList[i]);
+ pSrc = static_cast<TemplateContainerItem*>(mItemList[i]);
}
if (pTarget && pSrc)
@@ -512,8 +512,8 @@ bool TemplateLocalView::copyFrom(const sal_uInt16 nRegionItemId, const BitmapEx
sal_uInt16 nId = 0;
sal_uInt16 nDocId = 0;
- TemplateLocalViewItem *pRegionItem =
- static_cast<TemplateLocalViewItem*>(mItemList[i]);
+ TemplateContainerItem *pRegionItem =
+ static_cast<TemplateContainerItem*>(mItemList[i]);
if (!pRegionItem->maTemplates.empty())
{
@@ -533,8 +533,8 @@ bool TemplateLocalView::copyFrom(const sal_uInt16 nRegionItemId, const BitmapEx
aTemplate.aThumbnail = rThumbnail;
aTemplate.aPath = mpDocTemplates->GetPath(nRegionId,nDocId);
- TemplateLocalViewItem *pItem =
- static_cast<TemplateLocalViewItem*>(mItemList[i]);
+ TemplateContainerItem *pItem =
+ static_cast<TemplateContainerItem*>(mItemList[i]);
pItem->maTemplates.push_back(aTemplate);
@@ -550,7 +550,7 @@ bool TemplateLocalView::copyFrom(const sal_uInt16 nRegionItemId, const BitmapEx
return false;
}
-bool TemplateLocalView::copyFrom (TemplateLocalViewItem *pItem, const OUString &rPath)
+bool TemplateLocalView::copyFrom (TemplateContainerItem *pItem, const OUString &rPath)
{
sal_uInt16 nId = 0;
sal_uInt16 nDocId = 0;
@@ -595,8 +595,8 @@ bool TemplateLocalView::exportTo(const sal_uInt16 nItemId, const sal_uInt16 nReg
{
if (mItemList[i]->mnId == nRegionItemId)
{
- TemplateLocalViewItem *pRegItem =
- static_cast<TemplateLocalViewItem*>(mItemList[i]);
+ TemplateContainerItem *pRegItem =
+ static_cast<TemplateContainerItem*>(mItemList[i]);
std::vector<TemplateItemProperties>::iterator aIter;
for (aIter = pRegItem->maTemplates.begin(); aIter != pRegItem->maTemplates.end(); ++aIter)
@@ -627,7 +627,7 @@ bool TemplateLocalView::saveTemplateAs (sal_uInt16 nItemId,
{
if (mItemList[i]->mnId == nItemId)
{
- bRet = saveTemplateAs((const TemplateLocalViewItem*)mItemList[i],rModel,rName);
+ bRet = saveTemplateAs((const TemplateContainerItem*)mItemList[i],rModel,rName);
break;
}
}
@@ -635,7 +635,7 @@ bool TemplateLocalView::saveTemplateAs (sal_uInt16 nItemId,
return bRet;
}
-bool TemplateLocalView::saveTemplateAs(const TemplateLocalViewItem *pDstItem,
+bool TemplateLocalView::saveTemplateAs(const TemplateContainerItem *pDstItem,
com::sun::star::uno::Reference<com::sun::star::frame::XModel> &rModel,
const OUString &rName)
{
@@ -658,8 +658,8 @@ bool TemplateLocalView::isTemplateNameUnique(const sal_uInt16 nRegionItemId, con
{
if (mItemList[i]->mnId == nRegionItemId)
{
- TemplateLocalViewItem *pRegItem =
- static_cast<TemplateLocalViewItem*>(mItemList[i]);
+ TemplateContainerItem *pRegItem =
+ static_cast<TemplateContainerItem*>(mItemList[i]);
std::vector<TemplateItemProperties>::iterator aIter;
for (aIter = pRegItem->maTemplates.begin(); aIter != pRegItem->maTemplates.end(); ++aIter)
@@ -682,14 +682,14 @@ void TemplateLocalView::OnItemDblClicked (ThumbnailViewItem *pRegionItem)
mpItemView->setId(nRegionId);
mpItemView->setName(mpDocTemplates->GetRegionName(nRegionId));
- mpItemView->InsertItems(static_cast<TemplateLocalViewItem*>(pRegionItem)->maTemplates);
+ mpItemView->InsertItems(static_cast<TemplateContainerItem*>(pRegionItem)->maTemplates);
mpItemView->filterItems(ViewFilter_Application(meFilterOption));
showOverlay(true);
}
-static void lcl_updateThumbnails (TemplateLocalViewItem *pItem)
+static void lcl_updateThumbnails (TemplateContainerItem *pItem)
{
pItem->maPreview1.Clear();
pItem->maPreview2.Clear();
diff --git a/sfx2/source/control/templatelocalviewitem.cxx b/sfx2/source/control/templatelocalviewitem.cxx
index 54ba379..f8d24c5 100644
--- a/sfx2/source/control/templatelocalviewitem.cxx
+++ b/sfx2/source/control/templatelocalviewitem.cxx
@@ -26,16 +26,16 @@ using namespace basegfx::tools;
using namespace drawinglayer::attribute;
using namespace drawinglayer::primitive2d;
-TemplateLocalViewItem::TemplateLocalViewItem (ThumbnailView &rView)
+TemplateContainerItem::TemplateContainerItem (ThumbnailView &rView)
: ThumbnailViewItem(rView)
{
}
-TemplateLocalViewItem::~TemplateLocalViewItem ()
+TemplateContainerItem::~TemplateContainerItem ()
{
}
-void TemplateLocalViewItem::Paint (drawinglayer::processor2d::BaseProcessor2D *pProcessor,
+void TemplateContainerItem::Paint (drawinglayer::processor2d::BaseProcessor2D *pProcessor,
const ThumbnailItemAttributes *pAttrs)
{
int nCount = 0;
diff --git a/sfx2/source/doc/templatedlg.cxx b/sfx2/source/doc/templatedlg.cxx
index e400d27..b0ef5a2 100644
--- a/sfx2/source/doc/templatedlg.cxx
+++ b/sfx2/source/doc/templatedlg.cxx
@@ -807,7 +807,7 @@ void SfxTemplateManagerDlg::OnTemplateImport ()
for (pIter = maSelFolders.begin(); pIter != maSelFolders.end(); ++pIter)
{
OUString aTemplateList;
- TemplateLocalViewItem *pFolder = (TemplateLocalViewItem*)(*pIter);
+ TemplateContainerItem *pFolder = (TemplateContainerItem*)(*pIter);
for (size_t i = 0, n = aFiles.getLength(); i < n; ++i)
{
@@ -1175,7 +1175,7 @@ void SfxTemplateManagerDlg::OnTemplateSaveAs()
std::set<const ThumbnailViewItem*>::const_iterator pIter;
for (pIter = maSelFolders.begin(); pIter != maSelFolders.end(); ++pIter)
{
- TemplateLocalViewItem *pItem = (TemplateLocalViewItem*)(*pIter);
+ TemplateContainerItem *pItem = (TemplateContainerItem*)(*pIter);
if (!maView->isTemplateNameUnique(pItem->mnId,aName))
{
commit d998e633e74eba87ffd0f41b98e6aa13180adf67
Author: Cédric Bosdonnat <cedric.bosdonnat at free.fr>
Date: Mon Dec 17 22:06:18 2012 +0100
sfx2: rename TemplateRemoteViewItem to TemplateRepository
Change-Id: I7a7479f0264f38aa0193d50acfe58b20ff57d8d0
diff --git a/sfx2/inc/sfx2/templateremoteview.hxx b/sfx2/inc/sfx2/templateremoteview.hxx
index e8076f6..ad95463 100644
--- a/sfx2/inc/sfx2/templateremoteview.hxx
+++ b/sfx2/inc/sfx2/templateremoteview.hxx
@@ -15,7 +15,7 @@
#include <com/sun/star/ucb/XCommandEnvironment.hpp>
-class TemplateRemoteViewItem;
+class TemplateRepository;
class TemplateRemoteView : public TemplateAbstractView
{
@@ -29,7 +29,7 @@ public:
virtual void showOverlay (bool bVisible);
- bool loadRepository (TemplateRemoteViewItem* pRepository, bool bRefresh);
+ bool loadRepository (TemplateRepository* pRepository, bool bRefresh);
private:
diff --git a/sfx2/inc/sfx2/templaterepository.hxx b/sfx2/inc/sfx2/templaterepository.hxx
index 56f6f75..0c7725c 100644
--- a/sfx2/inc/sfx2/templaterepository.hxx
+++ b/sfx2/inc/sfx2/templaterepository.hxx
@@ -12,13 +12,13 @@
#include <sfx2/templateproperties.hxx>
-class TemplateRemoteViewItem
+class TemplateRepository
{
public:
- TemplateRemoteViewItem () : mnId(0) { };
+ TemplateRepository () : mnId(0) { };
- virtual ~TemplateRemoteViewItem () { };
+ virtual ~TemplateRepository () { };
void setURL (const rtl::OUString &rURL) { maUrl = rURL; }
diff --git a/sfx2/inc/templatedlg.hxx b/sfx2/inc/templatedlg.hxx
index 73c420a..44a6653 100644
--- a/sfx2/inc/templatedlg.hxx
+++ b/sfx2/inc/templatedlg.hxx
@@ -22,7 +22,7 @@ class SfxTemplateInfoDlg;
class TemplateAbstractView;
class TemplateLocalView;
class TemplateRemoteView;
-class TemplateRemoteViewItem;
+class TemplateRepository;
class TemplateSearchView;
class ThumbnailView;
class ThumbnailViewItem;
@@ -113,7 +113,7 @@ private:
// Remote repositories handling methods
void loadRepositories ();
- const std::vector<TemplateRemoteViewItem*>& getRepositories () const { return maRepositories; }
+ const std::vector<TemplateRepository*>& getRepositories () const { return maRepositories; }
bool insertRepository (const OUString &rName, const OUString &rURL);
@@ -146,7 +146,7 @@ private:
com::sun::star::uno::Reference< com::sun::star::frame::XComponentLoader > mxDesktop;
bool mbIsSynced; ///< Tells whether maRepositories is synchronized with the user config
- std::vector<TemplateRemoteViewItem*> maRepositories; ///< Stores the remote repositories for templates
+ std::vector<TemplateRepository*> maRepositories; ///< Stores the remote repositories for templates
};
#endif // TEMPLATEDLG_HXX
diff --git a/sfx2/source/control/templateremoteview.cxx b/sfx2/source/control/templateremoteview.cxx
index 9faf682..ac00a0a 100644
--- a/sfx2/source/control/templateremoteview.cxx
+++ b/sfx2/source/control/templateremoteview.cxx
@@ -77,7 +77,7 @@ void TemplateRemoteView::showOverlay (bool bVisible)
}
}
-bool TemplateRemoteView::loadRepository (TemplateRemoteViewItem* pItem, bool bRefresh)
+bool TemplateRemoteView::loadRepository (TemplateRepository* pItem, bool bRefresh)
{
if (!pItem)
return false;
@@ -92,7 +92,7 @@ bool TemplateRemoteView::loadRepository (TemplateRemoteViewItem* pItem, bool bRe
mpItemView->setId(pItem->mnId);
mpItemView->setName(pItem->maTitle);
- OUString aURL = static_cast<TemplateRemoteViewItem*>(pItem)->getURL();
+ OUString aURL = pItem->getURL();
try
{
diff --git a/sfx2/source/doc/templatedlg.cxx b/sfx2/source/doc/templatedlg.cxx
index eb28426..e400d27 100644
--- a/sfx2/source/doc/templatedlg.cxx
+++ b/sfx2/source/doc/templatedlg.cxx
@@ -625,7 +625,7 @@ IMPL_LINK(SfxTemplateManagerDlg, RepositoryMenuSelectHdl, Menu*, pMenu)
{
sal_uInt16 nRepoId = nMenuId - MNI_REPOSITORY_BASE;
- TemplateRemoteViewItem *pRepository = NULL;
+ TemplateRepository *pRepository = NULL;
for (size_t i = 0, n = maRepositories.size(); i < n; ++i)
{
@@ -1211,7 +1211,7 @@ void SfxTemplateManagerDlg::createRepositoryMenu()
mpRepositoryMenu->InsertItem(MNI_REPOSITORY_LOCAL,SfxResId(STR_REPOSITORY_LOCAL).toString());
- const std::vector<TemplateRemoteViewItem*> &rRepos = getRepositories();
+ const std::vector<TemplateRepository*> &rRepos = getRepositories();
for (size_t i = 0, n = rRepos.size(); i < n; ++i)
mpRepositoryMenu->InsertItem(MNI_REPOSITORY_BASE+rRepos[i]->mnId,rRepos[i]->maTitle);
@@ -1449,7 +1449,7 @@ void SfxTemplateManagerDlg::loadRepositories()
for (sal_Int32 i = 0; i < aUrls.getLength() && i < aNames.getLength(); ++i)
{
- TemplateRemoteViewItem *pItem = new TemplateRemoteViewItem();
+ TemplateRepository *pItem = new TemplateRepository();
pItem->mnId = i+1;
pItem->maTitle = aNames[i];
@@ -1467,7 +1467,7 @@ bool SfxTemplateManagerDlg::insertRepository(const OUString &rName, const OUStri
return false;
}
- TemplateRemoteViewItem *pItem = new TemplateRemoteViewItem();
+ TemplateRepository *pItem = new TemplateRepository();
pItem->mnId = maRepositories.size()+1;
pItem->maTitle = rName;
commit 5667dbd3e36869a08a93e7d18e610764b210caa6
Author: Cédric Bosdonnat <cedric.bosdonnat at free.fr>
Date: Mon Dec 17 21:53:25 2012 +0100
sfx2: renamed templateremoteviewitem.hxx to templaterepository.hxx
Change-Id: I5fb96df9ae95b42eb4e2485068488e8c81929563
diff --git a/sfx2/Package_inc.mk b/sfx2/Package_inc.mk
index 3292506..39aafac 100644
--- a/sfx2/Package_inc.mk
+++ b/sfx2/Package_inc.mk
@@ -125,7 +125,7 @@ $(eval $(call gb_Package_add_file,sfx2_inc,inc/sfx2/templateview.hxx,sfx2/templa
$(eval $(call gb_Package_add_file,sfx2_inc,inc/sfx2/templatelocalview.hxx,sfx2/templatelocalview.hxx))
$(eval $(call gb_Package_add_file,sfx2_inc,inc/sfx2/templatelocalviewitem.hxx,sfx2/templatelocalviewitem.hxx))
$(eval $(call gb_Package_add_file,sfx2_inc,inc/sfx2/templateremoteview.hxx,sfx2/templateremoteview.hxx))
-$(eval $(call gb_Package_add_file,sfx2_inc,inc/sfx2/templateremoteviewitem.hxx,sfx2/templateremoteviewitem.hxx))
+$(eval $(call gb_Package_add_file,sfx2_inc,inc/sfx2/templaterepository.hxx,sfx2/templaterepository.hxx))
$(eval $(call gb_Package_add_file,sfx2_inc,inc/sfx2/thumbnailview.hxx,sfx2/thumbnailview.hxx))
$(eval $(call gb_Package_add_file,sfx2_inc,inc/sfx2/thumbnailviewitem.hxx,sfx2/thumbnailviewitem.hxx))
$(eval $(call gb_Package_add_file,sfx2_inc,inc/sfx2/titledockwin.hxx,sfx2/titledockwin.hxx))
diff --git a/sfx2/inc/sfx2/templateremoteviewitem.hxx b/sfx2/inc/sfx2/templateremoteviewitem.hxx
deleted file mode 100644
index 83d47bc..0000000
--- a/sfx2/inc/sfx2/templateremoteviewitem.hxx
+++ /dev/null
@@ -1,46 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- */
-
-#ifndef __SFX2_TEMPLATEREMOTEVIEWITEM_HXX__
-#define __SFX2_TEMPLATEREMOTEVIEWITEM_HXX__
-
-#include <sfx2/templateproperties.hxx>
-
-class TemplateRemoteViewItem
-{
-public:
-
- TemplateRemoteViewItem () : mnId(0) { };
-
- virtual ~TemplateRemoteViewItem () { };
-
- void setURL (const rtl::OUString &rURL) { maUrl = rURL; }
-
- const rtl::OUString& getURL () const { return maUrl; }
-
- void insertTemplate (const TemplateItemProperties &prop) { maTemplates.push_back(prop); }
-
- void clearTemplates () { maTemplates.clear(); }
-
- const std::vector<TemplateItemProperties>& getTemplates () const { return maTemplates; }
-
-public:
-
- sal_uInt16 mnId;
- rtl::OUString maTitle;
-
-private:
-
- rtl::OUString maUrl;
- std::vector<TemplateItemProperties> maTemplates;
-};
-
-#endif // __SFX2_TEMPLATEREMOTEVIEWITEM_HXX__
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sfx2/inc/sfx2/templaterepository.hxx b/sfx2/inc/sfx2/templaterepository.hxx
new file mode 100644
index 0000000..56f6f75
--- /dev/null
+++ b/sfx2/inc/sfx2/templaterepository.hxx
@@ -0,0 +1,46 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ */
+
+#ifndef __SFX2_TEMPLATEREPOSITORY_HXX__
+#define __SFX2_TEMPLATEREPOSITORY_HXX__
+
+#include <sfx2/templateproperties.hxx>
+
+class TemplateRemoteViewItem
+{
+public:
+
+ TemplateRemoteViewItem () : mnId(0) { };
+
+ virtual ~TemplateRemoteViewItem () { };
+
+ void setURL (const rtl::OUString &rURL) { maUrl = rURL; }
+
+ const rtl::OUString& getURL () const { return maUrl; }
+
+ void insertTemplate (const TemplateItemProperties &prop) { maTemplates.push_back(prop); }
+
+ void clearTemplates () { maTemplates.clear(); }
+
+ const std::vector<TemplateItemProperties>& getTemplates () const { return maTemplates; }
+
+public:
+
+ sal_uInt16 mnId;
+ rtl::OUString maTitle;
+
+private:
+
+ rtl::OUString maUrl;
+ std::vector<TemplateItemProperties> maTemplates;
+};
+
+#endif // __SFX2_TEMPLATEREPOSITORY_HXX__
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sfx2/source/control/templateremoteview.cxx b/sfx2/source/control/templateremoteview.cxx
index 9e84c3f..9faf682 100644
--- a/sfx2/source/control/templateremoteview.cxx
+++ b/sfx2/source/control/templateremoteview.cxx
@@ -10,7 +10,7 @@
#include <sfx2/templateremoteview.hxx>
#include <comphelper/processfactory.hxx>
-#include <sfx2/templateremoteviewitem.hxx>
+#include <sfx2/templaterepository.hxx>
#include <sfx2/templateview.hxx>
#include <sfx2/templateviewitem.hxx>
#include <svtools/imagemgr.hxx>
diff --git a/sfx2/source/doc/templatedlg.cxx b/sfx2/source/doc/templatedlg.cxx
index 1e1ebd7ee6..eb28426 100644
--- a/sfx2/source/doc/templatedlg.cxx
+++ b/sfx2/source/doc/templatedlg.cxx
@@ -25,7 +25,7 @@
#include <sfx2/templatelocalview.hxx>
#include <sfx2/templatelocalviewitem.hxx>
#include <sfx2/templateremoteview.hxx>
-#include <sfx2/templateremoteviewitem.hxx>
+#include <sfx2/templaterepository.hxx>
#include <sfx2/templateviewitem.hxx>
#include <sfx2/thumbnailviewitem.hxx>
#include <sot/storage.hxx>
commit 83abceccfc011e8cb60cceea8984c7f51410bcd6
Author: Cédric Bosdonnat <cedric.bosdonnat at free.fr>
Date: Mon Dec 17 21:51:04 2012 +0100
Template Manager: moved repositories storage to dialog
Change-Id: If049e05b7cec060cbdbc5a366a4019f088325e1f
diff --git a/sfx2/Library_sfx.mk b/sfx2/Library_sfx.mk
index 58c4e81..6496e38 100644
--- a/sfx2/Library_sfx.mk
+++ b/sfx2/Library_sfx.mk
@@ -143,7 +143,6 @@ $(eval $(call gb_Library_add_exception_objects,sfx,\
sfx2/source/control/templatelocalview \
sfx2/source/control/templatelocalviewitem \
sfx2/source/control/templateremoteview \
- sfx2/source/control/templateremoteviewitem \
sfx2/source/control/templatesearchview \
sfx2/source/control/thumbnailviewitem \
sfx2/source/control/thumbnailviewacc \
diff --git a/sfx2/inc/sfx2/templateabstractview.hxx b/sfx2/inc/sfx2/templateabstractview.hxx
index a86ced0..a0cb1e0 100644
--- a/sfx2/inc/sfx2/templateabstractview.hxx
+++ b/sfx2/inc/sfx2/templateabstractview.hxx
@@ -81,9 +81,9 @@ public:
virtual ~TemplateAbstractView ();
// Fill view with template folders thumbnails
- virtual void Populate () = 0;
+ virtual void Populate () { };
- virtual void reload () = 0;
+ virtual void reload () { };
virtual void filterTemplatesByApp (const FILTER_APPLICATION &eApp) = 0;
diff --git a/sfx2/inc/sfx2/templateremoteview.hxx b/sfx2/inc/sfx2/templateremoteview.hxx
index 1d7e49d..e8076f6 100644
--- a/sfx2/inc/sfx2/templateremoteview.hxx
+++ b/sfx2/inc/sfx2/templateremoteview.hxx
@@ -25,29 +25,14 @@ public:
virtual ~TemplateRemoteView ();
- // Load repositories from user settings.
- virtual void Populate ();
-
- virtual void reload ();
-
virtual void filterTemplatesByApp (const FILTER_APPLICATION &eApp);
virtual void showOverlay (bool bVisible);
- bool loadRepository (const sal_uInt16 nRepositoryId, bool bRefresh);
-
- const std::vector<TemplateRemoteViewItem*>& getRepositories () const { return maRepositories; }
-
- bool insertRepository (const OUString &rName, const OUString &rURL);
-
- bool deleteRepository (const sal_uInt16 nRepositoryId);
-
- void syncRepositories () const;
+ bool loadRepository (TemplateRemoteViewItem* pRepository, bool bRefresh);
private:
- bool mbIsSynced;
- std::vector<TemplateRemoteViewItem*> maRepositories;
com::sun::star::uno::Reference< com::sun::star::ucb::XCommandEnvironment > m_xCmdEnv;
};
diff --git a/sfx2/inc/sfx2/templateremoteviewitem.hxx b/sfx2/inc/sfx2/templateremoteviewitem.hxx
index 63f2c7d..83d47bc 100644
--- a/sfx2/inc/sfx2/templateremoteviewitem.hxx
+++ b/sfx2/inc/sfx2/templateremoteviewitem.hxx
@@ -10,16 +10,15 @@
#ifndef __SFX2_TEMPLATEREMOTEVIEWITEM_HXX__
#define __SFX2_TEMPLATEREMOTEVIEWITEM_HXX__
-#include <sfx2/thumbnailviewitem.hxx>
#include <sfx2/templateproperties.hxx>
-class TemplateRemoteViewItem : public ThumbnailViewItem
+class TemplateRemoteViewItem
{
public:
- TemplateRemoteViewItem (ThumbnailView &rView);
+ TemplateRemoteViewItem () : mnId(0) { };
- virtual ~TemplateRemoteViewItem ();
+ virtual ~TemplateRemoteViewItem () { };
void setURL (const rtl::OUString &rURL) { maUrl = rURL; }
@@ -31,6 +30,11 @@ public:
const std::vector<TemplateItemProperties>& getTemplates () const { return maTemplates; }
+public:
+
+ sal_uInt16 mnId;
+ rtl::OUString maTitle;
+
private:
rtl::OUString maUrl;
diff --git a/sfx2/inc/templatedlg.hxx b/sfx2/inc/templatedlg.hxx
index 3f7ba13..73c420a 100644
--- a/sfx2/inc/templatedlg.hxx
+++ b/sfx2/inc/templatedlg.hxx
@@ -22,6 +22,7 @@ class SfxTemplateInfoDlg;
class TemplateAbstractView;
class TemplateLocalView;
class TemplateRemoteView;
+class TemplateRemoteViewItem;
class TemplateSearchView;
class ThumbnailView;
class ThumbnailViewItem;
@@ -109,6 +110,17 @@ private:
void localSearchMoveTo (sal_uInt16 nMenuId);
+ // Remote repositories handling methods
+ void loadRepositories ();
+
+ const std::vector<TemplateRemoteViewItem*>& getRepositories () const { return maRepositories; }
+
+ bool insertRepository (const OUString &rName, const OUString &rURL);
+
+ bool deleteRepository (const sal_uInt16 nRepositoryId);
+
+ void syncRepositories () const;
+
private:
TabControl maTabControl;
@@ -132,6 +144,9 @@ private:
bool mbIsSaveMode; ///< Flag that indicates if we are in save mode or not.
com::sun::star::uno::Reference< com::sun::star::frame::XModel > m_xModel;
com::sun::star::uno::Reference< com::sun::star::frame::XComponentLoader > mxDesktop;
+
+ bool mbIsSynced; ///< Tells whether maRepositories is synchronized with the user config
+ std::vector<TemplateRemoteViewItem*> maRepositories; ///< Stores the remote repositories for templates
};
#endif // TEMPLATEDLG_HXX
diff --git a/sfx2/source/control/templateremoteview.cxx b/sfx2/source/control/templateremoteview.cxx
index a04e471..9e84c3f 100644
--- a/sfx2/source/control/templateremoteview.cxx
+++ b/sfx2/source/control/templateremoteview.cxx
@@ -10,7 +10,6 @@
#include <sfx2/templateremoteview.hxx>
#include <comphelper/processfactory.hxx>
-#include <officecfg/Office/Common.hxx>
#include <sfx2/templateremoteviewitem.hxx>
#include <sfx2/templateview.hxx>
#include <sfx2/templateviewitem.hxx>
@@ -47,7 +46,6 @@ enum
TemplateRemoteView::TemplateRemoteView (Window *pParent, WinBits nWinStyle, bool bDisableTransientChildren)
: TemplateAbstractView(pParent,nWinStyle,bDisableTransientChildren)
- , mbIsSynced(true)
{
mpItemView->SetColor(Color(COL_WHITE));
@@ -60,36 +58,6 @@ TemplateRemoteView::TemplateRemoteView (Window *pParent, WinBits nWinStyle, bool
TemplateRemoteView::~TemplateRemoteView ()
{
- for (size_t i = 0, n = maRepositories.size(); i < n; ++i)
- delete maRepositories[i];
-}
-
-void TemplateRemoteView::Populate()
-{
- uno::Reference < uno::XComponentContext > m_context(comphelper::getProcessComponentContext());
-
- // Load from user settings
- com::sun::star::uno::Sequence<OUString> aUrls =
- officecfg::Office::Common::Misc::TemplateRepositoryUrls::get(m_context);
-
- com::sun::star::uno::Sequence<OUString> aNames =
- officecfg::Office::Common::Misc::TemplateRepositoryNames::get(m_context);
-
- for (sal_Int32 i = 0; i < aUrls.getLength() && i < aNames.getLength(); ++i)
- {
- TemplateRemoteViewItem *pItem = new TemplateRemoteViewItem(*this);
-
- pItem->mnId = i+1;
- pItem->maTitle = aNames[i];
- pItem->setURL(aUrls[i]);
-
- maRepositories.push_back(pItem);
- }
-}
-
-void TemplateRemoteView::reload ()
-{
- loadRepository(mpItemView->getId(),true);
}
void TemplateRemoteView::filterTemplatesByApp(const FILTER_APPLICATION &eApp)
@@ -109,19 +77,8 @@ void TemplateRemoteView::showOverlay (bool bVisible)
}
}
-bool TemplateRemoteView::loadRepository (const sal_uInt16 nRepositoryId, bool bRefresh)
+bool TemplateRemoteView::loadRepository (TemplateRemoteViewItem* pItem, bool bRefresh)
{
- TemplateRemoteViewItem *pItem = NULL;
-
- for (size_t i = 0, n = maRepositories.size(); i < n; ++i)
- {
- if (maRepositories[i]->mnId == nRepositoryId)
- {
- pItem = maRepositories[i];
- break;
- }
- }
-
if (!pItem)
return false;
@@ -132,7 +89,7 @@ bool TemplateRemoteView::loadRepository (const sal_uInt16 nRepositoryId, bool bR
}
mpItemView->Clear();
- mpItemView->setId(nRepositoryId);
+ mpItemView->setId(pItem->mnId);
mpItemView->setName(pItem->maTitle);
OUString aURL = static_cast<TemplateRemoteViewItem*>(pItem)->getURL();
@@ -156,7 +113,7 @@ bool TemplateRemoteView::loadRepository (const sal_uInt16 nRepositoryId, bool bR
uno::Reference< XResultSet > xResultSet;
uno::Reference< XDynamicResultSet > xDynResultSet;
- ucbhelper::ResultSetInclude eInclude = ucbhelper::INCLUDE_DOCUMENTS_ONLY;
+ ucbhelper::ResultSetInclude eInclude = ucbhelper::INCLUDE_FOLDERS_AND_DOCUMENTS;
xDynResultSet = aContent.createDynamicCursor( aProps, eInclude );
if ( xDynResultSet.is() )
@@ -243,67 +200,4 @@ bool TemplateRemoteView::loadRepository (const sal_uInt16 nRepositoryId, bool bR
return true;
}
-bool TemplateRemoteView::insertRepository(const OUString &rName, const OUString &rURL)
-{
- for (size_t i = 0, n = maRepositories.size(); i < n; ++i)
- {
- if (maRepositories[i]->maTitle == rName)
- return false;
- }
-
- TemplateRemoteViewItem *pItem = new TemplateRemoteViewItem(*this);
-
- pItem->mnId = maRepositories.size()+1;
- pItem->maTitle = rName;
- pItem->setURL(rURL);
-
- maRepositories.push_back(pItem);
-
- mbIsSynced = false;
- return true;
-}
-
-bool TemplateRemoteView::deleteRepository(const sal_uInt16 nRepositoryId)
-{
- bool bRet = false;
-
- for (size_t i = 0, n = maRepositories.size(); i < n; ++i)
- {
- if (maRepositories[i]->mnId == nRepositoryId)
- {
- delete maRepositories[i];
-
- maRepositories.erase(maRepositories.begin() + i);
- mbIsSynced = false;
- bRet = true;
- break;
- }
- }
-
- return bRet;
-}
-
-void TemplateRemoteView::syncRepositories() const
-{
- if (!mbIsSynced)
- {
- uno::Reference < uno::XComponentContext > pContext(comphelper::getProcessComponentContext());
- boost::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create(pContext));
-
- size_t nSize = maRepositories.size();
- uno::Sequence<OUString> aUrls(nSize);
- uno::Sequence<OUString> aNames(nSize);
-
- for(size_t i = 0; i < nSize; ++i)
- {
- aUrls[i] = maRepositories[i]->getURL();
- aNames[i] = maRepositories[i]->maTitle;
- }
-
- officecfg::Office::Common::Misc::TemplateRepositoryUrls::set(aUrls, batch, pContext);
- officecfg::Office::Common::Misc::TemplateRepositoryNames::set(aNames, batch, pContext);
- batch->commit();
- }
-}
-
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sfx2/source/control/templateremoteviewitem.cxx b/sfx2/source/control/templateremoteviewitem.cxx
deleted file mode 100644
index 626786f..0000000
--- a/sfx2/source/control/templateremoteviewitem.cxx
+++ /dev/null
@@ -1,21 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- */
-
-#include <sfx2/templateremoteviewitem.hxx>
-
-TemplateRemoteViewItem::TemplateRemoteViewItem (ThumbnailView &rView)
- : ThumbnailViewItem(rView)
-{
-}
-
-TemplateRemoteViewItem::~TemplateRemoteViewItem()
-{
-}
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sfx2/source/doc/templatedlg.cxx b/sfx2/source/doc/templatedlg.cxx
index 3546826..1e1ebd7ee6 100644
--- a/sfx2/source/doc/templatedlg.cxx
+++ b/sfx2/source/doc/templatedlg.cxx
@@ -15,6 +15,7 @@
#include <comphelper/processfactory.hxx>
#include <comphelper/storagehelper.hxx>
+#include <officecfg/Office/Common.hxx>
#include <sfx2/app.hxx>
#include <sfx2/docfac.hxx>
#include <sfx2/fcontnr.hxx>
@@ -106,7 +107,9 @@ SfxTemplateManagerDlg::SfxTemplateManagerDlg (Window *parent)
maView(new TemplateLocalView(this,SfxResId(TEMPLATE_VIEW))),
mpOnlineView(new TemplateRemoteView(this, WB_VSCROLL,false)),
mbIsSaveMode(false),
- mxDesktop(comphelper::getProcessServiceFactory()->createInstance( "com.sun.star.frame.Desktop" ),uno::UNO_QUERY )
+ mxDesktop(comphelper::getProcessServiceFactory()->createInstance( "com.sun.star.frame.Desktop" ),uno::UNO_QUERY ),
+ mbIsSynced(false),
+ maRepositories()
{
// Create popup menus
mpActionMenu = new PopupMenu;
@@ -179,7 +182,7 @@ SfxTemplateManagerDlg::SfxTemplateManagerDlg (Window *parent)
switchMainView(true);
- mpOnlineView->Populate();
+ loadRepositories();
createRepositoryMenu();
createDefaultTemplateMenu();
@@ -192,7 +195,10 @@ SfxTemplateManagerDlg::SfxTemplateManagerDlg (Window *parent)
SfxTemplateManagerDlg::~SfxTemplateManagerDlg ()
{
- mpOnlineView->syncRepositories();
+ // Synchronize the config before deleting it
+ syncRepositories();
+ for (size_t i = 0, n = maRepositories.size(); i < n; ++i)
+ delete maRepositories[i];
delete mpSearchEdit;
delete mpViewBar;
@@ -602,7 +608,7 @@ IMPL_LINK(SfxTemplateManagerDlg, RepositoryMenuSelectHdl, Menu*, pMenu)
{
boost::shared_ptr<Place> pPlace = dlg.GetPlace();
- if (mpOnlineView->insertRepository(pPlace->GetName(),pPlace->GetUrl()))
+ if (insertRepository(pPlace->GetName(),pPlace->GetUrl()))
{
// update repository list menu.
createRepositoryMenu();
@@ -619,7 +625,18 @@ IMPL_LINK(SfxTemplateManagerDlg, RepositoryMenuSelectHdl, Menu*, pMenu)
{
sal_uInt16 nRepoId = nMenuId - MNI_REPOSITORY_BASE;
- if (mpOnlineView->loadRepository(nRepoId,false))
+ TemplateRemoteViewItem *pRepository = NULL;
+
+ for (size_t i = 0, n = maRepositories.size(); i < n; ++i)
+ {
+ if (maRepositories[i]->mnId == nRepoId)
+ {
+ pRepository = maRepositories[i];
+ break;
+ }
+ }
+
+ if (mpOnlineView->loadRepository(pRepository,false))
{
switchMainView(false);
mpOnlineView->showOverlay(true);
@@ -1106,7 +1123,7 @@ void SfxTemplateManagerDlg::OnFolderDelete()
void SfxTemplateManagerDlg::OnRepositoryDelete()
{
- if(mpOnlineView->deleteRepository(mpOnlineView->getOverlayRegionId()))
+ if(deleteRepository(mpOnlineView->getOverlayRegionId()))
{
// close overlay and switch to local view
switchMainView(true);
@@ -1194,7 +1211,7 @@ void SfxTemplateManagerDlg::createRepositoryMenu()
mpRepositoryMenu->InsertItem(MNI_REPOSITORY_LOCAL,SfxResId(STR_REPOSITORY_LOCAL).toString());
- const std::vector<TemplateRemoteViewItem*> &rRepos = mpOnlineView->getRepositories();
+ const std::vector<TemplateRemoteViewItem*> &rRepos = getRepositories();
for (size_t i = 0, n = rRepos.size(); i < n; ++i)
mpRepositoryMenu->InsertItem(MNI_REPOSITORY_BASE+rRepos[i]->mnId,rRepos[i]->maTitle);
@@ -1419,6 +1436,92 @@ void SfxTemplateManagerDlg::localSearchMoveTo(sal_uInt16 nMenuId)
SearchUpdateHdl(mpSearchEdit);
}
+void SfxTemplateManagerDlg::loadRepositories()
+{
+ uno::Reference < uno::XComponentContext > m_context(comphelper::getProcessComponentContext());
+
+ // Load from user settings
+ com::sun::star::uno::Sequence<OUString> aUrls =
+ officecfg::Office::Common::Misc::TemplateRepositoryUrls::get(m_context);
+
+ com::sun::star::uno::Sequence<OUString> aNames =
+ officecfg::Office::Common::Misc::TemplateRepositoryNames::get(m_context);
+
+ for (sal_Int32 i = 0; i < aUrls.getLength() && i < aNames.getLength(); ++i)
+ {
+ TemplateRemoteViewItem *pItem = new TemplateRemoteViewItem();
+
+ pItem->mnId = i+1;
+ pItem->maTitle = aNames[i];
+ pItem->setURL(aUrls[i]);
+
+ maRepositories.push_back(pItem);
+ }
+}
+
+bool SfxTemplateManagerDlg::insertRepository(const OUString &rName, const OUString &rURL)
+{
+ for (size_t i = 0, n = maRepositories.size(); i < n; ++i)
+ {
+ if (maRepositories[i]->maTitle == rName)
+ return false;
+ }
+
+ TemplateRemoteViewItem *pItem = new TemplateRemoteViewItem();
+
+ pItem->mnId = maRepositories.size()+1;
+ pItem->maTitle = rName;
+ pItem->setURL(rURL);
+
+ maRepositories.push_back(pItem);
+
+ mbIsSynced = false;
+ return true;
+}
+
+bool SfxTemplateManagerDlg::deleteRepository(const sal_uInt16 nRepositoryId)
+{
+ bool bRet = false;
+
+ for (size_t i = 0, n = maRepositories.size(); i < n; ++i)
+ {
+ if (maRepositories[i]->mnId == nRepositoryId)
+ {
+ delete maRepositories[i];
+
+ maRepositories.erase(maRepositories.begin() + i);
+ mbIsSynced = false;
+ bRet = true;
+ break;
+ }
+ }
+
+ return bRet;
+}
+
+void SfxTemplateManagerDlg::syncRepositories() const
+{
+ if (!mbIsSynced)
+ {
+ uno::Reference < uno::XComponentContext > pContext(comphelper::getProcessComponentContext());
+ boost::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create(pContext));
+
+ size_t nSize = maRepositories.size();
+ uno::Sequence<OUString> aUrls(nSize);
+ uno::Sequence<OUString> aNames(nSize);
+
+ for(size_t i = 0; i < nSize; ++i)
+ {
+ aUrls[i] = maRepositories[i]->getURL();
+ aNames[i] = maRepositories[i]->maTitle;
+ }
+
+ officecfg::Office::Common::Misc::TemplateRepositoryUrls::set(aUrls, batch, pContext);
+ officecfg::Office::Common::Misc::TemplateRepositoryNames::set(aNames, batch, pContext);
+ batch->commit();
+ }
+}
+
static bool lcl_getServiceName ( const OUString &rFileURL, OUString &rName )
{
bool bRet = false;
commit 75353e716720f8c83b985b60545586f9a9e616c7
Author: Cédric Bosdonnat <cedric.bosdonnat at free.fr>
Date: Mon Dec 17 21:00:50 2012 +0100
File picker: add Path field for CMIS like other protocols
Change-Id: I9745831da13646d351858f221b1367374ebf737f
diff --git a/svtools/inc/svtools/ServerDetailsControls.hxx b/svtools/inc/svtools/ServerDetailsControls.hxx
index c6ab63f..1dfc051 100644
--- a/svtools/inc/svtools/ServerDetailsControls.hxx
+++ b/svtools/inc/svtools/ServerDetailsControls.hxx
@@ -143,6 +143,7 @@ class CmisDetailsContainer : public DetailsContainer
ListBox* m_pLBRepository;
Button* m_pBTRepoRefresh;
ListBox* m_pLBServerType;
+ Edit* m_pEDPath;
public:
CmisDetailsContainer( VclBuilderContainer* pBuilder );
diff --git a/svtools/source/dialogs/ServerDetailsControls.cxx b/svtools/source/dialogs/ServerDetailsControls.cxx
index 88f57e6..8b10c10 100644
--- a/svtools/source/dialogs/ServerDetailsControls.cxx
+++ b/svtools/source/dialogs/ServerDetailsControls.cxx
@@ -293,6 +293,9 @@ CmisDetailsContainer::CmisDetailsContainer( VclBuilderContainer* pBuilder ) :
pBuilder->get( m_pBTRepoRefresh, "repositoriesRefresh" );
m_pBTRepoRefresh->SetClickHdl( LINK( this, CmisDetailsContainer, RefreshReposHdl ) );
+ pBuilder->get( m_pEDPath, "cmisPath" );
+ m_pEDPath->SetModifyHdl( LINK( this, DetailsContainer, ValueChangeHdl ) );
+
show( false );
// Load the ServerType entries
@@ -308,6 +311,7 @@ CmisDetailsContainer::CmisDetailsContainer( VclBuilderContainer* pBuilder ) :
INetURLObject CmisDetailsContainer::getUrl( )
{
rtl::OUString sBindingUrl = rtl::OUString( m_pEDBinding->GetText() ).trim( );
+ rtl::OUString sPath = rtl::OUString( m_pEDPath->GetText() ).trim( );
rtl::OUString sUrl;
if ( !sBindingUrl.isEmpty( ) && !m_sRepoId.isEmpty() )
@@ -319,6 +323,7 @@ INetURLObject CmisDetailsContainer::getUrl( )
RTL_TEXTENCODING_UTF8 );
sUrl = "vnd.libreoffice.cmis://" + sEncodedBinding;
}
+ sUrl += sPath;
return INetURLObject( sUrl );
}
@@ -338,8 +343,8 @@ bool CmisDetailsContainer::setUrl( const INetURLObject& rUrl )
sRepositoryId = aHostUrl.GetMark( );
m_pEDBinding->SetText( sBindingUrl );
+ m_pEDPath->SetText( rUrl.GetURLPath() );
}
-
return bSuccess;
}
diff --git a/svtools/uiconfig/ui/placeedit.ui b/svtools/uiconfig/ui/placeedit.ui
index 285b023..36dd3fa 100644
--- a/svtools/uiconfig/ui/placeedit.ui
+++ b/svtools/uiconfig/ui/placeedit.ui
@@ -250,128 +250,102 @@
</packing>
</child>
<child>
- <object class="GtkFrame" id="CmisDetails">
+ <object class="GtkFrame" id="SmbDetails">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label_xalign">0</property>
<property name="shadow_type">none</property>
<child>
- <object class="GtkAlignment" id="alignment3">
+ <object class="GtkAlignment" id="alignment2">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="left_padding">12</property>
<child>
- <object class="GtkGrid" id="grid5">
+ <object class="GtkGrid" id="grid4">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="row_spacing">6</property>
<property name="column_spacing">6</property>
<child>
- <object class="GtkLabel" id="bindingLabel">
+ <object class="GtkLabel" id="label9">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="halign">start</property>
- <property name="label" translatable="yes">Binding URL</property>
+ <property name="label" translatable="yes">Host</property>
</object>
<packing>
<property name="left_attach">0</property>
- <property name="top_attach">1</property>
+ <property name="top_attach">0</property>
<property name="width">1</property>
<property name="height">1</property>
</packing>
</child>
<child>
- <object class="GtkLabel" id="repositoryLabel">
+ <object class="GtkLabel" id="label10">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="halign">start</property>
- <property name="label" translatable="yes">Repository</property>
+ <property name="label" translatable="yes">Share</property>
</object>
<packing>
<property name="left_attach">0</property>
- <property name="top_attach">2</property>
+ <property name="top_attach">1</property>
<property name="width">1</property>
<property name="height">1</property>
</packing>
</child>
<child>
- <object class="GtkEntry" id="binding">
+ <object class="GtkLabel" id="label11">
<property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="hexpand">True</property>
- <property name="invisible_char">â</property>
+ <property name="can_focus">False</property>
+ <property name="halign">start</property>
+ <property name="label" translatable="yes">Path</property>
</object>
<packing>
- <property name="left_attach">1</property>
- <property name="top_attach">1</property>
+ <property name="left_attach">0</property>
+ <property name="top_attach">2</property>
<property name="width">1</property>
<property name="height">1</property>
</packing>
</child>
<child>
- <object class="GtkGrid" id="grid6">
+ <object class="GtkEntry" id="smbHost">
<property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="column_spacing">6</property>
- <child>
- <object class="GtkComboBox" id="repositories">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="hexpand">True</property>
- </object>
- <packing>
- <property name="left_attach">0</property>
- <property name="top_attach">0</property>
- <property name="width">1</property>
- <property name="height">1</property>
- </packing>
- </child>
- <child>
- <object class="GtkButton" id="repositoriesRefresh">
- <property name="use_action_appearance">False</property>
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="receives_default">True</property>
- <property name="use_action_appearance">False</property>
- <property name="image">image1</property>
- </object>
- <packing>
- <property name="left_attach">1</property>
- <property name="top_attach">0</property>
- <property name="width">1</property>
- <property name="height">1</property>
- </packing>
- </child>
+ <property name="can_focus">True</property>
+ <property name="hexpand">True</property>
+ <property name="invisible_char">â</property>
</object>
<packing>
<property name="left_attach">1</property>
- <property name="top_attach">2</property>
+ <property name="top_attach">0</property>
<property name="width">1</property>
<property name="height">1</property>
</packing>
</child>
<child>
- <object class="GtkLabel" id="label3">
+ <object class="GtkEntry" id="smbShare">
<property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="halign">start</property>
- <property name="label" translatable="yes">Server Type</property>
+ <property name="can_focus">True</property>
+ <property name="hexpand">True</property>
+ <property name="invisible_char">â</property>
</object>
<packing>
- <property name="left_attach">0</property>
- <property name="top_attach">0</property>
+ <property name="left_attach">1</property>
+ <property name="top_attach">1</property>
<property name="width">1</property>
<property name="height">1</property>
</packing>
</child>
<child>
- <object class="GtkComboBox" id="serverType">
+ <object class="GtkEntry" id="smbPath">
<property name="visible">True</property>
- <property name="can_focus">False</property>
+ <property name="can_focus">True</property>
+ <property name="hexpand">True</property>
+ <property name="invisible_char">â</property>
</object>
<packing>
<property name="left_attach">1</property>
- <property name="top_attach">0</property>
+ <property name="top_attach">2</property>
<property name="width">1</property>
<property name="height">1</property>
</packing>
@@ -381,7 +355,7 @@
</object>
</child>
<child type="label">
- <object class="GtkLabel" id="label12">
+ <object class="GtkLabel" id="label8">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label" translatable="yes">Server Details</property>
@@ -398,70 +372,124 @@
</packing>
</child>
<child>
- <object class="GtkFrame" id="SmbDetails">
+ <object class="GtkFrame" id="CmisDetails">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label_xalign">0</property>
<property name="shadow_type">none</property>
<child>
- <object class="GtkAlignment" id="alignment2">
+ <object class="GtkAlignment" id="alignment3">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="left_padding">12</property>
<child>
- <object class="GtkGrid" id="grid4">
+ <object class="GtkGrid" id="grid5">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="row_spacing">6</property>
<property name="column_spacing">6</property>
<child>
- <object class="GtkLabel" id="label9">
+ <object class="GtkLabel" id="bindingLabel">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="halign">start</property>
- <property name="label" translatable="yes">Host</property>
+ <property name="label" translatable="yes">Binding URL</property>
</object>
<packing>
<property name="left_attach">0</property>
- <property name="top_attach">0</property>
+ <property name="top_attach">1</property>
<property name="width">1</property>
<property name="height">1</property>
</packing>
</child>
<child>
- <object class="GtkLabel" id="label10">
+ <object class="GtkLabel" id="repositoryLabel">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="halign">start</property>
- <property name="label" translatable="yes">Share</property>
+ <property name="label" translatable="yes">Repository</property>
</object>
<packing>
<property name="left_attach">0</property>
+ <property name="top_attach">2</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="binding">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="hexpand">True</property>
+ <property name="invisible_char">â</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
<property name="top_attach">1</property>
<property name="width">1</property>
<property name="height">1</property>
</packing>
</child>
<child>
- <object class="GtkLabel" id="label11">
+ <object class="GtkGrid" id="grid6">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="column_spacing">6</property>
+ <child>
+ <object class="GtkComboBox" id="repositories">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="hexpand">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="repositoriesRefresh">
+ <property name="use_action_appearance">False</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_action_appearance">False</property>
+ <property name="image">image1</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">0</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">2</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label3">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="halign">start</property>
- <property name="label" translatable="yes">Path</property>
+ <property name="label" translatable="yes">Server Type</property>
</object>
<packing>
<property name="left_attach">0</property>
- <property name="top_attach">2</property>
+ <property name="top_attach">0</property>
<property name="width">1</property>
<property name="height">1</property>
</packing>
</child>
<child>
- <object class="GtkEntry" id="smbHost">
+ <object class="GtkComboBox" id="serverType">
<property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="hexpand">True</property>
- <property name="invisible_char">â</property>
+ <property name="can_focus">False</property>
</object>
<packing>
<property name="left_attach">1</property>
@@ -471,29 +499,29 @@
</packing>
</child>
<child>
- <object class="GtkEntry" id="smbShare">
+ <object class="GtkLabel" id="label5">
<property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="hexpand">True</property>
- <property name="invisible_char">â</property>
+ <property name="can_focus">False</property>
+ <property name="halign">start</property>
+ <property name="yalign">0.49000000953674316</property>
+ <property name="label" translatable="yes">Path</property>
</object>
<packing>
- <property name="left_attach">1</property>
- <property name="top_attach">1</property>
+ <property name="left_attach">0</property>
+ <property name="top_attach">3</property>
<property name="width">1</property>
<property name="height">1</property>
</packing>
</child>
<child>
- <object class="GtkEntry" id="smbPath">
+ <object class="GtkEntry" id="cmisPath">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="hexpand">True</property>
<property name="invisible_char">â</property>
</object>
<packing>
<property name="left_attach">1</property>
- <property name="top_attach">2</property>
+ <property name="top_attach">3</property>
<property name="width">1</property>
<property name="height">1</property>
</packing>
@@ -503,7 +531,7 @@
</object>
</child>
<child type="label">
- <object class="GtkLabel" id="label8">
+ <object class="GtkLabel" id="label12">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label" translatable="yes">Server Details</property>
More information about the Libreoffice-commits
mailing list