浏览代码

#IQRV #comment 生产隐藏菜单栏,非生产自动隐藏

80374374 1 年之前
父节点
当前提交
8355a220ad
共有 1 个文件被更改,包括 12 次插入12 次删除
  1. 12 12
      Tool/VTMLauncher/VTM_IL.cpp

+ 12 - 12
Tool/VTMLauncher/VTM_IL.cpp

@@ -276,20 +276,22 @@ VOID HideTaskBar(BOOL bHide)
 		lParam = ABS_ALWAYSONTOP;
 	}
 	if (hWnd != NULL) {
-		//APPBARDATA apBar; 
-		//memset(&apBar, 0, sizeof(apBar)); 
-		//apBar.cbSize = sizeof(apBar); 
-		//apBar.hWnd = hWnd; 
-		//if (apBar.hWnd != NULL) 
-		//{ 
-		//	apBar.lParam = lParam; 
-		//	SHAppBarMessage(ABM_SETSTATE, &apBar); 
-		//} 
+#ifdef DEVOPS_ON_PRD
 		ShowWindow(hWnd, nCmdShow);
+#else
+		APPBARDATA apBar; 
+		memset(&apBar, 0, sizeof(apBar));
+		apBar.cbSize = sizeof(apBar);
+		apBar.hWnd = hWnd;
+		if (apBar.hWnd != NULL)
+		{
+			apBar.lParam = lParam;
+			SHAppBarMessage(ABM_SETSTATE, &apBar);
+		}
+#endif // DEVOPS_ON_PRD
 	}
 }
 
-
 BOOL InitInstance(HINSTANCE hInstance, int nCmdShow)
 {
 	// 校正active.txt的属性
@@ -297,9 +299,7 @@ BOOL InitInstance(HINSTANCE hInstance, int nCmdShow)
 
    //启动框架
 	if (RunSpshell()) {
-#ifdef DEVOPS_ON_PRD
 		HideTaskBar(TRUE);
-#endif // DEVOPS_ON_PRD
 	}
 
     hInst = hInstance; // 将实例句柄存储在全局变量中