void LLFloaterColorPicker::onColorSelect( const LLTextureEntry& te, void *data ) { LLFloaterColorPicker* self = (LLFloaterColorPicker*)data; if (self) { self->setCurRgb(te.getColor().mV[VRED], te.getColor().mV[VGREEN], te.getColor().mV[VBLUE]); if (self->mApplyImmediateCheck->get()) { LLColorSwatchCtrl::onColorChanged ( self->getSwatch (), LLColorSwatchCtrl::COLOR_CHANGE ); } } }
void LLFloaterColorPicker::onImmediateCheck( LLUICtrl* ctrl, void* data) { LLFloaterColorPicker* self = ( LLFloaterColorPicker* )data; if (self) { gSavedSettings.setBOOL("ApplyColorImmediately", self->mApplyImmediateCheck->get()); if (self->mApplyImmediateCheck->get()) { LLColorSwatchCtrl::onColorChanged ( self->getSwatch (), LLColorSwatchCtrl::COLOR_CHANGE ); } } }
////////////////////////////////////////////////////////////////////////////// // called when 'select' clicked void LLFloaterColorPicker::onClickSelect ( void* data ) { if (data) { LLFloaterColorPicker* self = ( LLFloaterColorPicker* )data; if ( self ) { // apply to selection LLColorSwatchCtrl::onColorChanged ( self->getSwatch (), LLColorSwatchCtrl::COLOR_SELECT ); self->closeFloater(); } } }