Commit ce8d67ef authored by Laurent Montel's avatar Laurent Montel 😁

Port++

svn path=/trunk/KDE/kdesdk/cervisia/; revision=622329
parent f40023ff
......@@ -15,7 +15,7 @@ set(libcervisia_SRCS
diffdlg.cpp
patchoptiondlg.cpp
logdlg.cpp
#progressdlg.cpp
progressdlg.cpp
resolvedlg.cpp
resolvedlg_p.cpp
annotateview.cpp
......@@ -50,7 +50,7 @@ kde4_automoc(${cervisia_KDEINIT_SRCS})
kde4_add_kdeinit_executable( cervisia ${cervisia_KDEINIT_SRCS})
target_link_libraries(kdeinit_cervisia ${KDE4_KPARTS_LIBS} ${KDE4_KUTILS_LIBS} cvsservice )
target_link_libraries(kdeinit_cervisia ${KDE4_KPARTS_LIBS} ${KDE4_KUTILS_LIBS} )
install(TARGETS kdeinit_cervisia DESTINATION ${LIB_INSTALL_DIR} )
......@@ -97,7 +97,7 @@ kde4_add_plugin(cervisiapart WITH_PREFIX ${cervisiapart_PART_SRCS})
target_link_libraries(cervisiapart ${KDE4_KPARTS_LIBS} ${KDE4_KUTILS_LIBS} cvsservice )
target_link_libraries(cervisiapart ${KDE4_KPARTS_LIBS} ${KDE4_KUTILS_LIBS} )
install(TARGETS cervisiapart DESTINATION ${PLUGIN_INSTALL_DIR} )
......
......@@ -36,7 +36,7 @@
CervisiaShell::CervisiaShell( const char *name )
: KParts::MainWindow( name )
: KParts::MainWindow( 0L,name )
, m_part(0)
{
setXMLFile( "cervisiashellui.rc" );
......@@ -97,7 +97,7 @@ void CervisiaShell::setupActions()
{
setStandardToolBarMenuEnabled( true );
KAction *action = KStandardAction::configureToolbars( this, SLOT(slotConfigureToolBars()),
QAction *action = KStandardAction::configureToolbars( this, SLOT(slotConfigureToolBars()),
actionCollection() );
QString hint = i18n("Allows you to configure the toolbar");
action->setToolTip( hint );
......@@ -142,13 +142,13 @@ void CervisiaShell::setupActions()
void CervisiaShell::openURL()
{
if( !m_lastOpenDir.isEmpty() )
m_part->openURL(KUrl::fromPathOrUrl(m_lastOpenDir));
m_part->openUrl(KUrl::fromPathOrUrl(m_lastOpenDir));
}
void CervisiaShell::openURL(const KUrl& url)
{
m_part->openURL(url);
m_part->openUrl(url);
}
......
......@@ -44,21 +44,21 @@ static OrgKdeCervisiaCvsserviceCvsserviceInterface* StartDCOPService(const QStri
{
// start the cvs DCOP service
QString error;
QByteArray appId;
if( KToolInvocation::startServiceByDesktopName("cvsservice", QStringList(),
&error, &appId) )
&error) )
{
std::cerr << "Starting cvsservice failed with message: "
<< error.latin1() << std::endl;
exit(1);
}
#if 0
QDBusReply<QDBusObjectPath> repository(appId, "CvsRepository");
repository.call("setWorkingCopy(QString)", directory);
// create a reference to the service
return new OrgKdeCervisiaCvsserviceCvsserviceInterface(appId, "CvsService");
#endif
}
......
......@@ -68,8 +68,8 @@ ProgressDialog::ProgressDialog(QWidget* parent, const QString& heading,
d->isShown = false;
d->hasError = false;
QDBusObjectPath path = jobPath.path();
d->cvsJob = new OrgKdeCervisiaCvsserviceCvsjobInterface("org.kde.cervisia",path,QDBusConnection::sessionBus(), this);
QDBusObjectPath path = jobPath;
d->cvsJob = new OrgKdeCervisiaCvsserviceCvsjobInterface("org.kde.cervisia",path.path(),QDBusConnection::sessionBus(), this);
d->buffer = "";
d->errorId1 = "cvs " + errorIndicator + ':';
......@@ -88,7 +88,8 @@ ProgressDialog::~ProgressDialog()
void ProgressDialog::setupGui(const QString& heading)
{
KVBox* vbox = makeVBoxMainWidget();
KVBox* vbox = new KVBox(this);
setMainWidget(vbox);
vbox->setSpacing(10);
QWidget* headingBox = new QWidget(vbox);
......@@ -119,7 +120,7 @@ bool ProgressDialog::execute()
// get command line and display it
QString cmdLine = d->cvsJob->cvsCommand();
d->resultbox->insertItem(cmdLine);
#if 0
// establish connections to the signals of the cvs job
connectDCOPSignal(d->cvsJob->app(), d->cvsJob->obj(), "jobExited(bool, int)",
"slotJobExited(bool, int)", true);
......@@ -127,7 +128,7 @@ bool ProgressDialog::execute()
"slotReceivedOutputNonGui(QString)", true);
connectDCOPSignal(d->cvsJob->app(), d->cvsJob->obj(), "receivedStderr(QString)",
"slotReceivedOutputNonGui(QString)", true);
#endif
// we wait for 4 seconds (or the timeout set by the user) before we
// force the dialog to show up
d->timer = new QTimer(this);
......@@ -229,12 +230,12 @@ void ProgressDialog::slotTimeoutOccurred()
void ProgressDialog::stopNonGuiPart()
{
d->timer->stop();
#if 0
disconnectDCOPSignal(d->cvsJob->app(), d->cvsJob->obj(), "receivedStdout(QString)",
"slotReceivedOutputNonGui(QString)");
disconnectDCOPSignal(d->cvsJob->app(), d->cvsJob->obj(), "receivedStderr(QString)",
"slotReceivedOutputNonGui(QString)");
#endif
kapp->exit_loop();
}
......
......@@ -66,14 +66,15 @@ UpdateView::UpdateView(KConfigBase& partConfig, QWidget *parent, const char *nam
// without this restoreLayout() can't change the column widths
for (int col = 0; col < columns(); ++col)
setColumnWidthMode(col, Q3ListView::Manual);
restoreLayout(&m_partConfig, QLatin1String("UpdateView"));
#warning "kde4: reactivate it"
//restoreLayout(&m_partConfig, QLatin1String("UpdateView"));
}
UpdateView::~UpdateView()
{
saveLayout(&m_partConfig, QLatin1String("UpdateView"));
#warning "kde4: reactivate it"
//saveLayout(&m_partConfig, QLatin1String("UpdateView"));
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment