-
Notifications
You must be signed in to change notification settings - Fork 10.3k
[Editor] Use serialized data when copying/pasting #15179
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
r=me, with comments addressed and passing tests; thank you!
src/display/editor/freetext.js
Outdated
const editor = super.deserialize(data, parent); | ||
|
||
editor.#fontSize = data.fontSize; | ||
editor.color = Util.makeHexColor(...data.color); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this correct, since I'd expect the following?
editor.color = Util.makeHexColor(...data.color); | |
editor.#color = Util.makeHexColor(...data.color); |
src/display/editor/tools.js
Outdated
@@ -285,35 +285,46 @@ class KeyboardManager { | |||
*/ | |||
class ClipboardManager { | |||
constructor() { | |||
this.element = null; | |||
this.elements = null; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Slightly unrelated to this patch, but should this property perhaps be private instead?
- in using the global clipboard, it'll be possible to copy from a pdf and paste in an other one; - it'll allow to edit a previously created annotation; - copy the editors in the current page.
/botio integrationtest |
From: Bot.io (Linux m4)ReceivedCommand cmd_integrationtest from @calixteman received. Current queue size: 0 Live output at: http://54.241.84.105:8877/c11c5ec7a7dca00/output.txt |
From: Bot.io (Windows)ReceivedCommand cmd_integrationtest from @calixteman received. Current queue size: 1 Live output at: http://54.193.163.58:8877/96e7d8857b17195/output.txt |
From: Bot.io (Linux m4)SuccessFull output at http://54.241.84.105:8877/c11c5ec7a7dca00/output.txt Total script time: 4.49 mins
|
From: Bot.io (Windows)FailedFull output at http://54.193.163.58:8877/96e7d8857b17195/output.txt Total script time: 10.81 mins
|
/botio unittest |
From: Bot.io (Linux m4)ReceivedCommand cmd_unittest from @calixteman received. Current queue size: 0 Live output at: http://54.241.84.105:8877/b1168438e6f0fb9/output.txt |
From: Bot.io (Windows)ReceivedCommand cmd_unittest from @calixteman received. Current queue size: 1 Live output at: http://54.193.163.58:8877/8b305972faace3f/output.txt |
From: Bot.io (Linux m4)SuccessFull output at http://54.241.84.105:8877/b1168438e6f0fb9/output.txt Total script time: 3.11 mins
|
From: Bot.io (Windows)SuccessFull output at http://54.193.163.58:8877/8b305972faace3f/output.txt Total script time: 9.66 mins
|
pdf and paste in an other one;