refactor arg_dropfiles with std::filesystem::path
This commit is contained in:
@@ -1238,7 +1238,7 @@ namespace detail
|
||||
0, AnyPropertyType, &type, &format, &len,
|
||||
&dummy_bytes_left, &data))
|
||||
{
|
||||
auto files = new std::vector<std::string>;
|
||||
auto files = new std::vector<std::filesystem::path>;
|
||||
std::stringstream ss(reinterpret_cast<char*>(data));
|
||||
|
||||
while(true)
|
||||
@@ -1258,7 +1258,7 @@ namespace detail
|
||||
break;
|
||||
}
|
||||
|
||||
files->push_back(file);
|
||||
files->emplace_back(file);
|
||||
}
|
||||
|
||||
if(files->size())
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
#include <X11/Xlib.h>
|
||||
#include <vector>
|
||||
#include <nana/deploy.hpp>
|
||||
#include <nana/filesystem/filesystem.hpp>
|
||||
|
||||
namespace nana
|
||||
{
|
||||
@@ -29,7 +30,7 @@ namespace detail
|
||||
Window window;
|
||||
int x;
|
||||
int y;
|
||||
std::vector<std::string> * files;
|
||||
std::vector<std::filesystem::path> * files;
|
||||
}mouse_drop;
|
||||
}u;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user