-
Notifications
You must be signed in to change notification settings - Fork 22
Expand file tree
/
Copy pathnoteViewObject.ts
More file actions
46 lines (43 loc) · 1.01 KB
/
noteViewObject.ts
File metadata and controls
46 lines (43 loc) · 1.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
import {Note} from "../../../models/note.model";
import {EditorView} from "./editor.view";
export class NoteViewObject {
key: string;
constructor(
private editorView: EditorView,
public note: Note,
) {
this.key = NoteViewObject.generateKey(editorView, note);
}
static generateKey(editorView: EditorView, n: Note): string {
return (
"LC" +
editorView.getNetzgrafikLoadCounter() +
"#" +
n.getId() +
"@" +
n.getPositionX() +
"_" +
n.getPositionY() +
"_" +
n.getHeight() +
"_" +
n.getWidth() +
"_" +
n.getText() +
"_" +
n.getTitle() +
"_" +
n.selected() +
"_" +
editorView.getNoteLayerIndex(n.getId()) +
"_" +
editorView.isFilterNotesEnabled() +
"_" +
editorView.isTemporaryDisableFilteringOfItemsInViewEnabled() +
"_" +
editorView.getLevelOfDetail() +
"_" +
editorView.trainrunSectionPreviewLineView.getVariantIsWritable()
);
}
}