mirror of
https://github.com/qvacua/vimr.git
synced 2024-11-28 02:54:31 +03:00
Wip
This commit is contained in:
parent
f0c329efc3
commit
02d6ef4ced
@ -91,14 +91,15 @@ class OpenQuicklyWindow: NSObject,
|
|||||||
private func subscription(_ state: StateType) {
|
private func subscription(_ state: StateType) {
|
||||||
self.updateRootUrls(state: state)
|
self.updateRootUrls(state: state)
|
||||||
|
|
||||||
guard state.openQuickly.open,
|
guard state.openQuickly.open, let curWinState = state.currentMainWindow else {
|
||||||
let curWinState = state.currentMainWindow else {
|
|
||||||
self.windowController.close()
|
self.windowController.close()
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
let windowIsOpen = self.window.isKeyWindow
|
||||||
|
|
||||||
// The window is open and the user changed the setting
|
// The window is open and the user changed the setting
|
||||||
if self.usesVcsIgnores != curWinState.usesVcsIgnores && self.window.isKeyWindow {
|
if self.usesVcsIgnores != curWinState.usesVcsIgnores && windowIsOpen {
|
||||||
self.usesVcsIgnores = curWinState.usesVcsIgnores
|
self.usesVcsIgnores = curWinState.usesVcsIgnores
|
||||||
|
|
||||||
self.reset()
|
self.reset()
|
||||||
@ -107,12 +108,14 @@ class OpenQuicklyWindow: NSObject,
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
if self.window.isKeyWindow {
|
if windowIsOpen {
|
||||||
// already open, so do nothing
|
// already open, so do nothing
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
self.usesVcsIgnores = curWinState.usesVcsIgnores
|
self.usesVcsIgnores = curWinState.usesVcsIgnores
|
||||||
|
|
||||||
|
// TODO: read global vcs ignores
|
||||||
self.prepareSearch(curWinState: curWinState)
|
self.prepareSearch(curWinState: curWinState)
|
||||||
self.windowController.showWindow(nil)
|
self.windowController.showWindow(nil)
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user