diff options
author | obo <obo@openoffice.org> | 2010-07-29 11:05:21 +0200 |
---|---|---|
committer | obo <obo@openoffice.org> | 2010-07-29 11:05:21 +0200 |
commit | 65dfd71991fc1132f0a872e371f95daeea3cb797 (patch) | |
tree | 6f5d5ed1c9266243dd22317e2ceaedcf92ea3d4e /fpicker | |
parent | ebf4a654d31d3dad0dab8f5e60ee627dff612300 (diff) | |
parent | 9a7bec4a045fa95f849c729b0be3bc295aa6d0ff (diff) |
CWS-TOOLING: integrate CWS vcl113
Diffstat (limited to 'fpicker')
-rw-r--r-- | fpicker/source/unx/gnome/SalGtkFilePicker.cxx | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/fpicker/source/unx/gnome/SalGtkFilePicker.cxx b/fpicker/source/unx/gnome/SalGtkFilePicker.cxx index 4766bb844a90..fdf4866daf24 100644 --- a/fpicker/source/unx/gnome/SalGtkFilePicker.cxx +++ b/fpicker/source/unx/gnome/SalGtkFilePicker.cxx @@ -900,6 +900,9 @@ uno::Sequence<rtl::OUString> SAL_CALL SalGtkFilePicker::getSelectedFiles() throw { static const OUString aStarDot = OUString::createFromAscii( "*." ); + ::rtl::OUString aNewFilter; + ::rtl::OUString aOldFilter = getCurrentFilter(); + sal_Bool bChangeFilter = sal_True; for ( FilterList::iterator aListIter = m_pFilterList->begin(); aListIter != m_pFilterList->end(); ++aListIter @@ -907,11 +910,17 @@ uno::Sequence<rtl::OUString> SAL_CALL SalGtkFilePicker::getSelectedFiles() throw { if( aListIter->getFilter().indexOf( aStarDot+sExtension ) >= 0 ) { - setCurrentFilter( aListIter->getTitle() ); + if( !aNewFilter.getLength() ) + aNewFilter = aListIter->getTitle(); + + if( aOldFilter == aListIter->getTitle() ) + bChangeFilter = sal_False; + bExtensionTypedIn = true; - break; } } + if( bChangeFilter ) + setCurrentFilter( aNewFilter ); } } |