[Libreoffice-commits] .: 2 commits - fpicker/AllLangResTarget_fps_office.mk fpicker/inc fpicker/Library_fps_office.mk fpicker/Module_fpicker.mk fpicker/Package_inc.mk fpicker/source svl/inc svtools/inc sw/source vcl/unx

Cédric Bosdonnat cbosdo at kemper.freedesktop.org
Fri May 4 03:20:42 PDT 2012


 fpicker/AllLangResTarget_fps_office.mk          |    6 
 fpicker/Library_fps_office.mk                   |    6 
 fpicker/Module_fpicker.mk                       |    1 
 fpicker/Package_inc.mk                          |   13 +
 fpicker/inc/fpicker/fpicker.hrc                 |   52 ++++
 fpicker/source/aqua/resourceprovider.mm         |    3 
 fpicker/source/office/OfficeFilePicker.hrc      |   47 ++++
 fpicker/source/office/OfficeFilePicker.src      |    2 
 fpicker/source/office/PlaceEditDialog.cxx       |  254 +++++++++++++++++-----
 fpicker/source/office/PlaceEditDialog.hrc       |   58 +++++
 fpicker/source/office/PlaceEditDialog.hxx       |   68 ++++-
 fpicker/source/office/PlaceEditDialog.src       |  183 +++++++++++++++
 fpicker/source/office/PlacesListBox.cxx         |    3 
 fpicker/source/office/PlacesListBox.hxx         |    1 
 fpicker/source/office/ServerDetailsControls.cxx |  275 ++++++++++++++++++++++++
 fpicker/source/office/ServerDetailsControls.hxx |  123 ++++++++++
 fpicker/source/office/iodlg.cxx                 |   13 -
 fpicker/source/office/iodlg.hrc                 |   17 -
 fpicker/source/office/iodlg.src                 |  110 ---------
 fpicker/source/win32/misc/resourceprovider.cxx  |    2 
 svl/inc/svl/solar.hrc                           |    5 
 svtools/inc/svtools/svtools.hrc                 |   40 ---
 sw/source/core/crsr/crsrsh.cxx                  |  126 ++++++----
 vcl/unx/kde/UnxFilePicker.cxx                   |    2 
 vcl/unx/kde4/KDE4FilePicker.cxx                 |    2 
 25 files changed, 1109 insertions(+), 303 deletions(-)

New commits:
commit cce89fa52867393633e98b643f038d5b3e5d5969
Author: Sebastian Spaeth <Sebastian at SSpaeth.de>
Date:   Fri May 4 09:54:40 2012 +0200

    sw/.../crsrsh.cxx: Translate some German comments
    
    I tried hard, in some cases the German did not make any more
    sense than the translations though. I also tried to carefully
    improve wording with respect to doxygen comments, without
    really having to understand the code...
    
    Change-Id: I I5f3abad10d1591ddc3c9a0cc77a18b80af0de5ce
    Signed-off-by: Sebastian Spaeth <Sebastian at SSpaeth.de>

diff --git a/sw/source/core/crsr/crsrsh.cxx b/sw/source/core/crsr/crsrsh.cxx
index 386798b..f6e43fc 100644
--- a/sw/source/core/crsr/crsrsh.cxx
+++ b/sw/source/core/crsr/crsrsh.cxx
@@ -77,17 +77,18 @@ using namespace util;
 TYPEINIT2(SwCrsrShell,ViewShell,SwModify);
 
 
-// Funktion loescht, alle ueberlappenden Cursor aus einem Cursor-Ring
+/**
+ * Delete all overlapping Cursors from a Cursor ring.
+ * @param pointer to SwCursor (ring)
+ */
 void CheckRange( SwCursor* );
 
 //-----------------------------------------------------------------------
 
-/*
- * Ueberpruefe ob der pCurCrsr in einen schon bestehenden Bereich zeigt.
- * Wenn ja, dann hebe den alten Bereich auf.
+/**
+ * Check if pCurCrsr points into already existing ranges and delete those.
+ * @param Pointer to SwCursor object
  */
-
-
 void CheckRange( SwCursor* pCurCrsr )
 {
     const SwPosition *pStt = pCurCrsr->Start(),
@@ -96,7 +97,7 @@ void CheckRange( SwCursor* pCurCrsr )
     SwPaM *pTmpDel = 0,
           *pTmp = (SwPaM*)pCurCrsr->GetNext();
 
-    // durchsuche den gesamten Ring
+    // Search the complete ring
     while( pTmp != pCurCrsr )
     {
         const SwPosition *pTmpStt = pTmp->Start(),
@@ -112,54 +113,58 @@ void CheckRange( SwCursor* pCurCrsr )
             if( *pStt < *pTmpEnd )
                 pTmpDel = pTmp;
         /*
-         * liegt ein SPoint oder GetMark innerhalb vom Crsr-Bereich
-         * muss der alte Bereich aufgehoben werden.
-         * Beim Vergleich ist darauf zu achten, das SPoint nicht mehr zum
-         * Bereich gehoert !
+         * If Point or Mark is within the Crsr range, we
+         * need to remove the old range. Take note that Point does
+         * not belong to the range anymore.
          */
         pTmp = (SwPaM*)pTmp->GetNext();
-        delete pTmpDel;         // hebe alten Bereich auf
+        delete pTmpDel;         // Remove old range
         pTmpDel = 0;
     }
 }
 
-// -------------- Methoden von der SwCrsrShell -------------
+
+
+/**
+ Methods of SwCrsrShell
+ */
+
 
 SwPaM * SwCrsrShell::CreateCrsr()
 {
-    // Innerhalb der Tabellen-SSelection keinen neuen Crsr anlegen
-    OSL_ENSURE( !IsTableMode(), "in Tabellen SSelection" );
+    // don't create Crsr in a table Selection (sic!)
+    OSL_ENSURE( !IsTableMode(), "in table Selection" );
 
-    // neuen Cursor als Kopie vom akt. und in den Ring aufnehmen
-    // Verkettung zeigt immer auf den zuerst erzeugten, also vorwaerts
+    // New cursor as copy of current one. Add to the ring.
+    // Links point to previously created one, ie forward.
     SwShellCrsr* pNew = new SwShellCrsr( *pCurCrsr );
 
-    // hier den akt. Pam nur logisch Hiden, weil sonst die Invertierung
-    // vom kopierten Pam aufgehoben wird !!
-
-    // #i75172#
+    // Hide PaM logically, to avoid undoing the inverting from
+    // copied PaM (#i75172#)
     pNew->swapContent(*pCurCrsr);
 
     pCurCrsr->DeleteMark();
 
     UpdateCrsr( SwCrsrShell::SCROLLWIN );
-//  return pCurCrsr;
     return pNew;
 }
 
-// loesche den aktuellen Cursor und der folgende wird zum Aktuellen
-
 
+/**
+ * Delete current Cursor, making the following one the current.
+ * Note, this function does not delete anything if there is no other cursor.
+ * @return - returns sal_True if there was another cursor and we deleted one.
+ */
 sal_Bool SwCrsrShell::DestroyCrsr()
 {
-    // Innerhalb der Tabellen-SSelection keinen neuen Crsr loeschen
-    OSL_ENSURE( !IsTableMode(), "in Tabellen SSelection" );
+    // don't delete Crsr within table selection
+    OSL_ENSURE( !IsTableMode(), "in table Selection" );
 
-    // ist ueberhaupt ein naechtser vorhanden ?
+    // Is there a next one? Don't do anything if not.
     if(pCurCrsr->GetNext() == pCurCrsr)
         return sal_False;
 
-    SwCallLink aLk( *this );        // Crsr-Moves ueberwachen,
+    SwCallLink aLk( *this );        // watch Crsr-Moves
     SwCursor* pNextCrsr = (SwCursor*)pCurCrsr->GetNext();
     delete pCurCrsr;
     pCurCrsr = dynamic_cast<SwShellCrsr*>(pNextCrsr);
@@ -168,6 +173,11 @@ sal_Bool SwCrsrShell::DestroyCrsr()
 }
 
 
+/**
+ * Create and return a new shell cursor.
+ * Simply returns the current shell cursor if there is no selection
+ * (HasSelection()).
+ */
 SwPaM & SwCrsrShell::CreateNewShellCursor()
 {
     if (HasSelection())
@@ -177,21 +187,26 @@ SwPaM & SwCrsrShell::CreateNewShellCursor()
     return *GetCrsr();
 }
 
+/**
+ * Return the current shell cursor
+ * @return - returns current `SwPaM` shell cursor
+ */
 SwPaM & SwCrsrShell::GetCurrentShellCursor()
 {
     return *GetCrsr();
 }
 
