attrib "key" -> "shortcut", also fix #20

This commit is contained in:
airstruck
2016-01-03 01:18:04 -05:00
parent 3abcce1615
commit c73833337e
12 changed files with 98 additions and 90 deletions

View File

@@ -198,13 +198,10 @@ This color is used to indicate the selected range of text.
--]]--
self:defineAttribute('highlight')
local defaultHighlight = { 0x80, 0x80, 0x80, 0x80 }
--[[--
@section end
--]]--
if not self.highlight then
self.highlight = { 0x80, 0x80, 0x80, 0x80 }
end
self.scrollX = 0
@@ -286,7 +283,7 @@ This color is used to indicate the selected range of text.
if self.focused then
-- draw highlighted selection
Backend.setColor(self.highlight)
Backend.setColor(self.highlight or defaultHighlight)
Backend.drawRectangle('fill', startX, y, width, height)
-- draw cursor selection
if Backend.getTime() % 2 < 1.75 then