minor bug fixes

This commit is contained in:
kepler155c@gmail.com
2020-04-27 22:31:57 -06:00
parent ef0886ec85
commit 8a9878b8e5
6 changed files with 26 additions and 10 deletions

View File

@@ -1,6 +1,7 @@
local ccemux = _G.ccemux
local fs = _G.fs
local peripheral = _G.peripheral
local textutils = _G.textutils
if ccemux then
-- add a System setup tab
@@ -13,4 +14,16 @@ if ccemux then
ccemux.attach(k, v.type, v.args)
end
end
_G.kernel.hook('clipboard_copy', function(_, args)
local data = args[1]
if type(data) == 'table' then
local s, m = pcall(textutils.serialize, data)
data = s and m or tostring(data)
end
if data then
ccemux.setClipboard(data)
end
end)
end

View File

@@ -214,12 +214,12 @@ nodeWizard = UI.Page {
},
sortColumn = 'slot',
help = 'Contents of inventory',
},
getDisplayValues = function(_, row)
row = Util.shallowCopy(row)
row.displayName = itemDB:getName(row)
return row
end,
},
enable = function(self)
UI.WizardPage.enable(self)
self:focusFirst()

View File

@@ -1,14 +1,14 @@
{
[ "4486006f811b88cacd5f211fd579717e29b600cd" ] = {
title = "Simple",
category = "Mining",
category = "Turtle",
icon = "\030 \0315\\\030 \031 \010\030 \0304\031f _ \030 \031c/\0315\\\010\030 \0304 ",
run = "simpleMiner.lua",
requires = 'turtle',
},
[ "da39a3ee5e6b4b0d3255bfef95601890afd80709" ] = {
title = "Scanning",
category = "Mining",
category = "Turtle",
icon = "\030 \0315\\\030 \031 \010\030 \0304\031f _ \030 \031c/\0315\\\010\030 \0304 ",
run = "scanningMiner.lua",
requires = 'turtle',

View File

@@ -120,6 +120,9 @@ function Process:new(args)
self.window = window.create(self.container, 2, 3, args.width, args.height, true)
self.terminal = self.window
self.container.setBackgroundColor(colors.black)
self.container.clear()
self.container.canvas.parent = monitor.canvas
if not monitor.canvas.children then
monitor.canvas.children = { }

View File

@@ -1,7 +1,7 @@
{
[ "377aaf9a802a23873738c0c3916282c8884c11fb" ] = {
title = "ShopLogs",
category = "Shop",
category = "Apps",
run = "Shoplogs /usr/swshop.log",
iconExt = "\0300\031f\136\140\132\0308\031 \130\030 \0318\144\010\0300\0315/\0305\031d\\\030f\0310\142\143\030 \149\010\0305\031d\\\030d\0315/\0300\031f\132\140\030 \0310\149",
},

View File

@@ -1,7 +1,6 @@
local Config = require('opus.config')
local UI = require('opus.ui')
local colors = _G.colors
local fs = _G.fs
local turtle = _G.turtle
@@ -11,9 +10,10 @@ if turtle then
local gpsTab = UI.Tab {
title = 'Home',
description = 'Turtle home location',
noFill = true,
labelText = UI.Text {
x = 3, ex = -3, y = 2,
textColor = colors.yellow,
textColor = 'yellow',
value = 'On restart, return to this location'
},
grid = UI.Grid {