-
-// gebe den aktuellen zurueck
-
+/**
+ * Return pointer to the current shell cursor
+ * @return - returns pointer to current `SwPaM` shell cursor
+ */
 SwPaM* SwCrsrShell::GetCrsr( sal_Bool bMakeTblCrsr ) const
 {
     if( pTblCrsr )
     {
         if( bMakeTblCrsr && pTblCrsr->IsCrsrMovedUpdt() )
         {
-            // geparkte Cursor werden nicht wieder erzeugt
+            //don't re-create 'parked'(?) cursors
             const SwCntntNode* pCNd;
             if( pTblCrsr->GetPoint()->nNode.GetIndex() &&
                 pTblCrsr->GetMark()->nNode.GetIndex() &&
@@ -217,7 +232,7 @@ void SwCrsrShell::StartAction()
 {
     if( !ActionPend() )
     {
-        // fuer das Update des Ribbon-Bars merken
+        // save for update of the ribbon bar
         const SwNode& rNd = pCurCrsr->GetPoint()->nNode.GetNode();
         nAktNode = rNd.GetIndex();
         nAktCntnt = pCurCrsr->GetPoint()->nContent.GetIndex();
@@ -228,22 +243,21 @@ void SwCrsrShell::StartAction()
         else
             nLeftFrmPos = 0;
     }
-    ViewShell::StartAction();           // zur ViewShell
+    ViewShell::StartAction();           // to the ViewShell
 }
 
 
 void SwCrsrShell::EndAction( const sal_Bool bIdleEnd )
 {
-
     sal_Bool bVis = bSVCrsrVis;
 
-    // Idle-Formatierung ?
+    // Idle-formatting?
     if( bIdleEnd && Imp()->GetRegion() )
     {
         pCurCrsr->Hide();
     }
 
-    // vor der letzten Action alle invaliden Numerierungen updaten
+    // Update all invalid numberings before the last action
     if( 1 == nStartAction )
         GetDoc()->UpdateNumRule();
 
@@ -252,29 +266,28 @@ void SwCrsrShell::EndAction( const sal_Bool bIdleEnd )
     sal_Bool bSavSVCrsrVis = bSVCrsrVis;
     bSVCrsrVis = sal_False;
 
-    ViewShell::EndAction( bIdleEnd );   //der ViewShell den Vortritt lassen
+    ViewShell::EndAction( bIdleEnd );   // have ViewShell go first
 
     bSVCrsrVis = bSavSVCrsrVis;
 
     if( ActionPend() )
     {
-        if( bVis )    // auch SV-Cursor wieder anzeigen
+        if( bVis )    // display SV-Cursor again
             pVisCrsr->Show();
 
-        // falls noch ein ChgCall vorhanden ist und nur noch die Basic
-        // Klammerung vorhanden ist, dann rufe ihn. Dadurch wird die interne
-        // mit der Basic-Klammerung entkoppelt; die Shells werden umgeschaltet
+        // If there is still a ChgCall and just the "basic
+        // parenthiszing(?) (Basic-Klammerung)" exists, call it. This
+        // decouples the internal with the Basic-parenthising, the
+        // Shells are switched.
         if( !BasicActionPend() )
         {
-            // es muss innerhalb einer BasicAction
-            //              der Cursor geupdatet werden; um z.B. den
-            //              TabellenCursor zu erzeugen. Im UpdateCrsr wird
-            //              das jetzt beruecksichtigt!
+            // Within a Basic action, one needs to update the cursor,
+            // to e.g. create the table cursos. This is being done in
+            // UpdateCrsr.
             UpdateCrsr( SwCrsrShell::CHKRANGE, bIdleEnd );
 
             {
-                // Crsr-Moves ueberwachen, evt. Link callen
-                // der DTOR ist das interressante!!
+                // watch Crsr-Moves, call Link if needed, the DTOR is key here!
                 SwCallLink aLk( *this, nAktNode, nAktCntnt, (sal_uInt8)nAktNdTyp,
                                 nLeftFrmPos, bAktSelection );
 
@@ -282,7 +295,7 @@ void SwCrsrShell::EndAction( const sal_Bool bIdleEnd )
             if( bCallChgLnk && bChgCallFlag && aChgLnk.IsSet() )
             {
                 aChgLnk.Call( this );
-                bChgCallFlag = sal_False;       // Flag zuruecksetzen
+                bChgCallFlag = sal_False;       // reset flag
             }
         }
         return;
@@ -292,24 +305,25 @@ void SwCrsrShell::EndAction( const sal_Bool bIdleEnd )
     if ( !bIdleEnd )
         nParm |= SwCrsrShell::SCROLLWIN;
 //    if( !IsViewLocked() )
-    UpdateCrsr( nParm, bIdleEnd );      // Cursor-Aenderungen anzeigen
+    UpdateCrsr( nParm, bIdleEnd );      // Show Cursor changes
 
     {
-        SwCallLink aLk( *this );        // Crsr-Moves ueberwachen,
-        aLk.nNode = nAktNode;           // evt. Link callen
+        SwCallLink aLk( *this );        // watch Crsr-Moves
+        aLk.nNode = nAktNode;           // call Link if needed
         aLk.nNdTyp = (sal_uInt8)nAktNdTyp;
         aLk.nCntnt = nAktCntnt;
         aLk.nLeftFrmPos = nLeftFrmPos;
 
         if( !nCrsrMove ||
             ( 1 == nCrsrMove && bInCMvVisportChgd ) )
-            ShowCrsrs( bSVCrsrVis ? sal_True : sal_False );    // Cursor & Selektionen wieder anzeigen
+            // display Cursor & Selektions again
+            ShowCrsrs( bSVCrsrVis ? sal_True : sal_False );
     }
-    // falls noch ein ChgCall vorhanden ist, dann rufe ihn
+    // call ChgCall if there is still one
     if( bCallChgLnk && bChgCallFlag && aChgLnk.IsSet() )
     {
         aChgLnk.Call( this );
-        bChgCallFlag = sal_False;       // Flag zuruecksetzen
+        bChgCallFlag = sal_False;       // reset flag
     }
 }
 
@@ -325,7 +339,7 @@ void SwCrsrShell::SttCrsrMove()
 
 void SwCrsrShell::EndCrsrMove( const sal_Bool bIdleEnd )
 {
-    OSL_ENSURE( nCrsrMove, "EndCrsrMove() ohne SttCrsrMove()." );
+    OSL_ENSURE( nCrsrMove, "EndCrsrMove() without SttCrsrMove()." );
     EndAction( bIdleEnd );
     if( !--nCrsrMove )
         bInCMvVisportChgd = sal_False;
commit e00e06ce4306e8e9e0b76e0b641c001734186347
Author: Cédric Bosdonnat <cedric.bosdonnat at free.fr>
Date:   Thu May 3 16:55:22 2012 +0200

    fpicker: make the place edition dialog working
    
    Change-Id: If290ea4c1418162902e00bcc29c3afe69685ec5d

diff --git a/fpicker/AllLangResTarget_fps_office.mk b/fpicker/AllLangResTarget_fps_office.mk
index 5d666bb..88c1b76 100644
--- a/fpicker/AllLangResTarget_fps_office.mk
+++ b/fpicker/AllLangResTarget_fps_office.mk
@@ -40,9 +40,15 @@ $(eval $(call gb_SrsTarget_use_packages,fps_office/res,\
 	svtools_inc \
 ))
 
+$(eval $(call gb_SrsTarget_set_include,fps_office/res,\
+    $$(INCLUDE) \
+    -I$(SRCDIR)/fpicker/inc \
+))
+
 $(eval $(call gb_SrsTarget_add_files,fps_office/res,\
 	fpicker/source/office/OfficeFilePicker.src \
 	fpicker/source/office/iodlg.src \
+	fpicker/source/office/PlaceEditDialog.src \
 ))
 
 # vim: set noet sw=4 ts=4:
diff --git a/fpicker/Library_fps_office.mk b/fpicker/Library_fps_office.mk
index af5bc1b..b9c9414 100644
--- a/fpicker/Library_fps_office.mk
+++ b/fpicker/Library_fps_office.mk
@@ -34,6 +34,11 @@ $(eval $(call gb_Library_use_api,fps_office,\
 	udkapi \
 ))
 
+$(eval $(call gb_Library_set_include,fps_office,\
+    $$(INCLUDE) \
+    -I$(SRCDIR)/fpicker/inc \
+))
+
 $(eval $(call gb_Library_use_libraries,fps_office,\
 	comphelper \
 	cppu \
@@ -62,6 +67,7 @@ $(eval $(call gb_Library_add_exception_objects,fps_office,\
 	fpicker/source/office/OfficeFolderPicker \
 	fpicker/source/office/PlaceEditDialog \
 	fpicker/source/office/PlacesListBox \
+	fpicker/source/office/ServerDetailsControls \
 ))
 
 # vim: set noet sw=4 ts=4:
diff --git a/fpicker/Module_fpicker.mk b/fpicker/Module_fpicker.mk
index 1edc7c9..30da957 100644
--- a/fpicker/Module_fpicker.mk
+++ b/fpicker/Module_fpicker.mk
@@ -33,6 +33,7 @@ $(eval $(call gb_Module_add_targets,fpicker,\
 	AllLangResTarget_fps_office \
 	Library_fpicker \
 	Library_fps_office \
+	Package_inc \
 ))
 
 ifeq ($(GUIBASE),aqua)
diff --git a/fpicker/Package_inc.mk b/fpicker/Package_inc.mk
new file mode 100644
index 0000000..81113e9
--- /dev/null
+++ b/fpicker/Package_inc.mk
@@ -0,0 +1,13 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#
+# 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/.
+#
+
+$(eval $(call gb_Package_Package,fpicker_inc,$(SRCDIR)/fpicker/inc))
+$(eval $(call gb_Package_add_file,fpicker_inc,inc/fpicker/fpicker.hrc,fpicker/fpicker.hrc))
+
+# vim: set noet sw=4 ts=4:
diff --git a/fpicker/inc/fpicker/fpicker.hrc b/fpicker/inc/fpicker/fpicker.hrc
new file mode 100644
index 0000000..32d7eb9
--- /dev/null
+++ b/fpicker/inc/fpicker/fpicker.hrc
@@ -0,0 +1,52 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * Version: MPL 1.1 / GPLv3+ / LGPLv3+
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License or as specified alternatively below. You may obtain a copy of
+ * the License at http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * Major Contributor(s):
+ * [ Copyright (C) 2012 SUSE <cbosdonnat at suse.com> (initial developer) ]
+ *
+ * All Rights Reserved.
+ *
+ * For minor contributions see the git repository.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+ * the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+ * in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+ * instead of those above.
+ */
+#ifndef _FPICKER_HRC
+#define _FPICKER_HRC
+
+#include <svl/solar.hrc>
+
+#define STR_SVT_FILEPICKER_START                    (RID_FPICKER_START+1)
+#define STR_SVT_FILEPICKER_AUTO_EXTENSION           (STR_SVT_FILEPICKER_START+ 0)
+#define STR_SVT_FILEPICKER_PASSWORD                 (STR_SVT_FILEPICKER_START+ 1)
+#define STR_SVT_FILEPICKER_FILTER_OPTIONS           (STR_SVT_FILEPICKER_START+ 2)
+#define STR_SVT_FILEPICKER_READONLY                 (STR_SVT_FILEPICKER_START+ 3)
+#define STR_SVT_FILEPICKER_INSERT_AS_LINK           (STR_SVT_FILEPICKER_START+ 4)
+#define STR_SVT_FILEPICKER_SHOW_PREVIEW             (STR_SVT_FILEPICKER_START+ 5)
+#define STR_SVT_FILEPICKER_PLAY                     (STR_SVT_FILEPICKER_START+ 6)
+#define STR_SVT_FILEPICKER_VERSION                  (STR_SVT_FILEPICKER_START+ 7)
+#define STR_SVT_FILEPICKER_TEMPLATES                (STR_SVT_FILEPICKER_START+ 8)
+#define STR_SVT_FILEPICKER_IMAGE_TEMPLATE           (STR_SVT_FILEPICKER_START+ 9)
+#define STR_SVT_FILEPICKER_SELECTION                (STR_SVT_FILEPICKER_START+10)
+#define STR_SVT_FILEPICKER_FILTER_TITLE             (STR_SVT_FILEPICKER_START+11)
+#define STR_SVT_FOLDERPICKER_DEFAULT_TITLE          (STR_SVT_FILEPICKER_START+12)
+#define STR_SVT_FOLDERPICKER_DEFAULT_DESCRIPTION    (STR_SVT_FILEPICKER_START+13)
+#define STR_SVT_FILEPICKER_END                      (STR_SVT_FOLDERPICKER_DEFAULT_DESCRIPTION)
+
+
+#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/fpicker/source/aqua/resourceprovider.mm b/fpicker/source/aqua/resourceprovider.mm
index bc821ec..92efaac 100644
--- a/fpicker/source/aqua/resourceprovider.mm
+++ b/fpicker/source/aqua/resourceprovider.mm
@@ -38,8 +38,7 @@
 #include <com/sun/star/ui/dialogs/CommonFilePickerElementIds.hpp>
 #include <com/sun/star/ui/dialogs/ExtendedFilePickerElementIds.hpp>
 
-#include <svtools/svtools.hrc>
-
+#include "fpicker.hrc"
 #include <svtools/filedlg2.hrc>
 #include "NSString_OOoAdditions.hxx"
 
diff --git a/fpicker/source/office/OfficeFilePicker.hrc b/fpicker/source/office/OfficeFilePicker.hrc
new file mode 100644
index 0000000..adbd328
--- /dev/null
+++ b/fpicker/source/office/OfficeFilePicker.hrc
@@ -0,0 +1,47 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * Version: MPL 1.1 / GPLv3+ / LGPLv3+
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License or as specified alternatively below. You may obtain a copy of
+ * the License at http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * Major Contributor(s):
+ * [ Copyright (C) 2012 SUSE <cbosdonnat at suse.com> (initial developer) ]
+ *
+ * All Rights Reserved.
+ *
+ * For minor contributions see the git repository.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+ * the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+ * in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+ * instead of those above.
+ */
+#ifndef _FPICKER_OFFICEFILEPICKER_HRC
+#define _FPICKER_OFFICEFILEPICKER_HRC
+
+#include <fpicker/fpicker.hrc>
+
+#define DLG_FPICKER_EXPLORERFILE                    (RID_FPICKER_START+14)
+#define DLG_FPICKER_QUERYFOLDERNAME                 (RID_FPICKER_START+15)
+#define DLG_FPICKER_PLACE_EDIT                      (RID_FPICKER_START+16)
+
+#define RID_FILEPICKER_IMAGES                       (RID_FPICKER_START+17)
+#define STR_SVT_NEW_FOLDER                          (RID_FPICKER_START+19)
+#define STR_SVT_ALREADYEXISTOVERWRITE               (RID_FPICKER_START+20)
+#define RID_FILEOPEN_INVALIDFOLDER                  (RID_FPICKER_START+23)
+#define RID_FILEOPEN_NOTEXISTENTFILE                (RID_FPICKER_START+24)
+#define STR_SVT_NOREMOVABLEDEVICE                   (RID_FPICKER_START+25)
+#define STR_SVT_ALLFORMATS                          (RID_FPICKER_START+26)
+
+
+#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/fpicker/source/office/OfficeFilePicker.src b/fpicker/source/office/OfficeFilePicker.src
index 8fbbc35..dfc3253 100644
--- a/fpicker/source/office/OfficeFilePicker.src
+++ b/fpicker/source/office/OfficeFilePicker.src
@@ -25,7 +25,7 @@
  *
  ************************************************************************/
 
-#include "svtools/svtools.hrc"
+#include "OfficeFilePicker.hrc"
 
 String STR_SVT_FILEPICKER_AUTO_EXTENSION
 {
diff --git a/fpicker/source/office/PlaceEditDialog.cxx b/fpicker/source/office/PlaceEditDialog.cxx
index d7569b4..1ecdb59 100644
--- a/fpicker/source/office/PlaceEditDialog.cxx
+++ b/fpicker/source/office/PlaceEditDialog.cxx
@@ -26,87 +26,183 @@
  * instead of those above.
  */
 
-#include "iodlg.hrc"
-#include <svtools/svtools.hrc>
-#include <vcl/msgbox.hxx>
-
+#include "OfficeFilePicker.hrc"
+#include "PlaceEditDialog.hrc"
 #include "fpsofficeResMgr.hxx"
 #include "PlacesListBox.hxx"
 #include "PlaceEditDialog.hxx"
+#include "ServerDetailsControls.hxx"
 
+#include <vcl/msgbox.hxx>
+
+using namespace boost;
 
 PlaceEditDialog::PlaceEditDialog(	Window* pParent ) :
-	ModalDialog( pParent, SvtResId( DLG_SVT_ADDPLACE ) ),
-	m_aFTServerUrl( this, SvtResId( FT_ADDPLACE_SERVERURL ) ),
+	ModalDialog( pParent, SvtResId( DLG_FPICKER_PLACE_EDIT ) ),
     m_aFTServerName( this, SvtResId( FT_ADDPLACE_SERVERNAME ) ),
     m_aFTServerType( this, SvtResId( FT_ADDPLACE_SERVERTYPE ) ),
-    m_aFTServerLogin( this, SvtResId( FT_ADDPLACE_SERVERLOGIN ) ),
-    m_aFTServerPassword( this, SvtResId( FT_ADDPLACE_SERVERPASSWORD) ),
-	m_aEDServerUrl ( this, SvtResId( ED_ADDPLACE_SERVERURL ) ),
 	m_aEDServerName ( this, SvtResId( ED_ADDPLACE_SERVERNAME ) ),
-	m_aEDServerType ( this, SvtResId( ED_ADDPLACE_SERVERTYPE ) ),
-	m_aEDServerLogin ( this, SvtResId( ED_ADDPLACE_SERVERLOGIN ) ),
-	m_aEDServerPassword ( this, SvtResId( ED_ADDPLACE_SERVERPASSWORD ) ),
+	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_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 ) )
 {
-	// This constructor is called when user request a place creation, so
-	// delete button is hidden.
 	m_aBTOk.SetClickHdl( LINK( this, PlaceEditDialog, OKHdl) );
 	m_aBTOk.Enable( sal_False );
 
 	m_aEDServerName.SetModifyHdl( LINK( this, PlaceEditDialog, EditHdl) );
-	m_aEDServerUrl.SetModifyHdl( LINK( this, PlaceEditDialog, EditHdl) );
 
-	m_aEDServerUrl.SetUrlFilter( &m_UrlFilter );
-	Edit aDummyEdit ( this, SvtResId( ED_ADDPLACE_SERVERURL ) );
-	m_aEDServerUrl.SetPosSizePixel( aDummyEdit.GetPosPixel(), aDummyEdit.GetSizePixel() );
-	m_aEDServerUrl.Show();
+	// This constructor is called when user request a place creation, so
+	// delete button is hidden.
 	m_aBTDelete.Hide();
+
+    m_aLBServerType.SetSelectHdl( LINK( this, PlaceEditDialog, SelectTypeHdl ) );
+
+    InitDetails( );
 }
 
-PlaceEditDialog::PlaceEditDialog( Window* pParent, PlacePtr pPlace ) :
-	ModalDialog( pParent, SvtResId( DLG_SVT_ADDPLACE ) ),
-	m_aFTServerUrl( this, SvtResId( FT_ADDPLACE_SERVERURL ) ),
+PlaceEditDialog::PlaceEditDialog( Window* pParent, const PlacePtr& pPlace ) :
+	ModalDialog( pParent, SvtResId( DLG_FPICKER_PLACE_EDIT ) ),
     m_aFTServerName( this, SvtResId( FT_ADDPLACE_SERVERNAME ) ),
     m_aFTServerType( this, SvtResId( FT_ADDPLACE_SERVERTYPE ) ),
-    m_aFTServerLogin( this, SvtResId( FT_ADDPLACE_SERVERLOGIN ) ),
-    m_aFTServerPassword( this, SvtResId( FT_ADDPLACE_SERVERPASSWORD) ),
-	m_aEDServerUrl ( this, SvtResId( ED_ADDPLACE_SERVERURL ) ),
 	m_aEDServerName ( this, SvtResId( ED_ADDPLACE_SERVERNAME ) ),
-	m_aEDServerType ( this, SvtResId( ED_ADDPLACE_SERVERTYPE ) ),
-	m_aEDServerLogin ( this, SvtResId( ED_ADDPLACE_SERVERLOGIN ) ),
-	m_aEDServerPassword ( this, SvtResId( ED_ADDPLACE_SERVERPASSWORD ) ),
+	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_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 ) )
 {
-	m_aBTOk.SetClickHdl( LINK( this, PlaceEditDialog, OKHdl) );
-	m_aBTDelete.SetClickHdl ( LINK( this, PlaceEditDialog, DelHdl) );
+    m_aBTOk.SetClickHdl( LINK( this, PlaceEditDialog, OKHdl) );
+    m_aBTDelete.SetClickHdl ( LINK( this, PlaceEditDialog, DelHdl) );
 
-	m_aEDServerName.SetModifyHdl( LINK( this, PlaceEditDialog, EditHdl) );
-	m_aEDServerUrl.SetModifyHdl( LINK( this, PlaceEditDialog, EditHdl) );
+    m_aEDServerName.SetModifyHdl( LINK( this, PlaceEditDialog, EditHdl) );
+    m_aLBServerType.SetSelectHdl( LINK( this, PlaceEditDialog, SelectTypeHdl ) );
+
+    InitDetails( );
 
-	m_aEDServerUrl.SetUrlFilter( &m_UrlFilter );
-	Edit aDummyEdit ( this, SvtResId( ED_ADDPLACE_SERVERURL ) );
-	m_aEDServerUrl.SetPosSizePixel( aDummyEdit.GetPosPixel(), aDummyEdit.GetSizePixel() );
-	m_aEDServerUrl.Show();
+    m_aEDServerName.SetText( pPlace->GetName() );
 
-	m_aEDServerName.SetText( pPlace->GetName() );
-	m_aEDServerUrl.SetText( pPlace->GetUrl() );
+    // Fill the boxes with the URL parts
+    bool bSuccess = false;
+    for ( size_t i = 0 ; i < m_aDetailsContainers.size( ) && !bSuccess; ++i )
+    {
+        INetURLObject& rUrl = pPlace->GetUrlObject( );
+        bSuccess = m_aDetailsContainers[i]->setUrl( rUrl );
+        if ( bSuccess )
+        {
+            m_aLBServerType.SelectEntryPos( i );
+            SelectTypeHdl( &m_aLBServerType );
+
+            // Fill the Username field
+            if ( rUrl.HasUserData( ) )
+                m_aEDUsername.SetText( rUrl.GetUser( ) );
+        }
+    }
 }
 
 PlaceEditDialog::~PlaceEditDialog()
 {
 }
 
+rtl::OUString PlaceEditDialog::GetServerUrl()
+{
+    rtl::OUString sUrl;
+    if ( m_pCurrentDetails.get( ) )
+    {
+        INetURLObject aUrl = m_pCurrentDetails->getUrl();
+        aUrl.SetUser( rtl::OUString( m_aEDUsername.GetText( ) ).trim( ) );
+        if ( !aUrl.HasError( ) )
+            sUrl = aUrl.GetMainURL( INetURLObject::NO_DECODE );
+    }
+
+    return sUrl;
+}
+
 PlacePtr PlaceEditDialog::GetPlace()
 {
-	PlacePtr newPlace( new Place( m_aEDServerName.GetText(), m_aEDServerUrl.GetURL(), true) );
+	PlacePtr newPlace( new Place( m_aEDServerName.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 );
+    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 );
+    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 );
+    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 );
+    pSmbDetails->setChangeHdl( LINK( this, PlaceEditDialog, EditHdl ) );
+    m_aDetailsContainers.push_back( pSmbDetails );
+
+    // Set default to first value
+    m_aLBServerType.SelectEntryPos( 0 );
+    SelectTypeHdl( &m_aLBServerType );
+}
+
 IMPL_LINK ( PlaceEditDialog,  OKHdl, Button *, EMPTYARG )
 {
 	EndDialog( RET_OK );
@@ -120,24 +216,74 @@ IMPL_LINK ( PlaceEditDialog, DelHdl, Button *, EMPTYARG )
 	return 1;
 }
 
-IMPL_LINK ( PlaceEditDialog, EditHdl, Edit *, EMPTYARG )
+IMPL_LINK ( PlaceEditDialog, EditHdl, void *, EMPTYARG )
 {
-	String anUrl = m_aEDServerUrl.GetText();
-	anUrl.EraseLeadingChars().EraseTrailingChars();
-	String aName = m_aEDServerName.GetText();
-	aName.EraseLeadingChars().EraseTrailingChars();
-	if ( ( anUrl.Len() ) && ( aName.Len() ) )
-	{
-		if ( !m_aBTOk.IsEnabled() )
-			m_aBTOk.Enable( sal_True );
-	}
-	else
-	{
-		if ( m_aBTOk.IsEnabled() )
-			m_aBTOk.Enable( sal_False );
-	}
+    rtl::OUString sUrl = GetServerUrl( );
+    rtl::OUString sName = rtl::OUString( m_aEDServerName.GetText() ).trim( );
+    m_aBTOk.Enable( !sName.isEmpty( ) && !sUrl.isEmpty( ) );
 	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( );
+    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 );
+
+
+    return 0;
+}
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/fpicker/source/office/PlaceEditDialog.hrc b/fpicker/source/office/PlaceEditDialog.hrc
new file mode 100644
index 0000000..b22f3f9
--- /dev/null
+++ b/fpicker/source/office/PlaceEditDialog.hrc
@@ -0,0 +1,58 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * Version: MPL 1.1 / GPLv3+ / LGPLv3+
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License or as specified alternatively below. You may obtain a copy of
+ * the License at http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * Major Contributor(s):
+ * [ Copyright (C) 2012 SUSE <cbosdonnat at suse.com> (initial developer) ]
+ *
+ * All Rights Reserved.
+ *
+ * For minor contributions see the git repository.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+ * the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+ * in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+ * instead of those above.
+ */
+
+#ifndef _FPICKER_PLACEEDITDLG_HRC
+#define _FPICKER_PLACEEDITDLG_HRC
+
+#include <svl/solar.hrc>
+
+// DLG_FPICKER_PLACE_EDIT ------------------------------
+#define FT_ADDPLACE_SERVERNAME		  		    10
+#define FT_ADDPLACE_SERVERTYPE		  		    11
+#define ED_ADDPLACE_SERVERNAME		  		    12
+#define LB_ADDPLACE_SERVERTYPE		  		    13
+#define BT_ADDPLACE_OK				      		14
+#define BT_ADDPLACE_CANCEL		    			15
+#define BT_ADDPLACE_DELETE			    		16
+#define FT_ADDPLACE_HOST        	 		    17
+#define ED_ADDPLACE_HOST        	 		    18
+#define FT_ADDPLACE_PORT        	 		    19
+#define ED_ADDPLACE_PORT        	 		    20
+#define FT_ADDPLACE_PATH        	 		    21
+#define ED_ADDPLACE_PATH        	 		    22
+#define CB_ADDPLACE_DAVS        	 		    23
+#define FT_ADDPLACE_USERNAME                    24
+#define ED_ADDPLACE_USERNAME                    25
+#define ED_ADDPLACE_SMBHOST        	 		    26
+#define FT_ADDPLACE_SHARE       	 		    27
+#define ED_ADDPLACE_SHARE       	 		    28
+#define FT_ADDPLACE_SMBPATH        	 		    29
+#define ED_ADDPLACE_SMBPATH        	 		    30
+
+#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/fpicker/source/office/PlaceEditDialog.hxx b/fpicker/source/office/PlaceEditDialog.hxx
index 4c6bb28..68ee425 100644
--- a/fpicker/source/office/PlaceEditDialog.hxx
+++ b/fpicker/source/office/PlaceEditDialog.hxx
@@ -25,63 +25,89 @@
  * in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
  * instead of those above.
  */
-#ifndef _SVTPLACEDIALOG_HXX
-#define _SVTPLACEDIALOG_HXX
+#ifndef _PLACEEDITDIALOG_HXX
+#define _PLACEEDITDIALOG_HXX
 
+#include "fpsofficeResMgr.hxx"
 #include "PlacesListBox.hxx"
+#include "ServerDetailsControls.hxx"
 
 #include <vcl/button.hxx>
 #include <vcl/dialog.hxx>
-#include <vcl/fixed.hxx>
 #include <vcl/edit.hxx>
+#include <vcl/fixed.hxx>
+#include <vcl/lstbox.hxx>
 
 #include <svtools/inettbc.hxx>
 
-#include <svl/restrictedpaths.hxx>
+#include <boost/shared_ptr.hpp>
+#include <vector>
 
 class Place;
 class PlaceEditDialog : public ModalDialog
 {
 private :
 
-    FixedText m_aFTServerUrl;
     FixedText m_aFTServerName;
     FixedText m_aFTServerType;
-    FixedText m_aFTServerLogin;
-    FixedText m_aFTServerPassword;
-
-    SvtURLBox m_aEDServerUrl;
 
     Edit m_aEDServerName;
-    Edit m_aEDServerType;
-    Edit m_aEDServerLogin;
-    Edit m_aEDServerPassword;
-
+    ListBox m_aLBServerType;
+    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_aFTUsername;
+    Edit         m_aEDUsername;
     OKButton m_aBTOk;
     CancelButton m_aBTCancel;
 
     PushButton m_aBTDelete;
 
-	::svt::RestrictedPaths m_UrlFilter;
-
-	DECL_LINK( OKHdl, Button *);
-	DECL_LINK ( DelHdl, Button *);
+    /** Vector holding the details UI control for each server type.
 
-	DECL_LINK ( EditHdl, Edit *);
+        The elements in this vector need to match the order in the type listbox, e.g.
+        the m_aDetailsContainer[0] will be shown for the type corresponding to entry 0
+        in the listbox.
+      */
+    std::vector< boost::shared_ptr< DetailsContainer > > m_aDetailsContainers;
 
 public :
 
      PlaceEditDialog( Window* pParent);
-     PlaceEditDialog( Window* pParent, PlacePtr pPlace );
+     PlaceEditDialog( Window* pParent, const PlacePtr& pPlace );
      ~PlaceEditDialog();
 
      // Returns a place instance with given informations
      PlacePtr GetPlace();
 
      rtl::OUString GetServerName() 	{ return m_aEDServerName.GetText(); }
-     rtl::OUString GetServerUrl() 	{ return m_aEDServerUrl.GetText(); }
+     rtl::OUString GetServerUrl();
+
+     ResId GetResId( sal_uInt16 nId ) { return SvtResId( nId ); };
+
+private:
+
+    void InitDetails( );
+
+	DECL_LINK ( OKHdl, Button * );
+	DECL_LINK ( DelHdl, Button * );
+	DECL_LINK ( EditHdl, void * );
+    DECL_LINK ( SelectTypeHdl, void * );
 
 };
 
-#endif //_SVTPLACEDIALOG_HXX
+#endif //_PLACEEDITDIALOG_HXX
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/fpicker/source/office/PlaceEditDialog.src b/fpicker/source/office/PlaceEditDialog.src
new file mode 100644
index 0000000..15c614d
--- /dev/null
+++ b/fpicker/source/office/PlaceEditDialog.src
@@ -0,0 +1,183 @@
+
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * Version: MPL 1.1 / GPLv3+ / LGPLv3+
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License or as specified alternatively below. You may obtain a copy of
+ * the License at http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * Major Contributor(s):
+ * [ Copyright (C) 2012 SUSE <cbosdonnat at suse.com> (initial developer) ]
+ *
+ * All Rights Reserved.
+ *
+ * For minor contributions see the git repository.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+ * the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+ * in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+ * instead of those above.
+ */
+
+#include "PlaceEditDialog.hrc"
+#include "OfficeFilePicker.hrc"
+
+// Place Edit Dialog --------------------------------------------------------------
+
+ModalDialog DLG_FPICKER_PLACE_EDIT
+{
+    OutputSize = TRUE ;
+    Border = TRUE ;
+    SVLook = TRUE ;
+    Moveable = TRUE ;
+    Closeable = TRUE ;
+    Sizeable = TRUE;
+    Size = MAP_APPFONT ( 200 , 76 ) ;
+    FixedText FT_ADDPLACE_SERVERNAME
+    {
+        Pos = MAP_APPFONT ( 12 , 14 ) ;
+        Size = MAP_APPFONT ( 40 , 10 ) ;
+        Text [ en-US ] = "Name" ;
+    };
+    FixedText FT_ADDPLACE_SERVERTYPE
+    {
+        Pos = MAP_APPFONT ( 12 , 30 ) ;
+        Size = MAP_APPFONT ( 40 , 10 ) ;
+        Text [ en-US ] = "Type" ;
+    };
+    FixedText FT_ADDPLACE_HOST
+    {
+        Pos = MAP_APPFONT ( 12 , 46 ) ;
+        Size = MAP_APPFONT ( 40 , 10 ) ;
+        Text [ en-US ] = "Host" ;
+    };
+    Edit ED_ADDPLACE_HOST
+    {
+        Pos = MAP_APPFONT ( 55, 44 ) ;
+        Size = MAP_APPFONT ( 71 , 12 ) ;
+        Border = TRUE ;
+    };
+    FixedText FT_ADDPLACE_PORT
+    {
+        Pos = MAP_APPFONT ( 129 , 46 ) ;
+        Size = MAP_APPFONT ( 20 , 10 ) ;
+        Text [ en-US ] = "Port" ;
+    };
+    NumericField ED_ADDPLACE_PORT
+    {
+        Pos = MAP_APPFONT ( 152, 44 ) ;
+        Size = MAP_APPFONT ( 40 , 12 ) ;
+        Border = TRUE ;
+        Spin = TRUE ;
+        Minimum = 0 ;
+        Maximum = 65535 ;
+    };
+    FixedText FT_ADDPLACE_PATH
+    {
+        Pos = MAP_APPFONT ( 12 , 62 ) ;
+        Size = MAP_APPFONT ( 40 , 10 ) ;
+        Text [ en-US ] = "Path" ;
+    };
+    Edit ED_ADDPLACE_PATH
+    {
+        Pos = MAP_APPFONT ( 55, 60 ) ;
+        Size = MAP_APPFONT ( 137 , 12 ) ;
+        Border = TRUE ;
+    };
+    CheckBox CB_ADDPLACE_DAVS
+    {
+        Pos = MAP_APPFONT ( 55, 74 ) ;
+        Size = MAP_APPFONT ( 137 , 10 ) ;
+        Text[ en-US ] = "Secured WebDAV (HTTPS)" ;
+    };
+    Edit ED_ADDPLACE_SMBHOST
+    {
+        Pos = MAP_APPFONT ( 55, 44 ) ;
+        Size = MAP_APPFONT ( 137 , 12 ) ;
+        Border = TRUE ;
+    };
+    FixedText FT_ADDPLACE_SHARE
+    {
+        Pos = MAP_APPFONT ( 12 , 62 ) ;
+        Size = MAP_APPFONT ( 40 , 10 ) ;
+        Text [ en-US ] = "Share" ;
+    };
+    Edit ED_ADDPLACE_SHARE
+    {
+        Pos = MAP_APPFONT ( 55, 60 ) ;
+        Size = MAP_APPFONT ( 137 , 12 ) ;
+        Border = TRUE ;
+    };
+    FixedText FT_ADDPLACE_SMBPATH
+    {
+        Pos = MAP_APPFONT ( 12 , 78 ) ;
+        Size = MAP_APPFONT ( 40 , 10 ) ;
+        Text [ en-US ] = "Path" ;
+    };
+    Edit ED_ADDPLACE_SMBPATH
+    {
+        Pos = MAP_APPFONT ( 55, 76 ) ;
+        Size = MAP_APPFONT ( 137 , 12 ) ;
+        Border = TRUE ;
+    };
+    Edit ED_ADDPLACE_SERVERNAME
+    {
+        Pos = MAP_APPFONT ( 55, 12 ) ;
+        Size = MAP_APPFONT ( 137 , 12 ) ;
+        Border = TRUE ;
+    };
+    ListBox LB_ADDPLACE_SERVERTYPE
+    {
+        Pos = MAP_APPFONT ( 55, 28 ) ;
+        Size = MAP_APPFONT ( 137 , 75 ) ;
+        Border = TRUE ;
+        DropDown = TRUE;
+        StringList [ en-US ] =
+        {
+            < "WebDAV" ; >;
+            < "FTP" ; >;
+            < "SSH" ; >;
+            < "Windows Share" ; >;
+        };
+    };
+    FixedText FT_ADDPLACE_USERNAME
+    {
+        Pos = MAP_APPFONT ( 12 , 46 ) ;
+        Size = MAP_APPFONT ( 40 , 10 ) ;
+        Text [ en-US ] = "Login" ;
+    };
+    Edit ED_ADDPLACE_USERNAME
+    {
+        Pos = MAP_APPFONT ( 55, 44 ) ;
+        Size = MAP_APPFONT ( 137 , 12 ) ;
+        Border = TRUE ;
+    };
+    OKButton BT_ADDPLACE_OK
+    {
+        Pos = MAP_APPFONT ( 80 , 60 ) ;
+        Size = MAP_APPFONT ( 50 , 14 ) ;
+        DefButton = TRUE ;
+    };
+    CancelButton BT_ADDPLACE_CANCEL
+    {
+        Pos = MAP_APPFONT ( 140, 60 ) ;
+        Size = MAP_APPFONT ( 50 , 14 ) ;
+    };
+    PushButton BT_ADDPLACE_DELETE
+    {
+        Pos = MAP_APPFONT ( 10 , 60 ) ;
+        Size = MAP_APPFONT ( 50 , 14 ) ;
+        Text [ en-US ] = "Delete" ;
+    };
+};
+
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/fpicker/source/office/PlacesListBox.cxx b/fpicker/source/office/PlacesListBox.cxx
index 708b500..e6595c6 100644
--- a/fpicker/source/office/PlacesListBox.cxx
+++ b/fpicker/source/office/PlacesListBox.cxx
@@ -165,13 +165,14 @@ IMPL_LINK ( PlacesListBox, DoubleClick, void*, EMPTYARG )
 	PlacePtr pPlace = maPlaces[nSelected];
 	if ( pPlace->IsEditable() == true )
 	{
-		PlaceEditDialog aDlg(mpDlg,pPlace);
+		PlaceEditDialog aDlg( mpDlg, pPlace );
 		short aRetCode = aDlg.Execute();
 		switch(aRetCode) {
 			case RET_OK :
 			{
 				pPlace->SetName ( aDlg.GetServerName() );
 				pPlace->SetUrl( aDlg.GetServerUrl() );
+                mbUpdated = true;
 				break;
 			}
 			case RET_NO :
diff --git a/fpicker/source/office/PlacesListBox.hxx b/fpicker/source/office/PlacesListBox.hxx
index 16ba19a..30e4cc7 100644
--- a/fpicker/source/office/PlacesListBox.hxx
+++ b/fpicker/source/office/PlacesListBox.hxx
@@ -62,6 +62,7 @@ class Place
 
         rtl::OUString& GetName( ) { return msName; }
         rtl::OUString GetUrl( ) { return maUrl.GetMainURL( INetURLObject::NO_DECODE ); }
+        INetURLObject& GetUrlObject( ) { return maUrl; }
         sal_Bool  IsLocal( ) { return maUrl.GetProtocol() == INET_PROT_FILE; };
         sal_Bool& IsEditable( ) { return mbEditable; }
 };
diff --git a/fpicker/source/office/ServerDetailsControls.cxx b/fpicker/source/office/ServerDetailsControls.cxx
new file mode 100644
index 0000000..ca00481
--- /dev/null
+++ b/fpicker/source/office/ServerDetailsControls.cxx
@@ -0,0 +1,275 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * Version: MPL 1.1 / GPLv3+ / LGPLv3+
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License or as specified alternatively below. You may obtain a copy of
+ * the License at http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * Major Contributor(s):
+ * [ Copyright (C) 2012 SUSE <cbosdonnat at suse.com> (initial developer) ]
+ *
+ * All Rights Reserved.
+ *
+ * For minor contributions see the git repository.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+ * the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+ * in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+ * instead of those above.
+ */
+
+#include "PlaceEditDialog.hrc"
+
+#include "fpsofficeResMgr.hxx"
+#include "PlaceEditDialog.hxx"
+#include "ServerDetailsControls.hxx"
+
+using namespace std;
+
+DetailsContainer::DetailsContainer( ) :
+    m_aControls( ),
+    m_bShown( false )
+{
+}
+
+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 );
+    }
+}
+
+INetURLObject DetailsContainer::getUrl( )
+{
+    // Don't use that class directly: make it smarter by subclassing it.
+    return INetURLObject( );
+}
+
+bool DetailsContainer::setUrl( const INetURLObject& )
+{
+    // That class doesn't contain any logic... it defers the dirty work
+    // to the sub classes.
+    return false;
+}
+
+void DetailsContainer::notifyChange( )
+{
+    m_aChangeHdl.Call( this );
+}
+
+IMPL_LINK( DetailsContainer, ValueChangeHdl, void *, EMPTYARG )
+{
+    notifyChange( );
+    return 0;
+}
+
+HostDetailsContainer::HostDetailsContainer( sal_uInt16 nPort, rtl::OUString sScheme ) :
+    DetailsContainer( ),
+    m_nDefaultPort( nPort ),
+    m_sScheme( sScheme )
+{
+}
+
+void HostDetailsContainer::show( bool bShow )
+{
+    DetailsContainer::show( bShow );
+    if ( bShow )
+        static_cast< NumericField* >( getControl( ED_ADDPLACE_PORT ) )->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 sUrl;
+    if ( !sHost.isEmpty( ) )
+    {
+        sUrl = m_sScheme + "://" + sHost;
+        if ( nPort != m_nDefaultPort )
+            sUrl += ":" + rtl::OUString::valueOf( nPort );
+        if ( !sPath.isEmpty( ) )
+            if ( sPath.indexOf( "/" ) != 0 )
+                sUrl += "/";
+            sUrl += sPath;
+    }
+
+    return INetURLObject( sUrl );
+}
+
+bool HostDetailsContainer::setUrl( const INetURLObject& rUrl )
+{
+    bool bSuccess = false;
+
+    bSuccess = verifyScheme( INetURLObject::GetScheme( rUrl.GetProtocol( ) ) );
+
+    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() );
+    }
+
+    return bSuccess;
+}
+
+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 )
+{
+    DetailsContainer::addControl( nId, pControl );
+
+    // Add listener on CB_ADDPLACE_DAVS
+    if ( nId == CB_ADDPLACE_DAVS )
+        static_cast< CheckBox* >( pControl )->SetToggleHdl( LINK( this, DavDetailsContainer, ToggledDavsHdl ) );
+}
+
+void DavDetailsContainer::show( bool bShow )
+{
+    HostDetailsContainer::show( bShow );
+    if ( bShow )
+        static_cast< CheckBox* >( getControl( CB_ADDPLACE_DAVS ) )->Check( false );
+}
+
+bool DavDetailsContainer::verifyScheme( const rtl::OUString& rScheme )
+{
+    bool bValid = false;
+    if ( rScheme.equals( "http://" ) )
+    {
+        bValid = true;
+        static_cast< CheckBox* >( getControl( CB_ADDPLACE_DAVS ) )->Check( false );
+    }
+    else if ( rScheme.equals( "https://" ) )
+    {
+        bValid = true;
+        static_cast< CheckBox* >( getControl( CB_ADDPLACE_DAVS ) )->Check( true );
+    }
+    return bValid;
+}
+
+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 );
+
+    rtl::OUString sScheme( "http" );
+    if ( bCheckedDavs )
+        sScheme = "https";
+    setScheme( sScheme );
+
+    notifyChange( );
+
+    return 0;
+}
+
+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 sUrl;
+    if ( !sHost.isEmpty( ) )
+    {
+        INetURLObject aUrl;
+        sUrl = "smb://" + sHost + "/";
+        if ( !sShare.isEmpty( ) )
+            sUrl += sShare;
+        if ( !sPath.isEmpty( ) )
+            if ( sPath.indexOf( "/" ) != 0 )
+                sUrl += "/";
+            sUrl += sPath;
+    }
+
+    return INetURLObject( sUrl );
+}
+
+bool SmbDetailsContainer::setUrl( const INetURLObject& rUrl )
+{
+    bool bSuccess =  rUrl.GetProtocol() == INET_PROT_SMB;
+
+    if ( bSuccess )
+    {
+        rtl::OUString sShare = rUrl.getName( 0 );
+        rtl::OUString sFullPath = rUrl.GetURLPath( );
+        rtl::OUString sPath;
+        if ( sFullPath.getLength( ) > sShare.getLength( ) )
+        {
+            sal_Int32 nPos = sShare.getLength( );
+            if ( nPos != 0 )
+                ++nPos;
+            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 );
+    }
+
+    return bSuccess;
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/fpicker/source/office/ServerDetailsControls.hxx b/fpicker/source/office/ServerDetailsControls.hxx
new file mode 100644
index 0000000..aafcc0c
--- /dev/null
+++ b/fpicker/source/office/ServerDetailsControls.hxx
@@ -0,0 +1,123 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * Version: MPL 1.1 / GPLv3+ / LGPLv3+
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License or as specified alternatively below. You may obtain a copy of
+ * the License at http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * Major Contributor(s):
+ * [ Copyright (C) 2012 SUSE <cbosdonnat at suse.com> (initial developer) ]
+ *
+ * All Rights Reserved.
+ *
+ * For minor contributions see the git repository.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+ * the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+ * in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+ * instead of those above.
+ */
+#ifndef _SERVERDETAILSCONTROLS_HXX
+#define _SERVERDETAILSCONTROLS_HXX
+
+#include <tools/urlobj.hxx>
+#include <vcl/ctrl.hxx>
+#include <vcl/edit.hxx>
+#include <vcl/field.hxx>
+#include <vcl/fixed.hxx>
+
+class PlaceEditDialog;
+
+class DetailsContainer
+{
+    private:
+        std::map< sal_uInt16, Control* > m_aControls;
+        bool m_bShown;
+        Link m_aChangeHdl;
+
+    public:
+        DetailsContainer( );
+        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 );
+        virtual INetURLObject getUrl( );
+
+        /** Try to split the URL in the controls of that container.
+
+            \param sUrl the URL to split
+            \return true if the split worked, false otherwise.
+         */
+        virtual bool setUrl( const INetURLObject& rUrl );
+
+    protected:
+        void notifyChange( );
+
+    private:
+        DECL_LINK ( ValueChangeHdl, void * );
+};
+
+class HostDetailsContainer : public DetailsContainer
+{
+    private:
+        sal_uInt16 m_nDefaultPort;
+        rtl::OUString m_sScheme;
+
+    public:
+        HostDetailsContainer( sal_uInt16 nPort, rtl::OUString sScheme );
+        virtual ~HostDetailsContainer( ) { };
+
+        virtual void show( bool bShow = true );
+        virtual INetURLObject getUrl( );
+        virtual bool setUrl( const INetURLObject& rUrl );
+
+    protected:
+        void setScheme( rtl::OUString sScheme ) { m_sScheme = sScheme; }
+
+        /** Verifies that the schement split from the URL can be handled by
+            the container and set the proper controls accordingly if needed.
+          */
+        virtual bool verifyScheme( const rtl::OUString& rScheme );
+};
+
+class DavDetailsContainer : public HostDetailsContainer
+{
+    public:
+        DavDetailsContainer( );
+        ~DavDetailsContainer( ) { };
+
+        virtual void addControl( sal_uInt16 nId, Control* pControl );
+        virtual void show( bool bShow = true );
+
+    protected:
+        virtual bool verifyScheme( const rtl::OUString& rScheme );
+
+    private:
+        DECL_LINK ( ToggledDavsHdl, CheckBox * pCheckBox );
+};
+
+class SmbDetailsContainer : public DetailsContainer
+{
+    public:
+        SmbDetailsContainer( ) : DetailsContainer( ) { };
+        ~SmbDetailsContainer( ) { };
+
+        virtual INetURLObject getUrl( );
+        virtual bool setUrl( const INetURLObject& rUrl );
+};
+
+#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/fpicker/source/office/iodlg.cxx b/fpicker/source/office/iodlg.cxx
index 64797c5..4de4a0c 100644
--- a/fpicker/source/office/iodlg.cxx
+++ b/fpicker/source/office/iodlg.cxx
@@ -52,8 +52,9 @@
 #include <toolkit/helper/vclunohelper.hxx>
 #include <unotools/localfilehelper.hxx>
 
