2012-10-08 19:32 UTC+0200 Viktor Szakats (harbour syenar.net)
* contrib/xhb/dbgfx.prg
* contrib/xhb/decode.prg
* contrib/xhb/dumpvar.prg
* contrib/xhb/hblognet.prg
* contrib/xhb/hjwindow.prg
* contrib/xhb/htjlist.prg
* contrib/xhb/htmutil.prg
* contrib/xhb/stream.prg
* contrib/xhb/tcgi.prg
* contrib/xhb/tedit.prg
* contrib/xhb/tfile.prg
* contrib/xhb/tframe.prg
* contrib/xhb/thtm.prg
* contrib/xhb/ttable.prg
* contrib/xhb/txml.prg
* contrib/xhb/xhbcomp.prg
* contrib/xhb/xhberr.prg
* contrib/xhb/xhbfunp.prg
* contrib/xhb/xhbmemo.prg
* contrib/xhb/xhbole.prg
* contrib/xhb/xhbtedit.prg
* contrib/xhb/xhw32prn.prg
* use __defaultNIL() instead of DEFAULT TO
* deleted common.ch from all files
This commit is contained in:
@@ -16,6 +16,32 @@
|
||||
The license applies to all entries newer than 2009-04-28.
|
||||
*/
|
||||
|
||||
2012-10-08 19:32 UTC+0200 Viktor Szakats (harbour syenar.net)
|
||||
* contrib/xhb/dbgfx.prg
|
||||
* contrib/xhb/decode.prg
|
||||
* contrib/xhb/dumpvar.prg
|
||||
* contrib/xhb/hblognet.prg
|
||||
* contrib/xhb/hjwindow.prg
|
||||
* contrib/xhb/htjlist.prg
|
||||
* contrib/xhb/htmutil.prg
|
||||
* contrib/xhb/stream.prg
|
||||
* contrib/xhb/tcgi.prg
|
||||
* contrib/xhb/tedit.prg
|
||||
* contrib/xhb/tfile.prg
|
||||
* contrib/xhb/tframe.prg
|
||||
* contrib/xhb/thtm.prg
|
||||
* contrib/xhb/ttable.prg
|
||||
* contrib/xhb/txml.prg
|
||||
* contrib/xhb/xhbcomp.prg
|
||||
* contrib/xhb/xhberr.prg
|
||||
* contrib/xhb/xhbfunp.prg
|
||||
* contrib/xhb/xhbmemo.prg
|
||||
* contrib/xhb/xhbole.prg
|
||||
* contrib/xhb/xhbtedit.prg
|
||||
* contrib/xhb/xhw32prn.prg
|
||||
* use __defaultNIL() instead of DEFAULT TO
|
||||
* deleted common.ch from all files
|
||||
|
||||
2012-10-08 19:14 UTC+0200 Viktor Szakats (harbour syenar.net)
|
||||
* contrib/xhb/hjwindow.prg
|
||||
* contrib/xhb/htmutil.prg
|
||||
@@ -164164,7 +164190,6 @@
|
||||
* contrib/xhb/makefile.vc
|
||||
* removed the "-TP" (force source as c++) msvc compiler flag
|
||||
|
||||
|
||||
2007-11-03 02:35 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
|
||||
* harbour/contrib/bmdbfcdx/bmdbfcdx1.c
|
||||
* replaced all direct access to hb_set structure with functions
|
||||
|
||||
@@ -50,7 +50,6 @@
|
||||
*
|
||||
*/
|
||||
|
||||
#include "common.ch"
|
||||
#include "fileio.ch"
|
||||
|
||||
STATIC s_lToOutDebug := .T.
|
||||
@@ -103,7 +102,7 @@ PROCEDURE HB_ToLogFile( cLogFile, ... )
|
||||
RETURN
|
||||
ENDIF
|
||||
|
||||
DEFAULT cLogFile TO "logfile.log"
|
||||
__defaultNIL( @cLogFile, "logfile.log" )
|
||||
|
||||
IF cLogFile != NIL
|
||||
|
||||
|
||||
@@ -51,8 +51,6 @@
|
||||
*
|
||||
*/
|
||||
|
||||
#include "common.ch"
|
||||
|
||||
/*
|
||||
PROCEDURE Main()
|
||||
LOCAL aArray
|
||||
|
||||
@@ -51,7 +51,6 @@
|
||||
*/
|
||||
|
||||
#include "hbclass.ch"
|
||||
#include "common.ch"
|
||||
|
||||
/*
|
||||
* (C) 2003 - Francesco Saverio Giudice
|
||||
@@ -88,7 +87,7 @@ FUNCTION HB_DumpVar( xVar, lRecursive, nMaxRecursionLevel )
|
||||
|
||||
// TraceLog( "HB_DumpVariable: xVar, lAssocAsObj, lRecursive", xVar, lAssocAsObj, lRecursive )
|
||||
|
||||
DEFAULT nMaxRecursionLevel TO 0
|
||||
__defaultNIL( @nMaxRecursionLevel, 0 )
|
||||
|
||||
RETURN __HB_DumpVar( xVar, , lRecursive, nIndent, nRecursionLevel, nMaxRecursionLevel )
|
||||
|
||||
@@ -98,8 +97,8 @@ STATIC FUNCTION __HB_DumpVar( xVar, lAssocAsObj, lRecursive, nIndent, nRecursion
|
||||
LOCAL cString := "", cKey
|
||||
LOCAL nEolLen
|
||||
|
||||
DEFAULT lAssocAsObj TO .F.
|
||||
DEFAULT lRecursive TO .F.
|
||||
__defaultNIL( @lAssocAsObj, .F. )
|
||||
__defaultNIL( @lRecursive, .F. )
|
||||
|
||||
// TraceLog( "Recursion: xVar, nRecursionLevel, nMaxRecursionLevel", xVar, nRecursionLevel, nMaxRecursionLevel )
|
||||
|
||||
@@ -177,7 +176,7 @@ STATIC FUNCTION DShowProperties( oVar, nScope, lRecursive, nIndent, nRecursionLe
|
||||
LOCAL aMethods, aMth
|
||||
LOCAL cString := ""
|
||||
|
||||
DEFAULT nIndent TO 0
|
||||
__defaultNIL( @nIndent, 0 )
|
||||
|
||||
IF HB_ISOBJECT( oVar )
|
||||
// lOldScope := __SetClassScope( .F. )
|
||||
@@ -216,7 +215,7 @@ STATIC FUNCTION DShowArray( aVar, lRecursive, nIndent, nRecursionLevel, nMaxRecu
|
||||
LOCAL xVal, nChar, nEolLen
|
||||
LOCAL cString := ""
|
||||
|
||||
DEFAULT nIndent TO 0
|
||||
__defaultNIL( @nIndent, 0 )
|
||||
|
||||
//TraceLog( "DShowArray: aVar, lRecursive", aVar, lRecursive )
|
||||
|
||||
@@ -247,7 +246,7 @@ STATIC FUNCTION DShowHash( hVar, lRecursive, nIndent, nRecursionLevel, nMaxRecur
|
||||
LOCAL nEolLen
|
||||
LOCAL cString := ""
|
||||
|
||||
DEFAULT nIndent TO 0
|
||||
__defaultNIL( @nIndent, 0 )
|
||||
|
||||
//TraceLog( "DShowHash: hVar, ValType( hVar ), lRecursive", hVar, ValType( hVar ), ValToPrg( hVar ), lRecursive )
|
||||
|
||||
|
||||
@@ -50,7 +50,6 @@
|
||||
*/
|
||||
|
||||
#include "hbclass.ch"
|
||||
#include "common.ch"
|
||||
|
||||
#define CRLF Chr( 13 ) + Chr( 10 )
|
||||
|
||||
|
||||
@@ -45,7 +45,6 @@
|
||||
*/
|
||||
|
||||
#include "hbclass.ch"
|
||||
#include "common.ch"
|
||||
#include "cgi.ch"
|
||||
|
||||
CLASS TJsWindow
|
||||
@@ -131,13 +130,13 @@ ENDCLASS
|
||||
|
||||
METHOD New( cVarName, cUrl, cName, x, y, w, h ) CLASS TJsWindow
|
||||
|
||||
DEFAULT cVarName TO "newWin"
|
||||
DEFAULT cURL TO " "
|
||||
DEFAULT cName TO cVarName
|
||||
DEFAULT x TO 100
|
||||
DEFAULT y TO 100
|
||||
DEFAULT h TO 300
|
||||
DEFAULT w TO 300
|
||||
__defaultNIL( @cVarName, "newWin" )
|
||||
__defaultNIL( @cURL, " " )
|
||||
__defaultNIL( @cName, cVarName )
|
||||
__defaultNIL( @x, 100 )
|
||||
__defaultNIL( @y, 100 )
|
||||
__defaultNIL( @h, 300 )
|
||||
__defaultNIL( @w, 300 )
|
||||
|
||||
::nH := HtmlPageHandle()
|
||||
::oHtm := HtmlPageObject()
|
||||
@@ -165,19 +164,19 @@ METHOD SetFeatures( alwaysRaised, alwaysLowered, ;
|
||||
|
||||
LOCAL cStr := ""
|
||||
|
||||
DEFAULT alwaysRaised TO ::alwaysRaised
|
||||
DEFAULT alwaysLowered TO ::alwaysLowered
|
||||
DEFAULT Resizable TO ::Resizable
|
||||
DEFAULT Menubar TO ::Menubar
|
||||
DEFAULT personalBar TO ::personalBar
|
||||
DEFAULT dependent TO ::dependent
|
||||
DEFAULT location TO ::location
|
||||
DEFAULT directories TO ::directories
|
||||
DEFAULT Scrollbars TO ::Scrollbars
|
||||
DEFAULT Status TO ::Status
|
||||
DEFAULT TitleBar TO ::TitleBar
|
||||
DEFAULT Toolbar TO ::Toolbar
|
||||
DEFAULT copyHistory TO ::copyHistory
|
||||
__defaultNIL( @alwaysRaised, ::alwaysRaised )
|
||||
__defaultNIL( @alwaysLowered, ::alwaysLowered )
|
||||
__defaultNIL( @Resizable, ::Resizable )
|
||||
__defaultNIL( @Menubar, ::Menubar )
|
||||
__defaultNIL( @personalBar, ::personalBar )
|
||||
__defaultNIL( @dependent, ::dependent )
|
||||
__defaultNIL( @location, ::location )
|
||||
__defaultNIL( @directories, ::directories )
|
||||
__defaultNIL( @Scrollbars, ::Scrollbars )
|
||||
__defaultNIL( @Status, ::Status )
|
||||
__defaultNIL( @TitleBar, ::TitleBar )
|
||||
__defaultNIL( @Toolbar, ::Toolbar )
|
||||
__defaultNIL( @copyHistory, ::copyHistory )
|
||||
|
||||
IF alwaysRaised
|
||||
cStr += "alwaysraised=yes,"
|
||||
@@ -259,10 +258,10 @@ METHOD SetSize( x, y, h, w ) CLASS TJsWindow
|
||||
|
||||
LOCAL cStr := ""
|
||||
|
||||
DEFAULT x TO ::ScreenX
|
||||
DEFAULT y TO ::ScreenY
|
||||
DEFAULT h TO ::height
|
||||
DEFAULT w TO ::width
|
||||
__defaultNIL( @x, ::ScreenX )
|
||||
__defaultNIL( @y, ::ScreenY )
|
||||
__defaultNIL( @h, ::height )
|
||||
__defaultNIL( @w, ::width )
|
||||
|
||||
::ScreenX := x
|
||||
::ScreenY := y
|
||||
@@ -430,7 +429,7 @@ METHOD ImageURL( cImage, cUrl, nHeight, nBorder, ;
|
||||
|
||||
LOCAL cStr := ""
|
||||
|
||||
DEFAULT cUrl TO ""
|
||||
__defaultNIL( @cUrl, "" )
|
||||
|
||||
IF cName != NIL
|
||||
cStr += ' NAME= "' + cName + '"' + CRLF()
|
||||
|
||||
@@ -49,7 +49,6 @@
|
||||
*/
|
||||
|
||||
#include "hbclass.ch"
|
||||
#include "common.ch"
|
||||
#include "cgi.ch"
|
||||
|
||||
CLASS TJsList
|
||||
@@ -98,16 +97,16 @@ METHOD New( name, lOpen, width, height, bgColor, ;
|
||||
|
||||
LOCAL cStr
|
||||
|
||||
DEFAULT name TO "l"
|
||||
DEFAULT lOpen TO .F.
|
||||
DEFAULT WIDTH TO 200
|
||||
DEFAULT HEIGHT TO 22
|
||||
DEFAULT BGCOLOR TO "white"
|
||||
DEFAULT FONT TO "Verdana"
|
||||
DEFAULT fntColor TO "black"
|
||||
DEFAULT fntSize TO 2
|
||||
DEFAULT cMinusImg TO "minus.gif"
|
||||
DEFAULT cPlusImg TO "plus.gif"
|
||||
__defaultNIL( @name, "l" )
|
||||
__defaultNIL( @lOpen, .F. )
|
||||
__defaultNIL( @WIDTH, 200 )
|
||||
__defaultNIL( @HEIGHT, 22 )
|
||||
__defaultNIL( @BGCOLOR, "white" )
|
||||
__defaultNIL( @FONT, "Verdana" )
|
||||
__defaultNIL( @fntColor, "black" )
|
||||
__defaultNIL( @fntSize, 2 )
|
||||
__defaultNIL( @cMinusImg, "minus.gif" )
|
||||
__defaultNIL( @cPlusImg, "plus.gif" )
|
||||
|
||||
::font := FONT
|
||||
::size := fntSize
|
||||
@@ -157,10 +156,10 @@ METHOD NewNode( name, lOpen, width, height, bgColor ) CLASS TJsList
|
||||
|
||||
LOCAL cStr := ""
|
||||
|
||||
DEFAULT lOpen TO .F.
|
||||
DEFAULT WIDTH TO 200
|
||||
DEFAULT HEIGHT TO 22
|
||||
DEFAULT BGCOLOR TO "white"
|
||||
__defaultNIL( @lOpen, .F. )
|
||||
__defaultNIL( @WIDTH, 200 )
|
||||
__defaultNIL( @HEIGHT, 22 )
|
||||
__defaultNIL( @BGCOLOR, "white" )
|
||||
cStr += "" //SPACE(10)
|
||||
cStr += name + "= new List("
|
||||
cStr += iif( lOpen, "true,", "false," )
|
||||
@@ -186,10 +185,10 @@ METHOD SetFont( name, font, fntColor, fntSize ) CLASS TJsList
|
||||
|
||||
LOCAL cStr := ""
|
||||
|
||||
DEFAULT name TO ::cCurrentNode
|
||||
DEFAULT FONT TO ::font
|
||||
DEFAULT fntColor TO ::fontColor
|
||||
DEFAULT fntSize TO ::Size
|
||||
__defaultNIL( @name, ::cCurrentNode )
|
||||
__defaultNIL( @FONT, ::font )
|
||||
__defaultNIL( @fntColor, ::fontColor )
|
||||
__defaultNIL( @fntSize, ::Size )
|
||||
|
||||
cStr += name + [.setFont("<FONT ] + ;
|
||||
[ FACE = '] + font + [' ] + ;
|
||||
@@ -212,8 +211,8 @@ METHOD AddItem( name, url, bgColor ) CLASS TJsList
|
||||
LOCAL cStr := ""
|
||||
LOCAL cUrl
|
||||
|
||||
DEFAULT name TO "o"
|
||||
DEFAULT url TO ""
|
||||
__defaultNIL( @name, "o" )
|
||||
__defaultNIL( @url, "" )
|
||||
cUrl := [<A HREF='] + url + ['>] + htmlSpace( 2 ) + name + htmlSpace( 2 )
|
||||
cStr += ::cCurrentNode + '.addItem( "' + cUrl + '"' + iif( bgColor != NIL, ',"' + bgColor + '"', "" ) + ');' + CRLF()
|
||||
::nItems++
|
||||
@@ -232,9 +231,9 @@ METHOD AddLink( name, url, img, bgColor ) CLASS TJsList
|
||||
LOCAL cStr := ""
|
||||
LOCAL cUrl
|
||||
|
||||
DEFAULT name TO "o"
|
||||
DEFAULT url TO ""
|
||||
DEFAULT img TO "webpage.jpg"
|
||||
__defaultNIL( @name, "o" )
|
||||
__defaultNIL( @url, "" )
|
||||
__defaultNIL( @img, "webpage.jpg" )
|
||||
cUrl := "<A HREF='" + url + "'><IMG SRC='" + img + "' border=0 align=absmiddle>" + htmlSpace( 2 ) + name + htmlSpace( 2 )
|
||||
cStr += ::cCurrentNode + '.addItem( "' + curl + '"' + iif( bgColor != NIL, ',"' + bgColor + '"', "" ) + ');' + CRLF()
|
||||
::nItems++
|
||||
@@ -259,8 +258,8 @@ METHOD Build( xPos, yPos ) CLASS TJsList
|
||||
LOCAL i
|
||||
LOCAL cStr := ""
|
||||
|
||||
DEFAULT xPos TO 5
|
||||
DEFAULT yPos TO 5
|
||||
__defaultNIL( @xPos, 5 )
|
||||
__defaultNIL( @yPos, 5 )
|
||||
|
||||
cStr += ::cMainNode + ".build(" + hb_ntos( xPos ) + "," + hb_ntos( yPos ) + ");" + CRLF()
|
||||
cStr += "}" + CRLF()
|
||||
|
||||
@@ -44,7 +44,6 @@
|
||||
*
|
||||
*/
|
||||
|
||||
#include "common.ch"
|
||||
#include "html.ch"
|
||||
#include "hbclass.ch"
|
||||
|
||||
@@ -58,7 +57,7 @@ STATIC s_aGreek := {}
|
||||
|
||||
PROCEDURE BackButton( cImage, oHtm )
|
||||
|
||||
DEFAULT cImage TO "back.gif"
|
||||
__defaultNIL( @cImage, "back.gif" )
|
||||
|
||||
IF oHtm == NIL
|
||||
oHtm := HtmlPageObject()
|
||||
@@ -116,12 +115,12 @@ FUNCTION PutCounter( oHtm, nNumber, cDir, nDigits, nWidth, bgColor, nBorder )
|
||||
oHtm := HtmlPageObject()
|
||||
ENDIF
|
||||
|
||||
DEFAULT nNumber TO 0
|
||||
DEFAULT cDir TO "/images/counters/"
|
||||
DEFAULT nWidth TO 50
|
||||
DEFAULT nDigits TO Len( hb_ntos( nNumber ) )
|
||||
DEFAULT nBorder TO 1
|
||||
DEFAULT BGCOLOR TO "black"
|
||||
__defaultNIL( @nNumber, 0 )
|
||||
__defaultNIL( @cDir, "/images/counters/" )
|
||||
__defaultNIL( @nWidth, 50 )
|
||||
__defaultNIL( @nDigits, Len( hb_ntos( nNumber ) ) )
|
||||
__defaultNIL( @nBorder, 1 )
|
||||
__defaultNIL( @BGCOLOR, "black" )
|
||||
|
||||
IF HB_ISNUMERIC( nNumber )
|
||||
cStr := StrZero( nNumber, nDigits )
|
||||
@@ -158,8 +157,8 @@ PROCEDURE htmlBrowse( oHtm, cAction, lUseLinks )
|
||||
LOCAL aFlds := dbStruct()
|
||||
LOCAL cAlign
|
||||
|
||||
DEFAULT cAction TO "confirm('RECORD: '+this.name+'\nPlace your action here !!!')"
|
||||
DEFAULT lUseLinks TO .F.
|
||||
__defaultNIL( @cAction, "confirm('RECORD: '+this.name+'\nPlace your action here !!!')" )
|
||||
__defaultNIL( @lUseLinks, .F. )
|
||||
|
||||
/*
|
||||
// browse caption...
|
||||
@@ -231,8 +230,8 @@ PROCEDURE htmlBrowseSql( oHtm, cAction, lUseLinks, cTarget, oServer, oQuery )
|
||||
|
||||
LOCAL cAlign
|
||||
|
||||
DEFAULT cAction TO "confirm('RECORD: '+this.name+'\nPlace your action here !!!')"
|
||||
DEFAULT lUseLinks TO .F.
|
||||
__defaultNIL( @cAction, "confirm('RECORD: '+this.name+'\nPlace your action here !!!')" )
|
||||
__defaultNIL( @lUseLinks, .F. )
|
||||
|
||||
/*
|
||||
// browse caption...
|
||||
@@ -387,13 +386,13 @@ ENDCLASS
|
||||
|
||||
METHOD New( cVarName, cUrl, cName, x, y, w, h ) CLASS JWindow
|
||||
|
||||
DEFAULT cVarName TO "newWin"
|
||||
DEFAULT cURL TO " "
|
||||
DEFAULT cName TO cVarName //"newWin"
|
||||
DEFAULT x TO 100
|
||||
DEFAULT y TO 100
|
||||
DEFAULT h TO 300
|
||||
DEFAULT w TO 300
|
||||
__defaultNIL( @cVarName, "newWin" )
|
||||
__defaultNIL( @cURL, " " )
|
||||
__defaultNIL( @cName, cVarName )
|
||||
__defaultNIL( @x, 100 )
|
||||
__defaultNIL( @y, 100 )
|
||||
__defaultNIL( @h, 300 )
|
||||
__defaultNIL( @w, 300 )
|
||||
|
||||
::nH := HtmlPageHandle()
|
||||
::oHtm := HtmlPageObject()
|
||||
@@ -425,19 +424,19 @@ METHOD SetFeatures( alwaysRaised, alwaysLowered, ;
|
||||
|
||||
LOCAL cStr := ""
|
||||
|
||||
DEFAULT alwaysRaised TO ::alwaysRaised
|
||||
DEFAULT alwaysLowered TO ::alwaysLowered
|
||||
DEFAULT Resizable TO ::Resizable
|
||||
DEFAULT Menubar TO ::Menubar
|
||||
DEFAULT personalBar TO ::personalBar
|
||||
DEFAULT dependent TO ::dependent
|
||||
DEFAULT location TO ::location
|
||||
DEFAULT directories TO ::directories
|
||||
DEFAULT Scrollbars TO ::Scrollbars
|
||||
DEFAULT Status TO ::Status
|
||||
DEFAULT TitleBar TO ::TitleBar
|
||||
DEFAULT Toolbar TO ::Toolbar
|
||||
DEFAULT copyHistory TO ::copyHistory
|
||||
__defaultNIL( @alwaysRaised, ::alwaysRaised )
|
||||
__defaultNIL( @alwaysLowered, ::alwaysLowered )
|
||||
__defaultNIL( @Resizable, ::Resizable )
|
||||
__defaultNIL( @Menubar, ::Menubar )
|
||||
__defaultNIL( @personalBar, ::personalBar )
|
||||
__defaultNIL( @dependent, ::dependent )
|
||||
__defaultNIL( @location, ::location )
|
||||
__defaultNIL( @directories, ::directories )
|
||||
__defaultNIL( @Scrollbars, ::Scrollbars )
|
||||
__defaultNIL( @Status, ::Status )
|
||||
__defaultNIL( @TitleBar, ::TitleBar )
|
||||
__defaultNIL( @Toolbar, ::Toolbar )
|
||||
__defaultNIL( @copyHistory, ::copyHistory )
|
||||
|
||||
IF alwaysRaised
|
||||
cStr += "alwaysraised=yes,"
|
||||
@@ -521,10 +520,10 @@ METHOD SetSize( x, y, h, w ) CLASS JWindow
|
||||
|
||||
LOCAL cStr := ""
|
||||
|
||||
DEFAULT x TO ::ScreenX
|
||||
DEFAULT y TO ::ScreenY
|
||||
DEFAULT h TO ::height
|
||||
DEFAULT w TO ::width
|
||||
__defaultNIL( @x, ::ScreenX )
|
||||
__defaultNIL( @y, ::ScreenY )
|
||||
__defaultNIL( @h, ::height )
|
||||
__defaultNIL( @w, ::width )
|
||||
|
||||
::ScreenX := x
|
||||
::ScreenY := y
|
||||
@@ -698,7 +697,7 @@ METHOD ImageURL( cImage, cUrl, nHeight, nBorder, ;
|
||||
|
||||
LOCAL cStr := ""
|
||||
|
||||
DEFAULT cUrl TO ""
|
||||
__defaultNIL( @cUrl, "" )
|
||||
|
||||
IF cName != NIL
|
||||
cStr += ' NAME= "' + cName + '"' + CRLF()
|
||||
|
||||
@@ -52,7 +52,6 @@
|
||||
|
||||
#include "hbclass.ch"
|
||||
|
||||
#include "common.ch"
|
||||
#include "fileio.ch"
|
||||
|
||||
#xtranslate THROW(<oErr>) => (Eval(ErrorBlock(), <oErr>), Break(<oErr>))
|
||||
@@ -219,7 +218,7 @@ METHOD New( cFile, nMode ) CLASS TStreamFileWriter
|
||||
::cFile := cFile
|
||||
|
||||
IF hb_FileExists( cFile )
|
||||
DEFAULT nMode TO FO_READWRITE
|
||||
__defaultNIL( @nMode, FO_READWRITE )
|
||||
|
||||
::Handle := FOpen( cFile, nMode )
|
||||
IF ::Handle <= 0
|
||||
@@ -229,7 +228,7 @@ METHOD New( cFile, nMode ) CLASS TStreamFileWriter
|
||||
::nLength := FSeek( ::Handle, 0, FS_END )
|
||||
::nPosition := ::nLength
|
||||
ELSE
|
||||
DEFAULT nMode TO FC_NORMAL
|
||||
__defaultNIL( @nMode, FC_NORMAL )
|
||||
|
||||
::Handle := FCreate( cFile, nMode )
|
||||
IF ::Handle <= 0
|
||||
|
||||
@@ -45,7 +45,6 @@
|
||||
*/
|
||||
|
||||
#include "hbclass.ch"
|
||||
#include "common.ch"
|
||||
#include "cgi.ch"
|
||||
|
||||
CLASS TCgi FROM THtml
|
||||
@@ -206,7 +205,7 @@ METHOD Field( cQueryName ) CLASS TCgi
|
||||
LOCAL cRet := ""
|
||||
LOCAL nRet
|
||||
|
||||
DEFAULT cQueryName TO ""
|
||||
__defaultNIL( @cQueryName, "" )
|
||||
|
||||
nRet := AScan( ::aQueryFields, ;
|
||||
{| x | Upper( x[ 1 ] ) == Upper( cQueryName ) } )
|
||||
|
||||
@@ -45,7 +45,6 @@
|
||||
*/
|
||||
|
||||
#include "hbclass.ch"
|
||||
#include "common.ch"
|
||||
#include "cgi.ch"
|
||||
|
||||
#define _OPTION_TEXT 1
|
||||
@@ -513,11 +512,11 @@ METHOD New( cName, cAction, cMethod, lFrame, cCaption, nWidth ) CLASS THtmlForm
|
||||
|
||||
HB_SYMBOL_UNUSED( cAction )
|
||||
|
||||
DEFAULT cName TO "Form1"
|
||||
DEFAULT cMethod TO "POST"
|
||||
DEFAULT lFrame TO .F.
|
||||
DEFAULT cCaption TO ""
|
||||
DEFAULT nWidth TO 90
|
||||
__defaultNIL( @cName, "Form1" )
|
||||
__defaultNIL( @cMethod, "POST" )
|
||||
__defaultNIL( @lFrame, .F. )
|
||||
__defaultNIL( @cCaption, "" )
|
||||
__defaultNIL( @nWidth, 90 )
|
||||
::oHtm := HtmlPageObject()
|
||||
::Name := cName
|
||||
::Method := cMethod
|
||||
@@ -542,7 +541,7 @@ RETURN Self
|
||||
|
||||
METHOD Put( lPutControls ) CLASS THtmlForm
|
||||
|
||||
DEFAULT lPutControls TO .F.
|
||||
__defaultNIL( @lPutControls, .F. )
|
||||
|
||||
IF ! HB_ISNUMERIC( ::width )
|
||||
::width := 90
|
||||
|
||||
@@ -45,7 +45,6 @@
|
||||
*/
|
||||
|
||||
#include "hbclass.ch"
|
||||
#include "common.ch"
|
||||
#include "fileio.ch"
|
||||
#include "cgi.ch"
|
||||
|
||||
@@ -154,7 +153,7 @@ METHOD New( cName ) CLASS TCgiFile
|
||||
|
||||
METHOD Open( nMode ) CLASS TCgiFile
|
||||
|
||||
DEFAULT nMode TO FO_EXCLUSIVE
|
||||
__defaultNIL( @nMode, FO_EXCLUSIVE )
|
||||
::Handle := FOpen( ::Name, nMode )
|
||||
IF ::Handle > 0
|
||||
::Size()
|
||||
@@ -170,7 +169,7 @@ METHOD CREATE ( nAttr ) CLASS TCgiFile
|
||||
|
||||
LOCAL nSuccess
|
||||
|
||||
DEFAULT nAttr TO 0
|
||||
__defaultNIL( @nAttr, 0 )
|
||||
nSuccess := FCreate( ::Name, nAttr )
|
||||
::Handle := nSuccess
|
||||
|
||||
@@ -201,8 +200,8 @@ METHOD Size() CLASS TCgiFile
|
||||
|
||||
METHOD _Read( nSize, cBuff ) CLASS TCgiFile
|
||||
|
||||
DEFAULT nSize TO 1024
|
||||
DEFAULT cBuff TO Space( nSize )
|
||||
__defaultNIL( @nSize, 1024 )
|
||||
__defaultNIL( @cBuff, Space( nSize ) )
|
||||
|
||||
::BytesRead := FRead( ::Handle, @cBuff, nSize )
|
||||
::Buffer := cBuff
|
||||
@@ -219,8 +218,8 @@ METHOD ReadAhead( nSize, cBuff ) CLASS TCgiFile
|
||||
|
||||
LOCAL nCurrent
|
||||
|
||||
DEFAULT nSize TO 1024
|
||||
DEFAULT cBuff TO Space( nSize )
|
||||
__defaultNIL( @nSize, 1024 )
|
||||
__defaultNIL( @cBuff, Space( nSize ) )
|
||||
|
||||
// --> save position in file
|
||||
nCurrent := FPOS( ::Handle )
|
||||
@@ -243,7 +242,7 @@ METHOD Readline( nSize ) CLASS TCgiFile
|
||||
LOCAL nCurrent
|
||||
LOCAL nCr
|
||||
|
||||
DEFAULT nSize TO 1024
|
||||
__defaultNIL( @nSize, 1024 )
|
||||
|
||||
IF nSize <= 0
|
||||
RETURN ""
|
||||
@@ -378,7 +377,7 @@ METHOD SKIP( nLines ) CLASS TCgiFile
|
||||
LOCAL nCount := 0
|
||||
LOCAL nPos := FPOS( ::Handle )
|
||||
|
||||
DEFAULT nLines TO 1
|
||||
__defaultNIL( @nLines, 1 )
|
||||
|
||||
IF nLines <= 0 // don't accept < 0
|
||||
|
||||
@@ -404,7 +403,7 @@ METHOD SKIP( nLines ) CLASS TCgiFile
|
||||
|
||||
METHOD MaxPages( nPageSize ) CLASS TCgiFile
|
||||
|
||||
DEFAULT nPageSize TO ::nPageSize
|
||||
__defaultNIL( @nPageSize, ::nPageSize )
|
||||
|
||||
RETURN ::Size() / nPageSize
|
||||
|
||||
@@ -414,7 +413,7 @@ METHOD MaxPages( nPageSize ) CLASS TCgiFile
|
||||
|
||||
METHOD PrevPage( nBytes ) CLASS TCgiFile
|
||||
|
||||
DEFAULT nBytes TO 1024
|
||||
__defaultNIL( @nBytes, 1024 )
|
||||
|
||||
IF nBytes <= 0
|
||||
RETURN ""
|
||||
@@ -435,7 +434,7 @@ METHOD PrevPage( nBytes ) CLASS TCgiFile
|
||||
|
||||
METHOD NextPage( nBytes ) CLASS TCgiFile
|
||||
|
||||
DEFAULT nBytes TO 1024
|
||||
__defaultNIL( @nBytes, 1024 )
|
||||
|
||||
IF nBytes <= 0
|
||||
RETURN ""
|
||||
@@ -464,7 +463,7 @@ METHOD PrevLine( nBytes ) CLASS TCgiFile
|
||||
LOCAL nPrev
|
||||
LOCAL cTemp
|
||||
|
||||
DEFAULT nBytes TO 256
|
||||
__defaultNIL( @nBytes, 256 )
|
||||
|
||||
IF nOrigPos == 0
|
||||
|
||||
|
||||
@@ -45,7 +45,6 @@
|
||||
*/
|
||||
|
||||
#include "hbclass.ch"
|
||||
#include "common.ch"
|
||||
#include "cgi.ch"
|
||||
|
||||
|
||||
@@ -75,7 +74,7 @@ METHOD New( cFName, cTitle ) CLASS THtmlFrameSet
|
||||
|
||||
LOCAL cStr
|
||||
|
||||
DEFAULT cTitle TO ""
|
||||
__defaultNIL( @cTitle, "" )
|
||||
|
||||
::FName := cFName
|
||||
::Title := cTitle
|
||||
@@ -172,11 +171,11 @@ METHOD Frame( cName, cURL, lBorder, lResize, lScrolling, ;
|
||||
|
||||
LOCAL cStr
|
||||
|
||||
DEFAULT lBorder TO .T.
|
||||
DEFAULT lResize TO .T.
|
||||
DEFAULT lScrolling TO .F.
|
||||
DEFAULT cScrolling TO "AUTO"
|
||||
DEFAULT cTarget TO "_self"
|
||||
__defaultNIL( @lBorder, .T. )
|
||||
__defaultNIL( @lResize, .T. )
|
||||
__defaultNIL( @lScrolling, .F. )
|
||||
__defaultNIL( @cScrolling, "AUTO" )
|
||||
__defaultNIL( @cTarget, "_self" )
|
||||
|
||||
cStr := " <frame "
|
||||
|
||||
|
||||
@@ -44,7 +44,6 @@
|
||||
*
|
||||
*/
|
||||
|
||||
#include "common.ch"
|
||||
#include "hbclass.ch"
|
||||
#include "cgi.ch"
|
||||
|
||||
@@ -105,11 +104,11 @@ CLASS THtml
|
||||
|
||||
METHOD CGIClose()
|
||||
|
||||
METHOD SetPageColor( cColor, lBody ) INLINE DEFAULT( lBody , .T. ), ::cStr += iif( lBody, '<BODY BGCOLOR="' + cColor + '">', ' BGCOLOR="' + cColor + '" ' )
|
||||
METHOD SetPageColor( cColor, lBody ) INLINE DEFAULT( lBody, .T. ), ::cStr += iif( lBody, '<BODY BGCOLOR="' + cColor + '">', ' BGCOLOR="' + cColor + '" ' )
|
||||
|
||||
METHOD SetTextColor( cColor, lBody ) INLINE DEFAULT( lBody , .T. ), ::cStr += iif( lBody, '<BODY TEXT="' + cColor + '">', ' TEXT="' + cColor + '" ' )
|
||||
METHOD SetTextColor( cColor, lBody ) INLINE DEFAULT( lBody, .T. ), ::cStr += iif( lBody, '<BODY TEXT="' + cColor + '">', ' TEXT="' + cColor + '" ' )
|
||||
|
||||
METHOD SetBgImage( cImage, lBody ) INLINE DEFAULT( lBody , .T. ), ::cStr += iif( lBody, '<BODY BACKGROUND="' + cImage + '">', ' BACKGROUND="' + cImage + '" ' )
|
||||
METHOD SetBgImage( cImage, lBody ) INLINE DEFAULT( lBody, .T. ), ::cStr += iif( lBody, '<BODY BACKGROUND="' + cImage + '">', ' BACKGROUND="' + cImage + '" ' )
|
||||
|
||||
METHOD CLOSE()
|
||||
|
||||
@@ -148,8 +147,8 @@ CLASS THtml
|
||||
DEFAULT( cols, 2 ), ;
|
||||
DEFAULT( gutter, 5 ), ;
|
||||
DEFAULT( width, 100 ), ;
|
||||
::cStr += '<MULTICOL COLS="' + hb_ntos( cols ) + '" GUTTER="' + hb_ntos( gutter ) + '" WIDTH="' + hb_ntos( width ) + '">' , ;
|
||||
::cStr += txt , ;
|
||||
::cStr += '<MULTICOL COLS="' + hb_ntos( cols ) + '" GUTTER="' + hb_ntos( gutter ) + '" WIDTH="' + hb_ntos( width ) + '">', ;
|
||||
::cStr += txt, ;
|
||||
::cStr += "</MULTICOL>"
|
||||
|
||||
METHOD PutHeading( cText, nWeight, lCentered )
|
||||
@@ -293,7 +292,7 @@ METHOD cgiNew( cTitle, cLinkTitle, cCharSet, aScriptSRC, ;
|
||||
cBaseURL, cBaseTarget, ;
|
||||
nRefresh, cRefreshURL, cStyleScr, ;
|
||||
lNocache, NOF, nMarginTop, nMarginHeight, ;
|
||||
nMarginWidth, nMarginLeft , .T. , cFile )
|
||||
nMarginWidth, nMarginLeft, .T., cFile )
|
||||
|
||||
METHOD New( cTitle, cLinkTitle, cCharSet, aScriptSRC, ;
|
||||
BGIMAGE, BGCOLOR, txtColor, aJsCode, ;
|
||||
@@ -307,21 +306,21 @@ METHOD New( cTitle, cLinkTitle, cCharSet, aScriptSRC, ;
|
||||
|
||||
LOCAL i
|
||||
|
||||
DEFAULT lCgi TO .F.
|
||||
__defaultNIL( @lCgi, .F. )
|
||||
::lCgi := lCgi
|
||||
IF lCgi
|
||||
DEFAULT cTitle TO "New CGI-HTML page"
|
||||
DEFAULT cLinkTitle TO cTitle
|
||||
DEFAULT cRefreshURL TO ""
|
||||
DEFAULT cCharset TO "windows-1251"
|
||||
DEFAULT lNocache TO .F.
|
||||
__defaultNIL( @cTitle, "New CGI-HTML page" )
|
||||
__defaultNIL( @cLinkTitle, cTitle )
|
||||
__defaultNIL( @cRefreshURL, "" )
|
||||
__defaultNIL( @cCharset, "windows-1251" )
|
||||
__defaultNIL( @lNocache, .F. )
|
||||
ELSE
|
||||
DEFAULT cFile TO "file1.htm"
|
||||
DEFAULT cTitle TO "New HTML page"
|
||||
DEFAULT cLinkTitle TO cTitle
|
||||
DEFAULT cRefreshURL TO ""
|
||||
DEFAULT cCharset TO "windows-1251"
|
||||
DEFAULT lNocache TO .F.
|
||||
__defaultNIL( @cFile, "file1.htm" )
|
||||
__defaultNIL( @cTitle, "New HTML page" )
|
||||
__defaultNIL( @cLinkTitle, cTitle )
|
||||
__defaultNIL( @cRefreshURL, "" )
|
||||
__defaultNIL( @cCharset, "windows-1251" )
|
||||
__defaultNIL( @lNocache, .F. )
|
||||
ENDIF
|
||||
|
||||
|
||||
@@ -527,10 +526,10 @@ METHOD SetFont( cFont, lBold, lItalic, lULine, nSize, cColor, lSet ) CLASS THtml
|
||||
|
||||
LOCAL cStr := CRLF() + '<FONT'
|
||||
|
||||
DEFAULT cFont TO ::fontFace
|
||||
DEFAULT nSize TO ::fontSize
|
||||
DEFAULT cColor TO ::fontColor
|
||||
DEFAULT lset TO iif( cFont != NIL, .T. , .F. )
|
||||
__defaultNIL( @cFont, ::fontFace )
|
||||
__defaultNIL( @nSize, ::fontSize )
|
||||
__defaultNIL( @cColor, ::fontColor )
|
||||
__defaultNIL( @lset, iif( cFont != NIL, .T., .F. ) )
|
||||
|
||||
IF cFont != NIL
|
||||
cStr += ' FACE="' + cFont + '"'
|
||||
@@ -590,11 +589,11 @@ METHOD StartFont( cFont, lBold, lItalic, lULine, nSize, cColor, lSet, lPut ) CLA
|
||||
|
||||
LOCAL cStr := "<FONT "
|
||||
|
||||
DEFAULT lSet TO .T.
|
||||
DEFAULT lPut TO .F.
|
||||
DEFAULT cFont TO ::fontFace
|
||||
DEFAULT nSize TO ::fontSize
|
||||
DEFAULT cColor TO ::fontColor
|
||||
__defaultNIL( @lSet, .T. )
|
||||
__defaultNIL( @lPut, .F. )
|
||||
__defaultNIL( @cFont, ::fontFace )
|
||||
__defaultNIL( @nSize, ::fontSize )
|
||||
__defaultNIL( @cColor, ::fontColor )
|
||||
|
||||
IF cFont != NIL
|
||||
cStr += ' FACE="' + cFont + '"'
|
||||
@@ -659,10 +658,10 @@ METHOD DefineFont( cFont, cType, nSize, cColor, lSet ) CLASS THtml
|
||||
|
||||
LOCAL cStr := "<FONT "
|
||||
|
||||
DEFAULT cFont TO ::fontFace
|
||||
DEFAULT nSize TO ::fontSize
|
||||
DEFAULT cColor TO ::fontColor
|
||||
DEFAULT lset TO iif( cFont != NIL, .T. , .F. )
|
||||
__defaultNIL( @cFont, ::fontFace )
|
||||
__defaultNIL( @nSize, ::fontSize )
|
||||
__defaultNIL( @cColor, ::fontColor )
|
||||
__defaultNIL( @lset, iif( cFont != NIL, .T., .F. ) )
|
||||
|
||||
IF cFont != NIL
|
||||
cStr += ' FACE="' + cFont + '"'
|
||||
@@ -732,10 +731,10 @@ METHOD SAY( str, font, size, type, color, style ) CLASS THtml
|
||||
LOCAL lStrong := .F.
|
||||
LOCAL nSize := Size
|
||||
|
||||
DEFAULT str TO ""
|
||||
DEFAULT FONT TO ::FontFace
|
||||
DEFAULT size TO ::FontSize
|
||||
DEFAULT COLOR TO ::FontColor
|
||||
__defaultNIL( @str, "" )
|
||||
__defaultNIL( @FONT, ::FontFace )
|
||||
__defaultNIL( @size, ::FontSize )
|
||||
__defaultNIL( @COLOR, ::FontColor )
|
||||
|
||||
IF FONT != NIL .OR. Size != NIL .OR. COLOR != NIL
|
||||
cOut := '<FONT ' + iif( font != NIL, 'FACE="' + font + '"', '' ) + iif( color != NIL, ' COLOR=' + color, '' ) + iif( nSize != NIL, ' SIZE=' + hb_ntos( size ), "" )
|
||||
@@ -823,8 +822,8 @@ METHOD Paragraph( lStart, cAlign, cStyle ) CLASS THtml
|
||||
|
||||
LOCAL cStr := "<P"
|
||||
|
||||
DEFAULT lStart TO .T.
|
||||
DEFAULT cAlign TO "LEFT"
|
||||
__defaultNIL( @lStart, .T. )
|
||||
__defaultNIL( @cAlign, "LEFT" )
|
||||
|
||||
IF lStart
|
||||
cStr := "<P ALIGN='" + cAlign + "'"
|
||||
@@ -852,9 +851,9 @@ METHOD Paragraph( lStart, cAlign, cStyle ) CLASS THtml
|
||||
|
||||
METHOD HLine( nSize, nWidth, lShade, cColor ) CLASS THtml
|
||||
|
||||
DEFAULT nSize TO 3
|
||||
DEFAULT nWidth TO 100
|
||||
DEFAULT lShade TO .T.
|
||||
__defaultNIL( @nSize, 3 )
|
||||
__defaultNIL( @nWidth, 100 )
|
||||
__defaultNIL( @lShade, .T. )
|
||||
|
||||
IF lShade
|
||||
::cStr += CRLF() + ;
|
||||
@@ -877,8 +876,8 @@ METHOD HLine( nSize, nWidth, lShade, cColor ) CLASS THtml
|
||||
|
||||
METHOD PutHeading( cText, nWeight, lCentered ) CLASS THtml
|
||||
|
||||
DEFAULT nWeight TO 3
|
||||
DEFAULT lCentered TO .F.
|
||||
__defaultNIL( @nWeight, 3 )
|
||||
__defaultNIL( @lCentered, .F. )
|
||||
|
||||
IF lCentered
|
||||
::cStr += "<CENTER>"
|
||||
@@ -903,9 +902,9 @@ METHOD PutTextUrl( cText, cUrl, cOnClick, cOnMsOver, cOnMsout, cTarget, font, cl
|
||||
|
||||
LOCAL cStr := ""
|
||||
|
||||
DEFAULT cUrl TO ""
|
||||
DEFAULT bld TO .F.
|
||||
DEFAULT lBreak TO .F.
|
||||
__defaultNIL( @cUrl, "" )
|
||||
__defaultNIL( @bld, .F. )
|
||||
__defaultNIL( @lBreak, .F. )
|
||||
|
||||
::cStr += ;
|
||||
'<A HREF="' + cUrl + '"' + CRLF()
|
||||
@@ -995,7 +994,7 @@ METHOD PutImageUrl( cImage, nBorder, nHeight, cUrl, ;
|
||||
|
||||
LOCAL cStr := ""
|
||||
|
||||
DEFAULT lbreak TO .F.
|
||||
__defaultNIL( @lbreak, .F. )
|
||||
|
||||
IF cName != NIL
|
||||
cStr += ' NAME= "' + cName + '"' + CRLF()
|
||||
@@ -1060,7 +1059,7 @@ METHOD PutTextImageUrl( cImage, nBorder, nHeight, cUrl, ;
|
||||
|
||||
LOCAL cStr := ""
|
||||
|
||||
DEFAULT lbreak TO .F.
|
||||
__defaultNIL( @lbreak, .F. )
|
||||
IF cName != NIL
|
||||
cStr += ' NAME= "' + cName + '"'
|
||||
ENDIF
|
||||
@@ -1120,7 +1119,7 @@ METHOD PutImage( cImage, nBorder, nHeight, ;
|
||||
|
||||
LOCAL cStr := ""
|
||||
|
||||
DEFAULT lbreak TO .F.
|
||||
__defaultNIL( @lbreak, .F. )
|
||||
|
||||
IF cName != NIL
|
||||
cStr += ' NAME= "' + cName + '"'
|
||||
@@ -1243,9 +1242,9 @@ METHOD DefineTable( nCols, nBorder, nWidth, nHeight, ColorFore, ColorBG, ;
|
||||
LOCAL cStr := CRLF() + CRLF() + "<TABLE "
|
||||
LOCAL xCols := nCols
|
||||
|
||||
DEFAULT l3d TO .T.
|
||||
DEFAULT lRuleCols TO .F.
|
||||
DEFAULT lRuleRows TO .F.
|
||||
__defaultNIL( @l3d, .T. )
|
||||
__defaultNIL( @lRuleCols, .F. )
|
||||
__defaultNIL( @lRuleRows, .F. )
|
||||
|
||||
IF ColorFore != NIL
|
||||
cStr += " bordercolor=" + ColorFore + ' '
|
||||
@@ -1342,9 +1341,9 @@ METHOD TableHead( cHead, cColor, cAlign, ;
|
||||
|
||||
LOCAL cStr := Space( 3 ) + "<TH"
|
||||
|
||||
DEFAULT cFont TO ::fontFace
|
||||
DEFAULT nSize TO ::fontSize
|
||||
DEFAULT cFntColor TO ::fontColor
|
||||
__defaultNIL( @cFont, ::fontFace )
|
||||
__defaultNIL( @nSize, ::fontSize )
|
||||
__defaultNIL( @cFntColor, ::fontColor )
|
||||
|
||||
IF cColor != NIL
|
||||
cStr += " bgcolor=" + '"' + cColor + '"'
|
||||
@@ -1443,12 +1442,12 @@ METHOD NewTableCell( cAlign, cColor, ;
|
||||
LOCAL cStr := Space( 10 ) + "<TD"
|
||||
LOCAL cAli := cAlign
|
||||
|
||||
DEFAULT lNoFont TO .T.
|
||||
DEFAULT cFont TO ::fontFace
|
||||
DEFAULT nSize TO ::fontSize
|
||||
DEFAULT cFntColor TO ::fontColor
|
||||
DEFAULT cAlign TO "LEFT"
|
||||
DEFAULT lWrap TO .T.
|
||||
__defaultNIL( @lNoFont, .T. )
|
||||
__defaultNIL( @cFont, ::fontFace )
|
||||
__defaultNIL( @nSize, ::fontSize )
|
||||
__defaultNIL( @cFntColor, ::fontColor )
|
||||
__defaultNIL( @cAlign, "LEFT" )
|
||||
__defaultNIL( @lWrap, .T. )
|
||||
|
||||
IF cBdrClr != NIL
|
||||
cStr += " BORDERCOLOR=" + cBdrClr
|
||||
@@ -1581,8 +1580,8 @@ METHOD EndTable() CLASS THtml
|
||||
|
||||
METHOD NewForm( cMethod, cAction, cName ) CLASS THtml
|
||||
|
||||
DEFAULT cMethod TO "POST"
|
||||
DEFAULT cName TO "newForm"
|
||||
__defaultNIL( @cMethod, "POST" )
|
||||
__defaultNIL( @cName, "newForm" )
|
||||
|
||||
::cStr += CRLF() + "<FORM"
|
||||
|
||||
@@ -1614,7 +1613,7 @@ METHOD NewForm( cMethod, cAction, cName ) CLASS THtml
|
||||
|
||||
METHOD FormEdit( cType, cName, xValue, nSize ) CLASS THtml
|
||||
|
||||
DEFAULT cType TO "edit"
|
||||
__defaultNIL( @cType, "edit" )
|
||||
|
||||
::cStr += '<INPUT Type="' + cType + '"'
|
||||
|
||||
@@ -1695,8 +1694,8 @@ METHOD PushButton( cName, cCaption, ;
|
||||
|
||||
LOCAL cStr := CRLF() + "<INPUT TYPE=BUTTON " + CRLF()
|
||||
|
||||
DEFAULT cOnMsOver TO "window.status=this.name;"
|
||||
DEFAULT cOnMsOut TO "window.status='';"
|
||||
__defaultNIL( @cOnMsOver, "window.status=this.name;" )
|
||||
__defaultNIL( @cOnMsOut, "window.status='';" )
|
||||
|
||||
IF cName != NIL
|
||||
cStr += " NAME=" + cName
|
||||
@@ -1758,8 +1757,8 @@ METHOD Button( cName, cCaption, ;
|
||||
|
||||
LOCAL cStr := CRLF() + "<BUTTON " + CRLF()
|
||||
|
||||
DEFAULT cOnMsOver TO "window.status=this.name;"
|
||||
DEFAULT cOnMsOut TO "window.status='';"
|
||||
__defaultNIL( @cOnMsOver, "window.status=this.name;" )
|
||||
__defaultNIL( @cOnMsOut, "window.status='';" )
|
||||
|
||||
IF cName != NIL
|
||||
cStr += " NAME=" + cName
|
||||
@@ -1825,18 +1824,18 @@ METHOD Marquee( cText, cFont, cFntColor, nFntSize, ;
|
||||
nScrollAmt, nScrollDelay, LOOP, ;
|
||||
onMsOver, onMsOut, onClick, onStart, onFinish ) CLASS THtml
|
||||
|
||||
DEFAULT cFont TO "Verdana"
|
||||
DEFAULT cFntColor TO "white"
|
||||
DEFAULT nFntSize TO 3
|
||||
DEFAULT cAlign TO "middle"
|
||||
DEFAULT nWidth TO 100
|
||||
DEFAULT cText TO ""
|
||||
DEFAULT cBgColor TO "black"
|
||||
DEFAULT cBehavior TO "scroll"
|
||||
DEFAULT cDirection TO "left"
|
||||
DEFAULT nScrollAmt TO 5
|
||||
DEFAULT nScrolldelay TO 2
|
||||
DEFAULT LOOP TO 0
|
||||
__defaultNIL( @cFont, "Verdana" )
|
||||
__defaultNIL( @cFntColor, "white" )
|
||||
__defaultNIL( @nFntSize, 3 )
|
||||
__defaultNIL( @cAlign, "middle" )
|
||||
__defaultNIL( @nWidth, 100 )
|
||||
__defaultNIL( @cText, "" )
|
||||
__defaultNIL( @cBgColor, "black" )
|
||||
__defaultNIL( @cBehavior, "scroll" )
|
||||
__defaultNIL( @cDirection, "left" )
|
||||
__defaultNIL( @nScrollAmt, 5 )
|
||||
__defaultNIL( @nScrolldelay, 2 )
|
||||
__defaultNIL( @LOOP, 0 )
|
||||
|
||||
::StartFont( cFont, , , , nFntSize, cFntColor )
|
||||
|
||||
@@ -1878,16 +1877,16 @@ METHOD StartMarquee( cFont, cFntColor, nFntSize, ;
|
||||
|
||||
LOCAL cStr := ""
|
||||
|
||||
DEFAULT cFont TO "Verdana"
|
||||
DEFAULT cFntColor TO "white"
|
||||
DEFAULT nFntSize TO 3
|
||||
DEFAULT cAlign TO "middle"
|
||||
DEFAULT nWidth TO 100
|
||||
DEFAULT cBgColor TO "black"
|
||||
DEFAULT cBehavior TO "scroll"
|
||||
DEFAULT cDirection TO "left"
|
||||
DEFAULT nScrollAmt TO 5
|
||||
DEFAULT nScrolldelay TO 2
|
||||
__defaultNIL( @cFont, "Verdana" )
|
||||
__defaultNIL( @cFntColor, "white" )
|
||||
__defaultNIL( @nFntSize, 3 )
|
||||
__defaultNIL( @cAlign, "middle" )
|
||||
__defaultNIL( @nWidth, 100 )
|
||||
__defaultNIL( @cBgColor, "black" )
|
||||
__defaultNIL( @cBehavior, "scroll" )
|
||||
__defaultNIL( @cDirection, "left" )
|
||||
__defaultNIL( @nScrollAmt, 5 )
|
||||
__defaultNIL( @nScrolldelay, 2 )
|
||||
|
||||
::StartFont( cFont, , , , nFntSize, cFntColor )
|
||||
|
||||
@@ -1938,9 +1937,9 @@ METHOD iFrame( name, src, border, marginwidth, marginheight, ;
|
||||
|
||||
LOCAL cStr := "<IFRAME " + CRLF()
|
||||
|
||||
DEFAULT BORDER TO .T.
|
||||
DEFAULT name TO "Frame01"
|
||||
// DEFAULT align TO "vertical"
|
||||
__defaultNIL( @BORDER, .T. )
|
||||
__defaultNIL( @name, "Frame01" )
|
||||
// __defaultNIL( @align, "vertical" )
|
||||
|
||||
IF name != NIL
|
||||
cStr += Space( 5 ) + ' NAME="' + name + '"' + CRLF()
|
||||
@@ -2203,8 +2202,8 @@ PROCEDURE HtmlJsCmd( nH, cCmd )
|
||||
|
||||
LOCAL cStr := ""
|
||||
|
||||
DEFAULT nH TO HtmlPageHandle()
|
||||
DEFAULT cCmd TO ""
|
||||
__defaultNIL( @nH, HtmlPageHandle() )
|
||||
__defaultNIL( @cCmd, "" )
|
||||
|
||||
cStr += '<SCRIPT LANGUAGE=JavaScript 1.2>' + CRLF() + ;
|
||||
"<!--" + CRLF()
|
||||
@@ -2226,12 +2225,12 @@ FUNCTION HtmlLinkStyle( cHoverStyle, cHoverClr, cHoverBG, ;
|
||||
|
||||
LOCAL cStr
|
||||
|
||||
DEFAULT cHoverStyle TO "normal"
|
||||
DEFAULT cLinkStyle TO "normal"
|
||||
DEFAULT cHoverClr TO "white"
|
||||
DEFAULT cHoverBg TO "black"
|
||||
DEFAULT cLinkClr TO "black"
|
||||
DEFAULT cLinkBg TO "white"
|
||||
__defaultNIL( @cHoverStyle, "normal" )
|
||||
__defaultNIL( @cLinkStyle, "normal" )
|
||||
__defaultNIL( @cHoverClr, "white" )
|
||||
__defaultNIL( @cHoverBg, "black" )
|
||||
__defaultNIL( @cLinkClr, "black" )
|
||||
__defaultNIL( @cLinkBg, "white" )
|
||||
cStr := ;
|
||||
"<!-- A:hover {text-decoration:" + cHoverStyle + ";color:" + cHoverClr + ";background:" + cHoverBG + ;
|
||||
";} A:link {text-decoration:" + cLinkStyle + ";color:" + cLinkClr + ";background:" + cLinkBG + ";}-->"
|
||||
|
||||
@@ -66,7 +66,6 @@
|
||||
#include "ttable.ch"
|
||||
#include "set.ch"
|
||||
#include "ord.ch"
|
||||
#include "common.ch"
|
||||
#include "inkey.ch"
|
||||
#include "dbinfo.ch"
|
||||
#include "error.ch"
|
||||
@@ -86,11 +85,11 @@ FUNCTION NetDbUse( cDataBase, cAlias, nSeconds, cDriver, ;
|
||||
LOCAL cOldScreen := SaveScreen( MaxRow(), 0, MaxRow(), MaxCol() + 1 )
|
||||
LOCAL lFirstPass := .T.
|
||||
|
||||
DEFAULT cDriver TO "DBFCDX"
|
||||
DEFAULT lNew TO .T.
|
||||
DEFAULT lOpenMode TO NET_OPEN_MODE
|
||||
DEFAULT lReadOnly TO .F.
|
||||
DEFAULT nSeconds TO s_nNetDelay
|
||||
__defaultNIL( @cDriver, "DBFCDX" )
|
||||
__defaultNIL( @lNew, .T. )
|
||||
__defaultNIL( @lOpenMode, NET_OPEN_MODE )
|
||||
__defaultNIL( @lReadOnly, .F. )
|
||||
__defaultNIL( @nSeconds, s_nNetDelay )
|
||||
|
||||
s_lNetOk := .F.
|
||||
nSeconds *= 1.00
|
||||
@@ -160,8 +159,8 @@ FUNCTION NetLock( nType, lReleaseLocks, nSeconds )
|
||||
RETURN lSuccess
|
||||
ENDIF
|
||||
|
||||
DEFAULT lReleaseLocks TO .F.
|
||||
DEFAULT nSeconds TO s_nNetDelay
|
||||
__defaultNIL( @lReleaseLocks, .F. )
|
||||
__defaultNIL( @nSeconds, s_nNetDelay )
|
||||
|
||||
nWaitTime := nSeconds
|
||||
|
||||
@@ -253,7 +252,7 @@ FUNCTION NetFunc( bBlock, nSeconds )
|
||||
|
||||
LOCAL lForever // Retry forever?
|
||||
|
||||
DEFAULT nSeconds TO s_nNetDelay
|
||||
__defaultNIL( @nSeconds, s_nNetDelay )
|
||||
lForever := ( nSeconds == 0 )
|
||||
|
||||
// Keep trying as long as specified or default
|
||||
@@ -348,7 +347,7 @@ FUNCTION NetReCall()
|
||||
|
||||
FUNCTION NetRecLock( nSeconds )
|
||||
|
||||
DEFAULT nSeconds TO s_nNetDelay
|
||||
__defaultNIL( @nSeconds, s_nNetDelay )
|
||||
|
||||
s_lNetOk := .F.
|
||||
|
||||
@@ -361,7 +360,7 @@ FUNCTION NetRecLock( nSeconds )
|
||||
FUNCTION NetFileLock( nSeconds )
|
||||
|
||||
s_lNetOk := .F.
|
||||
DEFAULT nSeconds TO s_nNetDelay
|
||||
__defaultNIL( @nSeconds, s_nNetDelay )
|
||||
|
||||
IF NetLock( NET_FILELOCK, , nSeconds )
|
||||
s_lNetOk := .T.
|
||||
@@ -373,8 +372,8 @@ FUNCTION NetAppend( nSeconds, lReleaseLocks )
|
||||
|
||||
LOCAL nOrd
|
||||
|
||||
DEFAULT lReleaseLocks TO .T.
|
||||
DEFAULT nSeconds TO s_nNetDelay
|
||||
__defaultNIL( @lReleaseLocks, .T. )
|
||||
__defaultNIL( @nSeconds, s_nNetDelay )
|
||||
s_lNetOk := .F.
|
||||
nOrd := ordSetFocus( 0 ) // --> set order to 0 to append ???
|
||||
|
||||
@@ -409,7 +408,7 @@ FUNCTION NetCommitAll()
|
||||
|
||||
FUNCTION IsLocked( nRecId )
|
||||
|
||||
DEFAULT nRecID TO RecNo()
|
||||
__defaultNIL( @nRecID, RecNo() )
|
||||
|
||||
RETURN AScan( dbRLockList(), {| n | n == nRecID } ) > 0
|
||||
|
||||
@@ -454,13 +453,13 @@ FUNCTION TableNew( cDBF, cALIAS, cOrderBag, cDRIVER, ;
|
||||
LOCAL oDB
|
||||
LOCAL o
|
||||
|
||||
DEFAULT lNET TO .T.
|
||||
DEFAULT lNEW TO .T.
|
||||
DEFAULT lREADONLY TO .F.
|
||||
DEFAULT cDRIVER TO "DBFCDX"
|
||||
DEFAULT cPATH TO Set( _SET_DEFAULT )
|
||||
DEFAULT cAlias TO FixExt( cDbf )
|
||||
DEFAULT cOrderBag TO FixExt( cDbf ) //+".CDX"
|
||||
__defaultNIL( @lNET, .T. )
|
||||
__defaultNIL( @lNEW, .T. )
|
||||
__defaultNIL( @lREADONLY, .F. )
|
||||
__defaultNIL( @cDRIVER, "DBFCDX" )
|
||||
__defaultNIL( @cPATH, Set( _SET_DEFAULT ) )
|
||||
__defaultNIL( @cAlias, FixExt( cDbf ) )
|
||||
__defaultNIL( @cOrderBag, FixExt( cDbf ) )
|
||||
|
||||
lAuto := Set( _SET_AUTOPEN, .F. )
|
||||
|
||||
@@ -547,7 +546,7 @@ METHOD NEW( cAlias ) CLASS HBRecord
|
||||
LOCAL aStruc
|
||||
LOCAL aItem
|
||||
|
||||
DEFAULT cAlias TO Alias()
|
||||
__defaultNIL( @cAlias, Alias() )
|
||||
|
||||
::Alias := cAlias
|
||||
::Buffer := {}
|
||||
@@ -788,13 +787,13 @@ METHOD New( cDBF, cALIAS, cOrderBag, cDRIVER, ;
|
||||
|
||||
LOCAL cOldRdd
|
||||
|
||||
DEFAULT lNET TO .F.
|
||||
DEFAULT lNEW TO .T.
|
||||
DEFAULT lREADONLY TO .F.
|
||||
DEFAULT cDRIVER TO "DBFCDX"
|
||||
DEFAULT cPATH TO Set( _SET_DEFAULT )
|
||||
DEFAULT cAlias TO FixExt( cDbf )
|
||||
DEFAULT cOrderBag TO FixExt( cDbf ) //+".CDX"
|
||||
__defaultNIL( @lNET, .F. )
|
||||
__defaultNIL( @lNEW, .T. )
|
||||
__defaultNIL( @lREADONLY, .F. )
|
||||
__defaultNIL( @cDRIVER, "DBFCDX" )
|
||||
__defaultNIL( @cPATH, Set( _SET_DEFAULT ) )
|
||||
__defaultNIL( @cAlias, FixExt( cDbf ) )
|
||||
__defaultNIL( @cOrderBag, FixExt( cDbf ) )
|
||||
|
||||
|
||||
::IsNew := lNEW
|
||||
@@ -805,7 +804,7 @@ METHOD New( cDBF, cALIAS, cOrderBag, cDRIVER, ;
|
||||
::cOrderBag := FixExt( cOrderBag )
|
||||
cOldRdd := rddSetDefault( ::driver )
|
||||
|
||||
::cOrderFile := ::cOrderBag + ordBagExt() //".CDX"
|
||||
::cOrderFile := ::cOrderBag + ordBagExt() //".cdx"
|
||||
rddSetDefault( cOldRdd )
|
||||
::Driver := cDRIVER
|
||||
::aOrders := {}
|
||||
@@ -847,7 +846,7 @@ METHOD OPEN() CLASS HBTable
|
||||
|
||||
METHOD PROCEDURE DBMove( nDirection ) CLASS HBTable
|
||||
|
||||
DEFAULT nDirection TO 0
|
||||
__defaultNIL( @nDirection, 0 )
|
||||
|
||||
DO CASE
|
||||
CASE nDirection == 0
|
||||
@@ -944,7 +943,7 @@ METHOD PROCEDURE READ( lKeepBuffer ) CLASS HBTable
|
||||
LOCAL adata := Array( 1, 2 )
|
||||
LOCAL Buffer
|
||||
|
||||
DEFAULT lKeepBuffer TO .F.
|
||||
__defaultNIL( @lKeepBuffer, .F. )
|
||||
|
||||
//? len( ::Buffer )
|
||||
|
||||
@@ -975,7 +974,7 @@ METHOD PROCEDURE ReadBlank( lKeepBuffer ) CLASS HBTable
|
||||
LOCAL adata := Array( 1, 2 )
|
||||
LOCAL Buffer
|
||||
|
||||
DEFAULT lKeepBuffer TO .F.
|
||||
__defaultNIL( @lKeepBuffer, .F. )
|
||||
|
||||
( ::Alias )->( dbGoBottom() )
|
||||
( ::Alias )->( dbSkip( 1 ) ) // go EOF
|
||||
@@ -1009,7 +1008,7 @@ METHOD Write( lKeepBuffer ) CLASS HBTable
|
||||
LOCAL xBuffer
|
||||
LOCAL n
|
||||
|
||||
DEFAULT lKeepBuffer TO .F.
|
||||
__defaultNIL( @lKeepBuffer, .F. )
|
||||
|
||||
IF ( lKeepBuffer == .T. ) .OR. ( ::lMonitor == .T. )
|
||||
|
||||
@@ -1050,7 +1049,7 @@ METHOD BUFWrite( aBuffer ) CLASS HBTable
|
||||
LOCAL nOrd := ( ::Alias )->( ordSetFocus() )
|
||||
LOCAL Buffer
|
||||
|
||||
DEFAULT aBuffer TO ::Buffer
|
||||
__defaultNIL( @aBuffer, ::Buffer )
|
||||
|
||||
IF ::isNet
|
||||
IF !( ::Alias )->( NetRecLock() )
|
||||
@@ -1079,7 +1078,7 @@ METHOD __oTDelete( lKeepBuffer ) // ::Delete()
|
||||
LOCAL lDeleted := Set( _SET_DELETED, .F. ) // make deleted records visible
|
||||
|
||||
// temporarily...
|
||||
DEFAULT lKeepBuffer TO .F.
|
||||
__defaultNIL( @lKeepBuffer, .F. )
|
||||
|
||||
::Read()
|
||||
|
||||
@@ -1122,7 +1121,7 @@ METHOD Undo( nBuffer, nLevel ) CLASS HBTable
|
||||
LOCAL nRec := ::RecNo()
|
||||
LOCAL aBuffers
|
||||
|
||||
DEFAULT nBuffer TO _WRITE_BUFFER
|
||||
__defaultNIL( @nBuffer, _WRITE_BUFFER )
|
||||
|
||||
IF nLevel == NIL
|
||||
nLevel := 0
|
||||
@@ -1138,7 +1137,7 @@ METHOD Undo( nBuffer, nLevel ) CLASS HBTable
|
||||
|
||||
nLen := Len( ::deleteBuffers )
|
||||
|
||||
DEFAULT nLevel TO nLen
|
||||
__defaultNIL( @nLevel, nLen )
|
||||
|
||||
IF nLevel == 0 .OR. nLevel == nLen // DO ALL...
|
||||
FOR EACH aBuffers IN ::deleteBuffers
|
||||
@@ -1187,7 +1186,7 @@ METHOD Undo( nBuffer, nLevel ) CLASS HBTable
|
||||
IF !Empty( ::WriteBuffers )
|
||||
|
||||
nLen := Len( ::WriteBuffers )
|
||||
DEFAULT nLevel TO nLen
|
||||
__defaultNIL( @nLevel, nLen )
|
||||
|
||||
IF nLevel == 0 .OR. nLen == nLevel // Do All...
|
||||
|
||||
@@ -1255,7 +1254,7 @@ METHOD AddOrder( cTag, cKey, cLabel, ;
|
||||
|
||||
LOCAL oOrd
|
||||
|
||||
DEFAULT cOrderFile TO ::cOrderBag
|
||||
__defaultNIL( @cOrderFile, ::cOrderBag )
|
||||
|
||||
oOrd := HBOrder():New( cTag, cKey, cLabel, ;
|
||||
cFor, cWhile, ;
|
||||
@@ -1284,7 +1283,7 @@ METHOD REINDEX() CLASS HBTable
|
||||
|
||||
IF hb_FileExists( ::cPath + ::cOrderFile )
|
||||
IF FErase( ::cPath + ::cOrderFile ) != 0
|
||||
// --> ALERT(".CDX *NOT* Deleted !!!" )
|
||||
// --> ALERT(".cdx *NOT* Deleted !!!" )
|
||||
ENDIF
|
||||
ENDIF
|
||||
|
||||
@@ -1323,7 +1322,7 @@ METHOD FastReindex() CLASS HBTable
|
||||
::Isnet := .F.
|
||||
IF hb_FileExists( ::cPath + ::cOrderFile )
|
||||
IF FErase( ::cPath + ::cOrderFile ) != 0
|
||||
// --> ALERT(".CDX *NOT* Deleted !!!" )
|
||||
// --> ALERT(".cdx *NOT* Deleted !!!" )
|
||||
ENDIF
|
||||
ENDIF
|
||||
|
||||
@@ -1417,7 +1416,7 @@ PROCEDURE AddChild( oChild, cKey ) CLASS HBTable // ::addChild()
|
||||
|
||||
/****
|
||||
* FixExt( cFileName )
|
||||
* extract .CDX filename from .DBF filename
|
||||
* extract .cdx filename from .dbf filename
|
||||
*/
|
||||
|
||||
STATIC FUNCTION FixExt( cFileName )
|
||||
@@ -1513,13 +1512,13 @@ ENDCLASS
|
||||
|
||||
METHOD New( cTag, cKey, cLabel, cFor, cWhile, lUnique, bEval, nInterval, cOrderBag ) CLASS HBOrder
|
||||
|
||||
DEFAULT cKey TO ".T."
|
||||
DEFAULT lUnique TO .F.
|
||||
DEFAULT cFor TO ".T."
|
||||
DEFAULT cWhile TO ".T."
|
||||
DEFAULT bEval TO {|| .T. }
|
||||
DEFAULT nInterval TO 1
|
||||
DEFAULT cLabel TO cTag
|
||||
__defaultNIL( @cKey, ".T." )
|
||||
__defaultNIL( @lUnique, .F. )
|
||||
__defaultNIL( @cFor, ".T." )
|
||||
__defaultNIL( @cWhile, ".T." )
|
||||
__defaultNIL( @bEval, {|| .T. } )
|
||||
__defaultNIL( @nInterval, 1 )
|
||||
__defaultNIL( @cLabel, cTag )
|
||||
::cOrderBag := cOrderBag
|
||||
::Tag := cTag
|
||||
::cKey := cKey
|
||||
@@ -1536,7 +1535,7 @@ METHOD New( cTag, cKey, cLabel, cFor, cWhile, lUnique, bEval, nInterval, cOrderB
|
||||
|
||||
METHOD PROCEDURE CREATE() CLASS HBOrder
|
||||
|
||||
DEFAULT ::cOrderBag TO ::oTable:cOrderBag
|
||||
__defaultNIL( @::cOrderBag, ::oTable:cOrderBag )
|
||||
|
||||
// ? "<<<", ::alias, ::cOrderBag
|
||||
|
||||
|
||||
@@ -52,7 +52,6 @@
|
||||
*
|
||||
*/
|
||||
|
||||
#include "common.ch"
|
||||
#include "fileio.ch"
|
||||
#include "hbxml.ch"
|
||||
#include "hbclass.ch"
|
||||
|
||||
@@ -50,7 +50,6 @@
|
||||
*
|
||||
*/
|
||||
|
||||
#include "common.ch"
|
||||
#include "hbclass.ch"
|
||||
|
||||
ANNOUNCE XHB_LIB
|
||||
|
||||
@@ -66,7 +66,6 @@
|
||||
* LogError()
|
||||
*/
|
||||
|
||||
#include "common.ch"
|
||||
#include "error.ch"
|
||||
#include "fileio.ch"
|
||||
#include "set.ch"
|
||||
@@ -640,7 +639,7 @@ STATIC FUNCTION strvalue( c, l )
|
||||
|
||||
LOCAL cr := ""
|
||||
|
||||
DEFAULT l TO .F.
|
||||
__defaultNIL( @l, .F. )
|
||||
|
||||
SWITCH ValType( c )
|
||||
CASE "C"
|
||||
|
||||
@@ -50,8 +50,6 @@
|
||||
*
|
||||
*/
|
||||
|
||||
#include "common.ch"
|
||||
|
||||
#include "hbgtinfo.ch"
|
||||
|
||||
FUNCTION gtSetClipboard( x ) ; RETURN hb_gtInfo( HB_GTI_CLIPBOARDDATA, x )
|
||||
|
||||
@@ -50,7 +50,6 @@
|
||||
*
|
||||
*/
|
||||
|
||||
#include "common.ch"
|
||||
#include "hbclass.ch"
|
||||
#include "memoedit.ch"
|
||||
#include "inkey.ch"
|
||||
@@ -82,7 +81,7 @@ METHOD MemoInit( xUDF ) CLASS XHB_TMemoEditor
|
||||
|
||||
LOCAL nUdfReturn
|
||||
|
||||
DEFAULT xUDF TO NIL
|
||||
__defaultNIL( @xUDF, NIL )
|
||||
|
||||
::aEditKeys := { K_DOWN,;
|
||||
K_UP,;
|
||||
@@ -294,8 +293,8 @@ METHOD HandleUdf( nKey, nUdfReturn, lEdited ) CLASS XHB_TMemoEditor
|
||||
A little trick to be able to handle a nUdfReturn with value of NIL
|
||||
like it had a value of ME_DEFAULT
|
||||
*/
|
||||
DEFAULT nUdfReturn TO ME_DEFAULT
|
||||
DEFAULT lEdited TO .F.
|
||||
__defaultNIL( @nUdfReturn, ME_DEFAULT )
|
||||
__defaultNIL( @lEdited, .F. )
|
||||
|
||||
// I won't reach this point during ME_INIT since ME_DEFAULT ends
|
||||
// initialization phase of MemoEdit()
|
||||
@@ -417,21 +416,21 @@ FUNCTION xhb_MemoEdit( cString,;
|
||||
|
||||
LOCAL oEd
|
||||
|
||||
DEFAULT cString TO ""
|
||||
DEFAULT nTop TO 0
|
||||
DEFAULT nLeft TO 0
|
||||
DEFAULT nBottom TO MaxRow()
|
||||
DEFAULT nRight TO MaxCol()
|
||||
DEFAULT lEditMode TO .T.
|
||||
DEFAULT nLineLength TO NIL
|
||||
__defaultNIL( @cString, "" )
|
||||
__defaultNIL( @nTop, 0 )
|
||||
__defaultNIL( @nLeft, 0 )
|
||||
__defaultNIL( @nBottom, MaxRow() )
|
||||
__defaultNIL( @nRight, MaxCol() )
|
||||
__defaultNIL( @lEditMode, .T. )
|
||||
__defaultNIL( @nLineLength, NIL )
|
||||
/* 24/10/2005 - <maurilio.longo@libero.it>
|
||||
NG says 4, but clipper 5.2e inserts 3 spaces when pressing K_TAB
|
||||
*/
|
||||
DEFAULT nTabSize TO 3
|
||||
DEFAULT nTextBuffRow TO 1
|
||||
DEFAULT nTextBuffColumn TO 0
|
||||
DEFAULT nWindowRow TO 0
|
||||
DEFAULT nWindowColumn TO nTextBuffColumn
|
||||
__defaultNIL( @nTabSize, 3 )
|
||||
__defaultNIL( @nTextBuffRow, 1 )
|
||||
__defaultNIL( @nTextBuffColumn, 0 )
|
||||
__defaultNIL( @nWindowRow, 0 )
|
||||
__defaultNIL( @nWindowColumn, nTextBuffColumn )
|
||||
|
||||
// 2006/JUL/22 - E.F. Check argument types.
|
||||
//
|
||||
|
||||
@@ -72,7 +72,6 @@ FUNCTION CreateOLEObject()
|
||||
|
||||
#include "hbclass.ch"
|
||||
|
||||
#include "common.ch"
|
||||
#include "error.ch"
|
||||
|
||||
#define EG_OLEEXCEPTION 1001
|
||||
|
||||
@@ -92,7 +92,6 @@
|
||||
* Modifications are based upon the following source file:
|
||||
*/
|
||||
|
||||
#include "common.ch"
|
||||
#include "hbclass.ch"
|
||||
#include "error.ch"
|
||||
#include "fileio.ch"
|
||||
@@ -261,18 +260,18 @@ ENDCLASS
|
||||
|
||||
METHOD New( cString, nTop, nLeft, nBottom, nRight, lEditMode, nLineLength, nTabSize, nTextRow, nTextCol, nWndRow, nWndCol ) CLASS XHBEditor
|
||||
|
||||
DEFAULT cString TO ""
|
||||
DEFAULT nTop TO 0
|
||||
DEFAULT nLeft TO 0
|
||||
DEFAULT nBottom TO MaxRow()
|
||||
DEFAULT nRight TO MaxCol()
|
||||
DEFAULT lEditMode TO .T.
|
||||
DEFAULT nLineLength TO NIL
|
||||
DEFAULT nTabSize TO NIL
|
||||
DEFAULT nTextRow TO 1
|
||||
DEFAULT nTextCol TO 0 // 1 Clipper Documentations says it is 0
|
||||
DEFAULT nWndRow TO 0 // 1 "
|
||||
DEFAULT nWndCol TO 0 // 1 "
|
||||
__defaultNIL( @ cString, "" )
|
||||
__defaultNIL( @ nTop, 0 )
|
||||
__defaultNIL( @ nLeft, 0 )
|
||||
__defaultNIL( @ nBottom, MaxRow() )
|
||||
__defaultNIL( @ nRight, MaxCol() )
|
||||
__defaultNIL( @ lEditMode, .T. )
|
||||
__defaultNIL( @ nLineLength, NIL )
|
||||
__defaultNIL( @ nTabSize, NIL )
|
||||
__defaultNIL( @ nTextRow, 1 )
|
||||
__defaultNIL( @ nTextCol, 0 )
|
||||
__defaultNIL( @ nWndRow, 0 )
|
||||
__defaultNIL( @ nWndCol, 0 )
|
||||
|
||||
// 2006/JUL/22 - E.F. To avoid run time error.
|
||||
IF nTop > nBottom .OR. nLeft > nRight
|
||||
@@ -399,10 +398,10 @@ METHOD New( cString, nTop, nLeft, nBottom, nRight, lEditMode, nLineLength, nTabS
|
||||
METHOD Resize( nTop, nLeft, nBottom, nRight ) CLASS XHBEditor
|
||||
|
||||
// don't change coordinates not given
|
||||
DEFAULT nTop to ::nTop
|
||||
DEFAULT nLeft to ::nLeft
|
||||
DEFAULT nBottom to ::nBottom
|
||||
DEFAULT nRight to ::nRight
|
||||
__defaultNIL( @nTop, ::nTop )
|
||||
__defaultNIL( @nLeft, ::nLeft )
|
||||
__defaultNIL( @nBottom, ::nBottom )
|
||||
__defaultNIL( @nRight, ::nRight )
|
||||
|
||||
::nTop := nTop
|
||||
::nLeft := nLeft
|
||||
@@ -523,7 +522,7 @@ METHOD RefreshLine( lRefreshColSel ) CLASS XHBEditor
|
||||
LOCAL nORow
|
||||
LOCAL nCol, nFirstCol
|
||||
|
||||
DEFAULT lRefreshColSel TO .F.
|
||||
__defaultNIL( @lRefreshColSel, .F. )
|
||||
|
||||
IF ::nRow <= ::LastRow()
|
||||
|
||||
@@ -1774,8 +1773,8 @@ METHOD K_Esc() CLASS XHBEditor
|
||||
|
||||
METHOD AddLine( cLine, lSoftCR ) CLASS XHBEditor
|
||||
|
||||
DEFAULT cLine TO ""
|
||||
DEFAULT lSoftCR TO .F.
|
||||
__defaultNIL( @cLine, "" )
|
||||
__defaultNIL( @lSoftCR, .F. )
|
||||
|
||||
AAdd( ::aText, HBTextLine():New( cLine, lSoftCR ) )
|
||||
|
||||
@@ -1787,8 +1786,8 @@ METHOD AddLine( cLine, lSoftCR ) CLASS XHBEditor
|
||||
|
||||
METHOD InsertLine( cLine, lSoftCR, nRow ) CLASS XHBEditor
|
||||
|
||||
DEFAULT nRow TO ::nRow
|
||||
DEFAULT lSoftCR TO .F.
|
||||
__defaultNIL( @nRow, ::nRow )
|
||||
__defaultNIL( @lSoftCR, .F. )
|
||||
|
||||
IF nRow > ::LastRow()
|
||||
IF Len( cLine ) == 0
|
||||
@@ -1807,7 +1806,7 @@ METHOD InsertLine( cLine, lSoftCR, nRow ) CLASS XHBEditor
|
||||
|
||||
METHOD RemoveLine( nRow ) CLASS XHBEditor
|
||||
|
||||
DEFAULT nRow TO ::nRow
|
||||
__defaultNIL( @nRow, ::nRow )
|
||||
|
||||
hb_ADel( ::aText, nRow, .T. )
|
||||
|
||||
@@ -1819,7 +1818,7 @@ METHOD RemoveLine( nRow ) CLASS XHBEditor
|
||||
|
||||
METHOD GetLine( nRow ) CLASS XHBEditor
|
||||
|
||||
DEFAULT nRow TO ::nRow
|
||||
__defaultNIL( @nRow, ::nRow )
|
||||
|
||||
IF nRow <= ::LastRow() .AND. nRow > 0
|
||||
IF ::lEditAllow .OR. Empty( ::nTabWidth )
|
||||
@@ -1839,7 +1838,7 @@ METHOD GetLine( nRow ) CLASS XHBEditor
|
||||
|
||||
METHOD DelTextRight( nRow ) CLASS XHBEditor
|
||||
|
||||
DEFAULT nRow TO ::nRow
|
||||
__defaultNIL( @nRow, ::nRow )
|
||||
|
||||
IF !::lEditAllow
|
||||
RETURN Self
|
||||
@@ -2006,7 +2005,7 @@ METHOD GotoCol( nCol ) CLASS XHBEditor
|
||||
|
||||
METHOD GotoPos( nRow, nCol, lRefresh ) CLASS XHBEditor
|
||||
|
||||
DEFAULT lRefresh TO .F.
|
||||
__defaultNIL( @lRefresh, .F. )
|
||||
|
||||
DispBegin() // to minimize flicker
|
||||
|
||||
@@ -2311,8 +2310,8 @@ METHOD DeHilite() CLASS XHBEditor
|
||||
|
||||
METHOD SetPos( nRow, nCol ) CLASS XHBEditor
|
||||
|
||||
DEFAULT nRow to ::nPhysRow
|
||||
DEFAULT nCol to ::nPhysCol
|
||||
__defaultNIL( @nRow, ::nPhysRow )
|
||||
__defaultNIL( @nCol, ::nPhysCol )
|
||||
|
||||
::nPhysRow := nRow
|
||||
::nPhysCol := nCol
|
||||
@@ -2389,7 +2388,7 @@ METHOD GetText( lSoftCr ) CLASS XHBEditor
|
||||
LOCAL cString := "", cSoft := ""
|
||||
LOCAL cEOL := hb_eol()
|
||||
|
||||
DEFAULT lSoftCr TO .F.
|
||||
__defaultNIL( @lSoftCr, .F. )
|
||||
|
||||
IF ::LastRow() > 0
|
||||
|
||||
@@ -2423,7 +2422,7 @@ METHOD GetTextSelection( lSoftCr ) CLASS XHBEditor
|
||||
LOCAL nRowSelEnd
|
||||
LOCAL nI
|
||||
|
||||
DEFAULT lSoftCr TO .F.
|
||||
__defaultNIL( @lSoftCr, .F. )
|
||||
|
||||
IF !::lSelActive
|
||||
RETURN cString
|
||||
@@ -2832,7 +2831,7 @@ METHOD AddText( cString, lAtPos ) CLASS XHBEditor
|
||||
::InsertState( .T. )
|
||||
ENDIF
|
||||
|
||||
DEFAULT lAtPos TO .F.
|
||||
__defaultNIL( @lAtPos, .F. )
|
||||
|
||||
IF ! lAtPos .OR. nAtRow > ::LastRow()
|
||||
FOR i := 1 TO nLines
|
||||
@@ -3067,7 +3066,7 @@ METHOD BrowseText( nPassedKey, lHandleOneKey ) CLASS XHBEditor
|
||||
|
||||
LOCAL nKey, bKeyBlock
|
||||
|
||||
DEFAULT lHandleOneKey TO .F.
|
||||
__defaultNIL( @lHandleOneKey, .F. )
|
||||
|
||||
|
||||
DO WHILE ! ::lExitEdit
|
||||
|
||||
@@ -64,7 +64,6 @@ RETURN NIL
|
||||
#else
|
||||
|
||||
#include "hbclass.ch"
|
||||
#include "common.ch"
|
||||
|
||||
#define TA_LEFT 0
|
||||
#define TA_BOTTOM 8
|
||||
@@ -104,16 +103,16 @@ METHOD StartPage() CLASS WIN32PRN
|
||||
|
||||
METHOD TextOut( cString, lNewLine, lUpdatePosX, nAlignHori, nAlignVert ) CLASS WIN32PRN
|
||||
|
||||
DEFAULT nAlignHori TO ::SetTextHori
|
||||
DEFAULT nAlignVert TO ::SetTextVert
|
||||
__defaultNIL( @nAlignHori, ::SetTextHori )
|
||||
__defaultNIL( @nAlignVert, ::SetTextVert )
|
||||
|
||||
RETURN ::WIN_PRN:TextOut( cString, lNewLine, lUpdatePosX, ;
|
||||
HB_BITOR( nAlignHori, nAlignVert ) )
|
||||
|
||||
METHOD TextOutAt( nPosX, nPosY, cString, lNewLine, lUpdatePosX, nAlignHori, nAlignVert ) CLASS WIN32PRN
|
||||
|
||||
DEFAULT nAlignHori TO ::SetTextHori
|
||||
DEFAULT nAlignVert TO ::SetTextVert
|
||||
__defaultNIL( @nAlignHori, ::SetTextHori )
|
||||
__defaultNIL( @nAlignVert, ::SetTextVert )
|
||||
|
||||
RETURN ::WIN_PRN:TextOutAt( nPosX, nPosY, cString, lNewLine, lUpdatePosX, ;
|
||||
HB_BITOR( nAlignHori, nAlignVert ) )
|
||||
@@ -122,8 +121,8 @@ METHOD TextAtFont( nPosX, nPosY, cString, cFont, nPointSize, ;
|
||||
nWidth, nBold, lUnderLine, lItalic, lNewLine, ;
|
||||
lUpdatePosX, nColor, nAlignHori, nAlignVert ) CLASS WIN32PRN
|
||||
|
||||
DEFAULT nAlignHori TO ::SetTextHori
|
||||
DEFAULT nAlignVert TO ::SetTextVert
|
||||
__defaultNIL( @nAlignHori, ::SetTextHori )
|
||||
__defaultNIL( @nAlignVert, ::SetTextVert )
|
||||
|
||||
RETURN ::WIN_PRN:TextAtFont( nPosX, nPosY, cString, cFont, nPointSize, ;
|
||||
nWidth, nBold, lUnderLine, lItalic, lNewLine, ;
|
||||
|
||||
Reference in New Issue
Block a user