MCPcopy Create free account
hub / github.com/TactilityProject/Tactility / getButtonPadding

Function getButtonPadding

Tactility/Source/app/launcher/Launcher.cpp:22–28  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

20static const auto LOGGER = Logger("Launcher");
21
22static uint32_t getButtonPadding(UiDensity density, uint32_t buttonSize) {
23 if (density == LVGL_UI_DENSITY_COMPACT) {
24 return 0;
25 } else {
26 return buttonSize / 8;
27 }
28}
29
30static int32_t computeButtonMargin(int32_t available_span, int32_t total_button_size) {
31 const int32_t usable = std::max<int32_t>(0, available_span - (3 * total_button_size));

Callers 3

createAppButtonMethod · 0.85
onShowMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected