File: w_main.srw
Size: 4892
Date: Fri, 09 Aug 2019 16:21:56 +0200
$PBExportHeader$w_main.srw
forward
global type w_main from window
end type
type st_2 from statictext within w_main
end type
type st_1 from statictext within w_main
end type
type cb_optionoff from commandbutton within w_main
end type
type cb_beep from commandbutton within w_main
end type
type cb_stop from commandbutton within w_main
end type
type cb_start from commandbutton within w_main
end type
type cb_cancel from commandbutton within w_main
end type
end forward

global type w_main from window
integer width = 2135
integer height = 1044
boolean titlebar = true
string title = "PBDebug"
boolean controlmenu = true
boolean minbox = true
boolean maxbox = true
long backcolor = 67108864
string icon = "AppIcon!"
boolean center = true
st_2 st_2
st_1 st_1
cb_optionoff cb_optionoff
cb_beep cb_beep
cb_stop cb_stop
cb_start cb_start
cb_cancel cb_cancel
end type
global w_main w_main

type prototypes

end prototypes

type variables
n_pbdebug in_pbdebug

end variables

on w_main.create
this.st_2=create st_2
this.st_1=create st_1
this.cb_optionoff=create cb_optionoff
this.cb_beep=create cb_beep
this.cb_stop=create cb_stop
this.cb_start=create cb_start
this.cb_cancel=create cb_cancel
this.Control[]={this.st_2,&
this.st_1,&
this.cb_optionoff,&
this.cb_beep,&
this.cb_stop,&
this.cb_start,&
this.cb_cancel}
end on

on w_main.destroy
destroy(this.st_2)
destroy(this.st_1)
destroy(this.cb_optionoff)
destroy(this.cb_beep)
destroy(this.cb_stop)
destroy(this.cb_start)
destroy(this.cb_cancel)
end on

type st_2 from statictext within w_main
integer x = 37
integer y = 672
integer width = 2053
integer height = 68
integer textsize = -10
integer weight = 400
fontcharset fontcharset = ansi!
fontpitch fontpitch = variable!
fontfamily fontfamily = swiss!
string facename = "Tahoma"
long textcolor = 255
long backcolor = 67108864
string text = "Make sure you changed the external functions to the correct version of pbvm."
boolean focusrectangle = false
end type

type st_1 from statictext within w_main
integer x = 37
integer y = 576
integer width = 978
integer height = 68
integer textsize = -10
integer weight = 400
fontcharset fontcharset = ansi!
fontpitch fontpitch = variable!
fontfamily fontfamily = swiss!
string facename = "Tahoma"
long textcolor = 255
long backcolor = 67108864
string text = "This will only work in an executable!"
boolean focusrectangle = false
end type

type cb_optionoff from commandbutton within w_main
integer x = 37
integer y = 416
integer width = 443
integer height = 100
integer taborder = 50
integer textsize = -8
integer weight = 400
fontcharset fontcharset = ansi!
fontpitch fontpitch = variable!
fontfamily fontfamily = swiss!
string facename = "Tahoma"
string text = "Option Off"
end type

event clicked;// turn off debugging option
in_pbdebug.of_option_off(34)

end event

type cb_beep from commandbutton within w_main
integer x = 37
integer y = 288
integer width = 443
integer height = 100
integer taborder = 40
integer textsize = -8
integer weight = 400
fontcharset fontcharset = ansi!
fontpitch fontpitch = variable!
fontfamily fontfamily = swiss!
string facename = "Tahoma"
string text = "Beep"
end type

event clicked;Beep(1)

end event

type cb_stop from commandbutton within w_main
integer x = 37
integer y = 160
integer width = 443
integer height = 100
integer taborder = 30
integer textsize = -8
integer weight = 400
fontcharset fontcharset = ansi!
fontpitch fontpitch = variable!
fontfamily fontfamily = swiss!
string facename = "Tahoma"
string text = "Stop Debug"
end type

event clicked;// turn off debugging
in_pbdebug.of_debug_off()

end event

type cb_start from commandbutton within w_main
integer x = 37
integer y = 32
integer width = 443
integer height = 100
integer taborder = 20
integer textsize = -8
integer weight = 400
fontcharset fontcharset = ansi!
fontpitch fontpitch = variable!
fontfamily fontfamily = swiss!
string facename = "Tahoma"
string text = "Start Debug"
end type

event clicked;// set debug filename
in_pbdebug.of_logfilename("C:\Temp\pbtrace.txt")

// turn on debugging
in_pbdebug.of_debug_on()

// turn on debugging options
in_pbdebug.of_option_on(1)    // Display console
in_pbdebug.of_option_on(30)   // Show function/event calls
in_pbdebug.of_option_on(34)   // Show pcode line execution

end event

type cb_cancel from commandbutton within w_main
integer x = 1755
integer y = 832
integer width = 334
integer height = 100
integer taborder = 10
integer textsize = -8
integer weight = 400
fontcharset fontcharset = ansi!
fontpitch fontpitch = variable!
fontfamily fontfamily = swiss!
string facename = "Tahoma"
string text = "Cancel"
boolean cancel = true
end type

event clicked;Close(Parent)

end event