Skip to content
This repository
Browse code

updates to sliders II

  • Loading branch information...
commit 4fab68a4baa8bee7216b790492fc083e07376fee 1 parent 570aeab
Addy Osmani authored October 26, 2010

Showing 1 changed file with 4 additions and 14 deletions. Show diff stats Hide diff stats

  1. 18  demo/app.js
18  demo/app.js
@@ -64,9 +64,7 @@
64 64
               $('.coverflowItem').removeClass('ui-selected');
65 65
 	          $('.coverflowItem:eq(' + ($itemNumber) +')').addClass('ui-selected');
66 66
 	          
67  
-	          //
68  
-	          
69  
-	          
  67
+	       
70 68
 	         
71 69
            }
72 70
 
@@ -210,20 +208,12 @@
210 208
 		skipTo(coverflowItem);
211 209
 	
212 210
 	
213  
-	//
  211
+	
214 212
 	var sliderVal2 = $("#slider-vertical").slider("value");
215 213
 	sliderVal2 += (delta*50);
216  
-	
217 214
 	$("#slider-vertical").slider("value", (sliderVal2));
218  
-	var topValue = -((100-sliderVal2)*difference/100);//calculate the content top from the slider position
219  
-		
220  
-	if (topValue>0) topValue = 0;//stop the content scrolling down too much
221  
-	if (Math.abs(topValue)>difference) topValue = (-1)*difference;//stop the content scrolling up too much
222  
-		
223  
-		
224  
-		
225  
-	$("#sortable").css({top: (coverflowItem * -25 ) });//move the content to the new position
226  
-
  215
+				
  216
+	$("#sortable").css({top: (coverflowItem * -25 ) });
227 217
 
228 218
 	
229 219
 	    event.preventDefault();//stop any default behaviour

0 notes on commit 4fab68a

Please sign in to comment.
Something went wrong with that request. Please try again.