-#include "svtools/svtools.hrc"
 #include "svtools/helpid.hrc"
+#include <svtools/svtools.hrc>
+#include "OfficeFilePicker.hrc"
 #include "iodlg.hrc"
 #include "asyncfilepicker.hxx"
 #include "iodlgimp.hxx"
@@ -398,7 +399,7 @@ SvtFileDialog::SvtFileDialog
     WinBits nBits,
     WinBits nExtraBits
 ) :
-    ModalDialog( _pParent, SvtResId( DLG_SVT_EXPLORERFILE ) )
+    ModalDialog( _pParent, SvtResId( DLG_FPICKER_EXPLORERFILE ) )
 
     ,_pUserControls( NULL )
     ,_pCbReadOnly( NULL )
@@ -423,7 +424,7 @@ SvtFileDialog::SvtFileDialog
 //*****************************************************************************
 
 SvtFileDialog::SvtFileDialog ( Window* _pParent, WinBits nBits )
-    :ModalDialog( _pParent, SvtResId( DLG_SVT_EXPLORERFILE ) )
+    :ModalDialog( _pParent, SvtResId( DLG_FPICKER_EXPLORERFILE ) )
     ,_pUserControls( NULL )
     ,_pCbReadOnly( NULL )
     ,_pCbLinkBox( NULL)
@@ -2164,7 +2165,7 @@ short SvtFileDialog::PrepareExecute()
 
     // set up initial filter
     sal_uInt16 nFilterCount = GetFilterCount();
-    String aAll( SvtResId( STR_FILTERNAME_ALL ) );
+    rtl::OUString aAll = SvtResId( STR_FILTERNAME_ALL ).toString();
     sal_Bool bHasAll = _pImp->HasFilterListEntry( aAll );
     if ( _pImp->GetCurFilter() || nFilterCount == 1 || ( nFilterCount == 2 && bHasAll ) )
     {
@@ -2178,7 +2179,7 @@ short SvtFileDialog::PrepareExecute()
                 nPos = nFilterCount;
                 while ( nPos-- )
                 {
-                    if ( GetFilterName( nPos ) != aAll )
+                    if ( aAll != rtl::OUString( GetFilterName( nPos ) ) )
                         break;
                 }
             }
@@ -3370,7 +3371,7 @@ QueryFolderNameDialog::QueryFolderNameDialog
     const String& rDefaultText,
     String* pGroupName
 ) :
-    ModalDialog( _pParent, SvtResId( DLG_SVT_QUERYFOLDERNAME ) ),
+    ModalDialog( _pParent, SvtResId( DLG_FPICKER_QUERYFOLDERNAME ) ),
 
     aNameText   ( this, SvtResId( FT_SVT_QUERYFOLDERNAME_DLG_NAME ) ),
     aNameEdit   ( this, SvtResId( ED_SVT_QUERYFOLDERNAME_DLG_NAME ) ),
