diff options
36 files changed, 442 insertions, 221 deletions
diff --git a/linden/indra/indra_complete/indra_complete.sln b/linden/indra/indra_complete/indra_complete.sln index f4a8647..c78dba2 100644 --- a/linden/indra/indra_complete/indra_complete.sln +++ b/linden/indra/indra_complete/indra_complete.sln | |||
@@ -504,7 +504,6 @@ Global | |||
504 | {E9F5BD55-F8E8-4C61-B9B5-CCE7C1048241}.ReleaseForDownload.ActiveCfg = Release|Win32 | 504 | {E9F5BD55-F8E8-4C61-B9B5-CCE7C1048241}.ReleaseForDownload.ActiveCfg = Release|Win32 |
505 | {E9F5BD55-F8E8-4C61-B9B5-CCE7C1048241}.ReleaseForDownload.Build.0 = Release|Win32 | 505 | {E9F5BD55-F8E8-4C61-B9B5-CCE7C1048241}.ReleaseForDownload.Build.0 = Release|Win32 |
506 | {E9F5BD55-F8E8-4C61-B9B5-CCE7C1048241}.ReleaseNoOpt.ActiveCfg = ReleaseNoOpt|Win32 | 506 | {E9F5BD55-F8E8-4C61-B9B5-CCE7C1048241}.ReleaseNoOpt.ActiveCfg = ReleaseNoOpt|Win32 |
507 | {E9F5BD55-F8E8-4C61-B9B5-CCE7C1048241}.ReleaseNoOpt.Build.0 = ReleaseNoOpt|Win32 | ||
508 | {023011F7-3ADB-49D3-9EC5-6D392F6D15FE}.Debug.ActiveCfg = Debug|Win32 | 507 | {023011F7-3ADB-49D3-9EC5-6D392F6D15FE}.Debug.ActiveCfg = Debug|Win32 |
509 | {023011F7-3ADB-49D3-9EC5-6D392F6D15FE}.Debug.Build.0 = Debug|Win32 | 508 | {023011F7-3ADB-49D3-9EC5-6D392F6D15FE}.Debug.Build.0 = Debug|Win32 |
510 | {023011F7-3ADB-49D3-9EC5-6D392F6D15FE}.Release.ActiveCfg = Release|Win32 | 509 | {023011F7-3ADB-49D3-9EC5-6D392F6D15FE}.Release.ActiveCfg = Release|Win32 |
diff --git a/linden/indra/llaudio/audioengine_fmod.cpp b/linden/indra/llaudio/audioengine_fmod.cpp index a69212e..0e8ea67 100644 --- a/linden/indra/llaudio/audioengine_fmod.cpp +++ b/linden/indra/llaudio/audioengine_fmod.cpp | |||
@@ -1136,7 +1136,7 @@ void * F_CALLBACKAPI windCallback(void *originalbuffer, void *newbuffer, int len | |||
1136 | double nextSample; | 1136 | double nextSample; |
1137 | 1137 | ||
1138 | // start with white noise | 1138 | // start with white noise |
1139 | nextSample = llclamp((ll_frand(2.0f) - 1.0f), -1.0f, 1.0f); | 1139 | nextSample = ll_frand(2.0f) - 1.0f; |
1140 | 1140 | ||
1141 | #if 1 // LLAE_WIND_PINK apply pinking filter | 1141 | #if 1 // LLAE_WIND_PINK apply pinking filter |
1142 | gbuf0 = 0.997f * gbuf0 + 0.0126502f * nextSample; | 1142 | gbuf0 = 0.997f * gbuf0 + 0.0126502f * nextSample; |
diff --git a/linden/indra/llcommon/llassettype.cpp b/linden/indra/llcommon/llassettype.cpp index cf38f7a..051092e 100644 --- a/linden/indra/llcommon/llassettype.cpp +++ b/linden/indra/llcommon/llassettype.cpp | |||
@@ -27,9 +27,11 @@ | |||
27 | 27 | ||
28 | #include "linden_common.h" | 28 | #include "linden_common.h" |
29 | 29 | ||
30 | #include "llassettype.h" | ||
31 | |||
30 | #include <time.h> | 32 | #include <time.h> |
31 | 33 | ||
32 | #include "llassettype.h" | 34 | #include "llstring.h" |
33 | #include "lltimer.h" | 35 | #include "lltimer.h" |
34 | 36 | ||
35 | // I added lookups for exact text of asset type enums in addition to the ones below, so shoot me. -Steve | 37 | // I added lookups for exact text of asset type enums in addition to the ones below, so shoot me. -Steve |
@@ -68,9 +70,9 @@ asset_info_t asset_types[] = | |||
68 | { LLAssetType::AT_NONE, "NONE" }, | 70 | { LLAssetType::AT_NONE, "NONE" }, |
69 | }; | 71 | }; |
70 | 72 | ||
71 | LLAssetType::EType LLAssetType::getType(const LLString& sin) | 73 | LLAssetType::EType LLAssetType::getType(const std::string& sin) |
72 | { | 74 | { |
73 | LLString s = sin; | 75 | std::string s = sin; |
74 | LLString::toUpper(s); | 76 | LLString::toUpper(s); |
75 | for (S32 idx = 0; ;idx++) | 77 | for (S32 idx = 0; ;idx++) |
76 | { | 78 | { |
@@ -83,17 +85,17 @@ LLAssetType::EType LLAssetType::getType(const LLString& sin) | |||
83 | return LLAssetType::AT_NONE; | 85 | return LLAssetType::AT_NONE; |
84 | } | 86 | } |
85 | 87 | ||
86 | LLString LLAssetType::getDesc(LLAssetType::EType type) | 88 | std::string LLAssetType::getDesc(LLAssetType::EType type) |
87 | { | 89 | { |
88 | for (S32 idx = 0; ;idx++) | 90 | for (S32 idx = 0; ;idx++) |
89 | { | 91 | { |
90 | asset_info_t* info = asset_types + idx; | 92 | asset_info_t* info = asset_types + idx; |
91 | if (type == info->type) | 93 | if (type == info->type) |
92 | return LLString(info->desc); | 94 | return info->desc; |
93 | if (info->type == LLAssetType::AT_NONE) | 95 | if (info->type == LLAssetType::AT_NONE) |
94 | break; | 96 | break; |
95 | } | 97 | } |
96 | return LLString("BAD TYPE"); | 98 | return "BAD TYPE"; |
97 | } | 99 | } |
98 | 100 | ||
99 | //============================================================================ | 101 | //============================================================================ |
@@ -225,7 +227,7 @@ EDragAndDropType LLAssetType::lookupDragAndDropType( EType asset ) | |||
225 | 227 | ||
226 | // static. Generate a good default description | 228 | // static. Generate a good default description |
227 | void LLAssetType::generateDescriptionFor(LLAssetType::EType type, | 229 | void LLAssetType::generateDescriptionFor(LLAssetType::EType type, |
228 | LLString& desc) | 230 | std::string& desc) |
229 | { | 231 | { |
230 | const S32 BUF_SIZE = 30; | 232 | const S32 BUF_SIZE = 30; |
231 | char time_str[BUF_SIZE]; /* Flawfinder: ignore */ | 233 | char time_str[BUF_SIZE]; /* Flawfinder: ignore */ |
diff --git a/linden/indra/llcommon/llassettype.h b/linden/indra/llcommon/llassettype.h index c62769a..67dc3ef 100644 --- a/linden/indra/llcommon/llassettype.h +++ b/linden/indra/llcommon/llassettype.h | |||
@@ -28,6 +28,8 @@ | |||
28 | #ifndef LL_LLASSETTYPE | 28 | #ifndef LL_LLASSETTYPE |
29 | #define LL_LLASSETTYPE | 29 | #define LL_LLASSETTYPE |
30 | 30 | ||
31 | #include <string> | ||
32 | |||
31 | #include "stdenums.h" // for EDragAndDropType | 33 | #include "stdenums.h" // for EDragAndDropType |
32 | 34 | ||
33 | class LLAssetType | 35 | class LLAssetType |
@@ -150,10 +152,10 @@ public: | |||
150 | // Generate a good default description. You may want to add a verb | 152 | // Generate a good default description. You may want to add a verb |
151 | // or agent name after this depending on your application. | 153 | // or agent name after this depending on your application. |
152 | static void generateDescriptionFor(LLAssetType::EType type, | 154 | static void generateDescriptionFor(LLAssetType::EType type, |
153 | LLString& desc); | 155 | std::string& desc); |
154 | 156 | ||
155 | static EType getType(const LLString& sin); | 157 | static EType getType(const std::string& sin); |
156 | static LLString getDesc(EType type); | 158 | static std::string getDesc(EType type); |
157 | 159 | ||
158 | private: | 160 | private: |
159 | // don't instantiate or derive one of these objects | 161 | // don't instantiate or derive one of these objects |
diff --git a/linden/indra/llcommon/llavatarconstants.h b/linden/indra/llcommon/llavatarconstants.h index f56e9ab..3335949 100644 --- a/linden/indra/llcommon/llavatarconstants.h +++ b/linden/indra/llcommon/llavatarconstants.h | |||
@@ -39,5 +39,17 @@ const char* const BLACKLIST_PROFILE_WEB_URL = "http://secondlife.com/app/webdisa | |||
39 | // Maximum number of avatar picks | 39 | // Maximum number of avatar picks |
40 | const S32 MAX_AVATAR_PICKS = 10; | 40 | const S32 MAX_AVATAR_PICKS = 10; |
41 | 41 | ||
42 | // For Flags in AvatarPropertiesReply | ||
43 | const U32 AVATAR_ALLOW_PUBLISH = 0x1 << 0; // whether profile is externally visible or not | ||
44 | const U32 AVATAR_MATURE_PUBLISH = 0x1 << 1; // profile is "mature" | ||
45 | const U32 AVATAR_IDENTIFIED = 0x1 << 2; // whether avatar has provided payment info | ||
46 | const U32 AVATAR_TRANSACTED = 0x1 << 3; // whether avatar has actively used payment info | ||
47 | const U32 AVATAR_ONLINE = 0x1 << 4; // the online status of this avatar, if known. | ||
48 | |||
49 | static const std::string VISIBILITY_DEFAULT("default"); | ||
50 | static const std::string VISIBILITY_HIDDEN("hidden"); | ||
51 | static const std::string VISIBILITY_VISIBLE("visible"); | ||
52 | static const std::string VISIBILITY_INVISIBLE("invisible"); | ||
53 | |||
42 | #endif | 54 | #endif |
43 | 55 | ||
diff --git a/linden/indra/llcommon/llsdutil.cpp b/linden/indra/llcommon/llsdutil.cpp index f111039..0f295a1 100644 --- a/linden/indra/llcommon/llsdutil.cpp +++ b/linden/indra/llcommon/llsdutil.cpp | |||
@@ -222,3 +222,14 @@ U32 ll_ipaddr_from_sd(const LLSD& sd) | |||
222 | memcpy(&ret, &(v[0]), 4); /* Flawfinder: ignore */ | 222 | memcpy(&ret, &(v[0]), 4); /* Flawfinder: ignore */ |
223 | return ret; | 223 | return ret; |
224 | } | 224 | } |
225 | |||
226 | // Converts an LLSD binary to an LLSD string | ||
227 | LLSD ll_string_from_binary(const LLSD& sd) | ||
228 | { | ||
229 | std::vector<U8> value = sd.asBinary(); | ||
230 | char* c_str = new char[value.size() + 1]; | ||
231 | memcpy(c_str, &value[0], value.size()); | ||
232 | c_str[value.size()] = '\0'; | ||
233 | |||
234 | return c_str; | ||
235 | } | ||
diff --git a/linden/indra/llcommon/llsdutil.h b/linden/indra/llcommon/llsdutil.h index 555d7fb..ca6b76f 100644 --- a/linden/indra/llcommon/llsdutil.h +++ b/linden/indra/llcommon/llsdutil.h | |||
@@ -70,4 +70,7 @@ U64 ll_U64_from_sd(const LLSD& sd); | |||
70 | LLSD ll_sd_from_ipaddr(const U32); | 70 | LLSD ll_sd_from_ipaddr(const U32); |
71 | U32 ll_ipaddr_from_sd(const LLSD& sd); | 71 | U32 ll_ipaddr_from_sd(const LLSD& sd); |
72 | 72 | ||
73 | // Binary to string | ||
74 | LLSD ll_string_from_binary(const LLSD& sd); | ||
75 | |||
73 | #endif // LL_LLSDUTIL_H | 76 | #endif // LL_LLSDUTIL_H |
diff --git a/linden/indra/llcommon/lluri.cpp b/linden/indra/llcommon/lluri.cpp index 2eb0f11..e697ec1 100644 --- a/linden/indra/llcommon/lluri.cpp +++ b/linden/indra/llcommon/lluri.cpp | |||
@@ -28,9 +28,13 @@ | |||
28 | */ | 28 | */ |
29 | 29 | ||
30 | #include "linden_common.h" | 30 | #include "linden_common.h" |
31 | |||
32 | #include "llapp.h" | ||
31 | #include "lluri.h" | 33 | #include "lluri.h" |
32 | #include "llsd.h" | 34 | #include "llsd.h" |
33 | 35 | ||
36 | #include "../llmath/lluuid.h" | ||
37 | |||
34 | // uric = reserved | unreserved | escaped | 38 | // uric = reserved | unreserved | escaped |
35 | // reserved = ";" | "/" | "?" | ":" | "@" | "&" | "=" | "+" | "$" | "," | 39 | // reserved = ";" | "/" | "?" | ":" | "@" | "&" | "=" | "+" | "$" | "," |
36 | // unreserved = alphanum | mark | 40 | // unreserved = alphanum | mark |
@@ -372,9 +376,21 @@ LLURI LLURI::buildHTTP(const std::string& host_port, | |||
372 | const LLSD& path) | 376 | const LLSD& path) |
373 | { | 377 | { |
374 | LLURI result; | 378 | LLURI result; |
375 | result.mScheme = "HTTP"; | 379 | |
376 | // TODO: deal with '/' '?' '#' in host_port | 380 | // TODO: deal with '/' '?' '#' in host_port |
377 | result.mEscapedAuthority = "//" + escape(host_port); | 381 | S32 index = host_port.find("://"); |
382 | if (index != host_port.npos) | ||
383 | { | ||
384 | // The scheme is part of the host_port | ||
385 | result.mScheme = ""; | ||
386 | result.mEscapedAuthority = escape(host_port); | ||
387 | } | ||
388 | else | ||
389 | { | ||
390 | result.mScheme = "HTTP"; | ||
391 | result.mEscapedAuthority = "//" + escape(host_port); | ||
392 | } | ||
393 | |||
378 | if (path.isArray()) | 394 | if (path.isArray()) |
379 | { | 395 | { |
380 | // break out and escape each path component | 396 | // break out and escape each path component |
@@ -416,6 +432,70 @@ LLURI LLURI::buildHTTP(const std::string& host_port, | |||
416 | return result; | 432 | return result; |
417 | } | 433 | } |
418 | 434 | ||
435 | // static | ||
436 | LLURI LLURI::buildAgentPresenceURI(const LLUUID& agent_id, LLApp* app) | ||
437 | { | ||
438 | std::string host = "localhost:12040"; | ||
439 | |||
440 | if (app) | ||
441 | { | ||
442 | host = app->getOption("backbone-host-port").asString(); | ||
443 | } | ||
444 | |||
445 | LLSD path = LLSD::emptyArray(); | ||
446 | path.append("agent"); | ||
447 | path.append(agent_id); | ||
448 | path.append("presence"); | ||
449 | |||
450 | return buildHTTP(host, path); | ||
451 | } | ||
452 | |||
453 | // static | ||
454 | LLURI LLURI::buildBulkAgentPresenceURI(LLApp* app) | ||
455 | { | ||
456 | std::string host = "localhost:12040"; | ||
457 | |||
458 | if (app) | ||
459 | { | ||
460 | host = app->getOption("backbone-host-port").asString(); | ||
461 | } | ||
462 | |||
463 | LLSD path = LLSD::emptyArray(); | ||
464 | path.append("agent"); | ||
465 | path.append("presence"); | ||
466 | |||
467 | return buildHTTP(host, path); | ||
468 | } | ||
469 | |||
470 | // static | ||
471 | LLURI LLURI::buildAgentSessionURI(const LLUUID& agent_id, LLApp* app) | ||
472 | { | ||
473 | std::string host = "localhost:12040"; | ||
474 | |||
475 | if (app) | ||
476 | { | ||
477 | host = app->getOption("backbone-host-port").asString(); | ||
478 | } | ||
479 | |||
480 | LLSD path = LLSD::emptyArray(); | ||
481 | path.append("agent"); | ||
482 | path.append(agent_id); | ||
483 | path.append("session"); | ||
484 | |||
485 | return buildHTTP(host, path); | ||
486 | } | ||
487 | |||
488 | // static | ||
489 | LLURI LLURI::buildAgentLoginInfoURI(const LLUUID& agent_id, const std::string& dataserver) | ||
490 | { | ||
491 | LLSD path = LLSD::emptyArray(); | ||
492 | path.append("agent"); | ||
493 | path.append(agent_id); | ||
494 | path.append("logininfo"); | ||
495 | |||
496 | return buildHTTP(dataserver, path); | ||
497 | } | ||
498 | |||
419 | std::string LLURI::asString() const | 499 | std::string LLURI::asString() const |
420 | { | 500 | { |
421 | if (mScheme.empty()) | 501 | if (mScheme.empty()) |
diff --git a/linden/indra/llcommon/lluri.h b/linden/indra/llcommon/lluri.h index 52f07bf..f69472f 100644 --- a/linden/indra/llcommon/lluri.h +++ b/linden/indra/llcommon/lluri.h | |||
@@ -33,6 +33,8 @@ | |||
33 | #include <string> | 33 | #include <string> |
34 | 34 | ||
35 | class LLSD; | 35 | class LLSD; |
36 | class LLUUID; | ||
37 | class LLApp; | ||
36 | 38 | ||
37 | /** | 39 | /** |
38 | * | 40 | * |
@@ -80,6 +82,11 @@ public: | |||
80 | static std::string escape(const std::string& str); | 82 | static std::string escape(const std::string& str); |
81 | static std::string unescape(const std::string& str); | 83 | static std::string unescape(const std::string& str); |
82 | 84 | ||
85 | // Functions for building specific URIs for web services | ||
86 | static LLURI buildAgentPresenceURI(const LLUUID& agent_id, LLApp* app); | ||
87 | static LLURI buildBulkAgentPresenceURI(LLApp* app); | ||
88 | static LLURI buildAgentSessionURI(const LLUUID& agent_id, LLApp* app); | ||
89 | static LLURI buildAgentLoginInfoURI(const LLUUID& agent_id, const std::string& dataserver); | ||
83 | private: | 90 | private: |
84 | std::string mScheme; | 91 | std::string mScheme; |
85 | std::string mEscapedOpaque; | 92 | std::string mEscapedOpaque; |
diff --git a/linden/indra/llcommon/llversion.h b/linden/indra/llcommon/llversion.h index 9cb01a3..af21f72 100644 --- a/linden/indra/llcommon/llversion.h +++ b/linden/indra/llcommon/llversion.h | |||
@@ -33,8 +33,8 @@ | |||
33 | // MUST ALSO change version number in secondlife setup.nsi | 33 | // MUST ALSO change version number in secondlife setup.nsi |
34 | const S32 LL_VERSION_MAJOR = 1; | 34 | const S32 LL_VERSION_MAJOR = 1; |
35 | const S32 LL_VERSION_MINOR = 13; | 35 | const S32 LL_VERSION_MINOR = 13; |
36 | const S32 LL_VERSION_PATCH = 2; | 36 | const S32 LL_VERSION_PATCH = 3; |
37 | const S32 LL_VERSION_BUILD = 15; | 37 | const S32 LL_VERSION_BUILD = 2; |
38 | 38 | ||
39 | 39 | ||
40 | 40 | ||
diff --git a/linden/indra/llmath/llrand.cpp b/linden/indra/llmath/llrand.cpp index 4c214c4..c0f03d2 100644 --- a/linden/indra/llmath/llrand.cpp +++ b/linden/indra/llmath/llrand.cpp | |||
@@ -30,34 +30,129 @@ | |||
30 | #include "llrand.h" | 30 | #include "llrand.h" |
31 | #include "lluuid.h" | 31 | #include "lluuid.h" |
32 | 32 | ||
33 | /** | ||
34 | * Through analysis, we have decided that we want to take values which | ||
35 | * are close enough to 1.0 to map back to 0.0. We came to this | ||
36 | * conclusion from noting that: | ||
37 | * | ||
38 | * [0.0, 1.0) | ||
39 | * | ||
40 | * when scaled to the integer set: | ||
41 | * | ||
42 | * [0, 4) | ||
43 | * | ||
44 | * there is some value close enough to 1.0 that when multiplying by 4, | ||
45 | * gets truncated to 4. Therefore: | ||
46 | * | ||
47 | * [0,1-eps] => 0 | ||
48 | * [1,2-eps] => 1 | ||
49 | * [2,3-eps] => 2 | ||
50 | * [3,4-eps] => 3 | ||
51 | * | ||
52 | * So 0 gets uneven distribution if we simply clamp. The actual | ||
53 | * clamp utilized in this file is to map values out of range back | ||
54 | * to 0 to restore uniform distribution. | ||
55 | * | ||
56 | * Also, for clamping floats when asking for a distribution from | ||
57 | * [0.0,g) we have determined that for values of g < 0.5, then | ||
58 | * rand*g=g, which is not the desired result. As above, we clamp to 0 | ||
59 | * to restore uniform distribution. | ||
60 | */ | ||
61 | |||
62 | // *NOTE: The system rand implementation is probably not correct. | ||
63 | #define LL_USE_SYSTEM_RAND 0 | ||
64 | |||
65 | #if LL_USE_SYSTEM_RAND | ||
66 | #include <stdlib.h> | ||
67 | #endif | ||
68 | |||
69 | #if LL_USE_SYSTEM_RAND | ||
70 | class LLSeedRand | ||
71 | { | ||
72 | public: | ||
73 | LLSeedRand() | ||
74 | { | ||
75 | #if LL_WINDOWS | ||
76 | srand(LLUUID::getRandomSeed()); | ||
77 | #else | ||
78 | srand48(LLUUID::getRandomSeed()); | ||
79 | #endif | ||
80 | } | ||
81 | }; | ||
82 | static LLSeedRand sRandomSeeder; | ||
83 | inline F64 ll_internal_random_double() | ||
84 | { | ||
85 | #if LL_WINDOWS | ||
86 | return (F64)rand() / (F64)RAND_MAX; | ||
87 | #else | ||
88 | return drand48(); | ||
89 | #endif | ||
90 | } | ||
91 | inline F32 ll_internal_random_float() | ||
92 | { | ||
93 | #if LL_WINDOWS | ||
94 | return (F32)rand() / (F32)RAND_MAX; | ||
95 | #else | ||
96 | return (F32)drand48(); | ||
97 | #endif | ||
98 | } | ||
99 | #else | ||
33 | static LLRandLagFib2281 gRandomGenerator(LLUUID::getRandomSeed()); | 100 | static LLRandLagFib2281 gRandomGenerator(LLUUID::getRandomSeed()); |
101 | inline F64 ll_internal_random_double() | ||
102 | { | ||
103 | // *HACK: Through experimentation, we have found that dual core | ||
104 | // CPUs (or at least multi-threaded processes) seem to | ||
105 | // occasionally give an obviously incorrect random number -- like | ||
106 | // 5^15 or something. Sooooo, clamp it as described above. | ||
107 | F64 rv = gRandomGenerator(); | ||
108 | if(!((rv >= 0.0) && (rv < 1.0))) return 0.0; | ||
109 | return rv; | ||
110 | } | ||
111 | |||
112 | inline F32 ll_internal_random_float() | ||
113 | { | ||
114 | // The clamping rules are described above. | ||
115 | F32 rv = (F32)gRandomGenerator(); | ||
116 | if(!((rv >= 0.0f) && (rv < 1.0f))) return 0.0f; | ||
117 | return rv; | ||
118 | } | ||
119 | #endif | ||
34 | 120 | ||
35 | S32 ll_rand() | 121 | S32 ll_rand() |
36 | { | 122 | { |
37 | return (S32)(gRandomGenerator() * RAND_MAX); | 123 | return ll_rand(RAND_MAX); |
38 | } | 124 | } |
39 | 125 | ||
40 | S32 ll_rand(S32 val) | 126 | S32 ll_rand(S32 val) |
41 | { | 127 | { |
42 | return (S32)(gRandomGenerator() * val); | 128 | // The clamping rules are described above. |
129 | S32 rv = (S32)(ll_internal_random_double() * val); | ||
130 | if(rv == val) return 0; | ||
131 | return rv; | ||
43 | } | 132 | } |
44 | 133 | ||
45 | F32 ll_frand() | 134 | F32 ll_frand() |
46 | { | 135 | { |
47 | return (F32)gRandomGenerator(); | 136 | return ll_internal_random_float(); |
48 | } | 137 | } |
49 | 138 | ||
50 | F32 ll_frand(F32 val) | 139 | F32 ll_frand(F32 val) |
51 | { | 140 | { |
52 | return (F32)gRandomGenerator() * val; | 141 | // The clamping rules are described above. |
142 | F32 rv = ll_internal_random_float() * val; | ||
143 | if(rv >= val) return 0.0f; | ||
144 | return rv; | ||
53 | } | 145 | } |
54 | 146 | ||
55 | F64 ll_drand() | 147 | F64 ll_drand() |
56 | { | 148 | { |
57 | return gRandomGenerator(); | 149 | return ll_internal_random_double(); |
58 | } | 150 | } |
59 | 151 | ||
60 | F64 ll_drand(F64 val) | 152 | F64 ll_drand(F64 val) |
61 | { | 153 | { |
62 | return gRandomGenerator() * val; | 154 | // The clamping rules are described above. |
155 | F64 rv = ll_internal_random_double() * val; | ||
156 | if(rv >= val) return 0.0; | ||
157 | return rv; | ||
63 | } | 158 | } |
diff --git a/linden/indra/llmessage/llhttpclient.cpp b/linden/indra/llmessage/llhttpclient.cpp index 5f75e59..d94918e 100644 --- a/linden/indra/llmessage/llhttpclient.cpp +++ b/linden/indra/llmessage/llhttpclient.cpp | |||
@@ -26,8 +26,10 @@ | |||
26 | */ | 26 | */ |
27 | 27 | ||
28 | #include "linden_common.h" | 28 | #include "linden_common.h" |
29 | #include "llassetstorage.h" | 29 | |
30 | #include "llhttpclient.h" | 30 | #include "llhttpclient.h" |
31 | |||
32 | #include "llassetstorage.h" | ||
31 | #include "lliopipe.h" | 33 | #include "lliopipe.h" |
32 | #include "llurlrequest.h" | 34 | #include "llurlrequest.h" |
33 | #include "llbufferstream.h" | 35 | #include "llbufferstream.h" |
@@ -251,6 +253,11 @@ void LLHTTPClient::post(const std::string& url, const LLSD& body, ResponderPtr r | |||
251 | request(url, LLURLRequest::HTTP_POST, new LLSDInjector(body), responder); | 253 | request(url, LLURLRequest::HTTP_POST, new LLSDInjector(body), responder); |
252 | } | 254 | } |
253 | 255 | ||
256 | void LLHTTPClient::del(const std::string& url, ResponderPtr responder) | ||
257 | { | ||
258 | request(url, LLURLRequest::HTTP_DELETE, NULL, responder); | ||
259 | } | ||
260 | |||
254 | #if 1 | 261 | #if 1 |
255 | void LLHTTPClient::postFile(const std::string& url, const std::string& filename, ResponderPtr responder) | 262 | void LLHTTPClient::postFile(const std::string& url, const std::string& filename, ResponderPtr responder) |
256 | { | 263 | { |
diff --git a/linden/indra/llmessage/llhttpclient.h b/linden/indra/llmessage/llhttpclient.h index c6b68b2..d48d084 100644 --- a/linden/indra/llmessage/llhttpclient.h +++ b/linden/indra/llmessage/llhttpclient.h | |||
@@ -35,8 +35,10 @@ | |||
35 | #include <string> | 35 | #include <string> |
36 | 36 | ||
37 | #include <boost/intrusive_ptr.hpp> | 37 | #include <boost/intrusive_ptr.hpp> |
38 | #include "llassetstorage.h" | ||
39 | 38 | ||
39 | #include "llassettype.h" | ||
40 | |||
41 | class LLUUID; | ||
40 | class LLPumpIO; | 42 | class LLPumpIO; |
41 | class LLSD; | 43 | class LLSD; |
42 | 44 | ||
diff --git a/linden/indra/llvfs/llvfs.cpp b/linden/indra/llvfs/llvfs.cpp index ed1c313..bb211df 100644 --- a/linden/indra/llvfs/llvfs.cpp +++ b/linden/indra/llvfs/llvfs.cpp | |||
@@ -1957,6 +1957,60 @@ void LLVFS::dumpStatistics() | |||
1957 | } | 1957 | } |
1958 | 1958 | ||
1959 | // Debug Only! | 1959 | // Debug Only! |
1960 | LLString get_extension(LLAssetType::EType type) | ||
1961 | { | ||
1962 | LLString extension; | ||
1963 | switch(type) | ||
1964 | { | ||
1965 | case LLAssetType::AT_TEXTURE: | ||
1966 | extension = ".jp2"; // ".j2c"; // IrfanView recognizes .jp2 -sjb | ||
1967 | break; | ||
1968 | case LLAssetType::AT_SOUND: | ||
1969 | extension = ".ogg"; | ||
1970 | break; | ||
1971 | case LLAssetType::AT_SOUND_WAV: | ||
1972 | extension = ".wav"; | ||
1973 | break; | ||
1974 | case LLAssetType::AT_TEXTURE_TGA: | ||
1975 | extension = ".tga"; | ||
1976 | break; | ||
1977 | case LLAssetType::AT_IMAGE_JPEG: | ||
1978 | extension = ".jpeg"; | ||
1979 | break; | ||
1980 | case LLAssetType::AT_ANIMATION: | ||
1981 | extension = ".lla"; | ||
1982 | break; | ||
1983 | default: | ||
1984 | extension = ".data"; | ||
1985 | break; | ||
1986 | } | ||
1987 | return extension; | ||
1988 | } | ||
1989 | |||
1990 | void LLVFS::listFiles() | ||
1991 | { | ||
1992 | lockData(); | ||
1993 | |||
1994 | for (fileblock_map::iterator it = mFileBlocks.begin(); it != mFileBlocks.end(); ++it) | ||
1995 | { | ||
1996 | LLVFSFileSpecifier file_spec = it->first; | ||
1997 | LLVFSFileBlock *file_block = it->second; | ||
1998 | S32 length = file_block->mLength; | ||
1999 | S32 size = file_block->mSize; | ||
2000 | if (length != BLOCK_LENGTH_INVALID && size > 0) | ||
2001 | { | ||
2002 | LLUUID id = file_spec.mFileID; | ||
2003 | LLString extension = get_extension(file_spec.mFileType); | ||
2004 | llinfos << " File: " << id | ||
2005 | << " Type: " << LLAssetType::getDesc(file_spec.mFileType) | ||
2006 | << " Size: " << size | ||
2007 | << llendl; | ||
2008 | } | ||
2009 | } | ||
2010 | |||
2011 | unlockData(); | ||
2012 | } | ||
2013 | |||
1960 | #include "llapr.h" | 2014 | #include "llapr.h" |
1961 | void LLVFS::dumpFiles() | 2015 | void LLVFS::dumpFiles() |
1962 | { | 2016 | { |
@@ -1978,16 +2032,8 @@ void LLVFS::dumpFiles() | |||
1978 | getData(id, type, buffer, 0, size); | 2032 | getData(id, type, buffer, 0, size); |
1979 | lockData(); | 2033 | lockData(); |
1980 | 2034 | ||
1981 | LLString extention = ".data"; | 2035 | LLString extension = get_extension(type); |
1982 | switch(type) | 2036 | LLString filename = id.getString() + extension; |
1983 | { | ||
1984 | case LLAssetType::AT_TEXTURE: | ||
1985 | extention = ".jp2"; // ".j2c"; // IrfanView recognizes .jp2 -sjb | ||
1986 | break; | ||
1987 | default: | ||
1988 | break; | ||
1989 | } | ||
1990 | LLString filename = id.getString() + extention; | ||
1991 | llinfos << " Writing " << filename << llendl; | 2037 | llinfos << " Writing " << filename << llendl; |
1992 | apr_file_t* file = ll_apr_file_open(filename, LL_APR_WB); | 2038 | apr_file_t* file = ll_apr_file_open(filename, LL_APR_WB); |
1993 | ll_apr_file_write(file, buffer, size); | 2039 | ll_apr_file_write(file, buffer, size); |
diff --git a/linden/indra/llvfs/llvfs.h b/linden/indra/llvfs/llvfs.h index f7affd4..4598c07 100644 --- a/linden/indra/llvfs/llvfs.h +++ b/linden/indra/llvfs/llvfs.h | |||
@@ -115,6 +115,7 @@ public: | |||
115 | void dumpMap(); | 115 | void dumpMap(); |
116 | void dumpLockCounts(); | 116 | void dumpLockCounts(); |
117 | void dumpStatistics(); | 117 | void dumpStatistics(); |
118 | void listFiles(); | ||
118 | void dumpFiles(); | 119 | void dumpFiles(); |
119 | 120 | ||
120 | protected: | 121 | protected: |
diff --git a/linden/indra/newview/English.lproj/InfoPlist.strings b/linden/indra/newview/English.lproj/InfoPlist.strings index 2f68a02..6ef64e4 100644 --- a/linden/indra/newview/English.lproj/InfoPlist.strings +++ b/linden/indra/newview/English.lproj/InfoPlist.strings | |||
@@ -1,5 +1,5 @@ | |||
1 | /* Localized versions of Info.plist keys */ | 1 | /* Localized versions of Info.plist keys */ |
2 | 2 | ||
3 | CFBundleName = "Second Life"; | 3 | CFBundleName = "Second Life"; |
4 | CFBundleShortVersionString = "Second Life version 1.13.2.15"; | 4 | CFBundleShortVersionString = "Second Life version 1.13.3.2"; |
5 | CFBundleGetInfoString = "Second Life version 1.13.2.15, Copyright 2004-2006 Linden Research, Inc."; | 5 | CFBundleGetInfoString = "Second Life version 1.13.3.2, Copyright 2004-2006 Linden Research, Inc."; |
diff --git a/linden/indra/newview/Info-SecondLife.plist b/linden/indra/newview/Info-SecondLife.plist index 3e6c65e..6e1de8b 100644 --- a/linden/indra/newview/Info-SecondLife.plist +++ b/linden/indra/newview/Info-SecondLife.plist | |||
@@ -32,7 +32,7 @@ | |||
32 | </dict> | 32 | </dict> |
33 | </array> | 33 | </array> |
34 | <key>CFBundleVersion</key> | 34 | <key>CFBundleVersion</key> |
35 | <string>1.13.2.15</string> | 35 | <string>1.13.3.2</string> |
36 | <key>CSResourcesFileMapped</key> | 36 | <key>CSResourcesFileMapped</key> |
37 | <true/> | 37 | <true/> |
38 | </dict> | 38 | </dict> |
diff --git a/linden/indra/newview/llfloateravatarinfo.cpp b/linden/indra/newview/llfloateravatarinfo.cpp index a429cc2..959967a 100644 --- a/linden/indra/newview/llfloateravatarinfo.cpp +++ b/linden/indra/newview/llfloateravatarinfo.cpp | |||
@@ -121,7 +121,7 @@ BOOL LLFloaterAvatarInfo::postBuild() | |||
121 | LLFloaterAvatarInfo::LLFloaterAvatarInfo(const std::string& name, const LLRect &rect, const LLUUID &avatar_id) | 121 | LLFloaterAvatarInfo::LLFloaterAvatarInfo(const std::string& name, const LLRect &rect, const LLUUID &avatar_id) |
122 | : LLPreview(name, rect, FLOATER_TITLE, LLUUID::null, LLUUID::null), | 122 | : LLPreview(name, rect, FLOATER_TITLE, LLUUID::null, LLUUID::null), |
123 | mAvatarID( avatar_id ), | 123 | mAvatarID( avatar_id ), |
124 | mSuggestedOnlineStatus(ONLINE_STATUS_UNKNOWN) | 124 | mSuggestedOnlineStatus(ONLINE_STATUS_NO) |
125 | { | 125 | { |
126 | mAutoFocus = TRUE; | 126 | mAutoFocus = TRUE; |
127 | 127 | ||
@@ -182,7 +182,7 @@ void LLFloaterAvatarInfo::showFromObject(const LLUUID &avatar_id, std::string ta | |||
182 | floater = new LLFloaterAvatarInfo("avatarinfo", FAI_RECT, | 182 | floater = new LLFloaterAvatarInfo("avatarinfo", FAI_RECT, |
183 | avatar_id); | 183 | avatar_id); |
184 | floater->center(); | 184 | floater->center(); |
185 | floater->mPanelAvatarp->setAvatarID(avatar_id, "", ONLINE_STATUS_UNKNOWN); | 185 | floater->mPanelAvatarp->setAvatarID(avatar_id, "", ONLINE_STATUS_NO); |
186 | 186 | ||
187 | } | 187 | } |
188 | 188 | ||
@@ -210,7 +210,7 @@ void LLFloaterAvatarInfo::showFromDirectory(const LLUUID &avatar_id) | |||
210 | floater = new LLFloaterAvatarInfo("avatarinfo", FAI_RECT, | 210 | floater = new LLFloaterAvatarInfo("avatarinfo", FAI_RECT, |
211 | avatar_id); | 211 | avatar_id); |
212 | floater->center(); | 212 | floater->center(); |
213 | floater->mPanelAvatarp->setAvatarID(avatar_id, "", ONLINE_STATUS_UNKNOWN); | 213 | floater->mPanelAvatarp->setAvatarID(avatar_id, "", ONLINE_STATUS_NO); |
214 | floater->open(); | 214 | floater->open(); |
215 | } | 215 | } |
216 | if(floater) | 216 | if(floater) |
diff --git a/linden/indra/newview/llfloaterland.cpp b/linden/indra/newview/llfloaterland.cpp index 22686fb..f19baa9 100644 --- a/linden/indra/newview/llfloaterland.cpp +++ b/linden/indra/newview/llfloaterland.cpp | |||
@@ -1018,8 +1018,8 @@ void LLPanelLandGeneral::onCommitAny(LLUICtrl *ctrl, void *userdata) | |||
1018 | } | 1018 | } |
1019 | 1019 | ||
1020 | // Extract data from UI | 1020 | // Extract data from UI |
1021 | std::string name = panelp->mEditName->getText(); | 1021 | std::string name = panelp->mEditName->getText(); |
1022 | std::string desc = panelp->mEditDesc->getText(); | 1022 | std::string desc = panelp->mEditDesc->getText(); |
1023 | 1023 | ||
1024 | // Valid data from UI | 1024 | // Valid data from UI |
1025 | 1025 | ||
@@ -1123,7 +1123,7 @@ BOOL LLPanelLandObjects::postBuild() | |||
1123 | 1123 | ||
1124 | mCleanOtherObjectsTime = LLUICtrlFactory::getLineEditorByName(this, "clean other time"); | 1124 | mCleanOtherObjectsTime = LLUICtrlFactory::getLineEditorByName(this, "clean other time"); |
1125 | mCleanOtherObjectsTime->setFocusLostCallback(onLostFocus); | 1125 | mCleanOtherObjectsTime->setFocusLostCallback(onLostFocus); |
1126 | childSetPrevalidate("clean other time", LLLineEditor::prevalidatePrintableNotPipe); | 1126 | childSetPrevalidate("clean other time", LLLineEditor::prevalidateNonNegativeS32); |
1127 | childSetUserData("clean other time", this); | 1127 | childSetUserData("clean other time", this); |
1128 | 1128 | ||
1129 | mOwnerListText = LLUICtrlFactory::getTextBoxByName(this, "Object Owners:"); | 1129 | mOwnerListText = LLUICtrlFactory::getTextBoxByName(this, "Object Owners:"); |
diff --git a/linden/indra/newview/llfloaterproperties.cpp b/linden/indra/newview/llfloaterproperties.cpp index abae955..8be2ce5 100644 --- a/linden/indra/newview/llfloaterproperties.cpp +++ b/linden/indra/newview/llfloaterproperties.cpp | |||
@@ -164,6 +164,7 @@ LLFloaterProperties::LLFloaterProperties(const std::string& name, const LLRect& | |||
164 | childSetPrevalidate("LabelItemName",&LLLineEditor::prevalidatePrintableNotPipe); | 164 | childSetPrevalidate("LabelItemName",&LLLineEditor::prevalidatePrintableNotPipe); |
165 | childSetCommitCallback("LabelItemName",onCommitName,this); | 165 | childSetCommitCallback("LabelItemName",onCommitName,this); |
166 | childSetPrevalidate("LabelItemDesc",&LLLineEditor::prevalidatePrintableNotPipe); | 166 | childSetPrevalidate("LabelItemDesc",&LLLineEditor::prevalidatePrintableNotPipe); |
167 | childSetCommitCallback("LabelItemDesc", onCommitDescription, this); | ||
167 | // Creator information | 168 | // Creator information |
168 | childSetAction("BtnCreator",onClickCreator,this); | 169 | childSetAction("BtnCreator",onClickCreator,this); |
169 | // owner information | 170 | // owner information |
diff --git a/linden/indra/newview/llgivemoney.cpp b/linden/indra/newview/llgivemoney.cpp index ce8cc06..d3c7598 100644 --- a/linden/indra/newview/llgivemoney.cpp +++ b/linden/indra/newview/llgivemoney.cpp | |||
@@ -153,7 +153,7 @@ LLFloaterPay::LLFloaterPay(const std::string& name, | |||
153 | 153 | ||
154 | childSetKeystrokeCallback("amount", &LLFloaterPay::onKeystroke, this); | 154 | childSetKeystrokeCallback("amount", &LLFloaterPay::onKeystroke, this); |
155 | childSetText("amount", last_amount); | 155 | childSetText("amount", last_amount); |
156 | childSetPrevalidate("desc", LLLineEditor::prevalidatePositiveS32); | 156 | childSetPrevalidate("amount", LLLineEditor::prevalidatePositiveS32); |
157 | 157 | ||
158 | info = new LLGiveMoneyInfo(this, 0); | 158 | info = new LLGiveMoneyInfo(this, 0); |
159 | mCallbackData.push_back(info); | 159 | mCallbackData.push_back(info); |
@@ -344,7 +344,7 @@ void LLFloaterPay::payDirectly(money_callback callback, | |||
344 | { | 344 | { |
345 | LLFloaterPay *floater = new LLFloaterPay("Give Money", callback, target_id, FALSE); | 345 | LLFloaterPay *floater = new LLFloaterPay("Give Money", callback, target_id, FALSE); |
346 | if (!floater) return; | 346 | if (!floater) return; |
347 | 347 | ||
348 | floater->childSetVisible("amount", TRUE); | 348 | floater->childSetVisible("amount", TRUE); |
349 | floater->childSetVisible("pay btn", TRUE); | 349 | floater->childSetVisible("pay btn", TRUE); |
350 | floater->childSetVisible("amount text", TRUE); | 350 | floater->childSetVisible("amount text", TRUE); |
diff --git a/linden/indra/newview/llhudeffect.cpp b/linden/indra/newview/llhudeffect.cpp index 6343dc3..090895e 100644 --- a/linden/indra/newview/llhudeffect.cpp +++ b/linden/indra/newview/llhudeffect.cpp | |||
@@ -57,6 +57,7 @@ LLHUDEffect::~LLHUDEffect() | |||
57 | void LLHUDEffect::packData(LLMessageSystem *mesgsys) | 57 | void LLHUDEffect::packData(LLMessageSystem *mesgsys) |
58 | { | 58 | { |
59 | mesgsys->addUUIDFast(_PREHASH_ID, mID); | 59 | mesgsys->addUUIDFast(_PREHASH_ID, mID); |
60 | mesgsys->addUUIDFast(_PREHASH_AgentID, gAgent.getID()); | ||
60 | mesgsys->addU8Fast(_PREHASH_Type, mType); | 61 | mesgsys->addU8Fast(_PREHASH_Type, mType); |
61 | mesgsys->addF32Fast(_PREHASH_Duration, mDuration); | 62 | mesgsys->addF32Fast(_PREHASH_Duration, mDuration); |
62 | mesgsys->addBinaryData(_PREHASH_Color, mColor.mV, 4); | 63 | mesgsys->addBinaryData(_PREHASH_Color, mColor.mV, 4); |
diff --git a/linden/indra/newview/llhudmanager.cpp b/linden/indra/newview/llhudmanager.cpp index 2afdac0..bb1c2da 100644 --- a/linden/indra/newview/llhudmanager.cpp +++ b/linden/indra/newview/llhudmanager.cpp | |||
@@ -195,9 +195,13 @@ void LLHUDManager::sendEffects() | |||
195 | } | 195 | } |
196 | if (hep->getNeedsSendToSim() && hep->getOriginatedHere()) | 196 | if (hep->getNeedsSendToSim() && hep->getOriginatedHere()) |
197 | { | 197 | { |
198 | gMessageSystem->newMessageFast(_PREHASH_ViewerEffect); | 198 | LLMessageSystem* msg = gMessageSystem; |
199 | gMessageSystem->nextBlockFast(_PREHASH_Effect); | 199 | msg->newMessageFast(_PREHASH_ViewerEffect); |
200 | hep->packData(gMessageSystem); | 200 | msg->nextBlockFast(_PREHASH_AgentData); |
201 | msg->addUUIDFast(_PREHASH_AgentID, gAgent.getID()); | ||
202 | msg->addUUIDFast(_PREHASH_SessionID, gAgent.getSessionID()); | ||
203 | msg->nextBlockFast(_PREHASH_Effect); | ||
204 | hep->packData(msg); | ||
201 | hep->setNeedsSendToSim(FALSE); | 205 | hep->setNeedsSendToSim(FALSE); |
202 | gAgent.sendMessage(); | 206 | gAgent.sendMessage(); |
203 | } | 207 | } |
diff --git a/linden/indra/newview/llpanelavatar.cpp b/linden/indra/newview/llpanelavatar.cpp index 8ba33a9..c7019e0 100644 --- a/linden/indra/newview/llpanelavatar.cpp +++ b/linden/indra/newview/llpanelavatar.cpp | |||
@@ -419,8 +419,11 @@ BOOL LLPanelAvatarSecondLife::postBuild(void) | |||
419 | childSetVisible("allow_publish",LLPanelAvatar::sAllowFirstLife); | 419 | childSetVisible("allow_publish",LLPanelAvatar::sAllowFirstLife); |
420 | childSetVisible("?",LLPanelAvatar::sAllowFirstLife); | 420 | childSetVisible("?",LLPanelAvatar::sAllowFirstLife); |
421 | 421 | ||
422 | childSetVisible("online_unknown",TRUE); | ||
423 | childSetVisible("online_yes",FALSE); | 422 | childSetVisible("online_yes",FALSE); |
423 | |||
424 | // These are cruft but may still exist in some xml files | ||
425 | // TODO: remove the following 2 lines once translators grab these changes | ||
426 | childSetVisible("online_unknown",FALSE); | ||
424 | childSetVisible("online_no",FALSE); | 427 | childSetVisible("online_no",FALSE); |
425 | 428 | ||
426 | childSetAction("Show on Map", LLPanelAvatar::onClickTrack, mPanelAvatar); | 429 | childSetAction("Show on Map", LLPanelAvatar::onClickTrack, mPanelAvatar); |
@@ -1298,6 +1301,19 @@ void LLPanelAvatar::setAvatar(LLViewerObject *avatarp) | |||
1298 | setAvatarID(avatarp->getID(), name, ONLINE_STATUS_YES); | 1301 | setAvatarID(avatarp->getID(), name, ONLINE_STATUS_YES); |
1299 | } | 1302 | } |
1300 | 1303 | ||
1304 | void LLPanelAvatar::setOnlineStatus(EOnlineStatus online_status) | ||
1305 | { | ||
1306 | // Online status NO could be because they are hidden | ||
1307 | // If they are a friend, we may know the truth! | ||
1308 | if ((ONLINE_STATUS_YES != online_status) | ||
1309 | && mIsFriend | ||
1310 | && (LLAvatarTracker::instance().isBuddyOnline( mAvatarID ))) | ||
1311 | { | ||
1312 | online_status = ONLINE_STATUS_YES; | ||
1313 | } | ||
1314 | |||
1315 | mPanelSecondLife->childSetVisible("online_yes", (online_status == ONLINE_STATUS_YES)); | ||
1316 | } | ||
1301 | 1317 | ||
1302 | void LLPanelAvatar::setAvatarID(const LLUUID &avatar_id, const LLString &name, | 1318 | void LLPanelAvatar::setAvatarID(const LLUUID &avatar_id, const LLString &name, |
1303 | EOnlineStatus online_status) | 1319 | EOnlineStatus online_status) |
@@ -1314,50 +1330,8 @@ void LLPanelAvatar::setAvatarID(const LLUUID &avatar_id, const LLString &name, | |||
1314 | // Determine if we have their calling card. | 1330 | // Determine if we have their calling card. |
1315 | mIsFriend = is_agent_friend(mAvatarID); | 1331 | mIsFriend = is_agent_friend(mAvatarID); |
1316 | 1332 | ||
1317 | if (ONLINE_STATUS_UNKNOWN == online_status) | 1333 | // setOnlineStatus uses mIsFriend |
1318 | { | 1334 | setOnlineStatus(online_status); |
1319 | // Determine if we know that they are online. If we can see them, | ||
1320 | // we know they're online. Likewise, if we have a calling card, | ||
1321 | // we know. Otherwise we don't. | ||
1322 | LLViewerObject* object = gObjectList.findObject( mAvatarID ); | ||
1323 | if (object && !object->isDead()) | ||
1324 | { | ||
1325 | online_status = ONLINE_STATUS_YES; | ||
1326 | } | ||
1327 | else if (mIsFriend) | ||
1328 | { | ||
1329 | if (LLAvatarTracker::instance().isBuddyOnline( mAvatarID )) | ||
1330 | { | ||
1331 | online_status = ONLINE_STATUS_YES; | ||
1332 | } | ||
1333 | else | ||
1334 | { | ||
1335 | online_status = ONLINE_STATUS_NO; | ||
1336 | } | ||
1337 | } | ||
1338 | else | ||
1339 | { | ||
1340 | // Don't actually know if they are online. | ||
1341 | } | ||
1342 | } | ||
1343 | |||
1344 | mPanelSecondLife->childSetVisible("online_unknown",FALSE); | ||
1345 | mPanelSecondLife->childSetVisible("online_yes",FALSE); | ||
1346 | mPanelSecondLife->childSetVisible("online_no",FALSE); | ||
1347 | |||
1348 | switch(online_status) | ||
1349 | { | ||
1350 | case ONLINE_STATUS_YES: | ||
1351 | mPanelSecondLife->childSetVisible("online_yes",TRUE); | ||
1352 | break; | ||
1353 | case ONLINE_STATUS_NO: | ||
1354 | mPanelSecondLife->childSetVisible("online_no",TRUE); | ||
1355 | break; | ||
1356 | case ONLINE_STATUS_UNKNOWN: | ||
1357 | default: | ||
1358 | mPanelSecondLife->childSetVisible("online_unknown",TRUE); | ||
1359 | break; | ||
1360 | } | ||
1361 | 1335 | ||
1362 | BOOL own_avatar = (mAvatarID == gAgent.getID() ); | 1336 | BOOL own_avatar = (mAvatarID == gAgent.getID() ); |
1363 | 1337 | ||
@@ -1755,8 +1729,11 @@ void LLPanelAvatar::processAvatarPropertiesReply(LLMessageSystem *msg, void**) | |||
1755 | //BOOL mature = FALSE; | 1729 | //BOOL mature = FALSE; |
1756 | BOOL identified = FALSE; | 1730 | BOOL identified = FALSE; |
1757 | BOOL transacted = FALSE; | 1731 | BOOL transacted = FALSE; |
1732 | BOOL online = FALSE; | ||
1758 | char profile_url[DB_USER_PROFILE_URL_BUF_SIZE]; | 1733 | char profile_url[DB_USER_PROFILE_URL_BUF_SIZE]; |
1759 | 1734 | ||
1735 | U32 flags = 0x0; | ||
1736 | |||
1760 | //llinfos << "properties packet size " << msg->getReceiveSize() << llendl; | 1737 | //llinfos << "properties packet size " << msg->getReceiveSize() << llendl; |
1761 | 1738 | ||
1762 | msg->getUUIDFast(_PREHASH_AgentData, _PREHASH_AgentID, agent_id); | 1739 | msg->getUUIDFast(_PREHASH_AgentData, _PREHASH_AgentID, agent_id); |
@@ -1776,7 +1753,6 @@ void LLPanelAvatar::processAvatarPropertiesReply(LLMessageSystem *msg, void**) | |||
1776 | { | 1753 | { |
1777 | self->childSetEnabled("Rate...",TRUE); | 1754 | self->childSetEnabled("Rate...",TRUE); |
1778 | } | 1755 | } |
1779 | lldebugs << "!!!!!!!!!!!!!!!!!!!!!!Enabling drop target" << llendl; | ||
1780 | self->childSetEnabled("drop target",TRUE); | 1756 | self->childSetEnabled("drop target",TRUE); |
1781 | 1757 | ||
1782 | self->mHaveProperties = TRUE; | 1758 | self->mHaveProperties = TRUE; |
@@ -1788,9 +1764,17 @@ void LLPanelAvatar::processAvatarPropertiesReply(LLMessageSystem *msg, void**) | |||
1788 | msg->getStringFast(_PREHASH_PropertiesData, _PREHASH_AboutText, DB_USER_ABOUT_BUF_SIZE, about_text ); | 1764 | msg->getStringFast(_PREHASH_PropertiesData, _PREHASH_AboutText, DB_USER_ABOUT_BUF_SIZE, about_text ); |
1789 | msg->getStringFast(_PREHASH_PropertiesData, _PREHASH_FLAboutText, DB_USER_FL_ABOUT_BUF_SIZE, fl_about_text ); | 1765 | msg->getStringFast(_PREHASH_PropertiesData, _PREHASH_FLAboutText, DB_USER_FL_ABOUT_BUF_SIZE, fl_about_text ); |
1790 | msg->getStringFast(_PREHASH_PropertiesData, _PREHASH_BornOn, DB_BORN_BUF_SIZE, born_on); | 1766 | msg->getStringFast(_PREHASH_PropertiesData, _PREHASH_BornOn, DB_BORN_BUF_SIZE, born_on); |
1791 | msg->getBOOLFast(_PREHASH_PropertiesData, _PREHASH_Identified, identified); | ||
1792 | msg->getBOOLFast(_PREHASH_PropertiesData, _PREHASH_Transacted, transacted); | ||
1793 | msg->getString("PropertiesData","ProfileURL", DB_USER_PROFILE_URL_BUF_SIZE, profile_url); | 1767 | msg->getString("PropertiesData","ProfileURL", DB_USER_PROFILE_URL_BUF_SIZE, profile_url); |
1768 | msg->getU32Fast(_PREHASH_PropertiesData, _PREHASH_Flags, flags); | ||
1769 | |||
1770 | identified = (flags & AVATAR_IDENTIFIED); | ||
1771 | transacted = (flags & AVATAR_TRANSACTED); | ||
1772 | allow_publish = (flags & AVATAR_ALLOW_PUBLISH); | ||
1773 | online = (flags & AVATAR_ONLINE); | ||
1774 | |||
1775 | EOnlineStatus online_status = (online) ? ONLINE_STATUS_YES : ONLINE_STATUS_NO; | ||
1776 | |||
1777 | self->setOnlineStatus(online_status); | ||
1794 | 1778 | ||
1795 | self->mPanelWeb->setWebURL(std::string(profile_url)); | 1779 | self->mPanelWeb->setWebURL(std::string(profile_url)); |
1796 | U8 caption_index = 0; | 1780 | U8 caption_index = 0; |
@@ -1868,7 +1852,6 @@ void LLPanelAvatar::processAvatarPropertiesReply(LLMessageSystem *msg, void**) | |||
1868 | { | 1852 | { |
1869 | image_ctrl->setImageAssetID(fl_image_id); | 1853 | image_ctrl->setImageAssetID(fl_image_id); |
1870 | } | 1854 | } |
1871 | msg->getBOOL("PropertiesData", "AllowPublish", allow_publish); | ||
1872 | 1855 | ||
1873 | self->mPanelSecondLife->childSetValue("allow_publish", allow_publish); | 1856 | self->mPanelSecondLife->childSetValue("allow_publish", allow_publish); |
1874 | 1857 | ||
diff --git a/linden/indra/newview/llpanelavatar.h b/linden/indra/newview/llpanelavatar.h index ab08ffb..81cfe02 100644 --- a/linden/indra/newview/llpanelavatar.h +++ b/linden/indra/newview/llpanelavatar.h | |||
@@ -55,7 +55,6 @@ class LLWebBrowserCtrl; | |||
55 | 55 | ||
56 | enum EOnlineStatus | 56 | enum EOnlineStatus |
57 | { | 57 | { |
58 | ONLINE_STATUS_UNKNOWN = -1, | ||
59 | ONLINE_STATUS_NO = 0, | 58 | ONLINE_STATUS_NO = 0, |
60 | ONLINE_STATUS_YES = 1 | 59 | ONLINE_STATUS_YES = 1 |
61 | }; | 60 | }; |
@@ -262,6 +261,8 @@ public: | |||
262 | // Pass one of the ONLINE_STATUS_foo constants above. | 261 | // Pass one of the ONLINE_STATUS_foo constants above. |
263 | void setAvatarID(const LLUUID &avatar_id, const LLString &name, EOnlineStatus online_status); | 262 | void setAvatarID(const LLUUID &avatar_id, const LLString &name, EOnlineStatus online_status); |
264 | 263 | ||
264 | void setOnlineStatus(EOnlineStatus online_status); | ||
265 | |||
265 | const LLUUID& getAvatarID() const { return mAvatarID; } | 266 | const LLUUID& getAvatarID() const { return mAvatarID; } |
266 | 267 | ||
267 | void disableRate(); | 268 | void disableRate(); |
diff --git a/linden/indra/newview/llpaneldirbrowser.cpp b/linden/indra/newview/llpaneldirbrowser.cpp index a7a3895..f701bf4 100644 --- a/linden/indra/newview/llpaneldirbrowser.cpp +++ b/linden/indra/newview/llpaneldirbrowser.cpp | |||
@@ -316,14 +316,8 @@ void LLPanelDirBrowser::onCommitList(LLUICtrl* ctrl, void* data) | |||
316 | 316 | ||
317 | switch(type) | 317 | switch(type) |
318 | { | 318 | { |
319 | // These are both people searches. Let the panel decide if they are online or offline. | ||
319 | case ONLINE_CODE: | 320 | case ONLINE_CODE: |
320 | if (self->mFloaterDirectory && self->mFloaterDirectory->mPanelAvatarp) | ||
321 | { | ||
322 | self->mFloaterDirectory->mPanelAvatarp->setVisible(TRUE); | ||
323 | self->mFloaterDirectory->mPanelAvatarp->setAvatarID(id, name, ONLINE_STATUS_YES); | ||
324 | self->mFloaterDirectory->mPanelAvatarp->disableRate(); | ||
325 | } | ||
326 | break; | ||
327 | case OFFLINE_CODE: | 321 | case OFFLINE_CODE: |
328 | if (self->mFloaterDirectory && self->mFloaterDirectory->mPanelAvatarp) | 322 | if (self->mFloaterDirectory && self->mFloaterDirectory->mPanelAvatarp) |
329 | { | 323 | { |
@@ -409,7 +403,6 @@ void LLPanelDirBrowser::processDirPeopleReply(LLMessageSystem *msg, void**) | |||
409 | char first_name[DB_FIRST_NAME_BUF_SIZE]; | 403 | char first_name[DB_FIRST_NAME_BUF_SIZE]; |
410 | char last_name[DB_LAST_NAME_BUF_SIZE]; | 404 | char last_name[DB_LAST_NAME_BUF_SIZE]; |
411 | LLUUID agent_id; | 405 | LLUUID agent_id; |
412 | U8 online; | ||
413 | 406 | ||
414 | msg->getUUIDFast(_PREHASH_QueryData,_PREHASH_QueryID, query_id); | 407 | msg->getUUIDFast(_PREHASH_QueryData,_PREHASH_QueryID, query_id); |
415 | 408 | ||
@@ -445,7 +438,7 @@ void LLPanelDirBrowser::processDirPeopleReply(LLMessageSystem *msg, void**) | |||
445 | msg->getStringFast(_PREHASH_QueryReplies,_PREHASH_FirstName, DB_FIRST_NAME_BUF_SIZE, first_name, i); | 438 | msg->getStringFast(_PREHASH_QueryReplies,_PREHASH_FirstName, DB_FIRST_NAME_BUF_SIZE, first_name, i); |
446 | msg->getStringFast(_PREHASH_QueryReplies,_PREHASH_LastName, DB_LAST_NAME_BUF_SIZE, last_name, i); | 439 | msg->getStringFast(_PREHASH_QueryReplies,_PREHASH_LastName, DB_LAST_NAME_BUF_SIZE, last_name, i); |
447 | msg->getUUIDFast( _PREHASH_QueryReplies,_PREHASH_AgentID, agent_id, i); | 440 | msg->getUUIDFast( _PREHASH_QueryReplies,_PREHASH_AgentID, agent_id, i); |
448 | msg->getU8Fast( _PREHASH_QueryReplies,_PREHASH_Online, online, i); | 441 | // msg->getU8Fast( _PREHASH_QueryReplies,_PREHASH_Online, online, i); |
449 | // unused | 442 | // unused |
450 | // msg->getStringFast(_PREHASH_QueryReplies,_PREHASH_Group, DB_GROUP_NAME_BUF_SIZE, group, i); | 443 | // msg->getStringFast(_PREHASH_QueryReplies,_PREHASH_Group, DB_GROUP_NAME_BUF_SIZE, group, i); |
451 | // msg->getS32Fast( _PREHASH_QueryReplies,_PREHASH_Reputation, reputation, i); | 444 | // msg->getS32Fast( _PREHASH_QueryReplies,_PREHASH_Reputation, reputation, i); |
@@ -461,24 +454,14 @@ void LLPanelDirBrowser::processDirPeopleReply(LLMessageSystem *msg, void**) | |||
461 | row["id"] = agent_id; | 454 | row["id"] = agent_id; |
462 | 455 | ||
463 | LLUUID image_id; | 456 | LLUUID image_id; |
464 | if (online) | 457 | // We don't show online status in the finder anymore, |
465 | { | 458 | // so just use the 'offline' icon as the generic 'person' icon |
466 | image_id.set( gViewerArt.getString("icon_avatar_online.tga") ); | 459 | image_id.set( gViewerArt.getString("icon_avatar_offline.tga") ); |
467 | row["columns"][0]["column"] = "icon"; | 460 | row["columns"][0]["column"] = "icon"; |
468 | row["columns"][0]["type"] = "icon"; | 461 | row["columns"][0]["type"] = "icon"; |
469 | row["columns"][0]["value"] = image_id; | 462 | row["columns"][0]["value"] = image_id; |
470 | |||
471 | content["type"] = ONLINE_CODE; | ||
472 | } | ||
473 | else | ||
474 | { | ||
475 | image_id.set( gViewerArt.getString("icon_avatar_offline.tga") ); | ||
476 | row["columns"][0]["column"] = "icon"; | ||
477 | row["columns"][0]["type"] = "icon"; | ||
478 | row["columns"][0]["value"] = image_id; | ||
479 | 463 | ||
480 | content["type"] = OFFLINE_CODE; | 464 | content["type"] = OFFLINE_CODE; |
481 | } | ||
482 | 465 | ||
483 | LLString fullname = LLString(first_name) + " " + LLString(last_name); | 466 | LLString fullname = LLString(first_name) + " " + LLString(last_name); |
484 | row["columns"][1]["column"] = "name"; | 467 | row["columns"][1]["column"] = "name"; |
@@ -487,19 +470,6 @@ void LLPanelDirBrowser::processDirPeopleReply(LLMessageSystem *msg, void**) | |||
487 | 470 | ||
488 | content["name"] = fullname; | 471 | content["name"] = fullname; |
489 | 472 | ||
490 | if (online) | ||
491 | { | ||
492 | row["columns"][2]["column"] = "online"; | ||
493 | row["columns"][2]["value"] = "yes"; | ||
494 | row["columns"][2]["font"] = "SANSSERIFSMALL"; | ||
495 | } | ||
496 | else | ||
497 | { | ||
498 | row["columns"][2]["column"] = "online"; | ||
499 | row["columns"][2]["value"] = "no"; | ||
500 | row["columns"][2]["font"] = "SANSSERIFSMALL"; | ||
501 | } | ||
502 | |||
503 | list->addElement(row); | 473 | list->addElement(row); |
504 | 474 | ||
505 | LLString id_str = agent_id.getString(); | 475 | LLString id_str = agent_id.getString(); |
diff --git a/linden/indra/newview/llpaneldirpeople.cpp b/linden/indra/newview/llpaneldirpeople.cpp index 87b3582..1fe1570 100644 --- a/linden/indra/newview/llpaneldirpeople.cpp +++ b/linden/indra/newview/llpaneldirpeople.cpp | |||
@@ -71,11 +71,6 @@ void LLPanelDirPeople::performQuery() | |||
71 | setupNewSearch(); | 71 | setupNewSearch(); |
72 | 72 | ||
73 | U32 scope = DFQ_PEOPLE; | 73 | U32 scope = DFQ_PEOPLE; |
74 | if (childGetValue("online check").asBoolean()) | ||
75 | { | ||
76 | llinfos << "Online only people search." << llendl; | ||
77 | scope |= DFQ_ONLINE; | ||
78 | } | ||
79 | 74 | ||
80 | // send the message | 75 | // send the message |
81 | sendDirFindQuery( | 76 | sendDirFindQuery( |
diff --git a/linden/indra/newview/llprefsim.cpp b/linden/indra/newview/llprefsim.cpp index 12ca0b1..383fe76 100644 --- a/linden/indra/newview/llprefsim.cpp +++ b/linden/indra/newview/llprefsim.cpp | |||
@@ -34,7 +34,7 @@ | |||
34 | #include "llcheckboxctrl.h" | 34 | #include "llcheckboxctrl.h" |
35 | #include "llstring.h" | 35 | #include "llstring.h" |
36 | #include "lltexteditor.h" | 36 | #include "lltexteditor.h" |
37 | 37 | #include "llavatarconstants.h" | |
38 | #include "llagent.h" | 38 | #include "llagent.h" |
39 | #include "llviewercontrol.h" | 39 | #include "llviewercontrol.h" |
40 | #include "llviewernetwork.h" | 40 | #include "llviewernetwork.h" |
@@ -42,9 +42,6 @@ | |||
42 | 42 | ||
43 | #include "lldirpicker.h" | 43 | #include "lldirpicker.h" |
44 | 44 | ||
45 | static const std::string VISIBILITY_DEFAULT("default"); | ||
46 | static const std::string VISIBILITY_HIDDEN("hidden"); | ||
47 | |||
48 | class LLPrefsIMImpl : public LLPanel | 45 | class LLPrefsIMImpl : public LLPanel |
49 | { | 46 | { |
50 | public: | 47 | public: |
@@ -77,7 +74,7 @@ protected: | |||
77 | bool mOriginalIMViaEmail; | 74 | bool mOriginalIMViaEmail; |
78 | 75 | ||
79 | // online status info | 76 | // online status info |
80 | bool mOriginalShowOnline; | 77 | bool mOriginalHideOnlineStatus; |
81 | std::string mDirectoryVisibility; | 78 | std::string mDirectoryVisibility; |
82 | }; | 79 | }; |
83 | 80 | ||
@@ -112,7 +109,7 @@ void LLPrefsIMImpl::cancel() | |||
112 | 109 | ||
113 | BOOL LLPrefsIMImpl::postBuild() | 110 | BOOL LLPrefsIMImpl::postBuild() |
114 | { | 111 | { |
115 | requires("directory_visibility"); | 112 | requires("online_visibility"); |
116 | requires("send_im_to_email"); | 113 | requires("send_im_to_email"); |
117 | if (!checkRequirements()) | 114 | if (!checkRequirements()) |
118 | { | 115 | { |
@@ -121,11 +118,11 @@ BOOL LLPrefsIMImpl::postBuild() | |||
121 | 118 | ||
122 | mGotPersonalInfo = false; | 119 | mGotPersonalInfo = false; |
123 | mOriginalIMViaEmail = false; | 120 | mOriginalIMViaEmail = false; |
124 | mOriginalShowOnline = false; | 121 | mOriginalHideOnlineStatus = true; |
125 | childSetLabelArg("send_im_to_email", "[EMAIL]", childGetText("log_in_to_change")); | 122 | childSetLabelArg("send_im_to_email", "[EMAIL]", childGetText("log_in_to_change")); |
126 | 123 | ||
127 | // Don't enable this until we get personal data | 124 | // Don't enable this until we get personal data |
128 | childDisable("directory_visibility"); | 125 | childDisable("online_visibility"); |
129 | childDisable("send_im_to_email"); | 126 | childDisable("send_im_to_email"); |
130 | childDisable("log_instant_messages"); | 127 | childDisable("log_instant_messages"); |
131 | childDisable("log_chat"); | 128 | childDisable("log_chat"); |
@@ -189,10 +186,10 @@ void LLPrefsIMImpl::apply() | |||
189 | LLFile::mkdir(gDirUtilp->getPerAccountChatLogsDir().c_str()); | 186 | LLFile::mkdir(gDirUtilp->getPerAccountChatLogsDir().c_str()); |
190 | 187 | ||
191 | bool new_im_via_email = childGetValue("send_im_to_email").asBoolean(); | 188 | bool new_im_via_email = childGetValue("send_im_to_email").asBoolean(); |
192 | bool new_show_online = childGetValue("directory_visibility").asBoolean(); | 189 | bool new_hide_online = childGetValue("online_visibility").asBoolean(); |
193 | 190 | ||
194 | if((new_im_via_email != mOriginalIMViaEmail) | 191 | if((new_im_via_email != mOriginalIMViaEmail) |
195 | ||(new_show_online != mOriginalShowOnline)) | 192 | ||(new_hide_online != mOriginalHideOnlineStatus)) |
196 | { | 193 | { |
197 | LLMessageSystem* msg = gMessageSystem; | 194 | LLMessageSystem* msg = gMessageSystem; |
198 | msg->newMessageFast(_PREHASH_UpdateUserInfo); | 195 | msg->newMessageFast(_PREHASH_UpdateUserInfo); |
@@ -206,12 +203,12 @@ void LLPrefsIMImpl::apply() | |||
206 | // can only select between 2 values, we represent it as a | 203 | // can only select between 2 values, we represent it as a |
207 | // checkbox. This breaks down a little bit for liaisons, but | 204 | // checkbox. This breaks down a little bit for liaisons, but |
208 | // works out in the end. | 205 | // works out in the end. |
209 | if(new_show_online != mOriginalShowOnline) | 206 | if(new_hide_online != mOriginalHideOnlineStatus) |
210 | { | 207 | { |
211 | if(new_show_online) mDirectoryVisibility = VISIBILITY_DEFAULT; | 208 | if(new_hide_online) mDirectoryVisibility = VISIBILITY_HIDDEN; |
212 | else mDirectoryVisibility = VISIBILITY_HIDDEN; | 209 | else mDirectoryVisibility = VISIBILITY_DEFAULT; |
213 | //Update showonline value, otherwise multiple applys won't work | 210 | //Update showonline value, otherwise multiple applys won't work |
214 | mOriginalShowOnline = new_show_online; | 211 | mOriginalHideOnlineStatus = new_hide_online; |
215 | } | 212 | } |
216 | msg->addString("DirectoryVisibility", mDirectoryVisibility); | 213 | msg->addString("DirectoryVisibility", mDirectoryVisibility); |
217 | gAgent.sendReliableMessage(); | 214 | gAgent.sendReliableMessage(); |
@@ -229,20 +226,20 @@ void LLPrefsIMImpl::setPersonalInfo( | |||
229 | mDirectoryVisibility = visibility; | 226 | mDirectoryVisibility = visibility; |
230 | if(visibility == VISIBILITY_DEFAULT) | 227 | if(visibility == VISIBILITY_DEFAULT) |
231 | { | 228 | { |
232 | mOriginalShowOnline = true; | 229 | mOriginalHideOnlineStatus = false; |
233 | childEnable("directory_visibility"); | 230 | childEnable("online_visibility"); |
234 | } | 231 | } |
235 | else if(visibility == VISIBILITY_HIDDEN) | 232 | else if(visibility == VISIBILITY_HIDDEN) |
236 | { | 233 | { |
237 | mOriginalShowOnline = false; | 234 | mOriginalHideOnlineStatus = true; |
238 | childEnable("directory_visibility"); | 235 | childEnable("online_visibility"); |
239 | } | 236 | } |
240 | else | 237 | else |
241 | { | 238 | { |
242 | mOriginalShowOnline = false; | 239 | mOriginalHideOnlineStatus = true; |
243 | } | 240 | } |
244 | childSetValue("directory_visibility", mOriginalShowOnline); | 241 | childSetValue("online_visibility", mOriginalHideOnlineStatus); |
245 | childSetLabelArg("directory_visibility", "[DIR_VIS]", mDirectoryVisibility); | 242 | childSetLabelArg("online_visibility", "[DIR_VIS]", mDirectoryVisibility); |
246 | childEnable("send_im_to_email"); | 243 | childEnable("send_im_to_email"); |
247 | childSetValue("send_im_to_email", im_via_email); | 244 | childSetValue("send_im_to_email", im_via_email); |
248 | childEnable("log_instant_messages"); | 245 | childEnable("log_instant_messages"); |
diff --git a/linden/indra/newview/llviewermenu.cpp b/linden/indra/newview/llviewermenu.cpp index 3e5063e..ab400de 100644 --- a/linden/indra/newview/llviewermenu.cpp +++ b/linden/indra/newview/llviewermenu.cpp | |||
@@ -581,21 +581,21 @@ void init_menus() | |||
581 | // flash when an item is triggered (the flash occurs in the holder) | 581 | // flash when an item is triggered (the flash occurs in the holder) |
582 | gViewerWindow->getRootView()->addChild(gMenuHolder); | 582 | gViewerWindow->getRootView()->addChild(gMenuHolder); |
583 | 583 | ||
584 | gMenuHolder->childSetLabelArg("Upload Image", "[COST]", "10"); | 584 | gMenuHolder->childSetLabelArg("Upload Image", "[COST]", "10"); |
585 | gMenuHolder->childSetLabelArg("Upload Sound", "[COST]", "10"); | 585 | gMenuHolder->childSetLabelArg("Upload Sound", "[COST]", "10"); |
586 | gMenuHolder->childSetLabelArg("Upload Animation", "[COST]", "10"); | 586 | gMenuHolder->childSetLabelArg("Upload Animation", "[COST]", "10"); |
587 | gMenuHolder->childSetLabelArg("Bulk Upload", "[COST]", "10"); | 587 | gMenuHolder->childSetLabelArg("Bulk Upload", "[COST]", "10"); |
588 | 588 | ||
589 | gAFKMenu = (LLMenuItemCallGL*)gMenuBarView->getChildByName("Set Away", TRUE); | 589 | gAFKMenu = (LLMenuItemCallGL*)gMenuBarView->getChildByName("Set Away", TRUE); |
590 | gBusyMenu = (LLMenuItemCallGL*)gMenuBarView->getChildByName("Set Busy", TRUE); | 590 | gBusyMenu = (LLMenuItemCallGL*)gMenuBarView->getChildByName("Set Busy", TRUE); |
591 | gAttachSubMenu = gMenuBarView->getChildMenuByName("Attach Object", TRUE); | 591 | gAttachSubMenu = gMenuBarView->getChildMenuByName("Attach Object", TRUE); |
592 | gDetachSubMenu = gMenuBarView->getChildMenuByName("Detach Object", TRUE); | 592 | gDetachSubMenu = gMenuBarView->getChildMenuByName("Detach Object", TRUE); |
593 | 593 | ||
594 | if (gAgent.mAccess < SIM_ACCESS_MATURE) | 594 | if (gAgent.mAccess < SIM_ACCESS_MATURE) |
595 | { | 595 | { |
596 | gMenuBarView->getChildByName("Menu Underpants", TRUE)->setVisible(FALSE); | 596 | gMenuBarView->getChildByName("Menu Underpants", TRUE)->setVisible(FALSE); |
597 | gMenuBarView->getChildByName("Menu Undershirt", TRUE)->setVisible(FALSE); | 597 | gMenuBarView->getChildByName("Menu Undershirt", TRUE)->setVisible(FALSE); |
598 | } | 598 | } |
599 | 599 | ||
600 | // TomY TODO convert these two | 600 | // TomY TODO convert these two |
601 | LLMenuGL*menu; | 601 | LLMenuGL*menu; |
@@ -626,23 +626,23 @@ void init_menus() | |||
626 | /// | 626 | /// |
627 | gPieSelf = gUICtrlFactory->buildPieMenu("menu_pie_self.xml", gMenuHolder); | 627 | gPieSelf = gUICtrlFactory->buildPieMenu("menu_pie_self.xml", gMenuHolder); |
628 | 628 | ||
629 | // TomY TODO: what shall we do about these? | 629 | // TomY TODO: what shall we do about these? |
630 | gDetachScreenPieMenu = (LLPieMenu*)gMenuHolder->getChildByName("Object Detach HUD", true); | 630 | gDetachScreenPieMenu = (LLPieMenu*)gMenuHolder->getChildByName("Object Detach HUD", true); |
631 | gDetachPieMenu = (LLPieMenu*)gMenuHolder->getChildByName("Object Detach", true); | 631 | gDetachPieMenu = (LLPieMenu*)gMenuHolder->getChildByName("Object Detach", true); |
632 | 632 | ||
633 | if (gAgent.mAccess < SIM_ACCESS_MATURE) | 633 | if (gAgent.mAccess < SIM_ACCESS_MATURE) |
634 | { | 634 | { |
635 | gMenuHolder->getChildByName("Self Underpants", TRUE)->setVisible(FALSE); | 635 | gMenuHolder->getChildByName("Self Underpants", TRUE)->setVisible(FALSE); |
636 | gMenuHolder->getChildByName("Self Undershirt", TRUE)->setVisible(FALSE); | 636 | gMenuHolder->getChildByName("Self Undershirt", TRUE)->setVisible(FALSE); |
637 | } | 637 | } |
638 | 638 | ||
639 | gPieAvatar = gUICtrlFactory->buildPieMenu("menu_pie_avatar.xml", gMenuHolder); | 639 | gPieAvatar = gUICtrlFactory->buildPieMenu("menu_pie_avatar.xml", gMenuHolder); |
640 | 640 | ||
641 | gPieObject = gUICtrlFactory->buildPieMenu("menu_pie_object.xml", gMenuHolder); | 641 | gPieObject = gUICtrlFactory->buildPieMenu("menu_pie_object.xml", gMenuHolder); |
642 | 642 | ||
643 | gAttachScreenPieMenu = (LLPieMenu*)gMenuHolder->getChildByName("Object Attach HUD", true); | 643 | gAttachScreenPieMenu = (LLPieMenu*)gMenuHolder->getChildByName("Object Attach HUD", true); |
644 | gAttachPieMenu = (LLPieMenu*)gMenuHolder->getChildByName("Object Attach", true); | 644 | gAttachPieMenu = (LLPieMenu*)gMenuHolder->getChildByName("Object Attach", true); |
645 | gPieRate = (LLPieMenu*)gMenuHolder->getChildByName("Rate Menu", true); | 645 | gPieRate = (LLPieMenu*)gMenuHolder->getChildByName("Rate Menu", true); |
646 | 646 | ||
647 | gPieAttachment = gUICtrlFactory->buildPieMenu("menu_pie_attachment.xml", gMenuHolder); | 647 | gPieAttachment = gUICtrlFactory->buildPieMenu("menu_pie_attachment.xml", gMenuHolder); |
648 | 648 | ||
diff --git a/linden/indra/newview/llviewermessage.cpp b/linden/indra/newview/llviewermessage.cpp index 124ae13..1b91f9d 100644 --- a/linden/indra/newview/llviewermessage.cpp +++ b/linden/indra/newview/llviewermessage.cpp | |||
@@ -3906,7 +3906,7 @@ void process_alert_core(const char* buffer, BOOL modal) | |||
3906 | { | 3906 | { |
3907 | //XUI:translate | 3907 | //XUI:translate |
3908 | LLString::format_map_t args; | 3908 | LLString::format_map_t args; |
3909 | args["[BUFFER]"] = buffer; | 3909 | args["[ERROR_MESSAGE]"] = buffer; |
3910 | gViewerWindow->alertXml("ErrorMessage", args); | 3910 | gViewerWindow->alertXml("ErrorMessage", args); |
3911 | } | 3911 | } |
3912 | else | 3912 | else |
diff --git a/linden/indra/newview/releasenotes.txt b/linden/indra/newview/releasenotes.txt index 4cce794..01f16b3 100644 --- a/linden/indra/newview/releasenotes.txt +++ b/linden/indra/newview/releasenotes.txt | |||
@@ -1,3 +1,15 @@ | |||
1 | Release Notes for Second Life 1.13.3(2) January 30, 2007 | ||
2 | ===================================== | ||
3 | Changes: | ||
4 | * It is no longer possible to only search for online residents | ||
5 | * Online status is no longer indicated in the Search -> People results list | ||
6 | ** The online status inside the profile shows 'Currently Online' or remains blank | ||
7 | *** Friends can see your Online status if you give permission via the Friends list | ||
8 | *** Anyone can see your Online status if 'Make my online status visible only to my Friends' is unchecked | ||
9 | |||
10 | Bug fixes: | ||
11 | * Fixed script email across simulators | ||
12 | |||
1 | Release Notes for Second Life 1.13.2(15) January 25, 2007 | 13 | Release Notes for Second Life 1.13.2(15) January 25, 2007 |
2 | ===================================== | 14 | ===================================== |
3 | Changes: | 15 | Changes: |
diff --git a/linden/indra/newview/res/newViewRes.rc b/linden/indra/newview/res/newViewRes.rc index cf7b935..41c2af1 100644 --- a/linden/indra/newview/res/newViewRes.rc +++ b/linden/indra/newview/res/newViewRes.rc | |||
@@ -227,8 +227,8 @@ TOOLPIPETTE CURSOR "toolpipette.cur" | |||
227 | // | 227 | // |
228 | 228 | ||
229 | VS_VERSION_INFO VERSIONINFO | 229 | VS_VERSION_INFO VERSIONINFO |
230 | FILEVERSION 1,13,2,15 | 230 | FILEVERSION 1,13,3,2 |
231 | PRODUCTVERSION 1,13,2,0 | 231 | PRODUCTVERSION 1,13,3,2 |
232 | FILEFLAGSMASK 0x3fL | 232 | FILEFLAGSMASK 0x3fL |
233 | #ifdef _DEBUG | 233 | #ifdef _DEBUG |
234 | FILEFLAGS 0x1L | 234 | FILEFLAGS 0x1L |
@@ -245,12 +245,12 @@ BEGIN | |||
245 | BEGIN | 245 | BEGIN |
246 | VALUE "CompanyName", "Linden Lab" | 246 | VALUE "CompanyName", "Linden Lab" |
247 | VALUE "FileDescription", "Second Life" | 247 | VALUE "FileDescription", "Second Life" |
248 | VALUE "FileVersion", "1.13.2.15" | 248 | VALUE "FileVersion", "1.13.3.57442" |
249 | VALUE "InternalName", "Second Life" | 249 | VALUE "InternalName", "Second Life" |
250 | VALUE "LegalCopyright", "Copyright © 2001-2006, Linden Research, Inc." | 250 | VALUE "LegalCopyright", "Copyright © 2001-2006, Linden Research, Inc." |
251 | VALUE "OriginalFilename", "SecondLife.exe" | 251 | VALUE "OriginalFilename", "SecondLife.exe" |
252 | VALUE "ProductName", "Second Life" | 252 | VALUE "ProductName", "Second Life" |
253 | VALUE "ProductVersion", "1.13.2.0" | 253 | VALUE "ProductVersion", "1.13.3.57442" |
254 | END | 254 | END |
255 | END | 255 | END |
256 | BLOCK "VarFileInfo" | 256 | BLOCK "VarFileInfo" |
diff --git a/linden/indra/newview/skins/xui/en-us/floater_directory.xml b/linden/indra/newview/skins/xui/en-us/floater_directory.xml index 8056aa9..8184fdb 100644 --- a/linden/indra/newview/skins/xui/en-us/floater_directory.xml +++ b/linden/indra/newview/skins/xui/en-us/floater_directory.xml | |||
@@ -464,12 +464,9 @@ To buy direct, visit the land and click on the place name in the title bar. | |||
464 | </text> | 464 | </text> |
465 | <line_editor bevel_style="in" border_style="line" border_thickness="1" bottom="-24" | 465 | <line_editor bevel_style="in" border_style="line" border_thickness="1" bottom="-24" |
466 | follows="left|top" font="SansSerif" height="18" left_delta="38" | 466 | follows="left|top" font="SansSerif" height="18" left_delta="38" |
467 | max_length="63" mouse_opaque="true" name="name" width="128" /> | 467 | max_length="63" mouse_opaque="true" name="name" width="200" /> |
468 | <check_box bottom="-24" control_name="FindPeopleOnline" follows="left|top" | ||
469 | font="SansSerifSmall" height="18" initial_value="true" label="Online" | ||
470 | left_delta="136" mouse_opaque="true" name="online check" width="70" /> | ||
471 | <button bottom="-26" follows="left|top" font="SansSerif" halign="center" height="20" | 468 | <button bottom="-26" follows="left|top" font="SansSerif" halign="center" height="20" |
472 | label="Search" label_selected="Search" left_delta="78" mouse_opaque="true" | 469 | label="Search" label_selected="Search" left_delta="210" mouse_opaque="true" |
473 | name="Search" width="70" /> | 470 | name="Search" width="70" /> |
474 | <scroll_list background_visible="false" bottom="-513" column_padding="0" draw_border="true" | 471 | <scroll_list background_visible="false" bottom="-513" column_padding="0" draw_border="true" |
475 | draw_heading="true" fg_disable_color="1, 1, 1, 1" | 472 | draw_heading="true" fg_disable_color="1, 1, 1, 1" |
@@ -478,8 +475,7 @@ To buy direct, visit the land and click on the place name in the title bar. | |||
478 | multi_select="false" name="results" search_column="2" width="326"> | 475 | multi_select="false" name="results" search_column="2" width="326"> |
479 | <column label="" name="icon" width="24" /> | 476 | <column label="" name="icon" width="24" /> |
480 | <column label="" name="type" width="-1" /> | 477 | <column label="" name="type" width="-1" /> |
481 | <column label="Name" name="name" width="174" /> | 478 | <column label="Name" name="name" width="274" /> |
482 | <column label="Online" name="online" width="100" /> | ||
483 | </scroll_list> | 479 | </scroll_list> |
484 | <text bg_visible="false" border_drop_shadow_visible="false" border_visible="false" | 480 | <text bg_visible="false" border_drop_shadow_visible="false" border_visible="false" |
485 | bottom_delta="-20" drop_shadow_visible="true" follows="left|bottom" | 481 | bottom_delta="-20" drop_shadow_visible="true" follows="left|bottom" |
diff --git a/linden/indra/newview/skins/xui/en-us/panel_avatar.xml b/linden/indra/newview/skins/xui/en-us/panel_avatar.xml index f285008..1cc6f54 100644 --- a/linden/indra/newview/skins/xui/en-us/panel_avatar.xml +++ b/linden/indra/newview/skins/xui/en-us/panel_avatar.xml | |||
@@ -42,21 +42,9 @@ | |||
42 | text_readonly_color="1, 1, 1, 1" width="180" /> | 42 | text_readonly_color="1, 1, 1, 1" width="180" /> |
43 | <text bg_visible="false" border_drop_shadow_visible="false" border_visible="false" | 43 | <text bg_visible="false" border_drop_shadow_visible="false" border_visible="false" |
44 | bottom="-24" drop_shadow_visible="true" follows="left|top" | 44 | bottom="-24" drop_shadow_visible="true" follows="left|top" |
45 | font="SansSerifSmall" h_pad="0" halign="left" height="16" left_delta="200" | 45 | font="SansSerifsmall" h_pad="0" halign="left" height="16" left_delta="200" |
46 | mouse_opaque="true" name="online_yes" v_pad="0" width="130"> | 46 | mouse_opaque="true" name="online_yes" v_pad="0" width="130"> |
47 | Online: Yes | 47 | Currently Online |
48 | </text> | ||
49 | <text bg_visible="false" border_drop_shadow_visible="false" border_visible="false" | ||
50 | bottom="-24" drop_shadow_visible="true" follows="left|top" | ||
51 | font="SansSerifSmall" h_pad="0" halign="left" height="16" left_delta="0" | ||
52 | mouse_opaque="true" name="online_no" v_pad="0" width="130"> | ||
53 | Online: No | ||
54 | </text> | ||
55 | <text bg_visible="false" border_drop_shadow_visible="false" border_visible="false" | ||
56 | bottom="-24" drop_shadow_visible="true" follows="left|top" | ||
57 | font="SansSerifSmall" h_pad="0" halign="left" height="16" left_delta="0" | ||
58 | mouse_opaque="true" name="online_unknown" v_pad="0" width="130"> | ||
59 | Online: Unknown | ||
60 | </text> | 48 | </text> |
61 | <text bg_visible="false" border_drop_shadow_visible="false" border_visible="false" | 49 | <text bg_visible="false" border_drop_shadow_visible="false" border_visible="false" |
62 | bottom_delta="-20" drop_shadow_visible="true" follows="left|top" | 50 | bottom_delta="-20" drop_shadow_visible="true" follows="left|top" |
diff --git a/linden/indra/newview/skins/xui/en-us/panel_preferences_im.xml b/linden/indra/newview/skins/xui/en-us/panel_preferences_im.xml index 5214ece..e787d2a 100644 --- a/linden/indra/newview/skins/xui/en-us/panel_preferences_im.xml +++ b/linden/indra/newview/skins/xui/en-us/panel_preferences_im.xml | |||
@@ -6,12 +6,12 @@ | |||
6 | bottom="-20" drop_shadow_visible="true" enabled="true" follows="left|top" | 6 | bottom="-20" drop_shadow_visible="true" enabled="true" follows="left|top" |
7 | font="SansSerifSmall" h_pad="0" halign="left" height="10" hidden="false" | 7 | font="SansSerifSmall" h_pad="0" halign="left" height="10" hidden="false" |
8 | left="12" mouse_opaque="false" name="text_box" v_pad="0" width="128"> | 8 | left="12" mouse_opaque="false" name="text_box" v_pad="0" width="128"> |
9 | Online Status in Search: | 9 | Profile Online Status: |
10 | </text> | 10 | </text> |
11 | <check_box bottom="-25" enabled="true" follows="left|top" font="SansSerifSmall" | 11 | <check_box bottom="-25" enabled="true" follows="left|top" font="SansSerifSmall" |
12 | height="16" hidden="false" initial_value="false" | 12 | height="16" hidden="false" initial_value="false" |
13 | label="Make my online status visible in Search" left="148" mouse_opaque="true" | 13 | label="Make my online status visible only to my Friends" left="148" mouse_opaque="true" |
14 | name="directory_visibility" radio_style="false" width="350" /> | 14 | name="online_visibility" radio_style="false" width="350" /> |
15 | <text type="string" length="1" bg_visible="false" border_drop_shadow_visible="false" border_visible="false" | 15 | <text type="string" length="1" bg_visible="false" border_drop_shadow_visible="false" border_visible="false" |
16 | bottom="-40" drop_shadow_visible="true" enabled="true" follows="left|top" | 16 | bottom="-40" drop_shadow_visible="true" enabled="true" follows="left|top" |
17 | font="SansSerifSmall" h_pad="0" halign="left" height="10" hidden="false" | 17 | font="SansSerifSmall" h_pad="0" halign="left" height="10" hidden="false" |
diff --git a/linden/scripts/messages/message_template.msg b/linden/scripts/messages/message_template.msg index b44b099..32a5145 100644 --- a/linden/scripts/messages/message_template.msg +++ b/linden/scripts/messages/message_template.msg | |||
@@ -4260,10 +4260,7 @@ sim -> dataserver | |||
4260 | { BornOn Variable 1 } // string | 4260 | { BornOn Variable 1 } // string |
4261 | { ProfileURL Variable 1 } // string | 4261 | { ProfileURL Variable 1 } // string |
4262 | { CharterMember Variable 1 } // special - usually U8 | 4262 | { CharterMember Variable 1 } // special - usually U8 |
4263 | { AllowPublish BOOL } // whether profile is externally visible or not | 4263 | { Flags U32 } |
4264 | { MaturePublish BOOL } // profile is "mature" | ||
4265 | { Identified BOOL } // whether avatar has provided payment info | ||
4266 | { Transacted BOOL } // whether avatar has actively used payment info | ||
4267 | } | 4264 | } |
4268 | } | 4265 | } |
4269 | 4266 | ||
@@ -9196,11 +9193,20 @@ sim -> dataserver | |||
9196 | 9193 | ||
9197 | // ViewerEffect | 9194 | // ViewerEffect |
9198 | // Viewer side effect that's sent from one viewer, and broadcast to other agents nearby | 9195 | // Viewer side effect that's sent from one viewer, and broadcast to other agents nearby |
9196 | // viewer-->sim (single effect created by viewer) | ||
9197 | // sim-->viewer (multiple effects that can be seen by viewer) | ||
9198 | // the AgentData block used for authentication for viewer-->sim messages | ||
9199 | { | 9199 | { |
9200 | ViewerEffect Medium NotTrusted Zerocoded | 9200 | ViewerEffect Medium NotTrusted Zerocoded |
9201 | { | 9201 | { |
9202 | AgentData Single | ||
9203 | { AgentID LLUUID } | ||
9204 | { SessionID LLUUID } | ||
9205 | } | ||
9206 | { | ||
9202 | Effect Variable | 9207 | Effect Variable |
9203 | { ID LLUUID } // UUID of the effect | 9208 | { ID LLUUID } // unique UUID of the effect |
9209 | { AgentID LLUUID } // yes, pack AgentID again (note this block is variable) | ||
9204 | { Type U8 } // Type of the effect | 9210 | { Type U8 } // Type of the effect |
9205 | { Duration F32 } // F32 time (seconds) | 9211 | { Duration F32 } // F32 time (seconds) |
9206 | { Color Fixed 4 } // Color4U | 9212 | { Color Fixed 4 } // Color4U |