mirror of
https://github.com/LDDestroier/CC/
synced 2025-01-08 08:20:27 +00:00
Fixed copy/cut with scrolling
This commit is contained in:
parent
4a58601ab0
commit
502e1771da
6
pain.lua
6
pain.lua
@ -2118,6 +2118,10 @@ local selectRegion = function()
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
local output = {}
|
local output = {}
|
||||||
|
pos[1][1] = pos[1][1] + paint.scrollX
|
||||||
|
pos[2][1] = pos[1][1] + paint.scrollX
|
||||||
|
pos[1][2] = pos[1][1] + paint.scrollY
|
||||||
|
pos[2][2] = pos[1][1] + paint.scrollY
|
||||||
for k,v in pairs(paintEncoded[frame]) do
|
for k,v in pairs(paintEncoded[frame]) do
|
||||||
if v.x >= pos[1][1] and v.x <= pos[2][1] then
|
if v.x >= pos[1][1] and v.x <= pos[2][1] then
|
||||||
if v.y >= pos[1][2] and v.y <= pos[2][2] then
|
if v.y >= pos[1][2] and v.y <= pos[2][2] then
|
||||||
@ -2178,7 +2182,7 @@ end
|
|||||||
local editCut = function()
|
local editCut = function()
|
||||||
local board = bottomPrompt("Cut to board: ")
|
local board = bottomPrompt("Cut to board: ")
|
||||||
renderAllPAIN()
|
renderAllPAIN()
|
||||||
renderBottomBar("Select region to copy.")
|
renderBottomBar("Select region to cut.")
|
||||||
local selectedDots, x1, y1, x2, y2 = selectRegion()
|
local selectedDots, x1, y1, x2, y2 = selectRegion()
|
||||||
theClipboard[board] = selectedDots
|
theClipboard[board] = selectedDots
|
||||||
local dot
|
local dot
|
||||||
|
Loading…
Reference in New Issue
Block a user