[Libreoffice-commits] .: 2 commits - sfx2/source svtools/inc svtools/source svtools/uiconfig svtools/UI_svt.mk

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Tue Nov 13 03:57:51 PST 2012


 sfx2/source/doc/objserv.cxx                      |    4 
 svtools/UI_svt.mk                                |    1 
 svtools/inc/svtools/PlaceEditDialog.hxx          |   40 -
 svtools/inc/svtools/ServerDetailsControls.hxx    |   40 -
 svtools/source/dialogs/PlaceEditDialog.cxx       |  219 +------
 svtools/source/dialogs/ServerDetailsControls.cxx |  178 ++----
 svtools/uiconfig/ui/placeedit.ui                 |  660 +++++++++++++++++++++++
 7 files changed, 825 insertions(+), 317 deletions(-)

New commits:
commit 2fa60c6dacd160f0365565cba9baf373c2873582
Author: Cédric Bosdonnat <cedric.bosdonnat at free.fr>
Date:   Tue Nov 13 11:14:24 2012 +0100

    fpicker: moved the PlaceEditDialog to .ui file
    
    This is a preliminary step to CMIS server selection simplification.
    
    Change-Id: I74f333a9f233bbaabb4d6b6ba48fb8e86df2f508

diff --git a/svtools/UI_svt.mk b/svtools/UI_svt.mk
index 7a8cf96..250bd5f 100644
--- a/svtools/UI_svt.mk
+++ b/svtools/UI_svt.mk
@@ -11,6 +11,7 @@ $(eval $(call gb_UI_UI,svt))
 
 $(eval $(call gb_UI_add_uifiles,svt,\
 	svtools/uiconfig/ui/graphicexport \
+	svtools/uiconfig/ui/placeedit \
 ))
 
 # vim: set noet sw=4 ts=4:
diff --git a/svtools/inc/svtools/PlaceEditDialog.hxx b/svtools/inc/svtools/PlaceEditDialog.hxx
index 14a1fb0..4db4316 100644
--- a/svtools/inc/svtools/PlaceEditDialog.hxx
+++ b/svtools/inc/svtools/PlaceEditDialog.hxx
@@ -46,39 +46,15 @@ class SVT_DLLPUBLIC PlaceEditDialog : public ModalDialog
 {
 private :
 
-    FixedText m_aFTServerName;
-    FixedText m_aFTServerType;
-
-    Edit m_aEDServerName;
-    ListBox m_aLBServerType;
+    Edit*      m_pEDServerName;
+    ListBox*   m_pLBServerType;
     boost::shared_ptr< DetailsContainer > m_pCurrentDetails;
 
-    FixedText    m_aFTHost;
-    Edit         m_aEDHost;
-    FixedText    m_aFTPort;
-    NumericField m_aEDPort;
-    FixedText    m_aFTPath;
-    Edit         m_aEDPath;
-    CheckBox     m_aCBDavs;
-
-    Edit         m_aEDSmbHost;
-    FixedText    m_aFTShare;
-    Edit         m_aEDShare;
-    FixedText    m_aFTSmbPath;
-    Edit         m_aEDSmbPath;
-
-    FixedText    m_aFTCmisBinding;
-    Edit         m_aEDCmisBinding;
-    FixedText    m_aFTCmisRepository;
-    ListBox      m_aLBCmisRepository;
-    ImageButton  m_aBTCmisRepoRefresh;
-
-    FixedText    m_aFTUsername;
-    Edit         m_aEDUsername;
-    OKButton m_aBTOk;
-    CancelButton m_aBTCancel;
-
-    PushButton m_aBTDelete;
+    Edit*         m_pEDUsername;
+    OKButton*     m_pBTOk;
+    CancelButton* m_pBTCancel;
+
+    PushButton*   m_pBTDelete;
 
     /** Vector holding the details UI control for each server type.
 
@@ -97,7 +73,7 @@ public :
      // Returns a place instance with given informations
      boost::shared_ptr<Place> GetPlace();
 
-     rtl::OUString GetServerName() 	{ return m_aEDServerName.GetText(); }
+    rtl::OUString GetServerName() { return m_pEDServerName->GetText(); }
      rtl::OUString GetServerUrl();
 
 private:
diff --git a/svtools/inc/svtools/ServerDetailsControls.hxx b/svtools/inc/svtools/ServerDetailsControls.hxx
index 7d0c9ad..f29ec44 100644
--- a/svtools/inc/svtools/ServerDetailsControls.hxx
+++ b/svtools/inc/svtools/ServerDetailsControls.hxx
@@ -33,26 +33,23 @@
 #include <com/sun/star/ucb/XCommandEnvironment.hpp>
 
 #include <tools/urlobj.hxx>
+#include <vcl/builder.hxx>
 #include <vcl/button.hxx>
 #include <vcl/edit.hxx>
 #include <vcl/field.hxx>
 #include <vcl/fixed.hxx>
+#include <vcl/layout.hxx>
 
 class DetailsContainer
 {
     private:
-        std::map< sal_uInt16, Control* > m_aControls;
-        bool m_bShown;
         Link m_aChangeHdl;
+        VclFrame*       m_pFrame;
 
     public:
-        DetailsContainer( );
+        DetailsContainer( VclBuilderContainer* pBuilder, const rtl::OString& rFrame );
         virtual ~DetailsContainer( );
 
-        virtual void addControl( sal_uInt16 nId, Control* pControl );
-        Control* getControl( sal_uInt16 nId );
-        Rectangle getBounds( );
-
         void setChangeHdl( const Link& rLink ) { m_aChangeHdl = rLink; }
 
         virtual void show( bool bShow = true );
@@ -69,8 +66,6 @@ class DetailsContainer
 
     protected:
         void notifyChange( );
-
-    private:
         DECL_LINK ( ValueChangeHdl, void * );
 };
 
@@ -80,8 +75,13 @@ class HostDetailsContainer : public DetailsContainer
         sal_uInt16 m_nDefaultPort;
         rtl::OUString m_sScheme;
 
+    protected:
+        Edit*           m_pEDHost;
+        NumericField*   m_pEDPort;
+        Edit*           m_pEDPath;
+
     public:
-        HostDetailsContainer( sal_uInt16 nPort, rtl::OUString sScheme );
+        HostDetailsContainer( VclBuilderContainer* pBuilder, sal_uInt16 nPort, rtl::OUString sScheme );
         virtual ~HostDetailsContainer( ) { };
 
         virtual void show( bool bShow = true );
@@ -99,11 +99,13 @@ class HostDetailsContainer : public DetailsContainer
 
 class DavDetailsContainer : public HostDetailsContainer
 {
+    private:
+        CheckBox*   m_pCBDavs;
+
     public:
-        DavDetailsContainer( );
+        DavDetailsContainer( VclBuilderContainer* pBuilder );
         ~DavDetailsContainer( ) { };
 
-        virtual void addControl( sal_uInt16 nId, Control* pControl );
         virtual void show( bool bShow = true );
 
     protected:
@@ -115,8 +117,13 @@ class DavDetailsContainer : public HostDetailsContainer
 
 class SmbDetailsContainer : public DetailsContainer
 {
+    private:
+        Edit*           m_pEDHost;
+        Edit*           m_pEDShare;
+        Edit*           m_pEDPath;
+
     public:
-        SmbDetailsContainer( ) : DetailsContainer( ) { };
+        SmbDetailsContainer( VclBuilderContainer* pBuilder );
         ~SmbDetailsContainer( ) { };
 
         virtual INetURLObject getUrl( );
@@ -131,14 +138,17 @@ class CmisDetailsContainer : public DetailsContainer
         std::vector< rtl::OUString > m_aRepoIds;
         rtl::OUString m_sRepoId;
 
+        Edit*       m_pEDBinding;
+        ListBox*    m_pLBRepository;
+        Button*     m_pBTRepoRefresh;
+
     public:
-        CmisDetailsContainer( );
+        CmisDetailsContainer( VclBuilderContainer* pBuilder );
         ~CmisDetailsContainer( ) { };
 
         virtual INetURLObject getUrl( );
         virtual bool setUrl( const INetURLObject& rUrl );
         virtual void setUsername( const rtl::OUString& rUsername );
-        virtual void addControl( sal_uInt16 nId, Control* pControl );
 
     private:
         void selectRepository( );
diff --git a/svtools/source/dialogs/PlaceEditDialog.cxx b/svtools/source/dialogs/PlaceEditDialog.cxx
index 9807050..2074bd5 100644
--- a/svtools/source/dialogs/PlaceEditDialog.cxx
+++ b/svtools/source/dialogs/PlaceEditDialog.cxx
@@ -36,90 +36,52 @@
 
 using namespace boost;
 
-PlaceEditDialog::PlaceEditDialog(	Window* pParent ) :
-    ModalDialog( pParent, SvtResId( DLG_FPICKER_PLACE_EDIT ) ),
-    m_aFTServerName( this, SvtResId( FT_ADDPLACE_SERVERNAME ) ),
-    m_aFTServerType( this, SvtResId( FT_ADDPLACE_SERVERTYPE ) ),
-    m_aEDServerName ( this, SvtResId( ED_ADDPLACE_SERVERNAME ) ),
-    m_aLBServerType ( this, SvtResId( LB_ADDPLACE_SERVERTYPE ) ),
-    m_pCurrentDetails( ),
-    m_aFTHost( this, SvtResId( FT_ADDPLACE_HOST ) ),
-    m_aEDHost( this, SvtResId( ED_ADDPLACE_HOST ) ),
-    m_aFTPort( this, SvtResId( FT_ADDPLACE_PORT ) ),
-    m_aEDPort( this, SvtResId( ED_ADDPLACE_PORT ) ),
-    m_aFTPath( this, SvtResId( FT_ADDPLACE_PATH ) ),
-    m_aEDPath( this, SvtResId( ED_ADDPLACE_PATH ) ),
-    m_aCBDavs( this, SvtResId( CB_ADDPLACE_DAVS ) ),
-    m_aEDSmbHost( this, SvtResId( ED_ADDPLACE_SMBHOST ) ),
-    m_aFTShare( this, SvtResId( FT_ADDPLACE_SHARE ) ),
-    m_aEDShare( this, SvtResId( ED_ADDPLACE_SHARE ) ),
-    m_aFTSmbPath( this, SvtResId( FT_ADDPLACE_SMBPATH ) ),
-    m_aEDSmbPath( this, SvtResId( ED_ADDPLACE_SMBPATH ) ),
-    m_aFTCmisBinding( this, SvtResId( FT_ADDPLACE_CMIS_BINDING ) ),
-    m_aEDCmisBinding( this, SvtResId( ED_ADDPLACE_CMIS_BINDING ) ),
-    m_aFTCmisRepository( this, SvtResId( FT_ADDPLACE_CMIS_REPOSITORY ) ),
-    m_aLBCmisRepository( this, SvtResId( LB_ADDPLACE_CMIS_REPOSITORY ) ),
-    m_aBTCmisRepoRefresh( this, SvtResId( BT_ADDPLACE_CMIS_REPOREFRESH ) ),
-    m_aFTUsername( this, SvtResId( FT_ADDPLACE_USERNAME ) ),
-    m_aEDUsername( this, SvtResId( ED_ADDPLACE_USERNAME ) ),
-    m_aBTOk( this, SvtResId( BT_ADDPLACE_OK ) ),
-    m_aBTCancel ( this, SvtResId ( BT_ADDPLACE_CANCEL ) ),
-    m_aBTDelete ( this, SvtResId (BT_ADDPLACE_DELETE ) )
+PlaceEditDialog::PlaceEditDialog( Window* pParent ) :
+    ModalDialog( pParent, "PlaceEditDialog", "svt/ui/placeedit.ui" ),
+    m_pCurrentDetails( )
 {
-    m_aBTOk.SetClickHdl( LINK( this, PlaceEditDialog, OKHdl) );
-    m_aBTOk.Enable( sal_False );
+    get( m_pEDServerName, "name" );
+    get( m_pLBServerType, "type" );
+    get( m_pEDUsername, "login" );
+    get( m_pBTOk, "ok" );
+    get( m_pBTCancel, "cancel" );
+    get( m_pBTDelete, "delete" );
 
-    m_aEDServerName.SetModifyHdl( LINK( this, PlaceEditDialog, EditHdl) );
+    m_pBTOk->SetClickHdl( LINK( this, PlaceEditDialog, OKHdl) );
+    m_pBTOk->Enable( sal_False );
+
+    m_pEDServerName->SetModifyHdl( LINK( this, PlaceEditDialog, EditHdl) );
 
     // This constructor is called when user request a place creation, so
     // delete button is hidden.
-    m_aBTDelete.Hide();
+    m_pBTDelete->Hide();
 
-    m_aLBServerType.SetSelectHdl( LINK( this, PlaceEditDialog, SelectTypeHdl ) );
-    m_aEDUsername.SetModifyHdl( LINK( this, PlaceEditDialog, EditUsernameHdl ) );
+    m_pLBServerType->SetSelectHdl( LINK( this, PlaceEditDialog, SelectTypeHdl ) );
+    m_pEDUsername->SetModifyHdl( LINK( this, PlaceEditDialog, EditUsernameHdl ) );
 
     InitDetails( );
 }
 
 PlaceEditDialog::PlaceEditDialog( Window* pParent, const boost::shared_ptr<Place>& pPlace ) :
-    ModalDialog( pParent, SvtResId( DLG_FPICKER_PLACE_EDIT ) ),
-    m_aFTServerName( this, SvtResId( FT_ADDPLACE_SERVERNAME ) ),
-    m_aFTServerType( this, SvtResId( FT_ADDPLACE_SERVERTYPE ) ),
-    m_aEDServerName ( this, SvtResId( ED_ADDPLACE_SERVERNAME ) ),
-    m_aLBServerType ( this, SvtResId( LB_ADDPLACE_SERVERTYPE ) ),
-    m_pCurrentDetails( ),
-    m_aFTHost( this, SvtResId( FT_ADDPLACE_HOST ) ),
-    m_aEDHost( this, SvtResId( ED_ADDPLACE_HOST ) ),
-    m_aFTPort( this, SvtResId( FT_ADDPLACE_PORT ) ),
-    m_aEDPort( this, SvtResId( ED_ADDPLACE_PORT ) ),
-    m_aFTPath( this, SvtResId( FT_ADDPLACE_PATH ) ),
-    m_aEDPath( this, SvtResId( ED_ADDPLACE_PATH ) ),
-    m_aCBDavs( this, SvtResId( CB_ADDPLACE_DAVS ) ),
-    m_aEDSmbHost( this, SvtResId( ED_ADDPLACE_SMBHOST ) ),
-    m_aFTShare( this, SvtResId( FT_ADDPLACE_SHARE ) ),
-    m_aEDShare( this, SvtResId( ED_ADDPLACE_SHARE ) ),
-    m_aFTSmbPath( this, SvtResId( FT_ADDPLACE_SMBPATH ) ),
-    m_aEDSmbPath( this, SvtResId( ED_ADDPLACE_SMBPATH ) ),
-    m_aFTCmisBinding( this, SvtResId( FT_ADDPLACE_CMIS_BINDING ) ),
-    m_aEDCmisBinding( this, SvtResId( ED_ADDPLACE_CMIS_BINDING ) ),
-    m_aFTCmisRepository( this, SvtResId( FT_ADDPLACE_CMIS_REPOSITORY ) ),
-    m_aLBCmisRepository( this, SvtResId( LB_ADDPLACE_CMIS_REPOSITORY ) ),
-    m_aBTCmisRepoRefresh( this, SvtResId( BT_ADDPLACE_CMIS_REPOREFRESH ) ),
-    m_aFTUsername( this, SvtResId( FT_ADDPLACE_USERNAME ) ),
-    m_aEDUsername( this, SvtResId( ED_ADDPLACE_USERNAME ) ),
-    m_aBTOk( this, SvtResId( BT_ADDPLACE_OK ) ),
-    m_aBTCancel ( this, SvtResId ( BT_ADDPLACE_CANCEL ) ),
-    m_aBTDelete ( this, SvtResId (BT_ADDPLACE_DELETE ) )
+    ModalDialog( pParent, "PlaceEditDialog", "svt/ui/placeedit.ui" ),
+    m_pCurrentDetails( )
 {
-    m_aBTOk.SetClickHdl( LINK( this, PlaceEditDialog, OKHdl) );
-    m_aBTDelete.SetClickHdl ( LINK( this, PlaceEditDialog, DelHdl) );
+    get( m_pEDServerName, "name" );
+    get( m_pLBServerType, "type" );
+    get( m_pEDUsername, "login" );
+    get( m_pBTOk, "ok" );
+    get( m_pBTCancel, "cancel" );
+    get( m_pBTDelete, "delete" );
+
+    m_pBTOk->SetClickHdl( LINK( this, PlaceEditDialog, OKHdl) );
+    m_pBTDelete->SetClickHdl ( LINK( this, PlaceEditDialog, DelHdl) );
 
-    m_aEDServerName.SetModifyHdl( LINK( this, PlaceEditDialog, EditHdl) );
-    m_aLBServerType.SetSelectHdl( LINK( this, PlaceEditDialog, SelectTypeHdl ) );
+    m_pEDServerName->SetModifyHdl( LINK( this, PlaceEditDialog, EditHdl) );
+    m_pLBServerType->SetSelectHdl( LINK( this, PlaceEditDialog, SelectTypeHdl ) );
 
     InitDetails( );
 
-    m_aEDServerName.SetText( pPlace->GetName() );
+    m_pEDServerName->SetText( pPlace->GetName() );
 
     // Fill the boxes with the URL parts
     bool bSuccess = false;
@@ -129,12 +91,12 @@ PlaceEditDialog::PlaceEditDialog( Window* pParent, const boost::shared_ptr<Place
         bSuccess = m_aDetailsContainers[i]->setUrl( rUrl );
         if ( bSuccess )
         {
-            m_aLBServerType.SelectEntryPos( i );
-            SelectTypeHdl( &m_aLBServerType );
+            m_pLBServerType->SelectEntryPos( i );
+            SelectTypeHdl( m_pLBServerType );
 
             // Fill the Username field
             if ( rUrl.HasUserData( ) )
-                m_aEDUsername.SetText( rUrl.GetUser( ) );
+                m_pEDUsername->SetText( rUrl.GetUser( ) );
         }
     }
 }
@@ -149,7 +111,7 @@ rtl::OUString PlaceEditDialog::GetServerUrl()
     if ( m_pCurrentDetails.get( ) )
     {
         INetURLObject aUrl = m_pCurrentDetails->getUrl();
-        rtl::OUString sUsername = rtl::OUString( m_aEDUsername.GetText( ) ).trim( );
+        rtl::OUString sUsername = rtl::OUString( m_pEDUsername->GetText( ) ).trim( );
         if ( !sUsername.isEmpty( ) )
             aUrl.SetUser( sUsername );
         if ( !aUrl.HasError( ) )
@@ -161,75 +123,38 @@ rtl::OUString PlaceEditDialog::GetServerUrl()
 
 boost::shared_ptr<Place> PlaceEditDialog::GetPlace()
 {
-    boost::shared_ptr<Place> newPlace( new Place( m_aEDServerName.GetText(), GetServerUrl(), true ) );
+    boost::shared_ptr<Place> newPlace( new Place( m_pEDServerName->GetText(), GetServerUrl(), true ) );
     return newPlace;
 }
 
 void PlaceEditDialog::InitDetails( )
 {
     // Create WebDAV / FTP / SSH details control
-    shared_ptr< DetailsContainer > pDavDetails( new DavDetailsContainer( ) );
-    pDavDetails->addControl( FT_ADDPLACE_HOST, &m_aFTHost );
-    pDavDetails->addControl( ED_ADDPLACE_HOST, &m_aEDHost );
-    pDavDetails->addControl( FT_ADDPLACE_PORT, &m_aFTPort );
-    pDavDetails->addControl( ED_ADDPLACE_PORT, &m_aEDPort );
-    pDavDetails->addControl( FT_ADDPLACE_PATH, &m_aFTPath );
-    pDavDetails->addControl( ED_ADDPLACE_PATH, &m_aEDPath );
-    pDavDetails->addControl( CB_ADDPLACE_DAVS, &m_aCBDavs );
+    shared_ptr< DetailsContainer > pDavDetails( new DavDetailsContainer( this ) );
     pDavDetails->setChangeHdl( LINK( this, PlaceEditDialog, EditHdl ) );
     m_aDetailsContainers.push_back( pDavDetails );
 
-    shared_ptr< DetailsContainer > pFtpDetails( new HostDetailsContainer( 21, "ftp" ) );
-    pFtpDetails->addControl( FT_ADDPLACE_HOST, &m_aFTHost );
-    pFtpDetails->addControl( ED_ADDPLACE_HOST, &m_aEDHost );
-    pFtpDetails->addControl( FT_ADDPLACE_PORT, &m_aFTPort );
-    pFtpDetails->addControl( ED_ADDPLACE_PORT, &m_aEDPort );
-    pFtpDetails->addControl( FT_ADDPLACE_PATH, &m_aFTPath );
-    pFtpDetails->addControl( ED_ADDPLACE_PATH, &m_aEDPath );
+    shared_ptr< DetailsContainer > pFtpDetails( new HostDetailsContainer( this, 21, "ftp" ) );
     pFtpDetails->setChangeHdl( LINK( this, PlaceEditDialog, EditHdl ) );
     m_aDetailsContainers.push_back( pFtpDetails );
 
-    shared_ptr< DetailsContainer > pSshDetails( new HostDetailsContainer( 22, "ssh" ) );
-    pSshDetails->addControl( FT_ADDPLACE_HOST, &m_aFTHost );
-    pSshDetails->addControl( ED_ADDPLACE_HOST, &m_aEDHost );
-    pSshDetails->addControl( FT_ADDPLACE_PORT, &m_aFTPort );
-    pSshDetails->addControl( ED_ADDPLACE_PORT, &m_aEDPort );
-    pSshDetails->addControl( FT_ADDPLACE_PATH, &m_aFTPath );
-    pSshDetails->addControl( ED_ADDPLACE_PATH, &m_aEDPath );
+    shared_ptr< DetailsContainer > pSshDetails( new HostDetailsContainer( this, 22, "ssh" ) );
     pSshDetails->setChangeHdl( LINK( this, PlaceEditDialog, EditHdl ) );
     m_aDetailsContainers.push_back( pSshDetails );
 
     // Create Windows Share control
-    shared_ptr< DetailsContainer > pSmbDetails( new SmbDetailsContainer( ) );
-    pSmbDetails->addControl( FT_ADDPLACE_HOST, &m_aFTHost );
-    pSmbDetails->addControl( ED_ADDPLACE_SMBHOST, &m_aEDSmbHost );
-    pSmbDetails->addControl( FT_ADDPLACE_SHARE, &m_aFTShare );
-    pSmbDetails->addControl( ED_ADDPLACE_SHARE, &m_aEDShare );
-    pSmbDetails->addControl( FT_ADDPLACE_SMBPATH, &m_aFTSmbPath );
-    pSmbDetails->addControl( ED_ADDPLACE_SMBPATH, &m_aEDSmbPath );
+    shared_ptr< DetailsContainer > pSmbDetails( new SmbDetailsContainer( this ) );
     pSmbDetails->setChangeHdl( LINK( this, PlaceEditDialog, EditHdl ) );
     m_aDetailsContainers.push_back( pSmbDetails );
 
     // Create CMIS control
-    shared_ptr< DetailsContainer > pCmisDetails( new CmisDetailsContainer( ) );
-    pCmisDetails->addControl( FT_ADDPLACE_CMIS_BINDING, &m_aFTCmisBinding );
-    pCmisDetails->addControl( ED_ADDPLACE_CMIS_BINDING, &m_aEDCmisBinding );
-    pCmisDetails->addControl( FT_ADDPLACE_CMIS_REPOSITORY, &m_aFTCmisRepository );
-    pCmisDetails->addControl( LB_ADDPLACE_CMIS_REPOSITORY, &m_aLBCmisRepository );
-    pCmisDetails->addControl( BT_ADDPLACE_CMIS_REPOREFRESH, &m_aBTCmisRepoRefresh );
+    shared_ptr< DetailsContainer > pCmisDetails( new CmisDetailsContainer( this ) );
     pCmisDetails->setChangeHdl( LINK( this, PlaceEditDialog, EditHdl ) );
-
-    if ( officecfg::Office::Common::Misc::ExperimentalMode::get() )
-        m_aDetailsContainers.push_back( pCmisDetails );
-    else
-    {
-        // Remove the CMIS entry, left it in src file for l10n
-        m_aLBServerType.RemoveEntry( m_aLBServerType.GetEntryCount( ) - 1 );
-    }
+    m_aDetailsContainers.push_back( pCmisDetails );
 
     // Set default to first value
-    m_aLBServerType.SelectEntryPos( 0 );
-    SelectTypeHdl( &m_aLBServerType );
+    m_pLBServerType->SelectEntryPos( 0 );
+    SelectTypeHdl( m_pLBServerType );
 }
 
 IMPL_LINK ( PlaceEditDialog,  OKHdl, Button *, EMPTYARG )
@@ -248,8 +173,8 @@ IMPL_LINK ( PlaceEditDialog, DelHdl, Button *, EMPTYARG )
 IMPL_LINK ( PlaceEditDialog, EditHdl, void *, EMPTYARG )
 {
     rtl::OUString sUrl = GetServerUrl( );
-    rtl::OUString sName = rtl::OUString( m_aEDServerName.GetText() ).trim( );
-    m_aBTOk.Enable( !sName.isEmpty( ) && !sUrl.isEmpty( ) );
+    rtl::OUString sName = rtl::OUString( m_pEDServerName->GetText() ).trim( );
+    m_pBTOk->Enable( !sName.isEmpty( ) && !sUrl.isEmpty( ) );
     return 1;
 }
 
@@ -258,70 +183,22 @@ IMPL_LINK ( PlaceEditDialog, EditUsernameHdl, void *, EMPTYARG )
     for ( std::vector< boost::shared_ptr< DetailsContainer > >::iterator it = m_aDetailsContainers.begin( );
             it != m_aDetailsContainers.end( ); ++it )
     {
-        ( *it )->setUsername( rtl::OUString( m_aEDUsername.GetText() ) );
+        ( *it )->setUsername( rtl::OUString( m_pEDUsername->GetText() ) );
     }
     return 1;
 }
 
 IMPL_LINK( PlaceEditDialog, SelectTypeHdl, void*, EMPTYARG )
 {
-    // Compute the vertical space between two rows
-    long nRowDelta = m_aLBServerType.GetPosPixel().getY() - m_aEDServerName.GetPosPixel().getY();
-    long nRowSpace = nRowDelta - m_aEDServerName.GetSizePixel().getHeight();
-
-    long nOldHeight = 0;
     if ( m_pCurrentDetails.get( ) )
-    {
         m_pCurrentDetails->show( false );
-        Rectangle aOldBounds = m_pCurrentDetails->getBounds( );
-        if ( !aOldBounds.IsEmpty() )
-            nOldHeight = aOldBounds.getHeight();
-    }
 
-    sal_uInt16 nPos = m_aLBServerType.GetSelectEntryPos( );
+    sal_uInt16 nPos = m_pLBServerType->GetSelectEntryPos( );
     m_pCurrentDetails = m_aDetailsContainers[nPos];
 
     m_pCurrentDetails->show( true );
-    Rectangle aNewBounds = m_pCurrentDetails->getBounds();
-
-    long nNewHeight = 0;
-    if ( !aNewBounds.IsEmpty() )
-    {
-        nNewHeight = aNewBounds.getHeight();
-
-        // Add row space if old height was 0
-        if ( nOldHeight == 0 )
-            nNewHeight += nRowSpace;
-    }
-
-    // If the new height is 0, but not the old one, then remove the doubled row space
-    if ( nNewHeight == 0 && nOldHeight > 0 )
-        nNewHeight -= nRowSpace;
-
-    long nHeightDelta = nNewHeight - nOldHeight;
-    Control* pToMove[] =
-    {
-        &m_aFTUsername,
-        &m_aEDUsername,
-        &m_aBTOk,
-        &m_aBTCancel,
-        &m_aBTDelete
-    };
-
-    Control** pCurrent = pToMove;
-    for ( sal_Int32 i = 0; i < sal_Int32(SAL_N_ELEMENTS( pToMove )); ++i, ++pCurrent )
-    {
-        Point aPos = ( *pCurrent )->GetPosPixel( );
-        aPos.setY( aPos.getY( ) + nHeightDelta );
-        ( *pCurrent )->SetPosPixel( aPos );
-    }
-
-    // Resize the dialog too
-    Size aDlgSize = GetSizePixel( );
-    aDlgSize.setHeight( aDlgSize.getHeight( ) + nHeightDelta );
-    SetSizePixel( aDlgSize );
-
 
+    SetSizePixel( GetOptimalSize( WINDOWSIZE_MINIMUM ) );
     return 0;
 }
 
diff --git a/svtools/source/dialogs/ServerDetailsControls.cxx b/svtools/source/dialogs/ServerDetailsControls.cxx
index a41e42c..056f7f9 100644
--- a/svtools/source/dialogs/ServerDetailsControls.cxx
+++ b/svtools/source/dialogs/ServerDetailsControls.cxx
@@ -50,58 +50,18 @@ using namespace com::sun::star::task;
 using namespace com::sun::star::ucb;
 using namespace com::sun::star::uno;
 
-DetailsContainer::DetailsContainer( ) :
-    m_aControls( ),
-    m_bShown( false )
+DetailsContainer::DetailsContainer( VclBuilderContainer* pBuilder, const rtl::OString& rFrame )
 {
+    pBuilder->get( m_pFrame, rFrame );
 }
 
 DetailsContainer::~DetailsContainer( )
 {
-    m_aControls.clear( );
-}
-
-void DetailsContainer::addControl( sal_uInt16 nId, Control* pControl )
-{
-    m_aControls.insert( pair< sal_uInt16, Control* >( nId, pControl ) );
-    pControl->Show( m_bShown );
-
-    if ( pControl->GetType( ) == WINDOW_EDIT )
-        static_cast< Edit* >( pControl )->SetModifyHdl( LINK( this, DetailsContainer, ValueChangeHdl ) );
-    else if ( pControl->GetType( ) == WINDOW_NUMERICFIELD )
-        static_cast< NumericField* >( pControl )->SetModifyHdl( LINK( this, DetailsContainer, ValueChangeHdl ) );
-    else if ( pControl->GetType( ) == WINDOW_CHECKBOX )
-        static_cast< CheckBox* >( pControl )->SetToggleHdl( LINK( this, DetailsContainer, ValueChangeHdl ) );
-}
-
-Control* DetailsContainer::getControl( sal_uInt16 nId )
-{
-    Control* pControl = NULL;
-    map< sal_uInt16, Control* >::iterator it = m_aControls.find( nId );
-    if ( it != m_aControls.end( ) )
-        pControl = it->second;
-    return pControl;
-}
-
-Rectangle DetailsContainer::getBounds( )
-{
-    Rectangle aBounds;
-    for ( map< sal_uInt16, Control* >::iterator it = m_aControls.begin( ); it != m_aControls.end( ); ++it )
-    {
-        Rectangle aControlBounds( it->second->GetPosPixel(), it->second->GetSizePixel() );
-        aBounds = aBounds.GetUnion( aControlBounds );
-    }
-
-    return aBounds;
 }
 
 void DetailsContainer::show( bool bShow )
 {
-    m_bShown = bShow;
-    for ( map< sal_uInt16, Control* >::iterator it = m_aControls.begin( ); it != m_aControls.end( ); ++it )
-    {
-        it->second->Show( m_bShown );
-    }
+    m_pFrame->Show( bShow );
 }
 
 INetURLObject DetailsContainer::getUrl( )
@@ -128,25 +88,35 @@ IMPL_LINK( DetailsContainer, ValueChangeHdl, void *, EMPTYARG )
     return 0;
 }
 
-HostDetailsContainer::HostDetailsContainer( sal_uInt16 nPort, rtl::OUString sScheme ) :
-    DetailsContainer( ),
+HostDetailsContainer::HostDetailsContainer( VclBuilderContainer* pBuilder, sal_uInt16 nPort, rtl::OUString sScheme ) :
+    DetailsContainer( pBuilder, "HostDetails" ),
     m_nDefaultPort( nPort ),
     m_sScheme( sScheme )
 {
+    pBuilder->get( m_pEDHost, "host" );
+    m_pEDHost->SetModifyHdl( LINK( this, DetailsContainer, ValueChangeHdl ) );
+
+    pBuilder->get( m_pEDPort, "port" );
+    m_pEDPort->SetModifyHdl( LINK( this, DetailsContainer, ValueChangeHdl ) );
+
+    pBuilder->get( m_pEDPath, "path" );
+    m_pEDPath->SetModifyHdl( LINK( this, DetailsContainer, ValueChangeHdl ) );
+
+    show( false );
 }
 
 void HostDetailsContainer::show( bool bShow )
 {
     DetailsContainer::show( bShow );
     if ( bShow )
-        static_cast< NumericField* >( getControl( ED_ADDPLACE_PORT ) )->SetValue( m_nDefaultPort );
+        m_pEDPort->SetValue( m_nDefaultPort );
 }
 
 INetURLObject HostDetailsContainer::getUrl( )
 {
-    rtl::OUString sHost = rtl::OUString( static_cast< Edit* >( getControl( ED_ADDPLACE_HOST ) )->GetText() ).trim( );
-    sal_Int64 nPort = static_cast< NumericField* >( getControl( ED_ADDPLACE_PORT ) )->GetValue();
-    rtl::OUString sPath = rtl::OUString( static_cast< Edit* >( getControl( ED_ADDPLACE_PATH ) )->GetText() ).trim( );
+    rtl::OUString sHost = rtl::OUString( m_pEDHost->GetText() ).trim( );
+    sal_Int64 nPort = m_pEDPort->GetValue();
+    rtl::OUString sPath = rtl::OUString( m_pEDPath->GetText() ).trim( );
 
     rtl::OUString sUrl;
     if ( !sHost.isEmpty( ) )
@@ -171,9 +141,9 @@ bool HostDetailsContainer::setUrl( const INetURLObject& rUrl )
 
     if ( bSuccess )
     {
-        static_cast< Edit* >( getControl( ED_ADDPLACE_HOST ) )->SetText( rUrl.GetHost( ) );
-        static_cast< NumericField* >( getControl( ED_ADDPLACE_PORT ) )->SetValue( rUrl.GetPort( ) );
-        static_cast< Edit* >( getControl( ED_ADDPLACE_PATH ) )->SetText( rUrl.GetURLPath() );
+        m_pEDHost->SetText( rUrl.GetHost( ) );
+        m_pEDPort->SetValue( rUrl.GetPort( ) );
+        m_pEDPath->SetText( rUrl.GetURLPath() );
     }
 
     return bSuccess;
@@ -184,25 +154,23 @@ bool HostDetailsContainer::verifyScheme( const rtl::OUString& sScheme )
     return sScheme.equals( m_sScheme + "://" );
 }
 
-DavDetailsContainer::DavDetailsContainer( ) :
-    HostDetailsContainer( 80, "http" )
-{
-}
-
-void DavDetailsContainer::addControl( sal_uInt16 nId, Control* pControl )
+DavDetailsContainer::DavDetailsContainer( VclBuilderContainer* pBuilder ) :
+    HostDetailsContainer( pBuilder, 80, "http" )
 {
-    DetailsContainer::addControl( nId, pControl );
+    pBuilder->get( m_pCBDavs, "webdavs" );
+    m_pCBDavs->SetToggleHdl( LINK( this, DavDetailsContainer, ToggledDavsHdl ) );
 
-    // Add listener on CB_ADDPLACE_DAVS
-    if ( nId == CB_ADDPLACE_DAVS )
-        static_cast< CheckBox* >( pControl )->SetToggleHdl( LINK( this, DavDetailsContainer, ToggledDavsHdl ) );
+    show( false );
 }
 
 void DavDetailsContainer::show( bool bShow )
 {
     HostDetailsContainer::show( bShow );
+
+    m_pCBDavs->Show( bShow );
+
     if ( bShow )
-        static_cast< CheckBox* >( getControl( CB_ADDPLACE_DAVS ) )->Check( false );
+        m_pCBDavs->Check( false );
 }
 
 bool DavDetailsContainer::verifyScheme( const rtl::OUString& rScheme )
@@ -211,12 +179,12 @@ bool DavDetailsContainer::verifyScheme( const rtl::OUString& rScheme )
     if ( rScheme.equals( "http://" ) )
     {
         bValid = true;
-        static_cast< CheckBox* >( getControl( CB_ADDPLACE_DAVS ) )->Check( false );
+        m_pCBDavs->Check( false );
     }
     else if ( rScheme.equals( "https://" ) )
     {
         bValid = true;
-        static_cast< CheckBox* >( getControl( CB_ADDPLACE_DAVS ) )->Check( true );
+        m_pCBDavs->Check( true );
     }
     return bValid;
 }
@@ -225,11 +193,10 @@ IMPL_LINK( DavDetailsContainer, ToggledDavsHdl, CheckBox*, pCheckBox )
 {
     // Change default port if needed
     sal_Bool bCheckedDavs = pCheckBox->IsChecked();
-    NumericField* pPortField = static_cast< NumericField* >( getControl( ED_ADDPLACE_PORT ) );
-    if ( pPortField->GetValue() == 80 && bCheckedDavs == sal_True)
-        pPortField->SetValue( 443 );
-    else if ( pPortField->GetValue() == 443 && bCheckedDavs == sal_False )
-        pPortField->SetValue( 80 );
+    if ( m_pEDPort->GetValue() == 80 && bCheckedDavs == sal_True)
+        m_pEDPort->SetValue( 443 );
+    else if ( m_pEDPort->GetValue() == 443 && bCheckedDavs == sal_False )
+        m_pEDPort->SetValue( 80 );
 
     rtl::OUString sScheme( "http" );
     if ( bCheckedDavs )
@@ -241,11 +208,26 @@ IMPL_LINK( DavDetailsContainer, ToggledDavsHdl, CheckBox*, pCheckBox )
     return 0;
 }
 
+SmbDetailsContainer::SmbDetailsContainer( VclBuilderContainer* pBuilder ) :
+    DetailsContainer( pBuilder, "SmbDetails" )
+{
+    pBuilder->get( m_pEDHost, "smbHost" );
+    m_pEDHost->SetModifyHdl( LINK( this, DetailsContainer, ValueChangeHdl ) );
+
+    pBuilder->get( m_pEDShare, "smbShare" );
+    m_pEDShare->SetModifyHdl( LINK( this, DetailsContainer, ValueChangeHdl ) );
+
+    pBuilder->get( m_pEDPath, "smbPath" );
+    m_pEDPath->SetModifyHdl( LINK( this, DetailsContainer, ValueChangeHdl ) );
+
+    show( false );
+}
+
 INetURLObject SmbDetailsContainer::getUrl( )
 {
-    rtl::OUString sHost = rtl::OUString( static_cast< Edit* >( getControl( ED_ADDPLACE_SMBHOST ) )->GetText() ).trim( );
-    rtl::OUString sShare = rtl::OUString( static_cast< Edit* >( getControl( ED_ADDPLACE_SHARE ) )->GetText() ).trim( );
-    rtl::OUString sPath = rtl::OUString( static_cast< Edit* >( getControl( ED_ADDPLACE_SMBPATH ) )->GetText() ).trim( );
+    rtl::OUString sHost = rtl::OUString( m_pEDHost->GetText() ).trim( );
+    rtl::OUString sShare = rtl::OUString( m_pEDShare->GetText() ).trim( );
+    rtl::OUString sPath = rtl::OUString(  m_pEDPath->GetText() ).trim( );
 
     rtl::OUString sUrl;
     if ( !sHost.isEmpty( ) )
@@ -279,16 +261,16 @@ bool SmbDetailsContainer::setUrl( const INetURLObject& rUrl )
             sPath = sFullPath.copy( nPos );
         }
 
-        static_cast< Edit* >( getControl( ED_ADDPLACE_SMBHOST ) )->SetText( rUrl.GetHost( ) );
-        static_cast< Edit* >( getControl( ED_ADDPLACE_SHARE ) )->SetText( sShare );
-        static_cast< Edit* >( getControl( ED_ADDPLACE_SMBPATH ) )->SetText( sPath );
+        m_pEDHost->SetText( rUrl.GetHost( ) );
+        m_pEDShare->SetText( sShare );
+        m_pEDPath->SetText( sPath );
     }
 
     return bSuccess;
 }
 
-CmisDetailsContainer::CmisDetailsContainer( ) :
-    DetailsContainer( ),
+CmisDetailsContainer::CmisDetailsContainer( VclBuilderContainer* pBuilder ) :
+    DetailsContainer( pBuilder, "CmisDetails" ),
     m_sUsername( ),
     m_xCmdEnv( )
 {
@@ -296,11 +278,22 @@ CmisDetailsContainer::CmisDetailsContainer( ) :
     Reference< XInteractionHandler > xGlobalInteractionHandler(
         InteractionHandler::createWithParent(xContext, 0), UNO_QUERY );
     m_xCmdEnv = new ucbhelper::CommandEnvironment( xGlobalInteractionHandler, Reference< XProgressHandler >() );
+
+    pBuilder->get( m_pEDBinding, "binding" );
+    m_pEDBinding->SetModifyHdl( LINK( this, DetailsContainer, ValueChangeHdl ) );
+
+    pBuilder->get( m_pLBRepository, "repositories" );
+    m_pLBRepository->SetSelectHdl( LINK( this, CmisDetailsContainer, SelectRepoHdl ) );
+
+    pBuilder->get( m_pBTRepoRefresh, "repositoriesRefresh" );
+    m_pBTRepoRefresh->SetClickHdl( LINK( this, CmisDetailsContainer, RefreshReposHdl ) );
+
+    show( false );
 }
 
 INetURLObject CmisDetailsContainer::getUrl( )
 {
-    rtl::OUString sBindingUrl = rtl::OUString( static_cast< Edit* >( getControl( ED_ADDPLACE_CMIS_BINDING ) )->GetText() ).trim( );
+    rtl::OUString sBindingUrl = rtl::OUString( m_pEDBinding->GetText() ).trim( );
 
     rtl::OUString sUrl;
     if ( !sBindingUrl.isEmpty( ) && !m_sRepoId.isEmpty() )
@@ -330,7 +323,7 @@ bool CmisDetailsContainer::setUrl( const INetURLObject& rUrl )
         sBindingUrl = aHostUrl.GetURLNoMark( );
         sRepositoryId = aHostUrl.GetMark( );
 
-        static_cast< Edit* >( getControl( ED_ADDPLACE_CMIS_BINDING ) )->SetText( sBindingUrl );
+        m_pEDBinding->SetText( sBindingUrl );
     }
 
     return bSuccess;
@@ -341,22 +334,10 @@ void CmisDetailsContainer::setUsername( const rtl::OUString& rUsername )
     m_sUsername = rtl::OUString( rUsername );
 }
 
-void CmisDetailsContainer::addControl( sal_uInt16 nId, Control* pControl )
-{
-    DetailsContainer::addControl( nId, pControl );
-
-    // Add listener on BT_ADDPLACE_CMIS_REPOREFRESH
-    if ( nId == BT_ADDPLACE_CMIS_REPOREFRESH )
-        static_cast< ImageButton* >( pControl )->SetClickHdl( LINK( this, CmisDetailsContainer, RefreshReposHdl ) );
-    if ( nId == LB_ADDPLACE_CMIS_REPOSITORY )
-        static_cast< ListBox* >( pControl )->SetSelectHdl( LINK( this, CmisDetailsContainer, SelectRepoHdl ) );
-}
-
 void CmisDetailsContainer::selectRepository( )
 {
     // Get the repo ID and call the Change listener
-    ListBox* pReposList = static_cast< ListBox* >( getControl( LB_ADDPLACE_CMIS_REPOSITORY ) );
-    sal_uInt16 nPos = pReposList->GetSelectEntryPos( );
+    sal_uInt16 nPos = m_pLBRepository->GetSelectEntryPos( );
     m_sRepoId = m_aRepoIds[nPos];
 
     notifyChange( );
@@ -364,11 +345,10 @@ void CmisDetailsContainer::selectRepository( )
 
 IMPL_LINK( CmisDetailsContainer, RefreshReposHdl, void *, EMPTYARG  )
 {
-    rtl::OUString sBindingUrl = rtl::OUString( static_cast< Edit* >( getControl( ED_ADDPLACE_CMIS_BINDING ) )->GetText() ).trim( );
+    rtl::OUString sBindingUrl = rtl::OUString( m_pEDBinding->GetText() ).trim( );
 
     // Clean the listbox
-    ListBox* pReposList = static_cast< ListBox* >( getControl( LB_ADDPLACE_CMIS_REPOSITORY ) );
-    pReposList->Clear( );
+    m_pLBRepository->Clear( );
     m_aRepoIds.clear( );
 
     // Compute the URL
@@ -402,7 +382,7 @@ IMPL_LINK( CmisDetailsContainer, RefreshReposHdl, void *, EMPTYARG  )
 
             Reference< XRow > xRow( xResultSet, UNO_QUERY );
             rtl::OUString sName = xRow->getString( 1 );
-            pReposList->InsertEntry( sName );
+            m_pLBRepository->InsertEntry( sName );
         }
     }
     catch ( const Exception& )
@@ -410,9 +390,9 @@ IMPL_LINK( CmisDetailsContainer, RefreshReposHdl, void *, EMPTYARG  )
     }
 
     // Auto-select the first one
-    if ( pReposList->GetEntryCount( ) > 0 )
+    if ( m_pLBRepository->GetEntryCount( ) > 0 )
     {
-        pReposList->SelectEntryPos( 0 );
+        m_pLBRepository->SelectEntryPos( 0 );
         selectRepository( );
     }
 
diff --git a/svtools/uiconfig/ui/placeedit.ui b/svtools/uiconfig/ui/placeedit.ui
new file mode 100644
index 0000000..2f0a2aa
--- /dev/null
+++ b/svtools/uiconfig/ui/placeedit.ui
@@ -0,0 +1,660 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+  <!-- interface-requires gtk+ 3.0 -->
+  <object class="GtkAdjustment" id="adjustment1">
+    <property name="upper">65535</property>
+    <property name="step_increment">1</property>
+    <property name="page_increment">10</property>
+  </object>
+  <object class="GtkListStore" id="ServerTypes">
+    <columns>
+      <!-- column-name ServerType -->
+      <column type="gchararray"/>
+    </columns>
+    <data>
+      <row>
+        <col id="0" translatable="yes">WebDAV</col>
+      </row>
+      <row>
+        <col id="0" translatable="yes">FTP</col>
+      </row>
+      <row>
+        <col id="0" translatable="yes">SSH</col>
+      </row>
+      <row>
+        <col id="0" translatable="yes">Windows Share</col>
+      </row>
+      <row>
+        <col id="0" translatable="yes">CMIS</col>
+      </row>
+    </data>
+  </object>
+  <object class="GtkDialog" id="PlaceEditDialog">
+    <property name="can_focus">False</property>
+    <property name="border_width">5</property>
+    <property name="type_hint">dialog</property>
+    <child internal-child="vbox">
+      <object class="GtkBox" id="dialog-vbox1">
+        <property name="can_focus">False</property>
+        <property name="orientation">vertical</property>
+        <property name="spacing">2</property>
+        <child>
+          <object class="GtkGrid" id="grid1">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="column_spacing">6</property>
+            <child>
+              <object class="GtkLabel" id="label1">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="halign">start</property>
+                <property name="label" translatable="yes">Name</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="GtkLabel" id="label2">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="halign">start</property>
+                <property name="margin_top">6</property>
+                <property name="label" translatable="yes">Type</property>
+              </object>
+              <packing>
+                <property name="left_attach">0</property>
+                <property name="top_attach">1</property>
+                <property name="width">1</property>
+                <property name="height">1</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkEntry" id="name">
+                <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">0</property>
+                <property name="width">1</property>
+                <property name="height">1</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkComboBox" id="type">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="margin_top">6</property>
+                <property name="hexpand">True</property>
+                <property name="model">ServerTypes</property>
+                <child>
+                  <object class="GtkCellRendererText" id="cellrenderertext1"/>
+                  <attributes>
+                    <attribute name="text">0</attribute>
+                  </attributes>
+                </child>
+              </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>
+          </object>
+          <packing>
+            <property name="expand">False</property>
+            <property name="fill">True</property>
+            <property name="position">0</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkFrame" id="HostDetails">
+            <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="alignment1">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="left_padding">12</property>
+                <child>
+                  <object class="GtkGrid" id="grid2">
+                    <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="hostLabel">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="halign">start</property>
+                        <property name="label" translatable="yes">Host</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="GtkLabel" id="pathLabel">
+                        <property name="visible">True</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">0</property>
+                        <property name="top_attach">1</property>
+                        <property name="width">1</property>
+                        <property name="height">1</property>
+                      </packing>
+                    </child>
+                    <child>
+                      <object class="GtkGrid" id="grid3">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="row_spacing">5</property>
+                        <property name="column_spacing">6</property>
+                        <child>
+                          <object class="GtkEntry" id="host">
+                            <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">0</property>
+                            <property name="top_attach">0</property>
+                            <property name="width">1</property>
+                            <property name="height">1</property>
+                          </packing>
+                        </child>
+                        <child>
+                          <object class="GtkLabel" id="portLabel">
+                            <property name="visible">True</property>
+                            <property name="can_focus">False</property>
+                            <property name="halign">start</property>
+                            <property name="label" translatable="yes">Port</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>
+                        <child>
+                          <object class="GtkSpinButton" id="port">
+                            <property name="visible">True</property>
+                            <property name="can_focus">True</property>
+                            <property name="invisible_char">●</property>
+                            <property name="adjustment">adjustment1</property>
+                            <property name="numeric">True</property>
+                          </object>
+                          <packing>
+                            <property name="left_attach">2</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">0</property>
+                        <property name="width">1</property>
+                        <property name="height">1</property>
+                      </packing>
+                    </child>
+                    <child>
+                      <object class="GtkEntry" id="path">
+                        <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="GtkCheckButton" id="webdavs">
+                        <property name="label" translatable="yes">Secured WebDAV (HTTPS)</property>
+                        <property name="use_action_appearance">False</property>
+                        <property name="can_focus">True</property>
+                        <property name="receives_default">False</property>
+                        <property name="hexpand">True</property>
+                        <property name="use_action_appearance">False</property>
+                        <property name="xalign">0</property>
+                        <property name="draw_indicator">True</property>
+                      </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>
+                      <placeholder/>
+                    </child>
+                  </object>
+                </child>
+              </object>
+            </child>
+            <child type="label">
+              <object class="GtkLabel" id="label4">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="label" translatable="yes">Server Details</property>
+                <attributes>
+                  <attribute name="weight" value="bold"/>
+                </attributes>
+              </object>
+            </child>
+          </object>
+          <packing>
+            <property name="expand">False</property>
+            <property name="fill">True</property>
+            <property name="position">1</property>
+          </packing>
+        </child>
+        <child>
+          <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="alignment2">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="left_padding">12</property>
+                <child>
+                  <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="label9">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="halign">start</property>
+                        <property name="label" translatable="yes">Host</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="GtkLabel" id="label10">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="halign">start</property>
+                        <property name="label" translatable="yes">Share</property>
+                      </object>
+                      <packing>
+                        <property name="left_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="label11">
+                        <property name="visible">True</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">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="smbHost">
+                        <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">0</property>
+                        <property name="width">1</property>
+                        <property name="height">1</property>
+                      </packing>
+                    </child>
+                    <child>
+                      <object class="GtkEntry" id="smbShare">
+                        <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="GtkEntry" id="smbPath">
+                        <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="width">1</property>
+                        <property name="height">1</property>
+                      </packing>
+                    </child>
+                  </object>
+                </child>
+              </object>
+            </child>
+            <child type="label">
+              <object class="GtkLabel" id="label8">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="label" translatable="yes">Server Details</property>
+                <attributes>
+                  <attribute name="weight" value="bold"/>
+                </attributes>
+              </object>
+            </child>
+          </object>
+          <packing>
+            <property name="expand">False</property>
+            <property name="fill">True</property>
+            <property name="position">3</property>
+          </packing>
+        </child>
+        <child>
+          <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="alignment3">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="left_padding">12</property>
+                <child>
+                  <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="bindingLabel">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="halign">start</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="width">1</property>
+                        <property name="height">1</property>
+                      </packing>
+                    </child>
+                    <child>
+                      <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">Repository</property>
+                      </object>
+                      <packing>
+                        <property name="left_attach">0</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">
+                        <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">0</property>
+                        <property name="width">1</property>
+                        <property name="height">1</property>
+                      </packing>
+                    </child>
+                    <child>
+                      <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">1</property>
+                        <property name="width">1</property>
+                        <property name="height">1</property>
+                      </packing>
+                    </child>
+                  </object>
+                </child>
+              </object>
+            </child>
+            <child type="label">
+              <object class="GtkLabel" id="label12">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="label" translatable="yes">Server Details</property>
+                <attributes>
+                  <attribute name="weight" value="bold"/>
+                </attributes>
+              </object>
+            </child>
+          </object>
+          <packing>
+            <property name="expand">False</property>
+            <property name="fill">True</property>
+            <property name="position">3</property>
+          </packing>
+        </child>
+        <child internal-child="action_area">
+          <object class="GtkButtonBox" id="dialog-action_area1">
+            <property name="can_focus">False</property>
+            <property name="layout_style">end</property>
+            <child>
+              <object class="GtkButton" id="delete">
+                <property name="label">gtk-delete</property>
+                <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="use_stock">True</property>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">0</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkButton" id="ok">
+                <property name="label">gtk-ok</property>
+                <property name="use_action_appearance">False</property>
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="can_default">True</property>
+                <property name="has_default">True</property>
+                <property name="receives_default">True</property>
+                <property name="use_action_appearance">False</property>
+                <property name="use_stock">True</property>
+                <property name="yalign">0.50999999046325684</property>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">2</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkButton" id="cancel">
+                <property name="label">gtk-cancel</property>
+                <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="use_stock">True</property>
+                <property name="image_position">top</property>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">3</property>
+              </packing>
+            </child>
+          </object>
+          <packing>
+            <property name="expand">False</property>
+            <property name="fill">True</property>
+            <property name="pack_type">end</property>
+            <property name="position">3</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkFrame" id="UserDetails">
+            <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="alignment4">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="left_padding">12</property>
+                <child>
+                  <object class="GtkGrid" id="grid7">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="column_spacing">6</property>
+                    <child>
+                      <object class="GtkLabel" id="label16">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="label" translatable="yes">Login</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="GtkEntry" id="login">
+                        <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">0</property>
+                        <property name="width">1</property>
+                        <property name="height">1</property>
+                      </packing>
+                    </child>
+                  </object>
+                </child>
+              </object>
+            </child>
+            <child type="label">
+              <object class="GtkLabel" id="label15">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="label" translatable="yes">User Details</property>
+                <attributes>
+                  <attribute name="weight" value="bold"/>
+                </attributes>
+              </object>
+            </child>
+          </object>
+          <packing>
+            <property name="expand">False</property>
+            <property name="fill">True</property>
+            <property name="position">5</property>
+          </packing>
+        </child>
+      </object>
+    </child>
+    <action-widgets>
+      <action-widget response="0">delete</action-widget>
+      <action-widget response="0">ok</action-widget>
+      <action-widget response="0">cancel</action-widget>
+    </action-widgets>
+  </object>
+  <object class="GtkImage" id="image1">
+    <property name="visible">True</property>
+    <property name="can_focus">False</property>
+    <property name="stock">gtk-refresh</property>
+  </object>
+</interface>
commit 4f679851dc2edcfdc4d7c45cb097acc0c80dab46
Author: Cédric Bosdonnat <cedric.bosdonnat at free.fr>
Date:   Thu Nov 8 16:56:16 2012 +0100

    CMIS: after cancel-checkout mark the document non changed
    
    Change-Id: I626bd6ab29da29d4cd312b56208e4a2d0697c2fe

diff --git a/sfx2/source/doc/objserv.cxx b/sfx2/source/doc/objserv.cxx
index 2412dcc..61bb81a 100644
--- a/sfx2/source/doc/objserv.cxx
+++ b/sfx2/source/doc/objserv.cxx
@@ -368,6 +368,10 @@ void SfxObjectShell::CancelCheckOut( )
     {
         uno::Reference< document::XCmisDocument > xCmisDoc( GetModel(), uno::UNO_QUERY_THROW );
         xCmisDoc->cancelCheckOut( );
+
+        uno::Reference< util::XModifiable > xModifiable( GetModel( ), uno::UNO_QUERY );
+        if ( xModifiable.is( ) )
+            xModifiable->setModified( sal_False );
     }
     catch ( const uno::RuntimeException& e )
     {


More information about the Libreoffice-commits mailing list