Hardware Reference
In-Depth Information
This helps us to create a dedicated event, as shown in the following screenshot:
We are now free to add anything we want in the ButtonClick event handler.
Therefore, this is the place to compute a button's position according to the *button
pointer that is given as a call parameter.
However, this is not enough. The graphical buttons matrix has been separated from
its logical representation. This is the role of the following command:
QStringList Leds_Matrix ;
This aims to define a list of matrices. In addition, the idea is to use the functions
provided with this container class—reverting, searching, removing, finding the first,
last, and so on—so that you can create your own graphical algorithms in an easier way.
Some transformations within switch are done because even though we know which
button has been clicked, we still ignore its position in the matrix. After this small
calculation, it's easy to affect the buttons due to the color-changing cycle. By the way,
we also update the logical matrix data.
 
Search WWH ::




Custom Search