Adding functionality to buttons

Hello All,

I’m working on Stable version 3.0 with RoundButton in the FlightDisplayViewWidgets.qml file (in later version the change it…).

I’ve added a button that has 3 states :
“A” - onClick calls C++ that can change the state(using Q_PROPERTY) to “B” or to stay on “A”.
“B” - onClick can move the state to “C”, or if something happen change it back to “A”.
“C” - final state, no going back to any state.

The functionality of this is working but i’m having a problem with the background yellow color that show when a RoundButton is pressed.

I’ve tried playing with the checked property in the States didn’t do much, i also created a new exclusiveGroup but i’m not quite understand what it really does.

relvent code from github:

  1. FlightWidgets https://github.com/mavlink/qgroundcontrol/blob/Stable_V3.0/src/FlightDisplay/FlightDisplayViewWidgets.qml
    2.RoundButton https://github.com/mavlink/qgroundcontrol/blob/Stable_V3.0/src/QmlControls/RoundButton.qml

It’s a small problem but i MUST solve it :slight_smile: