Changeset 8127 in ntrip for trunk/BNC/qwtpolar/qwt_polar_grid.cpp
- Timestamp:
- May 10, 2017, 3:20:54 PM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/BNC/qwtpolar/qwt_polar_grid.cpp
r4272 r8127 877 877 878 878 scaleDraw->setAngleRange( from, from - 360.0 ); 879 scaleDraw->setTransformation( azimuthMap.transformation()->copy() ); 879 880 const QwtTransform *transform = azimuthMap.transformation(); 881 if ( transform ) 882 scaleDraw->setTransformation( transform->copy() ); 883 else 884 scaleDraw->setTransformation( NULL ); 880 885 } 881 886 else … … 911 916 } 912 917 } 913 scaleDraw->setTransformation( radialMap.transformation()->copy() ); 918 const QwtTransform *transform = radialMap.transformation(); 919 if ( transform ) 920 scaleDraw->setTransformation( transform->copy() ); 921 else 922 scaleDraw->setTransformation( NULL ); 914 923 } 915 924 } … … 976 985 QwtScaleDiv sd = radialGrid.scaleDiv; 977 986 978 QList<double> &ticks = 979 const_cast<QList<double> &>( sd.ticks( QwtScaleDiv::MajorTick ) ); 987 QList<double> ticks = sd.ticks( QwtScaleDiv::MajorTick ); 980 988 981 989 if ( testDisplayFlag( SmartOriginLabel ) ) … … 1011 1019 } 1012 1020 1021 sd.setTicks( QwtScaleDiv::MajorTick, ticks ); 1013 1022 axis.scaleDraw->setScaleDiv( sd ); 1014 1023 … … 1049 1058 const QwtScaleDraw *QwtPolarGrid::scaleDraw( int axisId ) const 1050 1059 { 1051 if ( axisId >= QwtPolar::AxisLeft ||axisId <= QwtPolar::AxisBottom )1060 if ( axisId >= QwtPolar::AxisLeft && axisId <= QwtPolar::AxisBottom ) 1052 1061 return static_cast<QwtScaleDraw *>( d_data->axisData[axisId].scaleDraw ); 1053 1062 … … 1064 1073 QwtScaleDraw *QwtPolarGrid::scaleDraw( int axisId ) 1065 1074 { 1066 if ( axisId >= QwtPolar::AxisLeft ||axisId <= QwtPolar::AxisBottom )1075 if ( axisId >= QwtPolar::AxisLeft && axisId <= QwtPolar::AxisBottom ) 1067 1076 return static_cast<QwtScaleDraw *>( d_data->axisData[axisId].scaleDraw ); 1068 1077
Note:
See TracChangeset
for help on using the changeset viewer.