Change working directory to first argument if present for Windows Drag
and Drop compatibility
This commit is contained in:
parent
cf09235040
commit
d658d7a300
@ -1,3 +1,6 @@
|
|||||||
|
// C includes
|
||||||
|
#include <unistd.h>
|
||||||
|
|
||||||
// C++ includes
|
// C++ includes
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
|
|
||||||
@ -54,7 +57,12 @@ void render(Node *curr, Shader *shader, Matrix model) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
int main() {
|
int main(int argc, char *argv[]) {
|
||||||
|
|
||||||
|
if (argc == 2) {
|
||||||
|
chdir(argv[1]);
|
||||||
|
}
|
||||||
|
|
||||||
Window window;
|
Window window;
|
||||||
window.Init();
|
window.Init();
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user