mirror of
https://invent.kde.org/system/dolphin
synced 2024-09-12 12:54:29 +00:00
Provide a setting to turn on/off tooltips. The tooltip implementation itself will be committed before the feature freeze (20th of April).
CCMAIL: konst.heil@stud.uni-heidelberg.de svn path=/trunk/KDE/kdebase/apps/; revision=794772
This commit is contained in:
parent
ec19eaa2c5
commit
4b859a3621
|
@ -40,6 +40,10 @@
|
|||
<label context="@label">Show selection toggle</label>
|
||||
<default>true</default>
|
||||
</entry>
|
||||
<entry name="ShowToolTips" type="Bool">
|
||||
<label context="@label">Show tooltips</label>
|
||||
<default>false</default>
|
||||
</entry>
|
||||
<entry name="ShowCopyMoveMenu" type="Bool">
|
||||
<label context="@label">Show 'Copy To' and 'Move To' commands in context menu</label>
|
||||
<default>false</default>
|
||||
|
|
|
@ -120,6 +120,10 @@ DolphinView::DolphinView(QWidget* parent,
|
|||
|
||||
applyViewProperties(url);
|
||||
m_topLayout->addWidget(itemView());
|
||||
|
||||
if (DolphinSettings::instance().generalSettings()->showToolTips()) {
|
||||
// TODO: instantiate ToolTipManager here...
|
||||
}
|
||||
}
|
||||
|
||||
DolphinView::~DolphinView()
|
||||
|
|
|
@ -48,7 +48,8 @@ GeneralViewSettingsPage::GeneralViewSettingsPage(const KUrl& url,
|
|||
m_maxPreviewSize(0),
|
||||
m_spinBox(0),
|
||||
m_useFileThumbnails(0),
|
||||
m_showSelectionToggle(0)
|
||||
m_showSelectionToggle(0),
|
||||
m_showToolTips(0)
|
||||
{
|
||||
const int spacing = KDialog::spacingHint();
|
||||
const int margin = KDialog::marginHint();
|
||||
|
@ -100,6 +101,9 @@ GeneralViewSettingsPage::GeneralViewSettingsPage(const KUrl& url,
|
|||
m_showSelectionToggle = new QCheckBox(i18nc("@option:check", "Show selection toggle"), this);
|
||||
connect(m_showSelectionToggle, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
|
||||
|
||||
m_showToolTips = new QCheckBox(i18nc("@option:check", "Show tooltips"), this);
|
||||
connect(m_showToolTips, SIGNAL(toggled(bool)), this, SIGNAL(changed()));
|
||||
|
||||
// Add a dummy widget with no restriction regarding
|
||||
// a vertical resizing. This assures that the dialog layout
|
||||
// is not stretched vertically.
|
||||
|
@ -142,6 +146,7 @@ void GeneralViewSettingsPage::applySettings()
|
|||
globalConfig.sync();
|
||||
|
||||
settings->setShowSelectionToggle(m_showSelectionToggle->isChecked());
|
||||
settings->setShowToolTips(m_showToolTips->isChecked());
|
||||
}
|
||||
|
||||
void GeneralViewSettingsPage::restoreDefaults()
|
||||
|
@ -190,6 +195,7 @@ void GeneralViewSettingsPage::loadSettings()
|
|||
m_useFileThumbnails->setChecked(useFileThumbnails);
|
||||
|
||||
m_showSelectionToggle->setChecked(settings->showSelectionToggle());
|
||||
m_showToolTips->setChecked(settings->showToolTips());
|
||||
}
|
||||
|
||||
#include "generalviewsettingspage.moc"
|
||||
|
|
|
@ -67,6 +67,7 @@ private:
|
|||
QSpinBox* m_spinBox;
|
||||
QCheckBox* m_useFileThumbnails;
|
||||
QCheckBox* m_showSelectionToggle;
|
||||
QCheckBox* m_showToolTips;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue