Changeset View
Changeset View
Standalone View
Standalone View
src/svnfrontend/maintreewidget.cpp
Show First 20 Lines • Show All 144 Lines • ▼ Show 20 Line(s) | 143 | connect(m_DirTreeView->selectionModel(), | |||
---|---|---|---|---|---|
145 | this, SLOT(slotDirSelectionChanged(QItemSelection,QItemSelection))); | 145 | this, SLOT(slotDirSelectionChanged(QItemSelection,QItemSelection))); | ||
146 | 146 | | |||
147 | connect(m_Data->m_Model->svnWrapper(), SIGNAL(clientException(QString)), this, SLOT(slotClientException(QString))); | 147 | connect(m_Data->m_Model->svnWrapper(), SIGNAL(clientException(QString)), this, SLOT(slotClientException(QString))); | ||
148 | connect(m_Data->m_Model, SIGNAL(clientException(QString)), this, SLOT(slotClientException(QString))); | 148 | connect(m_Data->m_Model, SIGNAL(clientException(QString)), this, SLOT(slotClientException(QString))); | ||
149 | connect(m_Data->m_Model->svnWrapper(), SIGNAL(sendNotify(QString)), this, SLOT(slotNotifyMessage(QString))); | 149 | connect(m_Data->m_Model->svnWrapper(), SIGNAL(sendNotify(QString)), this, SLOT(slotNotifyMessage(QString))); | ||
150 | connect(m_Data->m_Model->svnWrapper(), SIGNAL(reinitItem(SvnItem*)), this, SLOT(slotReinitItem(SvnItem*))); | 150 | connect(m_Data->m_Model->svnWrapper(), SIGNAL(reinitItem(SvnItem*)), this, SLOT(slotReinitItem(SvnItem*))); | ||
151 | connect(m_Data->m_Model->svnWrapper(), SIGNAL(sigRefreshAll()), this, SLOT(refreshCurrentTree())); | 151 | connect(m_Data->m_Model->svnWrapper(), SIGNAL(sigRefreshAll()), this, SLOT(refreshCurrentTree())); | ||
152 | connect(m_Data->m_Model->svnWrapper(), SIGNAL(sigRefreshCurrent(SvnItem*)), this, SLOT(refreshCurrent(SvnItem*))); | 152 | connect(m_Data->m_Model->svnWrapper(), SIGNAL(sigRefreshCurrent(SvnItem*)), this, SLOT(refreshCurrent(SvnItem*))); | ||
153 | connect(m_Data->m_Model->svnWrapper(), SIGNAL(sigRefreshIcons()), this, SLOT(slotRescanIcons())); | 153 | connect(m_Data->m_Model->svnWrapper(), SIGNAL(sigRefreshItem(QString)), this, SLOT(slotRefreshItem(QString))); | ||
154 | connect(m_Data->m_Model->svnWrapper(), SIGNAL(sigGotourl(QUrl)), this, SLOT(_openUrl(QUrl))); | 154 | connect(m_Data->m_Model->svnWrapper(), SIGNAL(sigGotourl(QUrl)), this, SLOT(_openUrl(QUrl))); | ||
155 | connect(m_Data->m_Model->svnWrapper(), SIGNAL(sigCacheStatus(qlonglong,qlonglong)), this, SIGNAL(sigCacheStatus(qlonglong,qlonglong))); | 155 | connect(m_Data->m_Model->svnWrapper(), SIGNAL(sigCacheStatus(qlonglong,qlonglong)), this, SIGNAL(sigCacheStatus(qlonglong,qlonglong))); | ||
156 | connect(m_Data->m_Model->svnWrapper(), SIGNAL(sigThreadsChanged()), this, SLOT(enableActions())); | 156 | connect(m_Data->m_Model->svnWrapper(), SIGNAL(sigThreadsChanged()), this, SLOT(enableActions())); | ||
157 | connect(m_Data->m_Model->svnWrapper(), SIGNAL(sigCacheDataChanged()), this, SLOT(slotCacheDataChanged())); | 157 | connect(m_Data->m_Model->svnWrapper(), SIGNAL(sigCacheDataChanged()), this, SLOT(slotCacheDataChanged())); | ||
158 | 158 | | |||
159 | connect(m_Data->m_Model->svnWrapper(), SIGNAL(sigExtraStatusMessage(QString)), this, SIGNAL(sigExtraStatusMessage(QString))); | 159 | connect(m_Data->m_Model->svnWrapper(), SIGNAL(sigExtraStatusMessage(QString)), this, SIGNAL(sigExtraStatusMessage(QString))); | ||
160 | 160 | | |||
161 | connect(m_Data->m_Model, SIGNAL(urlDropped(QList<QUrl>,Qt::DropAction,QModelIndex,bool)), | 161 | connect(m_Data->m_Model, SIGNAL(urlDropped(QList<QUrl>,Qt::DropAction,QModelIndex,bool)), | ||
▲ Show 20 Lines • Show All 1449 Lines • ▼ Show 20 Line(s) | 1610 | if (!isWorkingCopy()) { | |||
1611 | return; | 1611 | return; | ||
1612 | } | 1612 | } | ||
1613 | SvnItem *which = SelectedOrMain(); | 1613 | SvnItem *which = SelectedOrMain(); | ||
1614 | if (!which) { | 1614 | if (!which) { | ||
1615 | return; | 1615 | return; | ||
1616 | } | 1616 | } | ||
1617 | m_Data->m_Model->svnWrapper()->slotResolved(which->fullName()); | 1617 | m_Data->m_Model->svnWrapper()->slotResolved(which->fullName()); | ||
1618 | which->refreshStatus(true); | 1618 | which->refreshStatus(true); | ||
1619 | //slotRescanIcons(false); | | |||
1620 | } | 1619 | } | ||
1621 | 1620 | | |||
1622 | void MainTreeWidget::slotTryResolve() | 1621 | void MainTreeWidget::slotTryResolve() | ||
1623 | { | 1622 | { | ||
1624 | if (!isWorkingCopy()) { | 1623 | if (!isWorkingCopy()) { | ||
1625 | return; | 1624 | return; | ||
1626 | } | 1625 | } | ||
1627 | SvnItem *which = Selected(); | 1626 | SvnItem *which = Selected(); | ||
▲ Show 20 Lines • Show All 662 Lines • ▼ Show 20 Line(s) | 2288 | } else { | |||
2290 | what.reserve(which.size()); | 2289 | what.reserve(which.size()); | ||
2291 | Q_FOREACH(const SvnItem *item, which) { | 2290 | Q_FOREACH(const SvnItem *item, which) { | ||
2292 | what.append(svn::Path(item->fullName())); | 2291 | what.append(svn::Path(item->fullName())); | ||
2293 | } | 2292 | } | ||
2294 | } | 2293 | } | ||
2295 | m_Data->m_Model->svnWrapper()->makeUpdate(svn::Targets(what), svn::Revision::HEAD, svn::DepthUnknown); | 2294 | m_Data->m_Model->svnWrapper()->makeUpdate(svn::Targets(what), svn::Revision::HEAD, svn::DepthUnknown); | ||
2296 | } | 2295 | } | ||
2297 | 2296 | | |||
2298 | void MainTreeWidget::slotRescanIcons() | 2297 | void MainTreeWidget::slotRefreshItem(const QString &path) | ||
2299 | { | 2298 | { | ||
2300 | m_Data->m_Model->refreshIndex(m_Data->m_Model->firstRootIndex()); | 2299 | const QModelIndex idx = m_Data->m_Model->findIndex(path); | ||
2300 | if (!idx.isValid()) | ||||
2301 | return; | ||||
2302 | m_Data->m_Model->emitDataChangedRow(idx); | ||||
2301 | } | 2303 | } | ||
2302 | 2304 | | |||
2303 | void MainTreeWidget::checkUseNavigation(bool startup) | 2305 | void MainTreeWidget::checkUseNavigation(bool startup) | ||
2304 | { | 2306 | { | ||
2305 | bool use = Kdesvnsettings::show_navigation_panel(); | 2307 | bool use = Kdesvnsettings::show_navigation_panel(); | ||
2306 | if (use) | 2308 | if (use) | ||
2307 | { | 2309 | { | ||
2308 | checkSyncTreeModel(); | 2310 | checkSyncTreeModel(); | ||
▲ Show 20 Lines • Show All 68 Lines • Show Last 20 Lines |