Merge pull request #1038 from lorenzhs/fix-nicklist-font

Fix nicklist not being affected by favorite font setting
This commit is contained in:
Lorenz Hübschle-Schneider 2018-11-08 09:57:08 +01:00 committed by GitHub
commit 934e85377e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 7 additions and 0 deletions

View File

@ -791,6 +791,13 @@ weechat.controller('WeechatCtrl', ['$rootScope', '$scope', '$store', '$timeout',
return true;
}
$scope.showNicklist = true;
// hack: retrigger the favorite-font update mechanism when showing the
// nicklist because the div is ng-if=showNicklist instead of ng-show for
// performance reasons (especially on mobile)
$timeout(function() {
utils.changeClassStyle('favorite-font', 'fontFamily', settings.fontfamily);
utils.changeClassStyle('favorite-font', 'fontSize', settings.fontsize);
}, 0);
return true;
};