broulik created this revision. broulik added reviewers: Plasma, hein. Restricted Application added a project: Plasma. Restricted Application added a subscriber: plasma-devel. broulik requested review of this revision.
REVISION SUMMARY Otherwise we would create an instance of this JS file for every delegate. The only contextual object it uses is `i18n`, so pass that in for the function call. TEST PLAN Verified that the JS file is created only once. Speeds up things somewhat. Verified that the favorites action still shows properly and works REPOSITORY R119 Plasma Desktop REVISION DETAIL https://phabricator.kde.org/D10507 AFFECTED FILES applets/kicker/package/contents/code/tools.js applets/kicker/package/contents/ui/DashboardRepresentation.qml applets/kicker/package/contents/ui/ItemGridDelegate.qml applets/kicker/package/contents/ui/ItemListDelegate.qml applets/kicker/package/contents/ui/SideBarItem.qml applets/kickoff/package/contents/code/tools.js applets/kickoff/package/contents/ui/KickoffItem.qml To: broulik, #plasma, hein Cc: plasma-devel, ZrenBot, progwolff, lesliezhai, ali-mohamed, jensreuterberg, abetts, sebas, apol, mart