DXGL r611 - Code Review

Jump to navigation Jump to search
Repository:DXGL
Revision:r610‎ | r611 | r612 >
Date:15:26, 16 May 2015
Author:admin
Status:new
Tags:
Comment:
Add fixed scaling to new DXGLCFG dialog box.
Sort new DXGLCFG dialog controls.
Modified paths:
  • /dxglcfg2/dxglcfg2.rc (modified) (history)
  • /dxglcfg2/resource.h (modified) (history)

Diff [purge]

Index: dxglcfg2/dxglcfg2.rc
——@@ -34,23 +34,29 @@
3535 STYLE DS_3DLOOK | DS_CENTER | DS_SHELLFONT | WS_VISIBLE | WS_CHILDWINDOW
3636 FONT 8, "Ms Shell Dlg"
3737 {
38 - COMBOBOX IDC_VSYNC, 114, 92, 102, 30, CBS_DROPDOWNLIST | CBS_HASSTRINGS, WS_EX_LEFT
39 - LTEXT "Vertical sync", IDC_STATIC, 114, 82, 41, 8, SS_LEFT, WS_EX_LEFT
40 - COMBOBOX IDC_EXTRAMODES, 114, 42, 102, 30, CBS_DROPDOWNLIST | CBS_HASSTRINGS | CBS_OWNERDRAWFIXED, WS_EX_LEFT
41 - LTEXT "Additional display modes", 0, 114, 32, 78, 8, SS_LEFT, WS_EX_LEFT
 38+ LTEXT "Video mode", IDC_STATIC, 7, 7, 38, 8, SS_LEFT, WS_EX_LEFT
 39+ COMBOBOX IDC_VIDMODE, 7, 17, 102, 30, CBS_DROPDOWNLIST | CBS_HASSTRINGS, WS_EX_LEFT
 40+ LTEXT "Add color depths", IDC_STATIC, 114, 7, 54, 8, SS_LEFT, WS_EX_LEFT
4241 COMBOBOX IDC_COLORDEPTH, 114, 17, 102, 30, CBS_DROPDOWNLIST | CBS_HASSTRINGS, WS_EX_LEFT
43 - LTEXT "Add color depths", IDC_STATIC, 114, 7, 54, 8, SS_LEFT, WS_EX_LEFT
44 - LTEXT "DPI scaling mode", IDC_STATIC, 7, 82, 55, 8, SS_LEFT, WS_EX_LEFT
45 - COMBOBOX IDC_DPISCALE, 7, 92, 102, 30, CBS_DROPDOWNLIST | CBS_HASSTRINGS, WS_EX_LEFT
46 - LTEXT "Screen aspect ratio", IDC_STATIC, 7, 57, 63, 8, SS_LEFT, WS_EX_LEFT
47 - COMBOBOX IDC_ASPECT, 7, 67, 102, 30, CBS_DROPDOWN | CBS_HASSTRINGS, WS_EX_LEFT
 42+ LTEXT "Scaling method", IDC_STATIC, 7, 32, 49, 8, SS_LEFT, WS_EX_LEFT
4843 COMBOBOX IDC_SCALE, 7, 42, 102, 30, CBS_DROPDOWNLIST | CBS_HASSTRINGS, WS_EX_LEFT
49 - LTEXT "Scaling method", IDC_STATIC, 7, 32, 49, 8, SS_LEFT, WS_EX_LEFT
 44+ LTEXT "Additional display modes", 0, 114, 32, 78, 8, SS_LEFT, WS_EX_LEFT
 45+ COMBOBOX IDC_EXTRAMODES, 114, 42, 102, 30, CBS_DROPDOWNLIST | CBS_HASSTRINGS | CBS_OWNERDRAWFIXED, WS_EX_LEFT
 46+ LTEXT "Fixed scaling", IDC_FIXEDSCALELABEL, 7, 57, 47, 9, WS_DISABLED | SS_LEFT, WS_EX_LEFT
 47+ LTEXT "X", IDC_FIXEDSCALELABELX, 7, 70, 6, 9, WS_DISABLED | SS_LEFT, WS_EX_LEFT
 48+ EDITTEXT IDC_FIXEDSCALEX, 15, 67, 24, 14, ES_AUTOHSCROLL, WS_EX_LEFT
 49+ LTEXT "Y", IDC_FIXEDSCALELABELY, 44, 70, 6, 9, WS_DISABLED | SS_LEFT, WS_EX_LEFT
 50+ EDITTEXT IDC_FIXEDSCALEY, 52, 67, 24, 14, ES_AUTOHSCROLL, WS_EX_LEFT
 51+ AUTOCHECKBOX "Square", IDC_FIXEDSCALESQUARE, 81, 67, 29, 14, BS_PUSHLIKE, WS_EX_LEFT
 52+ LTEXT "Sort video modes", IDC_STATIC, 114, 57, 56, 8, SS_LEFT, WS_EX_LEFT
5053 COMBOBOX IDC_SORTMODES, 114, 67, 102, 30, CBS_DROPDOWNLIST | CBS_HASSTRINGS, WS_EX_LEFT
51 - LTEXT "Sort video modes", IDC_STATIC, 114, 57, 56, 8, SS_LEFT, WS_EX_LEFT
52 - COMBOBOX IDC_VIDMODE, 7, 17, 102, 30, CBS_DROPDOWNLIST | CBS_HASSTRINGS, WS_EX_LEFT
53 - LTEXT "Video mode", IDC_STATIC, 7, 7, 38, 8, SS_LEFT, WS_EX_LEFT
54 - AUTOCHECKBOX "Change display color depth", IDC_COLOR, 7, 110, 100, 10, 0, WS_EX_LEFT
 54+ LTEXT "Screen aspect ratio", IDC_STATIC, 7, 82, 63, 8, SS_LEFT, WS_EX_LEFT
 55+ COMBOBOX IDC_ASPECT, 7, 92, 102, 30, CBS_DROPDOWN | CBS_HASSTRINGS, WS_EX_LEFT
 56+ LTEXT "Vertical sync", IDC_STATIC, 114, 82, 41, 8, SS_LEFT, WS_EX_LEFT
 57+ COMBOBOX IDC_VSYNC, 114, 92, 102, 30, CBS_DROPDOWNLIST | CBS_HASSTRINGS, WS_EX_LEFT
 58+ LTEXT "DPI scaling mode", IDC_STATIC, 7, 107, 55, 8, SS_LEFT, WS_EX_LEFT
 59+ COMBOBOX IDC_DPISCALE, 7, 117, 102, 30, CBS_DROPDOWNLIST | CBS_HASSTRINGS, WS_EX_LEFT
 60+ AUTOCHECKBOX "Change display color depth", IDC_COLOR, 114, 118, 100, 10, 0, WS_EX_LEFT
5561 }
5662
5763
——@@ -73,30 +79,27 @@
7480
7581
7682 LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
77 -IDD_DEBUG DIALOG 0, 0, 283, 173
 83+IDD_ADVANCED DIALOG 0, 0, 283, 173
