]> source.dussan.org Git - nextcloud-server.git/commitdiff
Replace deprecated $.tipsy(...) by $.tooltip(...)
authorChristoph Wurst <christoph@winzerhof-wurst.at>
Mon, 27 Feb 2017 21:25:05 +0000 (22:25 +0100)
committerChristoph Wurst <christoph@winzerhof-wurst.at>
Mon, 27 Feb 2017 21:25:05 +0000 (22:25 +0100)
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
apps/files/js/breadcrumb.js
apps/files/js/file-upload.js
core/js/share.js
core/js/tests/specs/shareSpec.js

index ff9700456da56610a8dfdc1743182900bdecac20..2a4c2bc8a529891619179821e7b6f6694432c592 100644 (file)
                                                // set the path of this one as title for the ellipsis
                                                this.$el.find('.crumb.ellipsized')
                                                        .attr('title', $crumb.attr('data-dir'))
-                                                       .tipsy();
+                                                       .tooltip();
                                                this.$el.find('.ellipsis')
                                                        .wrap('<a class="ellipsislink" href="' + encodeURI(OC.generateUrl('apps/files/?dir=' + $crumb.attr('data-dir'))) + '"></a>');
                                        }
index 0fbf3f559fedcdb277d1a2bc33447b1dea66b1da..7d7922124ca95a77bfb5908aa6941b36dc08beec 100644 (file)
@@ -895,7 +895,7 @@ OC.Uploader.prototype = _.extend({
                                start: function(e) {
                                        self.log('start', e, null);
                                        //hide the tooltip otherwise it covers the progress bar
-                                       $('#upload').tipsy('hide');
+                                       $('#upload').tooltip('hide');
                                },
                                fail: function(e, data) {
                                        var upload = self.getUpload(data);
@@ -991,7 +991,7 @@ OC.Uploader.prototype = _.extend({
                                                        + '</span><span class="mobile">'
                                                        + t('files', '...')
                                                        + '</span></em>');
-                    $('#uploadprogressbar').tipsy({gravity:'n', fade:true, live:true});
+                                       $('#uploadprogressbar').toopltip({placement: 'bottom'});
                                        self._showProgressBar();
                                        self.trigger('start', e, data);
                                });
index 913c78bb732f53b0476babb99aabd8da3dfff718..5bde7e63f361bbe630e6fae76316c99f0f376b5e 100644 (file)
@@ -302,7 +302,7 @@ OC.Share = _.extend(OC.Share || {}, {
                        }
                        action.html('<span> ' + message + '</span>').prepend(icon);
                        if (owner || recipients) {
-                               action.find('.remoteAddress').tipsy({gravity: 's'});
+                               action.find('.remoteAddress').tooltip({placement: 'top'});
                        }
                }
                else {
index 5c76ea600b8188a800711b48b6f00fcecd624f80..fbf6eecc8df3a0449e9d770685019a7bb16c4500 100644 (file)
 describe('OC.Share tests', function() {
        describe('markFileAsShared', function() {
                var $file;
-               var tipsyStub;
+               var tooltipStub;
 
                beforeEach(function() {
-                       tipsyStub = sinon.stub($.fn, 'tipsy');
+                       tooltipStub = sinon.stub($.fn, 'tooltip');
                        $file = $('<tr><td class="filename"><div class="thumbnail"></div><span class="name">File name</span></td></tr>');
                        $file.find('.filename').append(
                                '<span class="fileactions">' +
@@ -38,7 +38,7 @@ describe('OC.Share tests', function() {
                });
                afterEach(function() {
                        $file = null;
-                       tipsyStub.restore();
+                       tooltipStub.restore();
                });
                describe('displaying the share owner', function() {
                        function checkOwner(input, output, title) {
@@ -54,8 +54,8 @@ describe('OC.Share tests', function() {
                                } else {
                                        expect($action.find('.remoteAddress').attr('title')).not.toBeDefined();
                                }
-                               expect(tipsyStub.calledOnce).toEqual(true);
-                               tipsyStub.reset();
+                               expect(tooltipStub.calledOnce).toEqual(true);
+                               tooltipStub.reset();
                        }
 
                        it('displays the local share owner as is', function() {
@@ -172,8 +172,8 @@ describe('OC.Share tests', function() {
                                } else {
                                                expect($action.find('.remoteAddress').attr('title')).not.toBeDefined();
                                }
-                               expect(tipsyStub.calledOnce).toEqual(true);
-                               tipsyStub.reset();
+                               expect(tooltipStub.calledOnce).toEqual(true);
+                               tooltipStub.reset();
                        }
 
                        it('displays the local share owner as is', function() {