Interactive interface for browsing global, full-resolution satellite imagery
Mobile compability for Worldview
Tilak Joshi74dc349b096d
diff --git a/css/accordionPicker.css b/css/accordionPicker.cssindex 455dbce30..7e94db0be 100644--- a/css/accordionPicker.css+++ b/css/accordionPicker.css@@ -1,6 +1,6 @@-a.accordionToggler { float:left; display:block; width:28px; height:36px; border-radius: 0 10px 10px 0; -moz-border-radius: 0 10px 10px 0; -webkit-border-radius: 0 10px 10px 0; text-decoration:none; background: none no-repeat scroll center rgba(0, 0, 0, 0.88); color:#fff; position:relative; top:30px; letter-spacing:2px; font-family:"Gill Sans","Helvetica",sans-serif;}+/*a.accordionToggler { float:left; display:block; width:28px; height:36px; border-radius: 0 10px 10px 0; -moz-border-radius: 0 10px 10px 0; -webkit-border-radius: 0 10px 10px 0; text-decoration:none; background: none no-repeat scroll center rgba(0, 0, 0, 0.88); color:#fff; position:relative; top:30px; letter-spacing:2px; font-family:"Gill Sans","Helvetica",sans-serif;}a.atcollapse {background-image: url("../images/expandIn.png"); }-a.atexpand {background-image: url("../images/expandOut.png");}+a.atexpand {background-image: url("../images/expandOut.png");}*/.accordion {position:relative;}.ui-accordion { float:left; display:block; width:230px; /* background:rgba(50,50,60,0.89); */color:#fff; font: 1.05em "Gill Sans",sans-serif; text-shadow:none; font-weight:120;}.ui-accordion{ border-radius: 0 20px 20px 0; -moz-border-radius: 0 20px 20px 0; -webkit-border-radius: 0 20px 20px 0; background: none repeat scroll 0 0 rgba(0,0,0,0.8); border:rgba(0,0,0,0.35) 10px solid; border-width:10px 10px 10px 0;}diff --git a/css/bank.css b/css/bank.cssindex 7cac5c0a2..8f8d50400 100644--- a/css/bank.css+++ b/css/bank.css@@ -1,12 +1,12 @@canvas {float:left;}-a.accordionToggler { float:left; display:inline-block; width:28px; height:36px; /*box-shadow: 3px 0 4px 1px #bbb;*/ border-radius: 0 10px 10px 0; -moz-border-radius: 0 10px 10px 0; -webkit-border-radius: 0 10px 10px 0; text-decoration:none; background: none no-repeat scroll center rgba(45,50,55,0.65); color:#fff; position:relative; top:30px; letter-spacing:2px; font-family:"Gill Sans","Helvetica",sans-serif;}+a.accordionToggler { float:right; display:inline-block; width:10%; z-index:292; height:2.1em;/*box-shadow: 3px 0 4px 1px #bbb;*/ border-radius: 0 10px 10px 0; -moz-border-radius: 0 10px 10px 0; -webkit-border-radius: 0 10px 10px 0; text-decoration:none; background: none no-repeat scroll center; color:#fff; position:relative; letter-spacing:2px; font-family:"Gill Sans","Helvetica",sans-serif;}a.atcollapse {background-image: url("../images/expandIn.png"); }a.atexpand {background-image: url("../images/expandOut.png");}-.bank { display:inline-block; float:left; width: 210px; min-height:190px; padding-bottom:20px; /*box-shadow: 0 0 4px 1px #bbb;*/ font: 10px/12px "Gill Sans","helvetica",sans-serif; color: #fff; text-shadow:none;}+div.bank { display:inline-block; float:left; width: 100%; height:100%;/*box-shadow: 0 0 4px 1px #bbb;*/ font: 1em; color: #fff; text-shadow:none;}.bank h1,h2,h3,h4 {margin:0px; padding:0px; color:#fffbe7;}-.bank h2 {font:14px "gill sans", sans-serif; display:inline-block; float: left; color:#ffffff; font-size: 14px; font-weight:100; border:none; padding:9px 30px 9px 30px;+.bank h2 {font-size:1.4em; display:inline-block; float: left; color:#ffffff; border:none; padding:9px 30px 9px 30px;background: -moz-linear-gradient(top, rgba(255,255,255,0.7) 0%, rgba(11,95,160,0.7) 23%, rgba(0,88,156,0.7) 24%, rgba(0,81,144,0.7) 99%, rgba(0,81,144,0.7) 100%); /* FF3.6+ */background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgba(255,255,255,0.7)), color-stop(23%,rgba(11,95,160,0.7)), color-stop(24%,rgba(0,88,156,0.7)), color-stop(99%,rgba(0,81,144,0.7)), color-stop(100%,rgba(0,81,144,0.7))); /* Chrome,Safari4+ */background: -webkit-linear-gradient(top, rgba(255,255,255,0.7) 0%,rgba(11,95,160,0.7) 23%,rgba(0,88,156,0.7) 24%,rgba(0,81,144,0.7) 99%,rgba(0,81,144,0.7) 100%); /* Chrome10+,Safari5.1+ */@@ -18,12 +18,12 @@ filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#b3ffffff', e}.bank .tabContainer {border-bottom: 2px #005190 solid; }-.bank h3 {display:inline-block; float: left; color:#ffffff; font-size: 12px; font-weight:100; border:none; text-decoration:none; width:204px;}+.bank h3 {display:block; color:#ffffff; font-size: 1em; border:none; text-decoration:none; width:100%;}#callSelectorLink {display: inline-block; width:32px; height:32px; background: transparent url("../images/addLayers.png"); margin-left: 50px;float:right;}.bank div,.bank ul {display:block;width:100%; margin:0 auto;}-.bank ul {max-height:90px;}-.bank h3 {background: rgba(120,120,120,.7); margin-top:2px; padding: 1px 3px; font-size:10px !important;}-.bank li.item {padding:0; display:block; width:198px; padding:8px 9px 8px 3px;+.bank .category {overflow:hidden;}+.bank h3 {background: rgba(120,120,120,.7); margin-top:2px; padding: 1px 3px; }+.bank li.item {padding:0; display:block; width:100%; padding:8px 0px 8px 0px; overflow:hidden;background: -moz-linear-gradient(top, rgba(0,0,0,0.54) 0%, rgba(2,2,2,0.54) 1%, rgba(78,78,78,0.54) 50%, rgba(0,0,0,0.54) 100%); /* FF3.6+ */background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgba(0,0,0,0.24)), color-stop(1%,rgba(2,2,2,0.24)), color-stop(50%,rgba(78,78,78,0.24)), color-stop(100%,rgba(0,0,0,0.24))); /* Chrome,Safari4+ */background: -webkit-linear-gradient(top, rgba(0,0,0,0.24) 0%,rgba(2,2,2,0.24) 1%,rgba(78,78,78,0.24) 50%,rgba(0,0,0,0.24) 100%); /* Chrome10+,Safari5.1+ */@@ -35,20 +35,23 @@ filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#3d000000', e}+.categoryContainer { display:block; width:100%; overflow:hidden;}+.mCustomScrollBox > .mCSB_scrollTools {right: -6px;}-.bank li.item a {float:right; color:#fff; margin-right:5px; margin-top:3px;}-.bank li.item a.hdanchor {margin-top:0px;}-.bank li.item h4 {font-size:9px; font-weight:bold; padding:0 3px;}-.bank li.item p {padding:0 3px; color:#fffbe7; }+.bank li.item a {float:right; color:#fff; margin-right:0.3em;}+.bank li.item a.hdanchor {display:inline-block; overflow:hidden;}+.bank li.item h4 {font-size:0.9em; padding:0 3px;}+.bank li.item p {padding:0 3px; color:#fffbe7; font-size:0.8em;}.bank li.item span.palette {display:block; overflow:hidden; margin-top:5px; margin-left:5px;}.bank li.item ul.palette li {float:left;}-.bank ul.category { /*background: rgba(255,255,255,.7); border-radius:5px; */}+.bank ul.category { overflow:auto; *background: rgba(255,255,255,.7); border-radius:5px; */}.bank ul.category li h3 {display:block; clear:both; float:none;}+img.bank-item-img { display:block; height: 14px; width:auto;}span.p-min {float:left;}span.p-max {float:left;}span.p-units {float:left;}-.ui-tabs-hide {display:none !important;}+.ui-tabs-hide {/*display:none !important;*/ position:absolute !important; left:-999em !important;}diff --git a/css/dateSpan.css b/css/dateSpan.cssindex cf6d1b26c..b81c4ca61 100644--- a/css/dateSpan.css+++ b/css/dateSpan.css@@ -1,3 +1,5 @@+#timeds, #timemds {position:absolute;}+.datespan ul, menu, dir{-webkit-margin-before: 0em;-webkit-margin-after: 0em;@@ -39,7 +41,7 @@ filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#bf2d2d2d', eheight:23px;}-ul.sliderLabel {text-shadow: none; color:#fff; margin:-20px 0 0 0; background:none; height:20px; overflow:hidden; font-size:12px !important; font-weight:bold; line-height:20px !important;}+ul.sliderLabel {text-shadow: none; color:#fff; margin:-20px 0 0 0; background:none; height:20px; overflow:hidden; font-size:12px !important; font-weight:100; line-height:20px !important;}ul.sliderLabel li {float:left; background:none; margin:0px; text-align:center; overflow:hidden;}div.sliderDivYear {clear:both;}div.sliderDivMonth {background: rgba(45,50,55,0.5);}@@ -53,7 +55,7 @@ div.ui-slider {border:none; background:transparent; /*width:100%;*/ margin:0px;.sliderDivMonth a.ui-slider-handle {width:54px; margin-left:-30px !important;}.sliderDivYear a.ui-slider-handle {width:54px; margin-left:-30px !important;}*/-.dateHolder {display:inline-block; float:left; width:10%; /*background: rgba(45,50,55,.75);*/ margin-bottom:10px; margin-top:3px;text-shadow:none; color:#fff; font-weight:bold; font-size:12px; text-align:center; padding:5px 0px; padding-right:28px;+.dateHolder,#linkmode {display:inline-block; float:left; width:6em; /*background: rgba(45,50,55,.75);*/ margin-bottom:10px; margin-top:3px;text-shadow:none; color:#fff; font-weight:bold; font-size:12px; text-align:center; padding:5px 0px; padding-right:28px;border-radius: 0 5px 5px 0;background: -moz-linear-gradient(top, rgba(35,40,45,0.65) 0%, rgba(0,5,10,0.65) 50%, rgba(35,40,45,0.65) 100%); /* FF3.6+ */@@ -67,7 +69,7 @@ filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#bf2d2d2d', e-webkit-box-shadow: 0 -1px 15px #fff;*//*box-shadow: 0 0px 4px 1px #bbb;*/}-+#linkmode {border:none; text-shadow:none;}/*a.ui-slider-handle{height:130px; display:block; width:14%; background:rgba(228,108,10,.2); border:#E46C0A 2px solid; z-index:1004; position:relative; top:-142px; margin: 10px 0 0 -7% !important; padding: 5px 0 5px 0; }*//*span.sliderText {font: 14px/14px "Gill Sans", sans-serif, serif; font-weight:500; color:#fff; text-shadow:none; z-index:1005;}*/a.ui-btn {margin:0;}diff --git a/css/ext/jscrollpane/jquery.jscrollpane.css b/css/ext/jscrollpane/jquery.jscrollpane.cssnew file mode 100644index 000000000..a051caed0--- /dev/null+++ b/css/ext/jscrollpane/jquery.jscrollpane.css@@ -0,0 +1,120 @@+/*+ * CSS Styles that are needed by jScrollPane for it to operate correctly.+ *+ * Include this stylesheet in your site or copy and paste the styles below into your stylesheet - jScrollPane+ * may not operate correctly without them.+ */++.jspContainer+{+ overflow: hidden;+ position: relative;+}++.jspPane+{+ position: absolute;+}++.jspVerticalBar+{+ position: absolute;+ top: 0;+ right: 0;+ width: 16px;+ height: 100%;+ background: red;+}++.jspHorizontalBar+{+ position: absolute;+ bottom: 0;+ left: 0;+ width: 100%;+ height: 16px;+ background: red;+}++.jspVerticalBar *,+.jspHorizontalBar *+{+ margin: 0;+ padding: 0;+}++.jspCap+{+ display: none;+}++.jspHorizontalBar .jspCap+{+ float: left;+}++.jspTrack+{+ background: #dde;+ position: relative;+}++.jspDrag+{+ background: #bbd;+ position: relative;+ top: 0;+ left: 0;+ cursor: pointer;+}++.jspHorizontalBar .jspTrack,+.jspHorizontalBar .jspDrag+{+ float: left;+ height: 100%;+}++.jspArrow+{+ background: #50506d;+ text-indent: -20000px;+ display: block;+ cursor: pointer;+}++.jspArrow.jspDisabled+{+ cursor: default;+ background: #80808d;+}++.jspVerticalBar .jspArrow+{+ height: 16px;+}++.jspHorizontalBar .jspArrow+{+ width: 16px;+ float: left;+ height: 100%;+}++.jspVerticalBar .jspArrow:focus+{+ outline: none;+}++.jspCorner+{+ background: #eeeef4;+ float: left;+ height: 100%;+}++/* Yuk! CSS Hack for IE6 3 pixel bug :( */+* html .jspCorner+{+ margin: 0 -3px 0 0;+}\ No newline at end of filediff --git a/css/ext/mobiscroll/mobiscroll.android-ics.css b/css/ext/mobiscroll/mobiscroll.android-ics.cssnew file mode 100644index 000000000..4ab9ab46f--- /dev/null+++ b/css/ext/mobiscroll/mobiscroll.android-ics.css@@ -0,0 +1,204 @@+/* Android ICS skin */+.android-ics .dw {+ padding: 0;+ color: #31b6e7;+ background: #292829;+}+.android-ics .dw .dwwc,+.android-ics .dw .dwwl,+.android-ics .dw .dww,+.android-ics .dw .dwb,+.android-ics .dw .dwpm .dww {+ background: none;+}+.android-ics .dwwr {+ padding: 0;+}+.android-ics .dwc {+ padding: 30px 10px 1px 10px;+}+.android-ics .dwhl {+ padding: 1px 10px;+}+.android-ics .dwv {+ height: 36px;+ line-height: 36px;+ padding: 0;+ border-bottom: 2px solid #31b6e7;+ font-size: 18px;+}+.android-ics .dwwl {+ margin: 0 2px;+}+.android-ics .dww,+.android-ics .dw .dwpm .dwwl,+.android-ics .dw .dwpm .dww {+ border: 0;+}+.android-ics .dww .dw-li {+ color: #fff;+ font-size: 18px;+ text-shadow: none;+}+.android-ics .dww .dw-li.dw-hl {+ background: #31b6e7;+ background: rgba(49,182,231,.5);+}+.android-ics .dwwo {+ background: linear-gradient(#282828 0%,rgba(40,40,40,0) 52%, rgba(40,40,40,0) 48%, #282828 100%);+ background: -webkit-gradient(linear,left bottom,left top,from(#282828),color-stop(0.52, rgba(40,40,40,0)),color-stop(0.48, rgba(40,40,40,0)),to(#282828));+ background: -moz-linear-gradient(#282828 0%,rgba(40,40,40,0) 52%, rgba(40,40,40,0) 48%, #282828 100%);+ background: -o-linear-gradient(#282828 0%,rgba(40,40,40,0) 52%, rgba(40,40,40,0) 48%, #282828 100%);+}+.android-ics .dw .dwwb {+ background: #292829;+ box-shadow: none;+ -webkit-box-shadow: none;+}+.android-ics .dwwb span {+ display: none;+}+.android-ics .dwwb:after {+ position: absolute;+ top: 50%;+ left: 50%;+ margin-top: -8px;+ margin-left: -8px;+ color: #7e7e7e;+ width: 0;+ height: 0;+ border-width: 8px;+ border-style: solid;+ content: '';+}+.android-ics .dwwbm {+ top: 0;+ bottom: auto;+}+.android-ics .dwwbp {+ bottom: 0;+ top: auto;+}+.android-ics .dwwbm:after {+ border-color: transparent transparent #7e7e7e transparent;+}+.android-ics .dwwbp:after {+ border-color: #7e7e7e transparent transparent transparent;+}+.android-ics .dw .dwwl .dwb-a {+ background: #292829;+}+.android-ics .dwwbm.dwb-a:after {+ border-color: transparent transparent #319abd transparent;+}+.android-ics .dwwbp.dwb-a:after {+ border-color: #319abd transparent transparent transparent;+}+.android-ics .dw .dwwol {+ width: 60%;+ left: 20%;+ height: 36px;+ border-top: 2px solid #31b6e7;+ border-bottom: 2px solid #31b6e7;+ margin-top: -20px;+ display: block;+}+.android-ics .dwbc {+ border-top: 1px solid #424542;+ padding: 0;+}+.android-ics .dw .dwb {+ height: 36px;+ line-height: 36px;+ padding: 0;+ margin: 0;+ font-weight: normal;+ text-shadow: none;+ box-shadow: none;+ border-radius: 0;+ -webkit-border-radius: 0;+ -webkit-box-shadow: none;+}+.android-ics .dw .dwb-a {+ background: #29799c;+}+.android-ics .dwb-s .dwb, .android-ics .dwb-n .dwb {+ border-right: 1px solid #424542;+}+/* Docked */+.android-ics.dw-bottom .dw, .android-ics.dw-top .dw {+ border-radius: 0;+ -webkit-border-radius: 0;+}+/* Multiple select */+.android-ics .dwwms .dwwol {+ display: none;+}+.android-ics .dwwms .dw-li {+ padding-left: 5px;+ padding-right: 36px;+}+.android-ics .dwwms .dw-li:after {+ content: '';+ position: absolute;+ top: 50%;+ left: auto;+ right: 10px;+ width: 14px;+ height: 14px;+ margin-top: -9px;+ color: #31b6e7;+ line-height: 14px;+ border: 1px solid #424542;+ text-shadow: 0 0 5px #29799c;+}+.android-ics .dwwms .dw-msel:after {+ content: '✔';+}+/* Light version */+.android-ics.light .dw {+ background: #f5f5f5;+}+.android-ics.light .dww .dw-li {+ color: #000;+}+.android-ics.light .dwwo {+ background: linear-gradient(#f5f5f5 0%,rgba(245,245,245,0) 52%, rgba(245,245,245,0) 48%, #f5f5f5 100%);+ background: -webkit-gradient(linear,left bottom,left top,from(#f5f5f5),color-stop(0.52, rgba(245,245,245,0)),color-stop(0.48, rgba(245,245,245,0)),to(#f5f5f5));+ background: -moz-linear-gradient(#f5f5f5 0%,rgba(245,245,245,0) 52%, rgba(245,245,245,0) 48%, #f5f5f5 100%);+ background: -o-linear-gradient(#f5f5f5 0%,rgba(245,245,245,0) 52%, rgba(245,245,245,0) 48%, #f5f5f5 100%);+}+.android-ics.light .dw .dwwb {+ background: #f5f5f5;+ color: #f5f5f5;+}+.android-ics.light .dwbc {+ border-top: 1px solid #dbdbdb;+}+.android-ics.light .dwb {+ color: #000;+}+.android-ics.light .dwb-a {+ color: #fff;+}+.android-ics.light .dwb-s .dwb, .android-ics.light .dwb-n .dwb {+ border-right: 1px solid #dbdbdb;+}+/* Bubble positioning */+.android-ics .dw-bubble-bottom .dw-arr {+ border-color: transparent transparent #292829 transparent;+}+.android-ics .dw-bubble-top .dw-arr {+ border-color: #292829 transparent transparent transparent;+}+/* Bubble positioning */+.android-ics.light .dw-bubble-bottom .dw-arr {+ border-color: transparent transparent #f5f5f5 transparent;+}+.android-ics.light .dw-bubble-top .dw-arr {+ border-color: #f5f5f5 transparent transparent transparent;+}+/* Multiple select */+.android-ics.light .dwwms .dw-li:after {+ text-shadow: 0 0 5px #31b6e7;+}diff --git a/css/ext/mobiscroll/mobiscroll.android.css b/css/ext/mobiscroll/mobiscroll.android.cssnew file mode 100644index 000000000..599d39f2e--- /dev/null+++ b/css/ext/mobiscroll/mobiscroll.android.css@@ -0,0 +1,76 @@+/* Android Skin */+.android .dw {+ padding: 0;+ background: #000;+ border: 2px solid #555;+ color: #fff;+}+.android .dwv {+ padding: 10px;+ border-bottom: 1px solid #333;+}+.android .dwwr {+ padding: 0;+}+.android .dww {+ top: 0;+}+.android .dwwc {+ background: #000;+}+.android .dw .dwpm .dww,+.android .dw .dwpm .dwwl {+ border: 0;+ background: #fff;+}+.android .dw .dwpm .dww {+ margin: 0;+}+.android .dwpm .dww .dw-li {+ color: #000;+ text-shadow: none;+}+.android .dwbc {+ padding: 5px 1px;+ background: #9c9c9c;+}+.android .dw .dwb {+ margin: 0 5px;+ background: #ccc;+ background: linear-gradient(#eee,#ccc);+ background: -webkit-gradient(linear,left bottom,left top,from(#ccc),to(#eee));+ background: -moz-linear-gradient(#eee,#ccc);+ background: -o-linear-gradient(#eee,#ccc);+ color: #000;+ font-weight: normal;+ text-shadow: none;+ border-radius: 0;+ -moz-border-radius: 0;+ -webkit-border-radius: 0;+}+.android .dw .dwb-a, .android .dw .dwwl .dwb-a {+ background: #ffb25a;+ background: linear-gradient(#ffb25a,#ef6100);+ background: -webkit-gradient(linear,left bottom,left top,from(#ef6100),to(#ffb25a));+ background: -moz-linear-gradient(#ffb25a,#ef6100);+ background: -o-linear-gradient(#ffb25a,#ef6100);+}+/* Bubble positioning */+.android .dw-bubble-bottom .dw-arr {+ border-color: transparent transparent #000 transparent;+}+.android .dw-bubble-top .dw-arr {+ border-color: #9c9c9c transparent transparent transparent;+}+/* Docked */+.android.dw-top .dw,+.android.dw-bottom .dw {+ border-right: 0;+ border-left: 0;+}+.android.dw-top .dw {+ border-top: 0;+}+.android.dw-bottom .dw {+ border-bottom: 0;+}diff --git a/css/ext/mobiscroll/mobiscroll.animation.css b/css/ext/mobiscroll/mobiscroll.animation.cssnew file mode 100644index 000000000..cb89a42c7--- /dev/null+++ b/css/ext/mobiscroll/mobiscroll.animation.css@@ -0,0 +1,637 @@+.dw-trans .dw-persp {+ overflow: hidden;+ perspective: 1000px;+ -webkit-perspective: 1000px;+ -moz-perspective: 1000px;+}+.dw-trans .dwwb,+.dw-trans .dwwo {+ -webkit-backface-visibility: hidden;+}+.dw-in,+.dw-out {+ animation-duration: 350ms;+ -webkit-animation-duration: 350ms;+ -moz-animation-duration: 350ms;+}+.dw-in {+ animation-timing-function: ease-out;+ -webkit-animation-timing-function: ease-out;+ -moz-animation-timing-function: ease-out;+}+.dw-out {+ animation-timing-function: ease-in;+ -webkit-animation-timing-function: ease-in;+ -moz-animation-timing-function: ease-in;+}+.dw-flip,+.dw-swing,+.dw-slidehorizontal,+.dw-slidevertical,+.dw-slidedown,+.dw-slideup,+.dw-fade {+ backface-visibility: hidden;+ transform: translateX(0);+ -webkit-backface-visibility: hidden;+ -webkit-transform: translateX(0);+ -moz-backface-visibility: hidden;+ -moz-transform: translateX(0);+}+.dw-swing,+.dw-slidehorizontal,+.dw-slidevertical,+.dw-slidedown,+.dw-slideup,+.dw-fade {+ transform-origin: 0 0;+ -webkit-transform-origin: 0 0;+ -moz-transform-origin: 0 0;+}+.dw-flip,+.dw-pop {+ transform-origin: 50% 50%;+ -webkit-transform-origin: 50% 50%;+ -moz-transform-origin: 50% 50%;+}+.dw-pop.dw-in {+ opacity: 1;+ transform: scale(1);+ animation-name: dw-p-in;+ -webkit-animation-name: dw-p-in;+ -webkit-transform: scale(1);+ -moz-animation-name: dw-p-in;+ -moz-transform: scale(1);+}+.dw-pop.dw-out {+ opacity: 0;+ animation-name: dw-p-out;+ -webkit-animation-name: dw-p-out;+ -moz-animation-name: dw-p-out;+}+.dw-flip.dw-in {+ opacity: 1;+ transform: scale(1);+ animation-name: dw-fl-in;+ -webkit-animation-name: dw-fl-in;+ -webkit-transform: scale(1);+ -moz-animation-name: dw-fl-in;+ -moz-transform: scale(1);+}+.dw-flip.dw-out {+ opacity: 0;+ animation-name: dw-fl-out;+ -webkit-animation-name: dw-fl-out;+ -moz-animation-name: dw-fl-out;+}+.dw-swing.dw-in {+ opacity: 1;+ transform: scale(1);+ animation-name: dw-sw-in;+ -webkit-animation-name: dw-sw-in;+ -webkit-transform: scale(1);+ -moz-animation-name: dw-sw-in;+ -moz-transform: scale(1);+}+.dw-swing.dw-out {+ opacity: 0;+ animation-name: dw-sw-out;+ -webkit-animation-name: dw-sw-out;+ -moz-animation-name: dw-sw-out;+}+.dw-slidehorizontal.dw-in {+ opacity: 1;+ transform: scale(1);+ animation-name: dw-sh-in;+ -webkit-animation-name: dw-sh-in;+ -webkit-transform: scale(1);+ -moz-animation-name: dw-sh-in;+ -moz-transform: scale(1);+}+.dw-slidehorizontal.dw-out {+ opacity: 0;+ animation-name: dw-sh-out;+ -webkit-animation-name: dw-sh-out;+ -moz-animation-name: dw-sh-out;+}+.dw-slidevertical.dw-in {+ opacity: 1;+ animation-name: dw-dw-sv-in;+ transform: scale(1);+ -webkit-animation-name: dw-dw-sv-in;+ -webkit-transform: scale(1);+ -moz-animation-name: dw-dw-sv-in;+ -moz-transform: scale(1);+}+.dw-slidevertical.dw-out {+ opacity: 0;+ animation-name: dw-sv-out;+ -webkit-animation-name: dw-sv-out;+ -moz-animation-name: dw-sv-out;+}+.dw-slidedown.dw-in {+ animation-name: dw-sd-in;+ transform: scale(1);+ -webkit-animation-name: dw-sd-in;+ -webkit-transform: scale(1);+ -moz-animation-name: dw-sd-in;+ -moz-transform: scale(1);+}+.dw-slidedown.dw-out {+ animation-name: dw-sd-out;+ -webkit-animation-name: dw-sd-out;+ -moz-animation-name: dw-sd-out;+}+.dw-slideup.dw-in {+ transform: scale(1);+ animation-name: dw-su-in;+ -webkit-animation-name: dw-su-in;+ -webkit-transform: scale(1);+ -moz-animation-name: dw-su-in;+ -moz-transform: scale(1);+}+.dw-slideup.dw-out {+ animation-name: dw-su-out;+ -webkit-animation-name: dw-su-out;+ -moz-animation-name: dw-su-out;+}+.dw-fade.dw-in {+ opacity: 1;+ animation-name: dw-f-in;+ -webkit-animation-name: dw-f-in;+ -moz-animation-name: dw-f-in;+}+.dw-fade.dw-out {+ opacity: 0;+ animation-name: dw-f-out;+ -webkit-animation-name: dw-f-out;+ -moz-animation-name: dw-f-out;+}+/* Fade in */+@keyframes dw-f-in {+ from {+ opacity: 0;+ }+ to {+ opacity: 1;+ }+}+@-webkit-keyframes dw-f-in {+ from {+ opacity: 0;+ }+ to {+ opacity: 1;+ }+}+@-moz-keyframes dw-f-in {+ from {+ opacity: 0;+ }+ to {+ opacity: 1;+ }+}+/* Fade out */+@keyframes dw-f-out {+ from {+ opacity: 1;+ }+ to {+ opacity: 0;+ }+}+@-webkit-keyframes dw-f-out {+ from {+ opacity: 1;+ }+ to {+ opacity: 0;+ }+}+@-moz-keyframes dw-f-out {+ from {+ opacity: 1;+ }+ to {+ opacity: 0;+ }+}+/* Pop in */+@keyframes dw-p-in {+ from {+ opacity: 0;+ transform: scale(0.8);+ }+ to {+ opacity: 1;+ transform: scale(1);+ }+}+@-webkit-keyframes dw-p-in {+ from {+ opacity: 0;+ -webkit-transform: scale(0.8);+ }+ to {+ opacity: 1;+ -webkit-transform: scale(1);+ }+}+@-moz-keyframes dw-p-in {+ from {+ opacity: 0;+ -moz-transform: scale(0.8);+ }+ to {+ opacity: 1;+ -moz-transform: scale(1);+ }+}+/* Pop out */+@keyframes dw-p-out {+ from {+ opacity: 1;+ transform: scale(1);+ }+ to {+ opacity: 0;+ transform: scale(0.8);+ }+}+@-webkit-keyframes dw-p-out {+ from {+ opacity: 1;+ -webkit-transform: scale(1);+ }+ to {+ opacity: 0;+ -webkit-transform: scale(0.8);+ }+}+@-moz-keyframes dw-p-out {+ from {+ opacity: 1;+ -moz-transform: scale(1);+ }+ to {+ opacity: 0;+ -moz-transform: scale(0.8);+ }+}+/* Flip in */+@keyframes dw-fl-in {+ from {+ opacity: 0;+ transform: rotateY(90deg);+ }+ to {+ opacity: 1;+ transform: rotateY(0);+ }+}+@-webkit-keyframes dw-fl-in {+ from {+ opacity: 0;+ -webkit-transform: rotateY(90deg);+ }+ to {+ opacity: 1;+ -webkit-transform: rotateY(0);+ }+}+@-moz-keyframes dw-fl-in {+ from {+ opacity: 0;+ -moz-transform: rotateY(90deg);+ }+ to {+ opacity: 1;+ -moz-transform: rotateY(0);+ }+}+/* Flip out */+@keyframes dw-fl-out {+ from {+ opacity: 1;+ transform: rotateY(0deg);+ }+ to {+ opacity: 0;+ transform: rotateY(-90deg);+ }+}+@-webkit-keyframes dw-fl-out {+ from {+ opacity: 1;+ -webkit-transform: rotateY(0deg);+ }+ to {+ opacity: 0;+ -webkit-transform: rotateY(-90deg);+ }+}+@-moz-keyframes dw-fl-out {+ from {+ opacity: 1;+ -moz-transform: rotateY(0deg);+ }+ to {+ opacity: 0;+ -moz-transform: rotateY(-90deg);+ }+}+/* Swing in */+@keyframes dw-sw-in {+ from {+ opacity: 0;+ transform: rotateY(-90deg);+ }+ to {+ opacity: 1;+ transform: rotateY(0deg);+ }+}+@-webkit-keyframes dw-sw-in {+ from {+ opacity: 0;+ -webkit-transform: rotateY(-90deg);+ }+ to {+ opacity: 1;+ -webkit-transform: rotateY(0deg);+ }+}+@-moz-keyframes dw-sw-in {+ from {+ opacity: 0;+ -moz-transform: rotateY(-90deg);+ }+ to {+ opacity: 1;+ -moz-transform: rotateY(0deg);+ }+}+/* Swing out */+@keyframes dw-sw-out {+ from {+ opacity: 1;+ transform: rotateY(0deg);+ }+ to {+ opacity: 0;+ transform: rotateY(-90deg);+ }+}+@-webkit-keyframes dw-sw-out {+ from {+ opacity: 1;+ -webkit-transform: rotateY(0deg);+ }+ to {+ opacity: 0;+ -webkit-transform: rotateY(-90deg);+ }+}+@-moz-keyframes dw-sw-out {+ from {+ opacity: 1;+ -moz-transform: rotateY(0deg);+ }+ to {+ opacity: 0;+ -moz-transform: rotateY(-90deg);+ }+}+/* Slide horizontal in */+@keyframes dw-sh-in {+ from {+ opacity: 0;+ transform: translateX(-100%);+ }+ to {+ opacity: 1;+ transform: translateX(0);+ }+}+@-webkit-keyframes dw-sh-in {+ from {+ opacity: 0;+ -webkit-transform: translateX(-100%);+ }+ to {+ opacity: 1;+ -webkit-transform: translateX(0);+ }+}+@-moz-keyframes dw-sh-in {+ from {+ opacity: 0;+ -moz-transform: translateX(-100%);+ }+ to {+ opacity: 1;+ -moz-transform: translateX(0);+ }+}+/* Slide horizontal out */+@keyframes dw-sh-out {+ from {+ opacity: 1;+ transform: translateX(0);+ }+ to {+ opacity: 0;+ transform: translateX(100%);+ }+}+@-webkit-keyframes dw-sh-out {+ from {+ opacity: 1;+ -webkit-transform: translateX(0);+ }+ to {+ opacity: 0;+ -webkit-transform: translateX(100%);+ }+}+@-moz-keyframes dw-sh-out {+ from {+ opacity: 1;+ -moz-transform: translateX(0);+ }+ to {+ opacity: 0;+ -moz-transform: translateX(100%);+ }+}+/* Slide vertical in */+@keyframes dw-dw-sv-in {+ from {+ opacity: 0;+ transform: translateY(-100%);+ }+ to {+ opacity: 1;+ transform: translateY(0);+ }+}+@-webkit-keyframes dw-dw-sv-in {+ from {+ opacity: 0;+ -webkit-transform: translateY(-100%);+ }+ to {+ opacity: 1;+ -webkit-transform: translateY(0);+ }+}+@-moz-keyframes dw-dw-sv-in {+ from {+ opacity: 0;+ -moz-transform: translateY(-100%);+ }+ to {+ opacity: 1;+ -moz-transform: translateY(0);+ }+}+/* Slide vertical out */+@keyframes dw-sv-out {+ from {+ opacity: 1;+ transform: translateY(0);+ }+ to {+ opacity: 0;+ transform: translateY(100%);+ }+}+@-webkit-keyframes dw-sv-out {+ from {+ opacity: 1;+ -webkit-transform: translateY(0);+ }+ to {+ opacity: 0;+ -webkit-transform: translateY(100%);+ }+}+@-moz-keyframes dw-sv-out {+ from {+ opacity: 1;+ -moz-transform: translateY(0);+ }+ to {+ opacity: 0;+ -moz-transform: translateY(100%);+ }+}+/* Slide Down In */+@keyframes dw-sd-in {+ from {+ transform: translateY(-100%);+ }+ to {+ transform: translateY(0);+ }+}+@-webkit-keyframes dw-sd-in {+ from {+ opacity: 1;+ -webkit-transform: translateY(-100%);+ }+ to {+ opacity: 1;+ -webkit-transform: translateY(0);+ }+}+@-moz-keyframes dw-sd-in {+ from {+ -moz-transform: translateY(-100%);+ }+ to {+ -moz-transform: translateY(0);+ }+}+/* Slide down out */+@keyframes dw-sd-out {+ from {+ transform: translateY(0);+ }+ to {+ transform: translateY(-100%);+ }+}+@-webkit-keyframes dw-sd-out {+ from {+ opacity: 1;+ -webkit-transform: translateY(0);+ }+ to {+ opacity: 1;+ -webkit-transform: translateY(-100%);+ }+}+@-moz-keyframes dw-sd-out {+ from {+ -moz-transform: translateY(0);+ }+ to {+ -moz-transform: translateY(-100%);+ }+}+/* Slide Up In */+@keyframes dw-su-in {+ from {+ transform: translateY(100%);+ }+ to {+ transform: translateY(0);+ }+}+@-webkit-keyframes dw-su-in {+ from {+ opacity: 1;+ -webkit-transform: translateY(100%);+ }+ to {+ opacity: 1;+ -webkit-transform: translateY(0);+ }+}+@-moz-keyframes dw-su-in {+ from {+ -moz-transform: translateY(100%);+ }+ to {+ -moz-transform: translateY(0);+ }+}+/* Slide up out */+@keyframes dw-su-out {+ from {+ transform: translateY(0);+ }+ to {+ transform: translateY(100%);+ }+}+@-webkit-keyframes dw-su-out {+ from {+ opacity: 1;+ -webkit-transform: translateY(0);+ }+ to {+ opacity: 1;+ -webkit-transform: translateY(100%);+ }+}+@-moz-keyframes dw-su-out {+ from {+ -moz-transform: translateY(0);+ }+ to {+ -moz-transform: translateY(100%);+ }+}diff --git a/css/ext/mobiscroll/mobiscroll.core.css b/css/ext/mobiscroll/mobiscroll.core.cssnew file mode 100644index 000000000..53a02bf6b--- /dev/null+++ b/css/ext/mobiscroll/mobiscroll.core.css@@ -0,0 +1,365 @@+/* Datewheel overlay */+.dw {+ position: absolute;+ top: 5%;+ left: 0;+ z-index: 1001;+ color: #fff;+ font-family: arial, verdana, sans-serif;+ font-size: 12px;+ text-shadow: none;+ box-sizing: border-box;+ -webkit-box-sizing: border-box;+ -moz-box-sizing: border-box;+ -webkit-user-select: none;+ -moz-user-select: none;+ -ms-user-select: none;+ -ms-touch-action: none;+ -webkit-tap-highlight-color: rgba(0, 0, 0, 0);+ -webkit-backface-visibility: hidden;+}+.dwi {+ position: static;+ display: inline-block;+}+.dwwr {+ min-width: 170px;+ zoom: 1;+ padding: 0 10px;+ text-align: center;+}+/* Datewheel overlay background */+.dw-persp, .dwo {+ width: 100%;+ height: auto;+ position: absolute;+ top: 0;+ left: 0;+ z-index: 1001;+}+.dwo {+ background: #000;+ opacity: .7;+ filter: Alpha(Opacity=70);+ display:none;+}+/* Bubble positionings */+.dw-bubble .dw {+ margin: 20px 0;+}+.dw-bubble .dw-arrw {+ position: absolute;+ left: 0;+ width: 100%;+}+.dw-bubble-top .dw-arrw {+ bottom: -36px;+}+.dw-bubble-bottom .dw-arrw {+ top: -36px;+}+.dw-bubble .dw-arrw-i {+ margin: 0 30px;+ position: relative;+ height: 36px;+}+.dw-bubble .dw-arr {+ display: block;+}+.dw-arr {+ display: none;+ position: absolute;+ left: 0;+ width: 0;+ height: 0;+ border-width: 18px 18px;+ border-style: solid;+ margin-left: -18px;+}+.dw-bubble-bottom .dw-arr {+ top: 0;+ border-color: transparent transparent #fff transparent;+}+.dw-bubble-top .dw-arr {+ bottom: 0;+ border-color: #fff transparent transparent transparent;+}+/* Datewheel wheel container wrapper */+.dwc {+ padding: 30px 2px 5px 2px;+ display: inline-block;+}+/* Datewheel label */+.dwl {+ text-align: center;+ line-height: 30px;+ height: 30px;+ white-space: nowrap;+ position: absolute;+ top: -30px;+ width: 100%;+}+/* Datewheel value */+.dwv {+ padding: 10px 0;+ border-bottom: 1px solid #000;+}+/* Datewheel wheel container */+.dwrc {+ -webkit-border-radius: 3px;+ border-radius: 3px;+}+.dwwc {+ margin: 0;+ padding: 0 2px;+ position: relative;+ background: #000;+ zoom: 1;+}+/* Datewheel wheels */+.dwwl {+ margin: 4px 2px;+ padding: 0 2px;+ position: relative;+ z-index: 5;+}+.dwww {+ position: relative;+ padding: 1px;+}+.dww {+ overflow: hidden;+ position: relative;+ z-index: 2;+}+.dw-moz .dww {+ opacity: .99; /* Fixes Firefox translate overflow bug */+}+.dwsc .dwwl {+ background: #888;+ background: linear-gradient(#000 0%,#333 35%, #888 50%,#333 65%,#000 100%);+ background: -webkit-gradient(linear,left bottom,left top,from(#000),color-stop(0.35, #333),color-stop(0.50, #888),color-stop(0.65, #333),to(#000));+ background: -webkit-linear-gradient(#000 0%,#333 35%, #888 50%,#333 65%,#000 100%);+ background: -moz-linear-gradient(#000 0%,#333 35%, #888 50%,#333 65%,#000 100%);+}+.dwsc .dww {+ color: #fff;+ background: #444;+ background: linear-gradient(#000 0%,#444 45%, #444 55%, #000 100%);+ background: -webkit-gradient(linear,left bottom,left top,from(#000),color-stop(0.45, #444),color-stop(0.55, #444),to(#000));+ background: -webkit-linear-gradient(#000 0%,#444 45%, #444 55%, #000 100%);+ background: -moz-linear-gradient(#000 0%,#444 45%, #444 55%, #000 100%);+}+.dw-bf {+ -webkit-perspective: 1000;+ -webkit-backface-visibility: hidden;+}+.dw-ul {+ position: relative;+ z-index: 2;+}+.dw-li {+ padding: 0 5px;+ display: block;+ text-align: center;+ line-height: 40px;+ font-size: 26px;+ white-space: nowrap;+ text-shadow: 0 1px 1px #000;+ vertical-align: bottom;+ opacity: .3;+ filter: Alpha(Opacity=30);+}+/* Higlighted */+.dw-li.dw-hl {+ background: #fff;+ background: rgba(255,255,255,.3);+}+/* Valid entry */+.dw-li.dw-v {+ opacity: 1;+ filter: Alpha(Opacity=100);+}+/* Hidden entry */+.dw-li.dw-h {+ visibility: hidden;+}+.dw-i {+ position: relative;+ height: 100%;+}+/* Wheel +/- buttons */+.dwwb {+ position: absolute;+ z-index: 4;+ left: 0;+ cursor: pointer;+ width: 100%;+ height: 40px;+ text-align: center;+ opacity: 1;+ transition: opacity .2s linear;+ -webkit-transition: opacity .2s linear;+}+.dwa .dwwb {+ opacity: 0;+}+.dwwbp {+ top: 0;+ -webkit-border-radius: 3px 3px 0 0;+ border-radius: 3px 3px 0 0;+ font-size: 40px;+}+.dwwbm {+ bottom: 0;+ -webkit-border-radius: 0 0 3px 3px;+ border-radius: 0 0 3px 3px;+ font-size: 32px;+ font-weight: bold;+}+.dwpm .dwwc {+ background: transparent;+}+.dwpm .dwwl {+ padding: 0;+}+.dwpm .dw-li {+ text-shadow: none;+}+.dwpm .dwwol {+ display: none;+}+/* Datewheel wheel overlay */+.dwwo {+ position: absolute;+ z-index: 3;+ top: 0;+ left: 0;+ width: 100%;+ height: 100%;+ background: linear-gradient(#000 0%,rgba(44,44,44,0) 52%, rgba(44,44,44,0) 48%, #000 100%);+ background: -webkit-gradient(linear,left bottom,left top,from(#000),color-stop(0.52, rgba(44,44,44,0)),color-stop(0.48, rgba(44,44,44,0)),to(#000));+ background: -webkit-linear-gradient(#000 0%,rgba(44,44,44,0) 52%, rgba(44,44,44,0) 48%, #000 100%);+ background: -moz-linear-gradient(#000 0%,rgba(44,44,44,0) 52%, rgba(44,44,44,0) 48%, #000 100%);+}+/* Background line */+.dwwol {+ position: absolute;+ z-index: 1;+ top: 50%;+ left: 0;+ width: 100%;+ height: 0;+ margin-top: -1px;+ border-top: 1px solid #333;+ border-bottom: 1px solid #555;+}+/* Datewheel button */+.dwbg .dwb {+ cursor: pointer;+ overflow: hidden;+ display: block;+ height: 40px;+ line-height: 40px;+ padding: 0 15px;+ margin: 0 2px;+ font-size: 14px;+ font-weight: bold;+ text-decoration: none;+ text-shadow: 0 -1px 1px #000;+ border-radius: 5px;+ box-shadow: 0 1px 3px rgba(0,0,0,0.5);+ color: #fff;+ background: #000;+ background: linear-gradient(#6e6e6e 50%,#000 50%);+ background: -webkit-gradient(linear,left bottom,left top,color-stop(0.5, #000),color-stop(0.5, #6e6e6e));+ background: -webkit-linear-gradient(#6e6e6e 50%,#000 50%);+ background: -moz-linear-gradient(#6e6e6e 50%,#000 50%);+ white-space: nowrap;+ text-overflow: ellipsis;+ -webkit-box-shadow: 0 1px 3px rgba(0,0,0,0.5);+ -webkit-border-radius: 5px;+ -webkit-backface-visibility: hidden;+}+/* Datewheel button container */+.dwbc {+ padding: 5px 0;+ text-align: center;+}+/* Datewheel button wrapper */+.dwbw {+ display: inline-block;+ width: 50%;+ position: relative;+ z-index: 5;+}+.dwbc-p .dwbw {+ width: 33.33%;+}+/* Hidden label */+.dwhl {+ padding-top: 10px;+}+.dwhl .dwl {+ display: none;+}+/* Multiple selection */+.dwms .dwwms .dw-li {+ padding: 0 40px;+ position: relative;+}+.dwms .dw-msel:after {+ width: 40px;+ text-align: center;+ position: absolute;+ top: 0;+ left: 0;+ content: '✔';+}+/* Backgrounds */+.dwbg {+ background: rgba(38,43,49,0.85);+ border-radius: 3px;+ -webkit-border-radius: 3px;+}+.dwbg .dwpm .dwwl {+ border: 1px solid #aaa;+}+.dwbg .dwpm .dww {+ color: #000;+ background: #fff;+ -webkit-border-radius: 3px;+}+.dwbg .dwwb {+ background: #ccc;+ color: #888;+ text-shadow: 0 -1px 1px #333;+ box-shadow: 0 0 5px #333;+ -webkit-box-shadow: 0 0 5px #333;+}+.dwbg .dwwbp {+ background: linear-gradient(#f7f7f7,#bdbdbd);+ background: -webkit-gradient(linear,left bottom,left top,from(#bdbdbd),to(#f7f7f7));+ background: -webkit-linear-gradient(#f7f7f7,#bdbdbd);+ background: -moz-linear-gradient(#f7f7f7,#bdbdbd);+}+.dwbg .dwwbm {+ background: linear-gradient(#bdbdbd,#f7f7f7);+ background: -webkit-gradient(linear,left bottom,left top,from(#f7f7f7),to(#bdbdbd));+ background: -webkit-linear-gradient(#bdbdbd,#f7f7f7);+ background: -moz-linear-gradient(#bdbdbd,#f7f7f7);+}+.dwbg .dwb-a {+ background: #3c7500;+ background: linear-gradient(#94c840 50%,#3c7500 50%);+ background: -webkit-gradient(linear,left bottom,left top,color-stop(0.5, #3c7500),color-stop(0.5, #94c840));+ background: -webkit-linear-gradient(#94c840 50%,#3c7500 50%);+ background: -moz-linear-gradient(#94c840 50%,#3c7500 50%);+}+.dwbg .dwwl .dwb-a {+ background: #3c7500;+ background: linear-gradient(#94c840,#3c7500);+ background: -webkit-gradient(linear,left bottom,left top,from(#3c7500),to(#94c840));+ background: -webkit-linear-gradient(#94c840,#3c7500);+ background: -moz-linear-gradient(#94c840,#3c7500);+}diff --git a/css/ext/mobiscroll/mobiscroll.ios.css b/css/ext/mobiscroll/mobiscroll.ios.cssnew file mode 100644index 000000000..dbc3a42d3--- /dev/null+++ b/css/ext/mobiscroll/mobiscroll.ios.css@@ -0,0 +1,240 @@+/* iOS Skin */+.ios .dw {+ min-width: 134px;+ padding: 0;+ border: 1px solid #2d3034;+ background: none;+ color: #fff;+ border-radius: 0;+ -webkit-border-radius: 0;+}+.ios .dwo {+ background: none;+}+.ios .dwwr {+ position: relative;+ margin-top: 40px;+ background: #50515d;+ background: linear-gradient(#9f9fa6,#484a55 50%,#272836 50%,#282a39);+ background: -webkit-gradient(linear,left top,left bottom,from(#9f9fa6),color-stop(0.5, #484a55),color-stop(0.5, #272836),to(#282a39));+ background: -webkit-linear-gradient(#9f9fa6,#484a55 50%,#272836 50%,#282a39);+ background: -moz-linear-gradient(#9f9fa6,#484a55 50%,#272836 50%,#282a39);+}+.ios .dwi .dwwr {+ margin-top: 0;+}+.ios .dwv {+ display: none;+}+.ios .dwc {+ padding: 30px 2px;+ margin: 0;+}+.ios .dwhl {+ padding: 10px 2px;+}+.ios .dwwc {+ background: transparent;+}+.ios .dwwl {+ margin: 4px 0;+ border-left: 1px solid #000;+ border-right: 1px solid #000;+ background: #cbcce0;+ background: linear-gradient(#2c2c38 0%,#cbcce0 35%, #cbcce0 65%,#2c2c38 100%);+ background: -webkit-gradient(linear,left bottom,left top,from(#2c2c38),color-stop(0.35, #cbcce0),color-stop(0.65, #cbcce0),to(#2c2c38));+ background: -webkit-linear-gradient(#2c2c38 0%,#cbcce0 35%, #cbcce0 65%,#2c2c38 100%);+ background: -moz-linear-gradient(#2c2c38 0%,#cbcce0 35%, #cbcce0 65%,#2c2c38 100%);+ box-shadow: 0 1px 1px rgba(255,255,255,0.3);+ -webkit-box-shadow: 0 1px 1px rgba(255,255,255,0.3);+}+.ios td:first-child .dwwl {+ border-top-left-radius: 3px;+ border-bottom-left-radius: 3px;+ -webkit-border-top-left-radius: 3px;+ -webkit-border-bottom-left-radius: 3px;+}+.ios td:last-child .dwwl {+ border-top-right-radius: 3px;+ border-bottom-right-radius: 3px;+ -webkit-border-top-right-radius: 3px;+ -webkit-border-bottom-right-radius: 3px;+}+.ios .dwsc .dwwl {+ border-radius: 0;+ -webkit-border-radius: 0;+}+.ios .dwsc .dww {+ background: #fff;+ background: linear-gradient(#333 0%,#999 10%,#fff 30%,#fff 70%,#999 90%,#333 100%);+ background: -webkit-gradient(linear,left bottom,left top,from(#333),color-stop(0.10, #999),color-stop(0.30, #fff),color-stop(0.70, #fff),color-stop(0.90, #999),to(#333));+ background: -webkit-linear-gradient(#333 0%,#999 10%,#fff 30%,#fff 70%,#999 90%,#333 100%);+ background: -moz-linear-gradient(#333 0%,#999 10%,#fff 30%,#fff 70%,#999 90%,#333 100%);+ border-radius: 0;+ -webkit-border-radius: 0;+}+.ios .dw .dwpm .dww {+ background: linear-gradient(#333,#fff 48%,#fff 52%,#333);+ background: -webkit-gradient(linear,left bottom,left top,from(#333),color-stop(0.48, #fff),color-stop(0.52, #fff),to(#333));+ background: -webkit-linear-gradient(#333 0%,#fff 48%,#fff 52%,#333 100%);+ background: -moz-linear-gradient(#333 0%,#fff 48%,#fff 52%,#333 100%);+}+.ios .dw .dwpm .dwwl {+ margin: 4px 2px;+ border: 1px solid #000;+}+.ios .dw .dwpm .dww {+ margin: 0;+ border: 0;+}+.ios .dww .dw-li {+ color: #000;+ font-size: 20px;+ font-weight: bold;+ text-align: right;+ text-shadow: none;+}+.ios .dww .dw-li.dw-hl {+ background: linear-gradient(#0288f3,#005de6);+ background: -webkit-gradient(linear,left bottom,left top,from(#0288f3),to(#005de6));+ background: -webkit-linear-gradient(#0288f3,#005de6);+ background: -moz-linear-gradient(#0288f3,#005de6);+ color: #fff;+}+.ios .dwwo {+ background: linear-gradient(#333 0%,rgba(153,153,153,0) 10%, rgba(153,153,153,0) 90%, #333 100%);+ background: -webkit-gradient(linear,left bottom,left top,from(#333),color-stop(0.1, rgba(153,153,153,0)),color-stop(0.9, rgba(153,153,153,0)),to(#333));+ background: -webkit-linear-gradient(#333 0%,rgba(153,153,153,0) 10%, rgba(153,153,153,0) 90%, #333 100%);+ background: -moz-linear-gradient(#333 0%,rgba(153,153,153,0) 10%, rgba(153,153,153,0) 90%, #333 100%);+}+.ios .dwwol {+ height: 28px;+ padding: 1px;+ margin-top: -16px;+ border-color: #7b8699;+ background: #6f75b0;+ background: linear-gradient(rgba(151, 157, 197, 0.5) 50%,rgba(111, 117, 176, 0.5) 50%);+ background: -webkit-gradient(linear,left bottom,left top,color-stop(0.5, rgba(111, 117, 176, 0.5)),color-stop(0.5, rgba(151, 157, 197, 0.5)));+ background: -webkit-linear-gradient(rgba(151, 157, 197, 0.5) 50%,rgba(111, 117, 176, 0.5) 50%);+ background: -moz-linear-gradient(rgba(151, 157, 197, 0.5) 50%,rgba(111, 117, 176, 0.5) 50%);+ z-index: 10;+ left: -1px;+ box-shadow: 0 1px 3px rgba(0,0,0,0.5);+ -webkit-box-shadow: 0 1px 3px rgba(0,0,0,0.5);+ filter: alpha(opacity=50);+}+.ios .dww .dwwol {+ display: none;+}+.ios .dw .dwbc {+ position: absolute;+ top: -40px;+ left: 0;+ width: 100%;+ height: 28px;+ padding: 5px 0;+ background: #454545;+ background: linear-gradient(rgba(69,69,69,0.7),rgba(37,37,37,0.7) 50%,rgba(16,16,16,0.7) 50%,rgba(0,0,0,0.7));+ background: -webkit-gradient(linear,left top,left bottom,from(rgba(69,69,69,0.7)),color-stop(0.5, rgba(37,37,37,0.7)),color-stop(0.5, rgba(16,16,16,0.7)),to(rgba(0,0,0,0.7)));+ background: -webkit-linear-gradient(rgba(69,69,69,0.7),rgba(37,37,37,0.7) 50%,rgba(16,16,16,0.7) 50%,rgba(0,0,0,0.7));+ background: -moz-linear-gradient(rgba(69,69,69,0.7),rgba(37,37,37,0.7) 50%,rgba(16,16,16,0.7) 50%,rgba(0,0,0,0.7));+ border-bottom: 1px solid #888;+ border-bottom: 1px solid rgba(255,255,255,0.5);+ border-top: 1px solid #888;+ border-top: 1px solid rgba(255,255,255,0.5);+}+.ios .dw .dwb {+ margin: 0 5px;+ padding: 0 10px;+ display: inline-block;+ font-size: 12px;+ height: 26px;+ line-height: 26px;+ border: 1px solid #1f1f1f;+ background: #1a1a1a;+ background: linear-gradient(#7b7b7b,#1a1a1a 50%,#000 50%);+ background: -webkit-gradient(linear,left top,left bottom,from(#7b7b7b),color-stop(0.5, #1a1a1a),color-stop(0.5, #000));+ background: -webkit-linear-gradient(#7b7b7b,#1a1a1a 50%,#000 50%);+ background: -moz-linear-gradient(#7b7b7b,#1a1a1a 50%,#000 50%);+ box-shadow: 0 1px 0 rgba(255,255,255,0.3);+ -webkit-box-shadow: 0 1px 0 rgba(255,255,255,0.3);+}+.ios .dwb-s .dwb {+ border: 1px solid #194aab;+ background: #194aab;+ background: linear-gradient(#82aaff,#3162c4 50%,#194aab 50%);+ background: -webkit-gradient(linear,left top,left bottom,from(#82aaff),color-stop(0.5,#3162c4),color-stop(0.5,#194aab));+ background: -webkit-linear-gradient(#82aaff,#3162c4 50%,#194aab 50%);+ background: -moz-linear-gradient(#82aaff,#3162c4 50%,#194aab 50%);+}+.ios .dwb-a {+ opacity: .8;+ filter: alpha(opacity=80);+}+.ios .dw .dwwb {+ color: #fff;+ border: 0;+ background: #3f4e68;+ background: linear-gradient(#c7d1e2 0%,#808ea6 50%,#75859f 50%,#3f4e68 100%);+ background: -webkit-gradient(linear,left bottom,left top,from(#3f4e68),color-stop(0.5, #75859f),color-stop(0.5, #808ea6),to(#c7d1e2));+ background: -webkit-linear-gradient(#c7d1e2 0%,#808ea6 50%,#75859f 50%,#3f4e68 100%);+ background: -moz-linear-gradient(#c7d1e2 0%,#808ea6 50%,#75859f 50%,#3f4e68 100%);+}+.ios .dw .dwwl .dwb-a {+ background: #252c36;+ background: linear-gradient(#6b6e75 0%,#272e38 50%,#171e28 50%,#252c36 100%);+ background: -webkit-gradient(linear,left bottom,left top,from(#252c36),color-stop(0.5, #171e28),color-stop(0.5, #272e38),to(#6b6e75));+ background: -webkit-linear-gradient(#6b6e75 0%,#272e38 50%,#171e28 50%,#252c36 100%);+ background: -moz-linear-gradient(#6b6e75 0%,#272e38 50%,#171e28 50%,#252c36 100%);+}+.ios .dwb-s, .ios .dwb-n {+ width: auto;+ float: right;+ text-align: right;+}+.ios .dwb-c {+ width: auto;+ float: left;+ text-align: left;+}+/* Bubble positioning */+.ios.dw-bubble .dw {+ padding: 6px;+ background: #afafaf;+ background: linear-gradient(#afafaf, #1b2530 30%);+ background: -webkit-gradient(linear,left top,left bottom,from(#afafaf),color-stop(0.3, #1b2530));+ background: -webkit-linear-gradient(#afafaf, #1b2530 30%);+ background: -moz-linear-gradient(#afafaf, #1b2530 30%);+ box-shadow: 0 0 25px rgba(0,0,0,0.7);+ border-radius: 5px;+ -webkit-border-radius: 5px;+ -webkit-box-shadow: 0 0 25px rgba(0,0,0,0.7);+}+.ios .dw-bubble-bottom .dw-arr {+ border-color: transparent transparent #2d3034 transparent;+}+.ios .dw-bubble-bottom .dw-arr:after {+ content: '';+ position: absolute;+ top: -16px;+ left: -17px;+ border: 17px solid #afafaf;+ border-color: transparent transparent #afafaf transparent;+}+.ios .dw-bubble-top .dw-arr {+ border-color: #1b2530 transparent transparent transparent;+}+/* Multiple select */+.ios .dwwms .dwwol {+ display: none;+}+.ios .dwwms .dw-li {+ padding: 0 5px 0 30px;+ text-align: left;+}+.ios .dw-msel:after {+ width: 30px;+}+.ios .dww .dw-msel {+ color: #215085;+}diff --git a/css/ext/mobiscroll/mobiscroll.jqm.css b/css/ext/mobiscroll/mobiscroll.jqm.cssnew file mode 100644index 000000000..c70e96ee7--- /dev/null+++ b/css/ext/mobiscroll/mobiscroll.jqm.css@@ -0,0 +1,88 @@+/* jQuery Mobile Theme */+.jqm .dwo {+ background: none;+}+.jqm .dw {+ padding: 6px;+ z-index: 1003;+}+.jqm .dwv {+ position: static;+ width: auto;+ padding: .7em 15px .7em 15px;+ border: 0;+}+.jqm .dwwr {+ border: 0;+ padding: 0;+}+.jqm .dwpm .dwwo {+ background: none;+}+.jqm .dwc {+ padding: 30px 5px 5px 5px;+ }+.jqm .dwhl {+ padding: 5px;+}+.jqm .dwwb {+ margin: 0;+ border: 0;+}+.jqm .dwwb span {+ padding: 0;+}+.jqm .dwwbp .ui-btn-inner {+ font-size: 40px;+ border-radius: 3px 3px 0 0;+ -webkit-border-radius: 3px 3px 0 0;+ -moz-border-radius: 3px 3px 0 0;+}+.jqm .dwwbm .ui-btn-inner {+ font-size: 32px;+ border-radius: 0 0 3px 3px;+ -webkit-border-radius: 0 0 3px 3px;+ -moz-border-radius: 0 0 3px 3px;+}+.jqm .dwwbp span {+ font-weight: normal;+}+.jqm .dwbc {+ padding: 0;+}+.jqm .dwbc .ui-btn {+ margin: .5em 5px;+}+.jqm .dwbc .ui-btn-inner {+ font-size: 12px;+}+.jqm .dwpm .dwl {+ border: 0;+ background: none;+}+/* Bubble positioning */+.jqm .dw-bubble-bottom .dw-arr+{+ border-color: transparent transparent #444 transparent;+}+.jqm .dw-bubble-top .dw-arr+{+ border-color: #222 transparent transparent transparent;+}+/* Docked */+.jqm.dw-bottom .dw, .jqm.dw-top .dw {+ padding: 0;+ border-radius: 0;+ -webkit-border-radius: 0;+ -moz-border-radius: 0;+}+.jqm.dw-top .dw {+ border-right: 0;+ border-top: 0;+ border-left: 0;+}+.jqm.dw-bottom .dw {+ border-bottom: 0;+ border-right: 0;+ border-left: 0;+}diff --git a/css/ext/mobiscroll/mobiscroll.sense-ui.css b/css/ext/mobiscroll/mobiscroll.sense-ui.cssnew file mode 100644index 000000000..e856fce6d--- /dev/null+++ b/css/ext/mobiscroll/mobiscroll.sense-ui.css@@ -0,0 +1,61 @@+/* Sense UI Skin */+.sense-ui .dw {+ padding: 0;+ background: #333;+ border: 2px solid #fff;+ color: #fff;+}+.sense-ui .dwwr {+ padding: 0;+}+.sense-ui .dwv {+ padding: 5px 10px;+ border-bottom: 1px solid #666;+ text-align: left;+}+.sense-ui .dwwc {+ background: #333;+}+.sense-ui .dw .dwpm .dwwl,+.sense-ui .dw .dwpm .dww {+ background: #fff;+ border: 0;+ padding: 0;+}+.sense-ui .dwbc {+ padding: 5px 1px;+ background: #000;+ background: linear-gradient(#666 50%,#000 50%);+ background: -webkit-gradient(linear,left bottom,left top,color-stop(0.5, #000),color-stop(0.5, #666));+ background: -moz-linear-gradient(#666 50%,#000 50%);+ background: -o-linear-gradient(#666 50%,#000 50%);+}+.sense-ui .dw .dwb {+ margin: 0 5px;+ border: 1px solid #333;+ background: #222;+ background: linear-gradient(#444,#000);+ background: -webkit-gradient(linear,left bottom,left top,from(#000),to(#444));+ background: -moz-linear-gradient(#444,#000);+ background: -o-linear-gradient(#444,#000);+ box-shadow: inset 0 0 5px #000;+}+.sense-ui .dw .dwb-a {+ background: #3c7500;+ background: linear-gradient(#94c840,#3c7500);+ background: -webkit-gradient(linear,left bottom,left top,from(#3c7500),to(#94c840));+ background: -moz-linear-gradient(#94c840,#3c7500);+ background: -o-linear-gradient(#94c840,#3c7500);+}+/* Docked */+.sense-ui.dw-top .dw {+ border: 0;+ border-radius: 0;+ -webkit-border-radius: 0;+}+.sense-ui.dw-bottom .dw {+ border: 0;+ border-top: 1px solid #666;+ border-radius: 0;+ -webkit-border-radius: 0;+}diff --git a/css/ext/mobiscroll/mobiscroll.wp.css b/css/ext/mobiscroll/mobiscroll.wp.cssnew file mode 100644index 000000000..fd237dcf6--- /dev/null+++ b/css/ext/mobiscroll/mobiscroll.wp.css@@ -0,0 +1,404 @@+.wp .dw {+ background: #1f1f1f;+ border-radius: 0;+ -webkit-border-radius: 0;+}+.wp .dwwr {+ padding: 10px;+}+.wp .dwv {+ display: none;+}+.wp .dwc {+ padding: 30px 0 0 0;+ vertical-align: middle;+}+.wp .dwhl {+ padding: 0;+}+.wp .dwwc {+ padding: 3px;+ background: none;+}+.wp .dwwl {+ margin: 0;+ padding: 0 2px;+ background: none;+}+.wp .dwl {+ color: #fff;+}+.wp .dw .dwwl .dww {+ background: none;+ border: 0;+ color: #fff;+}+.wp .dw-li {+ position: relative;+ padding: 0;+ font-size: 26px;+ letter-spacing: -1px;+ text-align: left;+ text-shadow: none;+ opacity: 0;+ box-sizing: border-box;+ filter: Alpha(Opacity=0);+ /*transition: opacity .3s linear;*/+ -webkit-box-sizing: border-box;+ /*-webkit-transition: opacity .3s linear;*/+ -moz-box-sizing: border-box;+ /*-moz-transition: opacity .3s linear;*/+}+.wp .dw-i {+ position: relative;+ top: 4%;+ height: 92%;+ padding: 0 5px;+ border: 1px solid #4c4c4c;+ box-sizing: border-box;+ -webkit-box-sizing: border-box;+ -moz-box-sizing: border-box;+ filter: inherit;+}+.wp .wpa .dw-li, .wp .dwa .dw-li {+ opacity: .3;+ filter: Alpha(Opacity=30);+}+.wp .wpa .dw-v, .wp .dwa .dw-v, .wp .wpam .dw-v {+ opacity: 1;+ filter: Alpha(Opacity=100);+}+.wp .dw-day, .wp .dw-mon {+ display: block;+ color: #a9a9a9;+ line-height: 18px;+ font-size: 11px;+ letter-spacing: normal;+ position: absolute;+ bottom: 0;+ filter: inherit;+}+.wp .dw-sel {+ opacity: 1;+ filter: Alpha(Opacity=100);+}+.wp .dw .dw-sel .dw-i {+ color: #fff;+ background: #4c4c4c;+ /*transition: all .1s linear;+ -webkit-transition: all .1s linear;+ -moz-transition: all .1s linear;*/+}+.wp .dw-sel .dw-day, .wp .dw-sel .dw-mon {+ color: #fff;+}+.wp .dw-hl {+ background: none;+}+.wp .dw-hl .dw-i {+ background: #4c4c4c;+}+.wp .dwa .dww .dw-sel .dw-i {+ border: 1px solid #4c4c4c;+ background-color: transparent;+}+.wp .dwa .dw-day, .wp .dwa .dw-month {+ color: #a9a9a9;+}+.wp .dwwo {+ display: none;+}+.wp .dwwol {+ display: none;+}+.wp .dwbc {+ padding: 0;+}+.wp .dwbw {+ float: none;+ width: auto;+}+.wp .dw .dwb {+ position: relative;+ top: 0;+ min-width: 32px;+ display: inline-block;+ height: 20px;+ padding: 29px 5px 0 5px;+ background: none;+ box-shadow: none;+ line-height: 20px;+ font-size: 11px;+ font-weight: normal;+ text-transform: lowercase;+ text-shadow: none;+ transition: top .1s linear;+ -webkit-box-shadow: none;+ -webkit-transition: top .1s linear;+ -moz-transition: top .1s linear;+}+.wp .dwb:after {+ content: '';+ position: absolute;+ top: 3px;+ left: 50%;+ width: 26px;+ height: 26px;+ margin: 0 -13px;+ background: url(wp_icons.png) center center no-repeat;+}+.wp .dwb-s .dwb:after {+ background-position: 0 0;+}+.wp .dwb-c .dwb:after {+ background-position: -26px 0;+}+.wp .dwb-n .dwb:after {+ background-position: -52px 0;+}+.wp .dwb-s .dwb-a:after {+ background-position: 0 -26px;+}+.wp .dwb-c .dwb-a:after {+ background-position: -26px -26px;+}+.wp .dwb-n .dwb-a:after {+ background-position: -52px -26px;+}+.wp .dwb.dwb-a {+ top: -3px;+}+/* +/- buttons */+.wp .dw .dwwl .dwb-a {+ background: #1f1f1f;+}+.wp .dw .dwpm .dwwl {+ border: 0;+}+.wp .dw .dwwb {+ background: #1f1f1f;+ border-radius: 0;+ box-shadow: none;+ box-sizing: border-box;+ color: #a9a9a9;+ -webkit-box-shadow: none;+ -webkit-border-radius: 0;+ -webkit-box-sizing: border-box;+ -moz-box-sizing: border-box;+}+.wp .dwwb span {+ position: absolute;+ top: 50%;+ left: 50%;+ width: 26px;+ height: 0;+ padding-top: 26px;+ overflow: hidden;+ margin: -13px;+ display: block;+ background: url(wp_icons.png) center center no-repeat;+}+.wp .dwwbp span {+ background-position: -78px 0;+}+.wp .dwwbp.dwb-a span {+ background-position: -78px -26px;+}+.wp .dwwbm span {+ background-position: -104px 0;+}+.wp .dwwbm.dwb-a span {+ background-position: -104px -26px;+}+/* Bubble positioning */+.wp .dw-bubble-bottom .dw-arr {+ border-color: transparent transparent #1f1f1f transparent;+}+.wp .dw-bubble-top .dw-arr {+ border-color: #1f1f1f transparent transparent transparent;+}+/* Multiple select */+.wp .dwwms .dw-li {+ opacity: .3;+ filter: Alpha(Opacity=30);+ padding: 0 0 0 30px;+}+.wp .dwwms .dw-v {+ opacity: 1;+ filter: Alpha(Opacity=100);+}+.wp .dwc .dwwms .dw-i,+.wp .dwc .dwwms .dw-sel .dw-i,+.wp .dwc .dwwms .dw-hl .dw-i,+.wp .dwc .dwwms.dwa .dw-sel .dw-i {+ border: 0;+ background: none;+}+.wp .dwwms .dw-li:after {+ content: '';+ position: absolute;+ top: 50%;+ left: 5px;+ width: 20px;+ height: 20px;+ margin-top: -10px;+ font-size: 18px;+ line-height: 20px;+ background: #4c4c4c;+ color: #fff;+}+.wp .dwwms .dw-msel:after {+ content: '✔';+}+/* Light version */+.wp.light .dw {+ background: #dedede;+}+.wp.light .dwv,+.wp.light .dwl,+.wp.light .dwb {+ color: #000;+}+.wp.light .dw-li {+ color: #6b6b6b;+}+.wp.light .dw-i {+ border-color: #b5b5b5;+}+.wp.light .dw-sel .dw-i {+ background: #b5b5b5;+}+.wp.light .dw-hl .dw-i {+ color: #fff;+ background: #b5b5b5;+}+.wp.light .dw-day, .wp.light .dw-mon {+ color: #6b6b6b;+}+.wp.light .dw-sel .dw-day, .wp.light .dw-sel .dw-mon {+ color: #fff;+}+.wp.light .dw .dwa .dw-sel .dw-i {+ color: #6b6b6b;+ border: 1px solid #b5b5b5;+ background-color: transparent;+}+.wp.light .dw .dwc .dwa .dw-day, .wp.light .dw .dwc .dwa .dw-mon {+ color: #6b6b6b;+}+.wp.light .dwb:after {+ background-image: url(wp_icons_light.png);+}+.wp.light .dw .dwwb {+ background: #dedede;+}+.wp.light .dwwb span {+ background-image: url(wp_icons_light.png);+}+/* Bubble positioning */+.wp.light .dw-bubble-bottom .dw-arr {+ border-color: transparent transparent #dedede transparent;+}+.wp.light .dw-bubble-top .dw-arr {+ border-color: #dedede transparent transparent transparent;+}+/* Multiple select */+.wp.light .dwc .dwwms .dw-i,+.wp.light .dwwms.dwa .dw-sel .dw-i {+ border: 0;+ background: none;+ color: #000;+}+.wp.light .dwwms .dw-li:after {+ background: #b5b5b5;+}+.wp.light .wp-none .dwwms .dw-li:after {+ color: #000;+}+/* Accents */+.wp.light .wp-none .dw-sel .dw-i, .wp.light .wp-none .dw-hl .dw-i {+ color: #000;+}+.wp.light .wp-none .dw-day, .wp.light .wp-none .dw-mon {+ color: #6b6b6b;+}+.wp .wp-lime .dw-sel .dw-i, .wp .wp-lime .dw-hl .dw-i, .wp .wp-lime .dwwms .dw-li:after {+ background: #a4c400;+ border-color: #a4c400;+}+.wp .wp-green .dw-sel .dw-i, .wp .wp-green .dw-hl .dw-i, .wp .wp-green .dwwms .dw-li:after {+ background: #60a917;+ border-color: #60a917;+}+.wp .wp-emerald .dw-sel .dw-i, .wp .wp-emerald .dw-hl .dw-i, .wp .wp-emerald .dwwms .dw-li:after {+ background: #008a00;+ border-color: #008a00;+}+.wp .wp-teal .dw-sel .dw-i, .wp .wp-teal .dw-hl .dw-i, .wp .wp-teal .dwwms .dw-li:after {+ background: #00aba9;+ border-color: #00aba9;+}+.wp .wp-cyan .dw-sel .dw-i, .wp .wp-cyan .dw-hl .dw-i, .wp .wp-cyan .dwwms .dw-li:after {+ background: #1ba1e2;+ border-color: #1ba1e2;+}+.wp .wp-cobalt .dw-sel .dw-i, .wp .wp-cobalt .dw-hl .dw-i, .wp .wp-cobalt .dwwms .dw-li:after {+ background: #0050ef;+ border-color: #0050ef;+}+.wp .wp-indigo .dw-sel .dw-i, .wp .wp-indigo .dw-hl .dw-i, .wp .wp-indigo .dwwms .dw-li:after {+ background: #6a00ff;+ border-color: #6a00ff;+}+.wp .wp-violet .dw-sel .dw-i, .wp .wp-violet .dw-hl .dw-i, .wp .wp-violet .dwwms .dw-li:after {+ background: #aa00ff;+ border-color: #aa00ff;+}+.wp .wp-pink .dw-sel .dw-i, .wp .wp-pink .dw-hl .dw-i, .wp .wp-pink .dwwms .dw-li:after {+ background: #f472d0;+ border-color: #f472d0;+}+.wp .wp-magenta .dw-sel .dw-i, .wp .wp-magenta .dw-hl .dw-i, .wp .wp-magenta .dwwms .dw-li:after {+ background: #d80073;+ border-color: #d80073;+}+.wp .wp-crimson .dw-sel .dw-i, .wp .wp-crimson .dw-hl .dw-i, .wp .wp-crimson .dwwms .dw-li:after {+ background: #a20025;+ border-color: #a20025;+}+.wp .wp-red .dw-sel .dw-i, .wp .wp-red .dw-hl .dw-i, .wp .wp-red .dwwms .dw-li:after {+ background: #e51400;+ border-color: #e51400;+}+.wp .wp-orange .dw-sel .dw-i, .wp .wp-orange .dw-hl .dw-i, .wp .wp-orange .dwwms .dw-li:after {+ background: #fa6800;+ border-color: #fa6800;+}+.wp .wp-amber .dw-sel .dw-i, .wp .wp-amber .dw-hl .dw-i, .wp .wp-amber .dwwms .dw-li:after {+ background: #f0a30a;+ border-color: #f0a30a;+}+.wp .wp-yellow .dw-sel .dw-i, .wp .wp-yellow .dw-hl .dw-i, .wp .wp-yellow .dwwms .dw-li:after {+ background: #d8c100;+ border-color: #d8c100;+}+.wp .wp-brown .dw-sel .dw-i, .wp .wp-brown .dw-hl .dw-i, .wp .wp-brown .dwwms .dw-li:after {+ background: #825a2c;+ border-color: #825a2c;+}+.wp .wp-olive .dw-sel .dw-i, .wp .wp-olive .dw-hl .dw-i, .wp .wp-olive .dwwms .dw-li:after {+ background: #6d8764;+ border-color: #6d8764;+}+.wp .wp-steel .dw-sel .dw-i, .wp .wp-steel .dw-hl .dw-i, .wp .wp-steel .dwwms .dw-li:after {+ background: #647687;+ border-color: #647687;+}+.wp .wp-mauve .dw-sel .dw-i, .wp .wp-mauve .dw-hl .dw-i, .wp .wp-mauve .dwwms .dw-li:after {+ background: #76608a;+ border-color: #76608a;+}+.wp .wp-sienna .dw-sel .dw-i, .wp .wp-sienna .dw-hl .dw-i, .wp .wp-sienna .dwwms .dw-li:after {+ background: #7a3b3f;+ border-color: #7a3b3f;+}diff --git a/css/ext/mobiscroll/wp_icons.png b/css/ext/mobiscroll/wp_icons.pngnew file mode 100644index 000000000..22b1d7c43Binary files /dev/null and b/css/ext/mobiscroll/wp_icons.png differdiff --git a/css/ext/mobiscroll/wp_icons_light.png b/css/ext/mobiscroll/wp_icons_light.pngnew file mode 100644index 000000000..442fd7467Binary files /dev/null and b/css/ext/mobiscroll/wp_icons_light.png differdiff --git a/css/map.css b/css/map.cssindex 8acdadff8..26b705938 100644--- a/css/map.css+++ b/css/map.css@@ -30,12 +30,14 @@ div.olControlScaleLineCustom {margin-top:-2px;text-align: center;background-color:rgba(38,38,38,0.4);+ font-size: 0.9em;}.olControlScaleLineCustomTop {border: solid 2px black;border-top: none;text-align: center;background-color:rgba(38,38,38,0.4);+ font-size: 0.9em;}diff --git a/css/products.css b/css/products.cssindex 6586dbb5b..8c76d7b87 100644--- a/css/products.css+++ b/css/products.css@@ -1,16 +1,14 @@-#productsHolder {display:block; float:left; z-index:200; width:238px; height:300px; position:relative; top:10%;}--.products {display:block; float:left; width:210px; min-height:275px; max-height:300px; position:relative; overflow:hidden;+.products {display:block; float:left; z-index:292; min-width:238px; top:2%; width:25%; height:65%; position:relative; overflow:hidden;background: rgba(38,43,49,0.65); border-radius:0 10px 10px 0;}-.ui-tabs-nav {clear:both; display:block; overflow:hidden; width:100%; border-radius:0; border-bottom: 3px #00457b solid;}-.ui-tabs-nav li a {/*border-radius: 10px 10px 0 0;*/ font:14px "gill sans", sans-serif; display:inline-block; float: left; color:#ffffff; font-size: 14px; font-weight:400; border:none; padding:6px 0px 6px 0px; width:50%;-+.ui-tabs-nav {clear:both; display:inline-block; overflow:hidden; width:90%; border-radius:0; border-bottom: 3px #00457b solid; }+.ui-tabs-nav li {height:100%; display:inline-block; float:left; width:50%;}+.ui-tabs-nav li a {/*border-radius: 10px 10px 0 0;*/ color: #fff; font-size:1.1em; font-weight: 400; display:block; border:none; padding:0.5em 0; width:100%;text-align:center; text-decoration:none; text-shadow:none;}-.ui-tabs-nav li.first.ui-state-active a {background: -moz-linear-gradient(top, rgba(255,255,255,0.7) 0%, rgba(11,95,160,0.7) 23%, rgba(0,88,156,0.7) 24%, rgba(0,81,144,0.7) 99%, rgba(0,81,144,0.7) 100%); /* FF3.6+ */+.ui-tabs-nav li.first.ui-state-active a { background: -moz-linear-gradient(top, rgba(255,255,255,0.7) 0%, rgba(11,95,160,0.7) 23%, rgba(0,88,156,0.7) 24%, rgba(0,81,144,0.7) 99%, rgba(0,81,144,0.7) 100%); /* FF3.6+ */background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgba(255,255,255,0.7)), color-stop(23%,rgba(11,95,160,0.7)), color-stop(24%,rgba(0,88,156,0.7)), color-stop(99%,rgba(0,81,144,0.7)), color-stop(100%,rgba(0,81,144,0.7))); /* Chrome,Safari4+ */background: -webkit-linear-gradient(top, rgba(255,255,255,0.7) 0%,rgba(11,95,160,0.7) 23%,rgba(0,88,156,0.7) 24%,rgba(0,81,144,0.7) 99%,rgba(0,81,144,0.7) 100%); /* Chrome10+,Safari5.1+ */background: -o-linear-gradient(top, rgba(255,255,255,0.7) 0%,rgba(11,95,160,0.7) 23%,rgba(0,88,156,0.7) 24%,rgba(0,81,144,0.7) 99%,rgba(0,81,144,0.7) 100%); /* Opera 11.10+ */@@ -37,3 +35,16 @@ filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#b3ffffff', e}+.toggleButtonHolder { display:inline; overflow:hidden;}++@media screen and (max-width: 720px) and (orientation: portrait){+ .products {display:block; float:left; min-width:238px; width:100%; height:100%; position:absolute !important; overflow:hidden;+ background: rgba(38,43,49,0.95); border-radius:0 10px 10px 0; top:0;}+ .bank { height:96%;/*box-shadow: 0 0 4px 1px #bbb;*/ }+ #selectorboxcontent { max-height:97%;}+ .bank li.item a {float:right; color:#fff; margin-right:1.6em;}+ img.bank-item-img { display:block; height: 1.6em; width:auto;}++}++diff --git a/css/selector.css b/css/selector.cssindex 30dcd9bb4..df85ffbac 100644--- a/css/selector.css+++ b/css/selector.css@@ -1,10 +1,10 @@#selector {display:none;}-.selector { display:inline-block; float:left; width: 210px; height:245px; padding-bottom:20px; font: 10px/12px "Gill Sans","helvetica",sans-serif !important; color: #141b4c; text-shadow:none; overflow:auto; }+div.selector { display:inline-block; float:left; width: 100%; height:100%; font-size: 1em; color: #141b4c; text-shadow:none; }.selector h1,h2,h3,h4 {margin:0px; padding:0px;}-.selector h2 {font:14px "gill sans", sans-serif; display:inline-block; float: right; color:#ffffff; font-size: 14px; font-weight:100; border:none; padding:9px 30px 9px 30px;+.selector h2 { display:inline-block; float: right; color:#ffffff; border:none; padding:9px 30px 9px 30px;background: -moz-linear-gradient(top, rgba(255,255,255,0.7) 0%, rgba(160,121,11,0.7) 23%, rgba(156,115,0,0.7) 24%, rgba(144,106,0,0.7) 99%, rgba(144,106,0,0.7) 100%); /* FF3.6+ */background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgba(255,255,255,0.7)), color-stop(23%,rgba(160,121,11,0.7)), color-stop(24%,rgba(156,115,0,0.7)), color-stop(99%,rgba(144,106,0,0.7)), color-stop(100%,rgba(144,106,0,0.7))); /* Chrome,Safari4+ */background: -webkit-linear-gradient(top, rgba(255,255,255,0.7) 0%,rgba(160,121,11,0.7) 23%,rgba(156,115,0,0.7) 24%,rgba(144,106,0,0.7) 99%,rgba(144,106,0,0.7) 100%); /* Chrome10+,Safari5.1+ */@@ -16,9 +16,9 @@ filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#b3ffffff', e}.selector .tabContainer {border-bottom: 2px #906a00 solid; }-.selector h3 {display:inline-block; float: left; color:#333333; font-size: 12px; font-weight:100; border:none; text-decoration:none; }+.selector h3 {display:inline-block; float: left; color:#333333; font-size: 1em; border:none; text-decoration:none; }.selector div,.selector ul {display:block; overflow:hidden;margin:0 auto; width:100%;}-.selector li.selectorItem {padding:8px 9px 8px 3px; width:198px; display:block; float:left; overflow:hidden;+.selector li.selectorItem {padding:8px 0px 8px 0px; width:100%; display:block; float:left; overflow:hidden;color:#fffbe7;background: -moz-linear-gradient(top, rgba(0,0,0,0.24) 0%, rgba(2,2,2,0.24) 1%, rgba(78,78,78,0.24) 50%, rgba(0,0,0,0.24) 100%); /* FF3.6+ */background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgba(0,0,0,0.24)), color-stop(1%,rgba(2,2,2,0.24)), color-stop(50%,rgba(78,78,78,0.24)), color-stop(100%,rgba(0,0,0,0.24))); /* Chrome,Safari4+ */@@ -28,40 +28,26 @@ background: -ms-linear-gradient(top, rgba(0,0,0,0.24) 0%,rgba(2,2,2,0.24) 1%,rgbackground: linear-gradient(to bottom, rgba(0,0,0,0.24) 0%,rgba(2,2,2,0.24) 1%,rgba(78,78,78,0.24) 50%,rgba(0,0,0,0.24) 100%); /* W3C */filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#3d000000', endColorstr='#3d000000',GradientType=0 ); /* IE6-9 */}.selector li.selectorItem input {float:right;}-.selector li.selectorItem h4 {font-size:9px !important; font-weight:bold !important; color:#fffbe7 !important;padding: 0 3px;}-.selector li.selectorItem p {padding: 0 3px; }-.selector ul.category { border-radius:5px; max-height:90px; float:left; }-.selector h3.head {display:block; float: left; color:#ffffff; font-size: 10px !important; width:204px; font-weight:100; border:none; text-decoration:none; background: rgba(120,120,120,.7); margin-top:2px; padding: 1px 3px !important;}-.selector a.flowbutton {text-decoration:none; display:inline-block; float: left; color:#ffffff !important; font-size: 14px; font-weight:100; border:none; padding:6px 0; margin-top:20px; margin-left:5px;}+.selector li.selectorItem h4 {font-size:0.9em; color:#fffbe7;padding: 0 3px;}+.selector li.selectorItem p {padding: 0 3px; font-size:0.8em; }+.selector ul.category { float:left; overflow:auto;}+.selector h3.head {display:block; float: left; color:#ffffff; width:100%; border:none; text-decoration:none; background: rgba(120,120,120,.7); margin-top:2px; padding: 1px 3px;}+.selector a.flowbutton {text-decoration:none; display:inline-block; float: left; color:#ffffff; font-size: 1.4em; border:none; padding:6px 0; margin-top:20px; margin-left:5px;}.selector ul li div {padding:0 !important;}.selector ul.toplevel {padding:0px;}.selector ul.toplevel li {float:left; width:auto; margin: 20px 20px 0 0;}.selector ul.toplevel img {border-radius:5px; border:#fff 2px solid; }-.selector ul.toplevel a p {width:100%; text-align:center; color:#ffffff; font-weight:400; font-size: 12px;}+.selector ul.toplevel a p {width:100%; text-align:center; color:#ffffff; font-size: 1.2em;}#selector .bd {background: rgba(38, 43, 49, 0.65) !important; border-radius: 0 0 10px 10px; }#selector .hd {background: rgba(38, 43, 49, 0.65) !important;border-radius: 10px 10px 0 0; }#selector_c .yui-panel {border-radius:10px;}#selector_c .underlay {border-radius:10px;}-.search {display: inline-block; width:56%; height:16px; padding:2px 2%; margin:0px; line-height:12px; font-size:10px; position:relative; border:none; }-.select {display: inline-block; width:40%; height:16px; padding:2px 0; line-height:12px; font-size:10px; background:#ffffff; border:none; }+.search {display: inline-block; width:56%; padding:0.3em; margin:0px; font-size:1em; position:relative; border:none; }+.select {display: inline-block; width:40%; padding:0.3em 0; font-size:1em; background-color:#ffffff; background-image:none;border:none; }+.select option {-webkit-appearance: none;}-.facetedSearch {display:block; background:#fff; width:96% !important; margin: 5px auto !important; border-radius: 5px; }+div.facetedSearch {display:block; background:#fff; width:96%; margin: .5em auto; border-radius: 5px; }+#selectorboxcontent { height:100%;}-input[type="checkbox"] {- display:none;-}-input[type="checkbox"] {- display:inline-block;- width:19px;- height:19px;- margin:-1px 4px 0 0;- vertical-align:middle;- background:url("../images/checkboxes.png");- cursor:pointer;-}--input[type="checkbox"]:checked {- background:url("../images/checkboxes.png") -19px top no-repeat;-}diff --git a/css/sote.css b/css/sote.cssindex d1052809c..fa7f2ecc4 100644--- a/css/sote.css+++ b/css/sote.css@@ -1,6 +1,7 @@-html,body, div, ul, li {display:block; margin:0; padding:0; }-body {/*min-width:600px;*/ width:100%;}+html,body, div, ul, li, p, h1, h2, h3, h4, h5, h6 {display:block; margin:0; padding:0; font: 100 12.8px/16px "helvetica",sans-serif;}+body {min-width:320px; width:100%;}div {display:block;}+h1, h2, h3, h4, h5, h6 { font-weight:400; }.yui-skin-sam .yui-panel {background: transparent; width:700px; font: 13px "Gill Sans", sans-serif; font-weight:100;}#selector_c .yui-panel {background: transparent; width:210px; font: 13px "Gill Sans", sans-serif; font-weight:100;}@@ -14,6 +15,16 @@ div {display:block;}.yui-skin-sam .yui-panel-container .bd a {color: #48a8ff; }#splash_c.yui-overlay-hidden, #conclusionPanel_c.yui-overlay-hidden {display:none;}+.jspVerticalBar {width:4px !important; background:transparent;}+.jspTrack {+ background: #555555;+} /* or just remove the background property*/++.jspDrag {+ background: #cccccc;+ padding:2px 0;+}+#switch { overflow:hidden; z-index:1000; }#switch div{display:block; }#switch a,div.sw_current {display:block !important; width:40px; height:40px;}@@ -43,7 +54,7 @@ div {display:block;}#permpanel h3 {color:#FFFFFF; font: 12px "Gill Sans", sans-serif; font-weight:100; text-decoration:none;}#permpanel input[type='text']{width:280px;}-div.horizontalContainer {width:100%; display:block; float:left; position:absolute; overflow:hidden; bottom:10px; z-index:200; padding: 5px 0 5px 0;}+div.horizontalContainer {width:100%; height:17%; display:block; float:left; position:absolute; overflow:hidden; bottom:10px; z-index:200; padding: 5px 0 5px 0;}/*#imgDownloadLink,#aboutus,#permalink {float:right; margin-top:5px; position:relative; z-index:1002;display:block; width:50px; }#imgDownloadLink,#aboutus,#permalink img {width:50px; height:44.5px; border:none;}#imgDownloadLink,#aboutus,#permalink a{text-decoration:none; border:none;}*/diff --git a/images/close.png b/images/close.pngindex a9868beb3..537f0f18b 100644Binary files a/images/close.png and b/images/close.png differdiff --git a/images/invisible.png b/images/invisible.pngindex 3733e296f..599d0ee0e 100644Binary files a/images/invisible.png and b/images/invisible.png differdiff --git a/images/visible.png b/images/visible.pngindex ace5ef313..2f89d0c92 100644Binary files a/images/visible.png and b/images/visible.png differdiff --git a/index.html b/index.htmlindex 46a3a7f40..ded252ead 100755--- a/index.html+++ b/index.html@@ -35,7 +35,8 @@<!-- css.dev --> <link type="text/css" href="css/ext/joyride-2.0.3/joyride-2.0.3.css" rel="Stylesheet"/><!-- css.dev --> <link type="text/css" href="css/ext/jcrop-0.9.10-p1/jcrop.css" rel="Stylesheet" />- <!-- css.dev --> <link type="text/css" href="css/ext/jquery.mCustomScrollbar/jquery.mCustomScrollbar.css" rel="Stylesheet" />+ <!-- css.dev <link type="text/css" href="css/ext/jquery.mCustomScrollbar/jquery.mCustomScrollbar.css" rel="Stylesheet" /> -->+ <!-- css.dev --> <link type="text/css" href="css/ext/jscrollpane/jquery.jscrollpane.css" rel="Stylesheet" /><!-- css.dev --> <link type="text/css" href="css/map.css" rel="Stylesheet" /><!-- css.dev --> <link type="text/css" href="css/dateSpan.css" rel="Stylesheet" />@@ -56,10 +57,42 @@<!-- js.dev --> <script type="text/javascript" src="js/ext/jquery-1.6.4/jquery.js"></script><!-- js.dev --> <script type="text/javascript" src="js/ext/jqueryui-1.8.16/jquery-ui.min.js" ></script><!-- js.dev --> <script type="text/javascript" src="js/ext/jquery.mobile-1.0rc2/jquery.mobile.js"></script>- <!-- js.dev --> <script type="text/javascript" src="js/ext/jquery.mCustomScrollbar/jquery.mCustomScrollbar.concat.min.js"></script>+ <!-- js.dev <script type="text/javascript" src="js/ext/jquery.mCustomScrollbar/jquery.mCustomScrollbar.concat.min.js"></script> -->+ <!-- js.dev --> <script type="text/javascript" src="js/ext/jscrollpane/jquery.mousewheel.js"></script>+ <!-- js.dev --> <script type="text/javascript" src="js/ext/jscrollpane/mwheelIntent.js"></script>+ <!-- js.dev --> <script type="text/javascript" src="js/ext/jscrollpane/jquery.jscrollpane.min.js"></script>++ <script src="js/ext/mobiscroll/mobiscroll.core.js" type="text/javascript"></script>++ <script src="js/ext/mobiscroll/mobiscroll.datetime.js" type="text/javascript"></script>+ <script src="js/ext/mobiscroll/mobiscroll.select.js" type="text/javascript"></script>++ <script src="js/ext/mobiscroll/mobiscroll.jqm.js" type="text/javascript"></script>+ <script src="js/ext/mobiscroll/mobiscroll.ios.js" type="text/javascript"></script>+ <script src="js/ext/mobiscroll/mobiscroll.android.js" type="text/javascript"></script>+ <script src="js/ext/mobiscroll/mobiscroll.android-ics.js" type="text/javascript"></script>+ <script src="js/ext/mobiscroll/mobiscroll.wp.js" type="text/javascript"></script>++ <script src="js/ext/mobiscroll/i18n/mobiscroll.i18n.de.js" type="text/javascript"></script>+ <script src="js/ext/mobiscroll/i18n/mobiscroll.i18n.es.js" type="text/javascript"></script>+ <script src="js/ext/mobiscroll/i18n/mobiscroll.i18n.fr.js" type="text/javascript"></script>+ <script src="js/ext/mobiscroll/i18n/mobiscroll.i18n.hu.js" type="text/javascript"></script>+ <script src="js/ext/mobiscroll/i18n/mobiscroll.i18n.it.js" type="text/javascript"></script>+ <script src="js/ext/mobiscroll/i18n/mobiscroll.i18n.no.js" type="text/javascript"></script>+ <script src="js/ext/mobiscroll/i18n/mobiscroll.i18n.pt-BR.js" type="text/javascript"></script>+ <script src="js/ext/mobiscroll/i18n/mobiscroll.i18n.zh.js" type="text/javascript"></script>++ <link href="css/ext/mobiscroll/mobiscroll.core.css" rel="stylesheet" type="text/css" />+ <link href="css/ext/mobiscroll/mobiscroll.jqm.css" rel="stylesheet" type="text/css" />+ <link href="css/ext/mobiscroll/mobiscroll.android.css" rel="stylesheet" type="text/css" />+ <link href="css/ext/mobiscroll/mobiscroll.android-ics.css" rel="stylesheet" type="text/css" />+ <link href="css/ext/mobiscroll/mobiscroll.ios.css" rel="stylesheet" type="text/css" />+ <link href="css/ext/mobiscroll/mobiscroll.sense-ui.css" rel="stylesheet" type="text/css" />+ <link href="css/ext/mobiscroll/mobiscroll.wp.css" rel="stylesheet" type="text/css" />+ <link href="css/ext/mobiscroll/mobiscroll.animation.css" rel="stylesheet" type="text/css" />- <!-- js.dev --> <script type="text/javascript" src="js/ext/yui-2.9.0/yahoo/yahoo.js"></script>+ <!-- js.dev --> <script type="text/javascript" src="js/ext/yui-2.9.0/yahoo/yahoo.js"></script><!-- js.dev --> <script type="text/javascript" src="js/ext/yui-2.9.0/event/event.js"></script><!-- js.dev --> <script type="text/javascript" src="js/ext/yui-2.9.0/dom/dom.js"></script><!-- js.dev --> <script type="text/javascript" src="js/ext/yui-2.9.0/dragdrop/dragdrop.js"></script>@@ -78,11 +111,14 @@<!-- js.dev --> <script type="text/javascript" src="js/ext/openlayers-2.12/OpenLayers.debug.js?mobile"></script><!-- js.dev --> <script type="text/javascript" src="js/ext/jcrop-0.9.10-p1/jcrop.js"></script><!-- js.dev --> <script type="text/javascript" src="js/ext/jquery.dd-3.3/jquery.dd.js"></script>+<!-- js.dev --> <script type="text/javascript" src="js/component.js"></script><!-- js.dev --> <script type="text/javascript" src="js/registry.js"></script><!-- js.dev --> <script type="text/javascript" src="js/util.js"></script><!-- js.dev --> <script type="text/javascript" src="js/dateSpan.js"></script>+ <!-- js.dev --> <script type="text/javascript" src="js/mobileDateSpan.js"></script>+ <!-- js.dev --> <script type="text/javascript" src="js/datePicker.js"></script><!-- js.dev --> <script type="text/javascript" src="js/rubberBand.js"></script><!-- js.dev --> <script type="text/javascript" src="js/imageDownload.js"></script><!-- js.dev --> <script type="text/javascript" src="js/menuPicker.js"></script>diff --git a/js/bank.js b/js/bank.jsindex 1c035becd..3c755ae23 100644--- a/js/bank.js+++ b/js/bank.js@@ -76,6 +76,7 @@ SOTE.widget.Bank = function(containerId, config){this.config = config.config;this.paletteWidget = config.paletteWidget;this.queryString = "";+ this.noFireVal = null;this.init();//this.updateComponent(this.id+"=baselayers.MODIS_Terra_CorrectedReflectance_TrueColor-overlays.fires48.AIRS_Dust_Score.OMI_Aerosol_Index")@@ -167,9 +168,11 @@ SOTE.widget.Bank.prototype.render = function(){tabs.innerHTML = "<li><a href='#bank' class='activetab'>Active</a></li><li><a class='addlayerstab' href='#selectorbox'>Add Layers</a></li>";this.container.appendChild(tabs);*/- var container = document.createElement("div");+ var tabs_height = $(".ui-tabs-nav").outerHeight(true);+ $('#'+this.id).addClass('bank');+ $('#'+this.id).height($('#'+this.id).parent().outerHeight() - tabs_height); /*var container = document.createElement("div");container.setAttribute("id","bank");- container.setAttribute("class","bank");+ container.setAttribute("class","bank");*///var titleContainer = document.createElement("div");//titleContainer.setAttribute("class","tabContainer");@@ -192,12 +195,17 @@ SOTE.widget.Bank.prototype.render = function(){var category = document.createElement("ul");category.setAttribute("id",formattedCategoryName.toLowerCase());category.setAttribute("class",this.id+"category category");- var categoryTitleEl = document.createElement("li");++ var categoryContainer = document.createElement("div");+ categoryContainer.setAttribute("id",this.id + formattedCategoryName);+ categoryContainer.setAttribute("class","categoryContainer");+var categoryTitle = document.createElement("h3");categoryTitle.setAttribute("class","head");categoryTitle.innerHTML = this.categories[i];- categoryTitleEl.appendChild(categoryTitle);- container.appendChild(categoryTitleEl);++ categoryContainer.appendChild(categoryTitle);+if(this.values !== null && this.values[formattedCategoryName.toLowerCase()]){for(var j=0; j<this.values[formattedCategoryName.toLowerCase()].length; j++){@@ -205,13 +213,13 @@ SOTE.widget.Bank.prototype.render = function(){var item = document.createElement("li");item.setAttribute("id",formattedCategoryName.toLowerCase()+"-"+myVal);item.setAttribute("class",this.id+"item item");- item.innerHTML = "<a><img class='close' id='close"+myVal.replace(/:/g,"colon")+"' src='images/close.png' /></a>";+ item.innerHTML = "<a><img class='close bank-item-img' id='close"+myVal.replace(/:/g,"colon")+"' title='Remove Layer' src='images/close.png' /></a>";if(this.meta !== null && this.meta[myVal]){if(myVal in this.hidden){- item.innerHTML += "<a class='hdanchor'><img class='hide hideReg' id='hide"+myVal.replace(/:/g,"colon")+"' src='images/invisible.png' /></a>";+ item.innerHTML += "<a class='hdanchor'><img class='hide hideReg bank-item-img' title='Show Layer' id='hide"+myVal.replace(/:/g,"colon")+"' src='images/invisible.png' /></a>";}else {- item.innerHTML += "<a class='hdanchor'><img class='hide hideReg' id='hide"+myVal.replace(/:/g,"colon")+"' src='images/visible.png' /></a>";+ item.innerHTML += "<a class='hdanchor'><img class='hide hideReg bank-item-img' title='Hide Layer' id='hide"+myVal.replace(/:/g,"colon")+"' src='images/visible.png' /></a>";}item.innerHTML += "<h4>"+this.meta[myVal].label+"</h4>";item.innerHTML += "<p>"+this.meta[myVal].sublabel+"</p>";@@ -253,9 +261,10 @@ SOTE.widget.Bank.prototype.render = function(){}}- container.appendChild(category);+ categoryContainer.appendChild(category);+ this.container.appendChild(categoryContainer);+}- this.container.appendChild(container);/*var selectorbox = document.createElement("div");selectorbox.setAttribute("id","selectorbox");@@ -274,14 +283,20 @@ SOTE.widget.Bank.prototype.render = function(){$("#"+this.id).delegate(".close" ,'click',{self:this},SOTE.widget.Bank.removeValue);$("#"+this.id).delegate(".hideReg" ,'click',{self:this},SOTE.widget.Bank.toggleValue);$("#"+this.id).delegate(".hideSingle" ,'click',{self:this},SOTE.widget.Bank.toggleValue);- $( "." + this.id + "category" ).sortable({items: "li:not(.head)"});- $( "." + this.id + "category" ).mCustomScrollbar("destroy");- $( "." + this.id + "category" ).mCustomScrollbar({horizontalScroll:false, advanced:{- updateOnContentResize: true- }});+ $( "." + this.id + "category" ).sortable({items: "li:not(.head)"});+ if($(window).width() > 720)+ {+ if(this.jsp){+ var api = this.jsp.data('jsp');+ api.destroy();+ }+ this.jsp = $( "." + this.id + "category" ).jScrollPane({autoReinitialise: true});+ }$( "." + this.id + "category li" ).disableSelection();$( "." + this.id + "category" ).bind('sortstop',{self:this},SOTE.widget.Bank.handleSort);+ setTimeout(SOTE.widget.Bank.adjustCategoryHeights,1000,{self:this});+//this.hideAllRadioExceptTop();/*$('#'+this.id).tabs();@@ -296,6 +311,43 @@ SOTE.widget.Bank.prototype.render = function(){};+SOTE.widget.Bank.adjustCategoryHeights = function(args){+ var self = args.self;+ var heights = new Array;+ var container_height = $("#"+self.id).outerHeight();+ var labelHeight = 0;+ $('#'+self.id+' .head').each(function(){+ labelHeight += $(this).outerHeight(true);+ });+ container_height -= labelHeight;+ //console.log("This.id: " + container_height);+ for(var i=0; i<self.categories.length; i++){+ var formattedCategoryName = self.categories[i].replace(/\s/g, "");+ var actual_height = 0;+ var count = 0;+ $('#' + formattedCategoryName.toLowerCase() + ' li').each(function(){+ actual_height += $(this).outerHeight();+ count++;+ });++ heights.push({name:formattedCategoryName.toLowerCase(),height:actual_height,count:count});+ }++ if(heights[0].height + heights[1].height > container_height){+ if(heights[0].height > container_height/2) {+ heights[0].height = container_height/2;+ }++ heights[1].height = container_height - heights[0].height;++ }++ $("#" + heights[0].name).css("height",heights[0].height+"px");+ $("#" + heights[1].name).css("height",heights[1].height+"px");+++};+SOTE.widget.Bank.prototype.renderCanvases = function(){var openPaletteSelector = function(name) {@@ -406,10 +458,12 @@ SOTE.widget.Bank.toggleValue = function(e){if(val in self.hidden){delete self.hidden[val];e.target.src = 'images/visible.png';+ $("#"+e.target.id).attr("title","Hide Layer");}else {self.hidden[val] = 1;- e.target.src = 'images/invisible.png';+ e.target.src = 'images/invisible.png';+ $("#"+e.target.id).attr("title","Show Layer");}@@ -495,9 +549,11 @@ SOTE.widget.Bank.radioToggleValue = function(e){**/SOTE.widget.Bank.prototype.fire = function(){+ setTimeout(SOTE.widget.Bank.adjustCategoryHeights,1,{self:this});if(REGISTRY){- REGISTRY.fire(this);+ REGISTRY.fire(this,this.noFireVal);+ this.noFireVal = null;}else{alert("No REGISTRY found! Cannot fire to REGISTRY from Bank!");@@ -624,6 +680,7 @@ SOTE.widget.Bank.handleUpdateSuccess = function(self,qs){data.expanded = (expanded !== undefined && expanded !== "" && expanded !== null)? expanded:data.expanded;data.selected = (data.selected === undefined || data.selected === "")? SOTE.util.extractFromQuery(args.self.id,args.self.getValue()):data.selected;*/var projection = SOTE.util.extractFromQuery("switch", qs);+ self.noFireVal = (SOTE.util.extractFromQuery("norecurse",qs) === "")? null: SOTE.util.extractFromQuery("norecurse",qs);if (projection === "") {projection = self.VALID_PROJECTIONS[0];} else if ($.inArray(projection, self.VALID_PROJECTIONS) < 0) {@@ -710,6 +767,11 @@ SOTE.widget.Bank.prototype.validate = function(){};+SOTE.widget.Bank.prototype.setHeight = function(height){+ $("#"+this.id).css("height",height+"px");+ SOTE.widget.Bank.adjustCategoryHeights({self:this});+};+/*** Sets the data accessor that provides state change instructions given dependencies*diff --git a/js/datePicker.js b/js/datePicker.jsnew file mode 100644index 000000000..9223396b4--- /dev/null+++ b/js/datePicker.js@@ -0,0 +1,281 @@+SOTE.namespace("SOTE.widget.MobileDatePicker");+++/**+ * Instantiate the dateSpan+ *+ * @class A date selection object for a configurable period of days, containing thumnails of a sample data+ * product image for each day+ * @constructor+ * @this {dateSpan}+ * @param {String} containerId is the container id of the div in which to render the object+ * @param {Object} [config] is a hash allowing configuration of this component+ * @config {String} [minDate] an ISO8601 formatted date string containing the minimum bound for the dateSpan+ * @config {String} [maxDate] an ISO8601 formatted date string containing the maximum bound for the dateSpan+ * @config {boolean} [hasThumbnail] whether the dateSpan has a thumbnail+ * @config {String} [thumbSource] the address of a script producing thumbnails+ * @config {String} [extent] the extent of the current map (bbox=w,s,e,n)+ * @config {String} [product] the base product for the thumbnails+ * @config {String} [startDate] an ISO8601 formatted date string containing the start date of the dateSpan+ * @config {String} [selectedDate] an ISO8601 formatted date string containing the initially selected date+ * @config {Number} [range] the total number of days displayed to the user+ * @config {String} [anchorId] an HTML Element Id of the object to anchor the dateSpan with+ * @config {boolean} [slideToSelect] whether the selection slider is visible or not+ * @config {boolean} [isExpanded] whether the dateSpan thumbnails should be visible or not+ * @augments SOTE.widget.Component+ *+*/+SOTE.widget.DatePicker = function(containerId, config){+ this.log = Logging.getLogger("Worldview.Widget.DatePicker");++ this.container=document.getElementById(containerId);+ if (this.container==null){+ this.setStatus("Error: element '"+containerId+"' not found!",true);+ return;+ }+ this.id = containerId;+ //Store the container's ID+ this.containerId=containerId;++ this.config = config;+ this.current = null;++ this.init();++ $(window).bind("resize",{self:this},SOTE.widget.DatePicker.resize);++};++SOTE.widget.DatePicker.prototype = new SOTE.widget.Component;++/**+ * Displays the selectable dateSpan in HTML containing a thumbnail for each day in the span. If the date range contains+ * more days than the visible day span, create horizontal scrolling capability. All callbacks should be set. The+ * component UI should be rendered with controllers to call the events.+ *+ * @this {dateSpan}+ * @requires SOTE.widget.Map+*/+SOTE.widget.DatePicker.prototype.init = function(){++ this.ds_id = this.id+"ds";+ this.mds_id = this.id+"mds";+ var ds = document.createElement('div');+ ds.setAttribute("id",this.ds_id);+ var mds = document.createElement('div');+ mds.setAttribute("id",this.mds_id);++ this.container.appendChild(ds);+ this.container.appendChild(mds);++ this.ds = new SOTE.widget.DateSpan(this.ds_id, this.config);+ this.mds = new SOTE.widget.MobileDateSpan(this.mds_id, this.config);++ $("#"+this.ds_id).bind("fire", {self:this}, SOTE.widget.DatePicker.handleFire);+ $("#"+this.mds_id).bind("fire", {self:this}, SOTE.widget.DatePicker.handleFire)++ SOTE.widget.DatePicker.resize({data: {self:this}});++ if(REGISTRY){+ REGISTRY.register(this.id,this);+ REGISTRY.markComponentReady(this.id);+ }+ else{+ alert("No REGISTRY found! Cannot register DatePicker!");+ }++};++SOTE.widget.DatePicker.handleFire = function(e,value){+ var self = e.data.self;+ if(self.current.id = self.ds_id) self.mds.set(value); else self.ds.set(value);+ self.fire();+};++SOTE.widget.DatePicker.resize = function(e){+ var self = e.data.self;++ if($(window).width() > 720){+ self.current = self.ds;+ self.ds.show();+ self.mds.hide();+ }+ else {+ self.current = self.mds;+ self.ds.hide();+ self.mds.show();+ }+};++/**+ * Fires an event to the registry when the state of the component is changed+ *+ * @this {DatePicker}+ *+*/+SOTE.widget.DatePicker.prototype.fire = function(){++ if(REGISTRY){+ REGISTRY.fire(this);+ }+ else{+ alert("No REGISTRY found! Cannot fire to REGISTRY from AccordionPicker!");+ }++};++/**+ * Sets the selected date in the dateSpan from the passed in date string (ISO8601 format), if valid+ *+ * @this {dateSpan}+ * @param {String} value is the date to be set (i.e. [containerId]=[date])+ * @returns {boolean} true or false depending on if the passed in date validates+ *+*/+SOTE.widget.DatePicker.prototype.setValue = function(value){+ this.ds.setValue(value);+ this.mds.setValue(value);+};++/**+ * Gets the currently selected date in ISO8601 format+ *+ * @this {dateSpan}+ * @returns {String} a string representing the currently selected date in ISO8601 format ([containerId]=[selectedDate])+ *+*/+SOTE.widget.DatePicker.prototype.getValue = function(){+ return this.id + "=" + this.current.get();+};++/**+ * Modify the component based on dependencies (i.e. total number of dates in span, start date of span, selected date, thumbnails)+ *+ * @this {dateSpan}+ * @param {String} querystring contains all values of dependencies (from registry)+ * @returns {boolean} true or false depending on if the selected date validates against the updated criteria+ *+*/+SOTE.widget.DatePicker.prototype.updateComponent = function(qs){+ this.ds.updateComponent(qs);+ this.mds.updateComponent(qs);+};++/**+ * Sets the selected date from the querystring, [containerId]=[selectedDate]+ *+ * @this {dateSpan}+ * @param {String} qs contains the querystring (must contain [containerId]=[selectedDate] in the string)+ * @returns {boolean} true or false depending on if the extracted date validates+ *+*/+SOTE.widget.DatePicker.prototype.loadFromQuery = function(qs){+ this.ds.loadFromQuery(qs);+ this.mds.loadFromQuery(qs);+};++/**+ * Validates that the selected date is not null and within bounds+ *+ * @this {dateSpan}+ * @returns {boolean} true or false depending on whether the date is not null and within bounds+*/+SOTE.widget.DatePicker.prototype.validate = function(){++};++/**+ * Sets the data accessor that provides state change instructions given dependencies+ *+ * @this {dateSpan}+ * @param {String} datasourceurl is the relative location of the data accessor+ *+*/+SOTE.widget.DatePicker.prototype.setDataSourceUrl = function(datasourceurl){+ // Content+};++/**+ * Gets the data accessor+ *+ * @this {dateSpan}+ * @returns {String} the relative location of the accessor+ *+*/+SOTE.widget.DatePicker.prototype.getDataSourceUrl = function(){+ // Content+};++/**+ * Sets the status of the component+ *+ * @this {dateSpan}+ * @param {String} s the current status of the component (user prompts, error messages)+ *+*/+SOTE.widget.DatePicker.prototype.setStatus = function(s){+ // Content+};++/**+ * Gets the status of the component+ *+ * @this {dateSpan}+ * @returns {String} the current status of the component (user prompts, error messages)+ *+*/+SOTE.widget.DatePicker.prototype.getStatus = function(){+ // Content+};++/**+ * Makes the component UI invisible+ *+ * @this {dateSpan}+ *+*/+SOTE.widget.DatePicker.prototype.hide = function(){+ // Content+};++/**+ * Makes the component UI visible+ *+ * @this {dateSpan}+ *+*/+SOTE.widget.DatePicker.prototype.show = function(){+ // Content+};++/**+ * Expand the UI to show thumbnails+ *+ * @this {dateSpan}+ *+*/+SOTE.widget.DatePicker.prototype.expand = function(){+ // Content+};++/**+ * Collapse the UI (no thumbnails)+ *+ * @this {dateSpan}+ *+*/+SOTE.widget.DatePicker.prototype.collapse = function(){+ // Content+};++// Additional Functions+// setBounds, getAvailableDates, setStart, changeBaseProduct, setExtent+++++++++diff --git a/js/dateSpan.js b/js/dateSpan.jsindex 45e9225de..8741ba237 100644--- a/js/dateSpan.js+++ b/js/dateSpan.js@@ -270,6 +270,8 @@ SOTE.widget.DateSpan.prototype.createSlider = function(type){**/SOTE.widget.DateSpan.prototype.fire = function(){+ $("#"+this.id).trigger("fire",this.value);+if(REGISTRY){REGISTRY.fire(this);@@ -529,6 +531,10 @@ SOTE.widget.DateSpan.prototype.setValue = function(value){}};+SOTE.widget.DateSpan.prototype.set = function(value){+ this.value = value;+};+SOTE.widget.DateSpan.prototype.setVisualDate = function(){var dateString = this.value.toISOStringDate();$('#'+this.id+'dateHolder').html(dateString);@@ -547,6 +553,11 @@ SOTE.widget.DateSpan.prototype.getValue = function(){return ""+this.id +"="+datestring;};+SOTE.widget.DateSpan.prototype.get = function(){+ var datestring = this.value.toISOStringDate();+ return datestring;+};+/*** Modify the component based on dependencies (i.e. total number of dates in span, start date of span, selected date, thumbnails)*@@ -695,7 +706,7 @@ SOTE.widget.DateSpan.prototype.getStatus = function(){**/SOTE.widget.DateSpan.prototype.hide = function(){- // Content+ $("#"+this.id).css("left","-999em");};/**@@ -705,7 +716,7 @@ SOTE.widget.DateSpan.prototype.hide = function(){**/SOTE.widget.DateSpan.prototype.show = function(){- // Content+ $("#"+this.id).css("left","0");};/**diff --git a/js/ext/jscrollpane/jquery.jscrollpane.min.js b/js/ext/jscrollpane/jquery.jscrollpane.min.jsnew file mode 100644index 000000000..d7d9cae76--- /dev/null+++ b/js/ext/jscrollpane/jquery.jscrollpane.min.js@@ -0,0 +1,11 @@+/*!+ * jScrollPane - v2.0.14 - 2013-05-01+ * http://jscrollpane.kelvinluck.com/+ *+ * Copyright (c) 2010 Kelvin Luck+ * Dual licensed under the MIT or GPL licenses.+ */+(function(b,a,c){b.fn.jScrollPane=function(e){function d(D,O){var ay,Q=this,Y,aj,v,al,T,Z,y,q,az,aE,au,i,I,h,j,aa,U,ap,X,t,A,aq,af,am,G,l,at,ax,x,av,aH,f,L,ai=true,P=true,aG=false,k=false,ao=D.clone(false,false).empty(),ac=b.fn.mwheelIntent?"mwheelIntent.jsp":"mousewheel.jsp";aH=D.css("paddingTop")+" "+D.css("paddingRight")+" "+D.css("paddingBottom")+" "+D.css("paddingLeft");f=(parseInt(D.css("paddingLeft"),10)||0)+(parseInt(D.css("paddingRight"),10)||0);function ar(aQ){var aL,aN,aM,aJ,aI,aP,aO=false,aK=false;ay=aQ;if(Y===c){aI=D.scrollTop();aP=D.scrollLeft();D.css({overflow:"hidden",padding:0});aj=D.innerWidth()+f;v=D.innerHeight();D.width(aj);Y=b('<div class="jspPane" />').css("padding",aH).append(D.children());al=b('<div class="jspContainer" />').css({width:aj+"px",height:v+"px"}).append(Y).appendTo(D)}else{D.css("width","");aO=ay.stickToBottom&&K();aK=ay.stickToRight&&B();aJ=D.innerWidth()+f!=aj||D.outerHeight()!=v;if(aJ){aj=D.innerWidth()+f;v=D.innerHeight();al.css({width:aj+"px",height:v+"px"})}if(!aJ&&L==T&&Y.outerHeight()==Z){D.width(aj);return}L=T;Y.css("width","");D.width(aj);al.find(">.jspVerticalBar,>.jspHorizontalBar").remove().end()}Y.css("overflow","auto");if(aQ.contentWidth){T=aQ.contentWidth}else{T=Y[0].scrollWidth}Z=Y[0].scrollHeight;Y.css("overflow","");y=T/aj;q=Z/v;az=q>1;aE=y>1;if(!(aE||az)){D.removeClass("jspScrollable");Y.css({top:0,width:al.width()-f});n();E();R();w()}else{D.addClass("jspScrollable");aL=ay.maintainPosition&&(I||aa);if(aL){aN=aC();aM=aA()}aF();z();F();if(aL){N(aK?(T-aj):aN,false);M(aO?(Z-v):aM,false)}J();ag();an();if(ay.enableKeyboardNavigation){S()}if(ay.clickOnTrack){p()}C();if(ay.hijackInternalLinks){m()}}if(ay.autoReinitialise&&!av){av=setInterval(function(){ar(ay)},ay.autoReinitialiseDelay)}else{if(!ay.autoReinitialise&&av){clearInterval(av)}}aI&&D.scrollTop(0)&&M(aI,false);aP&&D.scrollLeft(0)&&N(aP,false);D.trigger("jsp-initialised",[aE||az])}function aF(){if(az){al.append(b('<div class="jspVerticalBar" />').append(b('<div class="jspCap jspCapTop" />'),b('<div class="jspTrack" />').append(b('<div class="jspDrag" />').append(b('<div class="jspDragTop" />'),b('<div class="jspDragBottom" />'))),b('<div class="jspCap jspCapBottom" />')));U=al.find(">.jspVerticalBar");ap=U.find(">.jspTrack");au=ap.find(">.jspDrag");if(ay.showArrows){aq=b('<a class="jspArrow jspArrowUp" />').bind("mousedown.jsp",aD(0,-1)).bind("click.jsp",aB);af=b('<a class="jspArrow jspArrowDown" />').bind("mousedown.jsp",aD(0,1)).bind("click.jsp",aB);if(ay.arrowScrollOnHover){aq.bind("mouseover.jsp",aD(0,-1,aq));af.bind("mouseover.jsp",aD(0,1,af))}ak(ap,ay.verticalArrowPositions,aq,af)}t=v;al.find(">.jspVerticalBar>.jspCap:visible,>.jspVerticalBar>.jspArrow").each(function(){t-=b(this).outerHeight()});au.hover(function(){au.addClass("jspHover")},function(){au.removeClass("jspHover")}).bind("mousedown.jsp",function(aI){b("html").bind("dragstart.jsp selectstart.jsp",aB);au.addClass("jspActive");var s=aI.pageY-au.position().top;b("html").bind("mousemove.jsp",function(aJ){V(aJ.pageY-s,false)}).bind("mouseup.jsp mouseleave.jsp",aw);return false});o()}}function o(){ap.height(t+"px");I=0;X=ay.verticalGutter+ap.outerWidth();Y.width(aj-X-f);try{if(U.position().left===0){Y.css("margin-left",X+"px")}}catch(s){}}function z(){if(aE){al.append(b('<div class="jspHorizontalBar" />').append(b('<div class="jspCap jspCapLeft" />'),b('<div class="jspTrack" />').append(b('<div class="jspDrag" />').append(b('<div class="jspDragLeft" />'),b('<div class="jspDragRight" />'))),b('<div class="jspCap jspCapRight" />')));am=al.find(">.jspHorizontalBar");G=am.find(">.jspTrack");h=G.find(">.jspDrag");if(ay.showArrows){ax=b('<a class="jspArrow jspArrowLeft" />').bind("mousedown.jsp",aD(-1,0)).bind("click.jsp",aB);x=b('<a class="jspArrow jspArrowRight" />').bind("mousedown.jsp",aD(1,0)).bind("click.jsp",aB);+if(ay.arrowScrollOnHover){ax.bind("mouseover.jsp",aD(-1,0,ax));x.bind("mouseover.jsp",aD(1,0,x))}ak(G,ay.horizontalArrowPositions,ax,x)}h.hover(function(){h.addClass("jspHover")},function(){h.removeClass("jspHover")}).bind("mousedown.jsp",function(aI){b("html").bind("dragstart.jsp selectstart.jsp",aB);h.addClass("jspActive");var s=aI.pageX-h.position().left;b("html").bind("mousemove.jsp",function(aJ){W(aJ.pageX-s,false)}).bind("mouseup.jsp mouseleave.jsp",aw);return false});l=al.innerWidth();ah()}}function ah(){al.find(">.jspHorizontalBar>.jspCap:visible,>.jspHorizontalBar>.jspArrow").each(function(){l-=b(this).outerWidth()});G.width(l+"px");aa=0}function F(){if(aE&&az){var aI=G.outerHeight(),s=ap.outerWidth();t-=aI;b(am).find(">.jspCap:visible,>.jspArrow").each(function(){l+=b(this).outerWidth()});l-=s;v-=s;aj-=aI;G.parent().append(b('<div class="jspCorner" />').css("width",aI+"px"));o();ah()}if(aE){Y.width((al.outerWidth()-f)+"px")}Z=Y.outerHeight();q=Z/v;if(aE){at=Math.ceil(1/y*l);if(at>ay.horizontalDragMaxWidth){at=ay.horizontalDragMaxWidth}else{if(at<ay.horizontalDragMinWidth){at=ay.horizontalDragMinWidth}}h.width(at+"px");j=l-at;ae(aa)}if(az){A=Math.ceil(1/q*t);if(A>ay.verticalDragMaxHeight){A=ay.verticalDragMaxHeight}else{if(A<ay.verticalDragMinHeight){A=ay.verticalDragMinHeight}}au.height(A+"px");i=t-A;ad(I)}}function ak(aJ,aL,aI,s){var aN="before",aK="after",aM;if(aL=="os"){aL=/Mac/.test(navigator.platform)?"after":"split"}if(aL==aN){aK=aL}else{if(aL==aK){aN=aL;aM=aI;aI=s;s=aM}}aJ[aN](aI)[aK](s)}function aD(aI,s,aJ){return function(){H(aI,s,this,aJ);this.blur();return false}}function H(aL,aK,aO,aN){aO=b(aO).addClass("jspActive");var aM,aJ,aI=true,s=function(){if(aL!==0){Q.scrollByX(aL*ay.arrowButtonSpeed)}if(aK!==0){Q.scrollByY(aK*ay.arrowButtonSpeed)}aJ=setTimeout(s,aI?ay.initialDelay:ay.arrowRepeatFreq);aI=false};s();aM=aN?"mouseout.jsp":"mouseup.jsp";aN=aN||b("html");aN.bind(aM,function(){aO.removeClass("jspActive");aJ&&clearTimeout(aJ);aJ=null;aN.unbind(aM)})}function p(){w();if(az){ap.bind("mousedown.jsp",function(aN){if(aN.originalTarget===c||aN.originalTarget==aN.currentTarget){var aL=b(this),aO=aL.offset(),aM=aN.pageY-aO.top-I,aJ,aI=true,s=function(){var aR=aL.offset(),aS=aN.pageY-aR.top-A/2,aP=v*ay.scrollPagePercent,aQ=i*aP/(Z-v);if(aM<0){if(I-aQ>aS){Q.scrollByY(-aP)}else{V(aS)}}else{if(aM>0){if(I+aQ<aS){Q.scrollByY(aP)}else{V(aS)}}else{aK();return}}aJ=setTimeout(s,aI?ay.initialDelay:ay.trackClickRepeatFreq);aI=false},aK=function(){aJ&&clearTimeout(aJ);aJ=null;b(document).unbind("mouseup.jsp",aK)};s();b(document).bind("mouseup.jsp",aK);return false}})}if(aE){G.bind("mousedown.jsp",function(aN){if(aN.originalTarget===c||aN.originalTarget==aN.currentTarget){var aL=b(this),aO=aL.offset(),aM=aN.pageX-aO.left-aa,aJ,aI=true,s=function(){var aR=aL.offset(),aS=aN.pageX-aR.left-at/2,aP=aj*ay.scrollPagePercent,aQ=j*aP/(T-aj);if(aM<0){if(aa-aQ>aS){Q.scrollByX(-aP)}else{W(aS)}}else{if(aM>0){if(aa+aQ<aS){Q.scrollByX(aP)}else{W(aS)}}else{aK();return}}aJ=setTimeout(s,aI?ay.initialDelay:ay.trackClickRepeatFreq);aI=false},aK=function(){aJ&&clearTimeout(aJ);aJ=null;b(document).unbind("mouseup.jsp",aK)};s();b(document).bind("mouseup.jsp",aK);return false}})}}function w(){if(G){G.unbind("mousedown.jsp")}if(ap){ap.unbind("mousedown.jsp")}}function aw(){b("html").unbind("dragstart.jsp selectstart.jsp mousemove.jsp mouseup.jsp mouseleave.jsp");if(au){au.removeClass("jspActive")}if(h){h.removeClass("jspActive")}}function V(s,aI){if(!az){return}if(s<0){s=0}else{if(s>i){s=i}}if(aI===c){aI=ay.animateScroll}if(aI){Q.animate(au,"top",s,ad)}else{au.css("top",s);ad(s)}}function ad(aI){if(aI===c){aI=au.position().top}al.scrollTop(0);I=aI;var aL=I===0,aJ=I==i,aK=aI/i,s=-aK*(Z-v);if(ai!=aL||aG!=aJ){ai=aL;aG=aJ;D.trigger("jsp-arrow-change",[ai,aG,P,k])}u(aL,aJ);Y.css("top",s);D.trigger("jsp-scroll-y",[-s,aL,aJ]).trigger("scroll")}function W(aI,s){if(!aE){return}if(aI<0){aI=0}else{if(aI>j){aI=j}}if(s===c){s=ay.animateScroll}if(s){Q.animate(h,"left",aI,ae)+}else{h.css("left",aI);ae(aI)}}function ae(aI){if(aI===c){aI=h.position().left}al.scrollTop(0);aa=aI;var aL=aa===0,aK=aa==j,aJ=aI/j,s=-aJ*(T-aj);if(P!=aL||k!=aK){P=aL;k=aK;D.trigger("jsp-arrow-change",[ai,aG,P,k])}r(aL,aK);Y.css("left",s);D.trigger("jsp-scroll-x",[-s,aL,aK]).trigger("scroll")}function u(aI,s){if(ay.showArrows){aq[aI?"addClass":"removeClass"]("jspDisabled");af[s?"addClass":"removeClass"]("jspDisabled")}}function r(aI,s){if(ay.showArrows){ax[aI?"addClass":"removeClass"]("jspDisabled");x[s?"addClass":"removeClass"]("jspDisabled")}}function M(s,aI){var aJ=s/(Z-v);V(aJ*i,aI)}function N(aI,s){var aJ=aI/(T-aj);W(aJ*j,s)}function ab(aV,aQ,aJ){var aN,aK,aL,s=0,aU=0,aI,aP,aO,aS,aR,aT;try{aN=b(aV)}catch(aM){return}aK=aN.outerHeight();aL=aN.outerWidth();al.scrollTop(0);al.scrollLeft(0);while(!aN.is(".jspPane")){s+=aN.position().top;aU+=aN.position().left;aN=aN.offsetParent();if(/^body|html$/i.test(aN[0].nodeName)){return}}aI=aA();aO=aI+v;if(s<aI||aQ){aR=s-ay.verticalGutter}else{if(s+aK>aO){aR=s-v+aK+ay.verticalGutter}}if(aR){M(aR,aJ)}aP=aC();aS=aP+aj;if(aU<aP||aQ){aT=aU-ay.horizontalGutter}else{if(aU+aL>aS){aT=aU-aj+aL+ay.horizontalGutter}}if(aT){N(aT,aJ)}}function aC(){return -Y.position().left}function aA(){return -Y.position().top}function K(){var s=Z-v;return(s>20)&&(s-aA()<10)}function B(){var s=T-aj;return(s>20)&&(s-aC()<10)}function ag(){al.unbind(ac).bind(ac,function(aL,aM,aK,aI){var aJ=aa,s=I;Q.scrollBy(aK*ay.mouseWheelSpeed,-aI*ay.mouseWheelSpeed,false);return aJ==aa&&s==I})}function n(){al.unbind(ac)}function aB(){return false}function J(){Y.find(":input,a").unbind("focus.jsp").bind("focus.jsp",function(s){ab(s.target,false)})}function E(){Y.find(":input,a").unbind("focus.jsp")}function S(){var s,aI,aK=[];aE&&aK.push(am[0]);az&&aK.push(U[0]);Y.focus(function(){D.focus()});D.attr("tabindex",0).unbind("keydown.jsp keypress.jsp").bind("keydown.jsp",function(aN){if(aN.target!==this&&!(aK.length&&b(aN.target).closest(aK).length)){return}var aM=aa,aL=I;switch(aN.keyCode){case 40:case 38:case 34:case 32:case 33:case 39:case 37:s=aN.keyCode;aJ();break;case 35:M(Z-v);s=null;break;case 36:M(0);s=null;break}aI=aN.keyCode==s&&aM!=aa||aL!=I;return !aI}).bind("keypress.jsp",function(aL){if(aL.keyCode==s){aJ()}return !aI});if(ay.hideFocus){D.css("outline","none");if("hideFocus" in al[0]){D.attr("hideFocus",true)}}else{D.css("outline","");if("hideFocus" in al[0]){D.attr("hideFocus",false)}}function aJ(){var aM=aa,aL=I;switch(s){case 40:Q.scrollByY(ay.keyboardSpeed,false);break;case 38:Q.scrollByY(-ay.keyboardSpeed,false);break;case 34:case 32:Q.scrollByY(v*ay.scrollPagePercent,false);break;case 33:Q.scrollByY(-v*ay.scrollPagePercent,false);break;case 39:Q.scrollByX(ay.keyboardSpeed,false);break;case 37:Q.scrollByX(-ay.keyboardSpeed,false);break}aI=aM!=aa||aL!=I;return aI}}function R(){D.attr("tabindex","-1").removeAttr("tabindex").unbind("keydown.jsp keypress.jsp")}function C(){if(location.hash&&location.hash.length>1){var aK,aI,aJ=escape(location.hash.substr(1));try{aK=b("#"+aJ+', a[name="'+aJ+'"]')}catch(s){return}if(aK.length&&Y.find(aJ)){if(al.scrollTop()===0){aI=setInterval(function(){if(al.scrollTop()>0){ab(aK,true);b(document).scrollTop(al.position().top);clearInterval(aI)}},50)}else{ab(aK,true);b(document).scrollTop(al.position().top)}}}}function m(){if(b(document.body).data("jspHijack")){return}b(document.body).data("jspHijack",true);b(document.body).delegate("a[href*=#]","click",function(s){var aI=this.href.substr(0,this.href.indexOf("#")),aK=location.href,aO,aP,aJ,aM,aL,aN;if(location.href.indexOf("#")!==-1){aK=location.href.substr(0,location.href.indexOf("#"))}if(aI!==aK){return}aO=escape(this.href.substr(this.href.indexOf("#")+1));aP;try{aP=b("#"+aO+', a[name="'+aO+'"]')}catch(aQ){return}if(!aP.length){return}aJ=aP.closest(".jspScrollable");aM=aJ.data("jsp");aM.scrollToElement(aP,true);if(aJ[0].scrollIntoView){aL=b(a).scrollTop();aN=aP.offset().top;if(aN<aL||aN>aL+b(a).height()){aJ[0].scrollIntoView()}}s.preventDefault()+})}function an(){var aJ,aI,aL,aK,aM,s=false;al.unbind("touchstart.jsp touchmove.jsp touchend.jsp click.jsp-touchclick").bind("touchstart.jsp",function(aN){var aO=aN.originalEvent.touches[0];aJ=aC();aI=aA();aL=aO.pageX;aK=aO.pageY;aM=false;s=true}).bind("touchmove.jsp",function(aQ){if(!s){return}var aP=aQ.originalEvent.touches[0],aO=aa,aN=I;Q.scrollTo(aJ+aL-aP.pageX,aI+aK-aP.pageY);aM=aM||Math.abs(aL-aP.pageX)>5||Math.abs(aK-aP.pageY)>5;return aO==aa&&aN==I}).bind("touchend.jsp",function(aN){s=false}).bind("click.jsp-touchclick",function(aN){if(aM){aM=false;return false}})}function g(){var s=aA(),aI=aC();D.removeClass("jspScrollable").unbind(".jsp");D.replaceWith(ao.append(Y.children()));ao.scrollTop(s);ao.scrollLeft(aI);if(av){clearInterval(av)}}b.extend(Q,{reinitialise:function(aI){aI=b.extend({},ay,aI);ar(aI)},scrollToElement:function(aJ,aI,s){ab(aJ,aI,s)},scrollTo:function(aJ,s,aI){N(aJ,aI);M(s,aI)},scrollToX:function(aI,s){N(aI,s)},scrollToY:function(s,aI){M(s,aI)},scrollToPercentX:function(aI,s){N(aI*(T-aj),s)},scrollToPercentY:function(aI,s){M(aI*(Z-v),s)},scrollBy:function(aI,s,aJ){Q.scrollByX(aI,aJ);Q.scrollByY(s,aJ)},scrollByX:function(s,aJ){var aI=aC()+Math[s<0?"floor":"ceil"](s),aK=aI/(T-aj);W(aK*j,aJ)},scrollByY:function(s,aJ){var aI=aA()+Math[s<0?"floor":"ceil"](s),aK=aI/(Z-v);V(aK*i,aJ)},positionDragX:function(s,aI){W(s,aI)},positionDragY:function(aI,s){V(aI,s)},animate:function(aI,aL,s,aK){var aJ={};aJ[aL]=s;aI.animate(aJ,{duration:ay.animateDuration,easing:ay.animateEase,queue:false,step:aK})},getContentPositionX:function(){return aC()},getContentPositionY:function(){return aA()},getContentWidth:function(){return T},getContentHeight:function(){return Z},getPercentScrolledX:function(){return aC()/(T-aj)},getPercentScrolledY:function(){return aA()/(Z-v)},getIsScrollableH:function(){return aE},getIsScrollableV:function(){return az},getContentPane:function(){return Y},scrollToBottom:function(s){V(i,s)},hijackInternalLinks:b.noop,destroy:function(){g()}});ar(O)}e=b.extend({},b.fn.jScrollPane.defaults,e);b.each(["arrowButtonSpeed","trackClickSpeed","keyboardSpeed"],function(){e[this]=e[this]||e.speed});return this.each(function(){var f=b(this),g=f.data("jsp");if(g){g.reinitialise(e)}else{b("script",f).filter('[type="text/javascript"],:not([type])').remove();g=new d(f,e);f.data("jsp",g)}})};b.fn.jScrollPane.defaults={showArrows:false,maintainPosition:true,stickToBottom:false,stickToRight:false,clickOnTrack:true,autoReinitialise:false,autoReinitialiseDelay:500,verticalDragMinHeight:0,verticalDragMaxHeight:99999,horizontalDragMinWidth:0,horizontalDragMaxWidth:99999,contentWidth:c,animateScroll:false,animateDuration:300,animateEase:"linear",hijackInternalLinks:false,verticalGutter:4,horizontalGutter:4,mouseWheelSpeed:3,arrowButtonSpeed:0,arrowRepeatFreq:50,arrowScrollOnHover:false,trackClickSpeed:0,trackClickRepeatFreq:70,verticalArrowPositions:"split",horizontalArrowPositions:"split",enableKeyboardNavigation:true,hideFocus:false,keyboardSpeed:0,initialDelay:300,speed:30,scrollPagePercent:0.8}})(jQuery,this);\ No newline at end of filediff --git a/js/ext/jscrollpane/jquery.mousewheel.js b/js/ext/jscrollpane/jquery.mousewheel.jsnew file mode 100644index 000000000..9d65c7162--- /dev/null+++ b/js/ext/jscrollpane/jquery.mousewheel.js@@ -0,0 +1,117 @@+/*! Copyright (c) 2013 Brandon Aaron (http://brandonaaron.net)+ * Licensed under the MIT License (LICENSE.txt).+ *+ * Thanks to: http://adomas.org/javascript-mouse-wheel/ for some pointers.+ * Thanks to: Mathias Bank(http://www.mathias-bank.de) for a scope bug fix.+ * Thanks to: Seamus Leahy for adding deltaX and deltaY+ *+ * Version: 3.1.3+ *+ * Requires: 1.2.2++ */++(function (factory) {+ if ( typeof define === 'function' && define.amd ) {+ // AMD. Register as an anonymous module.+ define(['jquery'], factory);+ } else if (typeof exports === 'object') {+ // Node/CommonJS style for Browserify+ module.exports = factory;+ } else {+ // Browser globals+ factory(jQuery);+ }+}(function ($) {++ var toFix = ['wheel', 'mousewheel', 'DOMMouseScroll', 'MozMousePixelScroll'];+ var toBind = 'onwheel' in document || document.documentMode >= 9 ? ['wheel'] : ['mousewheel', 'DomMouseScroll', 'MozMousePixelScroll'];+ var lowestDelta, lowestDeltaXY;++ if ( $.event.fixHooks ) {+ for ( var i = toFix.length; i; ) {+ $.event.fixHooks[ toFix[--i] ] = $.event.mouseHooks;+ }+ }++ $.event.special.mousewheel = {+ setup: function() {+ if ( this.addEventListener ) {+ for ( var i = toBind.length; i; ) {+ this.addEventListener( toBind[--i], handler, false );+ }+ } else {+ this.onmousewheel = handler;+ }+ },++ teardown: function() {+ if ( this.removeEventListener ) {+ for ( var i = toBind.length; i; ) {+ this.removeEventListener( toBind[--i], handler, false );+ }+ } else {+ this.onmousewheel = null;+ }+ }+ };++ $.fn.extend({+ mousewheel: function(fn) {+ return fn ? this.bind("mousewheel", fn) : this.trigger("mousewheel");+ },++ unmousewheel: function(fn) {+ return this.unbind("mousewheel", fn);+ }+ });+++ function handler(event) {+ var orgEvent = event || window.event,+ args = [].slice.call(arguments, 1),+ delta = 0,+ deltaX = 0,+ deltaY = 0,+ absDelta = 0,+ absDeltaXY = 0,+ fn;+ event = $.event.fix(orgEvent);+ event.type = "mousewheel";++ // Old school scrollwheel delta+ if ( orgEvent.wheelDelta ) { delta = orgEvent.wheelDelta; }+ if ( orgEvent.detail ) { delta = orgEvent.detail * -1; }++ // New school wheel delta (wheel event)+ if ( orgEvent.deltaY ) {+ deltaY = orgEvent.deltaY * -1;+ delta = deltaY;+ }+ if ( orgEvent.deltaX ) {+ deltaX = orgEvent.deltaX;+ delta = deltaX * -1;+ }++ // Webkit+ if ( orgEvent.wheelDeltaY !== undefined ) { deltaY = orgEvent.wheelDeltaY; }+ if ( orgEvent.wheelDeltaX !== undefined ) { deltaX = orgEvent.wheelDeltaX * -1; }++ // Look for lowest delta to normalize the delta values+ absDelta = Math.abs(delta);+ if ( !lowestDelta || absDelta < lowestDelta ) { lowestDelta = absDelta; }+ absDeltaXY = Math.max(Math.abs(deltaY), Math.abs(deltaX));+ if ( !lowestDeltaXY || absDeltaXY < lowestDeltaXY ) { lowestDeltaXY = absDeltaXY; }++ // Get a whole value for the deltas+ fn = delta > 0 ? 'floor' : 'ceil';+ delta = Math[fn](delta / lowestDelta);+ deltaX = Math[fn](deltaX / lowestDeltaXY);+ deltaY = Math[fn](deltaY / lowestDeltaXY);++ // Add event and delta to the front of the arguments+ args.unshift(event, delta, deltaX, deltaY);++ return ($.event.dispatch || $.event.handle).apply(this, args);+ }++}));diff --git a/js/ext/jscrollpane/mwheelIntent.js b/js/ext/jscrollpane/mwheelIntent.jsnew file mode 100644index 000000000..0a86d0589--- /dev/null+++ b/js/ext/jscrollpane/mwheelIntent.js@@ -0,0 +1,76 @@+/**+ * @author trixta+ * @version 1.2+ */+(function($){++var mwheelI = {+ pos: [-260, -260]+ },+ minDif = 3,+ doc = document,+ root = doc.documentElement,+ body = doc.body,+ longDelay, shortDelay+;++function unsetPos(){+ if(this === mwheelI.elem){+ mwheelI.pos = [-260, -260];+ mwheelI.elem = false;+ minDif = 3;+ }+}++$.event.special.mwheelIntent = {+ setup: function(){+ var jElm = $(this).bind('mousewheel', $.event.special.mwheelIntent.handler);+ if( this !== doc && this !== root && this !== body ){+ jElm.bind('mouseleave', unsetPos);+ }+ jElm = null;+ return true;+ },+ teardown: function(){+ $(this)+ .unbind('mousewheel', $.event.special.mwheelIntent.handler)+ .unbind('mouseleave', unsetPos)+ ;+ return true;+ },+ handler: function(e, d){+ var pos = [e.clientX, e.clientY];+ if( this === mwheelI.elem || Math.abs(mwheelI.pos[0] - pos[0]) > minDif || Math.abs(mwheelI.pos[1] - pos[1]) > minDif ){+ mwheelI.elem = this;+ mwheelI.pos = pos;+ minDif = 250;++ clearTimeout(shortDelay);+ shortDelay = setTimeout(function(){+ minDif = 10;+ }, 200);+ clearTimeout(longDelay);+ longDelay = setTimeout(function(){+ minDif = 3;+ }, 1500);+ e = $.extend({}, e, {type: 'mwheelIntent'});+ return ($.event.dispatch || $.event.handle).apply(this, arguments);+ }+ }+};+$.fn.extend({+ mwheelIntent: function(fn) {+ return fn ? this.bind("mwheelIntent", fn) : this.trigger("mwheelIntent");+ },++ unmwheelIntent: function(fn) {+ return this.unbind("mwheelIntent", fn);+ }+});++$(function(){+ body = doc.body;+ //assume that document is always scrollable, doesn't hurt if not+ $(doc).bind('mwheelIntent.mwheelIntentDefault', $.noop);+});+})(jQuery);diff --git a/js/ext/mobiscroll/i18n/mobiscroll.i18n.de.js b/js/ext/mobiscroll/i18n/mobiscroll.i18n.de.jsnew file mode 100644index 000000000..311287984--- /dev/null+++ b/js/ext/mobiscroll/i18n/mobiscroll.i18n.de.js@@ -0,0 +1,40 @@+(function ($) {+ $.mobiscroll.i18n.de = $.extend($.mobiscroll.i18n.de, {+ // Core+ setText: 'OK',+ cancelText: 'Abbrechen',+ // Datetime component+ dateFormat: 'dd.mm.yy',+ dateOrder: 'ddmmyy',+ dayNames: ['Sonntag', 'Montag', 'Dienstag', 'Mittwoch', 'Donnerstag', 'Freitag', 'Samstag'],+ dayNamesShort: ['So', 'Mo', 'Di', 'Mi', 'Do', 'Fr', 'Sa'],+ dayText: 'Tag',+ hourText: 'Stunde',+ minuteText: 'Minuten',+ monthNames: ['Januar', 'Februar', 'März', 'April', 'Mai', 'Juni', 'Juli', 'August', 'September', 'Oktober', 'November', 'Dezember'],+ monthNamesShort: ['Jan', 'Feb', 'Mär', 'Apr', 'Mai', 'Jun', 'Jul', 'Aug', 'Sep', 'Okt', 'Nov', 'Dez'],+ monthText: 'Monat',+ secText: 'Sekunden',+ timeFormat: 'HH:ii',+ timeWheels: 'HHii',+ yearText: 'Jahr',+ nowText: 'Jetzt',+ // Calendar component+ dateText: 'Datum',+ timeText: 'Zeit',+ calendarText: 'Kalender',+ // Measurement components+ wholeText: 'Ganze Zahl',+ fractionText: 'Bruchzahl',+ unitText: 'Maßeinheit',+ // Time / Timespan component+ labels: ['Jahre', 'Monate', 'Tage', 'Stunden', 'Minuten', 'Sekunden', ''],+ labelsShort: ['Yrs', 'Mths', 'Days', 'Hrs', 'Mins', 'Secs', ''],+ // Timer component+ startText: 'Start',+ stopText: 'Stop',+ resetText: 'Reset',+ lapText: 'Lap',+ hideText: 'Hide'+ });+})(jQuery);diff --git a/js/ext/mobiscroll/i18n/mobiscroll.i18n.es.js b/js/ext/mobiscroll/i18n/mobiscroll.i18n.es.jsnew file mode 100644index 000000000..d02d4aa16--- /dev/null+++ b/js/ext/mobiscroll/i18n/mobiscroll.i18n.es.js@@ -0,0 +1,40 @@+(function ($) {+ $.mobiscroll.i18n.es = $.extend($.mobiscroll.i18n.es, {+ // Core+ setText: 'Aceptar',+ cancelText: 'Cancelar',+ // Datetime component+ dateFormat: 'dd/mm/yy',+ dateOrder: 'ddmmyy',+ dayNames: ['Domingo','Lunes','Martes','Miércoles','Jueves','Viernes','Sábado'],+ dayNamesShort: ['Do','Lu','Ma','Mi','Ju','Vi','Sá'],+ dayText: 'Día',+ hourText: 'Horas',+ minuteText: 'Minutos',+ monthNames: ['Enero','Febrero','Marzo','Abril','Mayo','Junio','Julio','Agosto','Septiembre','Octubre','Noviembre','Diciembre'],+ monthNamesShort: ['Ene','Feb','Mar','Abr','May','Jun','Jul','Ago','Sep','Oct','Nov','Dic'],+ monthText: 'Mes',+ secText: 'Segundos',+ timeFormat: 'HH:ii',+ timeWheels: 'HHii',+ yearText: 'Año',+ nowText: 'Ahora',+ // Calendar component+ dateText: 'Fecha',+ timeText: 'Tiempo',+ calendarText: 'Calendario',+ // Measurement components+ wholeText: 'Entero',+ fractionText: 'Fracción',+ unitText: 'Unidad',+ // Time / Timespan component+ labels: ['Años', 'Meses', 'Días', 'Horas', 'Minutos', 'Segundos', ''],+ labelsShort: ['Yrs', 'Mths', 'Days', 'Hrs', 'Mins', 'Secs', ''],+ // Timer component+ startText: 'Iniciar',+ stopText: 'Deténgase',+ resetText: 'Reinicializar',+ lapText: 'Lap',+ hideText: 'Esconder'+ });+})(jQuery);diff --git a/js/ext/mobiscroll/i18n/mobiscroll.i18n.fr.js b/js/ext/mobiscroll/i18n/mobiscroll.i18n.fr.jsnew file mode 100644index 000000000..ee7e35e3a--- /dev/null+++ b/js/ext/mobiscroll/i18n/mobiscroll.i18n.fr.js@@ -0,0 +1,40 @@+(function ($) {+ $.mobiscroll.i18n.fr = $.extend($.mobiscroll.i18n.fr, {+ // Core+ setText: 'Terminé',+ cancelText: 'Annuler',+ // Datetime component+ dateFormat: 'dd/mm/yy',+ dateOrder: 'ddmmyy',+ dayNames: ['Dimanche', 'Lundi', 'Mardi', 'Mercredi', 'Jeudi', 'Vendredi', 'Samedi'],+ dayNamesShort: ['Dim.', 'Lun.', 'Mar.', 'Mer.', 'Jeu.', 'Ven.', 'Sam.'],+ dayText: 'Jour',+ monthText: 'Mois',+ monthNames: ['Janvier', 'Février', 'Mars', 'Avril', 'Mai', 'Juin', 'Juillet', 'Août', 'Septembre', 'Octobre', 'Novembre', 'Décembre'],+ monthNamesShort: ['Janv.', 'Févr.', 'Mars', 'Avril', 'Mai', 'Juin', 'Juil.', 'Août', 'Sept.', 'Oct.', 'Nov.', 'Déc.'],+ hourText: 'Heures',+ minuteText: 'Minutes',+ secText: 'Secondes',+ timeFormat: 'HH:ii',+ timeWheels: 'HHii',+ yearText: 'Année',+ nowText: 'Maintenant',+ // Calendar component+ dateText: 'Date',+ timeText: 'Heure',+ calendarText: 'Calendrier',+ // Measurement components+ wholeText: 'Entier',+ fractionText: 'Fraction',+ unitText: 'Unité',+ // Time / Timespan component+ labels: ['Ans', 'Mois', 'Jours', 'Heures', 'Minutes', 'Secondes', ''],+ labelsShort: ['Yrs', 'Mths', 'Days', 'Hrs', 'Mins', 'Secs', ''],+ // Timer component+ startText: 'Indít',+ stopText: 'Megállít',+ resetText: 'Visszaállít',+ lapText: 'Lap',+ hideText: 'Elrejt'+ });+})(jQuery);diff --git a/js/ext/mobiscroll/i18n/mobiscroll.i18n.hu.js b/js/ext/mobiscroll/i18n/mobiscroll.i18n.hu.jsnew file mode 100644index 000000000..3b0dcec7a--- /dev/null+++ b/js/ext/mobiscroll/i18n/mobiscroll.i18n.hu.js@@ -0,0 +1,40 @@+(function ($) {+ $.mobiscroll.i18n.hu = $.extend($.mobiscroll.i18n.hu, {+ // Core+ setText: 'OK',+ cancelText: 'Mégse',+ // Datetime component+ dateFormat: 'dd.mm.yy',+ dateOrder: 'ddmmyy',+ dayNames: ['Vasárnap', 'Hétfő', 'Kedd', 'Szerda', 'Csütörtök', 'Péntek', 'Szombat'],+ dayNamesShort: ['Va', 'Hé', 'Ke', 'Sze', 'Csü', 'Pé', 'Szo'],+ dayText: 'Nap',+ hourText: 'Óra',+ minuteText: 'Perc',+ monthNames: ['Január', 'Február', 'Március', 'Április', 'Május', 'Június', 'Július', 'Augusztus', 'Szeptember', 'Október', 'November', 'December'],+ monthNamesShort: ['Jan', 'Feb', 'Már', 'Ápr', 'Máj', 'Jún', 'Júl', 'Aug', 'Szep', 'Okt', 'Nov', 'Dec'],+ monthText: 'Hónap',+ secText: 'Másodperc',+ timeFormat: 'HH:ii',+ timeWheels: 'HHii',+ yearText: 'Év',+ nowText: 'Most',+ // Calendar component+ dateText: 'Dátum',+ timeText: 'Idő',+ calendarText: 'Naptár',+ // Measurement components+ wholeText: 'Egész',+ fractionText: 'Tört',+ unitText: 'Egység',+ // Time / Timespan component+ labels: ['Év', 'Hónap', 'Nap', 'Óra', 'Perc', 'Másodperc', ''],+ labelsShort: ['Év', 'Hó.', 'Nap', 'Óra', 'Perc', 'Mp.', ''],+ // Timer component+ startText: 'Indít',+ stopText: 'Megállít',+ resetText: 'Visszaállít',+ lapText: 'Lap',+ hideText: 'Elrejt'+ });+})(jQuery);diff --git a/js/ext/mobiscroll/i18n/mobiscroll.i18n.it.js b/js/ext/mobiscroll/i18n/mobiscroll.i18n.it.jsnew file mode 100644index 000000000..38c6c13db--- /dev/null+++ b/js/ext/mobiscroll/i18n/mobiscroll.i18n.it.js@@ -0,0 +1,39 @@+(function ($) {+ $.mobiscroll.i18n.it = $.extend($.mobiscroll.i18n.it, {+ // Core+ setText: 'OK',+ cancelText: 'Annulla',+ // Datetime component+ dateFormat: 'dd-mm-yyyy',+ dateOrder: 'ddmmyy',+ dayNames: ['Domenica', 'LunedÌ', 'MertedÌ', 'MercoledÌ', 'GiovedÌ', 'VenerdÌ', 'Sabato'],+ dayNamesShort: ['Do', 'Lu', 'Ma', 'Me', 'Gi', 'Ve', 'Sa'],+ dayText: 'Giorno',+ hourText: 'Ore',+ minuteText: 'Minuti',+ monthNames: ['Gennaio', 'Febbraio', 'Marzo', 'Aprile', 'Maggio', 'Giugno', 'Luglio', 'Agosto', 'Settembre', 'Ottobre', 'Novembre', 'Dicembre'],+ monthNamesShort: ['Gen', 'Feb', 'Mar', 'Apr', 'Mag', 'Giu', 'Lug', 'Ago', 'Set', 'Ott', 'Nov', 'Dic'],+ monthText: 'Mese',+ secText: 'Secondi',+ timeFormat: 'HH:ii',+ timeWheels: 'HHii',+ yearText: 'Anno',+ // Calendar component+ dateText: 'Data',+ timeText: 'Volta',+ calendarText: 'Calendario',+ // Measurement components+ wholeText: 'Intero',+ fractionText: 'Frazione',+ unitText: 'Unità',+ // Time / Timespan component+ labels: ['Anni', 'Mesi', 'Giorni', 'Ore', 'Minuti', 'Secondi', ''],+ labelsShort: ['Yrs', 'Mths', 'Days', 'Hrs', 'Mins', 'Secs', ''],+ // Timer component+ startText: 'Inizio',+ stopText: 'Arresto',+ resetText: 'Ripristina',+ lapText: 'Lap',+ hideText: 'Nascondi'+ });+})(jQuery);diff --git a/js/ext/mobiscroll/i18n/mobiscroll.i18n.ja.js b/js/ext/mobiscroll/i18n/mobiscroll.i18n.ja.jsnew file mode 100644index 000000000..2e609edb6--- /dev/null+++ b/js/ext/mobiscroll/i18n/mobiscroll.i18n.ja.js@@ -0,0 +1,40 @@+(function ($) {+ $.mobiscroll.i18n.ja = $.extend($.mobiscroll.i18n.ja, {+ // Core+ setText: 'セット',+ cancelText: 'キャンセル',+ // Datetime component+ dateFormat: 'yy年mm月dd日',+ dateOrder: 'yymmdd',+ dayNames: ['日','月','火','水','木','金','土'],+ dayNamesShort: ['日','月','火','水','木','金','土'],+ dayText: '日',+ hourText: '時',+ minuteText: '分',+ monthNames: ['1月','2月','3月','4月','5月','6月','7月','8月','9月','10月','11月','12月'],+ monthNamesShort: ['1月','2月','3月','4月','5月','6月','7月','8月','9月','10月','11月','12月'],+ monthText: '月',+ secText: '秒',+ timeFormat: 'HH:ii',+ timeWheels: 'HHii',+ yearText: '年',+ nowText: '今',+ // Calendar component+ dateText: '日付',+ timeText: '時間',+ calendarText: 'カレンダー',+ // Measurement components+ wholeText: '全数',+ fractionText: '分数',+ unitText: '単位',+ // Time / Timespan component+ labels: ['年間', '月間', '日間', '時間', '分', '秒', ''],+ labelsShort: ['年間', '月間', '日間', '時間', '分', '秒', ''],+ // Timer component+ startText: '開始',+ stopText: '停止',+ resetText: 'リセット',+ lapText: 'ラップ',+ hideText: '隠す'+ });+})(jQuery);diff --git a/js/ext/mobiscroll/i18n/mobiscroll.i18n.nl.js b/js/ext/mobiscroll/i18n/mobiscroll.i18n.nl.jsnew file mode 100644index 000000000..554ae1370--- /dev/null+++ b/js/ext/mobiscroll/i18n/mobiscroll.i18n.nl.js@@ -0,0 +1,40 @@+(function ($) {+ $.mobiscroll.i18n.nl = $.extend($.mobiscroll.i18n.nl, {+ // Core+ setText: 'Instellen',+ cancelText: 'Annuleer',+ // Datetime component+ dateFormat: 'dd/mm/yy',+ dateOrder: 'ddmmyy',+ dayNames: ['zondag', 'maandag', 'Dinsdag', 'Woensdag', 'Donderdag', 'Vrijdag', 'Zaterdag'],+ dayNamesShort: ['zo', 'ma', 'di', 'wo', 'do', 'vr', 'za'],+ dayText: 'Dag',+ hourText: 'Uur',+ minuteText: 'Minuten',+ monthNames: ['januari', 'februari', 'maart', 'april', 'mei', 'juni', 'juli', 'augustus', 'september', 'oktober', 'november', 'december'],+ monthNamesShort: ['jan', 'feb', 'mrt', 'apr', 'mei', 'jun', 'jul', 'aug', 'sep', 'okt', 'nov', 'dec'],+ monthText: 'Maand',+ secText: 'Seconden',+ timeFormat: 'hh:ii A',+ timeWheels: 'hhiiA',+ yearText: 'Jaar',+ nowText: 'Nu',+ // Calendar component+ dateText: 'Datum',+ timeText: 'Tijd',+ calendarText: 'Kalender',+ // Measurement components+ wholeText: 'geheel',+ fractionText: 'fractie',+ unitText: 'eenheid',+ // Time / Timespan component+ labels: ['Jaren', 'Maanden', 'Dagen', 'Uren', 'Minuten', 'Seconden', ''],+ labelsShort: ['j', 'm', 'd', 'u', 'min', 'sec', ''],+ // Timer component+ startText: 'Start',+ stopText: 'Stop',+ resetText: 'Reset',+ lapText: 'Lap',+ hideText: 'Verbergen'+ });+})(jQuery);diff --git a/js/ext/mobiscroll/i18n/mobiscroll.i18n.no.js b/js/ext/mobiscroll/i18n/mobiscroll.i18n.no.jsnew file mode 100644index 000000000..99205b332--- /dev/null+++ b/js/ext/mobiscroll/i18n/mobiscroll.i18n.no.js@@ -0,0 +1,40 @@+(function ($) {+ $.mobiscroll.i18n.no = $.extend($.mobiscroll.i18n.no, {+ // Core+ setText: 'OK',+ cancelText: 'Avbryt',+ // Datetime component+ dateFormat: 'dd.mm.yy',+ dateOrder: 'ddmmyy',+ dayNames: ['Søndag', 'Mandag', 'Tirsdag', 'Onsdag', 'Torsdag', 'Fredag', 'Lørdag'],+ dayNamesShort: ['Sø', 'Ma', 'Ti', 'On', 'To', 'Fr', 'Lø'],+ dayText: 'Dag',+ hourText: 'Time',+ minuteText: 'Minutt',+ monthNames: ['Januar', 'Februar', 'Mars', 'April', 'Mai', 'Juni', 'Juli', 'August', 'September', 'Oktober', 'November', 'Desember'],+ monthNamesShort: ['Jan', 'Feb', 'Mar', 'Apr', 'Mai', 'Jun', 'Jul', 'Aug', 'Sep', 'Okt', 'Nov', 'Des'],+ monthText: 'Måned',+ secText: 'Sekund',+ timeFormat: 'HH:ii',+ timeWheels: 'HHii',+ yearText: 'År',+ nowText: 'Nå',+ // Calendar component+ dateText: 'Dato',+ timeText: 'Tid',+ calendarText: 'Kalender',+ // Measurement components+ wholeText: 'Hele',+ fractionText: 'Fraksjon',+ unitText: 'Enhet',+ // Time / Timespan component+ labels: ['År', 'Måneder', 'Dager', 'Timer', 'Minutter', 'Sekunder', ''],+ labelsShort: ['Yrs', 'Mths', 'Days', 'Hrs', 'Mins', 'Secs', ''],+ // Timer component+ startText: 'Start',+ stopText: 'Stopp',+ resetText: 'Tilbakestille',+ lapText: 'Runde',+ hideText: 'Skjul'+ });+})(jQuery);diff --git a/js/ext/mobiscroll/i18n/mobiscroll.i18n.pt-BR.js b/js/ext/mobiscroll/i18n/mobiscroll.i18n.pt-BR.jsnew file mode 100644index 000000000..0f6ef9cd7--- /dev/null+++ b/js/ext/mobiscroll/i18n/mobiscroll.i18n.pt-BR.js@@ -0,0 +1,43 @@+/*+ * Translation by: Ivan Gomes <[email protected]>+ *+ */+(function ($) {+ $.mobiscroll.i18n['pt-BR'] = $.extend($.mobiscroll.i18n['pt-BR'], {+ // Core+ setText: 'Selecionar',+ cancelText: 'Cancelar',+ // Datetime component+ dateFormat: 'dd/mm/yy',+ dateOrder: 'ddMMyy',+ dayNames: ['Domingo','Segunda-feira','Terça-feira','Quarta-feira','Quinta-feira','Sexta-feira','Sábado'],+ dayNamesShort: ['Dom','Seg','Ter','Qua','Qui','Sex','Sáb'],+ dayText: 'Dia',+ hourText: 'Hora',+ minuteText: 'Minutos',+ monthNames: ['Janeiro','Fevereiro','Março','Abril','Maio','Junho','Julho','Agosto','Setembro','Outubro','Novembro','Dezembro'],+ monthNamesShort: ['Jan','Fev','Mar','Abr','Mai','Jun','Jul','Ago','Set','Out','Nov','Dez'],+ monthText: 'Mês',+ secText: 'Segundo',+ timeFormat: 'HH:ii',+ timeWheels: 'HHii',+ yearText: 'Ano',+ // Calendar component+ dateText: 'Data',+ timeText: 'Tempo',+ calendarText: 'Calendário',+ // Measurement components+ wholeText: 'Inteiro',+ fractionText: 'Fração',+ unitText: 'Unidade',+ // Time / Timespan component+ labels: ['Anos', 'Meses', 'Dias', 'Horas', 'Minutos', 'Segundos', ''],+ labelsShort: ['Yrs', 'Mths', 'Days', 'Hrs', 'Mins', 'Secs', ''],+ // Timer component+ startText: 'Começar',+ stopText: 'Pare',+ resetText: 'Reinicializar',+ lapText: 'Lap',+ hideText: 'Esconder'+ });+})(jQuery);diff --git a/js/ext/mobiscroll/i18n/mobiscroll.i18n.tr.js b/js/ext/mobiscroll/i18n/mobiscroll.i18n.tr.jsnew file mode 100644index 000000000..862b0d283--- /dev/null+++ b/js/ext/mobiscroll/i18n/mobiscroll.i18n.tr.js@@ -0,0 +1,40 @@+(function ($) {+ $.mobiscroll.i18n.tr = $.extend($.mobiscroll.i18n.tr, {+ // Core+ setText: 'Seç',+ cancelText: 'İptal',+ // Datetime component+ dateFormat: 'dd.mm.yy',+ dateOrder: 'ddmmyy',+ dayNames: ['Pazar', 'Pazartesi', 'Salı', 'Çarşamba', 'Perşembe', 'Cuma', 'Cumartesi'],+ dayNamesShort: ['Paz', 'Pzt', 'Sal', 'Çar', 'Per', 'Cum', 'Cmt'],+ dayText: 'Gün',+ hourText: 'Saat',+ minuteText: 'Dakika',+ monthNames: ['Ocak', 'Şubat', 'Mart', 'Nisan', 'Mayıs', 'Haziran', 'Temmuz', 'Ağustos', 'Eylül', 'Ekim', 'Kasım', 'Aralık'],+ monthNamesShort: ['Oca', 'Şub', 'Mar', 'Nis', 'May', 'Haz', 'Tem', 'Ağu', 'Eyl', 'Eki', 'Kas', 'Ara'],+ monthText: 'Ay',+ secText: 'Saniye',+ timeFormat: 'hh:ii A',+ timeWheels: 'hhiiA',+ yearText: 'Yıl',+ nowText: 'Şimdi',+ // Calendar component+ dateText: 'Tarih',+ timeText: 'Zaman',+ calendarText: 'Takvim',+ // Measurement components+ wholeText: 'Tam',+ fractionText: 'Kesir',+ unitText: 'Birim',+ // Time / Timespan component+ labels: ['Yıl', 'Ay', 'Gün', 'Saat', 'Dakika', 'Saniye', ''],+ labelsShort: ['Yıl', 'Ay', 'Gün', 'Sa', 'Dak', 'Sn', ''],+ // Timer component+ startText: 'Başla',+ stopText: 'Durdur',+ resetText: 'Sıfırla',+ lapText: 'Tur',+ hideText: 'Gizle'+ });+})(jQuery);diff --git a/js/ext/mobiscroll/i18n/mobiscroll.i18n.zh.js b/js/ext/mobiscroll/i18n/mobiscroll.i18n.zh.jsnew file mode 100644index 000000000..421b097a8--- /dev/null+++ b/js/ext/mobiscroll/i18n/mobiscroll.i18n.zh.js@@ -0,0 +1,40 @@+(function ($) {+ $.mobiscroll.i18n.zh = $.extend($.mobiscroll.i18n.zh, {+ // Core+ setText: '确定',+ cancelText: '取消',+ // Datetime component+ dateFormat: 'dd/mm/yy',+ dateOrder: 'ddmmyy',+ dayNames: ['周日','周一','周二','周三','周四','周五','周六'],+ dayNamesShort: ['日','一','二','三','四','五','六'],+ dayText: '日',+ hourText: '时',+ minuteText: '分',+ monthNames: ['1月','2月','3月','4月','5月','6月','7月','8月','9月','10月','11月','12月'],+ monthNamesShort: ['一','二','三','四','五','六','七','八','九','十','十一','十二'],+ monthText: '月',+ secText: '秒',+ timeFormat: 'HH:ii',+ timeWheels: 'HHii',+ yearText: '年',+ nowText: '当前',+ // Calendar component+ dateText: '日',+ timeText: '时间',+ calendarText: '日历',+ // Measurement components+ wholeText: 'Whole',+ fractionText: 'Fraction',+ unitText: 'Unit',+ // Time / Timespan component+ labels: ['Years', 'Months', 'Days', 'Hours', 'Minutes', 'Seconds', ''],+ labelsShort: ['Yrs', 'Mths', 'Days', 'Hrs', 'Mins', 'Secs', ''],+ // Timer component+ startText: 'Start',+ stopText: 'Stop',+ resetText: 'Reset',+ lapText: 'Lap',+ hideText: 'Hide'+ });+})(jQuery);diff --git a/js/ext/mobiscroll/mobiscroll.android-ics.js b/js/ext/mobiscroll/mobiscroll.android-ics.jsnew file mode 100644index 000000000..199ed6ad5--- /dev/null+++ b/js/ext/mobiscroll/mobiscroll.android-ics.js@@ -0,0 +1,18 @@+(function ($) {+ var theme = {+ defaults: {+ dateOrder: 'Mddyy',+ mode: 'mixed',+ rows: 5,+ width: 70,+ height: 36,+ showLabel: false,+ useShortLabels: true+ }+ };++ $.mobiscroll.themes['android-ics'] = theme;+ $.mobiscroll.themes['android-ics light'] = theme;++})(jQuery);+diff --git a/js/ext/mobiscroll/mobiscroll.android.js b/js/ext/mobiscroll/mobiscroll.android.jsnew file mode 100644index 000000000..29b214beb--- /dev/null+++ b/js/ext/mobiscroll/mobiscroll.android.js@@ -0,0 +1,13 @@+(function ($) {++ $.mobiscroll.themes.android = {+ defaults: {+ dateOrder: 'Mddyy',+ mode: 'clickpick',+ height: 50,+ showLabel: false+ }+ }++})(jQuery);+diff --git a/js/ext/mobiscroll/mobiscroll.core.js b/js/ext/mobiscroll/mobiscroll.core.jsnew file mode 100644index 000000000..eaaf16739--- /dev/null+++ b/js/ext/mobiscroll/mobiscroll.core.js@@ -0,0 +1,1078 @@+/*jslint eqeq: true, plusplus: true, undef: true, sloppy: true, vars: true, forin: true, nomen: true */+/*!+ * jQuery MobiScroll v2.6.0+ * http://mobiscroll.com+ *+ * Copyright 2010-2013, Acid Media+ * Licensed under the MIT license.+ *+ */+(function ($) {++ function Scroller(elem, settings) {+ var m,+ hi,+ v,+ dw,+ ww, // Window width+ wh, // Window height+ rwh,+ mw, // Modal width+ mh, // Modal height+ anim,+ debounce,+ theme,+ lang,+ click,+ scrollable,+ moved,+ start,+ startTime,+ stop,+ p,+ min,+ max,+ target,+ index,+ timer,+ readOnly,+ that = this,+ ms = $.mobiscroll,+ e = elem,+ elm = $(e),+ s = extend({}, defaults),+ pres = {},+ iv = {},+ pos = {},+ pixels = {},+ wheels = [],+ input = elm.is('input'),+ visible = false,+ onStart = function (e) {+ // Scroll start+ if (testTouch(e) && !move && !isReadOnly(this) && !click) {+ // Prevent scroll+ e.preventDefault();++ move = true;+ scrollable = s.mode != 'clickpick';+ target = $('.dw-ul', this);+ setGlobals(target);+ moved = iv[index] !== undefined; // Don't allow tap, if still moving+ p = moved ? getCurrentPosition(target) : pos[index];+ start = getCoord(e, 'Y');+ startTime = new Date();+ stop = start;+ scroll(target, index, p, 0.001);++ if (scrollable) {+ target.closest('.dwwl').addClass('dwa');+ }++ $(document).bind(MOVE_EVENT, onMove).bind(END_EVENT, onEnd);+ }+ },+ onMove = function (e) {+ if (scrollable) {+ e.preventDefault();+ e.stopPropagation();+ stop = getCoord(e, 'Y');+ scroll(target, index, constrain(p + (start - stop) / hi, min - 1, max + 1));+ }+ moved = true;+ },+ onEnd = function (e) {+ var time = new Date() - startTime,+ val = constrain(p + (start - stop) / hi, min - 1, max + 1),+ speed,+ dist,+ tindex,+ ttop = target.offset().top;++ if (time < 300) {+ speed = (stop - start) / time;+ dist = (speed * speed) / s.speedUnit;+ if (stop - start < 0) {+ dist = -dist;+ }+ } else {+ dist = stop - start;+ }++ tindex = Math.round(p - dist / hi);++ if (!dist && !moved) { // this is a "tap"+ var idx = Math.floor((stop - ttop) / hi),+ li = $('.dw-li', target).eq(idx),+ hl = scrollable;++ if (event('onValueTap', [li]) !== false) {+ tindex = idx;+ } else {+ hl = true;+ }++ if (hl) {+ li.addClass('dw-hl'); // Highlight+ setTimeout(function () {+ li.removeClass('dw-hl');+ }, 200);+ }+ }++ if (scrollable) {+ calc(target, tindex, 0, true, Math.round(val));+ }++ move = false;+ target = null;++ $(document).unbind(MOVE_EVENT, onMove).unbind(END_EVENT, onEnd);+ },+ onBtnStart = function (e) {+ $(document).bind(END_EVENT, onBtnEnd);+ // Active button+ if (!$(this).hasClass('dwb-d')) {+ $(this).addClass('dwb-a');+ }+ // +/- buttons+ if ($(this).hasClass('dwwb')) {+ var w = $(this).closest('.dwwl');+ if (testTouch(e) && !isReadOnly(w) && !w.hasClass('dwa')) {+ e.stopPropagation();+ e.preventDefault();+ click = true;+ // + Button+ var t = w.find('.dw-ul'),+ func = $(this).hasClass('dwwbp') ? plus : minus;++ setGlobals(t);+ clearInterval(timer);+ timer = setInterval(function () { func(t); }, s.delay);+ func(t);+ }+ }+ },+ onBtnEnd = function (e) {+ if (click) {+ clearInterval(timer);+ click = false;+ }+ $(document).unbind(END_EVENT, onBtnEnd);+ $('.dwb-a', dw).removeClass('dwb-a');+ },+ onScroll = function (e) {+ if (!isReadOnly(this)) {+ e.preventDefault();+ e = e.originalEvent;+ var delta = e.wheelDelta ? (e.wheelDelta / 120) : (e.detail ? (-e.detail / 3) : 0),+ t = $('.dw-ul', this);++ setGlobals(t);+ calc(t, Math.round(pos[index] - delta), delta < 0 ? 1 : 2);+ }+ };++ // Private functions++ function isReadOnly(wh) {+ if ($.isArray(s.readonly)) {+ var i = $('.dwwl', dw).index(wh);+ return s.readonly[i];+ }+ return s.readonly;+ }++ function generateWheelItems(i) {+ var html = '<div class="dw-bf">',+ ww = wheels[i],+ w = ww.values ? ww : convert(ww),+ l = 1,+ values = w.values,+ keys = w.keys || values;++ $.each(values, function (j, v) {+ if (l % 20 == 0) {+ html += '</div><div class="dw-bf">';+ }+ html += '<div class="dw-li dw-v" data-val="' + keys[j] + '" style="height:' + hi + 'px;line-height:' + hi + 'px;"><div class="dw-i">' + v + '</div></div>';+ l++;+ });++ html += '</div>';+ return html;+ }++ function setGlobals(t) {+ min = $('.dw-li', t).index($('.dw-v', t).eq(0));+ max = $('.dw-li', t).index($('.dw-v', t).eq(-1));+ index = $('.dw-ul', dw).index(t);+ }++ function formatHeader(v) {+ var t = s.headerText;+ return t ? (typeof t === 'function' ? t.call(e, v) : t.replace(/\{value\}/i, v)) : '';+ }++ function read() {+ that.temp = ((input && that.val !== null && that.val != elm.val()) || that.values === null) ? s.parseValue(elm.val() || '', that) : that.values.slice(0);+ setVal();+ }++ function getCurrentPosition(t) {+ var style = window.getComputedStyle ? getComputedStyle(t[0]) : t[0].style,+ matrix,+ px;++ if (has3d) {+ $.each(['t', 'webkitT', 'MozT', 'OT', 'msT'], function (i, v) {+ if (style[v + 'ransform'] !== undefined) {+ matrix = style[v + 'ransform'];+ return false;+ }+ });+ matrix = matrix.split(')')[0].split(', ');+ px = matrix[13] || matrix[5];+ } else {+ px = style.top.replace('px', '');+ }++ return Math.round(m - (px / hi));+ }++ function ready(t, i) {+ clearTimeout(iv[i]);+ delete iv[i];+ t.closest('.dwwl').removeClass('dwa');+ }++ function scroll(t, index, val, time, active) {++ var px = (m - val) * hi,+ style = t[0].style,+ i;++ if (px == pixels[index] && iv[index]) {+ return;+ }++ if (time && px != pixels[index]) {+ // Trigger animation start event+ event('onAnimStart', [dw, index, time]);+ }++ pixels[index] = px;++ style[pr + 'Transition'] = 'all ' + (time ? time.toFixed(3) : 0) + 's ease-out';++ if (has3d) {+ style[pr + 'Transform'] = 'translate3d(0,' + px + 'px,0)';+ } else {+ style.top = px + 'px';+ }++ if (iv[index]) {+ ready(t, index);+ }++ if (time && active !== undefined) {+ t.closest('.dwwl').addClass('dwa');+ iv[index] = setTimeout(function () {+ ready(t, index);+ }, time * 1000);+ }++ pos[index] = val;+ }++ function scrollToPos(time, index, manual, dir, active) {++ // Call validation event+ if (event('validate', [dw, index, time]) !== false) {++ // Set scrollers to position+ $('.dw-ul', dw).each(function (i) {+ var t = $(this),+ cell = $('.dw-li[data-val="' + that.temp[i] + '"]', t),+ cells = $('.dw-li', t),+ v = cells.index(cell),+ l = cells.length,+ sc = i == index || index === undefined;++ // Scroll to a valid cell+ if (!cell.hasClass('dw-v')) {+ var cell1 = cell,+ cell2 = cell,+ dist1 = 0,+ dist2 = 0;++ while (v - dist1 >= 0 && !cell1.hasClass('dw-v')) {+ dist1++;+ cell1 = cells.eq(v - dist1);+ }++ while (v + dist2 < l && !cell2.hasClass('dw-v')) {+ dist2++;+ cell2 = cells.eq(v + dist2);+ }++ // If we have direction (+/- or mouse wheel), the distance does not count+ if (((dist2 < dist1 && dist2 && dir !== 2) || !dist1 || (v - dist1 < 0) || dir == 1) && cell2.hasClass('dw-v')) {+ cell = cell2;+ v = v + dist2;+ } else {+ cell = cell1;+ v = v - dist1;+ }+ }++ if (!(cell.hasClass('dw-sel')) || sc) {+ // Set valid value+ that.temp[i] = cell.attr('data-val');++ // Add selected class to cell+ $('.dw-sel', t).removeClass('dw-sel');+ cell.addClass('dw-sel');++ // Scroll to position+ scroll(t, i, v, sc ? time : 0.1, sc ? active : false);+ }+ });++ // Reformat value if validation changed something+ v = s.formatResult(that.temp);+ if (s.display == 'inline') {+ setVal(manual, 0, true);+ } else {+ $('.dwv', dw).html(formatHeader(v));+ }++ if (manual) {+ event('onChange', [v]);+ }+ }++ }++ function event(name, args) {+ var ret;+ args.push(that);+ $.each([theme.defaults, pres, settings], function (i, v) {+ if (v[name]) { // Call preset event+ ret = v[name].apply(e, args);+ }+ });+ return ret;+ }++ function calc(t, val, dir, anim, orig) {+ val = constrain(val, min, max);++ var cell = $('.dw-li', t).eq(val),+ o = orig === undefined ? val : orig,+ idx = index,+ time = anim ? (val == o ? 0.1 : Math.abs((val - o) * s.timeUnit)) : 0;++ // Set selected scroller value+ that.temp[idx] = cell.attr('data-val');++ scroll(t, idx, val, time, orig);++ setTimeout(function () {+ // Validate+ scrollToPos(time, idx, true, dir, orig);+ }, 10);+ }++ function plus(t) {+ var val = pos[index] + 1;+ calc(t, val > max ? min : val, 1, true);+ }++ function minus(t) {+ var val = pos[index] - 1;+ calc(t, val < min ? max : val, 2, true);+ }++ function setVal(fill, time, noscroll, temp) {++ if (visible && !noscroll) {+ scrollToPos(time);+ }++ v = s.formatResult(that.temp);++ if (!temp) {+ that.values = that.temp.slice(0);+ that.val = v;+ }++ if (fill) {+ if (input) {+ elm.val(v).trigger('change');+ }+ }+ }++ // Public functions++ that.position = function (check) {++ if (s.display == 'inline' || (ww === $(window).width() && rwh === $(window).height() && check) || (event('onPosition', [dw]) === false)) {+ return;+ }++ var w,+ l,+ t,+ aw, // anchor width+ ah, // anchor height+ ap, // anchor position+ at, // anchor top+ al, // anchor left+ arr, // arrow+ arrw, // arrow width+ arrl, // arrow left+ scroll,+ totalw = 0,+ minw = 0,+ st = $(window).scrollTop(),+ wr = $('.dwwr', dw),+ d = $('.dw', dw),+ css = {},+ anchor = s.anchor === undefined ? elm : s.anchor;++ ww = $(window).width();+ rwh = $(window).height();+ wh = window.innerHeight; // on iOS we need innerHeight+ wh = wh || rwh;++ if (/modal|bubble/.test(s.display)) {+ $('.dwc', dw).each(function () {+ w = $(this).outerWidth(true);+ totalw += w;+ minw = (w > minw) ? w : minw;+ });+ w = totalw > ww ? minw : totalw;+ wr.width(w).css('white-space', totalw > ww ? '' : 'nowrap');+ }++ mw = d.outerWidth();+ mh = d.outerHeight(true);++ if (s.display == 'modal') {+ l = (ww - mw) / 2;+ t = st + (wh - mh) / 2;+ } else if (s.display == 'bubble') {+ scroll = true;+ arr = $('.dw-arrw-i', dw);+ ap = anchor.offset();+ at = ap.top;+ al = ap.left;++ // horizontal positioning+ aw = anchor.outerWidth();+ ah = anchor.outerHeight();+ l = al - (d.outerWidth(true) - aw) / 2;+ l = l > (ww - mw) ? (ww - (mw + 20)) : l;+ l = l >= 0 ? l : 20;++ // vertical positioning+ t = at - mh; // above the input+ if ((t < st) || (at > st + wh)) { // if doesn't fit above or the input is out of the screen+ d.removeClass('dw-bubble-top').addClass('dw-bubble-bottom');+ t = at + ah; // below the input+ } else {+ d.removeClass('dw-bubble-bottom').addClass('dw-bubble-top');+ }++ // Calculate Arrow position+ arrw = arr.outerWidth();+ arrl = al + aw / 2 - (l + (mw - arrw) / 2);++ // Limit Arrow position+ $('.dw-arr', dw).css({ left: constrain(arrl, 0, arrw) });+ } else {+ css.width = '100%';+ if (s.display == 'top') {+ t = st;+ } else if (s.display == 'bottom') {+ t = st + wh - mh;+ }+ }++ css.top = t < 0 ? 0 : t;+ css.left = l;+ d.css(css);++ // If top + modal height > doc height, increase doc height+ $('.dw-persp', dw).height(0).height(t + mh > $(document).height() ? t + mh : $(document).height());++ // Scroll needed+ if (scroll && ((t + mh > st + wh) || (at > st + wh))) {+ $(window).scrollTop(t + mh - wh);+ }+ };++ /**+ * Enables the scroller and the associated input.+ */+ that.enable = function () {+ s.disabled = false;+ if (input) {+ elm.prop('disabled', false);+ }+ };++ /**+ * Disables the scroller and the associated input.+ */+ that.disable = function () {+ s.disabled = true;+ if (input) {+ elm.prop('disabled', true);+ }+ };++ /**+ * Gets the selected wheel values, formats it, and set the value of the scroller instance.+ * If input parameter is true, populates the associated input element.+ * @param {Array} values - Wheel values.+ * @param {Boolean} [fill=false] - Also set the value of the associated input element.+ * @param {Number} [time=0] - Animation time+ * @param {Boolean} [temp=false] - If true, then only set the temporary value.(only scroll there but not set the value)+ */+ that.setValue = function (values, fill, time, temp) {+ that.temp = $.isArray(values) ? values.slice(0) : s.parseValue.call(e, values + '', that);+ setVal(fill, time, false, temp);+ };++ that.getValue = function () {+ return that.values;+ };++ that.getValues = function () {+ var ret = [],+ i;++ for (i in that._selectedValues) {+ ret.push(that._selectedValues[i]);+ }+ return ret;+ };++ /**+ * Changes the values of a wheel, and scrolls to the correct position+ */+ that.changeWheel = function (idx, time) {+ if (dw) {+ var i = 0,+ nr = idx.length;++ $.each(s.wheels, function (j, wg) {+ $.each(wg, function (k, w) {+ if ($.inArray(i, idx) > -1) {+ wheels[i] = w;+ $('.dw-ul', dw).eq(i).html(generateWheelItems(i));+ nr--;+ if (!nr) {+ that.position();+ scrollToPos(time, undefined, true);+ return false;+ }+ }+ i++;+ });+ if (!nr) {+ return false;+ }+ });+ }+ };++ /**+ * Return true if the scroller is currently visible.+ */+ that.isVisible = function () {+ return visible;+ };++ that.tap = function (el, handler) {+ var startX,+ startY;++ if (s.tap) {+ el.bind('touchstart', function (e) {+ e.preventDefault();+ startX = getCoord(e, 'X');+ startY = getCoord(e, 'Y');+ }).bind('touchend', function (e) {+ // If movement is less than 20px, fire the click event handler+ if (Math.abs(getCoord(e, 'X') - startX) < 20 && Math.abs(getCoord(e, 'Y') - startY) < 20) {+ handler.call(this, e);+ }+ tap = true;+ setTimeout(function () {+ tap = false;+ }, 300);+ });+ }++ el.bind('click', function (e) {+ if (!tap) {+ // If handler was not called on touchend, call it on click;+ handler.call(this, e);+ }+ });++ };++ /**+ * Shows the scroller instance.+ * @param {Boolean} prevAnim - Prevent animation if true+ */+ that.show = function (prevAnim) {+ if (s.disabled || visible) {+ return false;+ }++ if (s.display == 'top') {+ anim = 'slidedown';+ }++ if (s.display == 'bottom') {+ anim = 'slideup';+ }++ // Parse value from input+ read();++ event('onBeforeShow', []);++ // Create wheels+ var l = 0,+ mAnim = '';++ if (anim && !prevAnim) {+ mAnim = 'dw-' + anim + ' dw-in';+ }+ // Create wheels containers+ var html = '<div class="' + s.theme + ' dw-' + s.display + (prefix ? ' dw' + prefix : '') + '">' + (s.display == 'inline' ? '<div class="dw dwbg dwi"><div class="dwwr">' : '<div class="dw-persp">' + '<div class="dwo"></div><div class="dw dwbg ' + mAnim + '"><div class="dw-arrw"><div class="dw-arrw-i"><div class="dw-arr"></div></div></div><div class="dwwr">' + (s.headerText ? '<div class="dwv"></div>' : '')) + '<div class="dwcc">';++ $.each(s.wheels, function (i, wg) { // Wheel groups+ html += '<div class="dwc' + (s.mode != 'scroller' ? ' dwpm' : ' dwsc') + (s.showLabel ? '' : ' dwhl') + '"><div class="dwwc dwrc"><table cellpadding="0" cellspacing="0"><tr>';+ $.each(wg, function (j, w) { // Wheels+ wheels[l] = w;+ html += '<td><div class="dwwl dwrc dwwl' + l + '">' + (s.mode != 'scroller' ? '<div class="dwb-e dwwb dwwbp" style="height:' + hi + 'px;line-height:' + hi + 'px;"><span>+</span></div><div class="dwb-e dwwb dwwbm" style="height:' + hi + 'px;line-height:' + hi + 'px;"><span>–</span></div>' : '') + '<div class="dwl">' + (w.label || j) + '</div><div class="dwww"><div class="dww" style="height:' + (s.rows * hi) + 'px;min-width:' + s.width + 'px;"><div class="dw-ul">';+ // Create wheel values+ html += generateWheelItems(l);+ html += '</div><div class="dwwol"></div></div><div class="dwwo"></div></div><div class="dwwol"></div></div></td>';+ l++;+ });++ html += '</tr></table></div></div>';+ });++ html += '</div>' + (s.display != 'inline' ? '<div class="dwbc' + (s.button3 ? ' dwbc-p' : '') + '"><span class="dwbw dwb-s"><span class="dwb dwb-e">' + s.setText + '</span></span>' + (s.button3 ? '<span class="dwbw dwb-n"><span class="dwb dwb-e">' + s.button3Text + '</span></span>' : '') + '<span class="dwbw dwb-c"><span class="dwb dwb-e">' + s.cancelText + '</span></span></div></div>' : '') + '</div></div></div>';+ dw = $(html);++ scrollToPos();++ event('onMarkupReady', [dw]);++ // Show+ if (s.display != 'inline') {+ dw.appendTo('body');+ if (anim && !prevAnim) {+ dw.addClass('dw-trans');+ // Remove animation class+ setTimeout(function () {+ dw.removeClass('dw-trans').find('.dw').removeClass(mAnim);+ }, 350);+ }+ } else if (elm.is('div')) {+ elm.html(dw);+ } else {+ dw.insertAfter(elm);+ }++ event('onMarkupInserted', [dw]);++ visible = true;++ // Theme init+ theme.init(dw, that);++ if (s.display != 'inline') {+ // Init buttons+ that.tap($('.dwb-s span', dw), function () {+ if (that.hide(false, 'set') !== false) {+ setVal(true, 0, true);+ event('onSelect', [that.val]);+ }+ });++ that.tap($('.dwb-c span', dw), function () {+ that.cancel();+ });++ if (s.button3) {+ that.tap($('.dwb-n span', dw), s.button3);+ }++ // prevent scrolling if not specified otherwise+ if (s.scrollLock) {+ dw.bind('touchmove', function (e) {+ if (mh <= wh && mw <= ww) {+ e.preventDefault();+ }+ });+ }++ // Disable inputs to prevent bleed through (Android bug) and set autocomplete to off (for Firefox)+ /*$('input,select,button').each(function () {+ if (!this.disabled) {+ $(this).addClass('dwtd').prop('disabled', true).data('autocomplete', $(this).attr('autocomplete')).attr('autocomplete', 'off');+ }+ });*/++ // Set position+ that.position();+ $(window).bind('orientationchange.dw resize.dw', function () {+ // Sometimes scrollTop is not correctly set, so we wait a little+ clearTimeout(debounce);+ debounce = setTimeout(function () {+ that.position(true);+ }, 100);+ });+ }++ // Events+ dw.delegate('.dwwl', 'DOMMouseScroll mousewheel', onScroll).delegate('.dwb-e', START_EVENT, onBtnStart).delegate('.dwwl', START_EVENT, onStart);++ event('onShow', [dw, v]);+ };++ /**+ * Hides the scroller instance.+ */+ that.hide = function (prevAnim, btn) {+ // If onClose handler returns false, prevent hide+ if (!visible || event('onClose', [v, btn]) === false) {+ return false;+ }++ // Re-enable temporary disabled fields+ $('.dwtd').each(function () {+ $(this).prop('disabled', false).removeClass('dwtd');+ if ($(this).data('autocomplete')) {+ $(this).attr('autocomplete', $(this).data('autocomplete'));+ } else {+ $(this).removeAttr('autocomplete');+ }+ });+ elm.blur();++ // Hide wheels and overlay+ if (dw) {+ if (s.display != 'inline' && anim && !prevAnim) {+ dw.addClass('dw-trans').find('.dw').addClass('dw-' + anim + ' dw-out');+ setTimeout(function () {+ dw.remove();+ dw = null;+ }, 350);+ } else {+ dw.remove();+ dw = null;+ }+ visible = false;+ pixels = {};+ // Stop positioning on window resize+ $(window).unbind('.dw');+ }+ };++ /**+ * Cancel and hide the scroller instance.+ */+ that.cancel = function () {+ if (that.hide(false, 'cancel') !== false) {+ event('onCancel', [that.val]);+ }+ };++ /**+ * Scroller initialization.+ */+ that.init = function (ss) {+ // Get theme defaults+ theme = extend({ defaults: {}, init: empty }, ms.themes[ss.theme || s.theme]);++ // Get language defaults+ lang = ms.i18n[ss.lang || s.lang];++ extend(settings, ss); // Update original user settings+ extend(s, theme.defaults, lang, settings);++ that.settings = s;++ // Unbind all events (if re-init)+ elm.unbind('.dw');++ var preset = ms.presets[s.preset];++ if (preset) {+ pres = preset.call(e, that);+ extend(s, pres, settings); // Load preset settings+ }++ // Set private members+ m = Math.floor(s.rows / 2);+ hi = s.height;+ anim = s.animate;++ if (visible) {+ that.hide();+ }++ if (s.display == 'inline') {+ that.show();+ } else {+ read();+ if (input && s.showOnFocus) {+ // Set element readonly, save original state+ if (readOnly === undefined) {+ readOnly = e.readOnly;+ }+ e.readOnly = true;+ // Init show datewheel+ elm.bind('focus.dw', function () { that.show(); });+ }+ }+ };++ that.trigger = function (name, params) {+ return event(name, params);+ };++ that.option = function (opt, value) {+ var obj = {};+ if (typeof opt === 'object') {+ obj = opt;+ } else {+ obj[opt] = value;+ }+ that.init(obj);+ };++ that.destroy = function () {+ that.hide();+ elm.unbind('.dw');+ delete scrollers[e.id];+ if (input) {+ e.readOnly = readOnly;+ }+ };++ that.getInst = function () {+ return that;+ };++ that.values = null;+ that.val = null;+ that.temp = null;+ that._selectedValues = {};++ that.init(settings);+ }++ function testProps(props) {+ var i;+ for (i in props) {+ if (mod[props[i]] !== undefined) {+ return true;+ }+ }+ return false;+ }++ function testPrefix() {+ var prefixes = ['Webkit', 'Moz', 'O', 'ms'],+ p;++ for (p in prefixes) {+ if (testProps([prefixes[p] + 'Transform'])) {+ return '-' + prefixes[p].toLowerCase();+ }+ }+ return '';+ }++ function testTouch(e) {+ if (e.type === 'touchstart') {+ touch = true;+ /*setTimeout(function () {+ touch = false; // Reset if mouse event was not fired+ }, 500);*/+ } else if (touch) {+ touch = false;+ return false;+ }+ return true;+ }++ function getCoord(e, c) {+ var org = e.originalEvent,+ ct = e.changedTouches;+ return ct || (org && org.changedTouches) ? (org ? org.changedTouches[0]['page' + c] : ct[0]['page' + c]) : e['page' + c];++ }++ function constrain(val, min, max) {+ return Math.max(min, Math.min(val, max));+ }++ function convert(w) {+ var ret = {+ values: [],+ keys: []+ };+ $.each(w, function (k, v) {+ ret.keys.push(k);+ ret.values.push(v);+ });+ return ret;+ }++ function init(that, options, args) {+ var ret = that;++ // Init+ if (typeof options === 'object') {+ return that.each(function () {+ if (!this.id) {+ uuid += 1;+ this.id = 'mobiscroll' + uuid;+ }+ scrollers[this.id] = new Scroller(this, options);+ });+ }++ // Method call+ if (typeof options === 'string') {+ that.each(function () {+ var r,+ inst = scrollers[this.id];++ if (inst && inst[options]) {+ r = inst[options].apply(this, Array.prototype.slice.call(args, 1));+ if (r !== undefined) {+ ret = r;+ return false;+ }+ }+ });+ }++ return ret;+ }++ var move,+ tap,+ touch,+ date = new Date(),+ uuid = date.getTime(),+ scrollers = {},+ empty = function () {},+ mod = document.createElement('modernizr').style,+ has3d = testProps(['perspectiveProperty', 'WebkitPerspective', 'MozPerspective', 'OPerspective', 'msPerspective']),+ prefix = testPrefix(),+ pr = prefix.replace(/^\-/, '').replace('moz', 'Moz'),+ extend = $.extend,+ START_EVENT = 'touchstart mousedown',+ MOVE_EVENT = 'touchmove mousemove',+ END_EVENT = 'touchend mouseup',+ defaults = {+ // Options+ width: 70,+ height: 40,+ rows: 3,+ delay: 300,+ disabled: false,+ readonly: false,+ showOnFocus: true,+ showLabel: true,+ wheels: [],+ theme: '',+ headerText: '{value}',+ display: 'modal',+ mode: 'scroller',+ preset: '',+ lang: 'en-US',+ setText: 'Set',+ cancelText: 'Cancel',+ scrollLock: true,+ tap: true,+ speedUnit: 0.0012,+ timeUnit: 0.1,+ formatResult: function (d) {+ return d.join(' ');+ },+ parseValue: function (value, inst) {+ var val = value.split(' '),+ ret = [],+ i = 0,+ keys;++ $.each(inst.settings.wheels, function (j, wg) {+ $.each(wg, function (k, w) {+ w = w.values ? w : convert(w);+ keys = w.keys || w.values;+ if ($.inArray(val[i], keys) !== -1) {+ ret.push(val[i]);+ } else {+ ret.push(keys[0]);+ }+ i++;+ });+ });+ return ret;+ }+ };++ $(document).bind('mouseover mouseup mousedown click', function (e) { // Prevent standard behaviour on body click+ if (tap) {+ e.stopPropagation();+ e.preventDefault();+ return false;+ }+ });++ $.fn.mobiscroll = function (method) {+ extend(this, $.mobiscroll.shorts);+ return init(this, method, arguments);+ };++ $.mobiscroll = $.mobiscroll || {+ /**+ * Set settings for all instances.+ * @param {Object} o - New default settings.+ */+ setDefaults: function (o) {+ extend(defaults, o);+ },+ presetShort: function (name) {+ this.shorts[name] = function (method) {+ return init(this, extend(method, { preset: name }), arguments);+ };+ },+ shorts: {},+ presets: {},+ themes: {},+ i18n: {}+ };++ $.scroller = $.scroller || $.mobiscroll;+ $.fn.scroller = $.fn.scroller || $.fn.mobiscroll;++})(jQuery);diff --git a/js/ext/mobiscroll/mobiscroll.datetime.js b/js/ext/mobiscroll/mobiscroll.datetime.jsnew file mode 100644index 000000000..191374f42--- /dev/null+++ b/js/ext/mobiscroll/mobiscroll.datetime.js@@ -0,0 +1,676 @@+/*jslint eqeq: true, plusplus: true, undef: true, sloppy: true, vars: true, forin: true */+(function ($) {++ var ms = $.mobiscroll,+ date = new Date(),+ defaults = {+ dateFormat: 'mm/dd/yy',+ dateOrder: 'mmddy',+ timeWheels: 'hhiiA',+ timeFormat: 'hh:ii A',+ startYear: date.getFullYear() - 100,+ endYear: date.getFullYear() + 1,+ monthNames: ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December'],+ monthNamesShort: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'],+ dayNames: ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'],+ dayNamesShort: ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'],+ shortYearCutoff: '+10',+ monthText: 'Month',+ dayText: 'Day',+ yearText: 'Year',+ hourText: 'Hours',+ minuteText: 'Minutes',+ secText: 'Seconds',+ ampmText: ' ',+ nowText: 'Now',+ showNow: false,+ stepHour: 1,+ stepMinute: 1,+ stepSecond: 1,+ separator: ' '+ },+ preset = function (inst) {+ var that = $(this),+ html5def = {},+ format;+ // Force format for html5 date inputs (experimental)+ if (that.is('input')) {+ switch (that.attr('type')) {+ case 'date':+ format = 'yy-mm-dd';+ break;+ case 'datetime':+ format = 'yy-mm-ddTHH:ii:ssZ';+ break;+ case 'datetime-local':+ format = 'yy-mm-ddTHH:ii:ss';+ break;+ case 'month':+ format = 'yy-mm';+ html5def.dateOrder = 'mmyy';+ break;+ case 'time':+ format = 'HH:ii:ss';+ break;+ }+ // Check for min/max attributes+ var min = that.attr('min'),+ max = that.attr('max');+ if (min) {+ html5def.minDate = ms.parseDate(format, min);+ }+ if (max) {+ html5def.maxDate = ms.parseDate(format, max);+ }+ }++ // Set year-month-day order+ var i,+ k,+ keys,+ values,+ wg,+ start,+ end,+ orig = $.extend({}, inst.settings),+ s = $.extend(inst.settings, defaults, html5def, orig),+ offset = 0,+ wheels = [],+ ord = [],+ o = {},+ f = { y: 'getFullYear', m: 'getMonth', d: 'getDate', h: getHour, i: getMinute, s: getSecond, a: getAmPm },+ p = s.preset,+ dord = s.dateOrder,+ tord = s.timeWheels,+ regen = dord.match(/D/),+ ampm = tord.match(/a/i),+ hampm = tord.match(/h/),+ hformat = p == 'datetime' ? s.dateFormat + s.separator + s.timeFormat : p == 'time' ? s.timeFormat : s.dateFormat,+ defd = new Date(),+ stepH = s.stepHour,+ stepM = s.stepMinute,+ stepS = s.stepSecond,+ mind = s.minDate || new Date(s.startYear, 0, 1),+ maxd = s.maxDate || new Date(s.endYear, 11, 31, 23, 59, 59);++ format = format || hformat;++ if (p.match(/date/i)) {++ // Determine the order of year, month, day wheels+ $.each(['y', 'm', 'd'], function (j, v) {+ i = dord.search(new RegExp(v, 'i'));+ if (i > -1) {+ ord.push({ o: i, v: v });+ }+ });+ ord.sort(function (a, b) { return a.o > b.o ? 1 : -1; });+ $.each(ord, function (i, v) {+ o[v.v] = i;+ });++ wg = [];+ for (k = 0; k < 3; k++) {+ if (k == o.y) {+ offset++;+ values = [];+ keys = [];+ start = mind.getFullYear();+ end = maxd.getFullYear();+ for (i = start; i <= end; i++) {+ keys.push(i);+ values.push(dord.match(/yy/i) ? i : (i + '').substr(2, 2));+ }+ addWheel(wg, keys, values, s.yearText);+ } else if (k == o.m) {+ offset++;+ values = [];+ keys = [];+ for (i = 0; i < 12; i++) {+ var str = dord.replace(/[dy]/gi, '').replace(/mm/, i < 9 ? '0' + (i + 1) : i + 1).replace(/m/, (i + 1));+ keys.push(i);+ values.push(str.match(/MM/) ? str.replace(/MM/, '<span class="dw-mon">' + s.monthNames[i] + '</span>') : str.replace(/M/, '<span class="dw-mon">' + s.monthNamesShort[i] + '</span>'));+ }+ addWheel(wg, keys, values, s.monthText);+ } else if (k == o.d) {+ offset++;+ values = [];+ keys = [];+ for (i = 1; i < 32; i++) {+ keys.push(i);+ values.push(dord.match(/dd/i) && i < 10 ? '0' + i : i);+ }+ addWheel(wg, keys, values, s.dayText);+ }+ }+ wheels.push(wg);+ }++ if (p.match(/time/i)) {++ // Determine the order of hours, minutes, seconds wheels+ ord = [];+ $.each(['h', 'i', 's', 'a'], function (i, v) {+ i = tord.search(new RegExp(v, 'i'));+ if (i > -1) {+ ord.push({ o: i, v: v });+ }+ });+ ord.sort(function (a, b) {+ return a.o > b.o ? 1 : -1;+ });+ $.each(ord, function (i, v) {+ o[v.v] = offset + i;+ });++ wg = [];+ for (k = offset; k < offset + 4; k++) {+ if (k == o.h) {+ offset++;+ values = [];+ keys = [];+ for (i = 0; i < (hampm ? 12 : 24); i += stepH) {+ keys.push(i);+ values.push(hampm && i == 0 ? 12 : tord.match(/hh/i) && i < 10 ? '0' + i : i);+ }+ addWheel(wg, keys, values, s.hourText);+ } else if (k == o.i) {+ offset++;+ values = [];+ keys = [];+ for (i = 0; i < 60; i += stepM) {+ keys.push(i);+ values.push(tord.match(/ii/) && i < 10 ? '0' + i : i);+ }+ addWheel(wg, keys, values, s.minuteText);+ } else if (k == o.s) {+ offset++;+ values = [];+ keys = [];+ for (i = 0; i < 60; i += stepS) {+ keys.push(i);+ values.push(tord.match(/ss/) && i < 10 ? '0' + i : i);+ }+ addWheel(wg, keys, values, s.secText);+ } else if (k == o.a) {+ offset++;+ var upper = tord.match(/A/);+ addWheel(wg, [0, 1], upper ? ['AM', 'PM'] : ['am', 'pm'], s.ampmText);+ }+ }++ wheels.push(wg);+ }++ function get(d, i, def) {+ if (o[i] !== undefined) {+ return +d[o[i]];+ }+ if (def !== undefined) {+ return def;+ }+ return defd[f[i]] ? defd[f[i]]() : f[i](defd);+ }++ function addWheel(wg, k, v, lbl) {+ wg.push({+ values: v,+ keys: k,+ label: lbl+ });+ }++ function step(v, st) {+ return Math.floor(v / st) * st;+ }++ function getHour(d) {+ var hour = d.getHours();+ hour = hampm && hour >= 12 ? hour - 12 : hour;+ return step(hour, stepH);+ }++ function getMinute(d) {+ return step(d.getMinutes(), stepM);+ }++ function getSecond(d) {+ return step(d.getSeconds(), stepS);+ }++ function getAmPm(d) {+ return ampm && d.getHours() > 11 ? 1 : 0;+ }++ function getDate(d) {+ var hour = get(d, 'h', 0);+ return new Date(get(d, 'y'), get(d, 'm'), get(d, 'd', 1), get(d, 'a') ? hour + 12 : hour, get(d, 'i', 0), get(d, 's', 0));+ }++ // Extended methods+ // ---++ /**+ * Sets the selected date+ *+ * @param {Date} d Date to select.+ * @param {Boolean} [fill=false] Also set the value of the associated input element. Default is true.+ * @return {Object} jQuery object to maintain chainability+ */+ inst.setDate = function (d, fill, time, temp) {+ var i;++ // Set wheels+ for (i in o) {+ inst.temp[o[i]] = d[f[i]] ? d[f[i]]() : f[i](d);+ }+ inst.setValue(inst.temp, fill, time, temp);+ };++ /**+ * Returns the currently selected date.+ *+ * @param {Boolean} [temp=false] If true, return the currently shown date on the picker, otherwise the last selected one+ * @return {Date}+ */+ inst.getDate = function (temp) {+ return getDate(temp ? inst.temp : inst.values);+ };++ // ---++ return {+ button3Text: s.showNow ? s.nowText : undefined,+ button3: s.showNow ? function () { inst.setDate(new Date(), false, 0.3, true); } : undefined,+ wheels: wheels,+ headerText: function (v) {+ return ms.formatDate(hformat, getDate(inst.temp), s);+ },+ /**+ * Builds a date object from the wheel selections and formats it to the given date/time format+ * @param {Array} d - An array containing the selected wheel values+ * @return {String} - The formatted date string+ */+ formatResult: function (d) {+ return ms.formatDate(format, getDate(d), s);+ },+ /**+ * Builds a date object from the input value and returns an array to set wheel values+ * @return {Array} - An array containing the wheel values to set+ */+ parseValue: function (val) {+ var d = new Date(),+ i,+ result = [];+ try {+ d = ms.parseDate(format, val, s);+ } catch (e) {+ }+ // Set wheels+ for (i in o) {+ result[o[i]] = d[f[i]] ? d[f[i]]() : f[i](d);+ }+ return result;+ },+ /**+ * Validates the selected date to be in the minDate / maxDate range and sets unselectable values to disabled+ * @param {Object} dw - jQuery object containing the generated html+ * @param {Integer} [i] - Index of the changed wheel, not set for initial validation+ */+ validate: function (dw, i) {+ var temp = inst.temp, //.slice(0),+ mins = { y: mind.getFullYear(), m: 0, d: 1, h: 0, i: 0, s: 0, a: 0 },+ maxs = { y: maxd.getFullYear(), m: 11, d: 31, h: step(hampm ? 11 : 23, stepH), i: step(59, stepM), s: step(59, stepS), a: 1 },+ minprop = true,+ maxprop = true;+ $.each(['y', 'm', 'd', 'a', 'h', 'i', 's'], function (x, i) {+ if (o[i] !== undefined) {+ var min = mins[i],+ max = maxs[i],+ maxdays = 31,+ val = get(temp, i),+ t = $('.dw-ul', dw).eq(o[i]),+ y,+ m;+ if (i == 'd') {+ y = get(temp, 'y');+ m = get(temp, 'm');+ maxdays = 32 - new Date(y, m, 32).getDate();+ max = maxdays;+ if (regen) {+ $('.dw-li', t).each(function () {+ var that = $(this),+ d = that.data('val'),+ w = new Date(y, m, d).getDay(),+ str = dord.replace(/[my]/gi, '').replace(/dd/, d < 10 ? '0' + d : d).replace(/d/, d);+ $('.dw-i', that).html(str.match(/DD/) ? str.replace(/DD/, '<span class="dw-day">' + s.dayNames[w] + '</span>') : str.replace(/D/, '<span class="dw-day">' + s.dayNamesShort[w] + '</span>'));+ });+ }+ }+ if (minprop && mind) {+ min = mind[f[i]] ? mind[f[i]]() : f[i](mind);+ }+ if (maxprop && maxd) {+ max = maxd[f[i]] ? maxd[f[i]]() : f[i](maxd);+ }+ if (i != 'y') {+ var i1 = $('.dw-li', t).index($('.dw-li[data-val="' + min + '"]', t)),+ i2 = $('.dw-li', t).index($('.dw-li[data-val="' + max + '"]', t));+ $('.dw-li', t).removeClass('dw-v').slice(i1, i2 + 1).addClass('dw-v');+ if (i == 'd') { // Hide days not in month+ $('.dw-li', t).removeClass('dw-h').slice(maxdays).addClass('dw-h');+ }+ }+ if (val < min) {+ val = min;+ }+ if (val > max) {+ val = max;+ }+ if (minprop) {+ minprop = val == min;+ }+ if (maxprop) {+ maxprop = val == max;+ }+ // Disable some days+ if (s.invalid && i == 'd') {+ var idx = [];+ // Disable exact dates+ if (s.invalid.dates) {+ $.each(s.invalid.dates, function (i, v) {+ if (v.getFullYear() == y && v.getMonth() == m) {+ idx.push(v.getDate() - 1);+ }+ });+ }+ // Disable days of week+ if (s.invalid.daysOfWeek) {+ var first = new Date(y, m, 1).getDay(),+ j;+ $.each(s.invalid.daysOfWeek, function (i, v) {+ for (j = v - first; j < maxdays; j += 7) {+ if (j >= 0) {+ idx.push(j);+ }+ }+ });+ }+ // Disable days of month+ if (s.invalid.daysOfMonth) {+ $.each(s.invalid.daysOfMonth, function (i, v) {+ v = (v + '').split('/');+ if (v[1]) {+ if (v[0] - 1 == m) {+ idx.push(v[1] - 1);+ }+ } else {+ idx.push(v[0] - 1);+ }+ });+ }+ $.each(idx, function (i, v) {+ $('.dw-li', t).eq(v).removeClass('dw-v');+ });+ }++ // Set modified value+ temp[o[i]] = val;+ }+ });+ }+ };+ };++ $.each(['date', 'time', 'datetime'], function (i, v) {+ ms.presets[v] = preset;+ ms.presetShort(v);+ });++ /**+ * Format a date into a string value with a specified format.+ * @param {String} format - Output format.+ * @param {Date} date - Date to format.+ * @param {Object} settings - Settings.+ * @return {String} - Returns the formatted date string.+ */+ ms.formatDate = function (format, date, settings) {+ if (!date) {+ return null;+ }+ var s = $.extend({}, defaults, settings),+ look = function (m) { // Check whether a format character is doubled+ var n = 0;+ while (i + 1 < format.length && format.charAt(i + 1) == m) {+ n++;+ i++;+ }+ return n;+ },+ f1 = function (m, val, len) { // Format a number, with leading zero if necessary+ var n = '' + val;+ if (look(m)) {+ while (n.length < len) {+ n = '0' + n;+ }+ }+ return n;+ },+ f2 = function (m, val, s, l) { // Format a name, short or long as requested+ return (look(m) ? l[val] : s[val]);+ },+ i,+ output = '',+ literal = false;++ for (i = 0; i < format.length; i++) {+ if (literal) {+ if (format.charAt(i) == "'" && !look("'")) {+ literal = false;+ } else {+ output += format.charAt(i);+ }+ } else {+ switch (format.charAt(i)) {+ case 'd':+ output += f1('d', date.getDate(), 2);+ break;+ case 'D':+ output += f2('D', date.getDay(), s.dayNamesShort, s.dayNames);+ break;+ case 'o':+ output += f1('o', (date.getTime() - new Date(date.getFullYear(), 0, 0).getTime()) / 86400000, 3);+ break;+ case 'm':+ output += f1('m', date.getMonth() + 1, 2);+ break;+ case 'M':+ output += f2('M', date.getMonth(), s.monthNamesShort, s.monthNames);+ break;+ case 'y':+ output += (look('y') ? date.getFullYear() : (date.getYear() % 100 < 10 ? '0' : '') + date.getYear() % 100);+ break;+ case 'h':+ var h = date.getHours();+ output += f1('h', (h > 12 ? (h - 12) : (h == 0 ? 12 : h)), 2);+ break;+ case 'H':+ output += f1('H', date.getHours(), 2);+ break;+ case 'i':+ output += f1('i', date.getMinutes(), 2);+ break;+ case 's':+ output += f1('s', date.getSeconds(), 2);+ break;+ case 'a':+ output += date.getHours() > 11 ? 'pm' : 'am';+ break;+ case 'A':+ output += date.getHours() > 11 ? 'PM' : 'AM';+ break;+ case "'":+ if (look("'")) {+ output += "'";+ } else {+ literal = true;+ }+ break;+ default:+ output += format.charAt(i);+ }+ }+ }+ return output;+ };++ /**+ * Extract a date from a string value with a specified format.+ * @param {String} format - Input format.+ * @param {String} value - String to parse.+ * @param {Object} settings - Settings.+ * @return {Date} - Returns the extracted date.+ */+ ms.parseDate = function (format, value, settings) {+ var def = new Date();++ if (!format || !value) {+ return def;+ }++ value = (typeof value == 'object' ? value.toString() : value + '');++ var s = $.extend({}, defaults, settings),+ shortYearCutoff = s.shortYearCutoff,+ year = def.getFullYear(),+ month = def.getMonth() + 1,+ day = def.getDate(),+ doy = -1,+ hours = def.getHours(),+ minutes = def.getMinutes(),+ seconds = 0, //def.getSeconds(),+ ampm = -1,+ literal = false, // Check whether a format character is doubled+ lookAhead = function (match) {+ var matches = (iFormat + 1 < format.length && format.charAt(iFormat + 1) == match);+ if (matches) {+ iFormat++;+ }+ return matches;+ },+ getNumber = function (match) { // Extract a number from the string value+ lookAhead(match);+ var size = (match == '@' ? 14 : (match == '!' ? 20 : (match == 'y' ? 4 : (match == 'o' ? 3 : 2)))),+ digits = new RegExp('^\\d{1,' + size + '}'),+ num = value.substr(iValue).match(digits);++ if (!num) {+ return 0;+ }+ //throw 'Missing number at position ' + iValue;+ iValue += num[0].length;+ return parseInt(num[0], 10);+ },+ getName = function (match, s, l) { // Extract a name from the string value and convert to an index+ var names = (lookAhead(match) ? l : s),+ i;++ for (i = 0; i < names.length; i++) {+ if (value.substr(iValue, names[i].length).toLowerCase() == names[i].toLowerCase()) {+ iValue += names[i].length;+ return i + 1;+ }+ }+ return 0;+ //throw 'Unknown name at position ' + iValue;+ },+ checkLiteral = function () {+ //if (value.charAt(iValue) != format.charAt(iFormat))+ //throw 'Unexpected literal at position ' + iValue;+ iValue++;+ },+ iValue = 0,+ iFormat;++ for (iFormat = 0; iFormat < format.length; iFormat++) {+ if (literal) {+ if (format.charAt(iFormat) == "'" && !lookAhead("'")) {+ literal = false;+ } else {+ checkLiteral();+ }+ } else {+ switch (format.charAt(iFormat)) {+ case 'd':+ day = getNumber('d');+ break;+ case 'D':+ getName('D', s.dayNamesShort, s.dayNames);+ break;+ case 'o':+ doy = getNumber('o');+ break;+ case 'm':+ month = getNumber('m');+ break;+ case 'M':+ month = getName('M', s.monthNamesShort, s.monthNames);+ break;+ case 'y':+ year = getNumber('y');+ break;+ case 'H':+ hours = getNumber('H');+ break;+ case 'h':+ hours = getNumber('h');+ break;+ case 'i':+ minutes = getNumber('i');+ break;+ case 's':+ seconds = getNumber('s');+ break;+ case 'a':+ ampm = getName('a', ['am', 'pm'], ['am', 'pm']) - 1;+ break;+ case 'A':+ ampm = getName('A', ['am', 'pm'], ['am', 'pm']) - 1;+ break;+ case "'":+ if (lookAhead("'")) {+ checkLiteral();+ } else {+ literal = true;+ }+ break;+ default:+ checkLiteral();+ }+ }+ }+ if (year < 100) {+ year += new Date().getFullYear() - new Date().getFullYear() % 100 ++ (year <= (typeof shortYearCutoff != 'string' ? shortYearCutoff : new Date().getFullYear() % 100 + parseInt(shortYearCutoff, 10)) ? 0 : -100);+ }+ if (doy > -1) {+ month = 1;+ day = doy;+ do {+ var dim = 32 - new Date(year, month - 1, 32).getDate();+ if (day <= dim) {+ break;+ }+ month++;+ day -= dim;+ } while (true);+ }+ hours = (ampm == -1) ? hours : ((ampm && hours < 12) ? (hours + 12) : (!ampm && hours == 12 ? 0 : hours));+ var date = new Date(year, month - 1, day, hours, minutes, seconds);+ if (date.getFullYear() != year || date.getMonth() + 1 != month || date.getDate() != day) {+ throw 'Invalid date';+ }+ return date;+ };++})(jQuery);diff --git a/js/ext/mobiscroll/mobiscroll.ios.js b/js/ext/mobiscroll/mobiscroll.ios.jsnew file mode 100644index 000000000..984e24264--- /dev/null+++ b/js/ext/mobiscroll/mobiscroll.ios.js@@ -0,0 +1,15 @@+(function ($) {++ $.mobiscroll.themes.ios = {+ defaults: {+ dateOrder: 'MMdyy',+ rows: 5,+ height: 30,+ width: 55,+ headerText: false,+ showLabel: false,+ useShortLabels: true+ }+ }++})(jQuery);diff --git a/js/ext/mobiscroll/mobiscroll.jqm.js b/js/ext/mobiscroll/mobiscroll.jqm.jsnew file mode 100644index 000000000..eb6585482--- /dev/null+++ b/js/ext/mobiscroll/mobiscroll.jqm.js@@ -0,0 +1,30 @@+(function ($) {++ $.mobiscroll.themes.jqm = {+ defaults: {+ jqmBorder: 'a',+ jqmBody: 'c',+ jqmHeader: 'b',+ jqmWheel: 'd',+ jqmClickPick: 'c',+ jqmSet: 'b',+ jqmCancel: 'c'+ },+ init: function (elm, inst) {+ var s = inst.settings;+ $('.dw', elm).removeClass('dwbg').addClass('ui-overlay-shadow ui-corner-all ui-body-' + s.jqmBorder);+ $('.dwb-s span', elm).attr('data-role', 'button').attr('data-theme', s.jqmSet);+ $('.dwb-n span', elm).attr('data-role', 'button').attr('data-theme', s.jqmCancel);+ $('.dwb-c span', elm).attr('data-role', 'button').attr('data-theme', s.jqmCancel);+ $('.dwwb', elm).attr('data-role', 'button').attr('data-theme', s.jqmClickPick);+ $('.dwv', elm).addClass('ui-header ui-bar-' + s.jqmHeader);+ $('.dwwr', elm).addClass('ui-body-' + s.jqmBody);+ $('.dwpm .dwwl', elm).addClass('ui-body-' + s.jqmWheel);+ $('.dwpm .dwl', elm).addClass('ui-body-' + s.jqmBody);+ elm.trigger('create');+ // Hide on overlay click+ $('.dwo', elm).click(function () { inst.cancel(); });+ }+ };++})(jQuery);diff --git a/js/ext/mobiscroll/mobiscroll.jqmobi.js b/js/ext/mobiscroll/mobiscroll.jqmobi.jsnew file mode 100644index 000000000..6fb398125--- /dev/null+++ b/js/ext/mobiscroll/mobiscroll.jqmobi.js@@ -0,0 +1,230 @@+/*jslint eqeq: true, plusplus: true, undef: true, sloppy: true, vars: true, forin: true */+if (!window['jQuery']) {++ var jQuery = jq;++ (function ($) {+ var document = window.document,+ classSelectorRE = /^\.([\w-]+)$/,+ idSelectorRE = /^#([\w-]+)$/,+ tagSelectorRE = /^[\w-]+$/,+ tempParent = document.createElement('div'),+ emptyArray = [],+ slice = emptyArray.slice;++ function isNumeric(n) {+ return !isNaN(parseFloat(n)) && isFinite(n);+ }++ function matches(element, selector) {+ if (!element || element.nodeType !== 1) {+ return false;+ }++ var matchesSelector = element.webkitMatchesSelector || element.mozMatchesSelector ||+ element.oMatchesSelector || element.matchesSelector;++ if (matchesSelector) {+ return matchesSelector.call(element, selector)+ }+ // fall back to performing a selector:+ var match, parent = element.parentNode, temp = !parent+ if (temp) (parent = tempParent).appendChild(element)+ match = ~qsa(parent, selector).indexOf(element)+ temp && tempParent.removeChild(element)+ return match+ }++ function qsa(element, selector){+ var found+ return (element === document && idSelectorRE.test(selector)) ?+ ( (found = element.getElementById(RegExp.$1)) ? [found] : emptyArray ) :+ (element.nodeType !== 1 && element.nodeType !== 9) ? emptyArray :+ slice.call(+ classSelectorRE.test(selector) ? element.getElementsByClassName(RegExp.$1) :+ tagSelectorRE.test(selector) ? element.getElementsByTagName(selector) :+ element.querySelectorAll(selector)+ )+ }++ function camelize(str) {+ return str.replace(/-+(.)?/g, function(match, chr){ return chr ? chr.toUpperCase() : '' });+ }++ ['width', 'height'].forEach(function(dimension){+ $.fn[dimension] = function(value){++ var body = document.body,+ html = document.documentElement,+ offset, Dimension = dimension.replace(/./, function(m){return m[0].toUpperCase()})+ if (value === undefined) return this[0] == window ? document.documentElement['client' + Dimension] :+ this[0] == document ? Math.max(body['scroll' + Dimension], body['offset' + Dimension], html['client' + Dimension], html['scroll' + Dimension], html['offset' + Dimension]) : //document.documentElement['offset' + Dimension] :+ (offset = this.offset()) && offset[dimension]+ else return this.each(function(idx){+ var el = $(this)+ el.css(dimension, value)+ })+ }+ });++ ['width', 'height'].forEach(function(dimension) {+ var offset, Dimension = dimension.replace(/./, function(m) {return m[0].toUpperCase()});+ $.fn['outer' + Dimension] = function(margin) {+ var elem = this;+ if (elem) {+ var size = elem[0]['offset' + Dimension];+ var sides = {'width': ['left', 'right'], 'height': ['top', 'bottom']};+ sides[dimension].forEach(function(side) {+ if (margin) size += parseInt(elem.css(camelize('margin-' + side)), 10);+ });+ return size;+ }+ else {+ return null;+ }+ };+ });++ ["Left", "Top"].forEach(function(name, i) {+ var method = "scroll" + name;+ function isWindow( obj ) {+ return obj && typeof obj === "object" && "setInterval" in obj;+ }+ function getWindow( elem ) {+ return isWindow( elem ) ? elem : elem.nodeType === 9 ? elem.defaultView || elem.parentWindow : false;+ }++ $.fn[method] = function( val ) {+ var elem, win;+ if (val === undefined) {+ elem = this[0];+ if (!elem) {+ return null;+ }+ win = getWindow(elem);+ // Return the scroll offset+ return win ? ("pageXOffset" in win) ? win[i ? "pageYOffset" : "pageXOffset"] :+ win.document.documentElement[method] ||+ win.document.body[method] :+ elem[method];+ }++ // Set the scroll offset+ this.each(function() {+ win = getWindow(this);+ if (win) {+ var xCoord = !i ? val : $(win).scrollLeft();+ var yCoord = i ? val : $(win).scrollTop();+ win.scrollTo(xCoord, yCoord);+ }+ else {+ this[method] = val;+ }+ });+ }+ });++ $.fn.is = function (selector) {+ return this.length > 0 && matches(this[0], selector);+ };++ $.fn.prop = function (name, value) {+ return (value === undefined) ? (this[0] ? this[0][name] : undefined) : this.each(function (idx) { this[name] = value; });+ };++ $.fn.focus = function (handler) {+ if (handler === undefined) {+ $(this).trigger('focus');+ } else {+ $(this).bind('focus', handler);+ }+ };++ $.fn.blur = function (handler) {+ if (handler === undefined) {+ $(this).trigger('blur');+ } else {+ $(this).bind('blur', handler);+ }+ };++ $.fn.click = function (handler) {+ if (handler === undefined) {+ $(this).trigger('click');+ } else {+ $(this).bind('click', handler);+ }+ };++ $.fn.eq = function (i) {+ return $($(this).get(i));+ };++ $.fn.index = function (element) {+ return element ? this.indexOf($(element)[0]) : this.length ? this.parent().children().indexOf(this[0]) : -1;+ };++ $.fn.slice = function () {+ return $(slice.apply(this, arguments));+ };++ $.fn.before = function (elm) {+ $(elm).insertBefore(this);+ return this;+ };++ $.fn.appendTo = function (elm) {+ $(elm).append(this);+ return this;+ };++ $.fn.pluck = function (property) {+ return this.map(function () { return this[property]; });+ };++ $.fn.prev = function () {+ var p = this.pluck('previousElementSibling');+ return p[0][0] ? $(p[0]) : $([]);+ };++ $.fn.next = function () {+ var n = this.pluck('nextElementSibling');+ return n[0][0] ? $(n[0]) : $([]);+ };++ $.inArray = function (value, array, fromIndex) {+ var i = fromIndex || 0;+ while (i < array.length) {+ if (array[i++] == value) {+ return --i;+ }+ }+ return -1;+ };++ $.isPlainObject = function (v) {+ return $.isObject(v);+ };++ $.fn._css = $.fn.css;+ $.fn.css = function (attr, val, obj) {+ if ($.isObject(attr)) {+ var i;+ for (i in attr) {+ $(this)._css(i, isNumeric(attr[i]) ? attr[i] + 'px' : attr[i], obj);+ }+ return this;+ } else {+ return $(this)._css(attr, isNumeric(val) ? val + 'px' : val, obj);+ }+ };++ $._extend = $.extend;+ $.extend = function () {+ arguments[0] = arguments[0] || {};+ return $._extend.apply(this, arguments);+ };++ })(jQuery);++}diff --git a/js/ext/mobiscroll/mobiscroll.jqmwidget.js b/js/ext/mobiscroll/mobiscroll.jqmwidget.jsnew file mode 100644index 000000000..95ce9be86--- /dev/null+++ b/js/ext/mobiscroll/mobiscroll.jqmwidget.js@@ -0,0 +1,50 @@+/*+Copyright (c) 2012 Sergio Gabriel Teves+All rights reserved.++This program is free software: you can redistribute it and/or modify+it under the terms of the GNU General Public License as published by+the Free Software Foundation, either version 3 of the License, or+(at your option) any later version.++This program is distributed in the hope that it will be useful,+but WITHOUT ANY WARRANTY; without even the implied warranty of+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the+GNU General Public License for more details.++You should have received a copy of the GNU General Public License+along with this program. If not, see <http://www.gnu.org/licenses/>.+*/++(function($, undefined ) {++ $.widget( "mobile.jqmMobiscroll", $.mobile.widget, {+ options: {+ theme: 'jqm',+ preset: 'date',+ animate: 'pop'+ },+ _create: function() {+ var input = this.element,+ o = $.extend(this.options, input.jqmData('options'));+ input.mobiscroll(o);+ }+ });++ $(document).bind("pagebeforecreate", function(c) {+ // Convert date inputs to normal inputs+ $('input[type="date"]:jqmData(role="mobiscroll")', c.target).prop('type', 'text');+ });++ $(document).bind("pagecreate create", function(c) {+ $(document).trigger("mobiscrollbeforecreate");++ $(':jqmData(role="mobiscroll")', c.target).each(function() {+ if (typeof ($(this).data("mobiscroll")) === "undefined") {+ $(this).jqmMobiscroll();+ }+ })+ });++})( jQuery );+diff --git a/js/ext/mobiscroll/mobiscroll.list.js b/js/ext/mobiscroll/mobiscroll.list.jsnew file mode 100644index 000000000..265f9c324--- /dev/null+++ b/js/ext/mobiscroll/mobiscroll.list.js@@ -0,0 +1,404 @@+/*jslint eqeq: true, plusplus: true, undef: true, sloppy: true, vars: true, forin: true */+(function ($) {+ var ms = $.mobiscroll,+ defaults = {+ invalid: [],+ showInput: true,+ inputClass: ''+ },+ preset = function (inst) {+ var orig = $.extend({}, inst.settings),+ s = $.extend(inst.settings, defaults, orig),+ elm = $(this),+ input,+ prevent,+ id = this.id + '_dummy',+ lvl = 0,+ ilvl = 0,+ timer = {},+ wa = s.wheelArray || createWheelArray(elm),+ labels = generateLabels(lvl),+ currWheelVector = [],+ fwv = firstWheelVector(wa),+ w = generateWheelsFromVector(fwv, lvl);++ /**+ * Disables the invalid items on the wheels+ * @param {Object} dw - the jQuery mobiscroll object+ * @param {Number} nrWheels - the number of the current wheels+ * @param {Array} whArray - The wheel array objects containing the wheel tree+ * @param {Array} whVector - the wheel vector containing the current keys+ */+ function setDisabled(dw, nrWheels, whArray, whVector) {+ var i = 0;+ while (i < nrWheels) {+ var currWh = $('.dwwl' + i, dw),+ inv = getInvalidKeys(whVector, i, whArray);+ $.each(inv, function (i, v) {+ $('.dw-li[data-val="' + v + '"]', currWh).removeClass('dw-v');+ });+ i++;+ }+ }++ /**+ * Returns the invalid keys of one wheel as an array+ * @param {Array} whVector - the wheel vector used to search for the wheel in the wheel array+ * @param {Number} index - index of the wheel in the wheel vector, that we are interested in+ * @param {Array} whArray - the wheel array we are searching in+ * @return {Array} - list of invalid keys+ */+ function getInvalidKeys(whVector, index, whArray) {+ var i = 0,+ n,+ whObjA = whArray,+ invalids = [];++ while (i < index) {+ var ii = whVector[i];+ //whObjA = whObjA[ii].children;+ for (n in whObjA) {+ if (whObjA[n].key == ii) {+ whObjA = whObjA[n].children;+ break;+ }+ }+ i++;+ }+ i = 0;+ while (i < whObjA.length) {+ if (whObjA[i].invalid) {+ invalids.push(whObjA[i].key);+ }+ i++;+ }+ return invalids;+ }++ /**+ * Creates a Boolean vector with true values (except one) that can be used as the readonly vector+ * n - the length of the vector+ * i - the index of the value that's going to be false+ */+ function createROVector(n, i) {+ var a = [];+ while (n) {+ a[--n] = true;+ }+ a[i] = false;+ return a;+ }++ /**+ * Creates a labels vector, from values if they are defined, otherwise from numbers+ * l - the length of the vector+ */+ function generateLabels(l) {+ var a = [],+ i;+ for (i = 0; i < l; i++) {+ a[i] = s.labels && s.labels[i] ? s.labels[i] : i;+ }+ return a;+ }++ /**+ * Creates the wheel array from the vector provided+ * wv - wheel vector containing the values that should be selected on the wheels+ * l - the length of the wheel array+ */+ function generateWheelsFromVector(wv, l, index) {+ var i = 0, j, obj, chInd,+ w = [],+ wtObjA = wa;++ if (l) { // if length is defined we need to generate that many wheels (even if they are empty)+ for (j = 0; j < l; j++) {+ w[j] = [{}];+ //w[j] = {};+ //w[j][labels[j]] = {}; // each wheel will have a label generated by the generateLabels method+ }+ }+ while (i < wv.length) { // we generate the wheels until the length of the wheel vector+ //w[i] = {};+ //w[i][labels[i]] = getWheelFromObjA(wtObjA);+ w[i] = [getWheelFromObjA(wtObjA, labels[i])];++ j = 0;+ chInd = undefined;++ while (j < wtObjA.length && chInd === undefined) {+ if (wtObjA[j].key == wv[i] && ((index !== undefined && i <= index) || index === undefined)) {+ chInd = j;+ }+ j++;+ }++ if (chInd !== undefined && wtObjA[chInd].children) {+ i++;+ wtObjA = wtObjA[chInd].children;+ } else if ((obj = getFirstValidItemObjOrInd(wtObjA)) && obj.children) {+ i++;+ wtObjA = obj.children;+ } else {+ return w;+ }+ }+ return w;+ }++ /**+ * Returns the first valid Wheel Node Object or its index from a Wheel Node Object Array+ * getInd - if it is true then the return value is going to be the index, otherwise the object itself+ */+ function getFirstValidItemObjOrInd(wtObjA, getInd) {+ if (!wtObjA) {+ return false;+ }++ var i = 0,+ obj;++ while (i < wtObjA.length) {+ if (!(obj = wtObjA[i++]).invalid) {+ return getInd ? i - 1 : obj;+ }+ }+ return false;+ }++ function getWheelFromObjA(objA, lbl) {+ var wheel = {+ keys: [],+ values: [],+ label: lbl+ },+ j = 0;++ while (j < objA.length) {+ wheel.values.push(objA[j].value);+ wheel.keys.push(objA[j].key);+ j++;+ //wheel[objA[j].key] = objA[j++].value;+ }+ return wheel;+ }++ /**+ * Hides the last i number of wheels+ * i - the last number of wheels that has to be hidden+ */+ function hideWheels(dw, i) {+ $('.dwc', dw).css('display', '').slice(i).hide();+ }++ /**+ * Generates the first wheel vector from the wheeltree+ * wt - the wheel tree object+ * uses the lvl global variable to determine the length of the vector+ */+ function firstWheelVector(wa) {+ var t = [],+ ndObjA = wa,+ obj,+ ok = true,+ i = 0;++ while (ok) {+ obj = getFirstValidItemObjOrInd(ndObjA);+ t[i++] = obj.key;+ if (ok = obj.children) {+ ndObjA = obj.children;+ }+ }+ return t;+ }++ /**+ * Calculates the level of a wheel vector and the new wheel vector, depending on current wheel vector and the index of the changed wheel+ * wv - current wheel vector+ * index - index of the changed wheel+ */+ function calcLevelOfVector2(wv, index) {+ var t = [],+ ndObjA = wa,+ lvl = 0,+ next = false,+ i,+ childName,+ chInd;++ if (wv[lvl] !== undefined && lvl <= index) {+ i = 0;++ childName = wv[lvl];+ chInd = undefined;++ while (i < ndObjA.length && chInd === undefined) {+ if (ndObjA[i].key == wv[lvl] && !ndObjA[i].invalid) {+ chInd = i;+ }+ i++;+ }+ } else {+ chInd = getFirstValidItemObjOrInd(ndObjA, true);+ childName = ndObjA[chInd].key;+ }++ next = chInd !== undefined ? ndObjA[chInd].children : false;++ t[lvl] = childName;++ while (next) {+ ndObjA = ndObjA[chInd].children;+ lvl++;+ next = false;+ chInd = undefined;++ if (wv[lvl] !== undefined && lvl <= index) {+ i = 0;++ childName = wv[lvl];+ chInd = undefined;++ while (i < ndObjA.length && chInd === undefined) {+ if (ndObjA[i].key == wv[lvl] && !ndObjA[i].invalid) {+ chInd = i;+ }+ i++;+ }+ } else {+ chInd = getFirstValidItemObjOrInd(ndObjA, true);+ chInd = chInd === false ? undefined : chInd;+ childName = ndObjA[chInd].key;+ }+ next = chInd !== undefined && getFirstValidItemObjOrInd(ndObjA[chInd].children) ? ndObjA[chInd].children : false;+ t[lvl] = childName;+ }+ return {+ lvl: lvl + 1,+ nVector: t+ }; // return the calculated level and the wheel vector as an object+ }++ function createWheelArray(ul) {+ var wheelArray = [];++ lvl = lvl > ilvl++ ? lvl : ilvl;++ ul.children('li').each(function (index) {+ var that = $(this),+ c = that.clone();++ c.children('ul,ol').remove();++ var v = c.html().replace(/^\s\s*/, '').replace(/\s\s*$/, ''),+ inv = that.data('invalid') ? true : false,+ wheelObj = {+ key: that.data('val') || index,+ value: v,+ invalid: inv,+ children: null+ },+ nest = that.children('ul,ol');++ if (nest.length) {+ wheelObj.children = createWheelArray(nest);+ }++ wheelArray.push(wheelObj);+ });++ ilvl--;+ return wheelArray;+ }++ $('#' + id).remove(); // Remove input if exists++ if (s.showInput) {+ input = $('<input type="text" id="' + id + '" value="" class="' + s.inputClass + '" readonly />').insertBefore(elm);+ inst.settings.anchor = input; // give the core the input element for the bubble positioning++ if (s.showOnFocus) {+ input.focus(function () {+ inst.show();+ });+ }+ }++ if (!s.wheelArray) {+ elm.hide().closest('.ui-field-contain').trigger('create');+ }++ return {+ width: 50,+ wheels: w,+ headerText: false,+ onBeforeShow: function (dw) {+ var t = inst.temp;+ currWheelVector = t.slice(0);+ inst.settings.wheels = generateWheelsFromVector(t, lvl, lvl);+ prevent = true;+ },+ onSelect: function (v, inst) {+ if (input) {+ input.val(v);+ }+ },+ onChange: function (v, inst) {+ if (input && s.display == 'inline') {+ input.val(v);+ }+ },+ onClose: function () {+ if (input) {+ input.blur();+ }+ },+ onShow: function (dw) {+ $('.dwwl', dw).bind('mousedown touchstart', function () {+ clearTimeout(timer[$('.dwwl', dw).index(this)]);+ });+ },+ validate: function (dw, index, time) {+ var t = inst.temp;+ if ((index !== undefined && currWheelVector[index] != t[index]) || (index === undefined && !prevent)) {+ inst.settings.wheels = generateWheelsFromVector(t, null, index);+ var args = [],+ i = (index || 0) + 1,+ o = calcLevelOfVector2(t, index);+ if (index !== undefined) {+ inst.temp = o.nVector.slice(0);+ }+ while (i < o.lvl) {+ args.push(i++);+ }+ hideWheels(dw, o.lvl);+ currWheelVector = inst.temp.slice(0);+ if (args.length) {+ prevent = true;+ inst.settings.readonly = createROVector(lvl, index);+ clearTimeout(timer[index]);+ timer[index] = setTimeout(function () {+ inst.changeWheel(args);+ inst.settings.readonly = false;+ }, time * 1000);+ return false;+ }+ setDisabled(dw, o.lvl, wa, inst.temp);+ } else {+ var o = calcLevelOfVector2(t, t.length);+ setDisabled(dw, o.lvl, wa, t);+ hideWheels(dw, o.lvl);+ }+ prevent = false;+ }+ };+ };++ $.each(['list', 'image', 'treelist'], function (i, v) {+ ms.presets[v] = preset;+ ms.presetShort(v);+ });++})(jQuery);diff --git a/js/ext/mobiscroll/mobiscroll.select.js b/js/ext/mobiscroll/mobiscroll.select.jsnew file mode 100644index 000000000..14ba28836--- /dev/null+++ b/js/ext/mobiscroll/mobiscroll.select.js@@ -0,0 +1,351 @@+/*jslint eqeq: true, plusplus: true, undef: true, sloppy: true, vars: true, forin: true */+(function ($) {++ var defaults = {+ inputClass: '',+ invalid: [],+ rtl: false,+ group: false,+ groupLabel: 'Groups'+ };++ $.mobiscroll.presetShort('select');++ $.mobiscroll.presets.select = function (inst) {+ var orig = $.extend({}, inst.settings),+ s = $.extend(inst.settings, defaults, orig),+ elm = $(this),+ multiple = elm.prop('multiple'),+ id = this.id + '_dummy',+ option = multiple ? (elm.val() ? elm.val()[0] : $('option', elm).attr('value')) : elm.val(),+ group = elm.find('option[value="' + option + '"]').parent(),+ prev = group.index() + '',+ gr = prev,+ prevent,+ l1 = $('label[for="' + this.id + '"]').attr('for', id),+ l2 = $('label[for="' + id + '"]'),+ label = s.label !== undefined ? s.label : (l2.length ? l2.text() : elm.attr('name')),+ invalid = [],+ origValues = [],+ main = {},+ grIdx,+ optIdx,+ timer,+ input,+ roPre = s.readonly,+ w;++ function genWheels() {+ var cont,+ wg = 0,+ values = [],+ keys = [],+ w = [[]];++ if (s.group) {+ if (s.rtl) {+ wg = 1;+ }++ $('optgroup', elm).each(function (i) {+ values.push($(this).attr('label'));+ keys.push(i);+ });++ w[wg] = [{+ values: values,+ keys: keys,+ label: label+ }];++ cont = group;+ wg += (s.rtl ? -1 : 1);++ } else {+ cont = elm;+ }++ values = [];+ keys = [];++ $('option', cont).each(function () {+ var v = $(this).attr('value');+ values.push($(this).text());+ keys.push(v);+ if ($(this).prop('disabled')) {+ invalid.push(v);+ }+ });++ w[wg] = [{+ values: values,+ keys: keys,+ label: label+ }];++ return w;+ }++ function setVal(v, fill) {+ var value = [];++ if (multiple) {+ var sel = [],+ i = 0;++ for (i in inst._selectedValues) {+ sel.push(main[i]);+ value.push(i);+ }+ input.val(sel.join(', '));+ } else {+ input.val(v);+ value = fill ? inst.values[optIdx] : null;+ }++ if (fill) {+ prevent = true;+ elm.val(value).trigger('change');+ }+ }++ // if groups is true and there are no groups fall back to no grouping+ if (s.group && !$('optgroup', elm).length) {+ s.group = false;+ }++ if (!s.invalid.length) {+ s.invalid = invalid;+ }++ if (s.group) {+ if (s.rtl) {+ grIdx = 1;+ optIdx = 0;+ } else {+ grIdx = 0;+ optIdx = 1;+ }+ } else {+ grIdx = -1;+ optIdx = 0;+ }++ $('#' + id).remove();++ input = $('<input type="text" id="' + id + '" class="' + s.inputClass + '" readonly />').insertBefore(elm),++ $('option', elm).each(function () {+ main[$(this).attr('value')] = $(this).text();+ });++ if (s.showOnFocus) {+ input.focus(function () {+ inst.show();+ });+ }++ var v = elm.val() || [],+ i = 0;++ for (i; i < v.length; i++) {+ inst._selectedValues[v[i]] = v[i];+ }++ setVal(main[option]);++ elm.unbind('.dwsel').bind('change.dwsel', function () {+ if (!prevent) {+ inst.setValue(multiple ? elm.val() || [] : [elm.val()], true);+ }+ prevent = false;+ }).hide().closest('.ui-field-contain').trigger('create');++ // Extended methods+ // ---++ if (!inst._setValue) {+ inst._setValue = inst.setValue;+ }++ inst.setValue = function (d, fill, time, noscroll, temp) {+ var value,+ v = $.isArray(d) ? d[0] : d;++ option = v !== undefined ? v : $('option', elm).attr('value');++ if (multiple) {+ inst._selectedValues = {};+ var i = 0;+ for (i; i < d.length; i++) {+ inst._selectedValues[d[i]] = d[i];+ }+ }++ if (s.group) {+ group = elm.find('option[value="' + option + '"]').parent();+ gr = group.index();+ value = s.rtl ? [option, group.index()] : [group.index(), option];+ if (gr !== prev) { // Need to regenerate wheels, if group changed+ s.wheels = genWheels();+ inst.changeWheel([optIdx]);+ prev = gr + '';+ }+ } else {+ value = [option];+ }++ inst._setValue(value, fill, time, noscroll, temp);++ // Set input/select values+ if (fill) {+ var changed = multiple ? true : option !== elm.val();+ setVal(main[option], changed);+ }+ };++ inst.getValue = function (temp) {+ var val = temp ? inst.temp : inst.values;+ return val[optIdx];+ };++ // ---++ return {+ width: 50,+ wheels: w,+ headerText: false,+ multiple: multiple,+ anchor: input,+ formatResult: function (d) {+ return main[d[optIdx]];+ },+ parseValue: function () {+ var v = elm.val() || [],+ i = 0;++ if (multiple) {+ inst._selectedValues = {};+ for (i; i < v.length; i++) {+ inst._selectedValues[v[i]] = v[i];+ }+ }++ option = multiple ? (elm.val() ? elm.val()[0] : $('option', elm).attr('value')) : elm.val();++ group = elm.find('option[value="' + option + '"]').parent();+ gr = group.index();+ prev = gr + '';+ return s.group && s.rtl ? [option, gr] : s.group ? [gr, option] : [option];+ },+ validate: function (dw, i, time) {+ if (i === undefined && multiple) {+ var v = inst._selectedValues,+ j = 0;++ $('.dwwl' + optIdx + ' .dw-li', dw).removeClass('dw-msel');++ for (j in v) {+ $('.dwwl' + optIdx + ' .dw-li[data-val="' + v[j] + '"]', dw).addClass('dw-msel');+ }+ }++ if (i === grIdx) {+ gr = inst.temp[grIdx];+ if (gr !== prev) {+ group = elm.find('optgroup').eq(gr);+ gr = group.index();+ option = group.find('option').eq(0).val();+ option = option || elm.val();+ s.wheels = genWheels();+ if (s.group) {+ inst.temp = s.rtl ? [option, gr] : [gr, option];+ s.readonly = [s.rtl, !s.rtl];+ clearTimeout(timer);+ timer = setTimeout(function () {+ inst.changeWheel([optIdx]);+ s.readonly = roPre;+ prev = gr + '';+ }, time * 1000);+ return false;+ }+ } else {+ s.readonly = roPre;+ }+ } else {+ option = inst.temp[optIdx];+ }++ var t = $('.dw-ul', dw).eq(optIdx);+ $.each(s.invalid, function (i, v) {+ $('.dw-li[data-val="' + v + '"]', t).removeClass('dw-v');+ });+ },+ onBeforeShow: function (dw) {+ s.wheels = genWheels();+ if (s.group) {+ inst.temp = s.rtl ? [option, group.index()] : [group.index(), option];+ }+ },+ onMarkupReady: function (dw) {+ $('.dwwl' + grIdx, dw).bind('mousedown touchstart', function () {+ clearTimeout(timer);+ });+ if (multiple) {+ dw.addClass('dwms');+ $('.dwwl', dw).eq(optIdx).addClass('dwwms');+ origValues = {};+ var i;+ for (i in inst._selectedValues) {+ origValues[i] = inst._selectedValues[i];+ }+ }+ },+ onValueTap: function (li) {+ if (multiple && li.hasClass('dw-v') && li.closest('.dw').find('.dw-ul').index(li.closest('.dw-ul')) == optIdx) {+ var val = li.attr('data-val');+ if (li.hasClass('dw-msel')) {+ delete inst._selectedValues[val];+ } else {+ inst._selectedValues[val] = val;+ }+ li.toggleClass('dw-msel');++ if (s.display == 'inline') {+ setVal(val, true);+ }+ return false;+ }+ },+ onSelect: function (v) {+ setVal(v, true);+ if (s.group) {+ inst.values = null;+ }+ },+ onCancel: function () {+ if (s.group) {+ inst.values = null;+ }+ if (multiple) {+ inst._selectedValues = {};+ var i;+ for (i in origValues) {+ inst._selectedValues[i] = origValues[i];+ }+ }+ },+ onChange: function (v) {+ if (s.display == 'inline' && !multiple) {+ input.val(v);+ prevent = true;+ elm.val(inst.temp[optIdx]).trigger('change');+ }+ },+ onClose: function () {+ input.blur();+ }+ };+ };++})(jQuery);diff --git a/js/ext/mobiscroll/mobiscroll.wp.js b/js/ext/mobiscroll/mobiscroll.wp.jsnew file mode 100644index 000000000..a6bd5d965--- /dev/null+++ b/js/ext/mobiscroll/mobiscroll.wp.js@@ -0,0 +1,48 @@+(function ($) {++ var anim;++ $.mobiscroll.themes.wp = {+ defaults: {+ width: 70,+ height: 76,+ accent: 'none',+ dateOrder: 'mmMMddDDyy',+ showLabel: false,+ onAnimStart: function (dw, i, time) {+ $('.dwwl' + i, dw).addClass('wpam');+ clearTimeout(anim[i]);+ anim[i] = setTimeout(function () {+ $('.dwwl' + i, dw).removeClass('wpam');+ }, time * 1000 + 100);+ }+ },+ init: function (elm, inst) {+ var click,+ active;++ anim = {};++ $('.dw', elm).addClass('wp-' + inst.settings.accent);++ //$('.dwwl', elm).bind('touchstart mousedown DOMMouseScroll mousewheel', function () {+ $('.dwwl', elm).delegate('.dw-sel', 'touchstart mousedown DOMMouseScroll mousewheel', function () {+ click = true;+ active = $(this).closest('.dwwl').hasClass('wpa');+ $('.dwwl', elm).removeClass('wpa');+ $(this).closest('.dwwl').addClass('wpa');+ }).bind('touchmove mousemove', function () {+ click = false;+ }).bind('touchend mouseup', function () {+ if (click && active) {+ $(this).closest('.dwwl').removeClass('wpa');+ }+ });+ }+ };++ $.mobiscroll.themes['wp light'] = $.mobiscroll.themes.wp;++})(jQuery);++diff --git a/js/ext/mobiscroll/mobiscroll.zepto.js b/js/ext/mobiscroll/mobiscroll.zepto.jsnew file mode 100644index 000000000..b693f6228--- /dev/null+++ b/js/ext/mobiscroll/mobiscroll.zepto.js@@ -0,0 +1,91 @@+/*jslint eqeq: true, plusplus: true, undef: true, sloppy: true, vars: true, forin: true */+if (!window['jQuery']) {++ var jQuery = Zepto;++ (function ($) {++ ['width', 'height'].forEach(function(dimension){+ $.fn[dimension] = function(value){+ var body = document.body,+ html = document.documentElement,+ offset, Dimension = dimension.replace(/./, function(m){return m[0].toUpperCase()})+ if (value === undefined) return this[0] == window ? html['client' + Dimension] :+ this[0] == document ? Math.max(body['scroll' + Dimension], body['offset' + Dimension], html['client' + Dimension], html['scroll' + Dimension], html['offset' + Dimension]) :+ (offset = this.offset()) && offset[dimension]+ else return this.each(function(idx){+ var el = $(this)+ el.css(dimension, value)+ })+ }+ });++ ['width', 'height'].forEach(function (dimension) {+ var offset, Dimension = dimension.replace(/./, function (m) { return m[0].toUpperCase(); });+ $.fn['outer' + Dimension] = function (margin) {+ var elem = this;+ if (elem) {+ var size = elem[0]['offset' + Dimension],+ sides = {'width': ['left', 'right'], 'height': ['top', 'bottom']};+ sides[dimension].forEach(function (side) {+ if (margin) {+ size += parseInt(elem.css('margin-' + side), 10);+ }+ });+ return size;+ } else {+ return null;+ }+ };+ });++ ["Left", "Top"].forEach(function (name, i) {+ var method = "scroll" + name;++ function isWindow(obj) {+ return obj && typeof obj === "object" && "setInterval" in obj;+ }++ function getWindow(elem) {+ return isWindow(elem) ? elem : elem.nodeType === 9 ? elem.defaultView || elem.parentWindow : false;+ }++ $.fn[method] = function (val) {+ var elem, win;+ if (val === undefined) {+ elem = this[0];+ if (!elem) {+ return null;+ }+ win = getWindow(elem);+ // Return the scroll offset+ return win ? ("pageXOffset" in win) ? win[i ? "pageYOffset" : "pageXOffset"] :+ win.document.documentElement[method] ||+ win.document.body[method] :+ elem[method];+ }++ // Set the scroll offset+ this.each(function () {+ win = getWindow(this);+ if (win) {+ var xCoord = !i ? val : $(win).scrollLeft(),+ yCoord = i ? val : $(win).scrollTop();+ win.scrollTo(xCoord, yCoord);+ } else {+ this[method] = val;+ }+ });+ };+ });++ // Fix zepto.js extend to work with undefined parameter+ $._extend = $.extend;+ $.extend = function () {+ arguments[0] = arguments[0] || {};+ return $._extend.apply(this, arguments);+ };++ })(jQuery);++}\ No newline at end of filediff --git a/js/main.js b/js/main.jsindex 05bca31ea..534e1ced5 100644--- a/js/main.js+++ b/js/main.js@@ -3,6 +3,18 @@ $(function() {// Initialize "static" varsvar log = Logging.getLogger();var selector;+ var hideURLbar = function() {+ window.scrollTo(0, 1);+ };++ var checkMobile = function() {+ if (navigator.userAgent.indexOf('iPhone') != -1 || navigator.userAgent.indexOf('Android') != -1) {+ addEventListener("load", function() {+ setTimeout(hideURLbar, 0);+ }, false);+ }+ };+var entryPoint = function() {Worldview.Support.quirks();@@ -24,10 +36,12 @@ $(function() {// Initialize "static" vars$.getJSON("data/config", onConfigLoad).error(Worldview.ajaxError(onConfigLoadError));- }+ };var init = function(config) {+ checkMobile();+Worldview.Map.tileScheduler = Worldview.Scheduler({script: "js/Worldview/Map/TileWorker.js?v=" +Worldview.BUILD_TIMESTAMP,@@ -50,12 +64,13 @@ $(function() {// Initialize "static" varswindow.palettes = Worldview.Widget.Palette("palettes", config, {alignTo: "#products"});var ss = new SOTE.widget.Switch("switch",{dataSourceUrl:"a",selected:"geographic"});var p = new SOTE.widget.Products("productsHolder");+ window.p = p;//var a = new SOTE.widget.Bank("products",{paletteWidget: palettes, dataSourceUrl:"ap_products.php",title:"My Layers",selected:{antarctic:"baselayers,MODIS_Terra_CorrectedReflectance_TrueColor~overlays,antarctic_coastlines", arctic:"baselayers,MODIS_Terra_CorrectedReflectance_TrueColor~overlays,arctic_coastlines",geographic:"baselayers,MODIS_Terra_CorrectedReflectance_TrueColor~overlays,sedac_bound"},categories:["Base Layers","Overlays"],callback:showSelector,selector:selector,config:config});//var s = new SOTE.widget.Selector("selectorbox",{dataSourceUrl:"ap_products.php",categories:["Base Layers","Overlays"]});//var h = new SOTE.widget.MenuPicker("hazard",{dataSourceUrl:"data/mp_hazard.php"});//var tr = new SOTE.widget.MenuPicker("transition",{dataSourceUrl:"data/mp_transition.php"});- var map = new SOTE.widget.DateSpan("time",{hasThumbnail:false});+ var map = new SOTE.widget.DatePicker("time",{hasThumbnail:false});//Image download variablesrb = new SOTE.widget.RubberBand("camera",{icon:"images/camera.png",onicon:"images/cameraon.png",cropee:"map",paletteWidget:palettes,mapWidget:m});var id = new SOTE.widget.ImageDownload("imagedownload",{baseLayer:"MODIS_Terra_CorrectedReflectance_TrueColor",alignTo: rb, m:m});@@ -76,7 +91,7 @@ $(function() {// Initialize "static" varssetTimeout(fixSize, 700);setTimeout(fixSize, 1500);- REGISTRY.addEventListener("map","time","imagedownload");+ //REGISTRY.addEventListener("map","time","imagedownload");REGISTRY.addEventListener("time","map","imagedownload", apcn.containerId, epsg.containerId);REGISTRY.addEventListener("switch","map","products","selectorbox","time", "imagedownload", "camera", apcn.containerId, epsg.containerId);REGISTRY.addEventListener("products","map","time","selectorbox","imagedownload","palettes", apcn.containerId);diff --git a/js/mobileDateSpan.js b/js/mobileDateSpan.jsnew file mode 100644index 000000000..a41742c27--- /dev/null+++ b/js/mobileDateSpan.js@@ -0,0 +1,336 @@+SOTE.namespace("SOTE.widget.MobileMobileDateSpan");+++/**+ * Instantiate the dateSpan+ *+ * @class A date selection object for a configurable period of days, containing thumnails of a sample data+ * product image for each day+ * @constructor+ * @this {dateSpan}+ * @param {String} containerId is the container id of the div in which to render the object+ * @param {Object} [config] is a hash allowing configuration of this component+ * @config {String} [minDate] an ISO8601 formatted date string containing the minimum bound for the dateSpan+ * @config {String} [maxDate] an ISO8601 formatted date string containing the maximum bound for the dateSpan+ * @config {boolean} [hasThumbnail] whether the dateSpan has a thumbnail+ * @config {String} [thumbSource] the address of a script producing thumbnails+ * @config {String} [extent] the extent of the current map (bbox=w,s,e,n)+ * @config {String} [product] the base product for the thumbnails+ * @config {String} [startDate] an ISO8601 formatted date string containing the start date of the dateSpan+ * @config {String} [selectedDate] an ISO8601 formatted date string containing the initially selected date+ * @config {Number} [range] the total number of days displayed to the user+ * @config {String} [anchorId] an HTML Element Id of the object to anchor the dateSpan with+ * @config {boolean} [slideToSelect] whether the selection slider is visible or not+ * @config {boolean} [isExpanded] whether the dateSpan thumbnails should be visible or not+ * @augments SOTE.widget.Component+ *+*/+SOTE.widget.MobileDateSpan = function(containerId, config){+ this.log = Logging.getLogger("Worldview.Widget.MobileDateSpan");++ this.container=document.getElementById(containerId);+ if (this.container==null){+ this.setStatus("Error: element '"+containerId+"' not found!",true);+ return;+ }+ this.id = containerId;+ //Store the container's ID+ this.containerId=containerId;++ //Define an object for holding configuration+ if (config===undefined){+ config={};+ }++ if(config.dataSourceUrl === undefined){+ config.dataSourceUrl = null;+ }++ if(config.endDate === undefined){+ config.endDate = Worldview.today();+ }+ else{+ config.endDate = new Date(config.endDate);+ }++ if(config.startDate === undefined){+ config.startDate = new Date(Date.UTC(2012, 4, 8, 0, 0, 0));+ }+ else{+ config.startDate = new Date(config.startDate);+ }++ if(config.selected === undefined){+ config.selected = this.getToday();+ }++ if(config.isCollapsed === undefined){+ config.isCollapsed = false;//(config.thumbSource === null || config.hasThumbnail === false)? true: false;+ }+++ this.startDate = config.startDate;+ this.endDate = config.endDate;+ this.isCollapsed = config.isCollapsed;+ this.value = config.selected;+ this.dataSourceUrl = config.dataSourceUrl;+ this.statusStr = "";+ this.init();++};++SOTE.widget.MobileDateSpan.prototype = new SOTE.widget.Component;++/**+ * Displays the selectable dateSpan in HTML containing a thumbnail for each day in the span. If the date range contains+ * more days than the visible day span, create horizontal scrolling capability. All callbacks should be set. The+ * component UI should be rendered with controllers to call the events.+ *+ * @this {dateSpan}+ * @requires SOTE.widget.Map+*/+SOTE.widget.MobileDateSpan.prototype.init = function(){++ // inherit styles into the user-specified div+ this.container.setAttribute("class","datespan");+ this.container.innerHTML = '<input name="linkmode" id="linkmode" />';+ var self = this;++ $("#linkmode").mobiscroll().date({display:"bottom",+ onChange: function(valueText){+ var d = new Date(valueText);+ self.setValue(d.toISOStringDate());+ self.fire();+ },+ onShow: function(){+ $("#linkmode").css("display","none");+ },+ onClose: function(){+ $("#linkmode").css("display","block");+ }++ });+ $("#linkmode").mobiscroll('setDate',this.value,true);++ $("#linkmode").bind("onselect",function(){+ alert("fire");+ self.fire();+ });++ if(REGISTRY){+ REGISTRY.register(this.id,this);+ REGISTRY.markComponentReady(this.id);+ }+ else{+ alert("No REGISTRY found! Cannot register MobileDateSpan!");+ }++};++SOTE.widget.MobileDateSpan.prototype.getToday = function() {+ // If at the beginning of the day, wait on the previous day until GIBS+ // catches up.+ var today = Worldview.today();+ var now = Worldview.now();+ if ( now.getUTCHours() < Worldview.GIBS_HOUR_DELAY ) {+ today.setUTCDate(today.getUTCDate() - 1);+ return today;+ } else {+ return today;+ }+};++/**+ * Fires an event to the registry when the state of the component is changed+ *+ * @this {MobileDateSpan}+ *+*/+SOTE.widget.MobileDateSpan.prototype.fire = function(){++ $("#"+this.id).trigger("fire",this.value);++ if(REGISTRY){+ REGISTRY.fire(this);+ }+ else{+ alert("No REGISTRY found! Cannot fire to REGISTRY from AccordionPicker!");+ }++};++/**+ * Sets the selected date in the dateSpan from the passed in date string (ISO8601 format), if valid+ *+ * @this {dateSpan}+ * @param {String} value is the date to be set (i.e. [containerId]=[date])+ * @returns {boolean} true or false depending on if the passed in date validates+ *+*/+SOTE.widget.MobileDateSpan.prototype.setValue = function(value){+ var d;+ try {+ var d = value ? Date.parseISOString(value)+ : this.getToday();+ } catch ( error ) {+ this.log.warn("Invalid time: " + value + ", reason: " + error ++ "; using today");+ d = Worldview.today();+ }+ this.value = d;+ $("#linkmode").mobiscroll('setDate',this.value,true);++};++SOTE.widget.MobileDateSpan.prototype.set = function(value){+ this.value = value;+ $("#linkmode").mobiscroll('setDate',this.value,true);++};++/**+ * Gets the currently selected date in ISO8601 format+ *+ * @this {dateSpan}+ * @returns {String} a string representing the currently selected date in ISO8601 format ([containerId]=[selectedDate])+ *+*/+SOTE.widget.MobileDateSpan.prototype.getValue = function(){+ var datestring = this.value.toISOStringDate();+ return ""+this.id +"="+datestring;+};++SOTE.widget.MobileDateSpan.prototype.get = function(){+ var datestring = this.value.toISOStringDate();+ return datestring;+};++/**+ * Modify the component based on dependencies (i.e. total number of dates in span, start date of span, selected date, thumbnails)+ *+ * @this {dateSpan}+ * @param {String} querystring contains all values of dependencies (from registry)+ * @returns {boolean} true or false depending on if the selected date validates against the updated criteria+ *+*/+SOTE.widget.MobileDateSpan.prototype.updateComponent = function(qs){++};++/**+ * Sets the selected date from the querystring, [containerId]=[selectedDate]+ *+ * @this {dateSpan}+ * @param {String} qs contains the querystring (must contain [containerId]=[selectedDate] in the string)+ * @returns {boolean} true or false depending on if the extracted date validates+ *+*/+SOTE.widget.MobileDateSpan.prototype.loadFromQuery = function(qs){+ return this.setValue(SOTE.util.extractFromQuery(this.id,qs));+};++/**+ * Validates that the selected date is not null and within bounds+ *+ * @this {dateSpan}+ * @returns {boolean} true or false depending on whether the date is not null and within bounds+*/+SOTE.widget.MobileDateSpan.prototype.validate = function(){++};++/**+ * Sets the data accessor that provides state change instructions given dependencies+ *+ * @this {dateSpan}+ * @param {String} datasourceurl is the relative location of the data accessor+ *+*/+SOTE.widget.MobileDateSpan.prototype.setDataSourceUrl = function(datasourceurl){+ // Content+};++/**+ * Gets the data accessor+ *+ * @this {dateSpan}+ * @returns {String} the relative location of the accessor+ *+*/+SOTE.widget.MobileDateSpan.prototype.getDataSourceUrl = function(){+ // Content+};++/**+ * Sets the status of the component+ *+ * @this {dateSpan}+ * @param {String} s the current status of the component (user prompts, error messages)+ *+*/+SOTE.widget.MobileDateSpan.prototype.setStatus = function(s){+ // Content+};++/**+ * Gets the status of the component+ *+ * @this {dateSpan}+ * @returns {String} the current status of the component (user prompts, error messages)+ *+*/+SOTE.widget.MobileDateSpan.prototype.getStatus = function(){+ // Content+};++/**+ * Makes the component UI invisible+ *+ * @this {dateSpan}+ *+*/+SOTE.widget.MobileDateSpan.prototype.hide = function(){+ $("#"+this.id).css("left","-999em");+};++/**+ * Makes the component UI visible+ *+ * @this {dateSpan}+ *+*/+SOTE.widget.MobileDateSpan.prototype.show = function(){+ $("#"+this.id).css("left","0");+};++/**+ * Expand the UI to show thumbnails+ *+ * @this {dateSpan}+ *+*/+SOTE.widget.MobileDateSpan.prototype.expand = function(){+ // Content+};++/**+ * Collapse the UI (no thumbnails)+ *+ * @this {dateSpan}+ *+*/+SOTE.widget.MobileDateSpan.prototype.collapse = function(){+ // Content+};++// Additional Functions+// setBounds, getAvailableDates, setStart, changeBaseProduct, setExtent+++++++++diff --git a/js/products.js b/js/products.jsindex a2922159e..73dd39890 100644--- a/js/products.js+++ b/js/products.js@@ -96,44 +96,63 @@ SOTE.widget.Products.prototype.init = function(){SOTE.widget.Products.prototype.render = function(){this.container.innerHTML = "";- var productContainer = document.createElement("div");- productContainer.setAttribute("id",this.id+"prods");- productContainer.setAttribute("class","products");+ //var productContainer = document.createElement("div");+ //this.container.setAttribute("id",this.id+"prods");+ this.container.setAttribute("class","products");var tabs = document.createElement("ul");+ tabs.setAttribute("id",this.id+"tabs");tabs.innerHTML = "<li class='first'><a href='#products' class='activetab tab'>Active</a></li><li class='second'><a class='addlayerstab tab' href='#selectorbox'>Add Layers +</a></li>";- productContainer.appendChild(tabs);+ this.container.appendChild(tabs);//$('#'+this.id).addClass('products');+ var toggleButtonHolder = document.createElement("div");+ toggleButtonHolder.setAttribute("id",this.id+"toggleButtonHolder");+ toggleButtonHolder.setAttribute("class","toggleButtonHolder");+ var accordionToggler = document.createElement("a");+ accordionToggler.setAttribute("class","accordionToggler atcollapse");+ accordionToggler.setAttribute("title","Hide Products");+ this.isCollapsed = false;+ toggleButtonHolder.appendChild(accordionToggler);+ this.container.appendChild(toggleButtonHolder);+var container = document.createElement("div");container.setAttribute("id","products");- productContainer.appendChild(container);+ this.container.appendChild(container);var selectorbox = document.createElement("div");selectorbox.setAttribute("id","selectorbox");- productContainer.appendChild(selectorbox);+ this.container.appendChild(selectorbox);- this.container.appendChild(productContainer);- $('#'+this.id+"prods").tabs({show: SOTE.widget.Products.change});+ //this.container.appendChild(productContainer);+ $('#'+this.id).tabs({show: SOTE.widget.Products.change});this.b = new SOTE.widget.Bank("products",{paletteWidget: window.palettes, dataSourceUrl:"ap_products.php",title:"My Layers",selected:{antarctic:"baselayers,MODIS_Terra_CorrectedReflectance_TrueColor~overlays,antarctic_coastlines", arctic:"baselayers,MODIS_Terra_CorrectedReflectance_TrueColor~overlays,arctic_coastlines",geographic:"baselayers,MODIS_Terra_CorrectedReflectance_TrueColor~overlays,sedac_bound"},categories:["Base Layers","Overlays"],config:window.config});this.s = new SOTE.widget.Selector("selectorbox",{dataSourceUrl:"ap_products.php",categories:["Base Layers","Overlays"],selected:{antarctic:"baselayers,MODIS_Terra_CorrectedReflectance_TrueColor~overlays,antarctic_coastlines", arctic:"baselayers,MODIS_Terra_CorrectedReflectance_TrueColor~overlays,arctic_coastlines",geographic:"baselayers,MODIS_Terra_CorrectedReflectance_TrueColor~overlays,sedac_bound"}});//$('#'+this.id+"prods").on("tabsshow",SOTE.widget.Products.change);-- var accordionToggler = document.createElement("a");- accordionToggler.setAttribute("class","accordionToggler atcollapse");- accordionToggler.setAttribute("title","Hide Products");- this.isCollapsed = false;- this.container.appendChild(accordionToggler);- $('.accordionToggler').bind('click',{self:this},SOTE.widget.Products.toggle);+ $('.accordionToggler').bind('click',{self:this},SOTE.widget.Products.toggle);+++ //setTimeout(SOTE.forceResize();// Mark the component as ready in the registry if called via init()if ((this.initRenderComplete === false) && REGISTRY) {this.initRenderComplete = true;REGISTRY.markComponentReady(this.id);}-+ var self = this;+ $(window).resize(function(){+ self.b.render();+ self.s.render();+ });+};++SOTE.widget.Products.forceResize = function(self){+ var outerHeight = $("#"+self.id).outerHeight();+ var tabHeight = $("#"+self.id+"tabs").outerHeight();+ self.b.setHeight(outerHeight - tabHeight);+ self.s.setHeight(outerHeight - tabHeight);};SOTE.widget.Products.stopLink = function(e){@@ -147,6 +166,7 @@ SOTE.widget.Products.change = function(e,ui){else {$('.ui-tabs-nav').addClass('firstselected').removeClass('secondselected');}+return false;};@@ -155,14 +175,24 @@ SOTE.widget.Products.toggle = function(e,ui){if(self.isCollapsed){$('.accordionToggler').removeClass('atexpand').addClass('atcollapse');$('.accordionToggler').attr("title","Hide Products");- $('.products').css('display','block');+ $('.accordionToggler').css("float","right");+ $('.products').css("position","relative");+ //$('.products').css("left","0");+ $('.products').animate({left:'0'}, 200);self.isCollapsed = false;+ $('.accordionToggler').appendTo("#"+self.id+"toggleButtonHolder");}else{$('.accordionToggler').removeClass('atcollapse').addClass('atexpand');$('.accordionToggler').attr("title","Show Products");- $('.products').css('display','none');+ $('.accordionToggler').css("float","left");++ //$('.products').css("left","-999em");+ $('.products').animate({left:'-100em'}, 300, function(){+ $('.products').css("position","absolute");+ });self.isCollapsed = true;+ $("#"+self.id).after($('.accordionToggler'));}};diff --git a/js/registry.js b/js/registry.jsindex 54c0d0f7a..4ad5feef8 100644--- a/js/registry.js+++ b/js/registry.js@@ -43,7 +43,7 @@ SOTE.util.Registry = function () {//alert("Registry: storing: producer: "+producerId+", event object name: "+evtObj.name+", consumer: "+arguments[i]);this.storeEvent(producerId,evtObj);- this.consumers.push(new ConsumerProducerPair(arguments[i],producerId));+ this.consumers.push(new ConsumerProducerPair(arguments[i],producerId));}}}@@ -73,7 +73,7 @@ SOTE.util.Registry = function () {// fire an eventthis.fire = function fire(comp,noFireVal){if(noFireVal == null){- noFireVal = "norecurse=xxx";+ noFireVal = "xxx";}if(comp != null){var evtObjA = this.getEvents(this.getComponentId(comp));@@ -92,13 +92,12 @@ SOTE.util.Registry = function () {break;}}- //alert("Registry: fire: producer: "+this.getComponentId(comp)+", evtObj: "+evtObjA[i].consumerId+", recursive: "+recursive+", no fire val: "+noFireVal);- if(evtObjA[i].consumerId != noFireVal.split("=")[1] && evtObjA[i].consumerId != recursive){- /*if(recursive.length > 0){+ if(evtObjA[i].consumerId != noFireVal && evtObjA[i].consumerId != recursive){+ if(recursive.length > 0){evtObjA[i].componentUpdate.fire(comp.getValue()+"&norecurse="+recursive);- }else{*/+ }else{evtObjA[i].componentUpdate.fire(comp.getValue());- //}+ }}}}diff --git a/js/selector.js b/js/selector.jsindex a69072d06..debeca076 100644--- a/js/selector.js+++ b/js/selector.js@@ -107,7 +107,10 @@ SOTE.widget.Selector.prototype.render = function(){//this.container.innerHTML = "";$("#"+this.id).empty();+ var tabs_height = $(".ui-tabs-nav").outerHeight(true);$('#'+this.id).addClass('selector');+ $('#'+this.id).height($('#'+this.id).parent().outerHeight() - tabs_height);+var catList = document.createElement("ul");catList.setAttribute("class","toplevel");@@ -198,6 +201,7 @@ SOTE.widget.Selector.loadCategory = function(e){var form = document.createElement("div");form.setAttribute("class","facetedSearch");+ form.setAttribute("id",self.id+"facetedSearch");var select = document.createElement("select");select.setAttribute("id",self.id+"select");@@ -240,7 +244,7 @@ SOTE.widget.Selector.loadCategory = function(e){categories[formattedCategoryName.toLowerCase()] = document.createElement("ul");categories[formattedCategoryName.toLowerCase()].setAttribute("id",self.id + formattedCategoryName.toLowerCase());- categories[formattedCategoryName.toLowerCase()].setAttribute("class","category");+ categories[formattedCategoryName.toLowerCase()].setAttribute("class",self.id + "category category scroll-pane");}@@ -292,9 +296,13 @@ SOTE.widget.Selector.loadCategory = function(e){}for(var i=0; i<self.categories.length; i++){- var formattedCategoryName = self.categories[i].replace(/\s/g, "").toLowerCase();- content.appendChild(categoryTitles[i]);- content.appendChild(categories[formattedCategoryName]);+ var formattedCategoryName = self.categories[i].replace(/\s/g, "");+ var catContainer = document.createElement("div");+ catContainer.setAttribute("id",self.id+formattedCategoryName);+ catContainer.setAttribute("class","categoryContainer");+ catContainer.appendChild(categoryTitles[i]);+ catContainer.appendChild(categories[formattedCategoryName.toLowerCase()]);+ content.appendChild(catContainer);}self.container.appendChild(form);@@ -318,12 +326,18 @@ SOTE.widget.Selector.loadCategory = function(e){$("#"+self.id+"search").on('keyup',{self:self,select:false},SOTE.widget.Selector.search);$("#"+self.id+"search").focus();- $(".category" ).mCustomScrollbar({horizontalScroll:false, advanced:{- updateOnContentResize: true- }});+ if($(window).width() > 720){+ if(self.jsp){+ var api = self.jsp.data('jsp');+ if(api) {api.destroy()};+ }+ self.jsp = $( ".category" ).jScrollPane({autoReinitialise: true});+ }+ setTimeout(SOTE.widget.Selector.adjustCategoryHeights,1,{self:self});self.adjustSelected();+};SOTE.widget.Selector.selectCat = function(e){@@ -355,7 +369,7 @@ SOTE.widget.Selector.search = function(e){categories[formattedCategoryName.toLowerCase()] = document.createElement("ul");categories[formattedCategoryName.toLowerCase()].setAttribute("id",self.id + formattedCategoryName.toLowerCase());- categories[formattedCategoryName.toLowerCase()].setAttribute("class","category");+ categories[formattedCategoryName.toLowerCase()].setAttribute("class",self.id + "category category scroll-pane");}@@ -403,14 +417,24 @@ SOTE.widget.Selector.search = function(e){}for(var i=0; i<self.categories.length; i++){- var formattedCategoryName = self.categories[i].replace(/\s/g, "").toLowerCase();- content.appendChild(categoryTitles[i]);- content.appendChild(categories[formattedCategoryName]);+ var formattedCategoryName = self.categories[i].replace(/\s/g, "");+ var catContainer = document.createElement("div");+ catContainer.setAttribute("id",self.id+formattedCategoryName);+ catContainer.setAttribute("class","categoryContainer");+ catContainer.appendChild(categoryTitles[i]);+ catContainer.appendChild(categories[formattedCategoryName.toLowerCase()]);+ content.appendChild(catContainer);}- $(".category" ).mCustomScrollbar({horizontalScroll:false, advanced:{- updateOnContentResize: true- }});+ if($(window).width() > 720){+ if(self.jsp){+ var api = self.jsp.data('jsp');+ api.destroy();+ }+ self.jsp = $( ".category" ).jScrollPane({autoReinitialise: true});+ }+ setTimeout(SOTE.widget.Selector.adjustCategoryHeights,1,{self:self});+//content.appendChild(ul);};@@ -432,6 +456,46 @@ SOTE.widget.Selector.prototype.renderCanvases = function(cat){};+SOTE.widget.Selector.adjustCategoryHeights = function(args){+ var self = args.self;+ var heights = new Array;+ var facets_height = $("#"+self.id+"facetedSearch").outerHeight(true);+ var container_height = $("#"+self.id).outerHeight() - facets_height;+ $('#'+self.id+"content").height(container_height);+ var labelHeight = 0;+ $('#'+self.id+'content .head').each(function(){+ labelHeight += $(this).outerHeight(true);+ });+ container_height -= labelHeight;+ //console.log("This.id: " + container_height);+ for(var i=0; i<self.categories.length; i++){+ var formattedCategoryName = self.categories[i].replace(/\s/g, "");+ var actual_height = 0;+ var count = 0;+ $('#' + self.id + formattedCategoryName.toLowerCase() + ' li').each(function(){+ //console.log(document.getElementById(", " + $(this).outerHeight()));+ actual_height += $(this).outerHeight();+ count++;+ });++ heights.push({name:self.id + formattedCategoryName.toLowerCase(),height:actual_height,count:count});+ }++ if(heights[0].height + heights[1].height > container_height){+ if(heights[0].height > container_height/2) {+ heights[0].height = container_height/2;+ }++ heights[1].height = container_height - heights[0].height;++ }++ $("#" + heights[0].name).css("height",heights[0].height+"px");+ $("#" + heights[1].name).css("height",heights[1].height+"px");+++};+SOTE.widget.Selector.prototype.adjustSelected = function(){var inputs = document.getElementsByTagName("input");for(var i=0; i<inputs.length; i++){@@ -454,30 +518,23 @@ SOTE.widget.Selector.prototype.adjustSelected = function(){SOTE.widget.Selector.toggleValue = function(e){var self = e.data.self;var targetEl = e.target;- var category = $("#"+targetEl.id).parent().parent().parent().parent().attr("id");+ var category = $("#"+targetEl.id).parents('.category').attr("id");category = category.replace(self.id,"");var value = $("#"+targetEl.id).attr("value");value = value.replace(/colon/,":");var checked = $("#"+targetEl.id).attr("checked");- if($("#"+targetEl.id).attr("type") == "radio"){- self.values[category] = new Array();- self.values[category].unshift({"value":value});- }- else {- if(!self.values[category]){++ if(!self.values[category]){self.values[category] = new Array();- }- if(checked !== undefined && checked == "checked"){+ }+ if(checked !== undefined && checked == "checked"){self.removeItem(category,value);self.values[category].unshift({"value":value});- }- else{+ }+ else{self.removeItem(category,value);- }-}- //alert(self.serialize(self.values));- //e.stopPropagation();+self.fire();};@@ -496,6 +553,7 @@ SOTE.widget.Selector.prototype.removeItem = function(cat,val){**/SOTE.widget.Selector.prototype.fire = function(){+ setTimeout(SOTE.widget.Selector.adjustCategoryHeights,1,{self:this});if(REGISTRY){REGISTRY.fire(this);@@ -655,6 +713,11 @@ SOTE.widget.Selector.prototype.validate = function(){};+SOTE.widget.Selector.prototype.setHeight = function(height){+ $("#"+this.id).css("height",height+"px");+ SOTE.widget.Selector.adjustCategoryHeights({self:this});+};+/*** Sets the data accessor that provides state change instructions given dependencies*