File indexing completed on 2024-05-05 04:51:37

0001 /*
0002     SPDX-FileCopyrightText: 1998-2008 Sebastian Trueg <trueg@k3b.org>
0003 
0004     SPDX-License-Identifier: GPL-2.0-or-later
0005 */
0006 
0007 
0008 #include "k3bexternalbinoptiontab.h"
0009 #include "k3bexternalbinmanager.h"
0010 #include "k3bexternalbinwidget.h"
0011 
0012 #include <KLocalizedString>
0013 #include <KMessageBox>
0014 
0015 #include <QLabel>
0016 #include <QVBoxLayout>
0017 
0018 
0019 K3b::ExternalBinOptionTab::ExternalBinOptionTab( K3b::ExternalBinManager* manager, QWidget* parent )
0020     : QWidget( parent )
0021 {
0022     m_manager = manager;
0023 
0024     m_externalBinWidget = new K3b::ExternalBinWidget( manager, this );
0025 
0026     QLabel* m_labelInfo = new QLabel( this );
0027     m_labelInfo->setWordWrap( true );
0028     m_labelInfo->setText( "<p>" + i18n( "Specify the paths to the external programs that K3b needs to work properly, "
0029                                         "or press \"Refresh\" to let K3b search for the programs." ) + "</p>" );
0030 
0031     QVBoxLayout* frameLayout = new QVBoxLayout( this );
0032     frameLayout->setContentsMargins( 0, 0, 0, 0 );
0033     frameLayout->addWidget( m_labelInfo );
0034     frameLayout->addWidget( m_externalBinWidget );
0035 }
0036 
0037 
0038 K3b::ExternalBinOptionTab::~ExternalBinOptionTab()
0039 {
0040 }
0041 
0042 
0043 void K3b::ExternalBinOptionTab::readSettings()
0044 {
0045     m_externalBinWidget->load();
0046 }
0047 
0048 
0049 void K3b::ExternalBinOptionTab::saveSettings()
0050 {
0051     m_externalBinWidget->save();
0052 }
0053 
0054 #include "moc_k3bexternalbinoptiontab.cpp"