mirror of
https://github.com/transmission/transmission
synced 2024-12-26 09:37:56 +00:00
have the File Outline Controller reload the file data when reloading the table
This commit is contained in:
parent
34396e7820
commit
f0f958d755
3 changed files with 5 additions and 15 deletions
|
@ -33,8 +33,6 @@
|
|||
|
||||
@interface AddWindowController (Private)
|
||||
|
||||
- (void) updateTorrent;
|
||||
|
||||
- (void) folderChoiceClosed: (NSOpenPanel *) openPanel returnCode: (int) code contextInfo: (void *) contextInfo;
|
||||
|
||||
- (void) setGroupsMenu;
|
||||
|
@ -118,8 +116,8 @@
|
|||
[fLocationImageView setImage: nil];
|
||||
}
|
||||
|
||||
fTimer = [NSTimer scheduledTimerWithTimeInterval: UPDATE_SECONDS target: self
|
||||
selector: @selector(updateTorrent) userInfo: nil repeats: YES];
|
||||
fTimer = [NSTimer scheduledTimerWithTimeInterval: UPDATE_SECONDS target: fFileController
|
||||
selector: @selector(reloadData) userInfo: nil repeats: YES];
|
||||
}
|
||||
|
||||
- (void) windowDidLoad
|
||||
|
@ -130,7 +128,7 @@
|
|||
}
|
||||
|
||||
- (void) dealloc
|
||||
{NSLog(@"dealloc");
|
||||
{
|
||||
[[NSNotificationCenter defaultCenter] removeObserver: self];
|
||||
|
||||
[fTimer invalidate];
|
||||
|
@ -188,7 +186,7 @@
|
|||
- (void) verifyLocalData: (id) sender
|
||||
{
|
||||
[fTorrent resetCache];
|
||||
[self updateTorrent];
|
||||
[fFileController reloadData];
|
||||
}
|
||||
|
||||
- (void) updateGroupMenu: (NSNotification *) notification
|
||||
|
@ -216,12 +214,6 @@
|
|||
|
||||
@implementation AddWindowController (Private)
|
||||
|
||||
- (void) updateTorrent
|
||||
{
|
||||
[fTorrent updateFileStat];
|
||||
[fFileController reloadData];
|
||||
}
|
||||
|
||||
- (void) folderChoiceClosed: (NSOpenPanel *) openPanel returnCode: (int) code contextInfo: (void *) contextInfo
|
||||
{
|
||||
if (code == NSOKButton)
|
||||
|
|
|
@ -79,6 +79,7 @@ typedef enum
|
|||
|
||||
- (void) reloadData
|
||||
{
|
||||
[fTorrent updateFileStat];
|
||||
[fOutline reloadData];
|
||||
}
|
||||
|
||||
|
|
|
@ -1085,10 +1085,7 @@ typedef enum
|
|||
- (void) updateInfoFiles
|
||||
{
|
||||
if ([fTorrents count] == 1)
|
||||
{
|
||||
[[fTorrents objectAtIndex: 0] updateFileStat];
|
||||
[fFileController reloadData];
|
||||
}
|
||||
}
|
||||
|
||||
- (NSView *) tabViewForTag: (int) tag
|
||||
|
|
Loading…
Reference in a new issue