7884 STYLE DS_3DLOOK | DS_CENTER | DS_SHELLFONT | WS_VISIBLE | WS_CHILDWINDOW
7985 FONT 8, "Ms Shell Dlg"
8086 {
81 - LISTBOX IDC_DEBUGLIST, 7, 7, 269, 162, WS_TABSTOP | WS_VSCROLL | LBS_NOINTEGRALHEIGHT | LBS_OWNERDRAWFIXED | LBS_SORT | LBS_NOTIFY, WS_EX_LEFT
 87+ LTEXT "Texture format", IDC_STATIC, 7, 7, 50, 8, SS_LEFT, WS_EX_LEFT
 88+ COMBOBOX IDC_TEXTUREFORMAT, 7, 17, 102, 30, CBS_DROPDOWNLIST | CBS_HASSTRINGS, WS_EX_LEFT
 89+ LTEXT "Texture access method", IDC_STATIC, 114, 7, 76, 8, SS_LEFT, WS_EX_LEFT
 90+ COMBOBOX IDC_TEXUPLOAD, 114, 17, 102, 30, CBS_DROPDOWNLIST | CBS_HASSTRINGS, WS_EX_LEFT
 91+ LTEXT "Display name", 0, 7, 35, 43, 9, SS_LEFT, WS_EX_LEFT
 92+ EDITTEXT IDC_DISPLAYNAME, 7, 46, 209, 14, ES_AUTOHSCROLL, WS_EX_LEFT
 93+ PUSHBUTTON "Write INI file...", IDC_WRITEINI, 203, 155, 73, 14, 0, WS_EX_LEFT
8294 }
8395
8496
8597
8698 LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
87 -IDD_EFFECTS DIALOG 0, 0, 283, 173
 99+IDD_DEBUG DIALOG 0, 0, 283, 173
