summaryrefslogtreecommitdiffstats
path: root/js/app/controllers/feedcontroller.coffee
diff options
context:
space:
mode:
authorBernhard Posselt <nukeawhale@gmail.com>2013-05-07 10:43:54 +0200
committerBernhard Posselt <nukeawhale@gmail.com>2013-05-07 10:43:54 +0200
commit030f3e2ccd02a2786bba701d4b82cd2076de8133 (patch)
treed54e61353b72dcb81256d81e4ae50e93831f8363 /js/app/controllers/feedcontroller.coffee
parent1fca21d6d47eb38a0ba2e25e0cf51967c1873573 (diff)
dont highlight tab title when nothing changed, fix #157
Diffstat (limited to 'js/app/controllers/feedcontroller.coffee')
-rw-r--r--js/app/controllers/feedcontroller.coffee11
1 files changed, 8 insertions, 3 deletions
diff --git a/js/app/controllers/feedcontroller.coffee b/js/app/controllers/feedcontroller.coffee
index 41e4fa07d..43488ddba 100644
--- a/js/app/controllers/feedcontroller.coffee
+++ b/js/app/controllers/feedcontroller.coffee
@@ -56,10 +56,15 @@ ActiveFeed, FeedType, $window) ->
# and it has nothing to do with the body structure
if count > 0
titleCount = @_unreadCountFormatter(count)
- @_$window.document.title =
- 'News (' + titleCount + ') | ownCloud'
+ title = 'News (' + titleCount + ') | ownCloud'
else
- @_$window.document.title = 'News | ownCloud'
+ title = 'News | ownCloud'
+
+ # only update title when it changed to prevent highlighting the
+ # tab
+ if @_$window.document.title != title
+ @_$window.document.title = title
+
return count
@_$scope.isAddingFolder = =>