mirror of
https://github.com/jspsych/jsPsych.git
synced 2025-05-10 19:20:55 +00:00
Minor bug corrections
This commit is contained in:
parent
8bd466c18f
commit
ed5034bbd0
@ -41,7 +41,7 @@
|
|||||||
reps++;
|
reps++;
|
||||||
if(reps >= trial.repetitions)
|
if(reps >= trial.repetitions)
|
||||||
{
|
{
|
||||||
animation_trial($this, block, trial, part + 1);
|
plugin.trial($this, block, trial, part + 1);
|
||||||
clearInterval(animate_interval);
|
clearInterval(animate_interval);
|
||||||
showImage = false;
|
showImage = false;
|
||||||
}
|
}
|
||||||
|
8
jspsych-samedifferent.js
Executable file → Normal file
8
jspsych-samedifferent.js
Executable file → Normal file
@ -33,12 +33,12 @@
|
|||||||
"src": trial.a_path,
|
"src": trial.a_path,
|
||||||
"class": 'sd'
|
"class": 'sd'
|
||||||
}));
|
}));
|
||||||
setTimeout(function(){sd_trial($this, block, trial, part + 1);}, trial.timing[0]);
|
setTimeout(function(){plugin.trial($this, block, trial, part + 1);}, trial.timing[0]);
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
p2_time = (new Date()).getTime();
|
p2_time = (new Date()).getTime();
|
||||||
$('.sd').remove();
|
$('.sd').remove();
|
||||||
setTimeout(function(){sd_trial($this, block, trial, part + 1);}, trial.timing[1]);
|
setTimeout(function(){plugin.trial($this, block, trial, part + 1);}, trial.timing[1]);
|
||||||
break;
|
break;
|
||||||
case 3:
|
case 3:
|
||||||
p3_time = (new Date()).getTime();
|
p3_time = (new Date()).getTime();
|
||||||
@ -47,9 +47,9 @@
|
|||||||
"class": 'sd'
|
"class": 'sd'
|
||||||
}));
|
}));
|
||||||
if(trial.timing[3]!=undefined){
|
if(trial.timing[3]!=undefined){
|
||||||
setTimeout(function(){sd_trial($this, block, trial, part + 1);}, trial.timing[3]);
|
setTimeout(function(){plugin.trial($this, block, trial, part + 1);}, trial.timing[3]);
|
||||||
} else {
|
} else {
|
||||||
sd_trial($this, block, trial, part + 1);
|
plugin.trial($this, block, trial, part + 1);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case 4:
|
case 4:
|
||||||
|
2
jspsych-similarity.js
Executable file → Normal file
2
jspsych-similarity.js
Executable file → Normal file
@ -49,7 +49,7 @@
|
|||||||
$this.append($('<button>', {'id':'next','class':'sim'}));
|
$this.append($('<button>', {'id':'next','class':'sim'}));
|
||||||
$("#next").html('Next');
|
$("#next").html('Next');
|
||||||
$("#next").click(function(){
|
$("#next").click(function(){
|
||||||
similarity_trial($this,block,trial,part+1);
|
plugin.trial($this,block,trial,part+1);
|
||||||
});
|
});
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
(function( $ ) {
|
(function( $ ) {
|
||||||
jsPsych.xab-touch = (function(){
|
jsPsych.xab_touch = (function(){
|
||||||
|
|
||||||
var plugin = {};
|
var plugin = {};
|
||||||
|
|
||||||
@ -10,7 +10,7 @@
|
|||||||
for(var i = 0; i < trials.length; i++)
|
for(var i = 0; i < trials.length; i++)
|
||||||
{
|
{
|
||||||
trials[i] = {};
|
trials[i] = {};
|
||||||
trials[i]["type"] = "xab-touch";
|
trials[i]["type"] = "xab_touch";
|
||||||
trials[i]["a_path"] = xab_stims[i][0];
|
trials[i]["a_path"] = xab_stims[i][0];
|
||||||
trials[i]["b_path"] = xab_stims[i][1];
|
trials[i]["b_path"] = xab_stims[i][1];
|
||||||
trials[i]["timing"] = params["timing"];
|
trials[i]["timing"] = params["timing"];
|
||||||
@ -30,12 +30,12 @@
|
|||||||
"src": trial.a_path,
|
"src": trial.a_path,
|
||||||
"class": 'xab_touch'
|
"class": 'xab_touch'
|
||||||
}));
|
}));
|
||||||
setTimeout(function(){xab_touch_trial($this, block, trial, part + 1);}, trial.timing[0]);
|
setTimeout(function(){plugin.trial($this, block, trial, part + 1);}, trial.timing[0]);
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
p2_time = (new Date()).getTime();
|
p2_time = (new Date()).getTime();
|
||||||
$('.xab_touch').remove();
|
$('.xab_touch').remove();
|
||||||
setTimeout(function(){xab_touch_trial($this, block, trial, part + 1);}, trial.timing[1]);
|
setTimeout(function(){plugin.trial($this, block, trial, part + 1);}, trial.timing[1]);
|
||||||
break;
|
break;
|
||||||
case 3:
|
case 3:
|
||||||
p3_time = (new Date()).getTime();
|
p3_time = (new Date()).getTime();
|
||||||
|
Loading…
Reference in New Issue
Block a user