mirror of
https://github.com/transmission/transmission
synced 2024-12-26 09:37:56 +00:00
eliminate the second port status dot/text field to avoid confusion
This commit is contained in:
parent
4854aac298
commit
5373a9d82d
7 changed files with 5 additions and 30 deletions
2
macosx/English.lproj/MainMenu.nib/info.nib
generated
2
macosx/English.lproj/MainMenu.nib/info.nib
generated
|
@ -10,7 +10,7 @@
|
|||
<integer>5</integer>
|
||||
<key>IBOpenObjects</key>
|
||||
<array>
|
||||
<integer>1603</integer>
|
||||
<integer>302</integer>
|
||||
</array>
|
||||
<key>IBSystem Version</key>
|
||||
<string>9A581</string>
|
||||
|
|
BIN
macosx/English.lproj/MainMenu.nib/keyedobjects.nib
generated
BIN
macosx/English.lproj/MainMenu.nib/keyedobjects.nib
generated
Binary file not shown.
1
macosx/English.lproj/PrefsWindow.nib/info.nib
generated
1
macosx/English.lproj/PrefsWindow.nib/info.nib
generated
|
@ -10,7 +10,6 @@
|
|||
<integer>5</integer>
|
||||
<key>IBOpenObjects</key>
|
||||
<array>
|
||||
<integer>28</integer>
|
||||
<integer>66</integer>
|
||||
</array>
|
||||
<key>IBSystem Version</key>
|
||||
|
|
BIN
macosx/English.lproj/PrefsWindow.nib/keyedobjects.nib
generated
BIN
macosx/English.lproj/PrefsWindow.nib/keyedobjects.nib
generated
Binary file not shown.
|
@ -45,9 +45,9 @@
|
|||
IBOutlet NSTextField * fUploadField, * fDownloadField,
|
||||
* fSpeedLimitUploadField, * fSpeedLimitDownloadField;
|
||||
|
||||
IBOutlet NSTextField * fPortField, * fNatStatusField, * fPortStatusField;
|
||||
IBOutlet NSTextField * fPortField, * fPortStatusField;
|
||||
IBOutlet NSButton * fNatCheck;
|
||||
IBOutlet NSImageView * fNatStatusImage, * fPortStatusImage;
|
||||
IBOutlet NSImageView * fPortStatusImage;
|
||||
IBOutlet NSProgressIndicator * fPortStatusProgress;
|
||||
NSTimer * fNatStatusTimer;
|
||||
int fPublicPort, fNatStatus;
|
||||
|
|
|
@ -242,33 +242,9 @@
|
|||
{
|
||||
tr_handle_status * stat = tr_handleStatus(fHandle);
|
||||
|
||||
BOOL change = fNatStatus != stat->natTraversalStatus;
|
||||
if (change)
|
||||
if (fNatStatus != stat->natTraversalStatus || fPublicPort != stat->publicPort)
|
||||
{
|
||||
fNatStatus = stat->natTraversalStatus;
|
||||
switch (fNatStatus)
|
||||
{
|
||||
case TR_NAT_TRAVERSAL_MAPPED:
|
||||
[fNatStatusField setStringValue: NSLocalizedString(@"Port successfully mapped",
|
||||
"Preferences -> Advanced -> port map status")];
|
||||
[fNatStatusImage setImage: [NSImage imageNamed: @"GreenDot.png"]];
|
||||
break;
|
||||
|
||||
case TR_NAT_TRAVERSAL_NOTFOUND:
|
||||
case TR_NAT_TRAVERSAL_ERROR:
|
||||
[fNatStatusField setStringValue: NSLocalizedString(@"Error mapping port",
|
||||
"Preferences -> Advanced -> port map status")];
|
||||
[fNatStatusImage setImage: [NSImage imageNamed: @"RedDot.png"]];
|
||||
break;
|
||||
|
||||
default:
|
||||
[fNatStatusField setStringValue: @""];
|
||||
[fNatStatusImage setImage: nil];
|
||||
}
|
||||
}
|
||||
|
||||
if (change || fPublicPort != stat->publicPort)
|
||||
{
|
||||
fPublicPort = stat->publicPort;
|
||||
|
||||
[fPortStatusField setStringValue: [NSLocalizedString(@"Checking port status",
|
||||
|
|
|
@ -280,7 +280,7 @@
|
|||
if ([fDefaults boolForKey: @"PiecesBar"])
|
||||
{
|
||||
NSRect regularBarRect = barRect, piecesBarRect = barRect;
|
||||
regularBarRect.size.height /= 3;
|
||||
regularBarRect.size.height /= 2.5;
|
||||
piecesBarRect.origin.y += regularBarRect.size.height;
|
||||
piecesBarRect.size.height -= regularBarRect.size.height;
|
||||
|
||||
|
|
Loading…
Reference in a new issue