/***************************************************************************
                          rpmbuildwidgetimpl.cpp  -  description
                             -------------------
    begin                : Sun Dec 3 2000
    copyright            : (C) 2000 by Olaf Lueg, Adam Kreuschner
    email                : olaf.lueg@t-online.de, kreuschner@dvoid.org
 ***************************************************************************/

/***************************************************************************
 *                                                                         *
 *   This program is free software; you can redistribute it and/or modify  *
 *   it under the terms of the GNU General Public License as published by  *
 *   the Free Software Foundation; either version 2 of the License, or     *
 *   (at your option) any later version.                                   *
 *                                                                         *
 ***************************************************************************/

#include "rpmbuildwidgetimpl.h"

// kde include
#include <kiconloader.h>
#include <kurl.h>
#include <kfiledialog.h>
#include <klocale.h>

// qt include
#include <qtoolbutton.h>
#include <qlineedit.h>

RPMBuildWidgetImpl::RPMBuildWidgetImpl(QWidget *parent, const char *name ) : RPMBuildWidget(parent,name) {

}
RPMBuildWidgetImpl::~RPMBuildWidgetImpl(){
}
/**  */
void RPMBuildWidgetImpl::slotSourceFileOpen(){
		KURL url = KFileDialog::getOpenURL("/usr/src/",
      i18n("*.tar.gz *.tar.bz2|Source files"), this, i18n("Source file..."));
    if(!url.path().isEmpty()) {
      strSource->setText(url.path());
    }
}
/**  */
void RPMBuildWidgetImpl::slotPatchFileOpen(){
		KURL url = KFileDialog::getOpenURL("/usr/src/",
      i18n("*.patch *.diff|Patch files"), this, i18n("Patch file..."));
    if(!url.path().isEmpty()) {
      strPatch->setText(url.path());
    }
}

