Un-export SliderHandle

Closes #8
This commit is contained in:
Sasha Koshka 2024-08-16 18:35:19 -04:00
parent 155752ba78
commit 0fe4979483
2 changed files with 5 additions and 7 deletions

View File

@ -9,7 +9,7 @@ import "git.tebibyte.media/tomo/tomo/event"
// overflowing ContainerBox.
type Scrollbar struct {
tomo.ContainerBox
handle *SliderHandle
handle *sliderHandle
layout scrollbarLayout
dragging bool
dragOffset image.Point
@ -24,7 +24,7 @@ type Scrollbar struct {
func newScrollbar (orient string) *Scrollbar {
this := &Scrollbar {
ContainerBox: tomo.NewContainerBox(),
handle: &SliderHandle {
handle: &sliderHandle {
Box: tomo.NewBox(),
},
layout: scrollbarLayout {

View File

@ -9,7 +9,7 @@ import "git.tebibyte.media/tomo/tomo/event"
// Slider is a control that selects a numeric value between 0 and 1.
type Slider struct {
tomo.ContainerBox
handle *SliderHandle
handle *sliderHandle
layout sliderLayout
dragging bool
dragOffset image.Point
@ -21,16 +21,14 @@ type Slider struct {
}
}
// SliderHandle is a simple object that serves as a handle for sliders and
// scrollbars. It is completely inert.
type SliderHandle struct {
type sliderHandle struct {
tomo.Box
}
func newSlider (orient string, value float64) *Slider {
this := &Slider {
ContainerBox: tomo.NewContainerBox(),
handle: &SliderHandle {
handle: &sliderHandle {
Box: tomo.NewBox(),
},
layout: sliderLayout {