Add timestamp editor
This commit is contained in:
@ -65,3 +65,7 @@ func (c *Common) PopPage() (Component, error) {
|
||||
component.SetSize(c.width, c.height)
|
||||
return component, nil
|
||||
}
|
||||
|
||||
func (c *Common) HasSubpages() bool {
|
||||
return !c.pageStack.IsEmpty()
|
||||
}
|
||||
|
||||
@ -38,3 +38,10 @@ func (s *Stack[T]) Pop() (T, error) {
|
||||
|
||||
return item, nil
|
||||
}
|
||||
|
||||
func (s *Stack[T]) IsEmpty() bool {
|
||||
s.mutex.Lock()
|
||||
defer s.mutex.Unlock()
|
||||
|
||||
return len(s.items) == 0
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user