diff options
| author | Andrey Kleshchev <andreykproductengine@lindenlab.com> | 2023-11-07 23:20:40 +0200 |
|---|---|---|
| committer | akleshchev <117672381+akleshchev@users.noreply.github.com> | 2023-11-08 20:21:24 +0200 |
| commit | de844bfce11ea46d428d775d377460db8a2cf54b (patch) | |
| tree | 9fee59e69000e07a4a309a4e0f64bfe3ae54ea1d /indra/newview/llpanelvolume.cpp | |
| parent | e7b71cd8a10898320cf3e0aebc05bfdec3d2ffa3 (diff) | |
SL-20569 Notify user when reflection probe can't be selected
Diffstat (limited to 'indra/newview/llpanelvolume.cpp')
| -rw-r--r-- | indra/newview/llpanelvolume.cpp | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/indra/newview/llpanelvolume.cpp b/indra/newview/llpanelvolume.cpp index d6c36bbfb7..d47383b29a 100644 --- a/indra/newview/llpanelvolume.cpp +++ b/indra/newview/llpanelvolume.cpp @@ -746,6 +746,21 @@ void LLPanelVolume::sendIsLight() LL_INFOS() << "update light sent" << LL_ENDL; } +void notify_cant_select_reflection_probe() +{ + static bool show_notification = true; + if (show_notification) + { + // show only once per session if not ignored + show_notification = false; + if (!gSavedSettings.getBOOL("SelectReflectionProbes")) + { + LLNotificationsUtil::add("CantSelectReflectionProbe"); + } + // else: user used the setting, don't show again this session + } +} + void LLPanelVolume::sendIsReflectionProbe() { LLViewerObject* objectp = mObject; @@ -764,6 +779,7 @@ void LLPanelVolume::sendIsReflectionProbe() } else { + notify_cant_select_reflection_probe(); volobjp->setIsReflectionProbe(value); } } @@ -780,6 +796,7 @@ void LLPanelVolume::doSendIsReflectionProbe(const LLSD & notification, const LLS } LLVOVolume* volobjp = (LLVOVolume*)objectp; + notify_cant_select_reflection_probe(); volobjp->setIsReflectionProbe(true); { // has become a reflection probe, slam to a 10m sphere and pop up a message |
