diff options
| author | ambar chakravartty <[email protected]> | 2025-01-27 17:53:39 +0530 |
|---|---|---|
| committer | Méven Car <[email protected]> | 2025-02-06 14:32:35 +0000 |
| commit | c4528f6d74336d4e7e21cf3619cc96a7fcbba475 (patch) | |
| tree | d4f41c01b59b08c4820591130042a0c4662ed0bd /src/dolphintabwidget.cpp | |
| parent | cc8a577a2f81eef1d08b301171b780c8ee843d87 (diff) | |
refactored renameTab
Diffstat (limited to 'src/dolphintabwidget.cpp')
| -rw-r--r-- | src/dolphintabwidget.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/dolphintabwidget.cpp b/src/dolphintabwidget.cpp index 1723f6505..949642f4f 100644 --- a/src/dolphintabwidget.cpp +++ b/src/dolphintabwidget.cpp @@ -482,12 +482,10 @@ void DolphinTabWidget::currentTabChanged(int index) void DolphinTabWidget::renameTab(int index, const QString &name) { - if (name.isEmpty()) { - updateTabName(index); - } else { + if (!name.isEmpty()) { tabPageAt(index)->setTitle(name); - tabBar()->setTabText(index, name); } + updateTabName(index); } void DolphinTabWidget::tabInserted(int index) |
