Loading template/app/controller/CommentCounts.js +10 −0 Original line number Diff line number Diff line Loading @@ -17,9 +17,17 @@ Ext.define('Docs.controller.CommentCounts', { ref: 'guide', selector: '#guide' }, { ref: 'guideIndex', selector: '#guideindex' }, { ref: 'video', selector: '#video' }, { ref: 'videoIndex', selector: '#videoindex' } ], Loading @@ -30,7 +38,9 @@ Ext.define('Docs.controller.CommentCounts', { updateCounts: function(target, count) { this.getClass().updateCommentCounts(); this.getGuide().updateCommentCounts(); this.getGuideIndex().updateCommentCounts(); this.getVideo().updateCommentCounts(); this.getVideoIndex().updateCommentCounts(); } }); template/app/view/ThumbList.js +12 −0 Original line number Diff line number Diff line Loading @@ -120,6 +120,18 @@ Ext.define('Docs.view.ThumbList', { }, this); }, /** * Refreshes the comment counters. */ updateCommentCounts: function() { if (!this.getEl()) { return; } this.getEl().select(".comment-counter-small").remove(); this.initComments(); }, // Given groups data with subgroups like this: // // - group A Loading template/app/view/guides/Index.js +7 −0 Original line number Diff line number Diff line Loading @@ -35,5 +35,12 @@ Ext.define('Docs.view.guides.Index', { getTab: function() { var enabled = (Docs.data.guides|| []).length > 0; return enabled ? {cls: 'guides', href: '#!/guide', tooltip: 'Guides'} : false; }, /** * Refreshes the comment counters. */ updateCommentCounts: function() { this.down("thumblist").updateCommentCounts(); } }); template/app/view/videos/Index.js +7 −0 Original line number Diff line number Diff line Loading @@ -38,5 +38,12 @@ Ext.define('Docs.view.videos.Index', { getTab: function() { var enabled = (Docs.data.videos || []).length > 0; return enabled ? {cls: 'videos', href: '#!/video', tooltip: 'Videos'} : false; }, /** * Refreshes the comment counters. */ updateCommentCounts: function() { this.down("thumblist").updateCommentCounts(); } }); Loading
template/app/controller/CommentCounts.js +10 −0 Original line number Diff line number Diff line Loading @@ -17,9 +17,17 @@ Ext.define('Docs.controller.CommentCounts', { ref: 'guide', selector: '#guide' }, { ref: 'guideIndex', selector: '#guideindex' }, { ref: 'video', selector: '#video' }, { ref: 'videoIndex', selector: '#videoindex' } ], Loading @@ -30,7 +38,9 @@ Ext.define('Docs.controller.CommentCounts', { updateCounts: function(target, count) { this.getClass().updateCommentCounts(); this.getGuide().updateCommentCounts(); this.getGuideIndex().updateCommentCounts(); this.getVideo().updateCommentCounts(); this.getVideoIndex().updateCommentCounts(); } });
template/app/view/ThumbList.js +12 −0 Original line number Diff line number Diff line Loading @@ -120,6 +120,18 @@ Ext.define('Docs.view.ThumbList', { }, this); }, /** * Refreshes the comment counters. */ updateCommentCounts: function() { if (!this.getEl()) { return; } this.getEl().select(".comment-counter-small").remove(); this.initComments(); }, // Given groups data with subgroups like this: // // - group A Loading
template/app/view/guides/Index.js +7 −0 Original line number Diff line number Diff line Loading @@ -35,5 +35,12 @@ Ext.define('Docs.view.guides.Index', { getTab: function() { var enabled = (Docs.data.guides|| []).length > 0; return enabled ? {cls: 'guides', href: '#!/guide', tooltip: 'Guides'} : false; }, /** * Refreshes the comment counters. */ updateCommentCounts: function() { this.down("thumblist").updateCommentCounts(); } });
template/app/view/videos/Index.js +7 −0 Original line number Diff line number Diff line Loading @@ -38,5 +38,12 @@ Ext.define('Docs.view.videos.Index', { getTab: function() { var enabled = (Docs.data.videos || []).length > 0; return enabled ? {cls: 'videos', href: '#!/video', tooltip: 'Videos'} : false; }, /** * Refreshes the comment counters. */ updateCommentCounts: function() { this.down("thumblist").updateCommentCounts(); } });