88100 STYLE DS_3DLOOK | DS_CENTER | DS_SHELLFONT | WS_VISIBLE | WS_CHILDWINDOW
89101 FONT 8, "Ms Shell Dlg"
90102 {
91 - LTEXT "Y", IDC_CUSTOMSCALELABELY, 57, 72, 6, 8, WS_DISABLED | SS_LEFT, WS_EX_LEFT
92 - LTEXT "Custom scale", IDC_CUSTOMSCALELABEL, 7, 59, 43, 8, WS_DISABLED | SS_LEFT, WS_EX_LEFT
93 - LTEXT "Primary buffer scaling", 0, 7, 34, 68, 8, SS_LEFT, WS_EX_LEFT
94 - COMBOBOX IDC_PRIMARYSCALE, 7, 44, 101, 30, CBS_DROPDOWNLIST | CBS_HASSTRINGS, WS_EX_LEFT
95 - EDITTEXT IDC_CUSTOMSCALEX, 15, 69, 40, 14, WS_DISABLED | ES_AUTOHSCROLL, WS_EX_LEFT
96 - LTEXT "X", IDC_CUSTOMSCALELABELX, 7, 72, 6, 8, WS_DISABLED | SS_LEFT, WS_EX_LEFT
97 - EDITTEXT IDC_CUSTOMSCALEY, 65, 69, 40, 14, WS_DISABLED | ES_AUTOHSCROLL, WS_EX_LEFT
98 - AUTOCHECKBOX "Use post-processing shader", IDC_USESHADER, 7, 8, 103, 8, 0, WS_EX_LEFT
99 - COMBOBOX IDC_SHADER, 7, 18, 247, 92, WS_DISABLED | CBS_DROPDOWN | CBS_HASSTRINGS, WS_EX_LEFT
100 - PUSHBUTTON "...", IDC_BROWSESHADER, 256, 17, 20, 14, WS_DISABLED, WS_EX_LEFT
 103+ LISTBOX IDC_DEBUGLIST, 7, 7, 269, 162, WS_TABSTOP | WS_VSCROLL | LBS_NOINTEGRALHEIGHT | LBS_OWNERDRAWFIXED | LBS_SORT | LBS_NOTIFY, WS_EX_LEFT
101104 }
102105
103106
——@@ -107,40 +110,37 @@
108111 CAPTION "DXGL Config (Experimental)"
109112 FONT 8, "Ms Shell Dlg 2"
110113 {
 114+ LTEXT "Application profile", IDC_STATIC, 7, 7, 58, 8, SS_LEFT, WS_EX_LEFT
 115+ COMBOBOX IDC_APPS, 7, 17, 287, 195, WS_TABSTOP | WS_VSCROLL | CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | 0x00000400, WS_EX_LEFT
111116 CONTROL "", IDC_TABS, WC_TABCONTROL, 0, 7, 35, 287, 189, WS_EX_LEFT
 117+ PUSHBUTTON "A&dd...", IDC_ADD, 7, 226, 50, 14, 0, WS_EX_LEFT
 118+ PUSHBUTTON "&Remove", IDC_REMOVE, 59, 226, 50, 14, WS_DISABLED, WS_EX_LEFT
112119 DEFPUSHBUTTON "OK", IDOK, 140, 226, 50, 14, 0, WS_EX_LEFT
113120 PUSHBUTTON "Cancel", IDCANCEL, 192, 226, 50, 14, 0, WS_EX_LEFT
114121 PUSHBUTTON "&Apply", IDC_APPLY, 244, 226, 50, 14, WS_DISABLED, WS_EX_LEFT
115 - COMBOBOX IDC_APPS, 7, 17, 287, 195, WS_TABSTOP | WS_VSCROLL | CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | 0x00000400, WS_EX_LEFT
116 - LTEXT "Application profile", IDC_STATIC, 7, 7, 58, 8, SS_LEFT, WS_EX_LEFT
117 - PUSHBUTTON "A&dd...", IDC_ADD, 7, 226, 50, 14, 0, WS_EX_LEFT
118 - PUSHBUTTON "&Remove", IDC_REMOVE, 59, 226, 50, 14, WS_DISABLED, WS_EX_LEFT
119122 }
120123
121124
122125
123126 LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
124 -IDD_ADVANCED DIALOG 0, 0, 283, 173
 127+IDD_EFFECTS DIALOG 0, 0, 283, 173
