summaryrefslogtreecommitdiff
path: root/indra/newview/scripts/lua/test_login.lua
AgeCommit message (Collapse)Author
2024-08-05Fix a couple problems with "LLPanelLogin" listener (thanks Maxim!).Nat Goodspeed
Convert plain grid (e.g. "agni") to domain form (e.g. "util.agni.lindenlab.com"). Fix a typo in `savedLogins()`: "login_list", not "login.list". login.lua now returns a table with two functions: `login.login()` and `login.savedLogins()`. Defend Lua caller against trying to engage login features too late in startup sequence: in addition to waiting for "STATE_LOGIN_WAIT", produce an error if `startup.state()` is beyond that state. Since by then `LLPanelLogin` is destroyed, `leap.request("LLPanelLogin", ...)` would get no response, causing the calling Lua script to hang until viewer shutdown.
2024-08-02Add 'LLPanelLogin' 'login', 'savedLogins' operations.Nat Goodspeed
'login' accepts optional 'username', 'slurl', 'grid'. 'savedLogins' returns the list of saved usernames in both display form and internal form. Make LLPanelLogin::getUserName() accept (const LLPointer<LLCredential>&). There's a whole separate discussion pending as to whether const LLPointer<T> should provide access to non-const T methods. Similarly, make LLCredential::getIdentifier() a const method. These two changes enable read-only access to credentials. Make LLPanelLogin methods capture and reuse LLGridManager::instance() as appropriate. Add require/login.lua and test_login.lua.
2024-06-21login.lua works now, update test_login.lua accordingly.Nat Goodspeed
2024-06-11Add login.lua module with login() function.Nat Goodspeed
The nullary login() call (login with saved credentials) has been tested, but the binary login(username, password) call is known not to work yet.