Skip to content

Commit

Permalink
Add files via upload
Browse files Browse the repository at this point in the history
  • Loading branch information
ic005k authored May 5, 2022
1 parent 1b314db commit 7e8f463
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions mainwindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
#endif
#include "methods.h"

QString CurVersion = "1.1.64";
QString CurVersion = "1.1.65";
QString fileName, curFile, dragFileName, findStr, findPath, search_string,
curFindFile;

Expand Down Expand Up @@ -5005,24 +5005,25 @@ void MainWindow::closeEvent(QCloseEvent* event) {

// Save tabs
int tabcount = ui->tabWidget_textEdit->tabBar()->count();
int m = 0;
for (int i = 0; i < tabcount; i++) {
pWidget = ui->tabWidget_textEdit->widget(i);
lblCurrentFile = (QLabel*)pWidget->children().at(lblNumber);
if (lblCurrentFile->text() == tr("untitled") + ".dsl") {
tabcount--;
} else {
getCurrentEditor(i)->getCursorPosition(&rowDrag, &colDrag);
vs = getCurrentEditor(i)->verticalScrollBar()->sliderPosition();
hs = getCurrentEditor(i)->horizontalScrollBar()->sliderPosition();

Reg.setValue(QString::number(i) + "/" + "file", lblCurrentFile->text());
Reg.setValue(QString::number(i) + "/" + "row", rowDrag);
Reg.setValue(QString::number(i) + "/" + "col", colDrag);
Reg.setValue(QString::number(i) + "/" + "vs", vs);
Reg.setValue(QString::number(i) + "/" + "hs", hs);
Reg.setValue(QString::number(m) + "/" + "file", lblCurrentFile->text());
Reg.setValue(QString::number(m) + "/" + "row", rowDrag);
Reg.setValue(QString::number(m) + "/" + "col", colDrag);
Reg.setValue(QString::number(m) + "/" + "vs", vs);
Reg.setValue(QString::number(m) + "/" + "hs", hs);
m++;
}
}
Reg.setValue("count", tabcount);
Reg.setValue("count", m);

// Save scribble board
QSaveFile fileScribble(QDir::homePath() + "/.config/" + strAppName +
Expand Down

0 comments on commit 7e8f463

Please sign in to comment.