125128 STYLE DS_3DLOOK | DS_CENTER | DS_SHELLFONT | WS_VISIBLE | WS_CHILDWINDOW
126129 FONT 8, "Ms Shell Dlg"
127130 {
128 - PUSHBUTTON "Write INI file...", IDC_WRITEINI, 203, 155, 73, 14, 0, WS_EX_LEFT
129 - COMBOBOX IDC_TEXTUREFORMAT, 7, 17, 102, 30, CBS_DROPDOWNLIST | CBS_HASSTRINGS, WS_EX_LEFT
130 - LTEXT "Texture format", IDC_STATIC, 7, 7, 50, 8, SS_LEFT, WS_EX_LEFT
131 - LTEXT "Texture access method", IDC_STATIC, 114, 7, 76, 8, SS_LEFT, WS_EX_LEFT
132 - COMBOBOX IDC_TEXUPLOAD, 114, 17, 102, 30, CBS_DROPDOWNLIST | CBS_HASSTRINGS, WS_EX_LEFT
133 - LTEXT "Display name", 0, 7, 35, 43, 9, SS_LEFT, WS_EX_LEFT
134 - EDITTEXT IDC_DISPLAYNAME, 7, 46, 209, 14, ES_AUTOHSCROLL, WS_EX_LEFT
 131+ AUTOCHECKBOX "Use post-processing shader", IDC_USESHADER, 7, 8, 103, 8, 0, WS_EX_LEFT
 132+ COMBOBOX IDC_SHADER, 7, 18, 247, 92, WS_DISABLED | CBS_DROPDOWN | CBS_HASSTRINGS, WS_EX_LEFT
 133+ PUSHBUTTON "...", IDC_BROWSESHADER, 256, 17, 20, 14, WS_DISABLED, WS_EX_LEFT
 134+ LTEXT "Primary buffer scaling", 0, 7, 34, 68, 8, SS_LEFT, WS_EX_LEFT
 135+ COMBOBOX IDC_PRIMARYSCALE, 7, 44, 101, 30, CBS_DROPDOWNLIST | CBS_HASSTRINGS, WS_EX_LEFT
 136+ LTEXT "Custom scale", IDC_CUSTOMSCALELABEL, 7, 59, 43, 8, WS_DISABLED | SS_LEFT, WS_EX_LEFT
 137+ LTEXT "X", IDC_CUSTOMSCALELABELX, 7, 72, 8, 8, WS_DISABLED | SS_LEFT, WS_EX_LEFT
 138+ EDITTEXT IDC_CUSTOMSCALEX, 15, 69, 40, 14, WS_DISABLED | ES_AUTOHSCROLL, WS_EX_LEFT
 139+ LTEXT "Y", IDC_CUSTOMSCALELABELY, 57, 72, 8, 8, WS_DISABLED | SS_LEFT, WS_EX_LEFT
 140+ EDITTEXT IDC_CUSTOMSCALEY, 65, 69, 40, 14, WS_DISABLED | ES_AUTOHSCROLL, WS_EX_LEFT
135141 }
136142
137 -LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
138 -IDD_PATHS DIALOG 0, 0, 283, 173
139 -STYLE DS_3DLOOK | DS_CENTER | DS_SHELLFONT | WS_VISIBLE | WS_CHILDWINDOW
140 -FONT 8, "Ms Shell Dlg"
141 -{
142 - LISTBOX IDC_PATHS, 7, 7, 269, 162, WS_TABSTOP | WS_VSCROLL | LBS_NOINTEGRALHEIGHT | LBS_SORT | LBS_NOTIFY, WS_EX_LEFT
143 -}
144143
 144+
