소스 검색

Make `--doctool` imply `--headless` to speed up class reference generation

This also prevents spawning an unnecessary splash screen window
while the class reference is generated.
Hugo Locurcio 3 년 전
부모
커밋
76bf7f169d
1개의 변경된 파일5개의 추가작업 그리고 0개의 파일을 삭제
  1. 5 0
      main/main.cpp

+ 5 - 0
main/main.cpp

@@ -974,6 +974,11 @@ Error Main::setup(const char *execpath, int argc, char *argv[], bool p_second_ph
 		} else if (I->get() == "--doctool") {
 		} else if (I->get() == "--doctool") {
 			// Actually handling is done in start().
 			// Actually handling is done in start().
 			cmdline_tool = true;
 			cmdline_tool = true;
+
+			// `--doctool` implies `--headless` to avoid spawning an unnecessary window
+			// and speed up class reference generation.
+			audio_driver = "Dummy";
+			display_driver = "headless";
 			main_args.push_back(I->get());
 			main_args.push_back(I->get());
 #endif
 #endif
 		} else if (I->get() == "--path") { // set path of project to start or edit
 		} else if (I->get() == "--path") { // set path of project to start or edit