Select Git revision
Channels.js
Andrew Cohen authored
Channels.js 2.28 KiB
/*****************************************************************************/
//
// Copyright 2015 Andrew Cohen
//
// This file is part of CloneView - the tool for displaying stem cell lineaging in a webpage.
//
// CloneView is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// CloneView is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with CloneView in file "gnu gpl v3.txt". If not, see
// <http://www.gnu.org/licenses/>.
//
/*****************************************************************************/
var gnCurrentChannel=1;
function InitChannels() {
FileURL = window.location.href.split("?");
gImgURL = gExperimentPath + '/ImageData/' + FileURL[FILEURL_DATASET_NAME] +
'/' + FileURL[FILEURL_NCHANNELS+1]; + '_t';
document.getElementById("channelButtons").style.display="block";
} // SetupChannels
function ShowChannel(nChannel) {
var FileURL;
if (nChannel==gnCurrentChannel) return;
if (1==gnCurrentChannel) {
document.getElementById('phase').style.textDecoration="underline";
}
else if (2== gnCurrentChannel) {
document.getElementById('channel2').style.textDecoration="underline";
}
else {
document.getElementById('channel3').style.textDecoration="underline";
}
gnCurrentChannel=nChannel;
FileURL = window.location.href.split("?");
gImgURL = gExperimentPath + '/ImageData/' + FileURL[FILEURL_DATASET_NAME] +
'/' + FileURL[FILEURL_NCHANNELS+(gnCurrentChannel*2)-1];
if (1== nChannel) {
gImgURLPostscript='';
UpdateTime();
document.getElementById('phase').style.textDecoration="none";
return;
}
else if (2== nChannel) {
document.getElementById('channel2').style.textDecoration="none";
}
else {
document.getElementById('channel3').style.textDecoration="none";
}
gImgURLPostscript='_z0001';
UpdateTime();
}