diff options
author | Vadim Savchuk <vsavchuk@productengine.com> | 2010-01-06 12:58:33 +0200 |
---|---|---|
committer | Vadim Savchuk <vsavchuk@productengine.com> | 2010-01-06 12:58:33 +0200 |
commit | aa5aff1d79ea605f909efdbabde6dec853d54a90 (patch) | |
tree | 99ed950508998ba8b9ceb951b09d94e8b7e053a4 /indra | |
parent | a22df89f3b790afe993b217c6217ff5e61f337d5 (diff) | |
parent | 93417fe004b831f73f0c0c9906e93237d74ed589 (diff) |
Merge from default branch.
--HG--
branch : product-engine
Diffstat (limited to 'indra')
21 files changed, 360 insertions, 209 deletions
diff --git a/indra/llaudio/llstreamingaudio_fmod.cpp b/indra/llaudio/llstreamingaudio_fmod.cpp index a71a87203c..a4620fa13c 100644 --- a/indra/llaudio/llstreamingaudio_fmod.cpp +++ b/indra/llaudio/llstreamingaudio_fmod.cpp @@ -174,7 +174,7 @@ void LLStreamingAudio_FMOD::update() break; case -3: // failed to open, file not found, perhaps - llwarns << "InternetSteam - failed to open" << llendl; + llwarns << "InternetStream - failed to open" << llendl; stop(); return; case -4: diff --git a/indra/llui/lllayoutstack.h b/indra/llui/lllayoutstack.h index cde383b047..aba35773ee 100644 --- a/indra/llui/lllayoutstack.h +++ b/indra/llui/lllayoutstack.h @@ -91,6 +91,9 @@ public: bool getPanelMinSize(const std::string& panel_name, S32* min_widthp, S32* min_heightp); void updateLayout(BOOL force_resize = FALSE); + + S32 getPanelSpacing() const { return mPanelSpacing; } + static void updateClass(); protected: diff --git a/indra/media_plugins/webkit/media_plugin_webkit.cpp b/indra/media_plugins/webkit/media_plugin_webkit.cpp index 4b6da552cf..02f0045800 100644 --- a/indra/media_plugins/webkit/media_plugin_webkit.cpp +++ b/indra/media_plugins/webkit/media_plugin_webkit.cpp @@ -84,6 +84,7 @@ private: INIT_STATE_NAVIGATING, // Browser instance has been set up and initial navigate to about:blank has been issued INIT_STATE_NAVIGATE_COMPLETE, // initial navigate to about:blank has completed INIT_STATE_WAIT_REDRAW, // First real navigate begin has been received, waiting for page changed event to start handling redraws + INIT_STATE_WAIT_COMPLETE, // Waiting for first real navigate complete event INIT_STATE_RUNNING // All initialization gymnastics are complete. }; int mBrowserWindowId; @@ -122,7 +123,7 @@ private: } } - if ( (mInitState == INIT_STATE_RUNNING) && mNeedsUpdate ) + if ( (mInitState > INIT_STATE_WAIT_REDRAW) && mNeedsUpdate ) { const unsigned char* browser_pixels = LLQtWebKit::getInstance()->grabBrowserWindow( mBrowserWindowId ); @@ -295,7 +296,7 @@ private: { if(mInitState == INIT_STATE_WAIT_REDRAW) { - setInitState(INIT_STATE_RUNNING); + setInitState(INIT_STATE_WAIT_COMPLETE); } // flag that an update is required @@ -328,6 +329,14 @@ private: { if(mInitState >= INIT_STATE_NAVIGATE_COMPLETE) { + if(mInitState < INIT_STATE_RUNNING) + { + setInitState(INIT_STATE_RUNNING); + + // Clear the history, so the "back" button doesn't take you back to "about:blank". + LLQtWebKit::getInstance()->clearHistory(mBrowserWindowId); + } + LLPluginMessage message(LLPLUGIN_MESSAGE_CLASS_MEDIA_BROWSER, "navigate_complete"); message.setValue("uri", event.getEventUri()); message.setValueS32("result_code", event.getIntValue()); diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml index 5045703233..61cb93b675 100644 --- a/indra/newview/app_settings/settings.xml +++ b/indra/newview/app_settings/settings.xml @@ -276,7 +276,7 @@ <key>Value</key> <real>0.5</real> </map> - <key>AudioSteamingMedia</key> + <key>AudioStreamingMedia</key> <map> <key>Comment</key> <string>Enable streaming</string> diff --git a/indra/newview/llagentwearables.cpp b/indra/newview/llagentwearables.cpp index dc1598aacd..d21965568d 100644 --- a/indra/newview/llagentwearables.cpp +++ b/indra/newview/llagentwearables.cpp @@ -116,6 +116,39 @@ BOOL LLAgentWearables::mInitialWearablesUpdateReceived = FALSE; using namespace LLVOAvatarDefines; +// HACK: For EXT-3923: Pants item shows in inventory with skin icon and messes with "current look" +// Some db items are corrupted, have inventory flags = 0, implying wearable type = shape, even though +// wearable type stored in asset is some other value. +// Calling this function whenever a wearable is added to increase visibility if this problem +// turns up in other inventories. +void checkWearableAgainstInventory(LLWearable *wearable) +{ + if (wearable->getItemID().isNull()) + return; + + // Check for wearable type consistent with inventory item wearable type. + LLViewerInventoryItem *item = gInventory.getItem(wearable->getItemID()); + if (item) + { + if (!item->isWearableType()) + { + llwarns << "wearable associated with non-wearable item" << llendl; + } + if (item->getWearableType() != wearable->getType()) + { + llwarns << "type mismatch: wearable " << wearable->getName() + << " has type " << wearable->getType() + << " but inventory item " << item->getName() + << " has type " << item->getWearableType() << llendl; + } + } + else + { + llwarns << "wearable inventory item not found" << wearable->getName() + << " itemID " << wearable->getItemID().asString() << llendl; + } +} + void LLAgentWearables::dump() { llinfos << "LLAgentWearablesDump" << llendl; @@ -657,6 +690,7 @@ LLWearable* LLAgentWearables::getWearable(const EWearableType type, U32 index) void LLAgentWearables::setWearable(const EWearableType type, U32 index, LLWearable *wearable) { + LLWearable *old_wearable = getWearable(type,index); if (!old_wearable) { @@ -680,6 +714,7 @@ void LLAgentWearables::setWearable(const EWearableType type, U32 index, LLWearab wearable_vec[index] = wearable; old_wearable->setLabelUpdated(); wearableUpdated(wearable); + checkWearableAgainstInventory(wearable); } } @@ -695,6 +730,7 @@ U32 LLAgentWearables::pushWearable(const EWearableType type, LLWearable *wearabl { mWearableDatas[type].push_back(wearable); wearableUpdated(wearable); + checkWearableAgainstInventory(wearable); return mWearableDatas[type].size()-1; } return MAX_WEARABLES_PER_TYPE; @@ -1360,6 +1396,7 @@ LLUUID LLAgentWearables::makeNewOutfitLinks(const std::string& new_folder_name) LLPointer<LLInventoryCallback> cb = new LLAutoRenameFolder(folder_id); LLAppearanceManager::instance().shallowCopyCategory(LLAppearanceManager::instance().getCOF(),folder_id, cb); + LLAppearanceManager::instance().createBaseOutfitLink(folder_id, NULL); return folder_id; } @@ -1705,6 +1742,7 @@ void LLAgentWearables::setWearableFinal(LLInventoryItem* new_item, LLWearable* n mWearableDatas[type].push_back(new_wearable); llinfos << "Added additional wearable for type " << type << " size is now " << mWearableDatas[type].size() << llendl; + checkWearableAgainstInventory(new_wearable); } else { diff --git a/indra/newview/llappearancemgr.cpp b/indra/newview/llappearancemgr.cpp index 43b2f34ecd..25f1accb22 100644 --- a/indra/newview/llappearancemgr.cpp +++ b/indra/newview/llappearancemgr.cpp @@ -364,7 +364,7 @@ LLUUID LLAppearanceManager::getCOF() } -const LLViewerInventoryItem* LLAppearanceManager::getCurrentOutfitLink() +const LLViewerInventoryItem* LLAppearanceManager::getBaseOutfitLink() { const LLUUID& current_outfit_cat = getCOF(); LLInventoryModel::cat_array_t cat_array; @@ -444,6 +444,28 @@ void LLAppearanceManager::shallowCopyCategory(const LLUUID& src_id, const LLUUID } } +void LLAppearanceManager::purgeBaseOutfitLink(const LLUUID& category) +{ + LLInventoryModel::cat_array_t cats; + LLInventoryModel::item_array_t items; + gInventory.collectDescendents(category, cats, items, + LLInventoryModel::EXCLUDE_TRASH); + for (S32 i = 0; i < items.count(); ++i) + { + LLViewerInventoryItem *item = items.get(i); + if (item->getActualType() != LLAssetType::AT_LINK_FOLDER) + continue; + if (item->getIsLinkType()) + { + LLViewerInventoryCategory* catp = item->getLinkedCategory(); + if(catp && catp->getPreferredType() == LLFolderType::FT_OUTFIT) + { + gInventory.purgeObject(item->getUUID()); + } + } + } +} + void LLAppearanceManager::purgeCategory(const LLUUID& category, bool keep_outfit_links) { LLInventoryModel::cat_array_t cats; @@ -578,17 +600,9 @@ void LLAppearanceManager::updateCOF(const LLUUID& category, bool append) linkAll(cof, gest_items, link_waiter); // Add link to outfit if category is an outfit. - LLViewerInventoryCategory* catp = gInventory.getCategory(category); if (!append) { - std::string new_outfit_name = ""; - if (catp && catp->getPreferredType() == LLFolderType::FT_OUTFIT) - { - link_inventory_item(gAgent.getID(), category, cof, catp->getName(), - LLAssetType::AT_LINK_FOLDER, link_waiter); - new_outfit_name = catp->getName(); - } - updatePanelOutfitName(new_outfit_name); + createBaseOutfitLink(category, link_waiter); } } @@ -602,6 +616,22 @@ void LLAppearanceManager::updatePanelOutfitName(const std::string& name) } } +void LLAppearanceManager::createBaseOutfitLink(const LLUUID& category, LLPointer<LLInventoryCallback> link_waiter) +{ + const LLUUID cof = getCOF(); + LLViewerInventoryCategory* catp = gInventory.getCategory(category); + std::string new_outfit_name = ""; + + purgeBaseOutfitLink(cof); + + if (catp && catp->getPreferredType() == LLFolderType::FT_OUTFIT) + { + link_inventory_item(gAgent.getID(), category, cof, catp->getName(), + LLAssetType::AT_LINK_FOLDER, link_waiter); + new_outfit_name = catp->getName(); + } + updatePanelOutfitName(new_outfit_name); +} void LLAppearanceManager::updateAgentWearables(LLWearableHoldingPattern* holder, bool append) { diff --git a/indra/newview/llappearancemgr.h b/indra/newview/llappearancemgr.h index b625d42a50..11b910ee11 100644 --- a/indra/newview/llappearancemgr.h +++ b/indra/newview/llappearancemgr.h @@ -62,11 +62,13 @@ public: LLUUID getCOF(); // Finds the folder link to the currently worn outfit - const LLViewerInventoryItem *getCurrentOutfitLink(); + const LLViewerInventoryItem *getBaseOutfitLink(); // Update the displayed outfit name in UI. void updatePanelOutfitName(const std::string& name); + void createBaseOutfitLink(const LLUUID& category, LLPointer<LLInventoryCallback> link_waiter); + void updateAgentWearables(LLWearableHoldingPattern* holder, bool append); // For debugging - could be moved elsewhere. @@ -114,6 +116,7 @@ private: bool follow_folder_links); void purgeCategory(const LLUUID& category, bool keep_outfit_links); + void purgeBaseOutfitLink(const LLUUID& category); std::set<LLUUID> mRegisteredAttachments; bool mAttachmentInvLinkEnabled; diff --git a/indra/newview/llfloatertools.cpp b/indra/newview/llfloatertools.cpp index babef5b63d..9cae6f0ebd 100644 --- a/indra/newview/llfloatertools.cpp +++ b/indra/newview/llfloatertools.cpp @@ -1221,10 +1221,10 @@ void LLFloaterTools::getMediaState() mNeedMediaTitle = false; } - childSetEnabled("media_tex", bool_has_media & editable); - childSetEnabled( "edit_media", bool_has_media & editable ); - childSetEnabled( "delete_media", bool_has_media & editable ); - childSetEnabled( "add_media", ( ! bool_has_media ) & editable ); + childSetEnabled("media_tex", bool_has_media && editable); + childSetEnabled( "edit_media", bool_has_media && LLFloaterMediaSettings::getInstance()->mIdenticalHasMediaInfo && editable ); + childSetEnabled( "delete_media", bool_has_media && editable ); + childSetEnabled( "add_media", ( ! bool_has_media ) && editable ); // TODO: display a list of all media on the face - use 'identical' flag } else // not all face has media but at least one does. @@ -1252,7 +1252,7 @@ void LLFloaterTools::getMediaState() } childSetEnabled("media_tex", TRUE); - childSetEnabled( "edit_media", TRUE); + childSetEnabled( "edit_media", LLFloaterMediaSettings::getInstance()->mIdenticalHasMediaInfo); childSetEnabled( "delete_media", TRUE); childSetEnabled( "add_media", FALSE ); } @@ -1423,7 +1423,7 @@ void LLFloaterTools::updateMediaSettings() return mMediaEntry.getControls(); }; - const LLMediaEntry & mMediaEntry; + const LLMediaEntry &mMediaEntry; } func_controls(default_media_data); identical = selected_objects->getSelectedTEValue( &func_controls, value_u8 ); @@ -1446,7 +1446,7 @@ void LLFloaterTools::updateMediaSettings() return mMediaEntry.getFirstClickInteract(); }; - const LLMediaEntry & mMediaEntry; + const LLMediaEntry &mMediaEntry; } func_first_click(default_media_data); identical = selected_objects->getSelectedTEValue( &func_first_click, value_bool ); @@ -1469,7 +1469,7 @@ void LLFloaterTools::updateMediaSettings() return mMediaEntry.getHomeURL(); }; - const LLMediaEntry & mMediaEntry; + const LLMediaEntry &mMediaEntry; } func_home_url(default_media_data); identical = selected_objects->getSelectedTEValue( &func_home_url, value_str ); @@ -1492,7 +1492,7 @@ void LLFloaterTools::updateMediaSettings() return mMediaEntry.getCurrentURL(); }; - const LLMediaEntry & mMediaEntry; + const LLMediaEntry &mMediaEntry; } func_current_url(default_media_data); identical = selected_objects->getSelectedTEValue( &func_current_url, value_str ); @@ -1516,7 +1516,7 @@ void LLFloaterTools::updateMediaSettings() return mMediaEntry.getAutoZoom(); }; - const LLMediaEntry & mMediaEntry; + const LLMediaEntry &mMediaEntry; } func_auto_zoom(default_media_data); identical = selected_objects->getSelectedTEValue( &func_auto_zoom, value_bool ); @@ -1539,7 +1539,7 @@ void LLFloaterTools::updateMediaSettings() return mMediaEntry.getAutoPlay(); }; - const LLMediaEntry & mMediaEntry; + const LLMediaEntry &mMediaEntry; } func_auto_play(default_media_data); identical = selected_objects->getSelectedTEValue( &func_auto_play, value_bool ); @@ -1563,7 +1563,7 @@ void LLFloaterTools::updateMediaSettings() return mMediaEntry.getAutoScale();; }; - const LLMediaEntry & mMediaEntry; + const LLMediaEntry &mMediaEntry; } func_auto_scale(default_media_data); identical = selected_objects->getSelectedTEValue( &func_auto_scale, value_bool ); @@ -1586,7 +1586,7 @@ void LLFloaterTools::updateMediaSettings() return mMediaEntry.getAutoLoop(); }; - const LLMediaEntry & mMediaEntry; + const LLMediaEntry &mMediaEntry; } func_auto_loop(default_media_data); identical = selected_objects->getSelectedTEValue( &func_auto_loop, value_bool ); @@ -1609,7 +1609,7 @@ void LLFloaterTools::updateMediaSettings() return mMediaEntry.getWidthPixels(); }; - const LLMediaEntry & mMediaEntry; + const LLMediaEntry &mMediaEntry; } func_width_pixels(default_media_data); identical = selected_objects->getSelectedTEValue( &func_width_pixels, value_int ); @@ -1632,7 +1632,7 @@ void LLFloaterTools::updateMediaSettings() return mMediaEntry.getHeightPixels(); }; - const LLMediaEntry & mMediaEntry; + const LLMediaEntry &mMediaEntry; } func_height_pixels(default_media_data); identical = selected_objects->getSelectedTEValue( &func_height_pixels, value_int ); @@ -1655,7 +1655,7 @@ void LLFloaterTools::updateMediaSettings() return mMediaEntry.getAltImageEnable(); }; - const LLMediaEntry & mMediaEntry; + const LLMediaEntry &mMediaEntry; } func_enable_alt_image(default_media_data); identical = selected_objects->getSelectedTEValue( &func_enable_alt_image, value_bool ); @@ -1678,7 +1678,7 @@ void LLFloaterTools::updateMediaSettings() return 0 != ( mMediaEntry.getPermsInteract() & LLMediaEntry::PERM_OWNER ); }; - const LLMediaEntry & mMediaEntry; + const LLMediaEntry &mMediaEntry; } func_perms_owner_interact(default_media_data); identical = selected_objects->getSelectedTEValue( &func_perms_owner_interact, value_bool ); @@ -1701,7 +1701,7 @@ void LLFloaterTools::updateMediaSettings() return 0 != ( mMediaEntry.getPermsControl() & LLMediaEntry::PERM_OWNER ); }; - const LLMediaEntry & mMediaEntry; + const LLMediaEntry &mMediaEntry; } func_perms_owner_control(default_media_data); identical = selected_objects ->getSelectedTEValue( &func_perms_owner_control, value_bool ); @@ -1724,7 +1724,7 @@ void LLFloaterTools::updateMediaSettings() return 0 != ( mMediaEntry.getPermsInteract() & LLMediaEntry::PERM_GROUP ); }; - const LLMediaEntry & mMediaEntry; + const LLMediaEntry &mMediaEntry; } func_perms_group_interact(default_media_data); identical = selected_objects->getSelectedTEValue( &func_perms_group_interact, value_bool ); @@ -1747,7 +1747,7 @@ void LLFloaterTools::updateMediaSettings() return 0 != ( mMediaEntry.getPermsControl() & LLMediaEntry::PERM_GROUP ); }; - const LLMediaEntry & mMediaEntry; + const LLMediaEntry &mMediaEntry; } func_perms_group_control(default_media_data); identical = selected_objects->getSelectedTEValue( &func_perms_group_control, value_bool ); @@ -1770,7 +1770,7 @@ void LLFloaterTools::updateMediaSettings() return 0 != ( mMediaEntry.getPermsInteract() & LLMediaEntry::PERM_ANYONE ); }; - const LLMediaEntry & mMediaEntry; + const LLMediaEntry &mMediaEntry; } func_perms_anyone_interact(default_media_data); identical = LLSelectMgr::getInstance()->getSelection()->getSelectedTEValue( &func_perms_anyone_interact, value_bool ); @@ -1793,7 +1793,7 @@ void LLFloaterTools::updateMediaSettings() return 0 != ( mMediaEntry.getPermsControl() & LLMediaEntry::PERM_ANYONE ); }; - const LLMediaEntry & mMediaEntry; + const LLMediaEntry &mMediaEntry; } func_perms_anyone_control(default_media_data); identical = selected_objects->getSelectedTEValue( &func_perms_anyone_control, value_bool ); @@ -1816,7 +1816,7 @@ void LLFloaterTools::updateMediaSettings() return mMediaEntry.getWhiteListEnable(); }; - const LLMediaEntry & mMediaEntry; + const LLMediaEntry &mMediaEntry; } func_whitelist_enable(default_media_data); identical = selected_objects->getSelectedTEValue( &func_whitelist_enable, value_bool ); @@ -1839,7 +1839,7 @@ void LLFloaterTools::updateMediaSettings() return mMediaEntry.getWhiteList(); }; - const LLMediaEntry & mMediaEntry; + const LLMediaEntry &mMediaEntry; } func_whitelist_urls(default_media_data); identical = selected_objects->getSelectedTEValue( &func_whitelist_urls, value_vector_str ); diff --git a/indra/newview/llpanelprimmediacontrols.cpp b/indra/newview/llpanelprimmediacontrols.cpp index 5cc9c1951b..4f539f404d 100644 --- a/indra/newview/llpanelprimmediacontrols.cpp +++ b/indra/newview/llpanelprimmediacontrols.cpp @@ -127,7 +127,11 @@ LLPanelPrimMediaControls::LLPanelPrimMediaControls() : mScrollState = SCROLL_NONE; mPanelHandle.bind(this); + + mInactiveTimeout = gSavedSettings.getF32("MediaControlTimeout"); + mControlFadeTime = gSavedSettings.getF32("MediaControlFadeTime"); } + LLPanelPrimMediaControls::~LLPanelPrimMediaControls() { } @@ -172,6 +176,7 @@ BOOL LLPanelPrimMediaControls::postBuild() LLStringUtil::convertToF32(getString("zoom_near_padding"), mZoomNearPadding); LLStringUtil::convertToF32(getString("zoom_medium_padding"), mZoomMediumPadding); LLStringUtil::convertToF32(getString("zoom_far_padding"), mZoomFarPadding); + LLStringUtil::convertToS32(getString("top_world_view_avoid_zone"), mTopWorldViewAvoidZone); // These are currently removed...but getChild creates a "dummy" widget. // This class handles them missing. @@ -207,11 +212,9 @@ BOOL LLPanelPrimMediaControls::postBuild() } mMediaAddress->setFocusReceivedCallback(boost::bind(&LLPanelPrimMediaControls::onInputURL, _1, this )); - mInactiveTimeout = gSavedSettings.getF32("MediaControlTimeout"); - mControlFadeTime = gSavedSettings.getF32("MediaControlFadeTime"); - + mCurrentZoom = ZOOM_NONE; - // clicks on HUD buttons do not remove keyboard focus from media + // clicks on buttons do not remove keyboard focus from media setIsChrome(TRUE); return TRUE; } @@ -373,8 +376,8 @@ void LLPanelPrimMediaControls::updateShape() mVolumeUpCtrl->setVisible(has_focus); mVolumeDownCtrl->setVisible(has_focus); mVolumeCtrl->setEnabled(has_focus); - mVolumeSliderCtrl->setEnabled(has_focus && mVolumeSliderVisible > 0); - mVolumeSliderCtrl->setVisible(has_focus && mVolumeSliderVisible > 0); + mVolumeSliderCtrl->setEnabled(has_focus && shouldVolumeSliderBeVisible()); + mVolumeSliderCtrl->setVisible(has_focus && shouldVolumeSliderBeVisible()); mWhitelistIcon->setVisible(false); mSecureLockIcon->setVisible(false); @@ -627,36 +630,45 @@ void LLPanelPrimMediaControls::updateShape() update_min_max(min, max, LLVector3(screen_vert.v)); } + // convert screenspace bbox to pixels (in screen coords) + LLRect window_rect = gViewerWindow->getWorldViewRectScaled(); LLCoordGL screen_min; - screen_min.mX = llround((F32)gViewerWindow->getWorldViewWidthScaled() * (min.mV[VX] + 1.f) * 0.5f); - screen_min.mY = llround((F32)gViewerWindow->getWorldViewHeightScaled() * (min.mV[VY] + 1.f) * 0.5f); + screen_min.mX = llround((F32)window_rect.getWidth() * (min.mV[VX] + 1.f) * 0.5f); + screen_min.mY = llround((F32)window_rect.getHeight() * (min.mV[VY] + 1.f) * 0.5f); LLCoordGL screen_max; - screen_max.mX = llround((F32)gViewerWindow->getWorldViewWidthScaled() * (max.mV[VX] + 1.f) * 0.5f); - screen_max.mY = llround((F32)gViewerWindow->getWorldViewHeightScaled() * (max.mV[VY] + 1.f) * 0.5f); + screen_max.mX = llround((F32)window_rect.getWidth() * (max.mV[VX] + 1.f) * 0.5f); + screen_max.mY = llround((F32)window_rect.getHeight() * (max.mV[VY] + 1.f) * 0.5f); - // grow panel so that screenspace bounding box fits inside "media_region" element of HUD - LLRect media_controls_rect; - S32 volume_slider_height = mVolumeSliderCtrl->getRect().getHeight() - /*fudge*/ 2; - getParent()->screenRectToLocal(LLRect(screen_min.mX, screen_max.mY, screen_max.mX, screen_min.mY), &media_controls_rect); - media_controls_rect.mLeft -= mMediaRegion->getRect().mLeft; - media_controls_rect.mBottom -= mMediaRegion->getRect().mBottom - volume_slider_height; - media_controls_rect.mTop += getRect().getHeight() - mMediaRegion->getRect().mTop; - media_controls_rect.mRight += getRect().getWidth() - mMediaRegion->getRect().mRight; + // grow panel so that screenspace bounding box fits inside "media_region" element of panel + LLRect media_panel_rect; + // Get the height of the controls (less the volume slider) + S32 controls_height = mMediaControlsStack->getRect().getHeight() - mVolumeSliderCtrl->getRect().getHeight(); + getParent()->screenRectToLocal(LLRect(screen_min.mX, screen_max.mY, screen_max.mX, screen_min.mY), &media_panel_rect); + media_panel_rect.mTop += controls_height; - // keep all parts of HUD on-screen - LLRect window_rect = getParent()->getLocalRect(); - media_controls_rect.intersectWith(window_rect); + // keep all parts of panel on-screen + // Area of the top of the world view to avoid putting the controls + window_rect.mTop -= mTopWorldViewAvoidZone; + // Don't include "spacing" bookends on left & right of the media controls + window_rect.mLeft -= mLeftBookend->getRect().getWidth(); + window_rect.mRight += mRightBookend->getRect().getWidth(); + // Don't include the volume slider + window_rect.mBottom -= mVolumeSliderCtrl->getRect().getHeight(); + media_panel_rect.intersectWith(window_rect); // clamp to minimum size, keeping rect inside window - S32 centerX = media_controls_rect.getCenterX(); - S32 centerY = media_controls_rect.getCenterY(); + S32 centerX = media_panel_rect.getCenterX(); + S32 centerY = media_panel_rect.getCenterY(); + // Shrink screen rect by min width and height, to ensure containment window_rect.stretch(-mMinWidth/2, -mMinHeight/2); window_rect.clampPointToRect(centerX, centerY); - media_controls_rect.setCenterAndSize(centerX, centerY, - llmax(mMinWidth, media_controls_rect.getWidth()), llmax(mMinHeight, media_controls_rect.getHeight())); + media_panel_rect.setCenterAndSize(centerX, centerY, + llmax(mMinWidth, media_panel_rect.getWidth()), + llmax(mMinHeight, media_panel_rect.getHeight())); - setShape(media_controls_rect, true); + // Finally set the size of the panel + setShape(media_panel_rect, true); // Test mouse position to see if the cursor is stationary LLCoordWindow cursor_pos_window; @@ -699,13 +711,13 @@ void LLPanelPrimMediaControls::updateShape() /*virtual*/ void LLPanelPrimMediaControls::draw() { - F32 alpha = 1.f; + F32 alpha = getDrawContext().mAlpha; if(mFadeTimer.getStarted()) { F32 time = mFadeTimer.getElapsedTimeF32(); - alpha = llmax(lerp(1.0, 0.0, time / mControlFadeTime), 0.0f); + alpha *= llmax(lerp(1.0, 0.0, time / mControlFadeTime), 0.0f); - if(mFadeTimer.getElapsedTimeF32() >= mControlFadeTime) + if(time >= mControlFadeTime) { if(mClearFaceOnFade) { @@ -726,27 +738,30 @@ void LLPanelPrimMediaControls::draw() // Build rect for icon area in coord system of this panel // Assumes layout_stack is a direct child of this panel mMediaControlsStack->updateLayout(); - LLRect icon_area = mMediaControlsStack->getRect(); - + + // adjust for layout stack spacing + S32 space = mMediaControlsStack->getPanelSpacing() + 1; + LLRect controls_bg_area = mMediaControlsStack->getRect(); + + controls_bg_area.mTop += space; + // adjust to ignore space from volume slider - icon_area.mTop -= mVolumeSliderCtrl->getRect().getHeight(); + controls_bg_area.mBottom += mVolumeSliderCtrl->getRect().getHeight(); // adjust to ignore space from left bookend padding - icon_area.mLeft += mLeftBookend->getRect().getWidth(); + controls_bg_area.mLeft += mLeftBookend->getRect().getWidth() - space; // ignore space from right bookend padding - icon_area.mRight -= mRightBookend->getRect().getWidth(); + controls_bg_area.mRight -= mRightBookend->getRect().getWidth() - space; // draw control background UI image - mBackgroundImage->draw( icon_area, UI_VERTEX_COLOR % alpha); + mBackgroundImage->draw( controls_bg_area, UI_VERTEX_COLOR % alpha); // draw volume slider background UI image if (mVolumeSliderCtrl->getVisible()) { - LLRect volume_slider_rect = mVolumeSliderCtrl->getRect(); - // For some reason the rect is not in the right place (??) - // This translates the bg to under the slider - volume_slider_rect.translate(mVolumeSliderCtrl->getParent()->getRect().mLeft, icon_area.getHeight()); + LLRect volume_slider_rect; + screenRectToLocal(mVolumeSliderCtrl->calcScreenRect(), &volume_slider_rect); mVolumeSliderBackgroundImage->draw(volume_slider_rect, UI_VERTEX_COLOR % alpha); } @@ -1259,6 +1274,11 @@ void LLPanelPrimMediaControls::onToggleMute() { media_impl->setVolume(0.0); } + else if (mVolumeSliderCtrl->getValueF32() == 0.0) + { + media_impl->setVolume(1.0); + mVolumeSliderCtrl->setValue(1.0); + } else { media_impl->setVolume(mVolumeSliderCtrl->getValueF32()); @@ -1271,8 +1291,12 @@ void LLPanelPrimMediaControls::showVolumeSlider() mVolumeSliderVisible++; } - void LLPanelPrimMediaControls::hideVolumeSlider() { mVolumeSliderVisible--; } + +bool LLPanelPrimMediaControls::shouldVolumeSliderBeVisible() +{ + return mVolumeSliderVisible > 0; +} diff --git a/indra/newview/llpanelprimmediacontrols.h b/indra/newview/llpanelprimmediacontrols.h index d899ee4473..419f033628 100644 --- a/indra/newview/llpanelprimmediacontrols.h +++ b/indra/newview/llpanelprimmediacontrols.h @@ -111,6 +111,7 @@ private: void onToggleMute(); void showVolumeSlider(); void hideVolumeSlider(); + bool shouldVolumeSliderBeVisible(); static void onScrollUp(void* user_data); static void onScrollUpHeld(void* user_data); @@ -171,6 +172,7 @@ private: F32 mZoomNearPadding; F32 mZoomMediumPadding; F32 mZoomFarPadding; + S32 mTopWorldViewAvoidZone; LLUICtrl *mMediaPanelScroll; LLButton *mScrollUpCtrl; diff --git a/indra/newview/llsidepanelappearance.cpp b/indra/newview/llsidepanelappearance.cpp index 30b0075c4b..e2ce534c4f 100644 --- a/indra/newview/llsidepanelappearance.cpp +++ b/indra/newview/llsidepanelappearance.cpp @@ -198,7 +198,7 @@ void LLSidepanelAppearance::onFilterEdit(const std::string& search_string) void LLSidepanelAppearance::onOpenOutfitButtonClicked() { - const LLViewerInventoryItem *outfit_link = LLAppearanceManager::getInstance()->getCurrentOutfitLink(); + const LLViewerInventoryItem *outfit_link = LLAppearanceManager::getInstance()->getBaseOutfitLink(); if (!outfit_link) return; if (!outfit_link->getIsLinkType()) @@ -313,7 +313,7 @@ void LLSidepanelAppearance::refreshCurrentOutfitName(const std::string& name) { if (name == "") { - const LLViewerInventoryItem *outfit_link = LLAppearanceManager::getInstance()->getCurrentOutfitLink(); + const LLViewerInventoryItem *outfit_link = LLAppearanceManager::getInstance()->getBaseOutfitLink(); if (outfit_link) { const LLViewerInventoryCategory *cat = outfit_link->getLinkedCategory(); diff --git a/indra/newview/llviewermedia.cpp b/indra/newview/llviewermedia.cpp index bf96472e7e..0fc0afed3e 100644 --- a/indra/newview/llviewermedia.cpp +++ b/indra/newview/llviewermedia.cpp @@ -987,7 +987,7 @@ void LLViewerMediaImpl::emitEvent(LLPluginClassMedia* plugin, LLViewerMediaObser bool LLViewerMediaImpl::initializeMedia(const std::string& mime_type) { bool mimeTypeChanged = (mMimeType != mime_type); - bool pluginChanged = (LLMIMETypes::implType(mMimeType) != LLMIMETypes::implType(mime_type)); + bool pluginChanged = (LLMIMETypes::implType(mCurrentMimeType) != LLMIMETypes::implType(mime_type)); if(!mMediaSource || pluginChanged) { @@ -1127,6 +1127,9 @@ bool LLViewerMediaImpl::initializePlugin(const std::string& media_type) // If we got here, we want to ignore previous init failures. mMediaSourceFailed = false; + // Save the MIME type that really caused the plugin to load + mCurrentMimeType = mMimeType; + LLPluginClassMedia* media_source = newSourceFromMediaType(mMimeType, this, mMediaWidth, mMediaHeight); if (media_source) @@ -1563,6 +1566,7 @@ void LLViewerMediaImpl::unload() mMediaURL.clear(); mMimeType.clear(); mCurrentMediaURL.clear(); + mCurrentMimeType.clear(); } ////////////////////////////////////////////////////////////////////////////////////////// @@ -2123,7 +2127,7 @@ void LLViewerMediaImpl::handleMediaEvent(LLPluginClassMedia* plugin, LLPluginCla // TODO: may want a different message for this case? LLSD args; - args["PLUGIN"] = LLMIMETypes::implType(mMimeType); + args["PLUGIN"] = LLMIMETypes::implType(mCurrentMimeType); LLNotificationsUtil::add("MediaPluginFailed", args); } break; @@ -2137,7 +2141,7 @@ void LLViewerMediaImpl::handleMediaEvent(LLPluginClassMedia* plugin, LLPluginCla resetPreviousMediaState(); LLSD args; - args["PLUGIN"] = LLMIMETypes::implType(mMimeType); + args["PLUGIN"] = LLMIMETypes::implType(mCurrentMimeType); // SJB: This is getting called every frame if the plugin fails to load, continuously respawining the alert! //LLNotificationsUtil::add("MediaPluginFailed", args); } diff --git a/indra/newview/llviewermedia.h b/indra/newview/llviewermedia.h index 28fb379960..9119b783c2 100644 --- a/indra/newview/llviewermedia.h +++ b/indra/newview/llviewermedia.h @@ -187,6 +187,7 @@ public: std::string getMediaURL() const { return mMediaURL; } std::string getCurrentMediaURL(); std::string getHomeURL() { return mHomeURL; } + std::string getMediaEntryURL() { return mMediaEntryURL; } void setHomeURL(const std::string& home_url) { mHomeURL = home_url; }; void clearCache(); std::string getMimeType() { return mMimeType; } @@ -323,6 +324,7 @@ public: std::string mHomeURL; std::string mMimeType; std::string mCurrentMediaURL; // The most current media url from the plugin (via the "location changed" or "navigate complete" events). + std::string mCurrentMimeType; // The MIME type that caused the currently loaded plugin to be loaded. S32 mLastMouseX; // save the last mouse coord we get, so when we lose capture we can simulate a mouseup at that point. S32 mLastMouseY; S32 mMediaWidth; diff --git a/indra/newview/llviewermedia_streamingaudio.cpp b/indra/newview/llviewermedia_streamingaudio.cpp index e9293ac5a4..67b051e536 100644 --- a/indra/newview/llviewermedia_streamingaudio.cpp +++ b/indra/newview/llviewermedia_streamingaudio.cpp @@ -62,7 +62,7 @@ void LLStreamingAudio_MediaPlugins::start(const std::string& url) if (!mMediaPlugin) // lazy-init the underlying media plugin { mMediaPlugin = initializeMedia("audio/mpeg"); // assumes that whatever media implementation supports mp3 also supports vorbis. - llinfos << "steaming audio mMediaPlugin is now " << mMediaPlugin << llendl; + llinfos << "streaming audio mMediaPlugin is now " << mMediaPlugin << llendl; } if(!mMediaPlugin) diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp index 15855f154d..5445a79137 100644 --- a/indra/newview/llviewermenu.cpp +++ b/indra/newview/llviewermenu.cpp @@ -2466,7 +2466,7 @@ class LLViewJoystickFlycam : public view_listener_t class LLViewCheckJoystickFlycam : public view_listener_t { bool handleEvent(const LLSD& userdata) - { + { bool new_value = LLViewerJoystick::getInstance()->getOverrideCamera(); return new_value; } @@ -3704,6 +3704,7 @@ void reset_view_final( BOOL proceed ) } gAgent.resetView(TRUE, TRUE); + gAgent.setLookAt(LOOKAT_TARGET_CLEAR); } class LLViewLookAtLastChatter : public view_listener_t diff --git a/indra/newview/llviewerparcelmedia.cpp b/indra/newview/llviewerparcelmedia.cpp index 90a7ee98b9..86f0f4e04e 100644 --- a/indra/newview/llviewerparcelmedia.cpp +++ b/indra/newview/llviewerparcelmedia.cpp @@ -182,7 +182,7 @@ void LLViewerParcelMedia::play(LLParcel* parcel) if (!parcel) return; - if (!gSavedSettings.getBOOL("AudioSteamingMedia") || !gSavedSettings.getBOOL("AudioStreamingVideo")) + if (!gSavedSettings.getBOOL("AudioStreamingMedia") || !gSavedSettings.getBOOL("AudioStreamingVideo")) return; std::string media_url = parcel->getMediaURL(); @@ -594,8 +594,8 @@ bool callback_play_media(const LLSD& notification, const LLSD& response, LLParce if (option == 0) { gSavedSettings.setBOOL("AudioStreamingVideo", TRUE); - if(!gSavedSettings.getBOOL("AudioSteamingMedia")) - gSavedSettings.setBOOL("AudioSteamingMedia", TRUE); + if(!gSavedSettings.getBOOL("AudioStreamingMedia")) + gSavedSettings.setBOOL("AudioStreamingMedia", TRUE); LLViewerParcelMedia::play(parcel); } else diff --git a/indra/newview/llviewerparcelmgr.cpp b/indra/newview/llviewerparcelmgr.cpp index be68a2ef42..87a9eae028 100644 --- a/indra/newview/llviewerparcelmgr.cpp +++ b/indra/newview/llviewerparcelmgr.cpp @@ -1754,7 +1754,7 @@ void LLViewerParcelMgr::processParcelProperties(LLMessageSystem *msg, void **use void optionally_start_music(const std::string& music_url) { - if (gSavedSettings.getBOOL("AudioStreamingMusic") && gSavedSettings.getBOOL("AudioSteamingMedia")) + if (gSavedSettings.getBOOL("AudioStreamingMusic") && gSavedSettings.getBOOL("AudioStreamingMedia")) { // Make the user click the start button on the overlay bar. JC // llinfos << "Starting parcel music " << music_url << llendl; diff --git a/indra/newview/llviewertexture.cpp b/indra/newview/llviewertexture.cpp index b1ad01f54f..f825eaa8ab 100644 --- a/indra/newview/llviewertexture.cpp +++ b/indra/newview/llviewertexture.cpp @@ -2767,7 +2767,7 @@ void LLViewerMediaTexture::updateClass() #if 0 //force to play media. - gSavedSettings.setBOOL("AudioSteamingMedia", true) ; + gSavedSettings.setBOOL("AudioStreamingMedia", true) ; gSavedSettings.setBOOL("AudioStreamingVideo", true) ; #endif diff --git a/indra/newview/skins/default/xui/en/inspect_avatar.xml b/indra/newview/skins/default/xui/en/inspect_avatar.xml index 2f2964c42b..a666b8a427 100644 --- a/indra/newview/skins/default/xui/en/inspect_avatar.xml +++ b/indra/newview/skins/default/xui/en/inspect_avatar.xml @@ -65,7 +65,7 @@ <slider follows="top|left" height="23" - increment="0.05" + increment="0.01" left="1" max_val="0.95" min_val="0.05" diff --git a/indra/newview/skins/default/xui/en/panel_outfits_inventory.xml b/indra/newview/skins/default/xui/en/panel_outfits_inventory.xml index d6d8e9562b..7e512f9594 100644 --- a/indra/newview/skins/default/xui/en/panel_outfits_inventory.xml +++ b/indra/newview/skins/default/xui/en/panel_outfits_inventory.xml @@ -21,19 +21,6 @@ tab_position="top" halign="center" width="313"> - <inventory_panel - label="MY OUTFITS" - help_topic="my_outfits_tab" - allow_multi_select="true" - follows="all" - border="false" - left="0" - top="0" - height="500" - width="290" - mouse_opaque="true" - name="outfitslist_accordionpanel" - start_folder="My Outfits" /> <inventory_panel label="WEARING" help_topic="now_wearing_tab" @@ -46,6 +33,19 @@ mouse_opaque="true" name="cof_accordionpanel" start_folder="Current Outfit" /> + <inventory_panel + label="MY OUTFITS" + help_topic="my_outfits_tab" + allow_multi_select="true" + follows="all" + border="false" + left="0" + top="0" + height="500" + width="290" + mouse_opaque="true" + name="outfitslist_accordionpanel" + start_folder="My Outfits" /> </tab_container> <panel background_visible="true" diff --git a/indra/newview/skins/default/xui/en/panel_prim_media_controls.xml b/indra/newview/skins/default/xui/en/panel_prim_media_controls.xml index 677d0de243..4cef1f9c60 100644 --- a/indra/newview/skins/default/xui/en/panel_prim_media_controls.xml +++ b/indra/newview/skins/default/xui/en/panel_prim_media_controls.xml @@ -1,54 +1,99 @@ <?xml version="1.0" encoding="utf-8" standalone="yes" ?> <panel follows="left|right|top|bottom" - name="MediaControls" + name="MediaControlsPanel" background_visible="false" height="200" layout="topleft" help_topic="prim_media_controls" mouse_opaque="false" + min_width="300" width="800"> <string name="control_background_image_name">Inspector_Background</string> <string name="skip_step">0.2</string> - <string name="min_width">400</string> - <string name="min_height">120</string> + <string name="min_width">300</string> + <string name="min_height">75</string> <string name="zoom_near_padding">1.0</string> <string name="zoom_medium_padding">1.25</string> <string name="zoom_far_padding">1.5</string> - <panel - name="media_region" - height="100" - follows="left|right|top|bottom" + <string name="top_world_view_avoid_zone">50</string> + <layout_stack + name="progress_indicator_area" + follows="left|right|top" + height="8" layout="topleft" - mouse_opaque="false" - top="0" /> + animate="false" + left="0" + orientation="horizontal" + top="22"> + <!-- outer layout_panels center the inner one --> + <layout_panel + width="0" + name="left_bookend_bottom" + mouse_opaque="false" + layout="topleft" + user_resize="false" /> + <panel + name="media_progress_indicator" + mouse_opaque="false" + follows="left|right|top" + height="8" + layout="topleft" + left="0" + top="0" + auto_resize="false" + user_resize="false" + min_width="100" + width="200"> + <progress_bar + name="media_progress_bar" + color_bg="1 1 1 1" + color_bar="1 1 1 0.96" + follows="left|right|top" + height="8" + layout="topleft" + top="0" + left="0" + tool_tip="Media is Loading"/> + </panel> + <layout_panel + name="right_bookend_bottom" + width="0" + mouse_opaque="false" + layout="topleft" + user_resize="false" /> + </layout_stack> <layout_stack name="media_controls" - follows="left|right" + follows="left|right|top" animate="false" height="75" layout="topleft" + top="0" left="0" + border_size="1" mouse_opaque="false" - orientation="horizontal" - top="100"> + orientation="horizontal"> <!-- outer layout_panels center the inner one --> <layout_panel name="left_bookend" + top="0" width="0" - mouse_opaque="false" + mouse_opaque="false" layout="topleft" user_resize="false" /> <layout_panel name="back" + top="0" auto_resize="false" user_resize="false" layout="topleft" - mouse_opaque="false" + mouse_opaque="false" min_width="22" - width="22" - top="4"> + width="22"> <button + name="back_btn" + follows="top" image_overlay="Arrow_Left_Off" image_disabled="PushButton_Disabled" image_disabled_selected="PushButton_Disabled" @@ -56,12 +101,12 @@ image_unselected="PushButton_Off" hover_glow_amount="0.15" auto_resize="false" - height="22" layout="topleft" tool_tip="Navigate back" - width="22" + top="0" left="0" - top_delta="4"> + width="22" + height="22"> <button.commit_callback function="MediaCtrl.Back" /> </button> @@ -71,22 +116,24 @@ auto_resize="false" user_resize="false" layout="topleft" - top="10" min_width="22" + top="0" + height="22" width="22"> <button + follows="top" image_overlay="Arrow_Right_Off" image_disabled="PushButton_Disabled" image_disabled_selected="PushButton_Disabled" image_selected="PushButton_Selected" image_unselected="PushButton_Off" hover_glow_amount="0.15" + top="0" height="22" - layout="topleft" - tool_tip="Navigate forward" - top_delta="0" min_width="22" - width="22"> + width="22" + layout="topleft" + tool_tip="Navigate forward"> <button.commit_callback function="MediaCtrl.Forward" /> </button> @@ -96,10 +143,12 @@ auto_resize="false" user_resize="false" layout="topleft" - top="-2" + top="0" + height="22" min_width="22" width="22"> <button + follows="top" image_disabled="PushButton_Disabled" image_disabled_selected="PushButton_Disabled" image_overlay="Home_Off" @@ -108,6 +157,7 @@ hover_glow_amount="0.15" layout="topleft" tool_tip="Home page" + top="0" height="22" min_width="22" width="22"> @@ -120,19 +170,22 @@ auto_resize="false" user_resize="false" layout="topleft" - top="2" + top="0" + height="22" min_width="22" width="22"> <button + follows="top" image_overlay="Stop_Off" image_disabled="PushButton_Disabled" image_disabled_selected="PushButton_Disabled" image_selected="PushButton_Selected" image_unselected="PushButton_Off" hover_glow_amount="0.15" - height="22" layout="topleft" tool_tip="Stop media" + top="0" + height="22" min_width="22" width="22"> <button.commit_callback @@ -144,11 +197,12 @@ auto_resize="false" user_resize="false" layout="topleft" - top="6" + top="0" + height="22" min_width="22" width="22"> <button - height="22" + follows="top" image_overlay="Refresh_Off" image_disabled="PushButton_Disabled" image_disabled_selected="PushButton_Disabled" @@ -157,6 +211,8 @@ hover_glow_amount="0.15" layout="topleft" tool_tip="Reload" + top="0" + height="22" min_width="22" width="22"> <button.commit_callback @@ -168,11 +224,12 @@ auto_resize="false" user_resize="false" layout="topleft" - top="10" + top="0" + height="22" min_width="22" width="22"> <button - height="22" + follows="top" image_overlay="StopReload_Off" image_disabled="PushButton_Disabled" image_disabled_selected="PushButton_Disabled" @@ -181,6 +238,8 @@ hover_glow_amount="0.15" layout="topleft" tool_tip = "Stop loading" + top="0" + height="22" min_width="22" width="22"> <button.commit_callback @@ -192,10 +251,12 @@ auto_resize="false" user_resize="false" layout="topleft" - top="14" + top="0" + height="22" min_width="22" width="24"> <button + follows="top" image_overlay="Play_Off" image_disabled="PushButton_Disabled" image_disabled_selected="PushButton_Disabled" @@ -205,7 +266,7 @@ layout="topleft" tool_tip = "Play media" left_delta="2" - top="4" + top="0" height="22" min_width="22" width="22"> @@ -218,10 +279,11 @@ auto_resize="false" user_resize="false" layout="topleft" - top="18" + top="0" min_width="22" width="24"> <button + follows="top" image_overlay="Pause_Off" image_disabled="PushButton_Disabled" image_disabled_selected="PushButton_Disabled" @@ -229,10 +291,10 @@ image_unselected="PushButton_Off" hover_glow_amount="0.15" layout="topleft" + top="0" height="22" width="22" left_delta="-1" - top="4" tool_tip = "Pause media"> <button.commit_callback function="MediaCtrl.Pause" /> @@ -246,11 +308,12 @@ height="24" follows="left|right|bottom" layout="topleft" + top="0" width="190" min_width="90"> <line_editor name="media_address_url" - follows="left|right" + follows="top|left|right" height="22" top="0" tool_tip="Media URL" @@ -261,17 +324,18 @@ <layout_stack name="media_address_url_icons" animate="false" - follows="right" + follows="top|right" height="20" width="38" - right="-2" - top="-1" - mouse_opaque="false" + top="0" + right="-1" + border_size="0" + mouse_opaque="false" orientation="horizontal"> <layout_panel layout="topleft" width="16" - mouse_opaque="false" + mouse_opaque="false" auto_resize="false" user_resize="false"> <icon @@ -287,7 +351,7 @@ <layout_panel layout="topleft" width="16" - mouse_opaque="false" + mouse_opaque="false" auto_resize="false" user_resize="false"> <icon @@ -305,16 +369,17 @@ name="media_play_position" auto_resize="true" user_resize="false" - follows="left|right|top|bottom" + follows="left|right" layout="topleft" - height="16" + top="0" + height="22" min_width="100" width="200"> <slider_bar name="media_play_slider" follows="left|right|top" - height="20" - bottom="88" + top="0" + height="22" increment="0.01" initial_value="0.5" layout="topleft" @@ -330,9 +395,11 @@ auto_resize="false" user_resize="false" layout="topleft" + top="0" min_width="22" width="22"> <button + follows="top" image_overlay="SkipBackward_Off" image_disabled="PushButton_Disabled" image_disabled_selected="PushButton_Disabled" @@ -343,7 +410,7 @@ height="22" layout="topleft" tool_tip="Step back" - top="-14" + top="0" width="22" left="0"> <button.commit_callback @@ -355,9 +422,11 @@ auto_resize="false" user_resize="false" layout="topleft" + top="0" min_width="22" width="22"> <button + follows="top" image_overlay="SkipForward_Off" image_disabled="PushButton_Disabled" image_disabled_selected="PushButton_Disabled" @@ -367,7 +436,7 @@ height="22" layout="topleft" tool_tip="Step forward" - top="-14" + top="0" min_width="22" width="22"> <button.commit_callback @@ -379,26 +448,28 @@ auto_resize="false" user_resize="false" layout="topleft" - top="-50" + top="0" height="72" min_width="22" width="22"> <!-- Note: this is not quite right either...the mute button is not the --> <!-- same as the others because it cannot have the "image_overlay" be --> <!-- two different images. --> + <!-- Note also: the button and the slider must overlap! --> <button + follows="top" image_disabled="PushButton_Disabled" image_disabled_selected="PushButton_Disabled" image_selected="AudioMute_Off" image_unselected="Audio_Off" hover_glow_amount="0.15" name="media_mute_button" - height="22" is_toggle="true" layout="topleft" scale_image="false" tool_tip="Mute This Media" - top="118" + top="0" + height="20" min_width="22" width="22" > <button.commit_callback @@ -411,7 +482,7 @@ <slider orientation="vertical" left="0" - top="-2" + top="16" height="50" layout="topleft" increment="0.01" @@ -428,35 +499,24 @@ function="MediaCtrl.HideVolumeSlider" /> </slider> </layout_panel> - <panel - height="28" - layout="topleft" - auto_resize="false" - min_width="3" - width="3"> - <icon - height="26" - image_name="media_panel_divider.png" - layout="topleft" - top="0" - min_width="3" - width="3" /> - </panel> <layout_panel name="zoom_frame" auto_resize="false" user_resize="false" layout="topleft" + top="0" height="28" min_width="22" width="22"> <button + follows="top" image_overlay="Zoom_Off" image_disabled="PushButton_Disabled" image_disabled_selected="PushButton_Disabled" image_selected="PushButton_Selected" image_unselected="PushButton_Off" hover_glow_amount="0.15" + top="0" height="22" layout="topleft" tool_tip="Zoom into media" @@ -471,15 +531,18 @@ auto_resize="false" user_resize="false" layout="topleft" + top="0" min_width="21" width="21" > <button + follows="top" image_overlay="UnZoom_Off" image_disabled="PushButton_Disabled" image_disabled_selected="PushButton_Disabled" image_selected="PushButton_Selected" image_unselected="PushButton_Off" hover_glow_amount="0.15" + top="0" height="22" layout="topleft" tool_tip ="Zoom Back" @@ -494,9 +557,11 @@ auto_resize="false" user_resize="false" layout="topleft" + top="0" min_width="22" width="22"> <button + follows="top" image_overlay="ExternalBrowser_Off" image_disabled="PushButton_Disabled" image_disabled_selected="PushButton_Disabled" @@ -506,7 +571,7 @@ height="22" layout="topleft" tool_tip = "Open URL in browser" - top_delta="-4" + top="0" min_width="24" width="24" > <button.commit_callback @@ -516,46 +581,16 @@ <!-- bookend panel --> <layout_panel name="right_bookend" - width="0" - layout="topleft" - user_resize="false" /> - </layout_stack> - <layout_stack - follows="left|right|bottom" - height="20" - layout="topleft" - animate="false" - left="0" - orientation="horizontal" - top="170"> - <!-- outer layout_panels center the inner one --> - <layout_panel - width="0" - layout="topleft" - user_resize="false" /> - <panel - name="media_progress_indicator" - height="20" - layout="topleft" - left="0" top="0" - auto_resize="false" - user_resize="false" - min_width="100" - width="200"> - <progress_bar - name="media_progress_bar" - color_bar="1 1 1 0.96" - follows="left|right|top" - top="5" - height="8" - layout="topleft" - left="0" - tool_tip="Media is Loading"/> - </panel> - <layout_panel width="0" layout="topleft" user_resize="false" /> </layout_stack> + <panel + name="media_region" + height="100" + follows="left|right|top|bottom" + layout="topleft" + mouse_opaque="false" + top="30" /> </panel> |