diff --git a/harbour/ChangeLog b/harbour/ChangeLog index 0cf5e18b0c..cff02d8cdf 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -16,6 +16,13 @@ The license applies to all entries newer than 2009-04-28. */ +2012-07-20 15:23 UTC-0800 Pritpal Bedi (bedipritpal@hotmail.com) + * contrib/hbide/idefindreplace.prg + ! Fixed: Find action in FindInFiles was opening the source in + "Main" view before searching. It should had been if source + is opened only then take it from editing instance otherwise + from disk. I suspect yesterday night I was too tired. + 2012-07-20 21:30 UTC+0200 Viktor Szakats (vszakats syenar.net) * contrib/gtwvg/tests/demowvg.prg * contrib/gtwvg/tests/wvgwvtclasses.prg diff --git a/harbour/contrib/hbide/idefindreplace.prg b/harbour/contrib/hbide/idefindreplace.prg index 13b9ec7074..5b326c767a 100644 --- a/harbour/contrib/hbide/idefindreplace.prg +++ b/harbour/contrib/hbide/idefindreplace.prg @@ -1251,8 +1251,12 @@ METHOD IdeFindInFiles:findInABunch( aFiles ) s := hbide_pathToOSPath( s ) IF hb_fileExists( s ) ::nSearched++ - ::oSM:editSource( s, 0, 0, 0, NIL, "Main", .f., .t. ) - aBuffer := hb_ATokens( StrTran( ::qCurEdit:toPlainText(), Chr( 13 ) ), Chr( 10 ) ) + IF ::oEM:isOpen( s ) + ::oSM:editSource( s, 0, 0, 0, NIL, "Main", .f., .t. ) + aBuffer := hb_ATokens( StrTran( ::qCurEdit:toPlainText(), Chr( 13 ) ), Chr( 10 ) ) + ELSE + aBuffer := hb_ATokens( StrTran( hb_MemoRead( s ), Chr( 13 ) ), Chr( 10 ) ) + ENDIF nLine := 0 IF ::lRegEx