summaryrefslogtreecommitdiff
path: root/indra/newview/llfloatercolorpicker.cpp
diff options
context:
space:
mode:
authorErik Kundiman <erik@megapahit.org>2026-08-18 13:57:14 +0800
committerErik Kundiman <erik@megapahit.org>2026-08-18 13:57:14 +0800
commit2fa8281b2d8ce8bdbcacf139ec674480da6c9d81 (patch)
treeffb343fee97f21942123fd322d88fea3ef1a4811 /indra/newview/llfloatercolorpicker.cpp
parent742d802f073e81abc6d4cd512e58a4d03b414b83 (diff)
parent214fa765986b4c1e1de1b917581f8508278abd8e (diff)
Merge branch '26.3'
Diffstat (limited to 'indra/newview/llfloatercolorpicker.cpp')
-rw-r--r--indra/newview/llfloatercolorpicker.cpp16
1 files changed, 12 insertions, 4 deletions
diff --git a/indra/newview/llfloatercolorpicker.cpp b/indra/newview/llfloatercolorpicker.cpp
index cd45093856..56e086502a 100644
--- a/indra/newview/llfloatercolorpicker.cpp
+++ b/indra/newview/llfloatercolorpicker.cpp
@@ -233,7 +233,15 @@ bool LLFloaterColorPicker::postBuild()
childSetCommitCallback("sspin", onTextCommit, (void*)this );
childSetCommitCallback("lspin", onTextCommit, (void*)this );
- LLToolPipette::getInstance()->setToolSelectCallback(boost::bind(&LLFloaterColorPicker::onColorSelect, this, _1));
+ mPipetteConnection = LLToolPipette::getInstance()->setToolSelectCallback(
+ [this](LLPointer<LLViewerObject> object, S32 te_index)
+ {
+ const LLTextureEntry* entry = object->getTE(te_index);
+ if (entry)
+ {
+ onColorSelect(entry->getColor());
+ }
+ });
return true;
}
@@ -460,10 +468,10 @@ void LLFloaterColorPicker::onImmediateCheck( LLUICtrl* ctrl, void* data)
}
}
-void LLFloaterColorPicker::onColorSelect( const LLTextureEntry& te )
+// From pipette
+void LLFloaterColorPicker::onColorSelect( const LLColor4 &color )
{
- // Pipete
- selectCurRgb(te.getColor().mV[VRED], te.getColor().mV[VGREEN], te.getColor().mV[VBLUE]);
+ selectCurRgb(color.mV[VRED], color.mV[VGREEN], color.mV[VBLUE]);
}
void LLFloaterColorPicker::onMouseCaptureLost()