This commit is contained in:
Vadim Lopatin 2017-08-14 10:05:55 +03:00
parent 5b96e81d1e
commit e58f2a1abe
3 changed files with 23 additions and 14 deletions

View File

@ -713,6 +713,11 @@ alias currentDir = std.file.getcwd;
return path[0 .. lastSlash + 1];
}
/// Returns current executable path and file name
@property string exeFilename() {
return thisExePath();
}
/**
Returns application data directory

View File

@ -1505,8 +1505,10 @@ version (Windows) {
return result;
}
/// split command line arg list; prepend with executable file name
string[] splitCmdLine(string line) {
string[] res;
res ~= exeFilename();
int start = 0;
bool insideQuotes = false;
for (int i = 0; i <= line.length; i++) {

View File

@ -1087,7 +1087,7 @@ class Win32Platform : Platform {
for (uint i = 0; i + 1 < _windowList.length; i++) {
if (_windowList[i] is w) {
for (uint j = i + 1; j < _windowList.length; j++) {
if (_windowList[j].flags & WindowFlag.Modal && _windowList[j]._windowState != WindowState.hidden)
if (_windowList[j].flags & WindowFlag.Modal && _windowList[j].windowState != WindowState.hidden)
return true;
}
return false;
@ -1205,8 +1205,10 @@ int DLANGUIWinMain(void* hInstance, void* hPrevInstance,
return result;
}
/// split command line arg list; prepend with executable file name
string[] splitCmdLine(string line) {
string[] res;
res ~= exeFilename();
int start = 0;
bool insideQuotes = false;
for (int i = 0; i <= line.length; i++) {