vcs/cvsservice/cvslogdialog.cpp
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
#include <qvbox.h>
00013
#include <qregexp.h>
00014
#include <qdir.h>
00015
#include <qstringlist.h>
00016
00017
#include <kmessagebox.h>
00018
#include <kcursor.h>
00019
#include <klocale.h>
00020
#include <kdebug.h>
00021
00022
#include <cvsjob_stub.h>
00023
#include <cvsservice_stub.h>
00024
00025
#include "cvsoptions.h"
00026
#include "cvslogpage.h"
00027
#include "cvsdiffpage.h"
00028
00029
#include "cvslogdialog.h"
00030
00032
00034
00035 CVSLogDialog::CVSLogDialog( CvsService_stub *cvsService,
QWidget *parent,
const char *name,
int )
00036 :
KDialogBase( Tabbed, i18n("CVS Log & Diff Dialog"), Close, Close,
00037 parent, name? name : "logformdialog", false , true ),
00038 m_cvsLogPage( 0 ), m_cvsService( cvsService )
00039 {
00040 setWFlags( getWFlags() | WDestructiveClose );
00041
00042
QVBox *vbox = addVBoxPage( i18n(
"Log From CVS") );
00043
m_cvsLogPage =
new CVSLogPage(
m_cvsService, vbox );
00044
00045 connect(
m_cvsLogPage, SIGNAL(diffRequested(
const QString&,
const QString&,
const QString&)),
00046
this, SLOT(
slotDiffRequested(
const QString&,
const QString&,
const QString&)) );
00047 }
00048
00050
00051 CVSLogDialog::~CVSLogDialog()
00052 {
00053
kdDebug(9006) <<
"CVSLogDialog::~CVSLogDialog()" <<
endl;
00054 }
00055
00057
00058 void CVSLogDialog::startLog(
const QString &workDir,
const QString &pathName )
00059 {
00060
kdDebug(9006) <<
"CVSLogDialog::start() here! workDir = " << workDir <<
00061
", pathName = " << pathName <<
endl;
00062
00063
00064
00065
00066
00067
00068
00069
00070
00071
00072
m_cvsLogPage->
startLog( workDir, pathName );
00073 }
00074
00076
00077 void CVSLogDialog::slotDiffRequested(
const QString &pathName,
const QString &revA,
const QString &revB )
00078 {
00079
kdDebug(9006) <<
"CVSLogDialog::slotDiffRequested()" <<
endl;
00080
00081
00082
QString diffTitle = i18n(
"Diff between %1 and %2").arg( revA ).arg( revB );
00083
QVBox *vbox = addVBoxPage( diffTitle );
00084
CVSDiffPage *diffPage =
new CVSDiffPage(
m_cvsService, vbox );
00085 diffPage->
startDiff( pathName, revA, revB );
00086 }
00087
00089
00090 void CVSLogDialog::slotCancel()
00091 {
00092
00093
00094
KDialogBase::slotCancel();
00095 }
00096
00098
00099 void CVSLogDialog::displayActionFeedback(
bool working )
00100 {
00101
if (working)
00102 {
00103 setCursor( KCursor::waitCursor() );
00104 }
00105
else
00106 {
00107 setCursor( KCursor::arrowCursor() );
00108 }
00109 }
00110
00111
#include "cvslogdialog.moc"
00112
00113
This file is part of the documentation for KDevelop Version 3.0.4.