diff options
| author | ambar chakravartty <[email protected]> | 2025-02-02 10:36:06 +0530 |
|---|---|---|
| committer | Méven Car <[email protected]> | 2025-02-06 14:32:35 +0000 |
| commit | f1a5aaa183e4e917a6d1b19fa328fca0a38df479 (patch) | |
| tree | 9488333eda90023ecc363b1df365fa34a6573af6 /src | |
| parent | bb163a7b3dc7857f698150460b33ba8f3f2204f9 (diff) | |
changed all calls to "title(), setTitle()" to "customLabel(), setCustomLabel()"
Diffstat (limited to 'src')
| -rw-r--r-- | src/dolphintabpage.cpp | 15 | ||||
| -rw-r--r-- | src/dolphintabwidget.cpp | 6 |
2 files changed, 11 insertions, 10 deletions
diff --git a/src/dolphintabpage.cpp b/src/dolphintabpage.cpp index 7199bcbf3..dbc55e7d6 100644 --- a/src/dolphintabpage.cpp +++ b/src/dolphintabpage.cpp @@ -13,6 +13,7 @@ #include <QGridLayout> #include <QStyle> #include <QVariantAnimation> + DolphinTabPage::DolphinTabPage(const QUrl &primaryUrl, const QUrl &secondaryUrl, QWidget *parent) : QWidget(parent) , m_expandingContainer{nullptr} @@ -274,8 +275,8 @@ QByteArray DolphinTabPage::saveState() const stream << m_primaryViewActive; stream << m_splitter->saveState(); - if (!m_title.isEmpty()) { - stream << m_title; + if (!m_customLabel.isEmpty()) { + stream << m_customLabel; } return state; @@ -335,7 +336,7 @@ void DolphinTabPage::restoreState(const QByteArray &state) if (!stream.atEnd()) { QString tabTitle; stream >> tabTitle; - setTitle(tabTitle); + setCustomLabel(tabTitle); } } @@ -351,14 +352,14 @@ void DolphinTabPage::setActive(bool active) activeViewContainer()->setActive(active); } -void DolphinTabPage::setTitle(const QString &name) +void DolphinTabPage::setCustomLabel(const QString &label) { - m_title = name; + m_customLabel = label; } -QString DolphinTabPage::title() const +QString DolphinTabPage::customLabel() const { - return m_title; + return m_customLabel; } void DolphinTabPage::slotAnimationFinished() diff --git a/src/dolphintabwidget.cpp b/src/dolphintabwidget.cpp index c2fae5170..be674994d 100644 --- a/src/dolphintabwidget.cpp +++ b/src/dolphintabwidget.cpp @@ -124,8 +124,8 @@ void DolphinTabWidget::updateTabName(int index) { Q_ASSERT(index >= 0); - if (!tabPageAt(index)->title().isEmpty()) { - QString name = tabPageAt(index)->title(); + if (!tabPageAt(index)->customLabel().isEmpty()) { + QString name = tabPageAt(index)->customLabel(); tabBar()->setTabText(index, name); return; } @@ -483,7 +483,7 @@ void DolphinTabWidget::currentTabChanged(int index) void DolphinTabWidget::renameTab(int index, const QString &name) { if (!name.isEmpty()) { - tabPageAt(index)->setTitle(name); + tabPageAt(index)->setCustomLabel(name); } updateTabName(index); |
