style: Adjust button layout in drawDetail function for improved UI organization

This commit is contained in:
MayaTheShy
2026-02-20 02:47:16 -05:00
parent 86a6db04ac
commit 7dae800eed

View File

@@ -244,8 +244,8 @@ local function drawDetail()
print(" Empty") print(" Empty")
end end
-- Action buttons -- Action buttons (row 1: explore/home/stop)
local btnY = h - 7 local btnY = h - 10
addButton(1, btnY, 8, 2, "EXPLORE", function() addButton(1, btnY, 8, 2, "EXPLORE", function()
sendCommand(turtle.turtleID, "explore") sendCommand(turtle.turtleID, "explore")
end, colors.green) end, colors.green)
@@ -258,7 +258,8 @@ local function drawDetail()
sendCommand(turtle.turtleID, "stop") sendCommand(turtle.turtleID, "stop")
end, colors.red) end, colors.red)
btnY = h - 4 -- Row 2: manual/modes/setHome
btnY = h - 7
addButton(1, btnY, 8, 2, "MANUAL", function() addButton(1, btnY, 8, 2, "MANUAL", function()
viewMode = "manual" viewMode = "manual"
sendCommand(turtle.turtleID, "manual") sendCommand(turtle.turtleID, "manual")
@@ -272,7 +273,8 @@ local function drawDetail()
sendCommand(turtle.turtleID, "setHome") sendCommand(turtle.turtleID, "setHome")
end, colors.blue) end, colors.blue)
btnY = h - 7 -- Row 3: equip/rename
btnY = h - 4
addButton(1, btnY, 8, 2, "EQUIP L", function() addButton(1, btnY, 8, 2, "EQUIP L", function()
-- Send eval to equip left -- Send eval to equip left
modem.transmit(CHANNEL_SEND, CHANNEL_RECEIVE, { modem.transmit(CHANNEL_SEND, CHANNEL_RECEIVE, {
@@ -433,10 +435,6 @@ local function drawManual()
}) })
end, colors.cyan) end, colors.cyan)
addButton(19, h - 3, 7, 2, "INFO", function()
sendCommand(turtle.turtleID, "status")
end, colors.lightBlue)
addButton(1, h, 12, 1, "< BACK", function() addButton(1, h, 12, 1, "< BACK", function()
viewMode = "detail" viewMode = "detail"
end, colors.gray) end, colors.gray)