Documentation
¶
Index ¶
- type App
- func (a *App) AddFileAnnotationListener(c chan<- model.Annotation)
- func (a *App) AddFileListener(c chan<- *model.File)
- func (a *App) AddLineAnnotationListener(c chan<- model.Annotation)
- func (a *App) AddView(view gocui.Manager)
- func (a *App) AddWorkItemListener(c chan<- *work.FetchedItem)
- func (a *App) Close()
- func (a *App) CycleToNextView()
- func (a *App) Loop()
- func (a *App) SetFile(filename string, start, end int)
- func (a *App) SetHighlightedLine(line *model.Line)
- func (a *App) SetSelectedWorkItem(item *work.FetchedItem)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type App ¶
type App struct {
// contains filtered or unexported fields
}
App is the entry point into the tribe blame app. It manages the state of all the views that make up the entirity of the blame app.
func NewApp ¶
NewApp creates an instance of the App struct for the given model.File. This will create the CUI for blame.
func (*App) AddFileAnnotationListener ¶
func (a *App) AddFileAnnotationListener(c chan<- model.Annotation)
AddFileAnnotationListener adds a channel that will get notified every time a new file based annotation is available for display
func (*App) AddFileListener ¶
AddFileListener adds a channel that will get notified every time a new file is available for display
func (*App) AddLineAnnotationListener ¶
func (a *App) AddLineAnnotationListener(c chan<- model.Annotation)
AddLineAnnotationListener adds a channel that will get notified every time a new line based annotation is available for display
func (*App) AddView ¶
AddView adds a new view to blame.App. Every view added to the app will be added to to the underlying CUI system. blame.App also keeps track of the currently "focused" view and allows use of the TAB key to cycle between focusable views.
func (*App) AddWorkItemListener ¶
func (a *App) AddWorkItemListener(c chan<- *work.FetchedItem)
AddWorkItemListener adds a channel that will get notified every time a new work item is available for display
func (*App) Close ¶
func (a *App) Close()
Close stops the blame app and returns control back to the console
func (*App) CycleToNextView ¶
func (a *App) CycleToNextView()
CycleToNextView will Focus the next view in the list of views that can be focused. A view can be focused if it contains a FocusOn key
func (*App) Loop ¶
func (a *App) Loop()
Loop starts to CUI loop for the blame app. This function will hang until Close is called on this App.
func (*App) SetHighlightedLine ¶
SetHighlightedLine changes the current hightlighted line in blame app. This will trigger any view changes that are driven by line changes
func (*App) SetSelectedWorkItem ¶
func (a *App) SetSelectedWorkItem(item *work.FetchedItem)
SetSelectedWorkItem changes the currently selected work item in the blame app