diff --git a/fpicker/source/office/iodlg.hrc b/fpicker/source/office/iodlg.hrc
index 3e089fc..94a127f 100644
--- a/fpicker/source/office/iodlg.hrc
+++ b/fpicker/source/office/iodlg.hrc
@@ -28,7 +28,6 @@
 #ifndef _SVTOOLS_IODLGIMPL_HRC
 #define _SVTOOLS_IODLGIMPL_HRC
 
-#include "svtools/svtools.hrc"
 #include "svtools/helpid.hrc"
 
 // ModalDialog DLG_SVT_EXPLORERFILE
@@ -78,22 +77,6 @@
 #define STR_DEFAULT_DIRECTORY     			9
 #define STR_PLACES_TITLE         			10
 
-// DLG_SVT_ADDPLACE ------------------------------
-
-#define FT_ADDPLACE_SERVERURL			    10
-#define FT_ADDPLACE_SERVERNAME		  		11
-#define FT_ADDPLACE_SERVERTYPE		  		12
-#define FT_ADDPLACE_SERVERLOGIN			  	13
-#define FT_ADDPLACE_SERVERPASSWORD	 		14
-#define ED_ADDPLACE_SERVERURL		        15
-#define ED_ADDPLACE_SERVERNAME		  		16
-#define ED_ADDPLACE_SERVERTYPE		  		17
-#define ED_ADDPLACE_SERVERLOGIN			  	18
-#define ED_ADDPLACE_SERVERPASSWORD			19
-#define BT_ADDPLACE_OK				      		20
-#define BT_ADDPLACE_CANCEL		    			21
-#define BT_ADDPLACE_DELETE			    		22
-
 // DLG_SVT_QUERYFOLDERNAME -----------------------
 
 #define FT_SVT_QUERYFOLDERNAME_DLG_NAME     10