145145 LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
146146 IDD_LOADING DIALOG 0, 0, 246, 41
147147 STYLE DS_3DLOOK | DS_CENTER | DS_MODALFRAME | DS_SHELLFONT | WS_BORDER | WS_VISIBLE | WS_POPUP | WS_SYSMENU
——@@ -153,6 +153,16 @@
154154
155155
156156
 157+LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
 158+IDD_PATHS DIALOG 0, 0, 283, 173
 159+STYLE DS_3DLOOK | DS_CENTER | DS_SHELLFONT | WS_VISIBLE | WS_CHILDWINDOW
 160+FONT 8, "Ms Shell Dlg"
 161+{
 162+ LISTBOX IDC_PATHS, 7, 7, 269, 162, WS_TABSTOP | WS_VSCROLL | LBS_NOINTEGRALHEIGHT | LBS_SORT | LBS_NOTIFY, WS_EX_LEFT
 163+}
 164+
 165+
 166+
157167 //
158168 // Icon resources
159169 //
——@@ -174,13 +184,13 @@
175185 //
176186 LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
177187 1 VERSIONINFO
178 - FILEVERSION DXGLVERNUMBER
179 - PRODUCTVERSION DXGLVERNUMBER
 188+ FILEVERSION 0,5,7,609
 189+ PRODUCTVERSION 0,5,7,609
180190 FILEOS VOS__WINDOWS32
181191 FILETYPE VFT_APP
182192 FILESUBTYPE VFT2_UNKNOWN
183 - FILEFLAGSMASK 0x00000000
184 - FILEFLAGS 0x00000000
 193+ FILEFLAGSMASK 0
 194+ FILEFLAGS 0
185195 {
186196 BLOCK "StringFileInfo"
187197 {
——@@ -187,12 +197,12 @@
188198 BLOCK "08000352"
189199 {
190200 VALUE "FileDescription", "DXGL Configuration Program"
191 - VALUE "FileVersion", DXGLVERSTRING
 201+ VALUE "FileVersion", "0.5.7 r609"
192202 VALUE "InternalName", "DXGL"
193203 VALUE "LegalCopyright", "Copyright © 2011-2015 William Feely"
194204 VALUE "OriginalFilename", "dxglcfg.exe"
195205 VALUE "ProductName", "DXGL"
196 - VALUE "ProductVersion", DXGLVERSTRING
 206+ VALUE "ProductVersion", "0.5.7 r609"
197207 }
198208 }
199209 BLOCK "VarFileInfo"
Index: dxglcfg2/resource.h
——@@ -47,3 +47,9 @@
4848 #define IDC_PROGRESS 1031
4949 #define IDC_DISPLAYNAME 1032
5050 #define IDC_PATHS 1033
 51+#define IDC_INTEGERSCALELABEL 1034
 52+#define IDC_INTEGERSCALELABELX 1035
 53+#define IDC_INTEGERSCALEX 1036
 54+#define IDC_INTEGERSCALELABELY 1037
 55+#define IDC_INTEGERSCALEY 1038
 56+#define IDC_INTEGERSCALESQUARE 1039