Kaydet (Commit) 5e301969 authored tarafından Martin Richard's avatar Martin Richard Kaydeden (comit) Cédric Bosdonnat

fpicker: a list of bookmarks in the file picker

under dual licences MPLv1+/LGPLv3+

Authors:
  Martin Richard <martius@martiusweb.net>
  Julien Levesy <jlevesy@gmail.com>
üst 149650b0
...@@ -60,6 +60,8 @@ $(eval $(call gb_Library_add_exception_objects,fps_office,\ ...@@ -60,6 +60,8 @@ $(eval $(call gb_Library_add_exception_objects,fps_office,\
fpicker/source/office/OfficeControlAccess \ fpicker/source/office/OfficeControlAccess \
fpicker/source/office/OfficeFilePicker \ fpicker/source/office/OfficeFilePicker \
fpicker/source/office/OfficeFolderPicker \ fpicker/source/office/OfficeFolderPicker \
fpicker/source/office/PlacesListBox \
fpicker/source/office/SvtPlaceDialog \
)) ))
# vim: set noet sw=4 ts=4: # vim: set noet sw=4 ts=4:
/* -*- 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) 2011 Cedric Bosdonnat <cbosdonnat@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 <iodlg.hrc>
#include <PlacesListBox.hxx>
#include "SvtPlaceDialog.hxx"
#include <vcl/msgbox.hxx>
#include <svtools/svtdata.hxx>
namespace css = com::sun::star;
using rtl::OUString;
PlacesListBox::PlacesListBox( SvtFileDialog* pFileDlg, const ResId& rResId ) :
ListBox( pFileDlg, rResId ),
maPlaces( ),
mpDlg( pFileDlg ),
mnNbEditables( 0 ),
mbUpdated( false )
{
SetSelectHdl( LINK( this, PlacesListBox, SelectHdl ) );
SetDoubleClickHdl( LINK( this, PlacesListBox, DoubleClickHdl ) ) ;
}
PlacesListBox::~PlacesListBox( )
{
}
void PlacesListBox::AppendPlace( PlacePtr pPlace )
{
maPlaces.push_back( pPlace );
InsertEntry( pPlace->GetName( ), getEntryIcon( pPlace->GetType( ) ));
if(pPlace->IsEditable()) {
++mnNbEditables;
mbUpdated = true;
}
}
sal_Int32 PlacesListBox::GetNbPlaces() {
return maPlaces.size();
}
sal_Int32 PlacesListBox::GetNbEditablePlaces() {
return mnNbEditables;
}
bool PlacesListBox::IsUpdated() {
if(mbUpdated) {
mbUpdated = false;
return true;
}
return false;
}
const std::vector<PlacePtr>& PlacesListBox::GetPlaces() {
return maPlaces;
}
void PlacesListBox::RemovePlace( sal_uInt16 nPos )
{
if ( nPos < maPlaces.size() )
{
if(maPlaces[nPos]->IsEditable()) {
--mnNbEditables;
mbUpdated = true;
}
maPlaces.erase( maPlaces.begin() + nPos );
RemoveEntry( nPos );
}
}
void PlacesListBox::RemoveSelectedPlace() {
RemovePlace(GetSelectEntryPos());
}
Image PlacesListBox::getEntryIcon(Place::ePlaceType aType)
{
Image theImage;
switch (aType) {
case Place::e_PlaceCmis:
theImage = mpDlg->GetButtonImage( IMG_FILEDLG_BTN_UP );
break;
case Place::e_PlaceFtp:
theImage = mpDlg->GetButtonImage( IMG_FILEDLG_BTN_UP );
break;
case Place::e_PlaceLocal:
default:
theImage = mpDlg->GetButtonImage( IMG_FILEDLG_BTN_UP );
break;
};
return theImage;
}
IMPL_LINK( PlacesListBox, SelectHdl, ListBox* , EMPTYARG )
{
sal_uInt16 nSelected = GetSelectEntryPos();
PlacePtr pPlace = maPlaces[nSelected];
mpDlg->OpenURL_Impl( pPlace->GetUrl() );
if(pPlace->IsEditable())
mpDlg->RemovablePlaceSelected();
else
mpDlg->RemovablePlaceSelected(false);
return 0;
}
IMPL_LINK ( PlacesListBox, DoubleClickHdl, ListBox*, EMPTYARG )
{
sal_uInt16 nSelected = GetSelectEntryPos();
PlacePtr pPlace = maPlaces[nSelected];
if ( pPlace->IsEditable() == true )
{
SvtPlaceDialog aDlg(mpDlg,pPlace);
short aRetCode = aDlg.Execute();
switch(aRetCode) {
case RET_OK :
{
pPlace->SetName ( aDlg.GetServerName() );
pPlace->SetUrl( aDlg.GetServerUrl() );
break;
}
case RET_NO :
{
RemovePlace(nSelected);
break;
}
default:
break;
};
}
return 0;
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* -*- 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) 2011 Cedric Bosdonnat <cbosdonnat@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 _PLACESLISTBOX_HXX_
#define _PLACESLISTBOX_HXX_
#include <iodlg.hxx>
#include <vcl/lstbox.hxx>
#include <boost/shared_ptr.hpp>
#include <vector>
/** Class representing a file location: it mainly consist of display attributes and a URL.
*/
class Place
{
public:
enum ePlaceType {
e_PlaceLocal = 0,
e_PlaceFtp,
e_PlaceCmis
};
private:
rtl::OUString msName;
rtl::OUString msUrl;
ePlaceType meType;
sal_Bool mbEditable;
public:
Place( rtl::OUString sName, rtl::OUString sUrl, ePlaceType eType, sal_Bool bEditable = false) :
msName( sName ),
msUrl( sUrl ),
meType( eType ),
mbEditable( bEditable ) {};
~Place( ) {};
Place( const Place& rCopy ) : msName( rCopy.msName ), msUrl( rCopy.msUrl ), meType( rCopy.meType ){ };
void SetName(const rtl::OUString& aName ) { msName = aName; }
void SetUrl(const rtl::OUString& aUrl ) { msUrl = aUrl; }
rtl::OUString& GetName( ) { return msName; }
rtl::OUString& GetUrl( ) { return msUrl; }
ePlaceType& GetType( ) { return meType; }
sal_Bool& IsEditable( ) { return mbEditable; }
};
typedef boost::shared_ptr< Place > PlacePtr;
/** ListBox to handle Places.
*/
class PlacesListBox : public ListBox
{
private:
std::vector< PlacePtr > maPlaces;
SvtFileDialog* mpDlg;
sal_Int32 mnNbEditables;
bool mbUpdated;
public:
PlacesListBox( SvtFileDialog* pFileDlg, const ResId& rResId );
~PlacesListBox( );
void AppendPlace( PlacePtr pPlace );
void RemovePlace( sal_uInt16 nPos );
void RemoveSelectedPlace();
sal_Int32 GetNbPlaces();
sal_Int32 GetNbEditablePlaces();
bool IsUpdated();
const std::vector<PlacePtr>& GetPlaces();
private:
Image getEntryIcon( Place::ePlaceType eType);
DECL_LINK( SelectHdl, ListBox* );
DECL_LINK( DoubleClickHdl, ListBox* );
};
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* -*- 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 Julien Levesy <jlevesy@gmail.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 "iodlg.hrc"
#include <svtools/svtools.hrc>
#include <vcl/msgbox.hxx>
#include "fpsofficeResMgr.hxx"
#include "PlacesListBox.hxx"
#include "SvtPlaceDialog.hxx"
SvtPlaceDialog::SvtPlaceDialog( Window* pParent ) :
ModalDialog( pParent, SvtResId( DLG_SVT_ADDPLACE ) ),
m_aFTServerUrl( this, SvtResId( FT_ADDPLACE_SERVERURL ) ),
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_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, SvtPlaceDialog, OKHdl) );
m_aBTOk.Enable( sal_False );
m_aEDServerName.SetModifyHdl( LINK( this, SvtPlaceDialog, EditHdl) );
m_aEDServerUrl.SetModifyHdl( LINK( this, SvtPlaceDialog, EditHdl) );
m_aEDServerUrl.SetUrlFilter( &m_UrlFilter );
Edit aDummyEdit ( this, SvtResId( ED_ADDPLACE_SERVERURL ) );
m_aEDServerUrl.SetPosSizePixel( aDummyEdit.GetPosPixel(), aDummyEdit.GetSizePixel() );
m_aEDServerUrl.Show();
m_aBTDelete.Hide();
}
SvtPlaceDialog::SvtPlaceDialog( Window* pParent, PlacePtr pPlace ) :
ModalDialog( pParent, SvtResId( DLG_SVT_ADDPLACE ) ),
m_aFTServerUrl( this, SvtResId( FT_ADDPLACE_SERVERURL ) ),
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_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, SvtPlaceDialog, OKHdl) );
m_aBTDelete.SetClickHdl ( LINK( this, SvtPlaceDialog, DelHdl) );
m_aEDServerName.SetModifyHdl( LINK( this, SvtPlaceDialog, EditHdl) );
m_aEDServerUrl.SetModifyHdl( LINK( this, SvtPlaceDialog, EditHdl) );
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_aEDServerUrl.SetText( pPlace->GetUrl() );
}
SvtPlaceDialog::~SvtPlaceDialog()
{
}
PlacePtr SvtPlaceDialog::GetPlace()
{
PlacePtr newPlace( new Place( m_aEDServerName.GetText(), m_aEDServerUrl.GetURL(), Place::e_PlaceLocal, true) );
return newPlace;
}
IMPL_LINK ( SvtPlaceDialog, OKHdl, Button *, EMPTYARG )
{
EndDialog( RET_OK );
return 1;
}
IMPL_LINK ( SvtPlaceDialog, DelHdl, Button *, EMPTYARG )
{
// ReUsing existing symbols...
EndDialog( RET_NO );
return 1;
}
IMPL_LINK ( SvtPlaceDialog, EditHdl, Edit *, 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 );
}
return 1;
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* -*- 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 Julien Levesy <jlevesy@gmail.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 _SVTPLACEDIALOG_HXX
#define _SVTPLACEDIALOG_HXX
#include <vcl/button.hxx>
#include <vcl/dialog.hxx>
#include <vcl/fixed.hxx>
#include <vcl/edit.hxx>
#include <svtools/inettbc.hxx>
#include <svl/restrictedpaths.hxx>
class Place;
class SvtPlaceDialog : 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;
OKButton m_aBTOk;
CancelButton m_aBTCancel;
PushButton m_aBTDelete;
::svt::RestrictedPaths m_UrlFilter;
DECL_LINK( OKHdl, Button *);
DECL_LINK ( DelHdl, Button *);
DECL_LINK ( EditHdl, Edit *);
public :
SvtPlaceDialog( Window* pParent);
SvtPlaceDialog( Window* pParent, PlacePtr pPlace );
~SvtPlaceDialog();
// Returns a place instance with given informations
PlacePtr GetPlace();
rtl::OUString GetServerName() { return m_aEDServerName.GetText(); }
rtl::OUString GetServerUrl() { return m_aEDServerUrl.GetText(); }
};
#endif //_SVTPLACEDIALOG_HXX
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* -*- 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 Cédric Bosdonnat <cbosdonnat@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 _FPS_OFFICE_RESMGR_HXX_
#define _FPS_OFFICE_RESMGR_HXX_
#include <rtl/instance.hxx>
#include <tools/resmgr.hxx>
namespace
{
struct ResMgrHolder
{
ResMgr * operator ()()
{
return ResMgr::CreateResMgr ("fps_office");
}
static ResMgr * getOrCreate()
{
return rtl_Instance<
ResMgr, ResMgrHolder,
osl::MutexGuard, osl::GetGlobalMutex >::create (
ResMgrHolder(), osl::GetGlobalMutex());
}
};
struct SvtResId : public ResId
{
SvtResId (sal_uInt16 nId) : ResId (nId, *ResMgrHolder::getOrCreate()) {}
};
}
#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
...@@ -28,6 +28,8 @@ ...@@ -28,6 +28,8 @@
#include <sal/macros.h> #include <sal/macros.h>
#include "iodlg.hxx" #include "iodlg.hxx"
#include "PlacesListBox.hxx"
#include "fpsofficeResMgr.hxx"
#include <tools/stream.hxx> #include <tools/stream.hxx>
#include <tools/urlobj.hxx> #include <tools/urlobj.hxx>
#include <vcl/fixed.hxx> #include <vcl/fixed.hxx>
...@@ -52,7 +54,6 @@ ...@@ -52,7 +54,6 @@
#include "svtools/svtools.hrc" #include "svtools/svtools.hrc"
#include "svtools/helpid.hrc" #include "svtools/helpid.hrc"
#include "iodlg.hrc" #include "iodlg.hrc"
#include "rtl/instance.hxx"
#include "asyncfilepicker.hxx" #include "asyncfilepicker.hxx"
#include "iodlgimp.hxx" #include "iodlgimp.hxx"
#include "svtools/inettbc.hxx" #include "svtools/inettbc.hxx"
...@@ -86,8 +87,12 @@ ...@@ -86,8 +87,12 @@
#include "fpinteraction.hxx" #include "fpinteraction.hxx"
#include <osl/process.h> #include <osl/process.h>
#include <officecfg/Office/Common.hxx>
#include "SvtPlaceDialog.hxx"
#include <algorithm> #include <algorithm>
#include <functional> #include <functional>
#include <vector>
//#define AUTOSELECT_USERFILTER //#define AUTOSELECT_USERFILTER
// define this for the experimental feature of user-filter auto selection // define this for the experimental feature of user-filter auto selection
...@@ -419,33 +424,6 @@ ControlChain_Impl::~ControlChain_Impl() ...@@ -419,33 +424,6 @@ ControlChain_Impl::~ControlChain_Impl()
delete _pNext; delete _pNext;
} }
//*****************************************************************************
// ResMgrHolder
//*****************************************************************************
namespace
{
struct ResMgrHolder
{
ResMgr * operator ()()
{
return ResMgr::CreateResMgr ("fps_office");
}
static ResMgr * getOrCreate()
{
return rtl_Instance<
ResMgr, ResMgrHolder,
osl::MutexGuard, osl::GetGlobalMutex >::create (
ResMgrHolder(), osl::GetGlobalMutex());
}
};
struct SvtResId : public ResId
{
SvtResId (sal_uInt16 nId) : ResId (nId, *ResMgrHolder::getOrCreate()) {}
};
}
//***************************************************************************** //*****************************************************************************
// SvtFileDialog // SvtFileDialog
//***************************************************************************** //*****************************************************************************
...@@ -472,6 +450,7 @@ SvtFileDialog::SvtFileDialog ...@@ -472,6 +450,7 @@ SvtFileDialog::SvtFileDialog
,_bIsInExecute( sal_False ) ,_bIsInExecute( sal_False )
,m_bInExecuteAsync( false ) ,m_bInExecuteAsync( false )
,m_bHasFilename( false ) ,m_bHasFilename( false )
,m_context(comphelper::getProcessComponentContext())
{ {
Init_Impl( nBits ); Init_Impl( nBits );
} }
...@@ -514,6 +493,23 @@ SvtFileDialog::~SvtFileDialog() ...@@ -514,6 +493,23 @@ SvtFileDialog::~SvtFileDialog()
_pFileView->SetSelectHdl( Link() ); _pFileView->SetSelectHdl( Link() );
// Save bookmarked places
if(_pImp->_pPlaces->IsUpdated()) {
const std::vector<PlacePtr> aPlaces = _pImp->_pPlaces->GetPlaces();
Sequence< ::rtl::OUString > placesList(_pImp->_pPlaces->GetNbEditablePlaces());
int i(0);
for(std::vector<PlacePtr>::const_iterator it = aPlaces.begin(); it != aPlaces.end(); ++it) {
if((*it)->IsEditable()) {
placesList[i] = (*it)->GetUrl();
++i;
}
}
boost::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create(m_context));
officecfg::Office::Common::Misc::FilePickerPlaces::set(placesList, batch, m_context);
batch->commit();
}
delete _pImp; delete _pImp;
delete _pFileView; delete _pFileView;
...@@ -598,15 +594,27 @@ void SvtFileDialog::Init_Impl ...@@ -598,15 +594,27 @@ void SvtFileDialog::Init_Impl
} }
} }
_pImp->_pFtCurrentPath = new FixedText( this, SvtResId( FT_EXPLORERFILE_CURRENTPATH ) ); Edit anOtherDummy( this, SvtResId( ED_EXPLORERFILE_CURRENTPATH ) );
WinBits nTmpStyle = _pImp->_pFtCurrentPath->GetStyle(); _pImp->_pEdCurrentPath = new SvtURLBox( this, SvtResId(ED_EXPLORERFILE_CURRENTPATH) );
nTmpStyle |= WB_PATHELLIPSIS; _pImp->_pEdCurrentPath->SetUrlFilter( &m_aURLFilter );
_pImp->_pFtCurrentPath->SetStyle( nTmpStyle ); _pImp->_pEdCurrentPath->SetPosSizePixel( anOtherDummy.GetPosPixel(), anOtherDummy.GetSizePixel() );
_pImp->_pEdCurrentPath->Show();
_pImp->_pBtnFileOpen = new PushButton( this, SvtResId( BTN_EXPLORERFILE_OPEN ) ); _pImp->_pBtnFileOpen = new PushButton( this, SvtResId( BTN_EXPLORERFILE_OPEN ) );
_pImp->_pBtnCancel = new CancelButton( this, SvtResId( BTN_EXPLORERFILE_CANCEL ) ); _pImp->_pBtnCancel = new CancelButton( this, SvtResId( BTN_EXPLORERFILE_CANCEL ) );
_pImp->_pBtnHelp = new HelpButton( this, SvtResId( BTN_EXPLORERFILE_HELP ) ); _pImp->_pBtnHelp = new HelpButton( this, SvtResId( BTN_EXPLORERFILE_HELP ) );
_pImp->_pBtnConnectToServer = new PushButton ( this, SvtResId ( BTN_EXPLORERFILE_CONNECT_TO_SERVER ) );
_pImp->_pBtnConnectToServer->SetAccessibleName( _pImp->_pBtnConnectToServer->GetQuickHelpText() );
_pImp->_pBtnAddPlace = new PushButton ( this, SvtResId ( BTN_EXPLORERFILE_ADD_PLACE ) );
_pImp->_pBtnAddPlace->SetAccessibleName( _pImp->_pBtnAddPlace->GetQuickHelpText() );
_pImp->_pBtnAddPlace->SetClickHdl( STATIC_LINK ( this, SvtFileDialog, AddPlacePressed_Hdl ) );
_pImp->_pBtnRemovePlace = new PushButton ( this, SvtResId ( BTN_EXPLORERFILE_REMOVE_PLACE ) );
_pImp->_pBtnRemovePlace->SetAccessibleName( _pImp->_pBtnRemovePlace->GetQuickHelpText() );
_pImp->_pBtnRemovePlace->SetClickHdl( STATIC_LINK ( this, SvtFileDialog, RemovePlacePressed_Hdl ) );
_pImp->_pBtnUp = new SvtUpButton_Impl( this, SvtResId( BTN_EXPLORERFILE_UP ) ); _pImp->_pBtnUp = new SvtUpButton_Impl( this, SvtResId( BTN_EXPLORERFILE_UP ) );
_pImp->_pBtnNewFolder = new ImageButton( this, SvtResId( BTN_EXPLORERFILE_NEWFOLDER ) ); _pImp->_pBtnNewFolder = new ImageButton( this, SvtResId( BTN_EXPLORERFILE_NEWFOLDER ) );
_pImp->_pBtnNewFolder->SetStyle( _pImp->_pBtnNewFolder->GetStyle() | WB_NOPOINTERFOCUS ); _pImp->_pBtnNewFolder->SetStyle( _pImp->_pBtnNewFolder->GetStyle() | WB_NOPOINTERFOCUS );
...@@ -628,7 +636,7 @@ void SvtFileDialog::Init_Impl ...@@ -628,7 +636,7 @@ void SvtFileDialog::Init_Impl
_pFileView->SetHelpId( HID_FILEDLG_STANDARD ); _pFileView->SetHelpId( HID_FILEDLG_STANDARD );
_pFileView->SetStyle( _pFileView->GetStyle() | WB_TABSTOP ); _pFileView->SetStyle( _pFileView->GetStyle() | WB_TABSTOP );
// determine the positions and size of the buttons // determine the size of the buttons
Image aNewFolderImg( GetButtonImage( IMG_FILEDLG_CREATEFOLDER ) ); Image aNewFolderImg( GetButtonImage( IMG_FILEDLG_CREATEFOLDER ) );
_pImp->_pBtnNewFolder->SetModeImage( aNewFolderImg ); _pImp->_pBtnNewFolder->SetModeImage( aNewFolderImg );
...@@ -639,40 +647,61 @@ void SvtFileDialog::Init_Impl ...@@ -639,40 +647,61 @@ void SvtFileDialog::Init_Impl
_pImp->_pBtnUp->SetSizePixel( aSize ); _pImp->_pBtnUp->SetSizePixel( aSize );
_pImp->_pBtnStandard->SetSizePixel( aSize ); _pImp->_pBtnStandard->SetSizePixel( aSize );
// set position of the buttons
Size aDlgSize = GetOutputSizePixel(); Size aDlgSize = GetOutputSizePixel();
long n6AppFontInPixel = long n6AppFontInPixel =
LogicToPixel( Size( 6, 0 ), MAP_APPFONT ).Width(); LogicToPixel( Size( 6, 0 ), MAP_APPFONT ).Width();
long n3AppFontInPixel = long n3AppFontInPixel =
LogicToPixel( Size( 3, 0 ), MAP_APPFONT ).Width(); LogicToPixel( Size( 3, 0 ), MAP_APPFONT ).Width();
long nHalf3AppFontInPixel = n3AppFontInPixel/2;
// calculate the length of all buttons // nDelta is the space between the right border and the left border of the
const sal_uInt16 nBtnCount = 3; // "previous level", "new folder" and "standard dir" // component currently positioned
long nDelta = n6AppFontInPixel; // right border long nDelta = n6AppFontInPixel;
nDelta += ( nBtnCount * aSize.Width() ); // button count * button width
nDelta += ( n3AppFontInPixel + n3AppFontInPixel / 2 ); // spacing 1*big 1*small
// Standard dir
nDelta += aSize.Width();
Point aPos( Point aPos(
aDlgSize.Width() - nDelta, aDlgSize.Width() - nDelta,
_pImp->_pBtnUp->GetPosPixel().Y() _pImp->_pBtnStandard->GetPosPixel().Y()
); );
Size aCurPathSize( _pImp->_pBtnStandard->SetPosPixel(aPos);
aPos.X() - n6AppFontInPixel,
_pImp->_pFtCurrentPath->GetOutputSizePixel().Height() // New folder
); nDelta += aSize.Width() + nHalf3AppFontInPixel;
_pImp->_pFtCurrentPath->SetOutputSizePixel( aCurPathSize ); aPos.X() = aDlgSize.Width() - nDelta;
_pImp->_pBtnUp->SetPosPixel( aPos ); _pImp->_pBtnNewFolder->SetPosPixel(aPos);
aPos.X() += aSize.Width();
aPos.X() += n3AppFontInPixel; // Previous level (up)
_pImp->_pBtnNewFolder->SetPosPixel( aPos ); nDelta += aSize.Width() + nHalf3AppFontInPixel;
aPos.X() += aSize.Width(); aPos.X() = aDlgSize.Width() - nDelta;
aPos.X() += n3AppFontInPixel / 2; _pImp->_pBtnUp->SetPosPixel(aPos);
_pImp->_pBtnStandard->SetPosPixel( aPos );
nDelta = aSize.Height(); // Connect to server ("...")
nDelta -= aCurPathSize.Height(); nDelta += _pImp->_pBtnConnectToServer->GetSizePixel().Width() + n3AppFontInPixel;
nDelta /= 2; aPos.X() = aDlgSize.Width() - nDelta;
Point aCurPathPos = _pImp->_pFtCurrentPath->GetPosPixel();
aCurPathPos.Y() += nDelta; // Height of this button is URL bar's height
_pImp->_pFtCurrentPath->SetPosPixel( aCurPathPos ); long nBtnHeight = aSize.Height();
aSize = _pImp->_pBtnConnectToServer->GetSizePixel();
aSize.Height() = _pImp->_pEdCurrentPath->GetOutputSizePixel().Height();
// Keep the same height as for the other buttons
_pImp->_pBtnConnectToServer->SetSizePixel( aSize );
// Repositon the URL bar and the "..." button in order to have it vertically
// aligned with the buttons
aPos.Y() += (nBtnHeight - aSize.Height()) / 2;
_pImp->_pBtnConnectToServer->SetPosPixel(aPos);
// Set the size of the URL bar
nDelta += nHalf3AppFontInPixel; // right margin of the URL bar
aSize.Width() = aDlgSize.Width()
- _pImp->_pEdCurrentPath->GetPosPixel().X()
- nDelta;
_pImp->_pEdCurrentPath->SetOutputSizePixel(aSize);
aPos.X() = _pImp->_pEdCurrentPath->GetPosPixel().X();
_pImp->_pEdCurrentPath->SetPosPixel(aPos);
if ( nStyle & SFXWB_READONLY ) if ( nStyle & SFXWB_READONLY )
{ {
...@@ -703,12 +732,16 @@ void SvtFileDialog::Init_Impl ...@@ -703,12 +732,16 @@ void SvtFileDialog::Init_Impl
aPos.Y() += LogicToPixel( Size( 0, 6 ), MAP_APPFONT ).Height(); aPos.Y() += LogicToPixel( Size( 0, 6 ), MAP_APPFONT ).Height();
long nYOffset = aPos.Y(); long nYOffset = aPos.Y();
aPos = _pFileView->GetPosPixel(); aPos = _pFileView->GetPosPixel();
aPos.Y() = nYOffset;
nYOffset -= aPos.Y(); nYOffset -= aPos.Y();
// Adjust the position of the other elements. // Adjust the position of the other elements.
aPos.Y() += nYOffset;
_pFileView->SetPosPixel( aPos ); _pFileView->SetPosPixel( aPos );
aPos.X() = _pImp->_pPlaces->GetPosPixel().X();
_pImp->_pPlaces->SetPosPixel( aPos );
lcl_MoveControl( _pImp->_pFtFileName, 0, nYOffset ); lcl_MoveControl( _pImp->_pFtFileName, 0, nYOffset );
lcl_MoveControl( _pImp->_pEdFileName, 0, nYOffset ); lcl_MoveControl( _pImp->_pEdFileName, 0, nYOffset );
...@@ -770,6 +803,10 @@ void SvtFileDialog::Init_Impl ...@@ -770,6 +803,10 @@ void SvtFileDialog::Init_Impl
_pImp->SetFilterListSelectHdl( STATIC_LINK( this, SvtFileDialog, FilterSelectHdl_Impl ) ); _pImp->SetFilterListSelectHdl( STATIC_LINK( this, SvtFileDialog, FilterSelectHdl_Impl ) );
_pImp->_pEdFileName->SetGetFocusHdl( STATIC_LINK( this, SvtFileDialog, FileNameGetFocusHdl_Impl ) ); _pImp->_pEdFileName->SetGetFocusHdl( STATIC_LINK( this, SvtFileDialog, FileNameGetFocusHdl_Impl ) );
_pImp->_pEdFileName->SetModifyHdl( STATIC_LINK( this, SvtFileDialog, FileNameModifiedHdl_Impl ) ); _pImp->_pEdFileName->SetModifyHdl( STATIC_LINK( this, SvtFileDialog, FileNameModifiedHdl_Impl ) );
_pImp->_pEdCurrentPath->SetOpenHdl ( STATIC_LINK( this, SvtFileDialog, URLBoxModifiedHdl_Impl ) );
_pImp->_pBtnConnectToServer->SetClickHdl( STATIC_LINK ( this, SvtFileDialog, ConnectToServerPressed_Hdl ) );
_pFileView->SetSelectHdl( LINK( this, SvtFileDialog, SelectHdl_Impl ) ); _pFileView->SetSelectHdl( LINK( this, SvtFileDialog, SelectHdl_Impl ) );
_pFileView->SetDoubleClickHdl( LINK( this, SvtFileDialog, DblClickHdl_Impl ) ); _pFileView->SetDoubleClickHdl( LINK( this, SvtFileDialog, DblClickHdl_Impl ) );
_pFileView->SetOpenDoneHdl( LINK( this, SvtFileDialog, OpenDoneHdl_Impl ) ); _pFileView->SetOpenDoneHdl( LINK( this, SvtFileDialog, OpenDoneHdl_Impl ) );
...@@ -1060,7 +1097,7 @@ IMPL_STATIC_LINK( SvtFileDialog, OpenHdl_Impl, void*, pVoid ) ...@@ -1060,7 +1097,7 @@ IMPL_STATIC_LINK( SvtFileDialog, OpenHdl_Impl, void*, pVoid )
// if the dialog was opened to select a folder, the last selected folder should be selected // if the dialog was opened to select a folder, the last selected folder should be selected
if( pThis->_pImp->_eDlgType == FILEDLG_TYPE_PATHDLG ) if( pThis->_pImp->_eDlgType == FILEDLG_TYPE_PATHDLG )
{ {
aFileName = pThis->_pImp->_pFtCurrentPath->GetText(); aFileName = pThis->_pImp->_pEdCurrentPath->GetText();
nLen = aFileName.Len(); nLen = aFileName.Len();
} }
else else
...@@ -1417,6 +1454,63 @@ IMPL_STATIC_LINK( SvtFileDialog, FileNameModifiedHdl_Impl, void*, EMPTYARG ) ...@@ -1417,6 +1454,63 @@ IMPL_STATIC_LINK( SvtFileDialog, FileNameModifiedHdl_Impl, void*, EMPTYARG )
//***************************************************************************** //*****************************************************************************
IMPL_STATIC_LINK ( SvtFileDialog, URLBoxModifiedHdl_Impl, void*, EMPTYARG )
{
String _aPath = pThis->_pImp->_pEdCurrentPath->GetURL();
pThis->OpenURL_Impl(_aPath);
return 0;
}
//*****************************************************************************
IMPL_STATIC_LINK ( SvtFileDialog, ConnectToServerPressed_Hdl, void*, EMPTYARG )
{
pThis->_pFileView->EndInplaceEditing( false );
SvtPlaceDialog aDlg( pThis );
short aRetCode = aDlg.Execute();
switch (aRetCode) {
case RET_OK :
{
PlacePtr newPlace = aDlg.GetPlace();
pThis->_pImp->_pPlaces->AppendPlace(newPlace);
break;
}
case RET_CANCEL :
default :
// Do Nothing
break;
};
return 0;
}
//*****************************************************************************
IMPL_STATIC_LINK ( SvtFileDialog, AddPlacePressed_Hdl, void*, EMPTYARG )
{
// Maybe open the PlacesDialog would have been a better idea
// there is an ux choice to make we did not make...
PlacePtr newPlace(new Place(::rtl::OUString(pThis->_pFileView->GetViewURL()),
::rtl::OUString(pThis->_pFileView->GetViewURL()),
Place::e_PlaceLocal, true));
pThis->_pImp->_pPlaces->AppendPlace(newPlace);
return 0;
}
//*****************************************************************************
IMPL_STATIC_LINK ( SvtFileDialog, RemovePlacePressed_Hdl, void*, EMPTYARG )
{
pThis->_pImp->_pPlaces->RemoveSelectedPlace();
return 0;
}
//*****************************************************************************
SvtFileDialogFilter_Impl* SvtFileDialog::FindFilter_Impl SvtFileDialogFilter_Impl* SvtFileDialog::FindFilter_Impl
( (
const String& _rFilter, const String& _rFilter,
...@@ -1558,7 +1652,7 @@ void SvtFileDialog::UpdateControls( const String& rURL ) ...@@ -1558,7 +1652,7 @@ void SvtFileDialog::UpdateControls( const String& rURL )
if ( !sText.Len() && rURL.Len() ) if ( !sText.Len() && rURL.Len() )
// happens, for instance, for URLs which the INetURLObject does not know to belong to a hierarchical scheme // happens, for instance, for URLs which the INetURLObject does not know to belong to a hierarchical scheme
sText = rURL; sText = rURL;
_pImp->_pFtCurrentPath->SetText( sText ); _pImp->_pEdCurrentPath->SetText( sText );
} }
//========================================================================= //=========================================================================
...@@ -1937,6 +2031,17 @@ void SvtFileDialog::onAsyncOperationFinished() ...@@ -1937,6 +2031,17 @@ void SvtFileDialog::onAsyncOperationFinished()
_pImp->_pEdFileName->GrabFocus(); _pImp->_pEdFileName->GrabFocus();
// (if m_bInExecuteAsync is true, then the operation was finished within the minium wait time, // (if m_bInExecuteAsync is true, then the operation was finished within the minium wait time,
// and to the user, the operation appears to be synchronous) // and to the user, the operation appears to be synchronous)
_pImp->_pBtnRemovePlace->Disable();
}
//-----------------------------------------------------------------------------
void SvtFileDialog::RemovablePlaceSelected(bool enable)
{
if(enable)
_pImp->_pBtnRemovePlace->Enable();
else
_pImp->_pBtnRemovePlace->Disable();
} }
//------------------------------------------------------------------------- //-------------------------------------------------------------------------
...@@ -2485,8 +2590,9 @@ void SvtFileDialog::implArrangeControls() ...@@ -2485,8 +2590,9 @@ void SvtFileDialog::implArrangeControls()
// pb: #136070# new order so all LabeledBy relations are correct now // pb: #136070# new order so all LabeledBy relations are correct now
Control* pControls[] = Control* pControls[] =
{ {
_pImp->_pFtCurrentPath, _pImp->_pEdCurrentPath, _pImp->_pBtnConnectToServer,
_pImp->_pBtnUp, _pImp->_pBtnNewFolder, _pImp->_pBtnStandard, // image buttons _pImp->_pBtnUp, _pImp->_pBtnNewFolder, _pImp->_pBtnStandard, // image buttons
_pImp->_pPlaces, _pImp->_pBtnAddPlace, _pImp->_pBtnRemovePlace, // list of places
_pFileView, // the file view _pFileView, // the file view
_pImp->_pFtFileName, _pImp->_pEdFileName, _pImp->_pFtFileName, _pImp->_pEdFileName,
_pImp->_pFtFileVersion, _pImp->_pLbFileVersion, _pImp->_pFtFileVersion, _pImp->_pLbFileVersion,
...@@ -2655,6 +2761,11 @@ void SvtFileDialog::Resize() ...@@ -2655,6 +2761,11 @@ void SvtFileDialog::Resize()
_pFileView->SetSizePixel( aNewSize ); _pFileView->SetSizePixel( aNewSize );
// Resize the places list box to fit the height of the FileView
Size placesNewSize(_pImp->_pPlaces->GetSizePixel());
placesNewSize.Height() += nDeltaY;
_pImp->_pPlaces->SetSizePixel( placesNewSize );
if ( !nDeltaY && !nDeltaX ) if ( !nDeltaY && !nDeltaX )
// This resize was only called to show or hide the indicator. // This resize was only called to show or hide the indicator.
return; return;
...@@ -2669,7 +2780,8 @@ void SvtFileDialog::Resize() ...@@ -2669,7 +2780,8 @@ void SvtFileDialog::Resize()
_pImp->_pFtFileName, _pImp->_pEdFileName, _pImp->_pFtFileVersion, _pImp->_pLbFileVersion, _pImp->_pFtFileName, _pImp->_pEdFileName, _pImp->_pFtFileVersion, _pImp->_pLbFileVersion,
_pImp->_pFtTemplates, _pImp->_pLbTemplates, _pImp->_pFtImageTemplates, _pImp->_pLbImageTemplates, _pImp->_pFtTemplates, _pImp->_pLbTemplates, _pImp->_pFtImageTemplates, _pImp->_pLbImageTemplates,
_pImp->_pFtFileType, _pImp->GetFilterListControl(), _pCbReadOnly, _pCbLinkBox, _pCbPreviewBox, _pImp->_pFtFileType, _pImp->GetFilterListControl(), _pCbReadOnly, _pCbLinkBox, _pCbPreviewBox,
_pPbPlay, _pImp->_pCbPassword, _pImp->_pCbAutoExtension, _pImp->_pCbOptions, _pCbSelection _pPbPlay, _pImp->_pCbPassword, _pImp->_pCbAutoExtension, _pImp->_pCbOptions, _pCbSelection,
_pImp->_pBtnAddPlace, _pImp->_pBtnRemovePlace
}; };
Control** ppMoveControls = aMoveControlsVert; Control** ppMoveControls = aMoveControlsVert;
Control** ppMoveControlsEnd = ppMoveControls + SAL_N_ELEMENTS( aMoveControlsVert ); Control** ppMoveControlsEnd = ppMoveControls + SAL_N_ELEMENTS( aMoveControlsVert );
...@@ -2693,6 +2805,7 @@ void SvtFileDialog::Resize() ...@@ -2693,6 +2805,7 @@ void SvtFileDialog::Resize()
{ {
Control* aMoveControlsHor[] = Control* aMoveControlsHor[] =
{ {
_pImp->_pBtnConnectToServer,
_pImp->_pBtnUp, _pImp->_pBtnNewFolder, _pImp->_pBtnStandard _pImp->_pBtnUp, _pImp->_pBtnNewFolder, _pImp->_pBtnStandard
}; };
Control** ppMoveControls = aMoveControlsHor; Control** ppMoveControls = aMoveControlsHor;
...@@ -2707,7 +2820,7 @@ void SvtFileDialog::Resize() ...@@ -2707,7 +2820,7 @@ void SvtFileDialog::Resize()
Control* aSizeControls[] = Control* aSizeControls[] =
{ {
_pImp->_pEdFileName, _pImp->_pLbFileVersion, _pImp->_pLbTemplates, _pImp->_pLbImageTemplates, _pImp->_pEdFileName, _pImp->_pLbFileVersion, _pImp->_pLbTemplates, _pImp->_pLbImageTemplates,
_pImp->GetFilterListControl(), _pImp->_pFtCurrentPath, _pImp->GetFilterListControl(), _pImp->_pEdCurrentPath,
}; };
sal_Int32 nSizeControls = SAL_N_ELEMENTS( aSizeControls ); sal_Int32 nSizeControls = SAL_N_ELEMENTS( aSizeControls );
Control** ppSizeControls = aSizeControls; Control** ppSizeControls = aSizeControls;
...@@ -2804,7 +2917,7 @@ Control* SvtFileDialog::getControl( sal_Int16 _nControlId, sal_Bool _bLabelContr ...@@ -2804,7 +2917,7 @@ Control* SvtFileDialog::getControl( sal_Int16 _nControlId, sal_Bool _bLabelContr
break; break;
case FIXEDTEXT_CURRENTFOLDER: case FIXEDTEXT_CURRENTFOLDER:
pReturn = _pImp->_pFtCurrentPath; pReturn = _pImp->_pEdCurrentPath;
break; break;
case LISTBOX_VERSION: case LISTBOX_VERSION:
...@@ -2993,6 +3106,9 @@ void SvtFileDialog::AddControls_Impl( ) ...@@ -2993,6 +3106,9 @@ void SvtFileDialog::AddControls_Impl( )
_pImp->_pLbImageTemplates = new ListBox( this, SvtResId( LB_EXPLORERFILE_SHARED_LISTBOX ) ); _pImp->_pLbImageTemplates = new ListBox( this, SvtResId( LB_EXPLORERFILE_SHARED_LISTBOX ) );
_pImp->_pLbImageTemplates->SetHelpId( HID_FILEOPEN_IMAGE_TEMPLATE ); _pImp->_pLbImageTemplates->SetHelpId( HID_FILEOPEN_IMAGE_TEMPLATE );
} }
_pImp->_pPlaces = new PlacesListBox( this, SvtResId( LB_EXPLORERFILE_PLACES_LISTBOX ) );
initDefaultPlaces();
} }
// ----------------------------------------------------------------------- // -----------------------------------------------------------------------
...@@ -3317,6 +3433,23 @@ void SvtFileDialog::appendDefaultExtension(String& _rFileName, ...@@ -3317,6 +3433,23 @@ void SvtFileDialog::appendDefaultExtension(String& _rFileName,
} }
} }
void SvtFileDialog::initDefaultPlaces( )
{
PlacePtr pRootPlace( new Place( ResId::toString( SvtResId( STR_MY_DOCUMENTS ) ), GetStandardDir(), Place::e_PlaceLocal ) );
_pImp->_pPlaces->AppendPlace( pRootPlace );
// Load from user settings
Sequence< ::rtl::OUString > placesList(officecfg::Office::Common::Misc::FilePickerPlaces::get(m_context));
for(sal_Int32 nPlace = 0; nPlace < placesList.getLength(); ++nPlace) {
PlacePtr pPlace(new Place(placesList[nPlace], placesList[nPlace], Place::e_PlaceLocal, true));
_pImp->_pPlaces->AppendPlace(pPlace);
}
// Reset the placesList "updated" state
_pImp->_pPlaces->IsUpdated();
}
// QueryFolderNameDialog ------------------------------------------------------- // QueryFolderNameDialog -------------------------------------------------------
namespace svtools { namespace svtools {
......
...@@ -33,7 +33,7 @@ ...@@ -33,7 +33,7 @@
// ModalDialog DLG_SVT_EXPLORERFILE // ModalDialog DLG_SVT_EXPLORERFILE
#define FT_EXPLORERFILE_CURRENTPATH 10 #define ED_EXPLORERFILE_CURRENTPATH 10
#define BTN_EXPLORERFILE_NEWFOLDER 11 #define BTN_EXPLORERFILE_NEWFOLDER 11
#define BTN_EXPLORERFILE_UP 12 #define BTN_EXPLORERFILE_UP 12
#define BTN_EXPLORERFILE_STANDARD 13 #define BTN_EXPLORERFILE_STANDARD 13
...@@ -59,6 +59,11 @@ ...@@ -59,6 +59,11 @@
#define CB_AUTO_EXTENSION 42 #define CB_AUTO_EXTENSION 42
#define CB_OPTIONS 43 #define CB_OPTIONS 43
#define LB_EXPLORERFILE_PLACES_LISTBOX 50
#define BTN_EXPLORERFILE_CONNECT_TO_SERVER 51
#define BTN_EXPLORERFILE_ADD_PLACE 52
#define BTN_EXPLORERFILE_REMOVE_PLACE 53
// ----------------------------------------------- // -----------------------------------------------
#define STR_EXPLORERFILE_OPEN 1 #define STR_EXPLORERFILE_OPEN 1
...@@ -68,7 +73,24 @@ ...@@ -68,7 +73,24 @@
#define STR_PATHSELECT 5 #define STR_PATHSELECT 5
#define STR_BUTTONSELECT 6 #define STR_BUTTONSELECT 6
#define STR_ACTUALVERSION 7 #define STR_ACTUALVERSION 7
#define STR_PREVIEW 8 #define STR_PREVIEW 8
#define STR_MY_DOCUMENTS 9
// 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 ----------------------- // DLG_SVT_QUERYFOLDERNAME -----------------------
......
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/************************************************************************* /*********** **************************************************************
* *
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
...@@ -37,6 +37,7 @@ ...@@ -37,6 +37,7 @@
#include <com/sun/star/beans/StringPair.hpp> #include <com/sun/star/beans/StringPair.hpp>
#include <com/sun/star/uno/Any.hxx> #include <com/sun/star/uno/Any.hxx>
#include <com/sun/star/uno/Sequence.hxx> #include <com/sun/star/uno/Sequence.hxx>
#include <com/sun/star/uno/Reference.hxx>
#include <com/sun/star/ucb/IOErrorCode.hpp> #include <com/sun/star/ucb/IOErrorCode.hpp>
#include <com/sun/star/ui/dialogs/XDialogClosedListener.hpp> #include <com/sun/star/ui/dialogs/XDialogClosedListener.hpp>
#include <unotools/confignode.hxx> #include <unotools/confignode.hxx>
...@@ -46,6 +47,8 @@ ...@@ -46,6 +47,8 @@
#include "asyncfilepicker.hxx" #include "asyncfilepicker.hxx"
#include "OfficeControlAccess.hxx" #include "OfficeControlAccess.hxx"
#include "fpsmartcontent.hxx" #include "fpsmartcontent.hxx"
#include <comphelper/configuration.hxx>
#include <comphelper/processfactory.hxx>
#include <set> #include <set>
...@@ -122,6 +125,7 @@ private: ...@@ -122,6 +125,7 @@ private:
m_xListener; m_xListener;
bool m_bInExecuteAsync; bool m_bInExecuteAsync;
bool m_bHasFilename; bool m_bHasFilename;
::com::sun::star::uno::Reference < com::sun::star::uno::XComponentContext > m_context;
DECL_STATIC_LINK( SvtFileDialog, FilterSelectHdl_Impl, ListBox* ); DECL_STATIC_LINK( SvtFileDialog, FilterSelectHdl_Impl, ListBox* );
DECL_STATIC_LINK( SvtFileDialog, NewFolderHdl_Impl, PushButton* ); DECL_STATIC_LINK( SvtFileDialog, NewFolderHdl_Impl, PushButton* );
...@@ -131,6 +135,12 @@ private: ...@@ -131,6 +135,12 @@ private:
DECL_STATIC_LINK( SvtFileDialog, FileNameGetFocusHdl_Impl, void* ); DECL_STATIC_LINK( SvtFileDialog, FileNameGetFocusHdl_Impl, void* );
DECL_STATIC_LINK( SvtFileDialog, FileNameModifiedHdl_Impl, void* ); DECL_STATIC_LINK( SvtFileDialog, FileNameModifiedHdl_Impl, void* );
DECL_STATIC_LINK( SvtFileDialog, URLBoxModifiedHdl_Impl, void* );
DECL_STATIC_LINK( SvtFileDialog, ConnectToServerPressed_Hdl, void* );
DECL_STATIC_LINK( SvtFileDialog, AddPlacePressed_Hdl, void* );
DECL_STATIC_LINK( SvtFileDialog, RemovePlacePressed_Hdl, void* );
void Init_Impl( WinBits nBits ); void Init_Impl( WinBits nBits );
/** find a filter with the given wildcard /** find a filter with the given wildcard
@param _rFilter @param _rFilter
...@@ -158,6 +168,7 @@ private: ...@@ -158,6 +168,7 @@ private:
DECL_LINK( ClickHdl_Impl, CheckBox* ); DECL_LINK( ClickHdl_Impl, CheckBox* );
DECL_LINK(PlayButtonHdl_Impl, void *); DECL_LINK(PlayButtonHdl_Impl, void *);
// removes a filter with wildcards from the path and returns it // removes a filter with wildcards from the path and returns it
sal_Bool IsolateFilterFromPath_Impl( String& rPath, String& rFilter ); sal_Bool IsolateFilterFromPath_Impl( String& rPath, String& rFilter );
...@@ -256,6 +267,8 @@ public: ...@@ -256,6 +267,8 @@ public:
void onAsyncOperationStarted(); void onAsyncOperationStarted();
void onAsyncOperationFinished(); void onAsyncOperationFinished();
void RemovablePlaceSelected(bool enable = true);
void displayIOException( const String& _rURL, ::com::sun::star::ucb::IOErrorCode _eCode ); void displayIOException( const String& _rURL, ::com::sun::star::ucb::IOErrorCode _eCode );
void simulateAccessDenied( const String& _rURL ) void simulateAccessDenied( const String& _rURL )
{ {
...@@ -357,6 +370,8 @@ private: ...@@ -357,6 +370,8 @@ private:
String& _rFileName, String& _rFileName,
const String& _rFilterDefaultExtension, const String& _rFilterDefaultExtension,
const String& _rFilterExtensions); const String& _rFilterExtensions);
void initDefaultPlaces( );
}; };
//*************************************************************************** //***************************************************************************
......
...@@ -64,11 +64,11 @@ ModalDialog DLG_SVT_EXPLORERFILE ...@@ -64,11 +64,11 @@ ModalDialog DLG_SVT_EXPLORERFILE
Sizeable = TRUE; Sizeable = TRUE;
HelpId = HID_EXPLORERDLG_FILE ; HelpId = HID_EXPLORERDLG_FILE ;
Size = MAP_APPFONT ( 280 , 174 ) ; Size = MAP_APPFONT ( 280 , 174 ) ;
FixedText FT_EXPLORERFILE_CURRENTPATH Edit ED_EXPLORERFILE_CURRENTPATH
{ {
Pos = MAP_APPFONT ( 6 , 6 ) ; Pos = MAP_APPFONT ( 6 , 6 ) ;
Size = MAP_APPFONT ( 100 , 10 ) ; Size = MAP_APPFONT ( 90 , 14 ) ;
NoLabel = TRUE ; Border = TRUE ;
}; };
ImageButton BTN_EXPLORERFILE_NEWFOLDER ImageButton BTN_EXPLORERFILE_NEWFOLDER
{ {
...@@ -92,11 +92,45 @@ ModalDialog DLG_SVT_EXPLORERFILE ...@@ -92,11 +92,45 @@ ModalDialog DLG_SVT_EXPLORERFILE
Pos = MAP_APPFONT ( 59 , 6 ) ; Pos = MAP_APPFONT ( 59 , 6 ) ;
QuickHelpText [ en-US ] = "Default Directory" ; QuickHelpText [ en-US ] = "Default Directory" ;
}; };
ListBox LB_EXPLORERFILE_PLACES_LISTBOX
{
HelpID = "fpicker:ListBox:DLG_SVT_EXPLORERFILE:LB_EXPLORERFILE_PLACES_LISTBOX";
Pos = MAP_APPFONT ( 6 , 26 ) ;
Size = MAP_APPFONT ( 50 , 75 ) ;
DropDown = FALSE ;
AutoSize = FALSE ;
AutoHScroll = TRUE ;
Border = TRUE ;
};
PushButton BTN_EXPLORERFILE_CONNECT_TO_SERVER
{
HelpID = "fpicker:PushButton:DLG_SVT_EXPLORERFILE:BTN_EXPLORERFILE_CONNECT_TO_SERVER";
Pos = MAP_APPFONT ( 94 , 6 ) ;
Size = MAP_APPFONT ( 15 , 10 ) ;
Text [ en-US ] = "..." ;
QuickHelpText [ en-US ] = "Connect To Server" ;
};
PushButton BTN_EXPLORERFILE_ADD_PLACE
{
HelpID = "fpicker:PushButton:DLG_SVT_EXPLORERFILE:BTN_EXPLORERFILE_ADD_PLACE";
Pos = MAP_APPFONT ( 6 , 101 ) ;
Size = MAP_APPFONT ( 10 , 10 ) ;
Text [ en-US ] = "+" ;
QuickHelpText [ en-US ] = "Bookmark This Place" ;
};
PushButton BTN_EXPLORERFILE_REMOVE_PLACE
{
HelpID = "fpicker:PushButton:DLG_SVT_EXPLORERFILE:BTN_EXPLORERFILE_REMOVE_PLACE";
Pos = MAP_APPFONT ( 19 , 101 ) ;
Size = MAP_APPFONT ( 10 , 10 ) ;
Text [ en-US ] = "-" ;
QuickHelpText [ en-US ] = "Remove Selected Bookmark" ;
};
Control CTL_EXPLORERFILE_FILELIST Control CTL_EXPLORERFILE_FILELIST
{ {
TabStop = TRUE ; TabStop = TRUE ;
Pos = MAP_APPFONT ( 6 , 26 ) ; Pos = MAP_APPFONT ( 59 , 26 ) ;
Size = MAP_APPFONT ( 268 , 85 ) ; Size = MAP_APPFONT ( 215 , 85 ) ;
Border = TRUE ; Border = TRUE ;
}; };
FixedText FT_EXPLORERFILE_FILENAME FixedText FT_EXPLORERFILE_FILENAME
...@@ -218,9 +252,117 @@ ModalDialog DLG_SVT_EXPLORERFILE ...@@ -218,9 +252,117 @@ ModalDialog DLG_SVT_EXPLORERFILE
{ {
Text [ en-US ] = "File Preview"; Text [ en-US ] = "File Preview";
}; };
String STR_MY_DOCUMENTS
{
Text [ en-US ] = "My Documents" ;
};
};
// 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 ---------------------------------------------------------- // QueryFolderNameDialog ----------------------------------------------------------
ModalDialog DLG_SVT_QUERYFOLDERNAME ModalDialog DLG_SVT_QUERYFOLDERNAME
{ {
HelpID = "fpicker:ModalDialog:DLG_SVT_QUERYFOLDERNAME"; HelpID = "fpicker:ModalDialog:DLG_SVT_QUERYFOLDERNAME";
...@@ -229,7 +371,7 @@ ModalDialog DLG_SVT_QUERYFOLDERNAME ...@@ -229,7 +371,7 @@ ModalDialog DLG_SVT_QUERYFOLDERNAME
OutputSize = TRUE ; OutputSize = TRUE ;
SVLook = TRUE ; SVLook = TRUE ;
Text = "Ordner" ; Text = "Ordner" ;
Size = MAP_APPFONT ( 218 , 45 ) ; Size = MAP_APPFONT ( 100 , 45 ) ;
FixedText FT_SVT_QUERYFOLDERNAME_DLG_NAME FixedText FT_SVT_QUERYFOLDERNAME_DLG_NAME
{ {
Pos = MAP_APPFONT ( 12 , 14 ) ; Pos = MAP_APPFONT ( 12 , 14 ) ;
......
...@@ -360,9 +360,13 @@ SvtExpFileDlg_Impl::SvtExpFileDlg_Impl( WinBits ) : ...@@ -360,9 +360,13 @@ SvtExpFileDlg_Impl::SvtExpFileDlg_Impl( WinBits ) :
_pBtnNewFolder ( NULL ), _pBtnNewFolder ( NULL ),
_pBtnStandard ( NULL ), _pBtnStandard ( NULL ),
_pCbPassword ( NULL ), _pCbPassword ( NULL ),
_pFtCurrentPath ( NULL ), _pEdCurrentPath ( NULL ),
_pCbAutoExtension ( NULL ), _pCbAutoExtension ( NULL ),
_pCbOptions ( NULL ), _pCbOptions ( NULL ),
_pPlaces ( NULL ),
_pBtnConnectToServer( NULL ),
_pBtnAddPlace ( NULL ),
_pBtnRemovePlace ( NULL ),
_nState ( FILEDLG_STATE_REMOTE ), _nState ( FILEDLG_STATE_REMOTE ),
_nStyle ( 0 ), _nStyle ( 0 ),
_bDoubleClick ( sal_False ), _bDoubleClick ( sal_False ),
...@@ -378,7 +382,7 @@ SvtExpFileDlg_Impl::SvtExpFileDlg_Impl( WinBits ) : ...@@ -378,7 +382,7 @@ SvtExpFileDlg_Impl::SvtExpFileDlg_Impl( WinBits ) :
SvtExpFileDlg_Impl::~SvtExpFileDlg_Impl() SvtExpFileDlg_Impl::~SvtExpFileDlg_Impl()
{ {
delete _pFtCurrentPath; delete _pEdCurrentPath;
delete _pCbPassword; delete _pCbPassword;
delete _pCbAutoExtension; delete _pCbAutoExtension;
delete _pCbOptions; delete _pCbOptions;
...@@ -400,6 +404,10 @@ SvtExpFileDlg_Impl::~SvtExpFileDlg_Impl() ...@@ -400,6 +404,10 @@ SvtExpFileDlg_Impl::~SvtExpFileDlg_Impl()
delete _pFtFileName; delete _pFtFileName;
delete _pUserFilter; delete _pUserFilter;
delete _pFilter; delete _pFilter;
delete _pPlaces;
delete _pBtnConnectToServer;
delete _pBtnAddPlace;
delete _pBtnRemovePlace;
} }
//***************************************************************************** //*****************************************************************************
......
...@@ -28,6 +28,8 @@ ...@@ -28,6 +28,8 @@
#ifndef _IODLGIMP_HXX #ifndef _IODLGIMP_HXX
#define _IODLGIMP_HXX #define _IODLGIMP_HXX
#include <PlacesListBox.hxx>
#include <tools/string.hxx> #include <tools/string.hxx>
#include <vcl/fixed.hxx> #include <vcl/fixed.hxx>
#include <vcl/lstbox.hxx> #include <vcl/lstbox.hxx>
...@@ -184,10 +186,15 @@ public: ...@@ -184,10 +186,15 @@ public:
ImageButton* _pBtnNewFolder; ImageButton* _pBtnNewFolder;
SvtTravelButton_Impl* _pBtnStandard; SvtTravelButton_Impl* _pBtnStandard;
CheckBox* _pCbPassword; CheckBox* _pCbPassword;
FixedText* _pFtCurrentPath; SvtURLBox* _pEdCurrentPath;
CheckBox* _pCbAutoExtension; CheckBox* _pCbAutoExtension;
CheckBox* _pCbOptions; CheckBox* _pCbOptions;
PlacesListBox* _pPlaces;
PushButton* _pBtnConnectToServer;
PushButton* _pBtnAddPlace;
PushButton* _pBtnRemovePlace;
SvtFileDlgMode _eMode; SvtFileDlgMode _eMode;
SvtFileDlgType _eDlgType; SvtFileDlgType _eDlgType;
SvtFileDlgState _nState; SvtFileDlgState _nState;
......
...@@ -590,6 +590,9 @@ ...@@ -590,6 +590,9 @@
<value oor:external= <value oor:external=
"com.sun.star.configuration.backend.GconfBackend SymbolSet"/> "com.sun.star.configuration.backend.GconfBackend SymbolSet"/>
</prop> </prop>
<prop oor:name="FilePickerPlaces">
<value/>
</prop>
</node> </node>
<node oor:name="Save"> <node oor:name="Save">
<node oor:name="Document"> <node oor:name="Document">
......
...@@ -6755,6 +6755,11 @@ ...@@ -6755,6 +6755,11 @@
</info> </info>
<value>true</value> <value>true</value>
</prop> </prop>
<prop oor:name="FilePickerPlaces" oor:type="oor:string-list" oor:nillable="false">
<info>
<desc>List of the places the user bookmarked in the file picker dialog.</desc>
</info>
</prop>
</group> </group>
<group oor:name="Forms"> <group oor:name="Forms">
<info> <info>
......
...@@ -43,6 +43,7 @@ ...@@ -43,6 +43,7 @@
#define DLG_SVT_EXPLORERFILE (RID_SVTOOLS_START+4) #define DLG_SVT_EXPLORERFILE (RID_SVTOOLS_START+4)
#define DLG_SVT_QUERYFOLDERNAME (RID_SVTOOLS_START+5) #define DLG_SVT_QUERYFOLDERNAME (RID_SVTOOLS_START+5)
#define DLG_SVT_QUERYDELETE (RID_SVTOOLS_START+6) #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) #define STR_SVT_AUTOMATIC_COLOR (RID_SVTOOLS_START+16)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment