Improved radar time formatting, FIRE-604 from Ansariel Hiller

meow-7.2.2
Arrehn 2011-03-07 13:21:07 -05:00
parent f0a1d4a03f
commit b7fbe0e046
5 changed files with 15 additions and 11 deletions

View File

@ -382,7 +382,11 @@ void LLAvatarListItem::showStatusFlags(bool show)
void LLAvatarListItem::updateFirstSeen()
{
mFirstSeenDisplay->setValue(llformat("%d", time(NULL) - mFirstSeen));
S32 seentime = (S32)difftime(time(NULL), mFirstSeen);
S32 hours = (S32)(seentime / 3600);
S32 mins = (S32)((seentime - hours * 3600) / 60);
S32 secs = (S32)((seentime - hours * 3600 - mins * 60));
mFirstSeenDisplay->setValue(llformat("%d:%02d:%02d", hours, mins, secs));
updateChildren();
}

View File

@ -70,7 +70,7 @@
follows="right"
image_name="payment_info_used.tga"
layout="topleft"
right="-114"
right="-134"
name="payment_info"
tool_tip="Payment info on file"
top="0"
@ -82,7 +82,7 @@
top="5"
layout="topleft"
left_pad="5"
right="-70"
right="-90"
name="avatar_age"
text_color="LtGray_50"
value="0000"
@ -98,7 +98,7 @@
name="first_seen"
text_color="LtGray_50"
value="0000"
width="40" />
width="60" />
<text
follows="right"
font="SansSerifSmall"

View File

@ -120,7 +120,7 @@ Looking for people to hang out with? Use the search box to find topics or conten
left_pad="5"
name="header_age"
top="2"
right="-77"
right="-97"
width="30">AGE</text>
<text
follows="right"
@ -131,7 +131,7 @@ Looking for people to hang out with? Use the search box to find topics or conten
name="header_seen"
top="2"
right="-35"
width="40">SEEN</text>
width="50">SEEN</text>
<text
follows="right"
font="SansSerifSmall"

View File

@ -72,7 +72,7 @@
follows="right"
image_name="payment_info_used.tga"
layout="topleft"
right="-114"
right="-134"
name="payment_info"
tool_tip="Payment info on file"
top="0"
@ -84,7 +84,7 @@
top="5"
layout="topleft"
left_pad="5"
right="-70"
right="-90"
name="avatar_age"
text_color="LtGray_50"
value="0000"
@ -100,7 +100,7 @@
name="first_seen"
text_color="LtGray_50"
value="0000"
width="40" />
width="60" />
<text
follows="right"
font="SansSerifSmall"

View File

@ -119,7 +119,7 @@ Looking for people to hang out with? Use the search box to find topics or conten
left_pad="5"
name="header_age"
top="2"
right="-77"
right="-97"
width="30">AGE</text>
<text
follows="right"
@ -130,7 +130,7 @@ Looking for people to hang out with? Use the search box to find topics or conten
name="header_seen"
top="2"
right="-35"
width="40">SEEN</text>
width="50">SEEN</text>
<text
follows="right"
font="SansSerifSmall"