inky/impression: fix init of bounds

Fix typo in initialization of bounds when bounds are not explicitely set
by the user.
pull/102/head
Olivier Mengué 1 year ago
parent bc9678aa18
commit 13698420d8

@ -205,7 +205,7 @@ func NewImpression(p spi.Port, dc gpio.PinOut, reset gpio.PinOut, busy gpio.PinI
d.res = 0b11 d.res = 0b11
} }
// Prefer the passed in values via Opts. // Prefer the passed in values via Opts.
if o.Width == 0 && o.Height == 0 { if o.Width != 0 && o.Height != 0 {
d.width = o.Width d.width = o.Width
d.height = o.Height d.height = o.Height
} }

Loading…
Cancel
Save