Commit Graph

72 Commits (11f73b0e7ffa34a6a5402ce3d51b9d99831f6429)

Author SHA1 Message Date
Rye Mutt 3e322df4fb Replace liburiparser with boost::url 2024-07-29 13:33:12 +03:00
Ansariel b42f9d836b Re-enable a lot of compiler warnings for MSVC and address the C4267 "possible loss of precision" warnings 2024-06-01 15:49:26 +02:00
Andrey Lihatskiy 1b68f71348 #824 Process source files in bulk: replace tabs with spaces, convert CRLF to LF, and trim trailing whitespaces as needed 2024-04-29 07:56:09 +03:00
Nat Goodspeed 3c63cc9c55 SL-18837: Make LLVersionInfo::getBuild() S64 for GitHub run IDs. 2023-06-28 18:36:51 -04:00
Andrey Lihatskiy 49dd88e86c Merge branch 'master' into DRTVWR-540-maint
# Conflicts:
#	indra/newview/llfloatereditextdaycycle.cpp
#	indra/newview/llviewerinput.cpp
2021-11-19 04:45:15 +02:00
Andrey Lihatskiy 3e85f6a8c9 Merge branch 'master' into DRTVWR-540-maint 2021-07-19 22:22:58 +03:00
Andrey Lihatskiy 2ded530f93 Merge branch 'master' into DRTVWR-522-maint
# Conflicts:
#	doc/contributions.txt
#	indra/newview/llappcorehttp.cpp
#	indra/newview/llappcorehttp.h
2021-07-19 22:20:45 +03:00
Mnikolenko Productengine 2c557ffcfb SL-15507 Remove no longer used search token and no longer used search URL 2021-07-01 17:04:51 +03:00
Mnikolenko Productengine 03921adb12 SL-2202 Add exception handling around boost::regex_match() calls in the viewer 2021-01-11 17:07:03 +02:00
Mnikolenko Productengine 071e0ff36b SL-14494 FIXED llRequestURL() generated URLs are no longer recognized by the viewer as Second Life hosted URLs 2021-01-04 17:29:50 +02:00
Nat Goodspeed 5a260e0cc3 SL-11216: Convert LLVersionInfo to an LLSingleton.
This changeset is meant to exemplify how to convert a "namespace" class whose
methods are static -- and whose data are module-static -- to an LLSingleton.
LLVersionInfo has no initClass() or cleanupClass() methods, but the general
idea is the same.

* Derive the class from LLSingleton<T>:
  class LLSomeSingleton: public LLSingleton<LLSomeSingleton> { ... };
* Add LLSINGLETON(LLSomeSingleton); in the private section of the class. This
  usage implies a separate LLSomeSingleton::LLSomeSingleton() definition, as
  described in indra/llcommon/llsingleton.h.
* Move module-scope data in the .cpp file to non-static class members. Change
  any sVariableName to mVariableName to avoid being outright misleading.
* Make static class methods non-static. Remove '//static' comments from method
  definitions as needed.
* For LLVersionInfo specifically, the 'const std::string&' return type was
  replaced with 'std::string'. Returning a reference to a static or a member,
  const or otherwise, is an anti-pattern: the interface constrains the
  implementation, prohibiting possibly later returning a temporary (an
  expression).
* For LLVersionInfo specifically, 'const S32' return type was replaced with
  simple 'S32'. 'const' is just noise in that usage.
* Simple member initialization (e.g. the original initializer expressions for
  static variables) can be done with member{ value } initializers (no examples
  here though).
* Delete initClass() method.
* LLSingleton's forté is of course lazy initialization. It might work to
  simply delete any calls to initClass(). But if there are side effects that
  must happen at that moment, replace LLSomeSingleton::initClass() with
  (void)LLSomeSingleton::instance();
* Most initClass() initialization can be done in the constructor, as would
  normally be the case.
* Initialization that might cause a circular LLSingleton reference should be
  moved to initSingleton(). Override 'void initSingleton();' should be private.
* For LLVersionInfo specifically, certain initialization that used to be
  lazily performed was made unconditional, due to its low cost.
* For LLVersionInfo specifically, certain initialization involved calling
  methods that have become non-static. This was moved to initSingleton()
  because, in a constructor body, 'this' does not yet point to the enclosing
  class.
* Delete cleanupClass() method.
* There is already a generic LLSingletonBase::deleteAll() call in
  LLAppViewer::cleanup(). It might work to let this new LLSingleton be cleaned
  up with all the rest. But if there are side effects that must happen at that
  moment, replace LLSomeSingleton::cleanupClass() with
  LLSomeSingleton::deleteSingleton(). That said, much of the benefit of
  converting to LLSingleton is deleteAll()'s guarantee that cross-LLSingleton
  dependencies will be properly honored: we're trying to migrate the code base
  away from the present fragile manual cleanup sequence.
* Most cleanupClass() cleanup can be done in the destructor, as would normally
  be the case.
* Cleanup that might throw an exception should be moved to cleanupSingleton().
  Override 'void cleanupSingleton();' should be private.
* Within LLSomeSingleton methods, remove any existing
  LLSomeSingleton::methodName() qualification: simple methodName() is better.
* In the rest of the code base, convert most LLSomeSingleton::methodName()
  references to LLSomeSingleton::instance().methodName(). (Prefer instance() to
  getInstance() because a reference does not admit the possibility of NULL.)
* Of course, LLSomeSingleton::ENUM_VALUE can remain unchanged.

In general, for many successive references to an LLSingleton instance, it
can be useful to capture the instance() as in:

auto& versionInfo{LLVersionInfo::instance()};
// ... versionInfo.getVersion() ...

We did not do that here only to simplify the code review.

The STRINGIZE(expression) macro encapsulates:
std::ostringstream out;
out << expression;
return out.str();
We used that in a couple places.

For LLVersionInfo specifically, lllogininstance_test.cpp used to dummy out a
couple specific static methods. It's harder to dummy out
LLSingleton::instance() references, so we add the real class to that test.
2020-03-25 16:01:31 -04:00
andreykproductengine 47cbcb61f8 DRTVWR-493 Cleaned up unneded inits. 2019-07-04 20:24:38 +03:00
andreykproductengine 8369276a49 DRTVWR-493 LLViewerMedia to singleton 2019-06-21 20:55:39 +03:00
ruslantproductengine 2823b0639e SL-2642 - Better error logging for missing binormals
+ remove unreachable code
2018-09-27 17:35:12 +03:00
maxim_productengine 14c65a2c9e MAINT-8862 mailto URIs should be loaded in the external browser 2018-07-12 17:57:40 +03:00
andreykproductengine c21b3bbacc MAINT-7739 Make LLOSInfo a Singleton 2017-08-25 20:26:25 +03:00
daianakproductengine 1144fdc044 MAINT-6976 Fixed incorrect search line for open grid's in Search floater 2017-07-10 20:15:04 +03:00
AndreyL ProductEngine 3d9c39c77c MAINT-6663 [Win LibVLC] test video buttons still appearing in search 2016-08-20 12:53:03 +03:00
Oz Linden bc22e58743 merge changes for 4.0.1-release 2016-01-15 16:55:04 -05:00
callum_linden ec55f2cd10 MAINT-5862 Fix Provide a way for new Linux users to accept ToS 2015-11-13 16:19:16 -08:00
Oz Linden c8726aba30 remove execute permission from many files that should not have it 2015-11-10 09:48:56 -05:00
Cinder 5a282abe18 STORM-2113 - uri parsing cleanup and fixes 2015-04-11 15:23:06 -06:00
Mnikolenko ProductEngine 238eadde6d MAINT-4497 FIXED Use uriparser to find actual domain name. 2014-10-02 12:20:53 +03:00
AndreyL ProductEngine a23ec5ffa8 MAINT-4127: New default mode when clicking links: Linden links open in viewer, third-party links open in user's browser 2014-06-23 23:16:36 +03:00
Richard Linden e340009fc5 second phase summer cleaning
replace llinfos, lldebugs, etc with new LL_INFOS(), LL_DEBUGS(), etc.
2013-08-09 17:11:19 -07:00
Graham Madarasz bf6182daa8 Update Mac and Windows breakpad builds to latest 2013-03-29 07:50:08 -07:00
Oz Linden d500379cea PATH-735: Limit and clean up grid selection 2012-06-12 21:58:52 -04:00
Richard Linden a507fc259b finished removing remnants of media browser 2011-11-07 15:04:53 -08:00
Leslie Linden 7bc1eaf22f EXP-1342 FIX -- Update avatar picker and destination guide urls
* URL's are in place with the [GRID_LOWERCASE] used in the link to go to the
  proper page based on the grid.
* Added "GRID_LOWERCASE" substitution for URL's since it is case sensitive
2011-10-14 15:22:53 -07:00
Richard Nelson ec23ec68ea EXP-1310 FIX Profile button should open Web Profile floater
removed unused LLWeb functions for opening non-web media
moved logic inside floaters and away from auxiliary functions
2011-10-10 19:17:38 -07:00
Richard Linden feddda6740 EXP-1056 FIX Web popup issues with Web Content Browser
changed browser id back to a string so it accepts malformed uuid strings
coming from webkit - "{uuid}" instead of "uuid"
2011-07-29 16:38:07 -07:00
Richard Linden fa3f4d1166 EXP-880 FIX Enable navigation chrome for Search floater
search floater derives from floater_web_content
all web content now uses floater_web_content instead of media_browser
2011-07-12 20:58:30 -07:00
Monroe Linden dee57bea25 Merge from viewer-development. 2010-12-20 11:21:17 -08:00
callum 84a50386be SOCIAL-317 FIX LLWebContentFloater opens popups in the media browser 2010-12-02 18:46:26 -08:00
callum 522bcf17b7 SOCIAL-311 PARTIAL FIX Media browser has too many oddities to be useful for viewer web apps 2010-11-30 20:52:30 -08:00
Monroe Linden f974a019b1 Added DisableExternalBrowser setting.
Reviewed by Callum.
2010-10-06 16:50:04 -07:00
Monroe Linden a20a98454d Fix one variant of LLWeb::loadURLExternal() not passing through the uuid to the other variant. 2010-09-20 18:02:23 -07:00
Monroe Linden 531b77a948 Enable web popups to specify size and position of the Media Browser window from javascript.
This includes a Mac build of llqtwebkit from the following sources:

revision aacdf69cbf5aa12d77c179296e31ef643ed1ef4a of http://qt.gitorious.org/+lindenqt/qt/lindenqt (currently head of the 'lindenqt' branch)
revision 81ab5ae326f0 of http://hg.secondlife.com/llqtwebkit (currently head of the default branch)

Reviewed by Callum.
2010-09-15 14:39:42 -07:00
Monroe Linden b62b10dd26 Post-convert merge by convert_monolith.py from ./viewer-experience 2010-08-27 16:58:33 -07:00
Monroe Linden 25367cb33a Add support for an "_internal" target that forces a link to open in the embedded browser, regardless of the state of the "UseExternalBrowser" pref. 2010-08-18 16:58:57 -07:00
Oz Linden 06b0d72efa Change license from GPL to LGPL (version 2.1) 2010-08-13 07:24:57 -04:00
Monroe Linden d4668787ad Allow targeted links in the embedded browser to open multiple media browser windows.
Added an optional "target" parameter" to LLWeb::loadURL and loadInternal.

Made LLViewerMediaImpl::handleMediaEvent pass the target attribute of clicked links through.

Set floater_media_browser.xml to allow multiple instances.

Added LLFloaterMediaBrowser::create() and made LLFloaterMediaBrowser assume the incoming tag is the window's target, not the URL.

Reviewed by Richard at http://codereview.lindenlab.com/2641050
2010-08-05 11:16:13 -07:00
Richard Linden 68ca9dc957 VI-49 FIX "_external" links should work in shared media
monroe already did most of this, just moved dialog for confirming opening external browser to common code that calls out to external browser
so no way to skip notification unless the user opts out
2010-05-27 18:26:06 -07:00
Roxie Linden 658ccc3e85 Re-insert backed out SLE checkin so we can fix it 2010-04-07 11:08:04 -07:00
Tofu Linden 0bb3f144c0 Backed out changeset 63b699f90efd 2010-04-07 10:37:07 +01:00
Roxie Linden aa0a129b67 Automated Merge 2010-04-01 21:47:22 -07:00
Richard Nelson e50586043b EXT-3258 - Viewer freezes while external web browser loads page
reviewed by Callum
2010-03-29 15:28:48 -07:00
Lynx Linden f6304197a7 EXT-4882: Added firstlogin query param to Home website.
Url substitutions now support a [FIRST_LOGIN] parameter that returns
the value of gAgent.isFirstLogin(). This now gets passed to the Home
sidetray web site as a firstlogin query param.
2010-02-17 11:54:27 +00:00
Lynx Linden 6c992c95a9 EXT-3681: Send Parcel "Local ID" (S32) to web pages.
This is instead of sending the Parcel ID (LLUUID), which it turns out
the server never sends to the viewer (LLParcel::getID() always returns
NULL).
2010-02-04 10:23:24 +00:00
Lynx Linden f7120956f5 EXT-4898: Convert "en-us" to "en" for url substitutions.
The correct and general fix is to change English.lproj/language.txt.
This fix here is a more targeted and less risky fix at this stage
of the release cycle.
2010-02-04 09:21:02 +00:00