! \internal This slot is connected to the selectableChanged signals of the four axes in the constructor. It synchronizes the selectability of the axes. */
| 19926 | synchronizes the selectability of the axes. |
| 19927 | */ |
| 19928 | void QCPColorScaleAxisRectPrivate::axisSelectableChanged(QCPAxis::SelectableParts selectableParts) |
| 19929 | { |
| 19930 | // synchronize axis base selectability: |
| 19931 | QList<QCPAxis::AxisType> allAxisTypes = QList<QCPAxis::AxisType>() << QCPAxis::atBottom << QCPAxis::atTop << QCPAxis::atLeft << QCPAxis::atRight; |
| 19932 | foreach (QCPAxis::AxisType type, allAxisTypes) |
| 19933 | { |
| 19934 | if (QCPAxis *senderAxis = qobject_cast<QCPAxis*>(sender())) |
| 19935 | if (senderAxis->axisType() == type) |
| 19936 | continue; |
| 19937 | |
| 19938 | if (axis(type)->selectableParts().testFlag(QCPAxis::spAxis)) |
| 19939 | { |
| 19940 | if (selectableParts.testFlag(QCPAxis::spAxis)) |
| 19941 | axis(type)->setSelectableParts(axis(type)->selectableParts() | QCPAxis::spAxis); |
| 19942 | else |
| 19943 | axis(type)->setSelectableParts(axis(type)->selectableParts() & ~QCPAxis::spAxis); |
| 19944 | } |
| 19945 | } |
| 19946 | } |
| 19947 | /* end of 'src/layoutelements/layoutelement-colorscale.cpp' */ |
| 19948 | |
| 19949 |
nothing calls this directly
no outgoing calls
no test coverage detected