web/res/metadataplayer/Polemic.js
changeset 654 a5977736d2b0
parent 638 e0d4e8431de3
child 668 eb7e39c732c6
--- a/web/res/metadataplayer/Polemic.js	Tue Jul 03 18:19:39 2012 +0200
+++ b/web/res/metadataplayer/Polemic.js	Fri Jul 06 18:22:13 2012 +0200
@@ -40,18 +40,13 @@
             "keywords" : [ "?" ],
             "color" : "#036AAE"
         }
-    ],
-    requires : [
-        {
-            type: "Tooltip"
-        }
     ]
 };
 
 IriSP.Widgets.Polemic.prototype.onSearch = function(searchString) {
     this.searchString = typeof searchString !== "undefined" ? searchString : '';
     var _found = 0,
-        _re = IriSP.Model.regexpFromTextOrArray(searchString),
+        _re = IriSP.Model.regexpFromTextOrArray(searchString, true),
         _this = this;
     this.$tweets.each(function() {
         var _el = IriSP.jQuery(this);
@@ -287,6 +282,10 @@
         var _x = _e.pageX - _this.$zone.offset().left;
         _this.player.popcorn.currentTime(_this.source.getDuration().getSeconds() * _x / _this.width);
     });
+    
+    this.$.append('<div class="Ldt-Polemic-Tooltip"></div>');
+    
+    this.insertSubwidget(this.$.find(".Ldt-Polemic-Tooltip"), "tooltip", { type: "Tooltip" });
 }
 
 IriSP.Widgets.Polemic.prototype.onTimeupdate = function() {