Skip to content

Commit

Permalink
Merge pull request Codeux-Software#415 from elindsey/master
Browse files Browse the repository at this point in the history
add a 'Move Backward' menu option; rename selectNextSelection to selectN...
  • Loading branch information
emsquared committed Sep 12, 2013
2 parents b3a1460 + 63867a0 commit 82e5e66
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 6 deletions.
2 changes: 1 addition & 1 deletion Classes/Controllers/TXMasterController.m
Original file line number Diff line number Diff line change
Expand Up @@ -1055,7 +1055,7 @@ - (void)selectPreviousSelection:(NSEvent *)e
[self.worldController selectPreviousItem];
}

- (void)selectNextSelection:(NSEvent *)e
- (void)selectNextWindow:(NSEvent *)e
{
[self move:TXMoveAllKind target:TXMoveDownKind];
}
Expand Down
4 changes: 3 additions & 1 deletion Classes/Controllers/TXMenuController.m
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,7 @@ - (BOOL)validateMenuItemTag:(NSInteger)tag forItem:(NSMenuItem *)item
case 50010: // "Previous Unread Channel"
case 50011: // "Previous Selection"
case 50012: // "Move Forward"
case 50013: // "Move Backward"
case 521: // "Add Server…"
case 542: // "Logs"
case 5675: // "Connect to Help Channel"
Expand Down Expand Up @@ -2073,7 +2074,8 @@ - (void)processNavigationItem:(NSMenuItem *)sender
case 50009: { [self.masterController selectNextUnreadChannel:nil]; break; }
case 50010: { [self.masterController selectPreviousUnreadChannel:nil]; break; }
case 50011: { [self.masterController selectPreviousSelection:nil]; break; }
case 50012: { [self.masterController selectNextSelection:nil]; break; }
case 50012: { [self.masterController selectNextWindow:nil]; break; }
case 50013: { [self.masterController selectPreviousWindow:nil]; break; }
}
}

Expand Down
4 changes: 2 additions & 2 deletions Classes/Headers/TXMasterController.h
Original file line number Diff line number Diff line change
Expand Up @@ -97,17 +97,17 @@

- (void)selectNextServer:(NSEvent *)e;
- (void)selectNextChannel:(NSEvent *)e;
- (void)selectNextSelection:(NSEvent *)e;
- (void)selectNextWindow:(NSEvent *)e;
- (void)selectPreviousServer:(NSEvent *)e;
- (void)selectPreviousChannel:(NSEvent *)e;
- (void)selectPreviousWindow:(NSEvent *)e;
- (void)selectNextActiveServer:(NSEvent *)e;
- (void)selectNextUnreadChannel:(NSEvent *)e;
- (void)selectNextActiveChannel:(NSEvent *)e;
- (void)selectPreviousSelection:(NSEvent *)e;
- (void)selectPreviousActiveServer:(NSEvent *)e;
- (void)selectPreviousUnreadChannel:(NSEvent *)e;
- (void)selectPreviousActiveChannel:(NSEvent *)e;
- (void)selectPreviousWindow:(NSEvent *)e;
@end

@interface NSObject (TXMasterControllerObjectExtension)
Expand Down
1 change: 1 addition & 0 deletions Classes/Headers/TXMenuController.h
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@
50010: "Previous Unread Channel"
50011: "Previous Selection"
50012: "Move Forward"
50013: "Move Backward"
501: "Connect"
502: "Disconnect"
503: "Cancel Reconnect"
Expand Down
4 changes: 2 additions & 2 deletions Classes/Views/TVCMainWindow.m
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ - (void)swipeWithEvent:(NSEvent *)event
CGFloat x = [event deltaX];

if (x > 0) {
[self.masterController selectNextSelection:nil];
[self.masterController selectNextWindow:nil];
} else if (x < 0) {
[self.masterController selectPreviousWindow:nil];
}
Expand Down Expand Up @@ -139,7 +139,7 @@ - (void)endGestureWithEvent:(NSEvent *)event
if (delta.x > 0) {
[self.masterController selectPreviousWindow:nil];
} else {
[self.masterController selectNextSelection:nil];
[self.masterController selectNextWindow:nil];
}
}

Expand Down

0 comments on commit 82e5e66

Please sign in to comment.