| 930 | } |
| 931 | |
| 932 | void ImageViewerWindow::on_mouseClick() |
| 933 | { |
| 934 | if(_colorPickHandler) |
| 935 | _colorPickHandler->pickColor(IPLColor(_currentColor.redF(), _currentColor.greenF(), _currentColor.blueF())); |
| 936 | |
| 937 | if(_coordinatePickHandler) |
| 938 | _coordinatePickHandler->pickCoordinates(_currentPosition.x(), _currentPosition.y()); |
| 939 | |
| 940 | // update the scroll bars when they are moved by a drag |
| 941 | IPImageViewer* viewer = dynamic_cast<IPImageViewer*>( ui->tabWidget->currentWidget() ); |
| 942 | if (viewer && viewer->image()){ |
| 943 | int horiz = viewer->horizontalScrollBar()->value(); |
| 944 | int vert = viewer->verticalScrollBar()->value(); |
| 945 | if ( horiz != _horizontalScrollValue ) |
| 946 | on_horizontalScrollBarChanged( horiz ); |
| 947 | if ( vert != _verticalScrollValue ) |
| 948 | on_verticalScrollBarChanged( vert ); |
| 949 | } |
| 950 | } |
| 951 | |
| 952 | //----------------------------------------------------------------------------- |
| 953 | /*! |
nothing calls this directly
no test coverage detected