diff --git a/fpicker/source/office/iodlg.src b/fpicker/source/office/iodlg.src
index 881b741..0c78837 100644
--- a/fpicker/source/office/iodlg.src
+++ b/fpicker/source/office/iodlg.src
@@ -26,9 +26,10 @@
  ************************************************************************/
 
  // includes ******************************************************************
-#include "svtools/svtools.hrc"
 #include "svtools/helpid.hrc"
+#include "svtools/svtools.hrc"
 #include "iodlg.hrc"
+#include "OfficeFilePicker.hrc"
 
 #define FILEPICKER_IL_IDLIST \
     IdList = \
@@ -57,7 +58,7 @@ ImageList RID_FILEPICKER_IMAGES
 
  // dialogs *******************************************************************
 
-ModalDialog DLG_SVT_EXPLORERFILE
+ModalDialog DLG_FPICKER_EXPLORERFILE
 {
     OutputSize = TRUE ;
     SVLook = TRUE ;
@@ -255,112 +256,9 @@ ModalDialog DLG_SVT_EXPLORERFILE
     };
 };
 
-// Add Place Dialog --------------------------------------------------------------
-
-ModalDialog DLG_SVT_ADDPLACE
-{
-    OutputSize = TRUE ;
-    Border = TRUE ;
-    SVLook = TRUE ;
-    Moveable = TRUE ;
-    Closeable = TRUE ;
-    Sizeable = TRUE;
-    HelpId = HID_EXPLORERDLG_FILE ;
-    Size = MAP_APPFONT ( 200 , 140 ) ;
-    FixedText FT_ADDPLACE_SERVERURL
-    {
-        Pos = MAP_APPFONT ( 12 , 14 ) ;
-        Size = MAP_APPFONT ( 40 , 10 ) ;
-        Text [ en-US ] = "Server Url" ;
-    };
-    FixedText FT_ADDPLACE_SERVERNAME
-    {
-        Pos = MAP_APPFONT ( 12 , 34 ) ;
-        Size = MAP_APPFONT ( 40 , 10 ) ;
-        Text [ en-US ] = "Server Name" ;
-    };
-    FixedText FT_ADDPLACE_SERVERTYPE
-    {
-        Pos = MAP_APPFONT ( 12 , 54 ) ;
-        Size = MAP_APPFONT ( 40 , 10 ) ;
-        Text [ en-US ] = "Type" ;
-    };
-    FixedText FT_ADDPLACE_SERVERLOGIN
-    {
-        Pos = MAP_APPFONT ( 12 , 74 ) ;
-        Size = MAP_APPFONT ( 30 , 10 ) ;
-        Text [ en-US ] = "Login" ;
-    };
-    FixedText FT_ADDPLACE_SERVERPASSWORD
-    {
-        Pos = MAP_APPFONT ( 12 , 94 ) ;
-        Size = MAP_APPFONT ( 40 , 10 ) ;
-        Text [ en-US ] = "Password" ;
-    };
-    Edit ED_ADDPLACE_SERVERURL
-    {
-        //HelpID = "fpicker:Edit:DLG_SVT_QUERYFOLDERNAME:ED_SVT_QUERYFOLDERNAME_DLG_NAME";
-        Pos = MAP_APPFONT ( 62, 12 ) ;
-        Size = MAP_APPFONT ( 130 , 12 ) ;
-        Border = TRUE ;
-        //Left = TRUE ;
-    };
-    Edit ED_ADDPLACE_SERVERNAME
-    {
-        //HelpID = "fpicker:Edit:DLG_SVT_QUERYFOLDERNAME:ED_SVT_QUERYFOLDERNAME_DLG_NAME";
-        Pos = MAP_APPFONT ( 62, 32 ) ;
-        Size = MAP_APPFONT ( 130 , 12 ) ;
-        Border = TRUE ;
-        //Left = TRUE ;
-    };
-    Edit ED_ADDPLACE_SERVERTYPE
-    {
-        //HelpID = "fpicker:Edit:DLG_SVT_QUERYFOLDERNAME:ED_SVT_QUERYFOLDERNAME_DLG_NAME";
-        Pos = MAP_APPFONT ( 62, 52 ) ;
-        Size = MAP_APPFONT ( 130 , 12 ) ;
-        Border = TRUE ;
-        //Left = TRUE ;
-    };
-    Edit ED_ADDPLACE_SERVERLOGIN
-    {
-        //HelpID = "fpicker:Edit:DLG_SVT_QUERYFOLDERNAME:ED_SVT_QUERYFOLDERNAME_DLG_NAME";
-        Pos = MAP_APPFONT ( 62, 72 ) ;
-        Size = MAP_APPFONT ( 130 , 12 ) ;
-        Border = TRUE ;
-        //Left = TRUE ;
-    };
-    Edit ED_ADDPLACE_SERVERPASSWORD
-    {
-        //HelpID = "fpicker:Edit:DLG_SVT_QUERYFOLDERNAME:ED_SVT_QUERYFOLDERNAME_DLG_NAME";
-        Pos = MAP_APPFONT ( 62, 92 ) ;
-        Size = MAP_APPFONT ( 130 , 12 ) ;
-        Border = TRUE ;
-        //Left = TRUE ;
-    };
-    OKButton BT_ADDPLACE_OK
-    {
-        Pos = MAP_APPFONT ( 80 , 120 ) ;
-        Size = MAP_APPFONT ( 50 , 14 ) ;
-        DefButton = TRUE ;
-    };
-    CancelButton BT_ADDPLACE_CANCEL
-    {
-        Pos = MAP_APPFONT ( 140, 120 ) ;
-        Size = MAP_APPFONT ( 50 , 14 ) ;
-    };
-    PushButton BT_ADDPLACE_DELETE
-    {
-        //HelpID = "fpicker:PushButton:DLG_SVT_EXPLORERFILE:BTN_EXPLORERFILE_CONNECT_TO_SERVER";
-        Pos = MAP_APPFONT ( 10 , 120 ) ;
-        Size = MAP_APPFONT ( 50 , 14 ) ;
-        Text [ en-US ] = "Delete" ;
-        //QuickHelpText [ en-US ] = "Connect To Server" ;
-    };
-};
-
 // QueryFolderNameDialog ----------------------------------------------------------
 
-ModalDialog DLG_SVT_QUERYFOLDERNAME
+ModalDialog DLG_FPICKER_QUERYFOLDERNAME
 {
     HelpID = "fpicker:ModalDialog:DLG_SVT_QUERYFOLDERNAME";
     Border = TRUE ;
diff --git a/fpicker/source/win32/misc/resourceprovider.cxx b/fpicker/source/win32/misc/resourceprovider.cxx
index 629d195..6fb8e17 100644
--- a/fpicker/source/win32/misc/resourceprovider.cxx
+++ b/fpicker/source/win32/misc/resourceprovider.cxx
@@ -40,7 +40,7 @@
 #include <com/sun/star/ui/dialogs/CommonFilePickerElementIds.hpp>
 #include <com/sun/star/ui/dialogs/ExtendedFilePickerElementIds.hpp>
 
-#include <svtools/svtools.hrc>
+#include "fpicker.hrc"
 
 //------------------------------------------------------------
 // namespace directives
diff --git a/svl/inc/svl/solar.hrc b/svl/inc/svl/solar.hrc
index 3dc3363..2131d52 100644
--- a/svl/inc/svl/solar.hrc
+++ b/svl/inc/svl/solar.hrc
@@ -78,7 +78,10 @@
 #define RID_EDIT_START              (RID_LIB_START+5800)
 #define RID_EDIT_END                (RID_LIB_START+6369)
 
-#define RID_SVTOOLS_START           (RID_LIB_START+6370)
+#define RID_FPICKER_START           (RID_LIB_START+6370)
+#define RID_FPICKER_END             (RID_LIB_START+6389)
+
+#define RID_SVTOOLS_START           (RID_LIB_START+6390)
 #define RID_SVTOOLS_END             (RID_LIB_START+6499)
 
 #define RID_INET_START              (RID_LIB_START+6500)
diff --git a/svtools/inc/svtools/svtools.hrc b/svtools/inc/svtools/svtools.hrc
index 64c988b..de48b12 100644
--- a/svtools/inc/svtools/svtools.hrc
+++ b/svtools/inc/svtools/svtools.hrc
@@ -32,18 +32,12 @@
 #define RID_SVTOOLS_BITMAP_START        (RID_SVTOOLS_START + 0)
 #define RID_SVTOOLS_IMAGELIST_START     (RID_SVTOOLS_START + 0)
 
-//#define ABOUT_STR_COPYRIGHT             (RID_SVTOOLS_START + 1)
-//#define ABOUT_STR_DEVELOPER_ARY         (RID_SVTOOLS_START + 2)
-
 //.............................................................................
 // various unsorted stuff
 
 #define DLG_TWAIN_SOURCE                (RID_SVTOOLS_START+3)
 
-#define DLG_SVT_EXPLORERFILE            (RID_SVTOOLS_START+4)
-#define DLG_SVT_QUERYFOLDERNAME         (RID_SVTOOLS_START+5)
 #define DLG_SVT_QUERYDELETE             (RID_SVTOOLS_START+6)
-#define DLG_SVT_ADDPLACE			          (RID_SVTOOLS_START+7)
 
 #define STR_SVT_AUTOMATIC_COLOR         (RID_SVTOOLS_START+16)
 
@@ -56,15 +50,9 @@
 #define STR_SVT_KB                      (RID_SVTOOLS_START + 26)
 #define STR_SVT_MB                      (RID_SVTOOLS_START + 27)
 #define STR_SVT_GB                      (RID_SVTOOLS_START + 28)
-#define STR_FILTERNAME_ALL              (RID_SVTOOLS_START + 29)
-#define STR_SVT_NEW_FOLDER              (RID_SVTOOLS_START + 30)
-#define STR_SVT_ALREADYEXISTOVERWRITE   (RID_SVTOOLS_START + 31)
-#define STR_SVT_FILEVIEW_COLUMN_TYPE    (RID_SVTOOLS_START + 32)
-#define RID_FILEVIEW_CONTEXTMENU        (RID_SVTOOLS_START + 33)
-#define RID_FILEOPEN_INVALIDFOLDER      (RID_SVTOOLS_START + 34)
-#define RID_FILEOPEN_NOTEXISTENTFILE    (RID_SVTOOLS_START + 35)
-#define STR_SVT_NOREMOVABLEDEVICE       (RID_SVTOOLS_START + 36)
-#define STR_SVT_ALLFORMATS              (RID_SVTOOLS_START + 37)
+#define STR_SVT_FILEVIEW_COLUMN_TYPE    (RID_SVTOOLS_START + 29)
+#define STR_FILTERNAME_ALL              (RID_SVTOOLS_START + 30)
+#define RID_FILEVIEW_CONTEXTMENU        (RID_SVTOOLS_START + 31)
 
 // doc template dialog
 #define DLG_DOCTEMPLATE                 (RID_SVTOOLS_START+50)
@@ -225,25 +213,8 @@
 #define STR_SVT_COLLATE_PHONETIC_L          (STR_SVT_COLLATE_START+11)
 #define STR_SVT_COLLATE_END                 (STR_SVT_COLLATE_PHONETIC_L)
 
-#define STR_SVT_FILEPICKER_START                    (STR_SVT_COLLATE_END+1)
-#define STR_SVT_FILEPICKER_AUTO_EXTENSION           (STR_SVT_FILEPICKER_START+ 0)
-#define STR_SVT_FILEPICKER_PASSWORD                 (STR_SVT_FILEPICKER_START+ 1)
-#define STR_SVT_FILEPICKER_FILTER_OPTIONS           (STR_SVT_FILEPICKER_START+ 2)
-#define STR_SVT_FILEPICKER_READONLY                 (STR_SVT_FILEPICKER_START+ 3)
-#define STR_SVT_FILEPICKER_INSERT_AS_LINK           (STR_SVT_FILEPICKER_START+ 4)
-#define STR_SVT_FILEPICKER_SHOW_PREVIEW             (STR_SVT_FILEPICKER_START+ 5)
-#define STR_SVT_FILEPICKER_PLAY                     (STR_SVT_FILEPICKER_START+ 6)
-#define STR_SVT_FILEPICKER_VERSION                  (STR_SVT_FILEPICKER_START+ 7)
-#define STR_SVT_FILEPICKER_TEMPLATES                (STR_SVT_FILEPICKER_START+ 8)
-#define STR_SVT_FILEPICKER_IMAGE_TEMPLATE           (STR_SVT_FILEPICKER_START+ 9)
-#define STR_SVT_FILEPICKER_SELECTION                (STR_SVT_FILEPICKER_START+10)
-#define STR_SVT_FILEPICKER_FILTER_TITLE             (STR_SVT_FILEPICKER_START+11)
-#define STR_SVT_FOLDERPICKER_DEFAULT_TITLE          (STR_SVT_FILEPICKER_START+12)
-#define STR_SVT_FOLDERPICKER_DEFAULT_DESCRIPTION    (STR_SVT_FILEPICKER_START+13)
-#define STR_SVT_FILEPICKER_END                      (STR_SVT_FOLDERPICKER_DEFAULT_DESCRIPTION)
-
 // String-Ids for accessibility
-#define STR_SVT_ACC_BEGIN                   (STR_SVT_FILEPICKER_END+1)
+#define STR_SVT_ACC_BEGIN                   (STR_SVT_COLLATE_END+1)
 #define STR_SVT_TOOL_PANEL_BUTTON_FWD       (STR_SVT_ACC_BEGIN+0)
 #define STR_SVT_TOOL_PANEL_BUTTON_BACK      (STR_SVT_ACC_BEGIN+1)
 #define STR_SVT_ACC_DESC_TABLISTBOX         (STR_SVT_ACC_BEGIN+2)
@@ -255,7 +226,7 @@
 #define STR_SVT_ACC_LISTENTRY_SELCTED_STATE     (STR_SVT_ACC_BEGIN+7)
 #define STR_SVT_ACC_RULER_VERT_NAME (STR_SVT_ACC_BEGIN+8)
 #define STR_SVT_ACC_RULER_HORZ_NAME (STR_SVT_ACC_BEGIN+9)
-#define STR_SVT_ACC_END                     (STR_SVT_ACC_EMPTY_FIELD)
+#define STR_SVT_ACC_END                     (STR_SVT_ACC_RULER_HORZ_NAME)
 
 #define STR_SVT_INDEXENTRY_START            (STR_SVT_ACC_END + 1)
 #define STR_SVT_INDEXENTRY_ALPHANUMERIC     (STR_SVT_INDEXENTRY_START+0)
@@ -317,7 +288,6 @@
 #define RID_SVTOOLS_IMAGELIST_BIG                   (RID_SVTOOLS_IMAGELIST_START +  1)
 #define RID_SVTOOLS_IMAGELIST_SMALL                 (RID_SVTOOLS_IMAGELIST_START +  2)
 #define RID_SVTOOLS_IMAGELIST_EDITBROWSEBOX         (RID_SVTOOLS_IMAGELIST_START +  3)
-#define RID_FILEPICKER_IMAGES                       (RID_SVTOOLS_IMAGELIST_START +  7)
 
 //.............................................................................
 // error boxes
diff --git a/vcl/unx/kde/UnxFilePicker.cxx b/vcl/unx/kde/UnxFilePicker.cxx
index 3c29047..0bb0451 100644
--- a/vcl/unx/kde/UnxFilePicker.cxx
+++ b/vcl/unx/kde/UnxFilePicker.cxx
@@ -44,7 +44,7 @@
 #include <rtl/bootstrap.hxx>
 #include <tools/resmgr.hxx>
 
-#include <svtools/svtools.hrc>
+#include <fpicker/fpicker.hrc>
 #include <UnxFilePicker.hxx>
 #include <UnxCommandThread.hxx>
 #include <UnxNotifyThread.hxx>
diff --git a/vcl/unx/kde4/KDE4FilePicker.cxx b/vcl/unx/kde4/KDE4FilePicker.cxx
index 2388c13..140af9c 100644
--- a/vcl/unx/kde4/KDE4FilePicker.cxx
+++ b/vcl/unx/kde4/KDE4FilePicker.cxx
@@ -39,7 +39,7 @@
 #include <com/sun/star/ui/dialogs/ControlActions.hpp>
 #include <com/sun/star/ui/dialogs/ExecutableDialogResults.hpp>
 
-#include <svtools/svtools.hrc>
+#include <fpicker/fpicker.hrc>
 
 #include <osl/mutex.hxx>
 


More information about the Libreoffice-commits mailing list