summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2013-04-18 18:14:52 +0300
committerAndrei Karas <akaras@inbox.ru>2013-04-18 18:14:52 +0300
commit68a46feb0eb43663ff145fea3b2216ea79c8e36f (patch)
tree84b0eadd11da6e148401493df5bbbd45837543c4
parente36b143b5a6b5dadae90d9095fc60c16695de764 (diff)
downloadplus-68a46feb0eb43663ff145fea3b2216ea79c8e36f.tar.gz
plus-68a46feb0eb43663ff145fea3b2216ea79c8e36f.tar.bz2
plus-68a46feb0eb43663ff145fea3b2216ea79c8e36f.tar.xz
plus-68a46feb0eb43663ff145fea3b2216ea79c8e36f.zip
improve specialfolder file.
-rw-r--r--src/utils/specialfolder.cpp24
-rw-r--r--src/utils/specialfolder.h2
2 files changed, 2 insertions, 24 deletions
diff --git a/src/utils/specialfolder.cpp b/src/utils/specialfolder.cpp
index 536b4158f..9415e4d46 100644
--- a/src/utils/specialfolder.cpp
+++ b/src/utils/specialfolder.cpp
@@ -23,12 +23,6 @@
#include "utils/specialfolder.h"
#include <windows.h>
-#ifdef M_SPECIALFOLDERLOCATION_TEST_
-// compile with -D_SPECIALFOLDERLOCATION_TEST_ to get a standalone
-// binary for testing
-#include <iostream>
-#endif
-
#include "debug.h"
/*
@@ -37,7 +31,7 @@
* See http://msdn.microsoft.com/en-us/library/bb762494(VS.85).aspx for
* a list of folder ids
*/
-std::string getSpecialFolderLocation(int folderId)
+std::string getSpecialFolderLocation(const int folderId)
{
std::string ret;
LPITEMIDLIST pItemIdList;
@@ -62,20 +56,4 @@ std::string getSpecialFolderLocation(int folderId)
return ret;
}
-#ifdef M_SPECIALFOLDERLOCATION_TEST_
-int main()
-{
- std::cout << "APPDATA " << getSpecialFolderLocation(CSIDL_APPDATA)
- << std::endl;
- std::cout << "DESKTOP " << getSpecialFolderLocation(CSIDL_DESKTOP)
- << std::endl;
- std::cout << "LOCAL_APPDATA "
- << getSpecialFolderLocation(CSIDL_LOCAL_APPDATA)
- << std::endl;
- std::cout << "MYPICTURES " << getSpecialFolderLocation(CSIDL_MYPICTURES)
- << std::endl;
- std::cout << "PERSONAL " << getSpecialFolderLocation(CSIDL_PERSONAL)
- << std::endl;
-}
-#endif
#endif
diff --git a/src/utils/specialfolder.h b/src/utils/specialfolder.h
index 31ec95ef7..2ee91e2c3 100644
--- a/src/utils/specialfolder.h
+++ b/src/utils/specialfolder.h
@@ -27,7 +27,7 @@
#include <string>
#include "localconsts.h"
-std::string getSpecialFolderLocation(int folderId) A_WARN_UNUSED;
+std::string getSpecialFolderLocation(const int folderId) A_WARN_UNUSED;
#endif
#endif