Changeset 1223


Ignore:
Timestamp:
Dec 15, 2006, 3:50:34 AM (15 years ago)
Author:
livings124
Message:

identify (and display in mac version's inspector) if private torrent

Location:
branches/multitracker
Files:
9 edited

Legend:

Unmodified
Added
Removed
  • branches/multitracker/libtransmission/metainfo.c

    r1208 r1223  
    170170        inf->dateCreated = 0;
    171171    }
    172 
     172   
     173    /* Private torrent */
     174    if( ( val = tr_bencDictFind( beInfo, "private" ) ) && TYPE_INT == val->type )
     175    {
     176        inf->privateTorrent = val->val.i;
     177    }
     178   
    173179    /* Piece length */
    174180    if( !( val = tr_bencDictFind( beInfo, "piece length" ) ) )
  • branches/multitracker/libtransmission/tracker.c

    r1213 r1223  
    186186static void failureAnnouncing( tr_tracker_t * tc )
    187187{
    188     tr_torrent_t * tor = tc->tor;
    189     tr_info_t    * inf = &tor->info;
     188    tr_info_t * inf = &tc->tor->info;
    190189   
    191190    tc->shouldChangeAnnounce = tc->announceTier + 1 < inf->trackerTiers
  • branches/multitracker/libtransmission/transmission.h

    r1208 r1223  
    329329    char                 creator[MAX_PATH_LENGTH];
    330330    int                  dateCreated;
     331    int                  privateTorrent;
    331332
    332333    /* Pieces info */
  • branches/multitracker/macosx/English.lproj/InfoWindow.nib/classes.nib

    r1186 r1223  
    4444                fRevealDataButton = NSButton;
    4545                fRevealTorrentButton = NSButton;
     46                fSecureField = NSTextField;
    4647                fSeedersField = NSTextField;
    4748                fSizeField = NSTextField;
  • branches/multitracker/macosx/InfoWindowController.h

    r1186 r1223  
    3838    IBOutlet NSImageView * fImageView;
    3939    IBOutlet NSTextField * fNameField, * fSizeField, * fTrackerField,
    40                         * fPiecesField, * fHashField,
     40                        * fPiecesField, * fHashField, * fSecureField,
    4141                        * fTorrentLocationField, * fDataLocationField,
    4242                        * fDateStartedField,
  • branches/multitracker/macosx/InfoWindowController.m

    r1186 r1223  
    4040
    4141//15 spacing at the bottom of each tab
    42 #define TAB_INFO_HEIGHT 268.0
     42#define TAB_INFO_HEIGHT 284.0
    4343#define TAB_ACTIVITY_HEIGHT 170.0
    4444#define TAB_PEERS_HEIGHT 268.0
     
    156156        [fHashField setStringValue: @""];
    157157        [fHashField setToolTip: nil];
     158        [fSecureField setStringValue: @""];
    158159        [fCommentView setString: @""];
    159160       
     
    213214        [fHashField setStringValue: hashString];
    214215        [fHashField setToolTip: hashString];
     216        [fSecureField setStringValue: [torrent privateTorrent]
     217                        ? NSLocalizedString(@"Private Torrent", "Inspector -> is private torrent")
     218                        : NSLocalizedString(@"Public Torrent", "Inspector -> is not private torrent")];
    215219        [fCommentView setString: commentString];
    216220       
  • branches/multitracker/macosx/Torrent.h

    r1186 r1223  
    116116- (int)        pieceCount;
    117117- (NSString *) hashString;
     118- (BOOL)       privateTorrent;
    118119
    119120- (NSString *) torrentLocation;
  • branches/multitracker/macosx/Torrent.m

    r1186 r1223  
    744744}
    745745
     746- (BOOL) privateTorrent
     747{
     748    return fInfo->privateTorrent;
     749}
     750
    746751- (NSString *) torrentLocation
    747752{
Note: See TracChangeset for help on using the changeset viewer.