| 384 | } |
| 385 | |
| 386 | void ColourPanel::notifyScrollChangePositionAlpha(MyGUI::ScrollBar* _sender, size_t _position) |
| 387 | { |
| 388 | mCurrentColour.alpha = static_cast<float>(mAlphaSlider->getScrollPosition()) / |
| 389 | static_cast<float>(mAlphaSlider->getScrollRange() - 1); |
| 390 | |
| 391 | if (mCurrentColour.alpha > 1) |
| 392 | mCurrentColour.alpha = 1; |
| 393 | else if (mCurrentColour.alpha < 0) |
| 394 | mCurrentColour.alpha = 0; |
| 395 | |
| 396 | mInputAlpha->setCaption(MyGUI::utility::toString(mCurrentColour.alpha)); |
| 397 | mColourView->setAlpha(mCurrentColour.alpha); |
| 398 | |
| 399 | eventPreviewColour(mCurrentColour); |
| 400 | } |
| 401 | |
| 402 | void ColourPanel::setAlphaSupport(bool _value) |
| 403 | { |
nothing calls this directly
no test coverage detected