aboutsummaryrefslogtreecommitdiffstats
path: root/web/js
diff options
context:
space:
mode:
authorJason A. Donenfeld <Jason@zx2c4.com>2011-05-09 19:36:15 -0400
committerJason A. Donenfeld <Jason@zx2c4.com>2011-05-09 19:36:15 -0400
commit04996b8360e4b4d6b3a3cc445710147ff2f0de1a (patch)
tree4a1649f47046bb9853938369594b3dff5f07ca03 /web/js
parentAdd powered by logo. (diff)
downloadPhotoFloat-04996b8360e4b4d6b3a3cc445710147ff2f0de1a.tar.xz
PhotoFloat-04996b8360e4b4d6b3a3cc445710147ff2f0de1a.zip
Mark current thumb.
Diffstat (limited to 'web/js')
-rw-r--r--web/js/010-control.js6
1 files changed, 6 insertions, 0 deletions
diff --git a/web/js/010-control.js b/web/js/010-control.js
index 5cd6cb7..8a6ed2b 100644
--- a/web/js/010-control.js
+++ b/web/js/010-control.js
@@ -125,6 +125,7 @@ $(document).ready(function() {
}
if (current_photo_cache == null) {
+ $("#thumbs img").removeClass("current-thumb");
$("#album-view").removeClass("photo-view-container");
$("#subalbums").show();
$("#photo-view").hide();
@@ -221,6 +222,11 @@ $(document).ready(function() {
scroller.stop().animate({ scrollLeft: thumb.position().left + scroller.scrollLeft() - scroller.width() / 2 + thumb.width() / 2 }, "slow");
} else
$("html, body").stop().animate({ scrollTop: thumb.offset().top - $(window).height() / 2 + thumb.height() }, "slow");
+
+ if (current_photo_cache != null) {
+ $("#thumbs img").removeClass("current-thumb");
+ thumb.addClass("current-thumb");
+ }
}
function currentPhoto() {
for (current_photo_index = 0; current_photo_index < current_album.photos.length; ++current_photo_index) {