MCPcopy
hub / github.com/g3n/engine / setVerticalScrollbarVisible

Method setVerticalScrollbarVisible

gui/scroller.go:322–330  ·  view source on GitHub ↗

setVerticalScrollbarVisible sets the vertical scrollbar visible, creating and initializing it if it's the first time

()

Source from the content-addressed store, hash-verified

320
321// setVerticalScrollbarVisible sets the vertical scrollbar visible, creating and initializing it if it's the first time
322func (s *Scroller) setVerticalScrollbarVisible() {
323 if s.vscroll == nil {
324 s.vscroll = NewVScrollBar(s.style.VerticalScrollbar.Broadness, 0)
325 s.vscroll.applyStyle(&s.style.VerticalScrollbar.ScrollBarStyle)
326 s.vscroll.Subscribe(OnChange, s.onScrollBarEvent)
327 s.Add(s.vscroll)
328 }
329 s.vscroll.SetVisible(true)
330}
331
332// setVerticalScrollbarVisible sets the horizontal scrollbar visible, creating and initializing it if it's the first time
333func (s *Scroller) setHorizontalScrollbarVisible() {

Callers 1

Calls 5

NewVScrollBarFunction · 0.85
SubscribeMethod · 0.65
SetVisibleMethod · 0.65
applyStyleMethod · 0.45
AddMethod · 0.45

Tested by

no test coverage detected