Merge pull request #11 from JanX2/macosx-misc-1

OS X misc improvements 1
This commit is contained in:
Mike Gelfand 2017-01-07 23:23:07 +03:00 committed by GitHub
commit 505b4f8c4f
2 changed files with 8 additions and 3 deletions

View File

@ -1512,6 +1512,7 @@
);
name = Transmission;
sourceTree = "<group>";
usesTabs = 0;
};
29B97317FDCFA39411CA2CEA /* Resources */ = {
isa = PBXGroup;

View File

@ -843,7 +843,8 @@
[fDefaults setBool: YES forKey: @"DownloadLocationConstant"];
[self updateShowAddMagnetWindowField];
tr_sessionSetDownloadDir(fHandle, [folder UTF8String]);
assert(folder.length > 0);
tr_sessionSetDownloadDir(fHandle, [folder fileSystemRepresentation]);
}
else
{
@ -869,7 +870,8 @@
NSString * folder = [[[panel URLs] objectAtIndex: 0] path];
[fDefaults setObject: folder forKey: @"IncompleteDownloadFolder"];
tr_sessionSetIncompleteDir(fHandle, [folder UTF8String]);
assert(folder.length > 0);
tr_sessionSetIncompleteDir(fHandle, [folder fileSystemRepresentation]);
}
[fIncompleteFolderPopUp selectItemAtIndex: 0];
}];
@ -890,8 +892,10 @@
{
NSString * filePath = [[[panel URLs] objectAtIndex: 0] path];
assert(filePath.length > 0);
[fDefaults setObject: filePath forKey: @"DoneScriptPath"];
tr_sessionSetTorrentDoneScript(fHandle, [filePath UTF8String]);
tr_sessionSetTorrentDoneScript(fHandle, [filePath fileSystemRepresentation]);
[fDefaults setBool: YES forKey: @"DoneScriptEnabled"];
tr_sessionSetTorrentDoneScriptEnabled(fHandle, YES);