summaryrefslogtreecommitdiff
path: root/src/T2DLL/T2Message.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/T2DLL/T2Message.cpp')
-rw-r--r--src/T2DLL/T2Message.cpp41
1 files changed, 23 insertions, 18 deletions
diff --git a/src/T2DLL/T2Message.cpp b/src/T2DLL/T2Message.cpp
index f8cf66f..15876af 100644
--- a/src/T2DLL/T2Message.cpp
+++ b/src/T2DLL/T2Message.cpp
@@ -7,16 +7,17 @@
static char THIS_FILE[] = __FILE__;
#endif
-static BOOL s100E3E08;
-
// unknown name - 100E3E0C
static BOOL sVisible;
+static BOOL s100E3E08;
+
T2Message::T2Message() {
}
void T2Message::ShowMessage(const CString& str) {
if (!sVisible) {
+#pragma var_order(rect, bmi, pixels, brushResult, y, pattern, cols, buffer, x)
sVisible = true;
s100E3E08 = true;
@@ -44,26 +45,27 @@ void T2Message::ShowMessage(const CString& str) {
cols[1].rgbBlue = 0;
unsigned char *pixels = ((unsigned char *) buffer) + sizeof(BITMAPINFOHEADER) + sizeof(RGBQUAD) * 2;
- unsigned char row[8];
- row[0] = 1;
- row[1] = 1;
- row[2] = 1;
- row[3] = 1;
- row[4] = 0;
- row[5] = 0;
- row[6] = 0;
- row[7] = 0;
-
- for (int y = 0; y < 8; y++) {
- for (int x = 0; x < 8; x++) {
- pixels[x + y * 8] = row[(x + y) % 8];
+ unsigned char pattern[8];
+ pattern[0] = 1;
+ pattern[1] = 1;
+ pattern[2] = 1;
+ pattern[3] = 1;
+ pattern[4] = 0;
+ pattern[5] = 0;
+ pattern[6] = 0;
+ pattern[7] = 0;
+
+ int x, y;
+ for (y = 0; y < 8; y++) {
+ for (x = 0; x < 8; x++) {
+ pixels[x + y * 8] = pattern[(x + y) % 8];
}
}
- int result = mBrush.CreateDIBPatternBrush((const void *) buffer, DIB_RGB_COLORS);
+ BOOL brushResult = mBrush.CreateDIBPatternBrush((const void *) buffer, DIB_RGB_COLORS);
free(buffer);
#line 64
- _ASSERT(result != 0);
+ _ASSERT(brushResult != false);
mString = AfxRegisterWndClass(CS_VREDRAW | CS_HREDRAW | CS_NOCLOSE, NULL, (HBRUSH) GetStockObject(WHITE_BRUSH));
@@ -103,6 +105,7 @@ int T2Message::OnCreate(CREATESTRUCT* cs) {
if (CWnd::OnCreate(cs) == -1)
return -1;
+#pragma var_order(desktopRect, save, str, cursorPos, clientRect, dc)
CString str;
GetWindowText(str);
@@ -229,7 +232,8 @@ void T2Message::OnDestroy() {
KillTimer(1);
}
-int T2Message::OnEraseBkgnd(CDC* dc) {
+BOOL T2Message::OnEraseBkgnd(CDC* dc) {
+#pragma var_order(rect2, brush, pen, save, rect1, brush2)
CRect rect1;
GetClientRect(rect1);
@@ -282,6 +286,7 @@ int T2Message::OnEraseBkgnd(CDC* dc) {
dc->SetBkMode(TRANSPARENT);
dc->SelectObject(mFont);
+#pragma var_order(textRect, str)
CString str;
GetWindowText(str);