Fix object code
This commit is contained in:
@@ -202,7 +202,7 @@ func (this *ScrollContainer) handleKeyDown (key input.Key, numpad bool) bool {
|
||||
vector := image.Point { }
|
||||
switch key {
|
||||
case input.KeyPageUp:
|
||||
if modifiers.Shift {
|
||||
if modifiers.Shift() {
|
||||
vector.X -= this.PageSize().X
|
||||
} else {
|
||||
vector.Y -= this.PageSize().Y
|
||||
@@ -210,7 +210,7 @@ func (this *ScrollContainer) handleKeyDown (key input.Key, numpad bool) bool {
|
||||
this.scrollBy(vector)
|
||||
return true
|
||||
case input.KeyPageDown:
|
||||
if modifiers.Shift {
|
||||
if modifiers.Shift() {
|
||||
vector.X += this.PageSize().X
|
||||
} else {
|
||||
vector.Y += this.PageSize().Y
|
||||
@@ -218,7 +218,7 @@ func (this *ScrollContainer) handleKeyDown (key input.Key, numpad bool) bool {
|
||||
this.scrollBy(vector)
|
||||
return true
|
||||
case input.KeyUp:
|
||||
if modifiers.Shift {
|
||||
if modifiers.Shift() {
|
||||
vector.X -= this.StepSize().X
|
||||
} else {
|
||||
vector.Y -= this.StepSize().Y
|
||||
@@ -226,7 +226,7 @@ func (this *ScrollContainer) handleKeyDown (key input.Key, numpad bool) bool {
|
||||
this.scrollBy(vector)
|
||||
return true
|
||||
case input.KeyDown:
|
||||
if modifiers.Shift {
|
||||
if modifiers.Shift() {
|
||||
vector.X += this.StepSize().X
|
||||
} else {
|
||||
vector.Y += this.StepSize().Y
|
||||
@@ -241,6 +241,8 @@ func (this *ScrollContainer) handleKeyUp (key input.Key, numpad bool) bool {
|
||||
switch key {
|
||||
case input.KeyPageUp: return true
|
||||
case input.KeyPageDown: return true
|
||||
case input.KeyUp: return true
|
||||
case input.KeyDown: return true
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user