Skip to content

Commit f641db9

Browse files
committed
remove unused scroll method
1 parent f6117c1 commit f641db9

File tree

2 files changed

+0
-20
lines changed

2 files changed

+0
-20
lines changed

src/core/OSTreeTUI.cpp

-13
Original file line numberDiff line numberDiff line change
@@ -289,19 +289,6 @@ void OSTreeTUI::adjustScrollToSelectedCommit() {
289289
scrollOffset = std::min(min, newScroll);
290290
}
291291

292-
void OSTreeTUI::adjustSelectedCommitToScroll() {
293-
int yToFit = selectedCommit * CommitRender::COMMIT_WINDOW_HEIGHT;
294-
int maxVal = screen.dimy() - 4 - CommitRender::COMMIT_WINDOW_HEIGHT - scrollOffset;
295-
int minVal = -scrollOffset;
296-
297-
if (yToFit > maxVal) {
298-
--selectedCommit;
299-
}
300-
if (yToFit < minVal) {
301-
++selectedCommit;
302-
}
303-
}
304-
305292
// SETTER & non-const GETTER
306293
void OSTreeTUI::setPromotionBranch(std::string promotionBranch) {
307294
this->promotionBranch = promotionBranch;

src/core/OSTreeTUI.hpp

-7
Original file line numberDiff line numberDiff line change
@@ -76,13 +76,6 @@ class OSTreeTUI {
7676
*/
7777
void adjustScrollToSelectedCommit();
7878

79-
/**
80-
* @brief Adjust selected commit to fit to scroll commit (minimal adjustment of last selected)
81-
*
82-
* Warning: Currently only adjusts by 1
83-
*/
84-
void adjustSelectedCommitToScroll();
85-
8679
public:
8780
// "SETTER" & non-const GETTER
8881
void setPromotionBranch(std::string promotionBranch);

0 commit comments

Comments
 (0)