diff options
author | Richard Nelson <none@none> | 2010-07-30 10:02:30 -0700 |
---|---|---|
committer | Richard Nelson <none@none> | 2010-07-30 10:02:30 -0700 |
commit | 566e3969f98c7ac10fe151ba119a78ac5eda2e3c (patch) | |
tree | 1cc7ae3cfca94a0417d9de1fe600304b7cf7cc6c /indra/newview/llpreviewscript.cpp | |
parent | 147bc94274719db95462d2907872f52efe4fcb3d (diff) |
deprecated LLPanel::child*() methods
Diffstat (limited to 'indra/newview/llpreviewscript.cpp')
-rw-r--r-- | indra/newview/llpreviewscript.cpp | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/indra/newview/llpreviewscript.cpp b/indra/newview/llpreviewscript.cpp index 7b926f468d..73845e2772 100644 --- a/indra/newview/llpreviewscript.cpp +++ b/indra/newview/llpreviewscript.cpp @@ -219,7 +219,7 @@ void LLFloaterScriptSearch::onBtnSearch(void *userdata) void LLFloaterScriptSearch::handleBtnSearch() { LLCheckBoxCtrl* caseChk = getChild<LLCheckBoxCtrl>("case_text"); - mEditorCore->mEditor->selectNext(childGetText("search_text"), caseChk->get()); + mEditorCore->mEditor->selectNext(getChild<LLUICtrl>("search_text")->getValue().asString(), caseChk->get()); } // static @@ -232,7 +232,7 @@ void LLFloaterScriptSearch::onBtnReplace(void *userdata) void LLFloaterScriptSearch::handleBtnReplace() { LLCheckBoxCtrl* caseChk = getChild<LLCheckBoxCtrl>("case_text"); - mEditorCore->mEditor->replaceText(childGetText("search_text"), childGetText("replace_text"), caseChk->get()); + mEditorCore->mEditor->replaceText(getChild<LLUICtrl>("search_text")->getValue().asString(), getChild<LLUICtrl>("replace_text")->getValue().asString(), caseChk->get()); } // static @@ -245,7 +245,7 @@ void LLFloaterScriptSearch::onBtnReplaceAll(void *userdata) void LLFloaterScriptSearch::handleBtnReplaceAll() { LLCheckBoxCtrl* caseChk = getChild<LLCheckBoxCtrl>("case_text"); - mEditorCore->mEditor->replaceTextAll(childGetText("search_text"), childGetText("replace_text"), caseChk->get()); + mEditorCore->mEditor->replaceTextAll(getChild<LLUICtrl>("search_text")->getValue().asString(), getChild<LLUICtrl>("replace_text")->getValue().asString(), caseChk->get()); } @@ -457,7 +457,7 @@ bool LLScriptEdCore::hasChanged() void LLScriptEdCore::draw() { BOOL script_changed = hasChanged(); - childSetEnabled("Save_btn", script_changed); + getChildView("Save_btn")->setEnabled(script_changed); if( mEditor->hasFocus() ) { @@ -469,11 +469,11 @@ void LLScriptEdCore::draw() args["[LINE]"] = llformat ("%d", line); args["[COLUMN]"] = llformat ("%d", column); cursor_pos = LLTrans::getString("CursorPos", args); - childSetText("line_col", cursor_pos); + getChild<LLUICtrl>("line_col")->setValue(cursor_pos); } else { - childSetText("line_col", LLStringUtil::null); + getChild<LLUICtrl>("line_col")->setValue(LLStringUtil::null); } updateDynamicHelp(); @@ -666,7 +666,7 @@ void LLScriptEdCore::onBtnDynamicHelp() if (parent) parent->addDependentFloater(live_help_floater, TRUE); live_help_floater->childSetCommitCallback("lock_check", onCheckLock, this); - live_help_floater->childSetValue("lock_check", gSavedSettings.getBOOL("ScriptHelpFollowsCursor")); + live_help_floater->getChild<LLUICtrl>("lock_check")->setValue(gSavedSettings.getBOOL("ScriptHelpFollowsCursor")); live_help_floater->childSetCommitCallback("history_combo", onHelpComboCommit, this); live_help_floater->childSetAction("back_btn", onClickBack, this); live_help_floater->childSetAction("fwd_btn", onClickForward, this); @@ -959,10 +959,10 @@ BOOL LLPreviewLSL::postBuild() llassert(item); if (item) { - childSetText("desc", item->getDescription()); + getChild<LLUICtrl>("desc")->setValue(item->getDescription()); } childSetCommitCallback("desc", LLPreview::onText, this); - childSetPrevalidate("desc", &LLTextValidate::validateASCIIPrintableNoPipe); + getChild<LLLineEditor>("desc")->setPrevalidate(&LLTextValidate::validateASCIIPrintableNoPipe); return LLPreview::postBuild(); } @@ -1040,8 +1040,8 @@ void LLPreviewLSL::loadAsset() mScriptEd->mFunctions->setEnabled(FALSE); mAssetStatus = PREVIEW_ASSET_LOADED; } - childSetVisible("lock", !is_modifiable); - mScriptEd->childSetEnabled("Insert...", is_modifiable); + getChildView("lock")->setVisible( !is_modifiable); + mScriptEd->getChildView("Insert...")->setEnabled(is_modifiable); } else { @@ -1429,14 +1429,14 @@ LLLiveLSLEditor::LLLiveLSLEditor(const LLSD& key) : BOOL LLLiveLSLEditor::postBuild() { childSetCommitCallback("running", LLLiveLSLEditor::onRunningCheckboxClicked, this); - childSetEnabled("running", FALSE); + getChildView("running")->setEnabled(FALSE); childSetAction("Reset",&LLLiveLSLEditor::onReset,this); - childSetEnabled("Reset", TRUE); + getChildView("Reset")->setEnabled(TRUE); mMonoCheckbox = getChild<LLCheckBoxCtrl>("mono"); childSetCommitCallback("mono", &LLLiveLSLEditor::onMonoCheckboxClicked, this); - childSetEnabled("mono", FALSE); + getChildView("mono")->setEnabled(FALSE); mScriptEd->mEditor->makePristine(); mScriptEd->mEditor->setFocus(TRUE); |