mirror of
https://github.com/Mezeporta/Erupe.git
synced 2026-02-04 17:22:16 +01:00
Add config button to launcher
This commit is contained in:
@@ -9,7 +9,7 @@ function checkAuthResult() {
|
|||||||
var loginResult = window.external.getLastAuthResult();
|
var loginResult = window.external.getLastAuthResult();
|
||||||
console.log('|' + loginResult + '|');
|
console.log('|' + loginResult + '|');
|
||||||
if(loginResult == "AUTH_PROGRESS") {
|
if(loginResult == "AUTH_PROGRESS") {
|
||||||
setTimeout(checkAuthResult, 1500);
|
setTimeout(checkAuthResult, 500);
|
||||||
} else if (loginResult == "AUTH_SUCCESS") {
|
} else if (loginResult == "AUTH_SUCCESS") {
|
||||||
window.location.href = 'charsel.html'
|
window.location.href = 'charsel.html'
|
||||||
} else {
|
} else {
|
||||||
@@ -18,7 +18,6 @@ function checkAuthResult() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
$(function() {
|
$(function() {
|
||||||
|
|
||||||
// Login form submission.
|
// Login form submission.
|
||||||
$("#loginform").submit(function(e){
|
$("#loginform").submit(function(e){
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
@@ -35,4 +34,12 @@ $(function() {
|
|||||||
checkAuthResult();
|
checkAuthResult();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// Config button.
|
||||||
|
$("#configButton").click(function(){
|
||||||
|
try{
|
||||||
|
window.external.openMhlConfig();
|
||||||
|
} catch(e){
|
||||||
|
createErrorAlert("Error on openMhlConfig: " + e);
|
||||||
|
}
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -57,6 +57,7 @@
|
|||||||
<input type="password" class="form-control" id="password" placeholder="Password">
|
<input type="password" class="form-control" id="password" placeholder="Password">
|
||||||
</div>
|
</div>
|
||||||
<button id="submitButton" type="submit" class="btn btn-primary">Submit</button>
|
<button id="submitButton" type="submit" class="btn btn-primary">Submit</button>
|
||||||
|
<button id="configButton" class="btn btn-secondary">Config</button>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user