summaryrefslogtreecommitdiff
path: root/indra/newview
AgeCommit message (Collapse)Author
2024-07-10Simplify passing keys to leap.requestMnikolenko Productengine
2024-07-09Merge branch 'release/luau-scripting' into lua-snapshotNat Goodspeed
2024-07-09Merge branch 'release/luau-scripting' into lua-snapshotNat Goodspeed
2024-07-09Introduce LLSDParam<vector<T>> and LLSDParam<map<string, T>>.Nat Goodspeed
Use LLSDParam<uuid_vec_t> in LLAppearanceListener::wearItems() and detachItems() to build the vector of LLUUIDs from the passed LLSD array.
2024-07-08The I/O manipulator std::quoted() must be passed to an ostream.Nat Goodspeed
2024-07-08Slightly simplify LLAppearanceListener::wearItems(), detachItems().Nat Goodspeed
2024-07-08Combine LLAppearanceMgr::wearOutfit() and wearOutfitByName()Nat Goodspeed
into new private wearOutfit(LLInventoryCategory*) method.
2024-07-08Quote "LLAppearance" op="wearOutfit" folder_id and folder_name argsNat Goodspeed
2024-07-08Lua api for Snapshot and demo scriptMnikolenko Productengine
2024-07-05clean up and rename demo scriptMnikolenko Productengine
2024-07-03Use llsd::toMap() to return LLSD maps from "LLAppearance" listener.Nat Goodspeed
2024-07-02Merge branch 'release/luau-scripting' into lua-appearance-listenerNat Goodspeed
2024-07-02Merge branch 'release/luau-scripting' into lua-appearance-listenerNat Goodspeed
2024-07-02Eliminate c_str() calls from LLControlGroup::loadFromFile() calls.Nat Goodspeed
Passing std::string::c_str() to a (const std::string&) function parameter is worse than clutter, it's pointless overhead: it forces the compiler to construct a new std::string instance, instead of passing a const reference to the one you already have in hand.
2024-07-02Make require() implementation honor LuaRequirePath setting.Nat Goodspeed
Remove LL_TEST special case from require() code (to search in the viewer's source tree). Instead, make llluamanager_test.cpp append to LuaRequirePath to get the same effect.
2024-07-02Promote LuaRemover from llluamanager.cpp to lua_function.h.Nat Goodspeed
2024-07-01build fixMaxim Nikolenko
2024-07-01Move error strings to strings.xml; pass wearable type and is_worn flag for ↵Mnikolenko Productengine
outfit items
2024-06-28Add LuaAutorunPath, LuaCommandPath and LuaRequirePath settings.Nat Goodspeed
Remove AutorunLuaScriptFile and the LLLUAmanager::runScriptOnLogin() method that checked it. Instead, iterate over LuaAutorunPath directories at viewer startup, iterate over *.lua files in each and implicitly run those. LuaCommandPath and LuaRequirePath are not yet implemented.
2024-06-27Introduce TypeTag<T> template whose int value differs for each T.Nat Goodspeed
This replaces type_tag<T>(), which searched and possibly extended the type_tags unordered_map at runtime. If we called lua_emplace<T>() from different threads, that would require locking type_tags. In contrast, the compiler must instantiate a distinct TypeTag<T> for every distinct T passed to lua_emplace<T>(), so each gets a distinct value at static initialization time. No locking is required; no lookup; no allocations. Add a test to llluamanager_test.cpp to verify that each distinct T passed to lua_emplace<T>() gets its own TypeTag<T>::value, and that each gets its own destructor -- but that different lua_emplace<T>() calls with the same T share the same TypeTag<T>::value and the same destructor.
2024-06-25Add wear/detach actions to Appearance listener; update example scriptMnikolenko Productengine
2024-06-24Merge branch 'release/luau-scripting' into lua-appearance-listenerMnikolenko Productengine
2024-06-21Exercise the simple popup.lua APIsNat Goodspeed
2024-06-21Remove pre-Floater.lua versions of the floater test scripts.Nat Goodspeed
2024-06-21login.lua works now, update test_login.lua accordingly.Nat Goodspeed
2024-06-21Introduce require/logout.lua and test_logout.lua.Nat Goodspeed
Add "userQuit" operation to LLAppViewerListener to engage LLAppViewer::userQuit(), which pops up "Are you sure?" prompt unless suppressed.
2024-06-21Multiple LL.atexit(function) calls run functions in reverse order.Nat Goodspeed
2024-06-21Add Appearance listenerMnikolenko Productengine
2024-06-21Use util.classctor(LLChatListener).Nat Goodspeed
2024-06-21Move newer Lua modules to scripts/lua/require subdirectory.Nat Goodspeed
2024-06-21Merge branch 'release/luau-scripting' into lua-loginNat Goodspeed
2024-06-20Merge branch 'release/luau-scripting' into lua-chat-listenerNat Goodspeed
2024-06-20Use new popup.lua, which supersedes LLNotification.lua.Nat Goodspeed
Use ClassName(ctor args) for classes using util.classctor().
2024-06-20Merge branch 'release/luau-scripting' into lua-loginNat Goodspeed
2024-06-20Revert LLLuaFloater "idle" events in favor of Lua timers.Timer().nat-goodspeed
2024-06-20Merge branch 'release/luau-scripting' into lua-speedometer-demoNat Goodspeed
2024-06-20Give popup() the ability to not wait; add popup:tip(message).Nat Goodspeed
popup:tip() engages 'SystemMessageTip'.
2024-06-20Use LLLeapListener to listen to LLNearbyChat pumpMnikolenko Productengine
2024-06-19Move popup.lua to require subdir with the rest of the modules.Nat Goodspeed
2024-06-18Improve diagnostic output from running 'require' module.Nat Goodspeed
2024-06-18Remove special-case ~LuaState() code to call fiber.run().Nat Goodspeed
Instead, make fiber.lua call LL.atexit(fiber.run) to schedule that final run() call at ~LuaState() time using the generic mechanism. Append an explicit fiber.run() call to a specific test in llluamanager_test.cpp because the test code wants to interact with multiple Lua fibers *before* we destroy the LuaState.
2024-06-17Remove useless 'coro_name' infoMnikolenko Productengine
2024-06-17Store script's LuaListener in userdata in lua_State's Registry.Nat Goodspeed
Instead of deriving LuaListener from LLInstanceTracker with an int key, generating a unique int key and storing that key in the Registry, use new lua_emplace<LuaState>() to store the LuaListener directly in a Lua userdata object in the Lua Registry. Because lua_emplace<T>() uses LL.atexit() to guarantee that ~LuaState will destroy the T object, we no longer need ~LuaState() to make a special call specifically to destroy the LuaListener, if any. So we no longer need LuaState::getListener() separate from obtainListener(). Since LuaListener is no longer an LLInstanceTracker subclass, make LuaState::obtainListener() return LuaListener& rather than LuaListener::ptr_t.
2024-06-14Move Lua modules for 'require' to indra/newview/scripts/lua/require.Nat Goodspeed
Make viewer_manifest.py copy them into the viewer install image. Make the require() function look for them there.
2024-06-14Add nearby chat listenerMnikolenko Productengine
2024-06-12Avoid messing up Lua's global namespace in 'require' modules.Nat Goodspeed
2024-06-12Provide LUA Debug Console feedback for user typing LUA string.Nat Goodspeed
When the user explicitly types 'return expression[, expression]...' we convert the result of the expressions to LLSD and format them into the LUA Debug Console, which serves as a useful acknowledgment. But until now, if the user neither invoked print() nor ran a 'return' statement, the LUA Debug Console output remained empty. This could be a little disconcerting: you click Execute, or press Enter, and apparently nothing happens. You must either monitor viewer log output, or simply trust that the Lua snippet ran. When there are no 'return' results, at least emit 'ok'. But when the user is entering a series of no-output commands, vary the 'ok' output by appending a counter: 'ok 1', 'ok 2' etc.
2024-06-12Defend LLFloaterLUADebug against recursive calls to handlers.Nat Goodspeed
The special case of a Lua snippet that indirectly invokes the "LLNotifications" listener can result in a recursive call to LLFloaterLUADebug's handler methods. Defend against that case.
2024-06-12For a single string concatenation, use operator+().Nat Goodspeed
stringize() constructs, populates and destroys a std::ostringstream, which is actually less efficient than directly allocating a std::string big enough for the result of operator+(). Maybe someday we'll specialize stringize(p0, p1) for the case in which they're both string-like, and invoke operator+() for that situation...
2024-06-12Make popup() directly pass payload.Nat Goodspeed
The expression (payload or {}) is unnecessary, since that value will be converted to LLSD -- and both Lua nil and empty table convert to LLSD::isUndefined().