mirror of
https://github.com/meshcore-dev/MeshCore.git
synced 2026-04-20 22:13:47 +00:00
gps_page: enable if gps enabled
This commit is contained in:
parent
76aa7cf488
commit
db7635102d
2 changed files with 4 additions and 5 deletions
|
|
@ -75,7 +75,7 @@ class HomeScreen : public UIScreen {
|
||||||
RADIO,
|
RADIO,
|
||||||
BLUETOOTH,
|
BLUETOOTH,
|
||||||
ADVERT,
|
ADVERT,
|
||||||
#if UI_GPS_PAGE == 1
|
#if ENV_INCLUDE_GPS == 1
|
||||||
GPS,
|
GPS,
|
||||||
#endif
|
#endif
|
||||||
#if UI_SENSORS_PAGE == 1
|
#if UI_SENSORS_PAGE == 1
|
||||||
|
|
@ -173,7 +173,7 @@ public:
|
||||||
|
|
||||||
// curr page indicator
|
// curr page indicator
|
||||||
int y = 14;
|
int y = 14;
|
||||||
int x = display.width() / 2 - 25;
|
int x = display.width() / 2 - 5 * (HomePage::Count-1);
|
||||||
for (uint8_t i = 0; i < HomePage::Count; i++, x += 10) {
|
for (uint8_t i = 0; i < HomePage::Count; i++, x += 10) {
|
||||||
if (i == _page) {
|
if (i == _page) {
|
||||||
display.fillRect(x-1, y-1, 3, 3);
|
display.fillRect(x-1, y-1, 3, 3);
|
||||||
|
|
@ -253,7 +253,7 @@ public:
|
||||||
display.setColor(DisplayDriver::GREEN);
|
display.setColor(DisplayDriver::GREEN);
|
||||||
display.drawXbm((display.width() - 32) / 2, 18, advert_icon, 32, 32);
|
display.drawXbm((display.width() - 32) / 2, 18, advert_icon, 32, 32);
|
||||||
display.drawTextCentered(display.width() / 2, 64 - 11, "advert: " PRESS_LABEL);
|
display.drawTextCentered(display.width() / 2, 64 - 11, "advert: " PRESS_LABEL);
|
||||||
#if UI_GPS_PAGE == 1
|
#if ENV_INCLUDE_GPS == 1
|
||||||
} else if (_page == HomePage::GPS) {
|
} else if (_page == HomePage::GPS) {
|
||||||
LocationProvider* nmea = sensors.getLocationProvider();
|
LocationProvider* nmea = sensors.getLocationProvider();
|
||||||
int y = 18;
|
int y = 18;
|
||||||
|
|
@ -408,7 +408,7 @@ public:
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
#if UI_GPS_PAGE == 1
|
#if ENV_INCLUDE_GPS == 1
|
||||||
if (c == KEY_ENTER && _page == HomePage::GPS) {
|
if (c == KEY_ENTER && _page == HomePage::GPS) {
|
||||||
_task->toggleGPS();
|
_task->toggleGPS();
|
||||||
return true;
|
return true;
|
||||||
|
|
|
||||||
|
|
@ -55,7 +55,6 @@ build_flags = ${WioTrackerL1Eink.build_flags}
|
||||||
; -D MESH_DEBUG=1
|
; -D MESH_DEBUG=1
|
||||||
-D UI_RECENT_LIST_SIZE=6
|
-D UI_RECENT_LIST_SIZE=6
|
||||||
-D UI_SENSORS_PAGE=1
|
-D UI_SENSORS_PAGE=1
|
||||||
-D UI_GPS_PAGE=1
|
|
||||||
build_src_filter = ${WioTrackerL1Eink.build_src_filter}
|
build_src_filter = ${WioTrackerL1Eink.build_src_filter}
|
||||||
+<helpers/nrf52/SerialBLEInterface.cpp>
|
+<helpers/nrf52/SerialBLEInterface.cpp>
|
||||||
+<helpers/ui/MomentaryButton.cpp>
|
+<helpers/ui/MomentaryButton.cpp>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue