connect(selectionManager, &KItemListSelectionManager::selectionChanged,
this, &DolphinView::slotSelectionChanged);
+#ifdef HAVE_BALOO
m_toolTipManager = new ToolTipManager(this);
connect(m_toolTipManager, &ToolTipManager::urlActivated, this, &DolphinView::urlActivated);
+#endif
m_versionControlObserver = new VersionControlObserver(this);
m_versionControlObserver->setModel(m_model);
const QPoint pos = m_container->mapToGlobal(itemRect.topLeft().toPoint());
itemRect.moveTo(pos);
+#ifdef HAVE_BALOO
m_toolTipManager->showToolTip(item, itemRect, nativeParentWidget()->windowHandle());
+#endif
}
emit requestItemInfo(item);
void DolphinView::slotSelectedItemTextPressed(int index)
{
- if (GeneralSettings::renameInline()) {
+ if (GeneralSettings::renameInline() && !m_view->style()->styleHint(QStyle::SH_ItemView_ActivateItemOnSingleClick)) {
const KFileItem item = m_model->fileItem(index);
const KFileItemListProperties capabilities(KFileItemList() << item);
if (capabilities.supportsMoving()) {
void DolphinView::hideToolTip()
{
+#ifdef HAVE_BALOO
if (GeneralSettings::showToolTips()) {
m_toolTipManager->hideToolTip();
}
+#endif
}
void DolphinView::calculateItemCount(int& fileCount,
void DolphinView::slotDirectoryLoadingStarted()
{
// Disable the writestate temporary until it can be determined in a fast way
- // in DolphinView::slotLoadingCompleted()
+ // in DolphinView::slotDirectoryLoadingCompleted()
if (m_isFolderWritable) {
m_isFolderWritable = false;
emit writeStateChanged(m_isFolderWritable);
if (role == "text") {
const KFileItem oldItem = m_model->fileItem(index);
const QString newName = value.toString();
- if (!newName.isEmpty() && newName != oldItem.text() && newName != QLatin1String(".") && newName != QLatin1String("..")) {
+ if (!newName.isEmpty() && newName != oldItem.text() && newName != QLatin1Char('.') && newName != QLatin1String("..")) {
const QUrl oldUrl = oldItem.url();
QUrl newUrl = oldUrl.adjusted(QUrl::RemoveFilename);