- contrib/examples
+ examples
* doc/dirstruc.txt
* doc/whatsnew.txt
* examples/hbdoc/Makefile
* examples/pp/Makefile
* examples/hboleold/Makefile
* examples/hbsqlit2/Makefile
* examples/misc/Makefile
* examples/hbapollo/Makefile
* examples/rdddbt/Makefile
* examples/guestbk/Makefile
* examples/pe/Makefile
* examples/hbgf/hbgfwin/Makefile
* examples/hbgf/hbgfos2/Makefile
* examples/hbgf/hbgfgtk/Makefile
* examples/hbgf/Makefile
* examples/uhttpd/readme.txt
* examples/dbu/Makefile
* examples/hscript/Makefile
* examples/hbwhat/Makefile
* examples/rl/Makefile
* examples/Makefile
* Moved to flatten our dir layout and sync the locations
in unified distro and source tree.
; TODO: As a next step I'll replace Makefiles with .hbm
files. This will allow users to build these parts
outside the source distribution.
61 lines
1.2 KiB
Plaintext
61 lines
1.2 KiB
Plaintext
//
|
|
// $Id$
|
|
//
|
|
// Testing forms persistence
|
|
|
|
#include "hbclass.ch"
|
|
|
|
function Main()
|
|
|
|
local oForm2 := HBForm2():New()
|
|
|
|
oForm2:OnClick := "Form2Click"
|
|
|
|
oForm2:ShowModal()
|
|
|
|
return nil
|
|
|
|
CLASS HBForm2 FROM HBForm
|
|
|
|
METHOD New()
|
|
|
|
METHOD ViewAsTextClick( oSender ) INLINE MsgInfo( ::SaveToText() )
|
|
METHOD ExitClick( oSender ) INLINE ::Close()
|
|
|
|
METHOD Form2Click( oSender, nXPos, nYPos )
|
|
|
|
ENDCLASS
|
|
|
|
METHOD New() CLASS HBForm2
|
|
|
|
local oMenu, oMenuItem
|
|
|
|
Super:New()
|
|
|
|
::Caption := "Harbour GUI demo"
|
|
|
|
oMenu := HBMenu():New( Self )
|
|
|
|
oMenuItem := HGFMenuItem():New( oMenu )
|
|
oMenuitem:Caption := "View as Text"
|
|
oMenuitem:Name := "ViewAsText"
|
|
oMenuItem:OnClick := "ViewAsTextClick" // The container method to execute
|
|
oMenu:Add( oMenuItem )
|
|
|
|
oMenuItem := HGFMenuItem():New( oMenu )
|
|
oMenuitem:Caption := "Exit"
|
|
oMenuitem:Name := "Exit"
|
|
oMenuItem:OnClick := "ExitClick" // The container method to execute
|
|
oMenu:Add( oMenuItem )
|
|
|
|
::Menu := oMenu
|
|
|
|
return Self
|
|
|
|
METHOD Form2Click( oSender, nXPos, nYPos ) CLASS HBForm2
|
|
|
|
MsgInfo( "Click at " + AllTrim( Str( nXPos ) ) + ", " + ;
|
|
AllTrim( Str( nYPos ) ) )
|
|
|
|
return nil
|