diff --git a/Makefile b/Makefile index cd986d8a..92635dde 100644 --- a/Makefile +++ b/Makefile @@ -66,7 +66,7 @@ build-internal: prepare-internal cp ../*.deb /build/; prepare-internal: - dch --create -v $(VERSION)-2 --package $(PACKAGE_NAME) empty; \ + dch --create -v $(VERSION)-5 --package $(PACKAGE_NAME) empty; \ cd $(WORKDIR)/..; \ tar -czf octoscreen_$(VERSION).orig.tar.gz --exclude-vcs OctoScreen diff --git a/ui/move.go b/ui/move.go index 6ed66460..b486a783 100644 --- a/ui/move.go +++ b/ui/move.go @@ -35,16 +35,16 @@ func (m *movePanel) initialize() { m.Grid().Attach(m.createMoveButton("Z+", "move-z+.svg", octoprint.ZAxis, 1), 3, 1, 1, 1) m.step = MustStepButton("move-step.svg", - Step{"5mm", 5}, Step{"10mm", 10}, Step{"1mm", 1}, + Step{"5mm", 5}, Step{"10mm", 10}, Step{"1mm", 1}, Step{"0.1mm", 0.1}, ) m.Grid().Attach(m.step, 2, 2, 1, 1) } -func (m *movePanel) createMoveButton(label, image string, a octoprint.Axis, dir int) gtk.IWidget { +func (m *movePanel) createMoveButton(label, image string, a octoprint.Axis, dir float64) gtk.IWidget { return MustPressedButton(label, image, func() { - distance := m.step.Value().(int) * dir + distance := m.step.Value().(float64) * dir cmd := &octoprint.PrintHeadJogRequest{} switch a { diff --git a/vendor/github.com/mcuadros/go-octoprint/printer.go b/vendor/github.com/mcuadros/go-octoprint/printer.go index 9bc83f6c..4b282f21 100644 --- a/vendor/github.com/mcuadros/go-octoprint/printer.go +++ b/vendor/github.com/mcuadros/go-octoprint/printer.go @@ -75,13 +75,13 @@ func (cmd *StateRequest) Do(c *Client) (*FullStateResponse, error) { type PrintHeadJogRequest struct { // X is the amount distance to travel in mm or coordinate to jog print head // on x axis. - X int `json:"x,omitempty"` + X float64 `json:"x,omitempty"` // Y is the amount distance to travel in mm or coordinate to jog print head // on y axis. - Y int `json:"y,omitempty"` + Y float64 `json:"y,omitempty"` // Z is the amount distance to travel in mm.or coordinate to jog print head // on x axis. - Z int `json:"z,omitempty"` + Z float64 `json:"z,omitempty"` // Absolute is whether to move relative to current position (provided axes // values are relative amounts) or to absolute position (provided axes // values are coordinates)