Skip to content

Commit

Permalink
Merge pull request epreston#20 from cekoski/master
Browse files Browse the repository at this point in the history
Fixed keyboard navigation in flipped orientations. Thanks @cekoski
  • Loading branch information
epreston committed Sep 5, 2012
2 parents 9be5bed + 562b899 commit 3e8a407
Showing 1 changed file with 20 additions and 4 deletions.
24 changes: 20 additions & 4 deletions PSTreeGraphView/PSBaseTreeGraphView.m
Original file line number Diff line number Diff line change
Expand Up @@ -932,16 +932,32 @@ - (void) insertText:(NSString *)theText
[self toggleExpansionOfSelectedModelNodes:self];
break;
case 'w':
[self moveUp:self];
if (self.treeGraphOrientation == PSTreeGraphOrientationStyleVerticalFlipped ) {
[self moveDown:self];
} else {
[self moveUp:self];
}
break;
case 'a':
[self moveLeft:self];
if (self.treeGraphOrientation == PSTreeGraphOrientationStyleHorizontalFlipped ) {
[self moveRight:self];
} else {
[self moveLeft:self];
}
break;
case 's':
[self moveDown:self];
if (self.treeGraphOrientation == PSTreeGraphOrientationStyleVerticalFlipped ) {
[self moveUp:self];
} else {
[self moveDown:self];
}
break;
case 'd':
[self moveRight:self];
if (self.treeGraphOrientation == PSTreeGraphOrientationStyleHorizontalFlipped ) {
[self moveLeft:self];
} else {
[self moveRight:self];
}
break;

default:
Expand Down

0 comments on commit 3e8a407

Please sign in to comment.