Commit a7667134 authored by Peter Zhigalov's avatar Peter Zhigalov

Починил открытие файла с unicode именем через аргумент в проекте с Qt

parent fdb70071
......@@ -14,7 +14,6 @@ int main(int argc, char *argv[])
MainWindow w;
if(argc > 1)
{
#if defined _WIN32
string filename;
for(int i = 1; i < argc; i++)
{
......@@ -23,16 +22,6 @@ int main(int argc, char *argv[])
filename.append(" ");
}
w.open_file(QString::fromLocal8Bit(filename.c_str()));
#else
QString filename;
for(int i = 1; i < argc; i++)
{
filename.append(argv[i]);
if(i + 1 < argc)
filename.append(' ');
}
w.open_file(filename);
#endif
}
w.show();
return a.exec();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment