(trunk qt) #2077: doesn't show/modify the "Stop seeding torrents at ratio"

This commit is contained in:
Charles Kerr 2009-05-14 18:28:11 +00:00
parent cf389fd684
commit 5d4f4fdd51
4 changed files with 9 additions and 10 deletions

View File

@ -105,8 +105,6 @@ Prefs::PrefItem Prefs::myItems[] =
{ RPC_USERNAME, TR_PREFS_KEY_RPC_USERNAME, QVariant::String },
{ RPC_WHITELIST_ENABLED, TR_PREFS_KEY_RPC_WHITELIST_ENABLED, QVariant::Bool },
{ RPC_WHITELIST, TR_PREFS_KEY_RPC_WHITELIST, QVariant::String },
{ SEED_RATIO_LIMIT, TR_PREFS_KEY_RATIO, QVariant::Double },
{ SEED_RATIO_LIMITED, TR_PREFS_KEY_RATIO_ENABLED, QVariant::Bool },
{ USPEED_ENABLED, TR_PREFS_KEY_USPEED_ENABLED, QVariant::Bool },
{ USPEED, TR_PREFS_KEY_USPEED, QVariant::Int },
{ UPLOAD_SLOTS_PER_TORRENT, TR_PREFS_KEY_UPLOAD_SLOTS_PER_TORRENT, QVariant::Int }

View File

@ -109,8 +109,6 @@ class Prefs: public QObject
RPC_USERNAME,
RPC_WHITELIST_ENABLED,
RPC_WHITELIST,
SEED_RATIO_LIMIT,
SEED_RATIO_LIMITED,
USPEED_ENABLED,
USPEED,
UPLOAD_SLOTS_PER_TORRENT,

View File

@ -121,8 +121,6 @@ Session :: updatePref( int key )
case Prefs :: DOWNLOAD_DIR:
case Prefs :: PEER_LIMIT_GLOBAL:
case Prefs :: PEER_LIMIT_TORRENT:
case Prefs :: SEED_RATIO_LIMIT:
case Prefs :: SEED_RATIO_LIMITED:
case Prefs :: USPEED_ENABLED:
case Prefs :: USPEED:
case Prefs :: DSPEED_ENABLED:
@ -131,11 +129,16 @@ Session :: updatePref( int key )
case Prefs :: PORT_FORWARDING:
case Prefs :: PEER_PORT:
case Prefs :: PEER_PORT_RANDOM_ON_START:
case Prefs :: RATIO:
case Prefs :: RATIO_ENABLED:
sessionSet( myPrefs.keyStr(key), myPrefs.variant(key) );
break;
case Prefs :: RATIO:
sessionSet( "seedRatioLimit", myPrefs.variant(key) );
break;
case Prefs :: RATIO_ENABLED:
sessionSet( "seedRatioLimited", myPrefs.variant(key) );
break;
case Prefs :: RPC_AUTH_REQUIRED:
if( mySession )
tr_sessionSetRPCEnabled( mySession, myPrefs.getBool(key) );

View File

@ -340,8 +340,8 @@ Torrent :: getSeedRatio( double& ratio ) const
break;
case TR_RATIOLIMIT_GLOBAL:
if(( isLimited = myPrefs.getBool( Prefs :: SEED_RATIO_LIMITED )))
ratio = myPrefs.getDouble( Prefs :: SEED_RATIO_LIMIT );
if(( isLimited = myPrefs.getBool( Prefs :: RATIO_ENABLED )))
ratio = myPrefs.getDouble( Prefs :: RATIO );
break;
case TR_RATIOLIMIT_UNLIMITED: