summaryrefslogtreecommitdiff
path: root/indra/newview/lltoast.cpp
AgeCommit message (Collapse)Author
2024-07-08Re-enable compiler warnings C4244 and C4396 except for lltracerecording.h ↵Ansariel
and llunittype.h for now
2024-05-22Fix line endlingsAnsariel
2024-05-22Merge remote-tracking branch 'origin/main' into DRTVWR-600-maint-AAnsariel
# Conflicts: # autobuild.xml # indra/cmake/CMakeLists.txt # indra/cmake/GoogleMock.cmake # indra/llaudio/llaudioengine_fmodstudio.cpp # indra/llaudio/llaudioengine_fmodstudio.h # indra/llaudio/lllistener_fmodstudio.cpp # indra/llaudio/lllistener_fmodstudio.h # indra/llaudio/llstreamingaudio_fmodstudio.cpp # indra/llaudio/llstreamingaudio_fmodstudio.h # indra/llcharacter/llmultigesture.cpp # indra/llcharacter/llmultigesture.h # indra/llimage/llimage.cpp # indra/llimage/llimagepng.cpp # indra/llimage/llimageworker.cpp # indra/llimage/tests/llimageworker_test.cpp # indra/llmessage/tests/llmockhttpclient.h # indra/llprimitive/llgltfmaterial.h # indra/llrender/llfontfreetype.cpp # indra/llui/llcombobox.cpp # indra/llui/llfolderview.cpp # indra/llui/llfolderviewmodel.h # indra/llui/lllineeditor.cpp # indra/llui/lllineeditor.h # indra/llui/lltextbase.cpp # indra/llui/lltextbase.h # indra/llui/lltexteditor.cpp # indra/llui/lltextvalidate.cpp # indra/llui/lltextvalidate.h # indra/llui/lluictrl.h # indra/llui/llview.cpp # indra/llwindow/llwindowmacosx.cpp # indra/newview/app_settings/settings.xml # indra/newview/llappearancemgr.cpp # indra/newview/llappearancemgr.h # indra/newview/llavatarpropertiesprocessor.cpp # indra/newview/llavatarpropertiesprocessor.h # indra/newview/llbreadcrumbview.cpp # indra/newview/llbreadcrumbview.h # indra/newview/llbreastmotion.cpp # indra/newview/llbreastmotion.h # indra/newview/llconversationmodel.h # indra/newview/lldensityctrl.cpp # indra/newview/lldensityctrl.h # indra/newview/llface.inl # indra/newview/llfloatereditsky.cpp # indra/newview/llfloatereditwater.cpp # indra/newview/llfloateremojipicker.h # indra/newview/llfloaterimsessiontab.cpp # indra/newview/llfloaterprofiletexture.cpp # indra/newview/llfloaterprofiletexture.h # indra/newview/llgesturemgr.cpp # indra/newview/llgesturemgr.h # indra/newview/llimpanel.cpp # indra/newview/llimpanel.h # indra/newview/llinventorybridge.cpp # indra/newview/llinventorybridge.h # indra/newview/llinventoryclipboard.cpp # indra/newview/llinventoryclipboard.h # indra/newview/llinventoryfunctions.cpp # indra/newview/llinventoryfunctions.h # indra/newview/llinventorygallery.cpp # indra/newview/lllistbrowser.cpp # indra/newview/lllistbrowser.h # indra/newview/llpanelobjectinventory.cpp # indra/newview/llpanelprofile.cpp # indra/newview/llpanelprofile.h # indra/newview/llpreviewgesture.cpp # indra/newview/llsavedsettingsglue.cpp # indra/newview/llsavedsettingsglue.h # indra/newview/lltooldraganddrop.cpp # indra/newview/llurllineeditorctrl.cpp # indra/newview/llvectorperfoptions.cpp # indra/newview/llvectorperfoptions.h # indra/newview/llviewerparceloverlay.cpp # indra/newview/llviewertexlayer.cpp # indra/newview/llviewertexturelist.cpp # indra/newview/macmain.h # indra/test/test.cpp
2024-05-13Revert "viewer#819 Avoid reading the same XML file multiple times"Andrey Kleshchev
This reverts commit a865d423974ea06dffa47798c81e98e7570b02ec. Reason for revert: viewer#1420, reverting to not hold maint-A (is deepCopy not full?)
2024-04-29#824 Process source files in bulk: replace tabs with spaces, convert CRLF to ↵Andrey Lihatskiy
LF, and trim trailing whitespaces as needed
2024-03-05viewer#819 Avoid reading the same XML file multiple timesAlexander Gavriliuk
2024-02-21Convert remaining BOOL to boolAnsariel
2024-02-21Convert BOOL to bool in lluiAnsariel
2024-02-18Replace BOOL with bool in llwindow and dependent classesAnsariel
2024-02-12more misc: BOOL (int) to real boolLars Næsbye Christensen
2023-01-21SL-18989 Saved notifications some times stops displaying informationAndrey Kleshchev
2020-03-25DRTVWR-494: Defend LLInstanceTracker against multi-thread usage.Nat Goodspeed
The previous implementation went to some effort to crash if anyone attempted to create or destroy an LLInstanceTracker subclass instance during traversal. That restriction is manageable within a single thread, but becomes unworkable if it's possible that a given subclass might be used on more than one thread. Remove LLInstanceTracker::instance_iter, beginInstances(), endInstances(), also key_iter, beginKeys() and endKeys(). Instead, introduce key_snapshot() and instance_snapshot(), the only means of iterating over LLInstanceTracker instances. (These are intended to resemble functions, but in fact the current implementation simply presents the classes.) Iterating over a captured snapshot defends against container modifications during traversal. The term 'snapshot' reminds the coder that a new instance created during traversal will not be considered. To defend against instance deletion during traversal, a snapshot stores std::weak_ptrs which it lazily dereferences, skipping on the fly any that have expired. Dereferencing instance_snapshot::iterator gets you a reference rather than a pointer. Because some use cases want to delete all existing instances, add an instance_snapshot::deleteAll() method that extracts the pointer. Those cases used to require explicitly copying instance pointers into a separate container; instance_snapshot() now takes care of that. It remains the caller's responsibility to ensure that all instances of that LLInstanceTracker subclass were allocated on the heap. Replace unkeyed static LLInstanceTracker::getInstance(T*) -- which returned nullptr if that instance had been destroyed -- with new getWeak() method returning std::weak_ptr<T>. Caller must detect expiration of that weak_ptr. Adjust tests accordingly. Use of std::weak_ptr to detect expired instances requires engaging std::shared_ptr in the constructor. We now store shared_ptrs in the static containers (std::map for keyed, std::set for unkeyed). Make LLInstanceTrackerBase a template parameterized on the type of the static data it manages. For that reason, hoist static data class declarations out of the class definitions to an LLInstanceTrackerStuff namespace. Remove the static atomic sIterationNestDepth and its methods incrementDepth(), decrementDepth() and getDepth(), since they were used only to forbid creation and destruction during traversal. Add a std::mutex to static data. Introduce an internal LockStatic class that locks the mutex while providing a pointer to static data, making that the only way to access the static data. The LLINSTANCETRACKER_DTOR_NOEXCEPT macro goes away because we no longer expect ~LLInstanceTracker() to throw an exception in test programs. That affects LLTrace::StatBase as well as LLInstanceTracker itself. Adapt consumers to the new LLInstanceTracker API.
2019-08-10DRTVWR-493 LLUI to LLParamSingletonandreykproductengine
2018-05-22MAINT-8635 Don't allow using 'close all windows' if modal toast is openmaxim_productengine
2016-07-08MAINT-6448 PERMISSION_DEBIT notification should default to Denyandreykproductengine
2016-05-06merge 4.0.4-release and MAINT-5974Oz Linden
2016-01-21MAINT-2579 FIXED Permission request dialog cannot get focusMnikolenko ProductEngine
2015-11-10remove execute permission from many files that should not have itOz Linden
2014-06-25MAINT-4185 FIXED Close toasts silently.Mnikolenko ProductEngine
2013-11-11Automated merge with http://bitbucket.org/lindenlab/viewer-releaseRichard Linden
2013-10-08merge from viewer-releaseRichard Linden
2013-09-11MAINT-2894 FIXED Handle mouse events for popup menus in modal dialogs.Mnikolenko ProductEngine
2013-05-09Merge downstream code and viewer-betasimon
2013-04-24Remove an un-needed LL_CHECK_MEMORY checksimon
2013-04-24Follow-up code cleaning for LLToast work trying to get branch healthy.simon
Reviewed by Kelly
2013-04-24diff -r 59c7bed66dfd indra/llcommon/lleventapi.hsimon
2013-03-29Update Mac and Windows breakpad builds to latestGraham Madarasz
2013-02-28Modify LLInstanceTracker to avoid using a map of strings to find a map of ↵Graham Madarasz (Graham)
foo to find some pointers
2012-10-10Introduce new LLDir::findSkinnedFilenames() method. Use as needed.Nat Goodspeed
In a number of different places, for different reasons, the viewer wants to load a UI-related file that might be overridden by a non-default skin; and within that skin, might further be overridden by a non-default language. Apparently, for each of those use cases, every individual developer approached it as an entirely new problem, solving it idiosyncratically for that one case. Not only is this a maintenance problem, but it rubs one's nose in the fact that most such solutions consider only a subset of the relevant skin directories. Richard and I evolved an API intended to address all such cases: a central LLDir method returning a list of relevant pathnames, from most general to most localized, filtered to present only existing files; plus a couple of convenience methods to specifically obtain the most general and most localized available file. There were several load-skinned-file methods (LLFloater::buildFromFile(), LLPanel::buildFromFile() and LLUICtrlFactory::createFromFile() -- apparently cloned-and-modified from each other) that contained funky bolted-on logic to output the loaded data to an optional passed LLXMLNodePtr param. The trouble is that passing that param forced each of these methods to subvert its normal search: specifically for that case, it needed to find the baseline XML file instead of the localized one. Richard agreed that for the intended usage (reformatting XML files) we should use XML schema instead, and that the hacky functionality should be removed. Remove it. Also remove LLUICtrlFactory::getLocalizedXMLNode(), only used for those three special cases. Some callers explicitly passed the optional LLXMLNodePtr param as NULL. Remove that. Remove LLFloaterUIPreview::displayFloater(save) param, which relied on the optional output LLXMLNodePtr param. Make onClickSaveFloater() and onClickSaveAll() emit popupAndPrintWarning() about discontinued functionality. Recast LLFloater::buildFromFile(), LLPanel::buildFromFile(), LLUICtrlFactory::createFromFile(), LLNotifications::loadTemplates(), LLUI::locateSkin(), LLFontRegistry::parseFontInfo(), LLUIColorTable::loadFromSettings(), LLUICtrlFactory::loadWidgetTemplate(), LLUICtrlFactory::getLayeredXMLNode(), LLUIImageList::initFromFile(), LLAppViewer::launchUpdater() and LLMediaCtrl::navigateToLocalPage() to use findSkinnedFilenames(). (Is LLAppViewer::launchUpdater() ever called any more? Apparently so -- though the linux-updater.bin logic to process the relevant command-line switch has been disabled. Shrug.) (Is LLMediaCtrl::navigateToLocalPage() ever used?? If so, why?) Remove LLUI::setupPaths(), getXUIPaths(), getSkinPath() and getLocalizedSkinPath(). Remove the skins/paths.xml file read by setupPaths(). The only configuration it contained was the pair of partial paths "xui/en" and "xui/[LANGUAGE]" -- hardly likely to change. getSkinPath() specifically returned the first of these, while getLocalizedSkinPath() specifically returned the second. This knowledge is now embedded in findSkinnedFilenames(). Also remove paths.xml from viewer_manifest.py. Remove injected xui_paths from LLFontGL::initClass() and LLFontRegistry::LLFontRegistry(). These are no longer needed since LLFontRegistry can now directly consult LLDir for its path search. Stop passing LLUI::getXUIPaths() to LLFontGL::initClass() in LLViewerWindow's constructor and initFonts() method. Add LLDir::append() and add() methods for the simple task of combining two path components separated by getDirDelimiter() -- but only if they're both non-empty. Amazing how often that logic is replicated. Replace some existing concatenations with add() or append(). New LLDir::findSkinnedFilenames() method must know current language. Allow injecting current language by adding an LLDir::setSkinFolder(language) param, and pass it where LLAppViewer::init() and initConfiguration() currently call setSkinFolder(). Also add LLDir::getSkinFolder() and getLanguage() methods. Change LLFLoaterUIPreview's LLLocalizationResetForcer helper to "forcibly reset language" using LLDir::setSkinFolder() instead of LLUI::setupPaths(). Update LLDir stubs in lldir_stub.cpp and llupdaterservice_test.cpp. Add LLDir::getUserDefaultSkinDir() to obtain often-overlooked possible skin directory -- like getUserSkinDir() but with "default" in place of the current skin name as the last path component. (However, we hope findSkinnedFilenames() obviates most explicit use of such individual skin directory pathnames.) Add LLDir unit tests for new findSkinnedFilenames() and add() methods -- the latter exercises append() as well. Tweak indra/integration_tests/llui_libtest/llui_libtest.cpp for all the above. Notably, comment out its export_test_floaters() function, since the essential LLFloater::buildFromFile(optional LLXMLNodePtr) functionality has been removed. This may mean that llui_libtest.cpp has little remaining value, not sure.
2012-02-10EXP-1885 FIX Viewer crashes when receiving multiple inventory offer ↵Richard Linden
notifications
2012-02-01EXP-1672 FIXED Various fixes to prevent crashes in notifications.Seth ProductEngine
- Refactoring of LLToast and LLScreenChannel classes: moved LLToast signals to the private section. - Modified the screen channel's lists of toasts to store LLHandles instead of pointers and screen channel code to work with toast LLHandles.
2012-01-27EXP-1513 WIP Underscore ( _ ) fails to show in first chat entry in Local ChatRichard Linden
cleaned up font positioning on buttons
2011-12-16EXP-1742 FIX -- Clicking IM notification or receiving multiple IM ↵Leslie Linden
notifications in quick succession crashes to desktop * Moved toast logic for mouse hover out of the draw call to avoid chain of callbacks that lead to reordering of the draw list while we are iterating over it.
2011-12-03EXP-1506 FIXED updating IM toasts visibility upoon mouse over and mouse ↵Seth ProductEngine
leave events. The mouse position is checked every frame in relation to the toast to catch the mouse leaving the toast "i" button when the toast is moved by the screen channel. The fix is intended to avoid the toasts that don't fade in the following scenario: 1. Have User A Send 4 IM messages to User B: a, b, c, d 2. Have User B hover their mouse over the i on toast c (don't click on it just hover) 3. As the other toasts fade observe toast c moves up to the top and does not fade
2011-11-22EXP-1506 FIXED starting the toast fade timer when a toast is overlapped by ↵Seth ProductEngine
other floater like avatar inspector. This is a kind of a workaround: perhaps the logic of updating the toast fade timer should be refactored to start/stop the timer from onMouseLeave/onMouseEnter callbacks instead of using "IsHovered" flag for each toast.
2011-03-09SOCIAL-659 FIX Viewer crash when selecting report option from mini-inspector ↵Richard Linden
in minimal and standard skin
2010-12-09STORM-774 FIXED Made notification toasts (e.g. IM toasts) respect ↵Vadim ProductEngine
transparency settings: * Normally toasts are as opaque as specified by "inactive floater opacity" setting. * When mouse is hovering a toast, the toast uses "active floater opacity" setting. * Fading toasts have 1/2 of "inactive floater opacity".
2010-12-09STORM-774 WIP Misc renames to improve readability.Vadim ProductEngine
2010-12-04STORM-717 WIP Cleanup: removed unused on_mouse_enter callback from LLToast.Vadim ProductEngine
2010-10-26STORM-36 FIXED As a User, I want to control how long a chat toast appears ↵Paul Guslisty
before it fades. Please add fade time back to Chat preferences. - Added two spinners to the Chat preferences tab that control NearbyToastLifeTime and NearbyToastFadingTime - Added callbacks to the LLNearbyChatScreenChannel that update these properties if they were changed Refactoring of LLToast: - Removed code that was making toast transparent from LLToast::draw() - Modified LLToast interface that relates to showing and hiding toast, so that all screen channels can use LLToast universally. - Replaced in LLScreenChannel calling methods of old interface to new ones.
2010-10-14STORM-211 FIXED Only the hovered toasts now persists until you move mouse ↵Vadim ProductEngine
away (all toasts used to freeze).
2010-08-27Post-convert merge by convert_monolith.py from ./viewer-experienceMonroe Linden
2010-08-20changed buildPanel/buildFloater to member functions buildFromFileRichard Nelson
streamlined LLUICtrlFactory's interface
2010-08-16moved buildFloater out of lluictrlfactory to llfloater.cppRichard Nelson
2010-08-13Change license from GPL to LGPL (version 2.1)Oz Linden
2010-06-30EXT-8044 FIXED Prevented incorrect displaying of toasts in mouselook mode.Alexei Arabadji
Added virtual method LLToast::reshape to prevent calling LLModalDialog::reshape method that changes toasts position. Toasts position should be controlled by toast screen channel. Ideally toasts should have different implementation for alerts and other kind of toasts, but it will leads to vast unwilling for 2.1 changes. reviewed by Vadim Savchuk at https://codereview.productengine.com/secondlife/r/666/ --HG-- branch : product-engine
2010-06-01EXT-7590 FIX Modal alerts obscure any modal alerts that they spawnRichard Linden
the toast logic to set visibility on dialogs in reverse order was bringing older modal dialogs to the front
2010-04-22fixed EXT-6805 No fading on toast's disappearingAlexei Arabadji
Reverted toast fading logic. reviewed by Mike Antipov https://codereview.productengine.com/secondlife/r/292/ --HG-- branch : product-engine
2010-04-19fixed EXT-6848 Avoid creation of dummy objects in LLOnlineStatusToast and ↵Alexei Arabadji
LLPanelGenericTip classes. * decoupled tip toast panel related logic from class LLTast; * moved documentation comment of LLPanelGenericTip constructor from .cpp to .h file; * corrected name attribute in panel_generic_tip.xml; reviewed by Mike Antipov and Vadim Savchuk at https://codereview.productengine.com/secondlife/r/230/ --HG-- branch : product-engine
2010-04-12fix for Bug EXT-6713 Normal Gaps in nearby chat toasts queueYuri Chebotarev
and EXT-6714 Normal Old chat toast is shown while chat log is open reviwed https://codereview.productengine.com/secondlife/r/212/ manttipov --HG-- branch : product-engine