Hi
I wonder, why the switch in the "win32 GUI projct"-Template looks like this:
switch(uMsg)
{
case WM_INITDIALOG:
{
// Code
}
return TRUE;
}
return FALSE;
And so this indentation is a bit confusing.
It should rather look like this:
switch(uMsg)
{
case WM_INITDIALOG:
// Code
return TRUE;
}
return FALSE;
Is there a reason for that format ?
normally you use the brackets in the case for scope separation...
So you can use variable i in case 0 and case 1...
see the example:
switch(cnt)
{
case 1:
{
int tmp = 22;
}
break;
case 2:
{
int tmp = 33;
}
break;
}
without brackets you would get the redefinition error...
greetings