forked from marktext/marktext
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathaccessor.js
More file actions
24 lines (21 loc) · 863 Bytes
/
accessor.js
File metadata and controls
24 lines (21 loc) · 863 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
import WindowManager from '../app/windowManager'
import Preference from '../preferences'
import DataCenter from '../dataCenter'
import Keybindings from '../keyboard/shortcutHandler'
import AppMenu from '../menu'
class Accessor {
/**
* @param {AppEnvironment} appEnvironment The application environment instance.
*/
constructor (appEnvironment) {
const userDataPath = appEnvironment.paths.userDataPath
this.env = appEnvironment
this.paths = appEnvironment.paths // export paths to make it better accessible
this.preferences = new Preference(this.paths)
this.dataCenter = new DataCenter(this.paths)
this.keybindings = new Keybindings(userDataPath)
this.menu = new AppMenu(this.preferences, this.keybindings, userDataPath)
this.windowManager = new WindowManager(this.menu, this.preferences)
}
}
export default Accessor