2008-07-30 03:11 UTC+0200 Viktor Szakats (harbour.01 syenar hu)

* source/rtl/memoedit.prg
     ! Fixed to never popup "Abort (Y/N)" when pressing <Esc> 
       in case a user function is used with MemoEdit().
This commit is contained in:
Viktor Szakats
2008-07-30 01:11:29 +00:00
parent 8bdb46266a
commit 501287dfd0
2 changed files with 27 additions and 23 deletions

View File

@@ -8,6 +8,11 @@
2008-12-31 13:59 UTC+0100 Foo Bar <foo.bar@foobar.org>
*/
2008-07-30 03:11 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* source/rtl/memoedit.prg
! Fixed to never popup "Abort (Y/N)" when pressing <Esc>
in case a user function is used with MemoEdit().
2008-07-30 01:15 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* source/rtl/gtwvt/gtwvt.c
! Fixed recent MSVC warning. Please test on WinCE/pre-1200

View File

@@ -147,31 +147,30 @@ METHOD KeyboardHook( nKey ) CLASS HBMemoEditor
LOCAL nRow
LOCAL nCol
IF nKey == K_ESC
IF ::lDirty .AND. Set( _SET_SCOREBOARD )
cBackScr := SaveScreen( ::nTop, ::nRight - 18, ::nTop, ::nRight )
nRow := Row()
nCol := Col()
@ ::nTop, ::nRight - 18 SAY "Abort Edit? (Y/N)"
nYesNoKey := Inkey( 0 )
RestScreen( ::nTop, ::nRight - 18, ::nTop, ::nRight, cBackScr )
SetPos( nRow, nCol )
IF Upper( Chr( nYesNoKey ) ) == "Y"
::lSaved := .F.
::lExitEdit := .T.
ENDIF
ELSE
::lExitEdit := .T.
ENDIF
ENDIF
IF ISCHARACTER( ::xUserFunction )
::HandleUserKey( nKey, ::xDo( iif( ::lDirty, ME_UNKEYX, ME_UNKEY ) ) )
ELSE
IF nKey == K_ESC
IF ::lDirty .AND. Set( _SET_SCOREBOARD )
cBackScr := SaveScreen( ::nTop, ::nRight - 18, ::nTop, ::nRight )
nRow := Row()
nCol := Col()
@ ::nTop, ::nRight - 18 SAY "Abort Edit? (Y/N)"
nYesNoKey := Inkey( 0 )
RestScreen( ::nTop, ::nRight - 18, ::nTop, ::nRight, cBackScr )
SetPos( nRow, nCol )
IF Upper( Chr( nYesNoKey ) ) == "Y"
::lSaved := .F.
::lExitEdit := .T.
ENDIF
ELSE
::lExitEdit := .T.
ENDIF
ENDIF
ENDIF
RETURN Self