allow ctrl+f from diff sel, fix input focus

This commit is contained in:
Bui 2022-02-25 19:07:53 +00:00
parent 6c6da320e1
commit 24f02393eb

View File

@ -474,7 +474,10 @@ class SongSelect{
this.playBgm(false) this.playBgm(false)
} }
}else if(this.state.screen === "difficulty"){ }else if(this.state.screen === "difficulty"){
if(name === "confirm"){ if(event && event.keyCode && event.keyCode === 70 && ctrl){
this.displaySearch()
event.preventDefault()
}else if(name === "confirm"){
if(this.selectedDiff === 0){ if(this.selectedDiff === 0){
this.toSongSelect() this.toSongSelect()
}else if(this.selectedDiff === 1){ }else if(this.selectedDiff === 1){
@ -2771,7 +2774,10 @@ class SongSelect{
this.playSound("se_pause") this.playSound("se_pause")
loader.screen.appendChild(this.search.div) loader.screen.appendChild(this.search.div)
this.setSearchTip() this.setSearchTip()
setTimeout(() => {
this.search.input.focus() this.search.input.focus()
}, 10)
} }
removeSearch(byUser=false){ removeSearch(byUser=false){