1
0
mirror of https://invent.kde.org/system/dolphin synced 2024-07-04 17:30:55 +00:00

Merge branch 'Applications/15.08'

This commit is contained in:
Michael Palimaka 2015-09-26 05:38:06 +10:00
commit 8a56637663
5 changed files with 16 additions and 12 deletions

View File

@ -5,7 +5,7 @@ project(Dolphin)
# KDE Application Version, managed by release script
set (KDE_APPLICATIONS_VERSION_MAJOR "15")
set (KDE_APPLICATIONS_VERSION_MINOR "08")
set (KDE_APPLICATIONS_VERSION_MICRO "0")
set (KDE_APPLICATIONS_VERSION_MICRO "1")
set (KDE_APPLICATIONS_VERSION "${KDE_APPLICATIONS_VERSION_MAJOR}.${KDE_APPLICATIONS_VERSION_MINOR}.${KDE_APPLICATIONS_VERSION_MICRO}")
set(QT_MIN_VERSION "5.4.0")
@ -66,7 +66,7 @@ find_package(KF5 ${KF5_MIN_VERSION} REQUIRED COMPONENTS
WindowSystem
Notifications
)
find_package(KF5 ${KF5_MIN_VERSION} COMPONENTS
find_package(KF5 ${KF5_MIN_VERSION} OPTIONAL_COMPONENTS
Activities
)

View File

@ -74,28 +74,28 @@ DolphinSettingsDialog::DolphinSettingsDialog(const QUrl& url, QWidget* parent) :
NavigationSettingsPage* navigationSettingsPage = new NavigationSettingsPage(this);
KPageWidgetItem* navigationSettingsFrame = addPage(navigationSettingsPage,
i18nc("@title:group", "Navigation"));
navigationSettingsFrame->setIcon(QIcon::fromTheme("input-mouse"));
navigationSettingsFrame->setIcon(QIcon::fromTheme("edit-select"));
connect(navigationSettingsPage, &NavigationSettingsPage::changed, this, &DolphinSettingsDialog::enableApply);
// Services
ServicesSettingsPage* servicesSettingsPage = new ServicesSettingsPage(this);
KPageWidgetItem* servicesSettingsFrame = addPage(servicesSettingsPage,
i18nc("@title:group", "Services"));
servicesSettingsFrame->setIcon(QIcon::fromTheme("services"));
servicesSettingsFrame->setIcon(QIcon::fromTheme("flag"));
connect(servicesSettingsPage, &ServicesSettingsPage::changed, this, &DolphinSettingsDialog::enableApply);
// Trash
TrashSettingsPage* trashSettingsPage = new TrashSettingsPage(this);
KPageWidgetItem* trashSettingsFrame = addPage(trashSettingsPage,
i18nc("@title:group", "Trash"));
trashSettingsFrame->setIcon(QIcon::fromTheme("user-trash"));
trashSettingsFrame->setIcon(QIcon::fromTheme("trash-empty"));
connect(trashSettingsPage, &TrashSettingsPage::changed, this, &DolphinSettingsDialog::enableApply);
// General
GeneralSettingsPage* generalSettingsPage = new GeneralSettingsPage(url, this);
KPageWidgetItem* generalSettingsFrame = addPage(generalSettingsPage,
i18nc("@title:group General settings", "General"));
generalSettingsFrame->setIcon(QIcon::fromTheme("system-run"));
generalSettingsFrame->setIcon(QIcon::fromTheme("view-preview"));
connect(generalSettingsPage, &GeneralSettingsPage::changed, this, &DolphinSettingsDialog::enableApply);
m_pages.append(startupSettingsPage);

View File

@ -43,11 +43,6 @@ NavigationSettingsPage::NavigationSettingsPage(QWidget* parent) :
m_autoExpandFolders = new QCheckBox(i18nc("option:check", "Open folders during drag operations"), vBox);
vBoxLayout->addWidget(m_autoExpandFolders);
// Add a dummy widget with no restriction regarding
// a vertical resizing. This assures that the dialog layout
// is not stretched vertically.
new QWidget(vBox);
topLayout->addWidget(vBox);
loadSettings();

View File

@ -108,7 +108,6 @@ RenameDialog::RenameDialog(QWidget *parent, const KFileItemList& items) :
m_lineEdit->setText(m_newName);
m_lineEdit->setSelection(0, selectionLength);
m_lineEdit->setFocus();
topLayout->addWidget(editLabel);
topLayout->addWidget(m_lineEdit);
@ -197,6 +196,13 @@ void RenameDialog::slotTextChanged(const QString& newName)
m_okButton->setEnabled(enable);
}
void RenameDialog::showEvent(QShowEvent* event)
{
m_lineEdit->setFocus();
QDialog::showEvent(event);
}
void RenameDialog::renameItems()
{
// Iterate through all items and rename them...

View File

@ -45,6 +45,9 @@ private slots:
void slotAccepted();
void slotTextChanged(const QString& newName);
protected:
void showEvent(QShowEvent* event) override;
private:
void renameItems();
void renameItem(const KFileItem &item, const QString& newName);