Browse Source

Moved code to init

Tobias Reich 11 years ago
parent
commit
00156aa01a
3 changed files with 8 additions and 13 deletions
  1. 0 0
      assets/build/main.js
  2. 8 0
      assets/js/init.js
  3. 0 13
      assets/js/view.js

File diff suppressed because it is too large
+ 0 - 0
assets/build/main.js


+ 8 - 0
assets/js/init.js

@@ -101,6 +101,14 @@ $(document).ready(function(){
 		else if (visible.albums()&&$("#search").val().length!==0) search.reset();
 		else if (visible.albums()&&$("#search").val().length!==0) search.reset();
 	});
 	});
 
 
+	/* Fullscreen on mobile */
+	if (mobileBrowser()) {
+		$(document).on("touchend", "#image", function(e) {
+			if (visible.controls()) view.header.hide(e, 0);
+			else e.preventDefault();
+		});
+	}
+
 	/* Document */
 	/* Document */
 	$(document)
 	$(document)
 
 

+ 0 - 13
assets/js/view.js

@@ -377,19 +377,6 @@ view = {
 				.bind("mouseenter", view.header.show)
 				.bind("mouseenter", view.header.show)
 				.bind("mouseleave", view.header.hide);
 				.bind("mouseleave", view.header.hide);
 
 
-			// Fullscreen on mobile
-			if (mobileBrowser()) {
-				$(document).on("touchend", "#image", function(e) {
-					if (visible.controls()) {
-						view.header.hide(e, 0);
-						e.preventDefault();
-					} else {
-						view.header.show();
-						e.preventDefault();
-					}
-				});
-			}
-
 			lychee.animate(lychee.imageview, "fadeIn");
 			lychee.animate(lychee.imageview, "fadeIn");
 
 
 		},
 		},

Some files were not shown because too many files changed in this diff