Logo Search packages:      
Sourcecode: kdar version File versions  Download package

void KDarConfig::slotEditDirectoryFilter (  )  [virtual, slot]

Slot for editing a directory filter.

Definition at line 1688 of file kdarConfig.cpp.

References newDirectoryFilter().

{
    //Set the filesystem radiobutton, since if the user wants to edit the
    //filter, they can use the keyboard from the lineEdit --- you can't
    //edit the combobox anyway. Otherwise, we'd have to come up with a more
    //sophisticated filter system that keeps track of whether a given
    //filter came from the "list" or the "filesystem" part of the dialog.
    //The user can still select "list" and choose a combobox item.
    QListViewItem* filterItem = directoryFiltersListView->selectedItem();
    if ( filterItem )
    {
        m_directoryDlg->filesystemRadioButton->setChecked( true );
        QString type = filterItem->text( 0 );
        if ( type == i18n( "filter type for exclusion", "Exclude" ) )
        {
            m_directoryDlg->directoryFilesystemTypeComboBox->setCurrentItem( KDar::DO_NOT_INCLUDE );
        }
        else if ( type == i18n( "filter type for inclusion", "Include" ) )
        {
            m_directoryDlg->directoryFilesystemTypeComboBox->setCurrentItem( KDar::INCLUDE );
        }
        m_directoryDlg->directoryFilterValueKURLRequester->lineEdit()->setText( filterItem->text( 1 ) );
        if ( m_directoryDlg->exec() )
        {
            if ( filterItem ) delete filterItem;
            newDirectoryFilter();
        }
    }
}


Generated by  Doxygen 1.6.0   Back to index