mirror of
git://xwords.git.sourceforge.net/gitroot/xwords/xwords
synced 2025-01-13 08:01:33 +01:00
Track EDITTEXTs in dialogs when following focus with scroll position.
This seems to fix bug where conns dialog wouldn't scroll on Smartphone, though I'm not sure why.
This commit is contained in:
parent
32916d2918
commit
fa5d36517a
2 changed files with 9 additions and 6 deletions
|
@ -566,11 +566,12 @@ XP_Bool
|
|||
ceDoDlgHandle( CeDlgHdr* dlgHdr, UINT message, WPARAM wParam, LPARAM lParam )
|
||||
{
|
||||
XP_Bool handled = XP_FALSE;
|
||||
XP_U16 hiword = HIWORD(wParam);
|
||||
|
||||
switch( message ) {
|
||||
#ifdef OVERRIDE_BACKKEY
|
||||
case WM_HOTKEY:
|
||||
if ( VK_TBACK == HIWORD(lParam) ) {
|
||||
if ( VK_TBACK == hiword ) {
|
||||
if ( editHasFocus() ) {
|
||||
SHSendBackToFocusWindow( message, wParam, lParam );
|
||||
} else if ( 0 != (BACK_KEY_UP_MAYBE & LOWORD(lParam) ) ) {
|
||||
|
@ -589,11 +590,11 @@ ceDoDlgHandle( CeDlgHdr* dlgHdr, UINT message, WPARAM wParam, LPARAM lParam )
|
|||
|
||||
case WM_LBUTTONDOWN:
|
||||
dlgHdr->penDown = XP_TRUE;
|
||||
dlgHdr->prevY = HIWORD(lParam);
|
||||
dlgHdr->prevY = hiword;
|
||||
handled = XP_TRUE;
|
||||
break;
|
||||
case WM_MOUSEMOVE:
|
||||
scrollForMove( dlgHdr, HIWORD(lParam) );
|
||||
scrollForMove( dlgHdr, hiword );
|
||||
handled = XP_TRUE;
|
||||
break;
|
||||
case WM_LBUTTONUP:
|
||||
|
@ -602,10 +603,11 @@ ceDoDlgHandle( CeDlgHdr* dlgHdr, UINT message, WPARAM wParam, LPARAM lParam )
|
|||
break;
|
||||
|
||||
case WM_COMMAND:
|
||||
if ( BN_SETFOCUS == HIWORD(wParam) ) {
|
||||
if ( BN_SETFOCUS == hiword || EN_SETFOCUS == hiword ) {
|
||||
ceDoDlgFocusScroll( dlgHdr, (HWND)lParam );
|
||||
handled = TRUE;
|
||||
} else if ( BN_KILLFOCUS == HIWORD(wParam) ) { /* dialogs shouldn't have to handle this */
|
||||
} else if ( BN_KILLFOCUS == hiword || EN_KILLFOCUS == hiword ) {
|
||||
/* dialogs shouldn't have to handle these */
|
||||
handled = TRUE;
|
||||
}
|
||||
break;
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
/* -*-mode: C; fill-column: 77; c-basic-offset: 4; -*- */
|
||||
/*
|
||||
* Copyright 2002-2004 by Eric House (xwords@eehouse.org). All rights reserved.
|
||||
* Copyright 2002 - 2009 by Eric House (xwords@eehouse.org). All rights
|
||||
* reserved.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
|
Loading…
Reference in a new issue