<table><tr><td style="">kmaterka added inline comments.
</td><a style="text-decoration: none; padding: 4px 8px; margin: 0 8px 8px; float: right; color: #464C5C; font-weight: bold; border-radius: 3px; background-color: #F7F7F9; background-image: linear-gradient(to bottom,#fff,#f1f0f1); display: inline-block; border: 1px solid rgba(71,87,120,.2);" href="https://phabricator.kde.org/D28208">View Revision</a></tr></table><br /><div><strong>INLINE COMMENTS</strong><div><div style="margin: 6px 0 12px 0;"><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D28208#inline-160307">View Inline</a><span style="color: #4b4d51; font-weight: bold;">StatusNotifierItem.qml:58</span></div>
<div style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; white-space: pre-wrap; clear: both; padding: 4px 0; margin: 0;"><div style="padding: 0 8px; margin: 0 4px; "> <span class="p">}</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span style="color: #74777d">// IconItem.overlays only supports names so we need a second item for the overlay, using the same</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span style="color: #74777d">// positioning that KIconLoader::drawOverlays uses that IconItem uses internally</span>
</div></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">Should overlay pixmaps be supported in <tt style="background: #ebebeb; font-size: 13px;">PlasmaCore.IconItem</tt>? I guess that would require changes in <tt style="background: #ebebeb; font-size: 13px;">KIconLoader</tt> as well.</p></div></div><br /><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D28208#inline-160306">View Inline</a><span style="color: #4b4d51; font-weight: bold;">StatusNotifierItem.qml:72</span></div>
<div style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; white-space: pre-wrap; clear: both; padding: 4px 0; margin: 0;"><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span style="color: #aa4000">width:</span> <span class="p">{</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span style="color: #aa4000">if</span> <span class="p">(</span><span style="color: #004012">iconItem</span><span class="p">.</span><span style="color: #004012">width</span> <span style="color: #aa2211"><</span> <span style="color: #601200">32</span><span class="p">)</span> <span class="p">{</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span style="color: #aa4000">return</span> <span style="color: #601200">8</span><span class="p">;</span>
</div></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">In <a href="https://phabricator.kde.org/source/plasma-workspace/browse/master/dataengines/statusnotifieritem/statusnotifieritemsource.cpp$428" class="remarkup-link" target="_blank" rel="noreferrer">StatusNotifierItemSource::overlayIcon()</a> it is "width <= 32". There is a pre-existing inconsistency between StatusNotifierItemSource and IconItem/KIconLoader.</p></div></div><br /><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D28208#inline-160298">View Inline</a><span style="color: #4b4d51; font-weight: bold;">davidre</span> wrote in <span style="color: #4b4d51; font-weight: bold;">StatusNotifierItem.qml:84</span></div>
<div style="margin: 8px 0; padding: 0 12px; color: #74777D;"><p style="padding: 0; margin: 8px;">Good to know! That was a straight copy from <a href="https://cgit.kde.org/kiconthemes.git/tree/src/kiconloader.cpp#n478" class="remarkup-link" target="_blank" rel="noreferrer">https://cgit.kde.org/kiconthemes.git/tree/src/kiconloader.cpp#n478</a> :D<br />
I'm sure we can find better sizing though, I think this is to small, for sure.</p></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;"><a href="https://phabricator.kde.org/source/plasma-workspace/browse/master/dataengines/statusnotifieritem/statusnotifieritemsource.cpp$428" class="remarkup-link" target="_blank" rel="noreferrer">StatusNotifierItemSource::overlayIcon()</a> also has some sizes hard coded. I quickly checked, looks like the values are the same.<br />
You can use the same syntax here:</p>
<div class="remarkup-code-block" style="margin: 12px 0;" data-code-lang="text" data-sigil="remarkup-code-block"><pre class="remarkup-code" style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; padding: 12px; margin: 0; background: rgba(71, 87, 120, 0.08);">if (iconItem.width <= units.iconSize.medium) {
return units.iconSize.small / 2;
}
if (iconItem.width <= units.iconSize.large) {
return units.iconSize.small;
}</pre></div></div></div><br /><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D28208#inline-160297">View Inline</a><span style="color: #4b4d51; font-weight: bold;">ngraham</span> wrote in <span style="color: #4b4d51; font-weight: bold;">StatusNotifierItem.qml:90</span></div>
<div style="margin: 8px 0; padding: 0 12px; color: #74777D;"><p style="padding: 0; margin: 8px;">always round when multiplying by a non-integer value</p></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">In <a href="https://phabricator.kde.org/source/plasma-workspace/browse/master/dataengines/statusnotifieritem/statusnotifieritemsource.cpp$428" class="remarkup-link" target="_blank" rel="noreferrer">StatusNotifierItemSource::overlayIcon()</a> it has a different logic to position overlay. Margin is always the size of overlay icon. Another pre-existing inconsistency. Which one to choose? I think that <tt style="background: #ebebeb; font-size: 13px;">KIconLoader</tt> is more important.</p></div></div><br /><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D28208#inline-160299">View Inline</a><span style="color: #4b4d51; font-weight: bold;">systemtraymodel.h:97</span></div>
<div style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; white-space: pre-wrap; clear: both; padding: 4px 0; margin: 0;"><div style="padding: 0 8px; margin: 0 4px; "> <span class="n">IconThemePath</span><span class="p">,</span>
</div><div style="padding: 0 8px; margin: 0 4px; "> <span class="n">IconsChanged</span><span class="p">,</span>
</div><div style="padding: 0 8px; margin: 0 4px; "> <span class="n">Id</span><span class="p">,</span>
</div></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">You can safely remove all *Changed as well. Or maybe better in a separate commit?</p></div></div><br /><div style="border: 1px solid #C7CCD9; border-radius: 3px;"><div style="padding: 0; background: #F7F7F7; border-color: #e3e4e8; border-style: solid; border-width: 0 0 1px 0; margin: 0;"><div style="color: #74777d; background: #eff2f4; padding: 6px 8px; overflow: hidden;"><a style="float: right; text-decoration: none;" href="https://phabricator.kde.org/D28208#inline-160300">View Inline</a><span style="color: #4b4d51; font-weight: bold;">statusnotifieritemsource.cpp:90</span></div>
<div style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; white-space: pre-wrap; clear: both; padding: 4px 0; margin: 0;"><div style="padding: 0 8px; margin: 0 4px; "> <span style="color: #74777d">//by setting everything up-front so that we have all role names when we call the first checkForUpdate()</span>
</div><div style="padding: 0 8px; margin: 0 4px; background: rgba(151, 234, 151, .6);"> <span style="color: #74777d">// TODO Plasma 6 remove combined "*Icon" properties and only expose the raw "*IconName" and "*IconPixmap" properties</span>
</div><div style="padding: 0 8px; margin: 0 4px; "> <span class="n">setData</span><span class="p">(</span><span class="n">QStringLiteral</span><span class="p">(</span><span style="color: #766510">"AttentionIcon"</span><span class="p">),</span> <span class="n">QIcon</span><span class="p">());</span>
</div></div></div>
<div style="margin: 8px 0; padding: 0 12px;"><p style="padding: 0; margin: 8px;">I would suggest to extend removal to all *Changed roles. These are not used (were in KDE/Plasma 4).</p></div></div></div></div></div><br /><div><strong>REPOSITORY</strong><div><div>R120 Plasma Workspace</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D28208">https://phabricator.kde.org/D28208</a></div></div><br /><div><strong>To: </strong>davidre, kmaterka, broulik, mart, Plasma, VDG<br /><strong>Cc: </strong>ngraham, plasma-devel, Orage, LeGast00n, The-Feren-OS-Dev, cblack, jraleigh, zachus, fbampaloukas, GB_2, ragreen, ZrenBot, himcesjf, lesliezhai, ali-mohamed, jensreuterberg, abetts, sebas, apol, ahiemstra, mart<br /></div>