<table><tr><td style="">ngraham added a comment.
</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/D21027">View Revision</a></tr></table><br /><div><div><p>I don't like hardcoding the things we're comparing against. If we ever add more colors besides "black" or "translucent-light", or of the actual color values of those change (unlikely, but possible), all these buttons will need their code to be adjusted and that'll be easy to forget. I feel like we should be programmatically sampling the background color itself.</p>
<p>Also, if you're ever tempted to duplicate the same logic several times, that's a sure sign it should be in a function. Then each button can just call that function.</p>
<p>Finally porting from PlasmaComponents to QQC2 seems unrelated (or at least the relationship isn't clear from the description). Maybe we should first do that separately.</p></div></div><br /><div><strong>REPOSITORY</strong><div><div>R114 Plasma Addons</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D21027">https://phabricator.kde.org/D21027</a></div></div><br /><div><strong>To: </strong>filipf, Plasma, VDG, ngraham<br /><strong>Cc: </strong>davidedmundson, plasma-devel, jraleigh, GB_2, ragreen, Pitel, ZrenBot, lesliezhai, ali-mohamed, jensreuterberg, abetts, sebas, apol, mart<br /></div>