Changeset 313
- Timestamp:
- Jun 10, 2006, 3:21:36 AM (17 years ago)
- Location:
- trunk/macosx
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/macosx/Controller.m
r310 r313 1141 1141 SEL action = [menuItem action]; 1142 1142 1143 //only enable some menus if window is useable1143 //only enable some items if the window is useable or it is in a context menu 1144 1144 BOOL canUseWindow = [fWindow isKeyWindow] && ![fToolbar customizationPaletteIsRunning]; 1145 BOOL fromContext = [[[menuItem menu] title] isEqualToString: @"Context"]; 1145 1146 1146 1147 //enable show info … … 1191 1192 if (action == @selector(revealFile:)) 1192 1193 { 1193 return canUseWindow&& [fTableView numberOfSelectedRows] > 0;1194 return (canUseWindow || fromContext) && [fTableView numberOfSelectedRows] > 0; 1194 1195 } 1195 1196 … … 1225 1226 [title rangeOfString: NS_ELLIPSIS].location]]; 1226 1227 } 1227 return canUseWindow&& [fTableView numberOfSelectedRows] > 0;1228 return (canUseWindow || fromContext) && [fTableView numberOfSelectedRows] > 0; 1228 1229 } 1229 1230 … … 1231 1232 if( action == @selector(stopTorrent:) ) 1232 1233 { 1233 if (!canUseWindow )1234 if (!canUseWindow && !fromContext) 1234 1235 return NO; 1235 1236 … … 1250 1251 if( action == @selector(resumeTorrent:) ) 1251 1252 { 1252 if (!canUseWindow )1253 if (!canUseWindow && !fromContext) 1253 1254 return NO; 1254 1255 -
trunk/macosx/TorrentTableView.m
r284 r313 29 29 30 30 #define BUTTON_WIDTH 14.0 31 #define BUTTON_TO_TOP 3 2.532 #define AREA_CENTER 2 3.031 #define BUTTON_TO_TOP 33.5 32 #define AREA_CENTER 21.0 33 33 #define DISTANCE_FROM_CENTER 2.5 34 34 35 35 @implementation TorrentTableView 36 37 - (void) awakeFromNib 38 { 39 [fContextRow setTitle: @"Context"]; 40 [fContextNoRow setTitle: @"Context"]; 41 } 36 42 37 43 - (void) setTorrents: (NSArray *) torrents
Note: See TracChangeset
for help on using the changeset viewer.