Skip to content

Conversation

@Rider-Linden
Copy link
Contributor

@Rider-Linden Rider-Linden commented Dec 2, 2025

Issue #4628

Handle new privileged land permission. Allow caution dialog to contain multiple messages, (Debt and Land)

This is the viewer side for https://github.com/secondlife/server/pull/2249.
Supports the new permission and correctly handles multiple possible warning conditions.

@github-actions github-actions bot added the c/cpp label Dec 2, 2025
@Rider-Linden Rider-Linden marked this pull request as ready for review December 5, 2025 17:49
@Rider-Linden Rider-Linden requested a review from Geenz December 5, 2025 17:49
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds support for a new "privileged land access" script permission that allows objects to sell land on behalf of users. The change coordinates with a server-side update to handle this new permission type with appropriate caution dialogs.

  • Adds PrivilegedLandAccess as a new cautioned permission (19th permission)
  • Refactors caution dialog to support multiple warning messages instead of hardcoded single message
  • Updates UI layout to dynamically adjust based on visible content

Reviewed changes

Copilot reviewed 7 out of 8 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
indra/newview/llscriptruntimeperms.h Adds new PrivilegedLandAccess permission bit and updates array type from boost to std
indra/newview/llviewermessage.cpp Refactors caution handling to build dynamic warning messages for multiple caution permissions
indra/newview/lltoastscriptquestion.cpp Improves layout calculation to handle optional footer visibility and dynamic content sizing
indra/newview/skins/default/xui/en/strings.xml Adds localized strings for the new land permission caution and description
indra/newview/skins/default/xui/en/notifications.xml Updates notification template to accept dynamic warning content
indra/newview/skins/default/xui/en/panel_script_question_toast.xml Adjusts panel height and footer behavior for dynamic sizing
indra/newview/llviewerwindow.cpp Removes unused boost/lambda header

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

// Caustions go into top part of the dialog, questions go into the footer
if (caution_enabled && script_perm.caution)
{
warning_msg += "\n" + LLTrans::getString(script_perm.question + "Caution") + "\n";
Copy link

Copilot AI Dec 15, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The warning message construction adds leading and trailing newlines for each caution, which may result in excessive whitespace. Consider building the message without trailing newlines and adding them only between items, or trim the final result.

Copilot uses AI. Check for mistakes.
Rider-Linden and others added 3 commits December 15, 2025 13:48
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants