Changeset 8196


Ignore:
Timestamp:
Apr 10, 2009, 4:33:31 AM (13 years ago)
Author:
charles
Message:

(qt) fix minor bug reported by RolCol?: the "ask for more peers" button was enabled for paused torrents if they were being verified

Location:
trunk/qt
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/qt/session.cc

    r8192 r8196  
    8787        default: assert( "unknown type" );
    8888    }
    89 std::cerr << "request: " << tr_bencToJSON(&top) << std::endl;
    9089    exec( &top );
    9190    tr_bencFree( &top );
     
    10099    tr_bencDictAddInt( &top, "tag", TAG_PORT_TEST );
    101100    exec( &top );
    102 std::cerr << "request: " << tr_bencToJSON(&top) << std::endl;
    103101    tr_bencFree( &top );
    104102}
     
    155153            break;
    156154        case Prefs :: RPC_WHITELIST_ENABLED:
    157 std::cerr << "setting whitelist enabled" << std::endl;
    158155            if( mySession )
    159156                tr_sessionSetRPCWhitelistEnabled( mySession, myPrefs.getBool(key) );
    160157            break;
    161158        case Prefs :: RPC_WHITELIST:
    162 std::cerr << "setting whitelist" << std::endl;
    163159            if( mySession )
    164160                tr_sessionSetRPCWhitelist( mySession, myPrefs.getString(key).toUtf8().constData() );
     
    561557
    562558                case TAG_PORT_TEST: {
    563 std::cerr << "response: " << json << std::endl;
    564559                    tr_bool isOpen = 0;
    565560                    if( tr_bencDictFindDict( &top, "arguments", &args ) )
  • trunk/qt/torrent.h

    r8192 r8196  
    242242        QDateTime nextAnnounceTime( ) const { return getDateTime( NEXT_ANNOUNCE_TIME ); }
    243243        QDateTime nextScrapeTime( ) const { return getDateTime( NEXT_SCRAPE_TIME ); }
    244         bool canManualAnnounce( ) const { return !isPaused() && (manualAnnounceTime()<=QDateTime::currentDateTime()); }
     244        bool canManualAnnounce( ) const { return isReadyToTransfer() && (manualAnnounceTime()<=QDateTime::currentDateTime()); }
    245245        int peersWeAreDownloadingFrom( ) const { return getInt( PEERS_SENDING_TO_US ) + getInt( WEBSEEDS_SENDING_TO_US ); }
    246246        int peersWeAreUploadingTo( ) const { return getInt( PEERS_GETTING_FROM_US ); }
Note: See TracChangeset for help on using the changeset viewer.