Uploaded image for project: 'Qt Automotive Suite'
  1. Qt Automotive Suite
  2. AUTOSUITE-674

Get rid of Button.customBackgroundColor

    XMLWordPrintable

Details

    • Task
    • Resolution: Done
    • Not Evaluated
    • None
    • None
    • Neptune3
    • None

    Description

      There are several problems with this property:

      1. It's not used anywhere, except for dev/apps/com.pelagicore.sheets/components/ButtonPanel.qml
      2. Such a case should be handled by changing the appropriate property in the NeptuneStyle attached property for the button in question instead of creating a new property wich overlaps existing API (NeptuneStyle). That's one of the use cases intended to be solved by having a style being an attached property instead of a singleton. Let's use it!
      3. It's a bad name. It you think about it, every property is "custom" the moment you set a value different from the default one. So in that sense we should prefix every property with "custom"
      4. There's "magic" going on there. Setting a customBackgroundColor not only changes the background color but also the opacity of the background. So this property is exceeding is contract and having undisclosed side effects. If you need to change the opacity behavior, it should be done explicitly.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            dandrader Daniel d'Andrada
            dandrader Daniel d'Andrada
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes