|
|
@ -1,6 +1,7 @@ |
|
|
|
const DEFAULT_USER = "defaultUser"; |
|
|
|
const DEFAULT_USER = "defaultUser"; |
|
|
|
const DEFAULT_SESSION = "defaultSession"; |
|
|
|
const DEFAULT_SESSION = "defaultSession"; |
|
|
|
const DEFAULT_WALLPAPPER = "defaultWallpapper"; |
|
|
|
const DEFAULT_WALLPAPPER = "defaultWallpapper"; |
|
|
|
|
|
|
|
const WALLPAPPER_ELEMENT = "wallpappers"; |
|
|
|
|
|
|
|
|
|
|
|
function togglePasswordVisibility() { |
|
|
|
function togglePasswordVisibility() { |
|
|
|
var passwd = document.getElementById("password"); |
|
|
|
var passwd = document.getElementById("password"); |
|
|
@ -19,7 +20,7 @@ function updateDefaults(user, session) { |
|
|
|
localStorage.setItem(DEFAULT_USER, user) |
|
|
|
localStorage.setItem(DEFAULT_USER, user) |
|
|
|
localStorage.setItem(DEFAULT_SESSION, session) |
|
|
|
localStorage.setItem(DEFAULT_SESSION, session) |
|
|
|
|
|
|
|
|
|
|
|
var wallpapper = document.getElementById("wallpappers").value |
|
|
|
var wallpapper = document.getElementById(WALLPAPPER_ELEMENT).value |
|
|
|
if(wallpapper) { |
|
|
|
if(wallpapper) { |
|
|
|
localStorage.setItem(DEFAULT_WALLPAPPER, wallpapper) |
|
|
|
localStorage.setItem(DEFAULT_WALLPAPPER, wallpapper) |
|
|
|
} |
|
|
|
} |
|
|
@ -106,7 +107,7 @@ function initGreeter() { |
|
|
|
select.appendChild(btn) |
|
|
|
select.appendChild(btn) |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
const wallpappers = document.getElementById('wallpappers'); |
|
|
|
const wallpappers = document.getElementById(WALLPAPPER_ELEMENT); |
|
|
|
|
|
|
|
|
|
|
|
wallpappers.addEventListener('change', (event) => { |
|
|
|
wallpappers.addEventListener('change', (event) => { |
|
|
|
updateWallpapper(event.target.value); |
|
|
|
updateWallpapper(event.target.value); |
|
|
|