diff --git a/apps/shared/editable_cell_table_view_controller.h b/apps/shared/editable_cell_table_view_controller.h index bf7d4f5ac..9e7775c12 100644 --- a/apps/shared/editable_cell_table_view_controller.h +++ b/apps/shared/editable_cell_table_view_controller.h @@ -20,9 +20,10 @@ public: KDCoordinate rowHeight(int j) override; void viewWillAppear() override; void didBecomeFirstResponder() override; +protected: + static constexpr KDCoordinate k_cellHeight = 20; private: TextFieldDelegateApp * textFieldDelegateApp() override; - static constexpr KDCoordinate k_cellHeight = 20; virtual bool cellAtLocationIsEditable(int columnIndex, int rowIndex) = 0; virtual bool setDataAtLocation(double floatBody, int columnIndex, int rowIndex) = 0; virtual double dataAtLocation(int columnIndex, int rowIndex) = 0; diff --git a/apps/shared/store_controller.h b/apps/shared/store_controller.h index 98673122c..d29f00cf2 100644 --- a/apps/shared/store_controller.h +++ b/apps/shared/store_controller.h @@ -48,7 +48,7 @@ protected: static constexpr KDCoordinate k_cellWidth = 116; static constexpr KDCoordinate k_margin = 8; static constexpr KDCoordinate k_scrollBarMargin = Metric::CommonRightMargin; - constexpr static int k_maxNumberOfEditableCells = 22 * DoublePairStore::k_numberOfSeries; + constexpr static int k_maxNumberOfEditableCells = (Ion::Display::Width/k_cellWidth+2) * ((Ion::Display::Height - Metric::TitleBarHeight - Metric::TabHeight)/k_cellHeight+2); constexpr static int k_numberOfTitleCells = 4; static constexpr int k_titleCellType = 0; static constexpr int k_editableCellType = 1;