Polish launcher main and library flows
This commit is contained in:
@@ -227,10 +227,10 @@ async function renderInstallView(){
|
||||
const detailButton = document.createElement('button')
|
||||
detailButton.className = 'launcherSecondaryButton'
|
||||
detailButton.textContent = '자세히 보기'
|
||||
detailButton.addEventListener('click', (event) => {
|
||||
detailButton.addEventListener('click', async (event) => {
|
||||
event.stopPropagation()
|
||||
selectProfile(profile.id)
|
||||
renderInstallView()
|
||||
await renderInstallView()
|
||||
})
|
||||
|
||||
const installButton = document.createElement('button')
|
||||
@@ -248,6 +248,9 @@ async function renderInstallView(){
|
||||
if(typeof refreshSelectedProfileButton === 'function'){
|
||||
refreshSelectedProfileButton()
|
||||
}
|
||||
if(typeof refreshServerStatus === 'function'){
|
||||
refreshServerStatus(true)
|
||||
}
|
||||
selectProfile(profile.id)
|
||||
await renderInstallView()
|
||||
if(typeof refreshLibraryView === 'function'){
|
||||
@@ -270,9 +273,9 @@ async function renderInstallView(){
|
||||
main.appendChild(description)
|
||||
row.appendChild(main)
|
||||
row.appendChild(actions)
|
||||
row.addEventListener('click', () => {
|
||||
row.addEventListener('click', async () => {
|
||||
selectProfile(profile.id)
|
||||
renderInstallView()
|
||||
await renderInstallView()
|
||||
})
|
||||
installCatalogList.appendChild(row)
|
||||
}
|
||||
@@ -300,22 +303,10 @@ async function renderInstallView(){
|
||||
}
|
||||
}
|
||||
|
||||
document.getElementById('installOpenSettingsButton').addEventListener('click', async () => {
|
||||
await prepareSettings()
|
||||
switchView(getCurrentView(), VIEWS.settings)
|
||||
})
|
||||
|
||||
document.getElementById('installBackButton').addEventListener('click', () => {
|
||||
switchView(getCurrentView(), VIEWS.landing)
|
||||
})
|
||||
|
||||
document.getElementById('installBackToLibraryButton').addEventListener('click', async () => {
|
||||
if(typeof refreshLibraryView === 'function'){
|
||||
await refreshLibraryView()
|
||||
}
|
||||
switchView(getCurrentView(), VIEWS.library)
|
||||
})
|
||||
|
||||
document.getElementById('installDetailOpenLibraryButton').addEventListener('click', async () => {
|
||||
if(typeof refreshLibraryView === 'function'){
|
||||
await refreshLibraryView()
|
||||
|
||||
Reference in New Issue
Block a user