mirror of
https://github.com/alexhopeoconnor/firmware.git
synced 2026-10-22 11:17:49 +10:00
Remove dead code (#11082)
Removed: - MessageStore::addFromPacket and addFromString, superseded by tryAddFromPacket - GeoCoord rangeRadiansToMeters, distanceTo, bearingTo - Router::rawSend, declared virtual with no override and no caller - ContentHandler handleHotspot, handleFs, handleAdminSettings, handleAdminSettingsApply, handleDeleteFsContent and their commented route registrations, plus the now unreachable htmlDeleteDir and the handleUpdateFs declaration that had no definition - ContentHelper replaceAll - OnScreenKeyboardModule popup chain: showPopup, clearPopup, drawPopup, drawPopupOverlay and their state, unreachable since the frame based UI was replaced by baseUI - DebugRenderer drawDebugInfoTrampoline, drawDebugInfoSettingsTrampoline and the orphaned drawFrameSettings - NodeListRenderer calculateMaxScroll, drawColumns and a stale extern haveGlyphs declaration with no definition - UIRenderer::haveGlyphs, Screen::blink, NotificationRenderer::showKeyboardMessagePopupWithTitle, VirtualKeyboard::getInputText - InkHUD touchNavLeft, touchNavRight, Applet::getActiveNodeCount, ThreadedMessageApplet::saveMessagesToFlash - TwoButton::setHandlerUp, TwoButtonExtended setHandlerUp, setJoystickDownHandlers, setJoystickUpHandlers - CannedMessageModule LaunchRepeatDestination, isCharInputAllowed, hasMessages - TrafficManagementModule resetStats, recordRouterHopPreserved, saturatingIncrement - UnitConversions::MetersPerSecondToMilesPerHour - EncryptedStorage getSessionRemainingSeconds - BMI270Sensor::writeRegisters, GPS::hasFlow, FSCommon copyFile, SerialConsole consolePrintf, buzz playLongPressLeadUp, memGet displayPercentHeapFree
This commit is contained in:
@@ -1078,16 +1078,6 @@ bool isSessionExpired()
|
||||
return (millis() - s_sessionStartedMs) > s_sessionMaxMs;
|
||||
}
|
||||
|
||||
uint32_t getSessionRemainingSeconds()
|
||||
{
|
||||
if (s_sessionMaxMs == 0)
|
||||
return 0;
|
||||
uint32_t elapsedMs = millis() - s_sessionStartedMs;
|
||||
if (elapsedMs >= s_sessionMaxMs)
|
||||
return 0;
|
||||
return (s_sessionMaxMs - elapsedMs) / 1000UL;
|
||||
}
|
||||
|
||||
uint8_t consumeSessionBoot()
|
||||
{
|
||||
if (s_bootsRemaining == 0) {
|
||||
|
||||
@@ -243,10 +243,6 @@ void setSession(uint32_t maxSeconds);
|
||||
/// from the main loop on a low-frequency tick.
|
||||
bool isSessionExpired();
|
||||
|
||||
/// Seconds remaining in the current session. 0 if no timer is set, or if
|
||||
/// the timer has expired (use isSessionExpired() to distinguish).
|
||||
uint32_t getSessionRemainingSeconds();
|
||||
|
||||
/// Consume one boot from the on-flash token (the rollback ledger) and
|
||||
/// re-arm the session timer in place - no reboot. Called from the main
|
||||
/// loop when a session expires AND there is still budget. Decrements
|
||||
|
||||
Reference in New Issue
Block a user