Commit f94159cd authored by Huw Davies's avatar Huw Davies Committed by Alexandre Julliard

Don't get confused if PSN_SETACTIVE returns a positive number that

isn't a resource id.
parent b37adfb4
......@@ -2028,19 +2028,25 @@ static BOOL PROPSHEET_SetCurSel(HWND hwndDlg,
index+=skipdir;
if (index < 0) {
index = 0;
FIXME("Tried to skip before first property sheet page!\n");
WARN("Tried to skip before first property sheet page!\n");
break;
}
if (index >= psInfo->nPages) {
FIXME("Tried to skip after last property sheet page!\n");
WARN("Tried to skip after last property sheet page!\n");
index = psInfo->nPages-1;
break;
}
}
else if (result != 0)
{
index = PROPSHEET_FindPageByResId(psInfo, result);
continue;
int old_index = index;
index = PROPSHEET_FindPageByResId(psInfo, result);
if(index >= psInfo->nPages) {
index = old_index;
WARN("Tried to skip to nonexistant page by res id\n");
break;
}
continue;
}
}
/*
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment