- Timestamp:
- Sep 25, 2006, 8:53:10 PM (16 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 2 deleted
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Transmission.xcodeproj/project.pbxproj
r922 r923 8 8 9 9 /* Begin PBXBuildFile section */ 10 3518E4A50AC620FC002ED3A2 /* Pieces WindowController.h in Headers */ = {isa = PBXBuildFile; fileRef = 3518E4A30AC620FC002ED3A2 /* PiecesWindowController.h */; };11 3518E4A60AC620FC002ED3A2 /* Pieces WindowController.m in Sources */ = {isa = PBXBuildFile; fileRef = 3518E4A40AC620FC002ED3A2 /* PiecesWindowController.m */; };10 3518E4A50AC620FC002ED3A2 /* PiecesView.h in Headers */ = {isa = PBXBuildFile; fileRef = 3518E4A30AC620FC002ED3A2 /* PiecesView.h */; }; 11 3518E4A60AC620FC002ED3A2 /* PiecesView.m in Sources */ = {isa = PBXBuildFile; fileRef = 3518E4A40AC620FC002ED3A2 /* PiecesView.m */; }; 12 12 3518E4D10AC62517002ED3A2 /* PiecesBack.tiff in CopyFiles */ = {isa = PBXBuildFile; fileRef = 3518E4CD0AC62517002ED3A2 /* PiecesBack.tiff */; }; 13 13 3518E4D30AC62517002ED3A2 /* BoxBlue1.tiff in CopyFiles */ = {isa = PBXBuildFile; fileRef = 3518E4CF0AC62517002ED3A2 /* BoxBlue1.tiff */; }; 14 14 3518E4D40AC62517002ED3A2 /* BoxBlue2.tiff in CopyFiles */ = {isa = PBXBuildFile; fileRef = 3518E4D00AC62517002ED3A2 /* BoxBlue2.tiff */; }; 15 3518E4D70AC6253F002ED3A2 /* PiecesWindow.nib in Resources */ = {isa = PBXBuildFile; fileRef = 3518E4D50AC6253F002ED3A2 /* PiecesWindow.nib */; }; 16 3518E4FB0AC62832002ED3A2 /* PiecesWindowController.m in Sources */ = {isa = PBXBuildFile; fileRef = 3518E4A40AC620FC002ED3A2 /* PiecesWindowController.m */; }; 15 3518E4FB0AC62832002ED3A2 /* PiecesView.m in Sources */ = {isa = PBXBuildFile; fileRef = 3518E4A40AC620FC002ED3A2 /* PiecesView.m */; }; 17 16 3518E5210AC62A29002ED3A2 /* PiecesBack.tiff in Resources */ = {isa = PBXBuildFile; fileRef = 3518E4CD0AC62517002ED3A2 /* PiecesBack.tiff */; }; 18 17 3518E5230AC62A2A002ED3A2 /* BoxBlue2.tiff in Resources */ = {isa = PBXBuildFile; fileRef = 3518E4D00AC62517002ED3A2 /* BoxBlue2.tiff */; }; … … 250 249 29B97325FDCFA39411CA2CEA /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = /System/Library/Frameworks/Foundation.framework; sourceTree = "<absolute>"; }; 251 250 32CA4F630368D1EE00C91783 /* Transmission_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = Transmission_Prefix.pch; path = macosx/Transmission_Prefix.pch; sourceTree = "<group>"; }; 252 3518E4A30AC620FC002ED3A2 /* Pieces WindowController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PiecesWindowController.h; sourceTree = "<group>"; };253 3518E4A40AC620FC002ED3A2 /* Pieces WindowController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PiecesWindowController.m; sourceTree = "<group>"; };251 3518E4A30AC620FC002ED3A2 /* PiecesView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PiecesView.h; sourceTree = "<group>"; }; 252 3518E4A40AC620FC002ED3A2 /* PiecesView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PiecesView.m; sourceTree = "<group>"; }; 254 253 3518E4CD0AC62517002ED3A2 /* PiecesBack.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; name = PiecesBack.tiff; path = macosx/Images/PiecesBack.tiff; sourceTree = "<group>"; }; 255 254 3518E4CF0AC62517002ED3A2 /* BoxBlue1.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; name = BoxBlue1.tiff; path = macosx/Images/BoxBlue1.tiff; sourceTree = "<group>"; }; 256 255 3518E4D00AC62517002ED3A2 /* BoxBlue2.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; name = BoxBlue2.tiff; path = macosx/Images/BoxBlue2.tiff; sourceTree = "<group>"; }; 257 3518E4D60AC6253F002ED3A2 /* English */ = {isa = PBXFileReference; lastKnownFileType = wrapper.nib; name = English; path = macosx/English.lproj/PiecesWindow.nib; sourceTree = "<group>"; };258 256 3518E5270AC62A55002ED3A2 /* BoxBlue3.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; name = BoxBlue3.tiff; path = macosx/Images/BoxBlue3.tiff; sourceTree = "<group>"; }; 259 257 3518E5280AC62A55002ED3A2 /* BoxWhite.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; name = BoxWhite.tiff; path = macosx/Images/BoxWhite.tiff; sourceTree = "<group>"; }; … … 453 451 isa = PBXGroup; 454 452 children = ( 455 3518E4A30AC620FC002ED3A2 /* Pieces WindowController.h */,456 3518E4A40AC620FC002ED3A2 /* Pieces WindowController.m */,453 3518E4A30AC620FC002ED3A2 /* PiecesView.h */, 454 3518E4A40AC620FC002ED3A2 /* PiecesView.m */, 457 455 A2A306530AAD24A80049E2AC /* UKFileWatcher.h */, 458 456 A2A306540AAD24A80049E2AC /* UKFileWatcher.m */, … … 600 598 A253F7290A699373008EE24F /* FilterButtonSelectedRight.png */, 601 599 A2912C520A2956E80097A0CA /* PrefsWindow.nib */, 602 3518E4D50AC6253F002ED3A2 /* PiecesWindow.nib */,603 600 ); 604 601 name = Resources; … … 733 730 4DAB87C90ABE1F730081CF7E /* natpmp.h in Headers */, 734 731 4DAB87CB0ABE1F730081CF7E /* http.h in Headers */, 735 3518E4A50AC620FC002ED3A2 /* Pieces WindowController.h in Headers */,732 3518E4A50AC620FC002ED3A2 /* PiecesView.h in Headers */, 736 733 ); 737 734 runOnlyForDeploymentPostprocessing = 0; … … 887 884 35B038130AC5B6EB00A10FDF /* ResumeNoWaitOn.png in Resources */, 888 885 35B038140AC5B6EC00A10FDF /* ResumeNoWaitOff.png in Resources */, 889 3518E4D70AC6253F002ED3A2 /* PiecesWindow.nib in Resources */,890 886 3518E5210AC62A29002ED3A2 /* PiecesBack.tiff in Resources */, 891 887 3518E5230AC62A2A002ED3A2 /* BoxBlue2.tiff in Resources */, … … 923 919 4DAB87CA0ABE1F730081CF7E /* natpmp.c in Sources */, 924 920 4DAB87CC0ABE1F730081CF7E /* http.c in Sources */, 925 3518E4A60AC620FC002ED3A2 /* Pieces WindowController.m in Sources */,921 3518E4A60AC620FC002ED3A2 /* PiecesView.m in Sources */, 926 922 ); 927 923 runOnlyForDeploymentPostprocessing = 0; … … 958 954 A2A306600AAD24A80049E2AC /* UKKQueue.m in Sources */, 959 955 A2A306620AAD24A80049E2AC /* UKMainThreadProxy.m in Sources */, 960 3518E4FB0AC62832002ED3A2 /* Pieces WindowController.m in Sources */,956 3518E4FB0AC62832002ED3A2 /* PiecesView.m in Sources */, 961 957 ); 962 958 runOnlyForDeploymentPostprocessing = 0; … … 992 988 ); 993 989 name = MainMenu.nib; 994 sourceTree = "<group>";995 };996 3518E4D50AC6253F002ED3A2 /* PiecesWindow.nib */ = {997 isa = PBXVariantGroup;998 children = (999 3518E4D60AC6253F002ED3A2 /* English */,1000 );1001 name = PiecesWindow.nib;1002 990 sourceTree = "<group>"; 1003 991 }; -
trunk/macosx/Controller.h
r920 r923 31 31 #import "InfoWindowController.h" 32 32 #import "MessageWindowController.h" 33 #import "PiecesWindowController.h"34 33 #import "Badger.h" 35 34 #import "ImageBackgroundView.h" … … 51 50 InfoWindowController * fInfoController; 52 51 MessageWindowController * fMessageController; 53 PiecesWindowController * fPiecesWindowController;54 52 55 53 IBOutlet NSWindow * fWindow; … … 142 140 143 141 - (void) showMessageWindow: (id) sender; 144 - (void) showPiecesView: (id) sender;145 142 146 143 - (void) updateControlTint: (NSNotification *) notification; -
trunk/macosx/Controller.m
r920 r923 87 87 fMessageController = [[MessageWindowController alloc] initWithWindowNibName: @"MessageWindow"]; 88 88 fInfoController = [[InfoWindowController alloc] initWithWindowNibName: @"InfoWindow"]; 89 fPiecesWindowController = [[PiecesWindowController alloc] initWithWindowNibName: @"PiecesWindow"];90 89 fPrefsController = [[PrefsController alloc] initWithWindowNibName: @"PrefsWindow" handle: fLib]; 91 90 … … 105 104 [fInfoController release]; 106 105 [fMessageController release]; 107 [fPiecesWindowController release];108 106 [fPrefsController release]; 109 107 … … 359 357 if ([fDefaults boolForKey: @"InfoVisible"]) 360 358 [self showInfo: nil]; 361 362 if ([fDefaults boolForKey: @"PiecesViewerVisible"])363 [self showPiecesView: nil];364 359 365 360 //timer to auto toggle speed limit … … 429 424 //remember window states and close all windows 430 425 [fDefaults setBool: [[fInfoController window] isVisible] forKey: @"InfoVisible"]; 431 [fDefaults setBool: [[fPiecesWindowController window] isVisible] forKey: @"PiecesViewerVisible"];432 426 [[NSApp windows] makeObjectsPerformSelector: @selector(close)]; 433 427 [self showStatusBar: NO animate: NO]; … … 937 931 } 938 932 939 - (void) showPiecesView: (id) sender940 {941 if ([[fPiecesWindowController window] isVisible])942 [fPiecesWindowController close];943 else944 {945 [fPiecesWindowController updateView: NO];946 [[fPiecesWindowController window] orderFront: nil];947 }948 }949 950 933 - (void) updateControlTint: (NSNotification *) notification 951 934 { … … 977 960 if ([[fInfoController window] isVisible]) 978 961 [fInfoController updateInfoStats]; 979 980 //update pieces viewer981 if ([[fPiecesWindowController window] isVisible])982 [fPiecesWindowController updateView: NO];983 962 984 963 //badge dock … … 1728 1707 - (void) tableViewSelectionDidChange: (NSNotification *) notification 1729 1708 { 1730 NSArray * torrents = [self torrentsAtIndexes: [fTableView selectedRowIndexes]]; 1731 [fInfoController updateInfoForTorrents: torrents]; 1732 1733 Torrent * torrent = [torrents count] == 1 ? [torrents objectAtIndex: 0] : nil; 1734 [fPiecesWindowController setTorrent: torrent]; 1709 [fInfoController updateInfoForTorrents: [self torrentsAtIndexes: [fTableView selectedRowIndexes]]]; 1735 1710 } 1736 1711 … … 2071 2046 { 2072 2047 NSString * title = [[fInfoController window] isVisible] ? @"Hide Inspector" : @"Show Inspector"; 2073 if (![[menuItem title] isEqualToString: title])2074 [menuItem setTitle: title];2075 2076 return YES;2077 }2078 2079 //enable show pieces window2080 if (action == @selector(showPiecesView:))2081 {2082 NSString * title = [[fPiecesWindowController window] isVisible] ? @"Hide Pieces Viewer" : @"Show Pieces Viewer";2083 2048 if (![[menuItem title] isEqualToString: title]) 2084 2049 [menuItem setTitle: title]; -
trunk/macosx/Defaults.plist
r920 r923 55 55 <key>NatTraversal</key> 56 56 <true/> 57 <key>PiecesViewerVisible</key>58 <false/>59 57 <key>PlayDownloadSound</key> 60 58 <true/> -
trunk/macosx/English.lproj/InfoWindow.nib/classes.nib
r921 r923 29 29 fPieceSizeField = NSTextField; 30 30 fPiecesField = NSTextField; 31 fPiecesView = PiecesView; 31 32 fRatioField = NSTextField; 32 33 fRatioLimitField = NSTextField; … … 44 45 SUPERCLASS = NSWindowController; 45 46 }, 46 {CLASS = NSSegmentedControl; LANGUAGE = ObjC; SUPERCLASS = NSControl; } 47 {CLASS = NSSegmentedControl; LANGUAGE = ObjC; SUPERCLASS = NSControl; }, 48 { 49 CLASS = PiecesView; 50 LANGUAGE = ObjC; 51 OUTLETS = {fImageView = NSImageView; }; 52 SUPERCLASS = NSObject; 53 } 47 54 ); 48 55 IBVersion = 1; -
trunk/macosx/English.lproj/MainMenu.nib/classes.nib
r920 r923 29 29 showMainWindow = id; 30 30 showMessageWindow = id; 31 showPiecesView = id;32 31 showPreferenceWindow = id; 33 32 stopAllTorrents = id; -
trunk/macosx/English.lproj/MainMenu.nib/info.nib
r920 r923 32 32 <key>IBOpenObjects</key> 33 33 <array> 34 <integer>21</integer> 34 35 <integer>29</integer> 35 <integer>21</integer>36 36 </array> 37 37 <key>IBSystem Version</key> -
trunk/macosx/InfoWindowController.h
r921 r923 25 25 #import <Cocoa/Cocoa.h> 26 26 #import "Torrent.h" 27 #import "PiecesView.h" 27 28 #import <transmission.h> 28 29 … … 53 54 IBOutlet NSMatrix * fRatioMatrix; 54 55 IBOutlet NSTextField * fRatioLimitField; 56 57 IBOutlet PiecesView * fPiecesView; 55 58 } 56 59 -
trunk/macosx/InfoWindowController.m
r922 r923 170 170 [fPeers removeAllObjects]; 171 171 [fPeerTable reloadData]; 172 173 [fPiecesView setTorrent: nil]; 172 174 } 173 175 else … … 206 208 [fTorrentLocationField setSelectable: YES]; 207 209 [fDataLocationField setSelectable: YES]; 210 211 [fPiecesView setTorrent: torrent]; 208 212 } 209 213 … … 280 284 if ([[[fTabView selectedTabViewItem] identifier] isEqualToString: TAB_PEERS_IDENT]) 281 285 [self reloadPeerTable]; 286 287 //update pieces view if visible 288 if ([[[fTabView selectedTabViewItem] identifier] isEqualToString: TAB_ACTIVITY_IDENT]) 289 [fPiecesView updateView: NO]; 282 290 } 283 291 } … … 385 393 float height; 386 394 if ([identifier isEqualToString: TAB_ACTIVITY_IDENT]) 395 { 387 396 height = TAB_ACTIVITY_HEIGHT; 397 398 [fPiecesView updateView: NO]; 399 } 388 400 else if ([identifier isEqualToString: TAB_PEERS_IDENT]) 389 401 {
Note: See TracChangeset
for help on using the changeset viewer.