aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/PreviewCursor.tsx
diff options
context:
space:
mode:
authortschicke-brown <tyler_schicke@brown.edu>2019-05-09 19:25:58 -0400
committerGitHub <noreply@github.com>2019-05-09 19:25:58 -0400
commit6691c55623fff5194b5fd1a830096e3925281301 (patch)
tree2458827f32530528e306821db8fd37ced27ba7ef /src/client/views/PreviewCursor.tsx
parent39fd912fd4cd33f30a943290295a59992b9868eb (diff)
parente98dd0bf2ec4354daf95cc0d104cab1193fd4160 (diff)
Merge pull request #128 from browngraphicslab/cursor_refactor
Cursor refactor
Diffstat (limited to 'src/client/views/PreviewCursor.tsx')
-rw-r--r--src/client/views/PreviewCursor.tsx4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/views/PreviewCursor.tsx b/src/client/views/PreviewCursor.tsx
index 4ac4b9c95..78024a58c 100644
--- a/src/client/views/PreviewCursor.tsx
+++ b/src/client/views/PreviewCursor.tsx
@@ -17,7 +17,7 @@ export class PreviewCursor extends React.Component<{}> {
constructor(props: any) {
super(props);
- document.addEventListener("keydown", this.onKeyPress)
+ document.addEventListener("keydown", this.onKeyPress);
}
@action
@@ -27,7 +27,7 @@ export class PreviewCursor extends React.Component<{}> {
// the keyPress here.
//if not these keys, make a textbox if preview cursor is active!
if (e.key.startsWith("F") && !e.key.endsWith("F")) {
- } else if (e.key != "Escape" && e.key != "Alt" && e.key != "Shift" && e.key != "Meta" && e.key != "Control" && !e.defaultPrevented && !(e as any).DASHFormattedTextBoxHandled) {
+ } else if (e.key !== "Escape" && e.key !== "Alt" && e.key !== "Shift" && e.key !== "Meta" && e.key !== "Control" && !e.defaultPrevented && !(e as any).DASHFormattedTextBoxHandled) {
if ((!e.ctrlKey && !e.metaKey) || e.key === "v" || e.key === "q") {
PreviewCursor.Visible && PreviewCursor._onKeyPress && PreviewCursor._onKeyPress(e);
PreviewCursor.Visible = false;