Changeset 17724 in vbox
- Timestamp:
- Mar 12, 2009 9:32:18 AM (16 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/include/VBoxGlobal.h
r17714 r17724 36 36 #include <QProcess> 37 37 #include <QHash> 38 #include <QDesktopServices>39 #include <QDir>40 38 41 39 class QAction; … … 733 731 } 734 732 735 static inline QString documentsPath() 736 { 737 QString path; 738 #if QT_VERSION < 0x040400 739 path = QDir::homePath(); 740 #else 741 path = QDesktopServices::storageLocation (QDesktopServices::DocumentsLocation); 742 #endif 743 return QDir::cleanPath (path); 744 } 733 static QString documentsPath(); 745 734 746 735 signals: -
trunk/src/VBox/Frontends/VirtualBox/src/VBoxExportApplianceWzd.cpp
r17714 r17724 26 26 #include "VBoxProblemReporter.h" 27 27 28 /* Qt includes */ 29 #include <QDir> 30 28 31 class VMListWidgetItems: public QListWidgetItem 29 32 { -
trunk/src/VBox/Frontends/VirtualBox/src/VBoxGlobal.cpp
r17721 r17724 50 50 #include <QPainter> 51 51 #include <QTimer> 52 #include <QDir> 52 53 53 54 #include <math.h> … … 4845 4846 } 4846 4847 4848 /* static */ 4849 QString VBoxGlobal::documentsPath() 4850 { 4851 QString path; 4852 #if QT_VERSION < 0x040400 4853 path = QDir::homePath(); 4854 #else 4855 path = QDesktopServices::storageLocation (QDesktopServices::DocumentsLocation); 4856 #endif 4857 4858 /* Make sure the path exists */ 4859 QDir dir (path); 4860 while (!dir.exists()) 4861 dir.cdUp(); 4862 4863 return QDir::cleanPath (dir.canonicalPath()); 4864 } 4865 4847 4866 // Public slots 4848 4867 ////////////////////////////////////////////////////////////////////////////////
Note:
See TracChangeset
for help on using the changeset viewer.