mirror of
https://github.com/Azgaar/Fantasy-Map-Generator.git
synced 2025-12-17 17:51:24 +01:00
rough implementation of empty function to load csv for rivers
This commit is contained in:
parent
845dc893d2
commit
9b30da95d2
2 changed files with 19 additions and 1 deletions
|
|
@ -25,6 +25,7 @@ function overviewRivers() {
|
|||
document.getElementById("riversBasinHighlight").addEventListener("click", toggleBasinsHightlight);
|
||||
document.getElementById("riversExport").addEventListener("click", downloadRiversData);
|
||||
document.getElementById("riversRemoveAll").addEventListener("click", triggerAllRiversRemove);
|
||||
document.getElementById("loadriverfromcsv").addEventListener("click", loadriverfromcsvfunction);
|
||||
|
||||
// add line for each river
|
||||
function riversOverviewAddLines() {
|
||||
|
|
@ -164,7 +165,7 @@ function overviewRivers() {
|
|||
});
|
||||
}
|
||||
|
||||
function triggerAllRiversRemove() {
|
||||
function removeAllRivers() {
|
||||
alertMessage.innerHTML = /* html */ `Are you sure you want to remove all rivers?`;
|
||||
$("#alert").dialog({
|
||||
resizable: false,
|
||||
|
|
@ -187,4 +188,20 @@ function overviewRivers() {
|
|||
rivers.selectAll("*").remove();
|
||||
riversOverviewAddLines();
|
||||
}
|
||||
|
||||
function loadriverfromcsvfunction() {
|
||||
alertMessage.innerHTML = /* html */ `Are you sure you want to add river from csv?`;
|
||||
$("#alert").dialog({
|
||||
resizable: false,
|
||||
title: "Import rivers",
|
||||
buttons: {
|
||||
Remove: function() {
|
||||
$(this).dialog("close");
|
||||
},
|
||||
Cancel: function() {
|
||||
$(this).dialog("close");
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue