2011-02-06 11:14 UTC+0100 Viktor Szakats (harbour.01 syenar.hu)

* contrib/hbrunext/hbrunext.hbp
  * contrib/hbrunext/pullext.prg
  * utils/hbrun/hbrun.prg
    + Will now show the list of available extensions if any is linked.

  * INSTALL
    * watt homepage update. [Tamas]
This commit is contained in:
Viktor Szakats
2011-02-06 10:14:33 +00:00
parent a78f123db5
commit 8ab2bf32b2
5 changed files with 61 additions and 18 deletions

View File

@@ -16,6 +16,15 @@
The license applies to all entries newer than 2009-04-28.
*/
2011-02-06 11:14 UTC+0100 Viktor Szakats (harbour.01 syenar.hu)
* contrib/hbrunext/hbrunext.hbp
* contrib/hbrunext/pullext.prg
* utils/hbrun/hbrun.prg
+ Will now show the list of available extensions if any is linked.
* INSTALL
* watt homepage update. [Tamas]
2011-02-06 10:36 UTC+0100 Viktor Szakats (harbour.01 syenar.hu)
* contrib/hbct/keysec.prg
* contrib/hbct/keytime.prg

View File

@@ -1554,7 +1554,7 @@ HARBOUR
HB_WITH_SQLITE3 - sqlite3 [multiplatform, free, open-source]
http://www.sqlite.org/
HB_WITH_WATT - Watt-32 (TCP/IP sockets) [dos, free, open-source]
http://www.bgnett.no/~giva/
http://home.broadpark.no/~gvanem/
HB_WITH_ZLIB - zlib [multiplatform, free, open-source]
http://www.zlib.net/
HB_WITH_XDIFF - libxdiff (file differences/patches) [multiplatform, free, open-source]

View File

@@ -8,7 +8,7 @@
-o${hb_name}
-request=__HBRUN__PULLEXT
-request=__hbrun_extensions
pullext.prg
# Always build in shared mode for these platforms because the

View File

@@ -50,15 +50,20 @@
*
*/
ANNOUNCE __HBRUN__PULLEXT
FUNCTION __hbrun_extensions()
LOCAL aList := {}
REQUEST __HBEXTERN__HBCT__
REQUEST __HBEXTERN__HBEXPAT__
REQUEST __HBEXTERN__HBMEMIO__
REQUEST __HBEXTERN__HBMZIP__
#if defined( __PLATFORM__UNIX )
REQUEST __HBEXTERN__HBUNIX__
#endif
#if defined( __PLATFORM__WINDOWS )
REQUEST __HBEXTERN__HBWIN__
#endif
#xtranslate PULLEXT <cName> => REQUEST __HBEXTERN__<cName>__ ; AAdd( aList, Lower( <"cName"> ) )
PULLEXT hbct
PULLEXT hbexpat
PULLEXT hbmemio
PULLEXT hbmzip
#if defined( __PLATFORM__UNIX )
PULLEXT hbunix
#endif
#if defined( __PLATFORM__WINDOWS )
PULLEXT hbwin
#endif
RETURN aList

View File

@@ -80,7 +80,7 @@ REQUEST HB_GT_STD
#define HB_LINE_LEN 256
#define HB_PROMPT "."
STATIC s_nRow := 2
STATIC s_nRow
STATIC s_nCol := 0
STATIC s_aCompOptions := {}
STATIC s_aHistory := {}
@@ -279,6 +279,16 @@ EXIT PROCEDURE hbrun_exit()
RETURN
STATIC FUNCTION hbrun_extensionlist()
STATIC s_aList
IF s_aList == NIL
s_aList := iif( Type( "__HBRUN_EXTENSIONS()" ) == "UI", &("__hbrun_extensions()"), {} )
ASort( s_aList )
ENDIF
RETURN s_aList
STATIC FUNCTION hbrun_FileSig( cFile )
LOCAL hFile
LOCAL cBuff, cSig, cExt
@@ -333,6 +343,8 @@ STATIC PROCEDURE hbrun_Prompt( cCommand )
Set( _SET_EVENTMASK, hb_bitOr( INKEY_KEYBOARD, HB_INKEY_GTEVENT ) )
s_nRow := 2 + iif( Empty( hbrun_extensionlist() ), 0, 1 )
DO WHILE .T.
IF cLine == NIL
@@ -400,7 +412,7 @@ STATIC PROCEDURE hbrun_Prompt( cCommand )
hbrun_Exec( cCommand )
IF s_nRow >= MaxRow()
Scroll( 2, 0, MaxRow(), MaxCol(), 1 )
Scroll( 2 + iif( Empty( hbrun_extensionlist() ), 0, 1 ), 0, MaxRow(), MaxCol(), 1 )
s_nRow := MaxRow() - 1
ENDIF
@@ -448,9 +460,25 @@ STATIC PROCEDURE hbrun_Info( cCommand )
IF s_lPreserveHistory
hb_DispOutAt( 1, MaxCol(), "o", "R/BG" )
ENDIF
IF ! Empty( hbrun_extensionlist() )
hb_DispOutAt( 2, 0, PadR( "Ext: " + ArrayToList( hbrun_extensionlist() ), MaxCol() + 1 ), "W/B" )
ENDIF
RETURN
STATIC FUNCTION ArrayToList( array )
LOCAL cString := ""
LOCAL tmp
FOR tmp := 1 TO Len( array )
cString += array[ tmp ]
IF tmp < Len( array )
cString += ", "
ENDIF
NEXT
RETURN cString
/* ********************************************************************** */
STATIC PROCEDURE hbrun_Err( oErr, cCommand )
@@ -481,7 +509,7 @@ STATIC PROCEDURE hbrun_Err( oErr, cCommand )
/* ********************************************************************** */
STATIC PROCEDURE hbrun_Exec( cCommand )
LOCAL pHRB, cHRB, cFunc, bBlock, cEol
LOCAL pHRB, cHRB, cFunc, bBlock, cEol, nRowMin
cEol := hb_eol()
cFunc := "STATIC FUNC __HBDOT()" + cEol + ;
@@ -503,8 +531,9 @@ STATIC PROCEDURE hbrun_Exec( cCommand )
Eval( bBlock )
s_nRow := Row()
s_nCol := Col()
IF s_nRow < 2
s_nRow := 2
nRowMin := 2 + iif( Empty( hbrun_extensionlist() ), 0, 1 )
IF s_nRow < nRowMin
s_nRow := nRowMin
ENDIF
ENDIF
ENDIF