loleaflet/spec/tilebench.html             |    6 ++----
 loleaflet/spec/tilebench/TileBenchSpec.js |   23 +++--------------------
 2 files changed, 5 insertions(+), 24 deletions(-)

New commits:
commit 746c3cb747545ec68a54b9a7d5ae7391322cbcea
Author: Mihai Varga <[email protected]>
Date:   Mon Jul 27 10:34:07 2015 +0300

    loleaflet: updated the test to work with the new scrollbar control

diff --git a/loleaflet/spec/tilebench.html b/loleaflet/spec/tilebench.html
index c4eccc4..4cf5f50 100644
--- a/loleaflet/spec/tilebench.html
+++ b/loleaflet/spec/tilebench.html
@@ -36,12 +36,10 @@
        <!-- spec files -->
        <script type="text/javascript" 
src="tilebench/TileBenchSpec.js"></script>
 
+       <div id="toolbar" style="hidden">
+       </div>
        <div id="document-container" style="top:300px">
                <div id="map"></div>
-               <div id="scroll-container">
-                       <div id="mock-document">
-                       </div>
-               </div>
        </div>
 
        <script>
diff --git a/loleaflet/spec/tilebench/TileBenchSpec.js 
b/loleaflet/spec/tilebench/TileBenchSpec.js
index 13b5b64..6cb137a 100644
--- a/loleaflet/spec/tilebench/TileBenchSpec.js
+++ b/loleaflet/spec/tilebench/TileBenchSpec.js
@@ -15,7 +15,7 @@ describe('TileBench', function () {
 
        before(function () {
                // initialize the map and load the document
-               map = L.map('map', 'scroll-container', 'mock-document', {
+               map = L.map('map', {
                        center: [0, 0],
                        zoom: 10,
                        minZoom: 1,
@@ -31,24 +31,7 @@ describe('TileBench', function () {
                        readOnly: false
                });
                map.addLayer(docLayer);
-
-               ////// Scrollbar /////
-               (function($){
-                               $("#scroll-container").mCustomScrollbar({
-                                       axis: 'yx',
-                                       theme: 'dark-thick',
-                                       scrollInertia: 0,
-                                       callbacks:{
-                                               onScroll: function(){
-                                                       
docLayer._onScrollEnd(this);
-                                               },
-                                               whileScrolling: function(){
-                                                       
docLayer._onScroll(this);
-                                               },
-                                               alwaysTriggerOffsets:false
-                                       }
-                               });
-               })(jQuery);
+               map.addControl(L.control.scroll());
        });
 
        afterEach(function () {
@@ -72,7 +55,7 @@ describe('TileBench', function () {
                });
 
                it('Scroll to the bottom', function (done) {
-                       $('#scroll-container').mCustomScrollbar('scrollTo', 
'bottom', {scrollInertia: 3000});
+                       $('.scroll-container').mCustomScrollbar('scrollTo', 
'bottom', {scrollInertia: 3000});
                        // check how we're doing 200ms after the scroll has 
ended
                        // (allow enough time to request new tiles)
                        this.timeOut = setTimeout(L.bind(function () {
_______________________________________________
Libreoffice-commits mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to