1
1
mirror of https://github.com/qvacua/vimr.git synced 2024-12-29 00:34:26 +03:00

Refactor slightly

This commit is contained in:
Tae Won Ha 2017-09-04 22:29:47 +02:00
parent ff4b2fa4c6
commit 2bddff5956
No known key found for this signature in database
GPG Key ID: E40743465B5B8B44

View File

@ -193,8 +193,19 @@ class MainWindow: NSObject,
self.workspace.toggleAllTools()
}
self.windowController.window?.delegate = self
self.workspace.delegate = self
self.addViews()
self.updateNeoVimAppearance()
self.neoVimView.delegate = self
self.open(urls: state.urlsToOpen)
self.window.setFrame(state.frame, display: true)
self.window.makeFirstResponder(self.neoVimView)
Observable
.of(self.scrollDebouncer.observable, self.cursorDebouncer.observable)
.merge()
@ -203,10 +214,6 @@ class MainWindow: NSObject,
})
.disposed(by: self.disposeBag)
self.addViews()
self.windowController.window?.delegate = self
source
.observeOn(MainScheduler.instance)
.subscribe(
@ -284,14 +291,6 @@ class MainWindow: NSObject,
}
})
.disposed(by: self.disposeBag)
self.updateNeoVimAppearance()
self.neoVimView.delegate = self
self.open(urls: state.urlsToOpen)
self.window.setFrame(state.frame, display: true)
self.window.makeFirstResponder(self.neoVimView)
}
func uuidAction(for action: Action) -> UuidAction<Action> {