mirror of
https://github.com/vsariola/sointu.git
synced 2025-06-03 00:58:26 -04:00
refactor(tracker): move C & D type shortcuts for layout.Context and layout.Dimensions to layout.go
layout.go is where the basic core of the layout should reside
This commit is contained in:
parent
cece2d77d4
commit
e2fcfbbc4a
@ -14,9 +14,6 @@ import (
|
|||||||
"golang.org/x/exp/shiny/materialdesign/icons"
|
"golang.org/x/exp/shiny/materialdesign/icons"
|
||||||
)
|
)
|
||||||
|
|
||||||
type C = layout.Context
|
|
||||||
type D = layout.Dimensions
|
|
||||||
|
|
||||||
func (t *Tracker) updateInstrumentScroll() {
|
func (t *Tracker) updateInstrumentScroll() {
|
||||||
if t.CurrentInstrument > 7 {
|
if t.CurrentInstrument > 7 {
|
||||||
t.InstrumentDragList.List.Position.First = t.CurrentInstrument - 7
|
t.InstrumentDragList.List.Position.First = t.CurrentInstrument - 7
|
||||||
|
@ -11,6 +11,9 @@ import (
|
|||||||
"gioui.org/widget/material"
|
"gioui.org/widget/material"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
type C = layout.Context
|
||||||
|
type D = layout.Dimensions
|
||||||
|
|
||||||
func smallButton(icStyle material.IconButtonStyle) material.IconButtonStyle {
|
func smallButton(icStyle material.IconButtonStyle) material.IconButtonStyle {
|
||||||
icStyle.Size = unit.Dp(14)
|
icStyle.Size = unit.Dp(14)
|
||||||
icStyle.Inset = layout.UniformInset(unit.Dp(1))
|
icStyle.Inset = layout.UniformInset(unit.Dp(1))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user