Skip to content

Commit

Permalink
Fixes loading text
Browse files Browse the repository at this point in the history
  • Loading branch information
jorgerojas26 committed Dec 9, 2023
1 parent 37bf97e commit 8ff86a1
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions components/ConnectionSelection.go
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,9 @@ func (cs *ConnectionSelection) connect(connectionUrl string) {
MainPages.SwitchToPage(connectionUrl)
App.Draw()
} else {
cs.StatusText.SetText("Connecting...").SetTextStyle(tcell.StyleDefault.Foreground(app.ActiveTextColor))
App.Draw()

newDbDriver := drivers.MySql{}
newDbDriver.SetConnectionString(connectionUrl)

Expand All @@ -139,13 +142,10 @@ func (cs *ConnectionSelection) connect(connectionUrl string) {
} else {
newHome := NewHomePage(connectionUrl, newDbDriver)

cs.StatusText.SetText("Connecting...").SetTextStyle(tcell.StyleDefault.Foreground(app.ActiveTextColor))
App.ForceDraw()

MainPages.AddAndSwitchToPage(connectionUrl, newHome, true)

cs.StatusText.SetText("")
App.ForceDraw()
App.Draw()

selectedRow, selectedCol := ConnectionListTable.GetSelection()
cell := ConnectionListTable.GetCell(selectedRow, selectedCol)
Expand Down

0 comments on commit 8ff86a1

Please sign in to comment.