Skip to content
This repository has been archived by the owner on Mar 26, 2024. It is now read-only.

remove extra character when copy/paste #92

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

suixy
Copy link

@suixy suixy commented Oct 14, 2021

For PRJ-380 and PRJ-426, I believe that we can merely send copy/paste events to projector-server without the extra "c" and "v", aiming at avoiding the useless character displayed in the terminal.

@SerVB
Copy link
Member

SerVB commented Oct 14, 2021

Thank you for the PR. I can't review it well right now, I hope I will return to it in two weeks or so.

But I've checked briefly and I think there is a better place for blocking the press event:

if (type == ClientKeyEvent.KeyEventType.DOWN && message.code !in invisibleCodes) {
// we've blocked special keys like Tab to stop the browser react
// but we also disabled generation of PRESS events
// so need to send them manually
this@fireKeyEvent(ClientKeyPressEvent(
timeStamp = message.timeStamp,
char = message.char,
modifiers = message.modifiers,
))
}

Anyway, need to check if it's the same behavior as Swing does when pressing copy and paste keystrokes. If Swing sends a KEY_TYPED event, then we should do it too and solve PRJ-380 and PRJ-426 in some other way...

@codecov-commenter
Copy link

Codecov Report

Merging #92 (d2c155a) into master (ead58ab) will decrease coverage by 0.00%.
The diff coverage is 0.00%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master      #92      +/-   ##
============================================
- Coverage     22.18%   22.18%   -0.01%     
  Complexity       57       57              
============================================
  Files           160      160              
  Lines          4142     4143       +1     
  Branches        576      577       +1     
============================================
  Hits            919      919              
- Misses         3201     3202       +1     
  Partials         22       22              
Impacted Files Coverage Δ
...etbrains/projector/client/web/state/ClientState.kt 0.00% <0.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update ead58ab...d2c155a. Read the comment docs.

@SerVB SerVB self-requested a review October 28, 2021 10:34
@SerVB
Copy link
Member

SerVB commented Nov 10, 2021

Well, looks like I'm stuck with rendering-related tickets now and I can't spend time on digging into keyboard problems in the near future.

As I noted before, this PR can't be accepted as is: some changes are required at least, and some research is needed too.

So let me postpone the review of this PR.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants