src/widgets/Polemic.js
branchnew-model
changeset 925 28efc97b5d78
parent 924 64c2eaafe5e2
child 930 165f236e42f2
equal deleted inserted replaced
924:64c2eaafe5e2 925:28efc97b5d78
    44 };
    44 };
    45 
    45 
    46 IriSP.Widgets.Polemic.prototype.onSearch = function(searchString) {
    46 IriSP.Widgets.Polemic.prototype.onSearch = function(searchString) {
    47     this.searchString = typeof searchString !== "undefined" ? searchString : '';
    47     this.searchString = typeof searchString !== "undefined" ? searchString : '';
    48     var _found = 0,
    48     var _found = 0,
    49         _re = IriSP.Model.regexpFromTextOrArray(searchString),
    49         _re = IriSP.Model.regexpFromTextOrArray(searchString, true),
    50         _this = this;
    50         _this = this;
    51     this.$tweets.each(function() {
    51     this.$tweets.each(function() {
    52         var _el = IriSP.jQuery(this);
    52         var _el = IriSP.jQuery(this);
    53         if (_this.searchString) {
    53         if (_this.searchString) {
    54             if (_re.test(_el.attr("tweet-title"))) {
    54             if (_re.test(_el.attr("tweet-title"))) {