1.  
  2. // BEGIN :: Top slider
  3. this.topSlider = new BiSlider("vertical");
  4. this.topSlider.setLocation(0,0);
  5. this.topSlider.setHeight(142);
  6. this.topSlider.setZIndex(0);
  7. this.topSlider.setMinimum(0);
  8. this.topSlider.setMaximum(100);
  9. this.topSlider.setValue(100);
  10. this.topSlider._line.setStyleProperty("display", "none");
  11. this.topSlider.remove(this.topSlider._thumb);
  12. this.topSlider._thumb = null;
  13.  
  14. this.topOdometer.setText(this.topSlider.getValue());
  15.  
  16. var topBg = new BiComponent();
  17. topBg.setWidth(66);
  18. topBg.setStyleProperty("backgroundColor", "#e7ebf7");
  19. topBg.setOpacity(.6);
  20. topBg.setStyleProperty("display", "none");
  21. this.topSlider.add(topBg);
  22. this.topSlider.referToBg = topBg;
  23.  
  24. var topThumb = this.topSlider._thumb = new BiImage("./sliderTopActive.gif");
  25. this.topSlider._thumb.setSize(66, 13);
  26. this.topSlider._thumb.setStyleProperty("cursor", "pointer");
  27. this.topSlider.add(this.topSlider._thumb);
  28.  
  29. this.topSlider.setStyleProperty("left", getLeftPositionPercentageForCenter(this.topSlider, screen.width) + "%");
  30. this.topSlider.setStyleProperty("top", getTopPositionPercentageForCenter(this.topSlider, screen.height) + "%");
  31. this.topSlider.setWidth(topThumb.getWidth());
  32. this.sliderBody.add(this.topSlider);
  33. // END :: Top slider
  34. // BEGIN :: Bottom slider
  35. this.bottomSlider = new BiSlider("vertical");
  36. this.bottomSlider.setLocation(0,0);
  37. this.bottomSlider.setHeight(142);
  38. this.bottomSlider.setZIndex(0);
  39. this.bottomSlider.setMinimum(0);
  40. this.bottomSlider.setMaximum(100);
  41. this.bottomSlider.setValue(0);
  42. this.bottomSlider._line.setStyleProperty("display", "none");
  43. this.bottomSlider.remove(this.bottomSlider._thumb);
  44. this.bottomSlider._thumb = null;
  45. this.bottomOdometer.setText(this.bottomSlider.getValue());
  46.  
  47. var bottomBg = new BiComponent();
  48. bottomBg.setWidth(66);
  49. bottomBg.setStyleProperty("backgroundColor", "#e7ebf7");
  50. bottomBg.setOpacity(.6);
  51. bottomBg.setStyleProperty("display", "none");
  52. this.bottomSlider.add(bottomBg);
  53. this.bottomSlider.referToBg = bottomBg;
  54.  
  55. var bottomThumb = this.bottomSlider._thumb = new BiImage("./sliderBottomActive.gif");
  56. this.bottomSlider._thumb.setSize(66, 13);
  57. this.bottomSlider._thumb.setStyleProperty("cursor", "pointer");
  58. this.bottomSlider.add(this.bottomSlider._thumb);
  59.  
  60. this.bottomSlider.setStyleProperty("left", getLeftPositionPercentageForCenter(this.bottomSlider, this.sliderBody.getWidth()) + "%");
  61. this.bottomSlider.setStyleProperty("top", getTopPositionPercentageForCenter(this.bottomSlider, this.sliderBody.getHeight()) + "%");
  62. this.bottomSlider.setWidth(bottomThumb.getWidth());
  63. this.sliderBody.add(this.bottomSlider);
  64. // END :: Bottom slider
  65.  
  66.