Changeset 5296


Ignore:
Timestamp:
Mar 18, 2008, 9:59:17 PM (14 years ago)
Author:
livings124
Message:

fold similar strings together for easier translation

Location:
trunk
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/NEWS

    r5274 r5296  
    1515   + Optional display of remaining time while seeding in Minimal View
    1616   + Improved accuracy for displaying the remaining disk space warning
    17 - Gtk+:
     17- GTK+:
    1818   + New "watch directory" for auto-adding torrents
    1919   + New system tray popup to notify when a torrent is completed
  • trunk/macosx/Controller.m

    r5260 r5296  
    14221422                        tr_getSessionStats(fLib, &stats);
    14231423                   
    1424                     statusString = [NSLocalizedString(@"Ratio: ", "status bar -> status label")
    1425                                     stringByAppendingString: [NSString stringForRatio: stats.ratio]];
     1424                    statusString = [NSString stringWithFormat: @"%@: %@", NSLocalizedString(@"Ratio", "status bar -> status label"),
     1425                                    [NSString stringForRatio: stats.ratio]];
    14261426                }
    14271427                else //STATUS_TRANSFER_TOTAL or STATUS_TRANSFER_SESSION
     
    14351435                        tr_getSessionStats(fLib, &stats);
    14361436                   
    1437                     statusString = [NSString stringWithFormat: NSLocalizedString(@"DL: %@  UL: %@",
    1438                         "status bar -> status label (2 spaces between)"),
    1439                         [NSString stringForFileSize: stats.downloadedBytes], [NSString stringForFileSize: stats.uploadedBytes]];
     1437                    statusString = [NSString stringWithFormat: @"%@: %@  %@: %@",
     1438                            NSLocalizedString(@"DL", "status bar -> status label"), [NSString stringForFileSize: stats.downloadedBytes],
     1439                            NSLocalizedString(@"UL", "status bar -> status label"), [NSString stringForFileSize: stats.uploadedBytes]];
    14401440                }
    14411441               
  • trunk/macosx/English.lproj/Localizable.strings

    r5261 r5296  
    22" - %@ remaining" = " - %@ remaining";
    33
    4 /* Torrent -> status string */
    5 " - DL: %@, UL: %@" = " - DL: %1$@, UL: %2$@";
    6 
    74/* Torrent -> progress string */
    85" - remaining time unknown" = " - remaining time unknown";
    9 
    10 /* Torrent -> status string */
    11 " - UL: %@" = " - UL: %@";
    126
    137/* Removal confirm panel -> message part 2 */
     
    295289"Debug" = "Debug";
    296290
    297 /* status bar -> status label (2 spaces between) */
    298 "DL: %@  UL: %@" = "DL: %1$@  UL: %2$@";
    299 
    300 /* Torrent -> status string */
    301 "DL: %@, UL: %@" = "DL: %1$@, UL: %2$@";
     291/* Torrent -> status string
     292   status bar -> status label */
     293"DL" = "DL";
    302294
    303295/* Open duplicate alert -> button
     
    325317
    326318/* Stats window -> label */
    327 "Downloaded:" = "Downloaded:";
     319"Downloaded" = "Downloaded";
    328320
    329321/* Torrent -> status string */
     
    502494"Open Torrent Address" = "Open Torrent Address";
    503495
     496/* Open toolbar item -> palette label */
     497"Open Torrent Files" = "Open Torrent Files";
     498
    504499/* Open toolbar item -> tooltip */
    505500"Open torrent files" = "Open torrent files";
    506 
    507 /* Open toolbar item -> palette label */
    508 "Open Torrent Files" = "Open Torrent Files";
    509501
    510502/* Open address toolbar item -> tooltip */
     
    579571
    580572/* Stats window -> label */
    581 "Program Started:" = "Program Started:";
     573"Program Started" = "Program Started";
    582574
    583575/* Inspector -> Peers tab -> table row tooltip */
     
    598590"Quitting" = "Quitting";
    599591
    600 /* Torrent table -> group row -> tooltip */
     592/* Stats window -> label
     593   status bar -> status label
     594   Torrent table -> group row -> tooltip
     595   Torrent -> status string */
    601596"Ratio" = "Ratio";
    602 
    603 /* Stats window -> label */
    604 "Ratio:" = "Ratio:";
    605 
    606 /* status bar -> status label */
    607 "Ratio: " = "Ratio: ";
    608 
    609 /* Torrent -> status string */
    610 "Ratio: %@, UL: %@" = "Ratio: %1$@, UL: %2$@";
    611597
    612598/* Groups -> Name */
     
    648634
    649635/* Stats window -> label */
    650 "Running Time:" = "Running Time:";
     636"Running Time" = "Running Time";
    651637
    652638/* Message window -> save button */
     
    656642"Seeding" = "Seeding";
    657643
    658 /* Torrent -> status string */
    659 "Seeding complete" = "Seeding complete";
    660 
    661644/* Growl notification title */
    662645"Seeding Complete" = "Seeding Complete";
     646
     647/* Torrent -> status string */
     648"Seeding complete" = "Seeding complete";
    663649
    664650/* Torrent -> status string */
     
    847833"Transmission Support Folder" = "Transmission Support Folder";
    848834
     835/* Torrent -> status string
     836   status bar -> status label */
     837"UL" = "UL";
     838
    849839/* Preferences -> Advanced -> port status */
    850840"Unable to check port status" = "Unable to check port status";
     
    863853
    864854/* Stats window -> label */
    865 "Uploaded:" = "Uploaded:";
     855"Uploaded" = "Uploaded";
    866856
    867857/* inspector -> peer table -> header tool tip */
  • trunk/macosx/StatsWindowController.m

    r5259 r5296  
    6161   
    6262    //set label text
    63     [fUploadedLabelField setStringValue: NSLocalizedString(@"Uploaded:", "Stats window -> label")];
    64     [fDownloadedLabelField setStringValue: NSLocalizedString(@"Downloaded:", "Stats window -> label")];
    65     [fRatioLabelField setStringValue: NSLocalizedString(@"Ratio:", "Stats window -> label")];
    66     [fTimeLabelField setStringValue: NSLocalizedString(@"Running Time:", "Stats window -> label")];
    67     [fNumOpenedLabelField setStringValue: NSLocalizedString(@"Program Started:", "Stats window -> label")];
     63    [fUploadedLabelField setStringValue: [NSLocalizedString(@"Uploaded", "Stats window -> label") stringByAppendingString: @":"]];
     64    [fDownloadedLabelField setStringValue: [NSLocalizedString(@"Downloaded", "Stats window -> label") stringByAppendingString: @":"]];
     65    [fRatioLabelField setStringValue: [NSLocalizedString(@"Ratio", "Stats window -> label") stringByAppendingString: @":"]];
     66    [fTimeLabelField setStringValue: [NSLocalizedString(@"Running Time", "Stats window -> label") stringByAppendingString: @":"]];
     67    [fNumOpenedLabelField setStringValue: [NSLocalizedString(@"Program Started", "Stats window -> label")
     68                                            stringByAppendingString: @":"]];
    6869   
    6970    //size all elements
  • trunk/macosx/Torrent.m

    r5282 r5296  
    929929    tr_peer_stat * peers = tr_torrentPeers(fHandle, &totalPeers);
    930930   
    931     NSMutableArray * peerDics = [NSMutableArray arrayWithCapacity: totalPeers];
    932     NSMutableDictionary * dic;
    933    
    934     tr_peer_stat * peer;
     931    NSMutableArray * peerDicts = [NSMutableArray arrayWithCapacity: totalPeers];
     932   
    935933    for (i = 0; i < totalPeers; i++)
    936934    {
    937         peer = &peers[i];
    938        
    939         dic = [NSMutableDictionary dictionaryWithObjectsAndKeys:
    940             [NSNumber numberWithInt: peer->from], @"From",
    941             [NSString stringWithUTF8String: peer->addr], @"IP",
    942             [NSNumber numberWithInt: peer->port], @"Port",
    943             [NSNumber numberWithFloat: peer->progress], @"Progress",
    944             [NSNumber numberWithBool: peer->isEncrypted], @"Encryption",
    945             [NSString stringWithUTF8String: peer->client], @"Client",
    946             [NSString stringWithUTF8String: peer->flagStr], @"Flags", nil];
     935        tr_peer_stat * peer = &peers[i];
     936        NSMutableDictionary * dict = [NSMutableDictionary dictionaryWithCapacity: 9];
     937       
     938        [dict setObject: [NSNumber numberWithInt: peer->from] forKey: @"From"];
     939        [dict setObject: [NSString stringWithUTF8String: peer->addr] forKey: @"IP"];
     940        [dict setObject: [NSNumber numberWithInt: peer->port] forKey: @"Port"];
     941        [dict setObject: [NSNumber numberWithFloat: peer->progress] forKey: @"Progress"];
     942        [dict setObject: [NSNumber numberWithBool: peer->isEncrypted] forKey: @"Encryption"];
     943        [dict setObject: [NSString stringWithUTF8String: peer->client] forKey: @"Client"];
     944        [dict setObject: [NSString stringWithUTF8String: peer->flagStr] forKey: @"Flags"];
    947945       
    948946        if (peer->isUploadingTo)
    949             [dic setObject: [NSNumber numberWithFloat: peer->uploadToRate] forKey: @"UL To Rate"];
     947            [dict setObject: [NSNumber numberWithFloat: peer->uploadToRate] forKey: @"UL To Rate"];
    950948        if (peer->isDownloadingFrom)
    951             [dic setObject: [NSNumber numberWithFloat: peer->downloadFromRate] forKey: @"DL From Rate"];
    952        
    953         [peerDics addObject: dic];
     949            [dict setObject: [NSNumber numberWithFloat: peer->downloadFromRate] forKey: @"DL From Rate"];
     950       
     951        [peerDicts addObject: dict];
    954952    }
    955953   
    956954    tr_torrentPeersFree(peers, totalPeers);
    957955   
    958     return peerDics;
     956    return peerDicts;
    959957}
    960958
     
    10741072    {
    10751073        if (fStat->status == TR_STATUS_DOWNLOAD)
    1076             string = [string stringByAppendingFormat: NSLocalizedString(@" - DL: %@, UL: %@", "Torrent -> status string"),
    1077                     [NSString stringForSpeed: [self downloadRate]], [NSString stringForSpeed: [self uploadRate]]];
     1074            string = [string stringByAppendingFormat: @" - %@: %@, %@: %@",
     1075                        NSLocalizedString(@"DL", "Torrent -> status string"), [NSString stringForSpeed: [self downloadRate]],
     1076                        NSLocalizedString(@"UL", "Torrent -> status string"), [NSString stringForSpeed: [self uploadRate]]];
    10781077        else
    1079             string = [string stringByAppendingFormat: NSLocalizedString(@" - UL: %@", "Torrent -> status string"),
    1080                         [NSString stringForSpeed: [self uploadRate]]];
     1078            string = [string stringByAppendingFormat: @" - %@: %@",
     1079                        NSLocalizedString(@"UL", "Torrent -> status string"), [NSString stringForSpeed: [self uploadRate]]];
    10811080    }
    10821081   
     
    11131112       
    11141113        case TR_STATUS_DOWNLOAD:
    1115             string = [NSString stringWithFormat: NSLocalizedString(@"DL: %@, UL: %@", "Torrent -> status string"),
    1116                             [NSString stringForSpeed: [self downloadRate]], [NSString stringForSpeed: [self uploadRate]]];
     1114            string = [NSString stringWithFormat: @"%@: %@, %@: %@",
     1115                            NSLocalizedString(@"DL", "Torrent -> status string"), [NSString stringForSpeed: [self downloadRate]],
     1116                            NSLocalizedString(@"UL", "Torrent -> status string"), [NSString stringForSpeed: [self uploadRate]]];
    11171117            break;
    11181118       
    11191119        case TR_STATUS_SEED:
    11201120        case TR_STATUS_DONE:
    1121             string = [NSString stringWithFormat: NSLocalizedString(@"Ratio: %@, UL: %@", "Torrent -> status string"),
    1122                             [NSString stringForRatio: [self ratio]], [NSString stringForSpeed: [self uploadRate]]];
     1121            string = [NSString stringWithFormat: @"%@: %@, %@: %@",
     1122                            NSLocalizedString(@"Ratio", "Torrent -> status string"), [NSString stringForRatio: [self ratio]],
     1123                            NSLocalizedString(@"UL", "Torrent -> status string"), [NSString stringForSpeed: [self uploadRate]]];
    11231124            break;
    11241125       
Note: See TracChangeset for help on using the changeset viewer.