qt/scicon: Avoid warnings about unused MakeSingleColorImage#6328
qt/scicon: Avoid warnings about unused MakeSingleColorImage#6328luke-jr wants to merge 1 commit intobitcoin:masterfrom
Conversation
|
+9 / -3 yours Well I like mine better, as I removed an #ifdef ;). |
|
ACK |
|
We had this discussion before, shortly ago: #6143 For the sake of making sure as much code gets compiled for every platform, logic that does not use specific platform-dependent APIs (and thus potentially compiles on other platforms) should not be in platform-specific #ifdefs. E.g. use MACOSX/WINDOWS to determine a UIPlatformStyle enum once, then pass that on. This could be overridden for testing. This would also apply to things such as "display images on buttons" which are currently #ifdefed. (Or instead of an enum: this could work like |
|
Closing in favor of #6487, which implements the approach outlined in my above post. |
Introduce a PlatformStyle to handle platform-specific customization of the UI. This replaces 'scicon', as well as #ifdefs to determine whether to place icons on buttons. The selected PlatformStyle defaults to the platform that the application was compiled on, but can be overridden from the command line with `-uiplatform=<x>`. Also fixes the warning from bitcoin#6328.
A cleaner alternative to #6327