1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-07-06 10:42:32 +03:00

render commit graph

This commit is contained in:
Jesse Duffield
2021-11-02 16:39:15 +11:00
parent 2fc1498517
commit 802cfb1a04
53 changed files with 543 additions and 284 deletions

View File

@ -75,8 +75,6 @@ type GuiMutexes struct {
tickingMutex sync.Mutex
ViewsMutex sync.Mutex
drawMutex sync.Mutex
}
type PlayMode int
@ -936,8 +934,6 @@ func (g *Gui) drawListFooter(v *View, fgColor, bgColor Attribute) error {
// flush updates the gui, re-drawing frames and buffers.
func (g *Gui) flush() error {
g.Mutexes.drawMutex.Lock()
defer g.Mutexes.drawMutex.Unlock()
// pretty sure we don't need this, but keeping it here in case we get weird visual artifacts
// g.clear(g.FgColor, g.BgColor)
@ -966,18 +962,6 @@ func (g *Gui) flush() error {
return nil
}
func (g *Gui) Draw(v *View) error {
g.Mutexes.drawMutex.Lock()
defer g.Mutexes.drawMutex.Unlock()
if err := g.draw(v); err != nil {
return err
}
Screen.Show()
return nil
}
// draw manages the cursor and calls the draw function of a view.
func (g *Gui) draw(v *View) error {
if g.suspended {