diff options
author | Saturn&Eric <[email protected]> | 2021-12-13 14:50:57 +0000 |
---|---|---|
committer | GitHub <[email protected]> | 2021-12-13 14:50:57 +0000 |
commit | ee4752ed756e3114f740efddf63ce987ac154d03 (patch) | |
tree | 27653d56c88849c99c70b8fc7223f8ae98090f0b /src/ui/widgets/TextEdit.cpp | |
parent | Update CI for Release and Debug. (diff) | |
parent | Added & Fixed (diff) | |
download | GpgFrontend-ee4752ed756e3114f740efddf63ce987ac154d03.tar.gz GpgFrontend-ee4752ed756e3114f740efddf63ce987ac154d03.zip |
Merge pull request #31 from saturneric/develop-ui
v2.0.2-beta.1
Diffstat (limited to 'src/ui/widgets/TextEdit.cpp')
-rw-r--r-- | src/ui/widgets/TextEdit.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/ui/widgets/TextEdit.cpp b/src/ui/widgets/TextEdit.cpp index ec6c6c7a..036c69d4 100644 --- a/src/ui/widgets/TextEdit.cpp +++ b/src/ui/widgets/TextEdit.cpp @@ -77,12 +77,13 @@ void TextEdit::slotNewFileTab() const { void TextEdit::slotOpenFile(QString& path) { QFile file(path); - LOG(INFO) << " path" << path.toStdString(); + LOG(INFO) << "path" << path.toStdString(); auto result = file.open(QIODevice::ReadOnly | QIODevice::Text); if (result) { auto* page = new EditorPage(path); QApplication::setOverrideCursor(Qt::WaitCursor); - tabWidget->addTab(page, strippedName(path)); + auto index = tabWidget->addTab(page, strippedName(path)); + tabWidget->setTabIcon(index, QIcon(":file.png")); tabWidget->setCurrentIndex(tabWidget->count() - 1); QApplication::restoreOverrideCursor(); page->getTextPage()->setFocus(); @@ -96,7 +97,6 @@ void TextEdit::slotOpenFile(QString& path) { } file.close(); - LOG(INFO) << "done"; } void TextEdit::slotOpen() { |