![]() |
Vista: CXTPTaskDialog::PreTranslateMessage problem |
Post Reply
|
| Author | |
znakeeye
Senior Member
Joined: 26 July 2006 Status: Offline Points: 1672 |
Post Options
Thanks(0)
Quote Reply
Topic: Vista: CXTPTaskDialog::PreTranslateMessage problemPosted: 08 October 2008 at 11:31am |
|
CMyTaskDialog dlg;
dlg.DoModal(FALSE);
In XP, the code below works. In Vista, it does not. What could be wrong?!
BOOL CMyTaskDialog::PreTranslateMessage(MSG* pMsg)
{ if (pMsg->message == WM_KEYDOWN) { if (GetKeyState(VK_CONTROL) & 0x8000) { // Ctrl+C and Ctrl+Insert should copy the message text to the Clipboard. if (pMsg->wParam == 'C' || pMsg->wParam == VK_INSERT) { CopyToClipboard(); } } } return CXTPTaskDialog::PreTranslateMessage(pMsg); |
|
![]() |
|
Oleg
Senior Member
Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
Quote Reply
Posted: 09 October 2008 at 1:26am |
|
If you set Breakpoint inside first 'If' its executed ? if outside ?
replace
if (GetKeyState(VK_CONTROL) & 0x8000)
to
if (GetKeyState(VK_CONTROL) < 0)
|
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
znakeeye
Senior Member
Joined: 26 July 2006 Status: Offline Points: 1672 |
Post Options
Thanks(0)
Quote Reply
Posted: 10 October 2008 at 3:29am |
|
Thanks for your reply. The problem was on our side (I had no access to a Vista machine so I could not debug this immediately).
Anyway, you should not rely on the return value from GlobalUnlock() in Vista =)
|
|
![]() |
|
Oleg
Senior Member
Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
Quote Reply
Posted: 10 October 2008 at 6:28am |
|
:) ok
|
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
Post Reply
|
|
|
Tweet
|
| Forum Jump | Forum Permissions ![]() You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |