diff options
| Commit | 3b200a7a4737086de7723bfe9dbb000bd2eba9ec (patch) | |
|---|---|---|
| Author | 2022-06-14 12:49:04 +0300 | |
| Committer | 2022-06-14 12:49:04 +0300 | |
| Files | f21a9074e865ebd3acea169e5bb328a9b26402d7 /src | |
| FMI-OOP-P2_Tables-3b200a7a4737086de7723bfe9dbb000bd2eba9ec.tar FMI-OOP-P2_Tables-3b200a7a4737086de7723bfe9dbb000bd2eba9ec.tar.gz FMI-OOP-P2_Tables-3b200a7a4737086de7723bfe9dbb000bd2eba9ec.zip | ||
| Parent | 983aab300faacd145bf552b450874c743ecab079 (diff) | |
Autocommit at 14.06.2022 @ 12:49
2 files changed, 3 insertions, 2 deletions
| -rw-r--r-- | src/Models/CellFormula.cpp | 1 | ||||
| -rw-r--r-- | src/UserInterface/UserInterface.cpp | 4 |
diff --git a/src/Models/CellFormula.cpp b/src/Models/CellFormula.cpp index 19bea60..f26ce0e 100644 --- a/src/Models/CellFormula.cpp +++ b/src/Models/CellFormula.cpp @@ -95,6 +95,7 @@ void O(const char*& str, char& buffer) { void CellFormula::parseAndSetValue(const char* str) { rawFormula = String(str); + formula.clear(); Pair<int, int> loc; char currOp = 0; diff --git a/src/UserInterface/UserInterface.cpp b/src/UserInterface/UserInterface.cpp index 315b7e4..99b1d2f 100644 --- a/src/UserInterface/UserInterface.cpp +++ b/src/UserInterface/UserInterface.cpp @@ -91,7 +91,7 @@ void UserInterface::com_edit(const char* params) { return; } - unsigned row = atoi(++params); + unsigned row = atoi(++params) - 1; while (*params != 'C') { if (*params == '\0') { printLine("Error: End of line reached. Expected row number."); @@ -104,7 +104,7 @@ void UserInterface::com_edit(const char* params) { params++; } - unsigned col = atoi(++params); + unsigned col = atoi(++params) - 1; while (*params != ' ') { if (*params == '\0') { printLine("Error: End of line reached. Expected columns number."); |
