Commit Graph

31 Commits (680194deaf7a35caaa629abc16e886d71baff636)

Author SHA1 Message Date
Brad Payne (Vir Linden) a04a706c1b merge 2013-05-21 16:18:48 -04:00
Graham Madarasz bf6182daa8 Update Mac and Windows breakpad builds to latest 2013-03-29 07:50:08 -07:00
Don Kjer f945415210 Large changes to the LLCurl::Responder API, as well as pulling in some changes to common libraries from the server codebase:
* Additional error checking in http handlers.
* Uniform log spam for http errors.
* Switch to using constants for http heads and status codes.
* Fixed bugs in incorrectly checking if parsing LLSD xml resulted in an error.
* Reduced spam regarding LLSD parsing errors in the default completedRaw http handler.  It should not longer be necessary to short-circuit completedRaw to avoid spam.
* Ported over a few bug fixes from the server code.
* Switch mode http status codes to use S32 instead of U32.
* Ported LLSD::asStringRef from server code; avoids copying strings all over the place.
* Ported server change to LLSD::asBinary; this always returns a reference now instead of copying the entire binary blob.
* Ported server pretty notation format (and pretty binary format) to llsd serialization.

* The new LLCurl::Responder API no longer has two error handlers to choose from.  Overriding the following methods have been deprecated:
** error - use httpFailure
** errorWithContent - use httpFailure
** result - use httpSuccess
** completed - use httpCompleted
** completedHeader - no longer necessary; call getResponseHeaders() from a completion method to obtain these headers.

* In order to 'catch' a completed http request, override one of these methods:
** httpSuccess - Called for any 2xx status code.
** httpFailure - Called for any non-2xx status code.
** httpComplete - Called for all status codes.  Default implementation is to call either httpSuccess or httpFailure.
* It is recommended to keep these methods protected/private in order to avoid triggering of these methods without using a 'push' method (see below).

* Uniform error handling should followed whenever possible by calling a variant of this during httpFailure:
** llwarns << dumpResponse() << llendl;
* Be sure to include LOG_CLASS(your_class_name) in your class in order for the log entry to give more context.

* In order to 'push' a result into the responder, you should no longer call error, errorWithContent, result, or completed.
* Nor should you directly call httpSuccess/Failure/Completed (unless passing a message up to a parent class).
* Instead, you can set the internal content of a responder and trigger a corresponding method using the following methods:
** successResult - Sets results and calls httpSuccess
** failureResult - Sets results and calls httpFailure
** completedResult - Sets results and calls httpCompleted

* To obtain information about a the response from a reponder method, use the following getters:
** getStatus - HTTP status code
** getReason - Reason string
** getContent - Content (Parsed body LLSD)
** getResponseHeaders - Response Headers (LLSD map)
** getHTTPMethod - HTTP method of the request
** getURL - URL of the request

* It is still possible to override completeRaw if you want to manipulate data directly out of LLPumpIO.

* See indra/llmessage/llcurl.h for more information.
2013-03-13 06:26:25 +00:00
Oz Linden 06531fc24d SRCH-1623: UNDO EXP--1081 2011-09-08 17:16:35 -04:00
Richard Nelson dc8944ac49 EXP-1081 FIX add search auth token as cookie instead of query param
moved all parameters other than search query to base64 encoded llsd
2011-08-15 11:10:00 -07:00
Richard Linden 63a857f0c7 EXP-1054 FIX Entering search term in search box in Viewer UI does not produce search results if search window is already open
use new parameters when opening existing floater
2011-07-28 19:09:48 -07:00
Richard Linden 38ba526cc5 EXP-1009 WIP Teleport links from Search floater and destination guide in viewer fail with intrusted browser error in viewer 2011-07-13 17:59:53 -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
Leyla Farazha 2411a107e7 EXP-628 Inventory floater may be opened by SLApp
EXP-630 My appearance floater may be opened by SLApp
EXP-633 Search floater can be opened by SLApps
2011-04-18 14:22:23 -07:00
callum 5b69eeca91 SOCIAL-269 FIX Search floater in client should bypass the usual media MIME type detection 2010-11-16 17:55:31 -08:00
Richard Linden f3cdc9b01d allow_popups is now driven by trusted content flag
trusted content is now a const attribute of LLMediaCtrl, set in constructor params
2010-09-17 12:16:07 -07:00
Tofu Linden e416840f85 Backed out changeset c3d41f18ce2b
back-out the back-out for this branch.  yay.
2010-08-24 19:22:00 +01:00
Tofu Linden 98cc236503 Backed out changeset a62bf7c0af21
Backing out this merge that I pushed (prematurely) to the wrong place.
2010-08-24 18:44:39 +01:00
Tofu Linden 6ba23344c9 merge heads. whew. 2010-08-24 18:37:53 +01:00
Oz Linden 06b0d72efa Change license from GPL to LGPL (version 2.1) 2010-08-13 07:24:57 -04:00
Richard Nelson 566e3969f9 deprecated LLPanel::child*() methods 2010-07-30 10:02:30 -07:00
Lynx Linden 023bbc608d DEV-44136: Don't show previous search results when opening Find floater.
We now tear down the web view when we close the find floater. This
means that we don't show the previous search results when performing a
new search. It also makes for more efficient use of resources as we
don't have a web view continually running in the background. (This is
how the Help Browser currently works too.)
2010-02-18 16:48:02 +00:00
Lynx Linden 07aa9421e6 EXT-4145: Added a secondlife:///app/search SLapp
Displays the search floater and performs a search. You can specify an
optional category and an optional search string. See the wiki docs for
usage details: https://wiki.lindenlab.com/wiki/Viewer_2.0_SLapps
2010-01-11 11:39:37 +00:00
Lynx Linden 3726d3bda8 DEV-44136: Hide previous results when performing new search.
When a new search is performed, we first display a blank page in the
search floater so that the previous results are not visible while the
new results are being retrieved from the search server.
2010-01-04 11:42:48 +00:00
Lynx Linden 931591c0ab EXT-3496: Add a common authentication key for search and home.
Search and the Home sidetray now have their own specific
authentication keys that they support from login.cgi, but they
fallback to a common key as follows:

Search: "search_token", fallback to "auth_token"
Home: "home_sidetray_token", fallback to "auth_token"
2009-12-15 23:45:38 +00:00
Lynx Linden 870d4449f5 EXT-3441: Support various substitutions for Search URL.
The search URL is now specified in app_settings/settings.xml (instead
of in floater_search.xml), and it is now defined more flexibly with
support for various substitution strings, such as [QUERY], [AUTH_KEY],
[MATURITY], [GODLIKE], etc.

I pulled the common substitution code out into a new static method,
LLWeb::expandURLSubstitutions(). This provides support for common
strings like [VERSION], [CHANNEL], [LANGUAGE], [OS], etc. The Help and
Home sidetray code has been updated to use this new function, to avoid
replicating this behavior 3 times.

I also cleaned up the app_settings/settings.xml file and removed the
old search keys of: SearchURLDefault, SearchURLQuery, and
SearchURLSuffix2.
2009-12-15 16:00:28 +00:00
Lynx Linden d06ef88783 DEV-43679: Display god level warning in Search window.
If you change your god level from when you performed a search, the
search results may be inappropriate for your god level (we pass the
current god status to the search web pages). When this is the case, we
now display a warning at the bottom of the search floater to let the
user know that they should redo their search.
2009-12-10 19:02:33 +00:00
Lynx Linden 0c607a6b88 DEV-43679: Pass god mode through to search.
The state of gAgent.isGodlike() is now passed through to the Search
web pages via a new g=[0|1] query parameter.
2009-12-08 15:16:04 +00:00
Lynx Linden d491050c55 DEV-43439: Added navigation buttons to the Home side panel.
Added Back, Forward, and Home buttons to the web view for the Home
side panel. Still more work to do here, but the basic functionality
is there; albeit hardcoded to secondlife.com.

I notice that you can click Back on the first page. Seems to be an
issue for the general media browser too. I'll file a JIRA for that.
2009-12-02 21:18:59 +00:00
Lynx Linden 3a2fcad0cb DEV-41358: pass localization information to the Search web pages via a
new ?lang=<LANG> query parameter.
2009-12-01 13:07:41 +00:00
Lynx Linden 6b14f9a48f DEV-41358: Changed format of preferred maturity for search.
Now preferred maturity is passed to the search web pages as an
r={13|21|42} query param.
2009-11-11 22:42:25 +00:00
Lynx Linden a3017978d3 DEV-41358: Added user's preferred maturity level to search URL.
The Search URL now includes a "r=" query parameter to specify the
user's preferred maturity rating. This can be "pg" or "pg,mature"
or "pg,mature,adult".
2009-11-11 00:25:33 +00:00
Lynx Linden 068e132039 DEV-41358 DEV-41362: Get an authentication token from login.cgi and
pass this token through to the search web pages via a q= query
parameter in the search URL. This will let the search facility
determine the user's maturity and teen settings.

I also now escape the search string that the user typed in, 'cos they
could type anything.

Thanks to Mani for showing me how to get responses from login.cgi.
2009-11-04 09:12:32 +00:00
Martin Reddy 99aa77baae DEV-41358: Include the current user's maturity and teen ratings in the
URL that we send to the Search web page. This can be used to determine
the maturity levels to display. These bools are passed as query params
in the URL (as agreed upon with the search team).
2009-11-02 11:37:44 +00:00
Martin Reddy eb620735fc DEV-41358: Added support for search categories.
You can now specify a search category for all web-based searches,
e.g., "all" (default), "people", "places", "events", "groups", "wiki",
"destinations", "classifieds". Specifying a category will add the
relevant subdir to the search URL, as specified by the search team.
2009-10-20 14:07:50 +00:00
Martin Reddy 4ac6e30595 DEV-41359: Added a new web-based Search floater, LLFloaterSearch.
This new Search floater replaces the current XUI-based search
interface with one that is implemented entirely as a web service.

This is currently pointing toward a temporary search URL. The URL will
be updated when the stable version is available.
2009-10-19 11:59:57 +00:00