diff options
| author | simon <none@none> | 2013-03-25 11:12:52 -0700 |
|---|---|---|
| committer | simon <none@none> | 2013-03-25 11:12:52 -0700 |
| commit | 98a82c50d539451e1931826ca75fbc01d611806d (patch) | |
| tree | 3c3dcac20286246f0724c11f126233702f0bdaaf /indra/newview/lltoolbarview.cpp | |
| parent | 94ae64d6fd30e4dbc3280cd277f772c038ccd9fe (diff) | |
| parent | 515f0e5a559ff3f0cb7d02e1d40b0f71425800ea (diff) | |
Pull in downstream CHUI code from viewer-development
Diffstat (limited to 'indra/newview/lltoolbarview.cpp')
| -rw-r--r-- | indra/newview/lltoolbarview.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/indra/newview/lltoolbarview.cpp b/indra/newview/lltoolbarview.cpp index a29f58b319..b2318f9158 100644 --- a/indra/newview/lltoolbarview.cpp +++ b/indra/newview/lltoolbarview.cpp @@ -241,8 +241,9 @@ bool LLToolBarView::loadToolbars(bool force_default) LLXUIParser parser; if (!err) { - parser.readXUI(root, toolbar_set, toolbar_file); + parser.readXUI(root, toolbar_set, toolbar_file); } + if (!err && !toolbar_set.validateBlock()) { llwarns << "Unable to validate toolbars from file: " << toolbar_file << llendl; @@ -254,8 +255,9 @@ bool LLToolBarView::loadToolbars(bool force_default) if (force_default) { llerrs << "Unable to load toolbars from default file : " << toolbar_file << llendl; - return false; - } + return false; + } + // Try to load the default toolbars return loadToolbars(true); } @@ -605,7 +607,7 @@ BOOL LLToolBarView::handleDragTool( S32 x, S32 y, const LLUUID& uuid, LLAssetTyp BOOL LLToolBarView::handleDropTool( void* cargo_data, S32 x, S32 y, LLToolBar* toolbar) { BOOL handled = FALSE; - LLInventoryItem* inv_item = (LLInventoryItem*)cargo_data; + LLInventoryObject* inv_item = static_cast<LLInventoryObject*>(cargo_data); LLAssetType::EType type = inv_item->getType(); if (type == LLAssetType::AT_WIDGET) |
