UI Purdyness
@@ -611,9 +611,10 @@ void LLButton::draw()
|
|||||||
S32 text_left = mLeftHPad;
|
S32 text_left = mLeftHPad;
|
||||||
S32 text_right = getRect().getWidth() - mRightHPad;
|
S32 text_right = getRect().getWidth() - mRightHPad;
|
||||||
S32 text_width = getRect().getWidth() - mLeftHPad - mRightHPad;
|
S32 text_width = getRect().getWidth() - mLeftHPad - mRightHPad;
|
||||||
|
S32 text_middle = text_left + text_width/2;
|
||||||
|
|
||||||
// draw overlay image
|
// draw overlay image
|
||||||
if (mImageOverlay.notNull())
|
if (mImageOverlay.notNull() && mImageOverlay->getWidth() > 1)
|
||||||
{
|
{
|
||||||
// get max width and height (discard level 0)
|
// get max width and height (discard level 0)
|
||||||
S32 overlay_width = mImageOverlay->getWidth();
|
S32 overlay_width = mImageOverlay->getWidth();
|
||||||
@@ -645,6 +646,7 @@ void LLButton::draw()
|
|||||||
case LLFontGL::LEFT:
|
case LLFontGL::LEFT:
|
||||||
text_left += overlay_width + 1;
|
text_left += overlay_width + 1;
|
||||||
text_width -= overlay_width + 1;
|
text_width -= overlay_width + 1;
|
||||||
|
text_middle += (overlay_width+1)/4;
|
||||||
mImageOverlay->draw(
|
mImageOverlay->draw(
|
||||||
mLeftHPad,
|
mLeftHPad,
|
||||||
center_y - (overlay_height / 2),
|
center_y - (overlay_height / 2),
|
||||||
@@ -663,6 +665,7 @@ void LLButton::draw()
|
|||||||
case LLFontGL::RIGHT:
|
case LLFontGL::RIGHT:
|
||||||
text_right -= overlay_width + 1;
|
text_right -= overlay_width + 1;
|
||||||
text_width -= overlay_width + 1;
|
text_width -= overlay_width + 1;
|
||||||
|
text_middle += (overlay_width+1)/4;
|
||||||
mImageOverlay->draw(
|
mImageOverlay->draw(
|
||||||
getRect().getWidth() - mRightHPad - overlay_width,
|
getRect().getWidth() - mRightHPad - overlay_width,
|
||||||
center_y - (overlay_height / 2),
|
center_y - (overlay_height / 2),
|
||||||
@@ -688,7 +691,10 @@ void LLButton::draw()
|
|||||||
x = text_right;
|
x = text_right;
|
||||||
break;
|
break;
|
||||||
case LLFontGL::HCENTER:
|
case LLFontGL::HCENTER:
|
||||||
x = text_left + (text_width / 2);
|
{
|
||||||
|
S32 actual_width = mGLFont->getWidth(label.c_str());
|
||||||
|
x = llmax(text_middle, text_left + actual_width/2);
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
case LLFontGL::LEFT:
|
case LLFontGL::LEFT:
|
||||||
default:
|
default:
|
||||||
@@ -704,6 +710,7 @@ void LLButton::draw()
|
|||||||
x++;
|
x++;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
mGLFont->render(label, 0,
|
mGLFont->render(label, 0,
|
||||||
(F32)x,
|
(F32)x,
|
||||||
(F32)(LLBUTTON_V_PAD + y_offset),
|
(F32)(LLBUTTON_V_PAD + y_offset),
|
||||||
|
|||||||
|
Before Width: | Height: | Size: 138 B After Width: | Height: | Size: 22 B |
|
Before Width: | Height: | Size: 138 B After Width: | Height: | Size: 22 B |
|
Before Width: | Height: | Size: 138 B After Width: | Height: | Size: 22 B |
|
Before Width: | Height: | Size: 138 B After Width: | Height: | Size: 22 B |
|
Before Width: | Height: | Size: 138 B After Width: | Height: | Size: 22 B |
|
Before Width: | Height: | Size: 138 B After Width: | Height: | Size: 22 B |
|
Before Width: | Height: | Size: 138 B After Width: | Height: | Size: 22 B |
|
Before Width: | Height: | Size: 138 B After Width: | Height: | Size: 22 B |
0
indra/newview/skins/default/textures/icon_net_close_circuit.tga
Executable file → Normal file
|
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 1.0 KiB |
0
indra/newview/skins/default/textures/icon_net_close_circuit_gray.tga
Executable file → Normal file
|
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 1.0 KiB |
0
indra/newview/skins/default/textures/icon_net_close_eventpoll.tga
Executable file → Normal file
|
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 1.0 KiB |
0
indra/newview/skins/default/textures/icon_net_close_eventpoll_gray.tga
Executable file → Normal file
|
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 1.0 KiB |
0
indra/newview/skins/default/textures/preview.png
Executable file → Normal file
|
Before Width: | Height: | Size: 24 KiB After Width: | Height: | Size: 24 KiB |
0
indra/newview/skins/default/xui/en-us/floater_object_backup.xml
Executable file → Normal file
@@ -5,7 +5,7 @@
|
|||||||
<button bottom="-22" height="22" image_overlay="active_speakers.tga" label="" left="2"
|
<button bottom="-22" height="22" image_overlay="active_speakers.tga" label="" left="2"
|
||||||
name="speakers_btn"
|
name="speakers_btn"
|
||||||
tool_tip="Show list of residents using voice chat around you" width="38" />
|
tool_tip="Show list of residents using voice chat around you" width="38" />
|
||||||
<button bottom="-22" height="22" label="Talk" left_delta="40" name="push_to_talk"
|
<button bottom="-22" height="22" pad_left="16" label="Talk" left_delta="40" name="push_to_talk"
|
||||||
tab_stop="false" tool_tip="Hold the button to talk" width="60" />
|
tab_stop="false" tool_tip="Hold the button to talk" width="60" />
|
||||||
<button bottom="-19" height="16" image_selected="ptt_lock_on.tga"
|
<button bottom="-19" height="16" image_selected="ptt_lock_on.tga"
|
||||||
image_unselected="ptt_lock_off.tga" label="" left_delta="4" name="ptt_lock"
|
image_unselected="ptt_lock_off.tga" label="" left_delta="4" name="ptt_lock"
|
||||||
|
|||||||