| 1157 | } |
| 1158 | |
| 1159 | void CollapseWindow(void) |
| 1160 | { |
| 1161 | RECT wrect; |
| 1162 | |
| 1163 | GetWindowRect(hwndMemWatch,&wrect); //Get currect window size |
| 1164 | |
| 1165 | if (!MemWCollapsed) //If window is full size collapse it |
| 1166 | { |
| 1167 | wrect.right = (wrect.right - ((wrect.right-wrect.left)/2)); |
| 1168 | MemWCollapsed = true; |
| 1169 | SetDlgItemText(hwndMemWatch, MEMW_EXPANDCOLLAPSE, ">"); |
| 1170 | ChangeMemwMenuItemText(MEMW_OPTIONS_EXPANDCOLLAPSE, "&Expand to 2 columns"); |
| 1171 | } |
| 1172 | else //Else expand it |
| 1173 | { |
| 1174 | wrect.right = (wrect.right + (wrect.right-wrect.left)); |
| 1175 | MemWCollapsed = false; |
| 1176 | SetDlgItemText(hwndMemWatch, MEMW_EXPANDCOLLAPSE, "<"); |
| 1177 | ChangeMemwMenuItemText(MEMW_OPTIONS_EXPANDCOLLAPSE, "&Collapse to 1 column"); |
| 1178 | } |
| 1179 | |
| 1180 | SetWindowPos(hwndMemWatch,NULL,MemWatch_wndx,MemWatch_wndy,(wrect.right-wrect.left),(wrect.bottom-wrect.top),NULL); |
| 1181 | } |
no test coverage detected