Changeset 9338


Ignore:
Timestamp:
Oct 20, 2009, 2:01:15 PM (13 years ago)
Author:
charles
Message:

(trunk gtk,qt) synchronize the gtk, qt preferences dialogs a bit

Location:
trunk
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/gtk/add-dialog.c

    r8671 r9338  
    296296    data->downloadDir = g_strdup( str );
    297297    data->list = file_list_new( core, 0 );
    298     data->trash_check =
    299         gtk_check_button_new_with_mnemonic( _( "_Move source file to Trash" ) );
    300     data->run_check =
    301         gtk_check_button_new_with_mnemonic( _( "_Start when added" ) );
     298    str = _( "Mo_ve .torrent file to the trash" );
     299    data->trash_check = gtk_check_button_new_with_mnemonic( str );
     300    str = _( "_Start when added" );
     301    data->run_check = gtk_check_button_new_with_mnemonic( str );
    302302
    303303    g_signal_connect( G_OBJECT( d ), "response",
     
    458458        gtk_file_chooser_set_current_folder( GTK_FILE_CHOOSER( w ), folder );
    459459
    460     c = gtk_check_button_new_with_mnemonic( _( "Display _options dialog" ) );
     460    c = gtk_check_button_new_with_mnemonic( _( "Show _options dialog" ) );
    461461    gtk_toggle_button_set_active( GTK_TOGGLE_BUTTON( c ),
    462462                                 pref_flag_get( PREF_KEY_OPTIONS_PROMPT ) );
  • trunk/gtk/main.c

    r9328 r9338  
    553553            _( "Transmission is a file sharing program.  When you run a torrent, its data will be made available to others by means of upload.  And of course, any content you share is your sole responsibility.\n\nYou probably knew this, so we won't tell you again." ) );
    554554        gtk_dialog_add_button( GTK_DIALOG( w ), GTK_STOCK_QUIT, GTK_RESPONSE_REJECT );
    555         gtk_dialog_add_button( GTK_DIALOG( w ), _( "I Accept" ), GTK_RESPONSE_ACCEPT );
     555        gtk_dialog_add_button( GTK_DIALOG( w ), _( "I _Accept" ), GTK_RESPONSE_ACCEPT );
    556556        gtk_dialog_set_default_response( GTK_DIALOG( w ), GTK_RESPONSE_ACCEPT );
    557557        switch( gtk_dialog_run( GTK_DIALOG( w ) ) ) {
  • trunk/gtk/tr-prefs.c

    r9328 r9338  
    291291#endif
    292292
    293     s = _( "Keep incomplete files in:" );
     293    s = _( "Show _options dialog" );
     294    w = new_check_button( s, PREF_KEY_OPTIONS_PROMPT, core );
     295    hig_workarea_add_wide_control( t, &row, w );
     296
     297    s = _( "_Start when added" );
     298    w = new_check_button( s, PREF_KEY_START, core );
     299    hig_workarea_add_wide_control( t, &row, w );
     300
     301    s = _( "Mo_ve .torrent file to the trash" );
     302    w = new_check_button( s, PREF_KEY_TRASH_ORIGINAL, core );
     303    hig_workarea_add_wide_control( t, &row, w );
     304
     305    s = _( "Keep _incomplete files in:" );
    294306    l = new_check_button( s, TR_PREFS_KEY_INCOMPLETE_DIR_ENABLED, core );
    295307    w = new_path_chooser_button( TR_PREFS_KEY_INCOMPLETE_DIR, core );
     
    297309    g_signal_connect( l, "toggled", G_CALLBACK( target_cb ), w );
    298310    hig_workarea_add_row_w( t, &row, l, w, NULL );
    299 
    300     s = _( "Display _options dialog" );
    301     w = new_check_button( s, PREF_KEY_OPTIONS_PROMPT, core );
    302     hig_workarea_add_wide_control( t, &row, w );
    303 
    304     s = _( "_Start when added" );
    305     w = new_check_button( s, PREF_KEY_START, core );
    306     hig_workarea_add_wide_control( t, &row, w );
    307 
    308     s = _( "Mo_ve source files to Trash" );
    309     w = new_check_button( s, PREF_KEY_TRASH_ORIGINAL, core );
    310     hig_workarea_add_wide_control( t, &row, w );
    311311
    312312    w = new_path_chooser_button( TR_PREFS_KEY_DOWNLOAD_DIR, core );
     
    346346    hig_workarea_add_wide_control( t, &row, w );
    347347
    348     s = _( "Show Transmission in the notification _area" );
     348    s = _( "Show Transmission in the _notification area" );
    349349    w = new_check_button( s, PREF_KEY_SHOW_TRAY_ICON, core );
    350350    hig_workarea_add_wide_control( t, &row, w );
    351351
    352     s = _( "Show popup _notifications" );
     352    s = _( "Show _popup notifications" );
    353353    w = new_check_button( s, PREF_KEY_SHOW_DESKTOP_NOTIFICATION, core );
    354354    hig_workarea_add_wide_control( t, &row, w );
  • trunk/qt/mainwin.cc

    r9261 r9338  
    10811081
    10821082
    1083         QCheckBox * button = new QCheckBox( tr( "Display &options dialog" ) );
     1083        QCheckBox * button = new QCheckBox( tr( "Show &options dialog" ) );
    10841084        button->setChecked( myPrefs.getBool( Prefs::OPTIONS_PROMPT ) );
    10851085        QGridLayout * layout = dynamic_cast<QGridLayout*>(myFileDialog->layout());
  • trunk/qt/options.cc

    r9247 r9338  
    111111    layout->addWidget( c, ++row, 0, 1, 2, Qt::AlignLeft );
    112112
    113     c = myTrashCheck = new QCheckBox( tr( "&Delete source file" ) );
     113    c = myTrashCheck = new QCheckBox( tr( "Mo&ve .torrent file to the trash" ) );
    114114    c->setChecked( prefs.getBool( Prefs :: TRASH_ORIGINAL ) );
    115115    layout->addWidget( c, ++row, 0, 1, 2, Qt::AlignLeft );
  • trunk/qt/prefs-dialog.cc

    r9330 r9338  
    564564        enableBuddyWhenChecked( qobject_cast<QCheckBox*>(l), b );
    565565
    566         hig->addWideControl( checkBoxNew( tr( "Display &options dialog" ), Prefs::OPTIONS_PROMPT ) );
     566        hig->addWideControl( checkBoxNew( tr( "Show &options dialog" ), Prefs::OPTIONS_PROMPT ) );
    567567        hig->addWideControl( checkBoxNew( tr( "&Start when added" ), Prefs::START ) );
    568         hig->addWideControl( checkBoxNew( tr( "&Delete source files" ), Prefs::TRASH_ORIGINAL ) );
     568        hig->addWideControl( checkBoxNew( tr( "Mo&ve .torrent file to the trash" ), Prefs::TRASH_ORIGINAL ) );
     569
     570        b = myIncompleteButton = new QPushButton;
     571        b->setIcon( folderPixmap );
     572        b->setStyleSheet( "text-align: left; padding-left: 5; padding-right: 5" );
     573        connect( b, SIGNAL(clicked(bool)), this, SLOT(onDestinationClicked(void)) );
     574        hig->addRow( tr( "Keep &incomplete files in:" ), b );
    569575
    570576        b = myDestinationButton = new QPushButton;
     
    623629         << Prefs :: BLOCKLIST_ENABLED
    624630         << Prefs :: DIR_WATCH
    625          << Prefs :: DOWNLOAD_DIR;
     631         << Prefs :: DOWNLOAD_DIR
     632         << Prefs :: INCOMPLETE_DIR
     633         << Prefs :: INCOMPLETE_DIR_ENABLED;
    626634    foreach( int key, keys )
    627635        updatePref( key );
     
    710718
    711719        case Prefs :: DOWNLOAD_DIR: {
    712             QString path( myPrefs.getString( Prefs :: DOWNLOAD_DIR ) );
     720            QString path( myPrefs.getString( key ) );
    713721            myDestinationButton->setText( QFileInfo(path).fileName() );
    714722            break;
    715723        }
     724
     725        case Prefs :: INCOMPLETE_DIR: {
     726            QString path( myPrefs.getString( key ) );
     727            myIncompleteButton->setText( QFileInfo(path).fileName() );
     728            break;
     729        }
     730
     731        case Prefs :: INCOMPLETE_DIR_ENABLED: {
     732            const bool enabled = myPrefs.getBool( key );
     733            myIncompleteButton->setEnabled( enabled );
     734            break;
     735        }
     736       
    716737
    717738        default:
Note: See TracChangeset for help on using the changeset viewer.