...
 
Commits (3)
This diff is collapsed.
This diff is collapsed.
......@@ -65,7 +65,7 @@ Public Sub SelectButton(iTab As Integer)
Dim hButton As ToolButton = Me.Children[iTab]
If $bNoSelectButton Then Return
$bNoSelectButton = True
If Not hButton.Value Then hButton.Value = True
$bNoSelectButton = False
......
......@@ -39,8 +39,8 @@
Name = "btnTasks"
MoveScaled(58,0,10,4)
AutoResize = True
Text = ("Tasks")
Picture = Picture["icon:/small/apply"]
Text = ("Notes")
Picture = Picture["icon:/small/tag"]
Toggle = True
}
{ btnSearchList ToolButton btnDebug
......@@ -59,4 +59,12 @@
Picture = Picture["icon:/small/clock"]
Toggle = True
}
{ btnTest ToolButton btnDebug
Name = "btnTest"
MoveScaled(104,0,12,4)
AutoResize = True
Text = ("Unit tests")
Picture = Picture["icon:/small/ok"]
Toggle = True
}
}
......@@ -2,7 +2,7 @@
Public Shown As Boolean
Private Enum TAB_DEBUG, TAB_CONSOLE, TAB_BREAK, TAB_COMPILATION, TAB_TASK, TAB_SEARCH, TAB_VERSION_CONTROL
Private Enum TAB_DEBUG, TAB_CONSOLE, TAB_BREAK, TAB_COMPILATION, TAB_TASK, TAB_SEARCH, TAB_VERSION_CONTROL, TAB_TEST
Private $cRefreshBreakpoint As New Collection
......@@ -316,6 +316,8 @@ Public Sub ReadConfig()
Project.SetConsoleFont(trmVersionControl)
MTheme.InitControl(trmVersionControl)
Project.SetConsoleFont(trmTest)
MTheme.InitControl(trmTest)
For Each hCtrl In [panBreakpoint, panSearch, panVersionControl]
Project.SetSmallFont(hCtrl)
......@@ -900,6 +902,7 @@ Public Sub OnProjectChange()
SetCompilation
CloseSearch
trmVersionControl.Clear
trmTest.Clear
End
......@@ -1412,6 +1415,12 @@ Public Sub ShowDebugging()
End
Public Sub ShowTest()
FDebugButton.SelectButton(TAB_TEST)
End
Public Sub cvwVariable_Rename()
Dim sVar As String
......@@ -1516,3 +1525,21 @@ Public Sub cvwVariable_Select()
Balloon.Hide(cvwVariable)
End
Public Sub GetTestTerminal() As TerminalView
Return trmTest
End
Public Sub btnTestClear_Click()
trmTest.Clear
End
Public Sub btnTest_Click()
Design.Test()
End
......@@ -15,7 +15,7 @@
{ wizDebug Wizard
MoveScaled(2,5,122,41)
Arrangement = Arrange.Vertical
Count = 7
Count = 8
ShowTitle = False
ShowButton = False
Border = False
......@@ -317,6 +317,34 @@
Border = False
Limit = 65536
Blink = True
ReadOnly = True
}
Index = 7
Text = ("Test")
{ panVersionControl2 HBox
MoveScaled(0,0,119,4)
{ btnTestClear ToolButton
MoveScaled(0,0,4,4)
ToolTip = ("Clear console")
Picture = Picture["icon:/small/clear"]
}
{ btnTest ToolButton
MoveScaled(5,0,14,4)
AutoResize = True
Text = ("Test again")
Picture = Picture["icon:/small/ok"]
}
}
{ Separator2 Separator
MoveScaled(19,6,34,0)
}
{ trmTest TerminalView
MoveScaled(1,8,69,27)
Expand = True
Border = False
Limit = 65536
Blink = True
ReadOnly = True
}
Index = 0
}
......
......@@ -1421,6 +1421,8 @@ Public Sub Action_Activate((Key) As String) As Boolean
panProject.Hidden = Not Action[Key].Value
Case "start"
Project.Run(False)
Case "test"
Project.Test()
Case "pause"
Design.Pause
Case "stop"
......
......@@ -259,6 +259,12 @@
Checked = True
}
}
{ mnuTest Menu
Action = "test"
Text = ("Test")
Picture = Picture["icon:/small/ok"]
Shortcut = "F4"
}
{ Menu36 Menu
}
{ mnuUseTerminal Menu
......@@ -379,7 +385,6 @@
Picture = Picture["icon:/small/edit"]
Toggle = True
Checked = True
Shortcut = "F4"
}
{ mnuViewConsole Menu
Action = "console"
......@@ -975,67 +980,73 @@
Action = "compile-all"
Picture = Picture["icon:/small/make-all"]
}
{ btnTest ToolButton
MoveScaled(70,0,4,4)
ToolTip = ("Test")
Action = "test"
Picture = Picture["icon:/small/ok"]
}
{ btnGo MenuButton
MoveScaled(70,0,6,4)
MoveScaled(74,0,6,4)
ToolTip = ("Run")
Action = "start"
Picture = Picture["icon:/small/play"]
Border = False
}
{ btnPause ToolButton
MoveScaled(75,0,4,4)
MoveScaled(79,0,4,4)
ToolTip = ("Pause")
Action = "pause"
Picture = Picture["icon:/small/pause"]
}
{ btnStop ToolButton
MoveScaled(78,0,4,4)
MoveScaled(82,0,4,4)
ToolTip = ("Stop")
Action = "stop"
Picture = Picture["icon:/small/stop"]
}
{ btnStep ToolButton
MoveScaled(81,0,4,4)
MoveScaled(85,0,4,4)
ToolTip = ("Step")
Action = "step"
Picture = Picture["icon:/small/end"]
}
{ btnForward ToolButton
MoveScaled(84,0,4,4)
MoveScaled(88,0,4,4)
ToolTip = ("Forward")
Action = "forward"
Picture = Picture["icon:/small/forward"]
}
{ btnFrom ToolButton
MoveScaled(86,0,4,4)
MoveScaled(90,0,4,4)
ToolTip = ("Finish current function")
Action = "return"
Picture = Picture["icon:/small/eject"]
}
{ btnUntil ToolButton mnuUntil
Name = "btnUntil"
MoveScaled(89,0,4,4)
MoveScaled(93,0,4,4)
ToolTip = ("Run until current line")
Action = "until"
Picture = Picture["icon:/small/jump"]
}
{ btnShowMenu ToolButton
MoveScaled(94,0,4,4)
MoveScaled(98,0,4,4)
Visible = False
ToolTip = ("Show menubar")
Picture = Picture["icon:/small/menu"]
}
{ Panel3 Panel
MoveScaled(98,0,1,4)
MoveScaled(102,0,1,4)
}
{ txtSearch ButtonBox
MoveScaled(99,0,37,4)
MoveScaled(103,0,37,4)
ToolTip = ("Browse project") & "..."
Action = "find-project"
Picture = Picture["icon:/small/find"]
}
{ btnGoBack MenuButton
MoveScaled(136,0,6,4)
MoveScaled(140,0,6,4)
Enabled = False
ToolTip = ("Go back")
Action = "go-back"
......@@ -1044,28 +1055,28 @@
Menu = "mnuBackward"
}
{ btnGoForward ToolButton
MoveScaled(140,0,4,4)
MoveScaled(144,0,4,4)
Enabled = False
ToolTip = ("Go forward")
Action = "go-forward"
Picture = Picture["icon:/small/right"]
}
{ ToolButton6 ToolButton
MoveScaled(143,0,4,4)
MoveScaled(147,0,4,4)
Visible = False
ToolTip = ("Browse project")
Action = "browse-project"
Picture = Picture["icon:/small/file-manager"]
}
{ ToolButton11 ToolButton
MoveScaled(145,0,4,4)
MoveScaled(149,0,4,4)
Visible = False
ToolTip = ("Open a terminal")
Action = "open-terminal"
Picture = Picture["icon:/small/terminal"]
}
{ ToolButton13 ToolButton
MoveScaled(148,0,4,4)
MoveScaled(152,0,4,4)
Visible = False
ToolTip = ("Send project by mail")
Action = "send-mail"
......@@ -1684,7 +1695,7 @@
}
{ Action property
Text = "Properties"
Shortcut = "F4"
Shortcut = ""
Picture = "icon:/small/properties"
}
{ Action publish
......@@ -1779,6 +1790,11 @@
Text = "Use terminal emulator"
Shortcut = ""
}
{ Action test
Text = "Test"
Shortcut = "F4"
Picture = "icon:/small/ok"
}
{ Action tips
Text = "Tips of the day"
Shortcut = ""
......@@ -1837,7 +1853,7 @@
{ Toolbars
{ Toolbar main
Text = ""
List = "new-project,open-project,save-project,save-project-as,project-property,refresh-project,option,shortcut,exec,translate,archive,install,project,property,control,console,find,help,compile,compile-all,start,pause,stop,step,forward,return,until,find-project,go-back,go-forward,browse-project,open-terminal,send-mail,publish,farm,gui,menu-file,menu-edit,menu-project,menu-debug,menu-view,menu-tool,menu-help,version-control"
Default = "new-project,open-project,save-project,save-project-as,project-property,option,|,exec,translate,|,compile,compile-all,start,pause,stop,step,forward,return,until,-,find-project,go-back,go-forward,version-control"
List = "new-project,open-project,save-project,save-project-as,project-property,refresh-project,option,shortcut,exec,translate,archive,install,project,property,control,console,find,help,compile,compile-all,test,start,pause,stop,step,forward,return,until,find-project,go-back,go-forward,browse-project,open-terminal,send-mail,publish,farm,gui,menu-file,menu-edit,menu-project,menu-debug,menu-view,menu-tool,menu-help,version-control"
Default = "new-project,open-project,save-project,save-project-as,project-property,option,|,exec,translate,|,compile,compile-all,test,start,pause,stop,step,forward,return,until,-,find-project,go-back,go-forward,version-control"
}
}
......@@ -143,13 +143,13 @@ Public Sub SelectImage(sPropertyType As String, sImage As String) As String
Dim iOption As Integer
Dim aSizes As String[]
If sPropertyType <> "Image" Then
'If sPropertyType <> "Image" Then
If Project.Components.Exist("gb.form") Then
iOption = FSelectIcon.SELECT_STOCK
aSizes = Stock.Sizes
aSizes.Insert(["16", "22", "24", "32", "48", "64", "96", "128", "192", "256"])
Endif
Endif
'Endif
If sPropertyType = "SvgImage" Then
iOption += FSelectIcon.SELECT_SVGIMAGE
Else
......
......@@ -2548,6 +2548,13 @@ Public Sub Run(Optional bCompileAll As Boolean, Optional iDebug As Integer, Opti
End
Public Sub Test()
If CheckRunning() Then Return
Design.Test
End
Public Sub Forward()
If CheckRunning() Then Return
......
# Gambas Form File 3.0
{ FTest Form
MoveScaled(0,0,64,64)
}
[Component]
Key=gb.test
Version=3.14.90
State=2
State=1
Hidden=True
Authors=Christof Thalhofer,Tobias Boege
comp/src/gb.test/.icon.png

10.9 KB | W: | H:

comp/src/gb.test/.icon.png

10.7 KB | W: | H:

comp/src/gb.test/.icon.png
comp/src/gb.test/.icon.png
comp/src/gb.test/.icon.png
comp/src/gb.test/.icon.png
  • 2-up
  • Swipe
  • Onion skin
......@@ -126,6 +126,11 @@ void COMPONENT_load_all(void)
COMPONENT_create("gb.eval");
COMPONENT_create("gb.debug");
}
if (PROJECT_run_tests)
{
COMPONENT_create("gb.test");
}
_load_all = TRUE;
......