DXGL r751 - Code Review

Jump to navigation Jump to search
Repository:DXGL
Revision:r750‎ | r751 | r752 >
Date:02:45, 8 October 2017
Author:admin
Status:new
Tags:
Comment:
Prepare DXGL Test dialog for merging with new DXGL Config.
Add ESC key to interactive tests and main DXGLTest dialog.
Remove some unnecessary system information from DXGLTest info pane.
Modified paths:
  • /dxgltest/Resource.h (modified) (history)
  • /dxgltest/dxgltest.cpp (modified) (history)
  • /dxgltest/dxgltest.rc (modified) (history)
  • /dxgltest/tests.cpp (modified) (history)

Diff [purge]

Index: dxgltest/Resource.h
@@ -76,15 +76,7 @@
7777 #define IDC_FSAALABEL 1029
7878 #define IDC_TEST 1031
7979 #define IDC_DDVER 1032
80 -#define IDC_DDEXVER 1041
81 -#define IDC_D3DVER 1042
82 -#define IDC_D3D7VER 1043
83 -#define IDC_D3DREFVER 1044
84 -#define IDC_D3DRAMPVER 1045
85 -#define IDC_D3DRMVER 1046
86 -#define IDC_D3DXOFVER 1047
8780 #define IDC_FILLSTIPPLELLLABEL 1047
88 -#define IDC_D3DPMESHVER 1048
8981 #define IDC_FILLSTIPPLETYPE 1052
9082 #define IDC_FILLSTIPPLEFILE 1053
9183 #define IDC_FILLSTIPPLEBROWSE 1054
Index: dxgltest/dxgltest.cpp
@@ -135,26 +135,10 @@
136136
137137 const TCHAR *dllnames[] = {
138138 _T("ddraw.dll"),
139 - _T("ddrawex.dll"),
140 - _T("d3dim.dll"),
141 - _T("d3dim700.dll"),
142 - _T("d3dref.dll"),
143 - _T("d3dramp.dll"),
144 - _T("d3drm.dll"),
145 - _T("d3dxof.dll"),
146 - _T("d3dpmesh.dll")
147139 };
148140
149141 int dllboxes[] = {
150142 IDC_DDVER,
151 - IDC_DDEXVER,
152 - IDC_D3DVER,
153 - IDC_D3D7VER,
154 - IDC_D3DREFVER,
155 - IDC_D3DRAMPVER,
156 - IDC_D3DRMVER,
157 - IDC_D3DXOFVER,
158 - IDC_D3DPMESHVER
159143 };
160144
161145 INT_PTR CALLBACK SysTabCallback(HWND hWnd, UINT Msg, WPARAM wParam, LPARAM lParam)
@@ -176,7 +160,7 @@
177161 SetWindowText(GetDlgItem(hWnd,dllboxes[0]),ver.c_str());
178162 if(!IsDXGLDDraw)
179163 {
180 - for(i = 1; i < 9; i++)
 164+ for(i = 1; i < 1; i++)
181165 {
182166 GetFileVersion(ver,dllnames[i]);
183167 SetWindowText(GetDlgItem(hWnd,dllboxes[i]),ver.c_str());
@@ -184,7 +168,7 @@
185169 }
186170 else
187171 {
188 - for(i = 1; i < 9; i++)
 172+ for(i = 1; i < 1; i++)
189173 SetWindowText(GetDlgItem(hWnd,dllboxes[i]),_T("N/A"));
190174 }
191175 break;
@@ -553,6 +537,7 @@
554538 switch(LOWORD(wParam))
555539 {
556540 case IDOK:
 541+ case IDCANCEL:
557542 EndDialog(hWnd,IDOK);
558543 break;
559544 }
Index: dxgltest/dxgltest.rc
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream
Index: dxgltest/tests.cpp
@@ -2574,6 +2574,9 @@
25752575 d3d7dev->SetRenderState(D3DRENDERSTATE_FOGDENSITY, *((LPDWORD)(&f)));
25762576 }
25772577 break;
 2578+ case IDCANCEL:
 2579+ SendMessage(hWnd, WM_CLOSE, 0, 0);
 2580+ break;
25782581 default:
25792582 return FALSE;
25802583 }
@@ -3095,6 +3098,9 @@
30963099 d3d7dev->SetLight(vertexshaderstate.currentlight, &lights[vertexshaderstate.currentlight]);
30973100 }
30983101 break;
 3102+ case IDCANCEL:
 3103+ SendMessage(hWnd, WM_CLOSE, 0, 0);
 3104+ break;
30993105 default:
31003106 return FALSE;
31013107 }