add functions for scrolling up and down in vertical themes (addresses #46)
This commit is contained in:
parent
8c6d98c0b4
commit
c99d72ff55
1 changed files with 36 additions and 17 deletions
|
@ -1,7 +1,7 @@
|
||||||
/*
|
/*
|
||||||
* Image scrolling JQuery code.
|
* Image scrolling JQuery code.
|
||||||
*
|
*
|
||||||
* Copyright (c) 2007, 2008 Jan Dittberner <jan@dittberner.info>
|
* Copyright (c) 2007, 2008, 2009 Jan Dittberner <jan@dittberner.info>
|
||||||
* Jan Dittberner IT-Consulting & -Solutions
|
* Jan Dittberner IT-Consulting & -Solutions
|
||||||
* Cottbuser Str. 1, D-01129 Dresden
|
* Cottbuser Str. 1, D-01129 Dresden
|
||||||
*
|
*
|
||||||
|
@ -65,6 +65,7 @@ function updateContentImage(pathParts) {
|
||||||
}
|
}
|
||||||
|
|
||||||
$(document).ready(function() {
|
$(document).ready(function() {
|
||||||
|
if (themetype == 'horizontal') {
|
||||||
$("#arrleft").mouseover(function() {
|
$("#arrleft").mouseover(function() {
|
||||||
$("#scrollable").animate({
|
$("#scrollable").animate({
|
||||||
left: "0px"
|
left: "0px"
|
||||||
|
@ -81,6 +82,24 @@ $(document).ready(function() {
|
||||||
}).mouseout(function() {
|
}).mouseout(function() {
|
||||||
$("#scrollable").stop();
|
$("#scrollable").stop();
|
||||||
});
|
});
|
||||||
|
} else {
|
||||||
|
$('#arrup').mouseover(function() {
|
||||||
|
$('#scrollable').animate({
|
||||||
|
top: "0px"
|
||||||
|
}, 500);
|
||||||
|
}).mouseout(function() {
|
||||||
|
$('#scrollable').stop();
|
||||||
|
});
|
||||||
|
$('#arrdown').mouseover(function() {
|
||||||
|
offset = parseInt($('#imgscroller').css('height')) -
|
||||||
|
parseInt($('#scrollable').css('height'));
|
||||||
|
$('#scrollable').animate({
|
||||||
|
top: offset + "px"
|
||||||
|
}, 500);
|
||||||
|
}).mouseout(function() {
|
||||||
|
$('#scrollable').stop();
|
||||||
|
});
|
||||||
|
}
|
||||||
$("#backbtn").click(function() {
|
$("#backbtn").click(function() {
|
||||||
$("div.thumbnail img").each(function(i) {
|
$("div.thumbnail img").each(function(i) {
|
||||||
var curparts = getPathParts($("img#contentimg").attr("src"));
|
var curparts = getPathParts($("img#contentimg").attr("src"));
|
||||||
|
|
Reference in a new issue