diff --git a/harbour/ChangeLog b/harbour/ChangeLog index 048d6784a9..a5948c51f3 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -7,6 +7,8 @@ For example: 2002-12-01 23:12 UTC+0100 Foo Bar */ +2002-11-07 22:05 UTC-0300 Luiz Rafael Culik + ! due an little mistake i`ve posted xharbour code, i`ve reverted back to version 1.38 and applyed the patch 2002-11-07 08:30 UTC-0300 Luiz Rafael Culik * source/rtl/alert.prg ! minor fix to my change from yesterday diff --git a/harbour/source/rtl/alert.prg b/harbour/source/rtl/alert.prg index f3a448e87f..1cae9a1cba 100644 --- a/harbour/source/rtl/alert.prg +++ b/harbour/source/rtl/alert.prg @@ -33,8 +33,8 @@ /* TOFIX: Clipper defines a clipped window for Alert() [vszakats] */ /* NOTE: Clipper will return NIL if the first parameter is not a string, but - this is not documented. This implementation converts the first - parameter to a string if another type was passed. You can switch back + this is not documented. This implementation converts the first + parameter to a string if another type was passed. You can switch back to Clipper compatible mode by defining constant HB_C52_STRICT. [vszakats] */ @@ -60,7 +60,6 @@ FUNCTION Alert( xMessage, aOptions, cColorNorm, nDelay ) LOCAL nOldDispCount LOCAL nCount - LOCAL nIndex, nLen Local cNew,cOld,cTemp #ifdef HB_COMPAT_C53 @@ -70,8 +69,7 @@ FUNCTION Alert( xMessage, aOptions, cColorNorm, nDelay ) /* TOFIX: Clipper decides at runtime, whether the GT is linked in, if it is not, the console mode is choosen here. [vszakats] */ LOCAL lConsole := .F. - cOld:=xMessage - cNew:="" + #ifdef HB_C52_UNDOC DEFAULT s_lNoAlert TO hb_argCheck( "NOALERT" ) @@ -121,6 +119,7 @@ FUNCTION Alert( xMessage, aOptions, cColorNorm, nDelay ) CASE ValType( xMessage ) == "B" ; xMessage := "{||...}" OTHERWISE ; xMessage := "NIL" ENDCASE + if Len(cOld) >60 WHILE LEN(cOld) > 0 @@ -150,37 +149,13 @@ FUNCTION Alert( xMessage, aOptions, cColorNorm, nDelay ) endif + DO WHILE ( nPos := At( ';', xMessage ) ) != 0 AAdd( aSay, Left( xMessage, nPos - 1 ) ) xMessage := SubStr( xMessage, nPos + 1 ) ENDDO AAdd( aSay, xMessage ) - nIndex := 0 - FOR EACH xMessage IN aSay - nIndex++ - - IF ( nLen := Len( xMessage ) ) > 58 - FOR nPos := 58 TO 1 STEP -1 - IF xMessage[nPos] $ " " + Chr( 9 ) - EXIT - ENDIF - NEXT - - IF nPos == 0 - nPos := 58 - ENDIF - - aSay[ nIndex ] := RTrim( Left( xMessage, nPos ) ) - - IF Len( aSay ) == nIndex - aAdd( aSay, SubStr( xMessage, nPos + 1 ) ) - ELSE - aIns( aSay, nIndex + 1, SubStr( xMessage, nPos + 1 ), .T. ) - ENDIF - ENDIF - NEXT - ENDIF #endif