-
Michael Weghorn yazdı
Use base class's 'Qt5FilePicker::getDirectory' instead to reduce duplication. Strictly speaking, the 'KDE5FilePicker::implGetDirectory' implementation used by 'KDE5FilePicker::getDirectory' suggests that the display directory is returned rather than the selected directory, and the same method 'implGetDirectory()' was actually previously used by the 'KDE5FilePicker::getDisplayDirectory()' method as well (removed in a previous commit). The code worked fine inside KDE5FilePicker (where the native Plasma/kde5 file dialog is used) but would lead to incorrect results when used inside Qt5FilePicker, e.g. for the following scenario * open folder picker displaying $HOME that contains a directory "bar" * do a single mouse click on the "bar" directory * click "OK" The call to 'toOUString(m_pFileDialog->directoryUrl().url())' inside 'getDirectory()' would return '$HOME/bar' for the native QFileDialog on KDE Plasma 5, but '$HOME' when used with the non-native QFileDialog Anyway, the implementation inside 'Qt5FilePicker::getDirectory' works fine for both cases, so just drop the KDE5FilePicker one. Change-Id: I86dcf98ed310636b899ad289d8a8a8fa263dd2e9 Reviewed-on: https://gerrit.libreoffice.org/68050 Tested-by: Jenkins Reviewed-by:
Katarina Behrens <Katarina.Behrens@cib.de>
fa738707