automated functions
This commit is contained in:
parent
4f98414710
commit
26901027c0
45
static/js/d3_map.js
vendored
45
static/js/d3_map.js
vendored
@ -102,28 +102,45 @@ d3.json("/static/js/group1.json", function(error, json) {
|
|||||||
//}
|
//}
|
||||||
|
|
||||||
// scripts for mouse events
|
// scripts for mouse events
|
||||||
$("#dadaloglu").click(function(){
|
|
||||||
$("#showdadaloglu").fadeIn()
|
function popup(name,time) {
|
||||||
|
$("#"+name).click(function(){
|
||||||
|
$("#show"+name).fadeIn()
|
||||||
console.log("around")
|
console.log("around")
|
||||||
var dada = document.getElementById("textdadaloglu");
|
var dada = document.getElementById("text"+name);
|
||||||
dada.className += " active";
|
dada.className += " active";
|
||||||
dada.scrollIntoView();
|
dada.scrollIntoView();
|
||||||
var audio1 = document.getElementById("audioBG");
|
var audio1 = document.getElementById("audioBG");
|
||||||
audio1.currentTime = 12;
|
audio1.currentTime = time;
|
||||||
audio1.play();
|
audio1.play();
|
||||||
});
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
popup('dadaloglu',12);
|
||||||
|
popup('asikA',45);
|
||||||
|
|
||||||
|
// $("#dadaloglu").click(function(){
|
||||||
$("#asikA").click(function(){$("#showasikA").fadeIn()
|
// $("#showdadaloglu").fadeIn()
|
||||||
console.log("around")
|
// console.log("around")
|
||||||
var muh = document.getElementById("textasikA");
|
// var dada = document.getElementById("textdadaloglu");
|
||||||
muh.className += " active";
|
// dada.className += " active";
|
||||||
muh.scrollIntoView();
|
// dada.scrollIntoView();
|
||||||
var audio2 = document.getElementById("audioBG");
|
// var audio1 = document.getElementById("audioBG");
|
||||||
audio2.currentTime = 120;
|
// audio1.currentTime = 12;
|
||||||
audio2.play();
|
// audio1.play();
|
||||||
});
|
// });
|
||||||
|
//
|
||||||
|
//
|
||||||
|
//
|
||||||
|
// $("#asikA").click(function(){$("#showasikA").fadeIn()
|
||||||
|
// console.log("around")
|
||||||
|
// var muh = document.getElementById("textasikA");
|
||||||
|
// muh.className += " active";
|
||||||
|
// muh.scrollIntoView();
|
||||||
|
// var audio2 = document.getElementById("audioBG");
|
||||||
|
// audio2.currentTime = 120;
|
||||||
|
// audio2.play();
|
||||||
|
// });
|
||||||
|
|
||||||
//stop events when clicking somewhere else
|
//stop events when clicking somewhere else
|
||||||
$(document).click(function (e) {
|
$(document).click(function (e) {
|
||||||
|
Loading…
Reference in New Issue
Block a user