diff options
Diffstat (limited to '')
-rw-r--r-- | linden/indra/newview/llpanelgrouplandmoney.cpp | 41 |
1 files changed, 21 insertions, 20 deletions
diff --git a/linden/indra/newview/llpanelgrouplandmoney.cpp b/linden/indra/newview/llpanelgrouplandmoney.cpp index 21f4d4b..02aaec4 100644 --- a/linden/indra/newview/llpanelgrouplandmoney.cpp +++ b/linden/indra/newview/llpanelgrouplandmoney.cpp | |||
@@ -4,6 +4,7 @@ | |||
4 | * | 4 | * |
5 | * Copyright (c) 2006-2007, Linden Research, Inc. | 5 | * Copyright (c) 2006-2007, Linden Research, Inc. |
6 | * | 6 | * |
7 | * Second Life Viewer Source Code | ||
7 | * The source code in this file ("Source Code") is provided by Linden Lab | 8 | * The source code in this file ("Source Code") is provided by Linden Lab |
8 | * to you under the terms of the GNU General Public License, version 2.0 | 9 | * to you under the terms of the GNU General Public License, version 2.0 |
9 | * ("GPL"), unless you have obtained a separate licensing agreement | 10 | * ("GPL"), unless you have obtained a separate licensing agreement |
@@ -242,7 +243,7 @@ void LLPanelGroupLandMoney::impl::setYourMaxContributionTextBox(int max) | |||
242 | char buffer[MAX_STRING]; /*Flawfinder: ignore*/ | 243 | char buffer[MAX_STRING]; /*Flawfinder: ignore*/ |
243 | buffer[0] = '\0'; | 244 | buffer[0] = '\0'; |
244 | 245 | ||
245 | snprintf(buffer, sizeof(buffer), "(%d max)", max); /*Flawfinder: ignore*/ | 246 | snprintf(buffer, sizeof(buffer), "(%d max)", max); /* Flawfinder: ignore */ |
246 | if ( mYourContributionMaxTextp ) | 247 | if ( mYourContributionMaxTextp ) |
247 | { | 248 | { |
248 | mYourContributionMaxTextp->setText(buffer); | 249 | mYourContributionMaxTextp->setText(buffer); |
@@ -308,14 +309,14 @@ void LLPanelGroupLandMoney::impl::processGroupLand(LLMessageSystem* msg) | |||
308 | S32 total_contribution; | 309 | S32 total_contribution; |
309 | msg->getS32("QueryData", "ActualArea", total_contribution, 0); | 310 | msg->getS32("QueryData", "ActualArea", total_contribution, 0); |
310 | char buffer[MAX_STRING]; /*Flawfinder: ignore*/ | 311 | char buffer[MAX_STRING]; /*Flawfinder: ignore*/ |
311 | snprintf(buffer, sizeof(buffer), "%d sq. meters", total_contribution); /*Flawfinder: ignore*/ | 312 | snprintf(buffer, sizeof(buffer), "%d sq. meters", total_contribution); /* Flawfinder: ignore */ |
312 | mTotalContributedLandp->setText(buffer); | 313 | mTotalContributedLandp->setText(buffer); |
313 | S32 committed; | 314 | S32 committed; |
314 | msg->getS32("QueryData", "BillableArea", committed, 0); | 315 | msg->getS32("QueryData", "BillableArea", committed, 0); |
315 | snprintf(buffer, sizeof(buffer), "%d sq. meters", committed); /*Flawfinder: ignore*/ | 316 | snprintf(buffer, sizeof(buffer), "%d sq. meters", committed); /* Flawfinder: ignore */ |
316 | mTotalLandInUsep->setText(buffer); | 317 | mTotalLandInUsep->setText(buffer); |
317 | S32 available = total_contribution - committed; | 318 | S32 available = total_contribution - committed; |
318 | snprintf(buffer, sizeof(buffer), "%d sq. meters", available); /*Flawfinder: ignore*/ | 319 | snprintf(buffer, sizeof(buffer), "%d sq. meters", available); /* Flawfinder: ignore */ |
319 | mLandAvailablep->setText(buffer); | 320 | mLandAvailablep->setText(buffer); |
320 | buffer[0] = '\0'; | 321 | buffer[0] = '\0'; |
321 | if ( mGroupOverLimitTextp && mGroupOverLimitIconp ) | 322 | if ( mGroupOverLimitTextp && mGroupOverLimitIconp ) |
@@ -359,18 +360,18 @@ void LLPanelGroupLandMoney::impl::processGroupLand(LLMessageSystem* msg) | |||
359 | S32 region_x = llround(global_x) % REGION_WIDTH_UNITS; | 360 | S32 region_x = llround(global_x) % REGION_WIDTH_UNITS; |
360 | S32 region_y = llround(global_y) % REGION_WIDTH_UNITS; | 361 | S32 region_y = llround(global_y) % REGION_WIDTH_UNITS; |
361 | char location[MAX_STRING]; /*Flawfinder: ignore*/ | 362 | char location[MAX_STRING]; /*Flawfinder: ignore*/ |
362 | snprintf(location, MAX_STRING, "%s (%d, %d)", sim_name, region_x, region_y); /*Flawfinder: ignore*/ | 363 | snprintf(location, MAX_STRING, "%s (%d, %d)", sim_name, region_x, region_y); /* Flawfinder: ignore */ |
363 | char area[MAX_STRING]; /*Flawfinder: ignore*/ | 364 | char area[MAX_STRING]; /*Flawfinder: ignore*/ |
364 | if(billable_area == actual_area) | 365 | if(billable_area == actual_area) |
365 | { | 366 | { |
366 | snprintf(area, MAX_STRING, "%d", billable_area); /*Flawfinder: ignore*/ | 367 | snprintf(area, MAX_STRING, "%d", billable_area); /* Flawfinder: ignore */ |
367 | } | 368 | } |
368 | else | 369 | else |
369 | { | 370 | { |
370 | snprintf(area, MAX_STRING, "%d / %d", billable_area, actual_area); /*Flawfinder: ignore*/ | 371 | snprintf(area, MAX_STRING, "%d / %d", billable_area, actual_area); /* Flawfinder: ignore */ |
371 | } | 372 | } |
372 | char hidden[MAX_STRING]; /*Flawfinder: ignore*/ | 373 | char hidden[MAX_STRING]; /*Flawfinder: ignore*/ |
373 | snprintf(hidden, MAX_STRING, "%f %f", global_x, global_y); /*Flawfinder: ignore*/ | 374 | snprintf(hidden, MAX_STRING, "%f %f", global_x, global_y); /* Flawfinder: ignore */ |
374 | 375 | ||
375 | LLSD row; | 376 | LLSD row; |
376 | 377 | ||
@@ -996,7 +997,7 @@ void LLGroupMoneyDetailsTabEventHandler::processReply(LLMessageSystem* msg, | |||
996 | return; | 997 | return; |
997 | } | 998 | } |
998 | 999 | ||
999 | snprintf(line, MAX_STRING, "%s\n\n", start_date); /*Flawfinder: ignore*/ | 1000 | snprintf(line, MAX_STRING, "%s\n\n", start_date); /* Flawfinder: ignore */ |
1000 | text.append(line); | 1001 | text.append(line); |
1001 | 1002 | ||
1002 | S32 total_amount = 0; | 1003 | S32 total_amount = 0; |
@@ -1011,7 +1012,7 @@ void LLGroupMoneyDetailsTabEventHandler::processReply(LLMessageSystem* msg, | |||
1011 | 1012 | ||
1012 | if (amount != 0) | 1013 | if (amount != 0) |
1013 | { | 1014 | { |
1014 | snprintf(line, MAX_STRING, "%-24s %6d\n", desc, amount ); /*Flawfinder: ignore*/ | 1015 | snprintf(line, MAX_STRING, "%-24s %6d\n", desc, amount ); /* Flawfinder: ignore */ |
1015 | text.append(line); | 1016 | text.append(line); |
1016 | } | 1017 | } |
1017 | else | 1018 | else |
@@ -1024,7 +1025,7 @@ void LLGroupMoneyDetailsTabEventHandler::processReply(LLMessageSystem* msg, | |||
1024 | 1025 | ||
1025 | text.append(1, '\n'); | 1026 | text.append(1, '\n'); |
1026 | 1027 | ||
1027 | snprintf(line, MAX_STRING, "%-24s %6d\n", "Total", total_amount ); /*Flawfinder: ignore*/ | 1028 | snprintf(line, MAX_STRING, "%-24s %6d\n", "Total", total_amount ); /* Flawfinder: ignore */ |
1028 | text.append(line); | 1029 | text.append(line); |
1029 | 1030 | ||
1030 | if ( mImplementationp->mTextEditorp ) | 1031 | if ( mImplementationp->mTextEditorp ) |
@@ -1141,7 +1142,7 @@ void LLGroupMoneySalesTabEventHandler::processReply(LLMessageSystem* msg, | |||
1141 | { | 1142 | { |
1142 | text.clear(); | 1143 | text.clear(); |
1143 | 1144 | ||
1144 | snprintf(line, MAX_STRING, "%s\n\n", start_date); /*Flawfinder: ignore*/ | 1145 | snprintf(line, MAX_STRING, "%s\n\n", start_date); /* Flawfinder: ignore */ |
1145 | text.append(line); | 1146 | text.append(line); |
1146 | } | 1147 | } |
1147 | 1148 | ||
@@ -1196,7 +1197,7 @@ void LLGroupMoneySalesTabEventHandler::processReply(LLMessageSystem* msg, | |||
1196 | break; | 1197 | break; |
1197 | } | 1198 | } |
1198 | 1199 | ||
1199 | snprintf(line, sizeof(line), "%s %6d - %s %s %s\n", time, amount, user, verb, item); /*Flawfinder: ignore*/ | 1200 | snprintf(line, sizeof(line), "%s %6d - %s %s %s\n", time, amount, user, verb, item); /* Flawfinder: ignore */ |
1200 | text.append(line); | 1201 | text.append(line); |
1201 | } | 1202 | } |
1202 | } | 1203 | } |
@@ -1349,26 +1350,26 @@ void LLGroupMoneyPlanningTabEventHandler::processReply(LLMessageSystem* msg, | |||
1349 | return; | 1350 | return; |
1350 | } | 1351 | } |
1351 | 1352 | ||
1352 | snprintf(line, MAX_STRING, "Summary for this week, beginning on %s\n", start_date); /*Flawfinder: ignore*/ | 1353 | snprintf(line, MAX_STRING, "Summary for this week, beginning on %s\n", start_date); /* Flawfinder: ignore */ |
1353 | text.append(line); | 1354 | text.append(line); |
1354 | 1355 | ||
1355 | if (current_interval == 0) | 1356 | if (current_interval == 0) |
1356 | { | 1357 | { |
1357 | snprintf(line, MAX_STRING, "The next stipend day is %s\n\n", next_stipend_date); /*Flawfinder: ignore*/ | 1358 | snprintf(line, MAX_STRING, "The next stipend day is %s\n\n", next_stipend_date); /* Flawfinder: ignore */ |
1358 | text.append(line); | 1359 | text.append(line); |
1359 | snprintf(line, MAX_STRING, "%-24sL$%6d\n", "Balance", balance ); /*Flawfinder: ignore*/ | 1360 | snprintf(line, MAX_STRING, "%-24sL$%6d\n", "Balance", balance ); /* Flawfinder: ignore */ |
1360 | text.append(line); | 1361 | text.append(line); |
1361 | 1362 | ||
1362 | text.append(1, '\n'); | 1363 | text.append(1, '\n'); |
1363 | } | 1364 | } |
1364 | 1365 | ||
1365 | snprintf(line, MAX_STRING, " Group Individual Share\n"); /*Flawfinder: ignore*/ | 1366 | snprintf(line, MAX_STRING, " Group Individual Share\n"); /* Flawfinder: ignore */ |
1366 | text.append(line); | 1367 | text.append(line); |
1367 | snprintf(line, MAX_STRING, "%-24s %6d %6d \n", "Credits", total_credits, (S32)floor((F32)total_credits/(F32)non_exempt_members)); /*Flawfinder: ignore*/ | 1368 | snprintf(line, MAX_STRING, "%-24s %6d %6d \n", "Credits", total_credits, (S32)floor((F32)total_credits/(F32)non_exempt_members)); /* Flawfinder: ignore */ |
1368 | text.append(line); | 1369 | text.append(line); |
1369 | snprintf(line, MAX_STRING, "%-24s %6d %6d \n", "Debits", total_debits, (S32)floor((F32)total_debits/(F32)non_exempt_members)); /*Flawfinder: ignore*/ | 1370 | snprintf(line, MAX_STRING, "%-24s %6d %6d \n", "Debits", total_debits, (S32)floor((F32)total_debits/(F32)non_exempt_members)); /* Flawfinder: ignore */ |
1370 | text.append(line); | 1371 | text.append(line); |
1371 | snprintf(line, MAX_STRING, "%-24s %6d %6d \n", "Total", total_credits + total_debits, (S32)floor((F32)(total_credits + total_debits)/(F32)non_exempt_members)); /*Flawfinder: ignore*/ | 1372 | snprintf(line, MAX_STRING, "%-24s %6d %6d \n", "Total", total_credits + total_debits, (S32)floor((F32)(total_credits + total_debits)/(F32)non_exempt_members)); /* Flawfinder: ignore */ |
1372 | text.append(line); | 1373 | text.append(line); |
1373 | 1374 | ||
1374 | if ( mImplementationp->mTextEditorp ) | 1375 | if ( mImplementationp->mTextEditorp ) |