diff options
author | Jacek Antonelli | 2008-08-15 23:44:59 -0500 |
---|---|---|
committer | Jacek Antonelli | 2008-08-15 23:44:59 -0500 |
commit | a408bac29378072fbf36864164149458c978cfcc (patch) | |
tree | 67feccf1a5d3816611ba48d6762f86f0f7f4b1f6 /linden/indra/newview/llpaneldirclassified.cpp | |
parent | Second Life viewer sources 1.17.0.12 (diff) | |
download | meta-impy-a408bac29378072fbf36864164149458c978cfcc.zip meta-impy-a408bac29378072fbf36864164149458c978cfcc.tar.gz meta-impy-a408bac29378072fbf36864164149458c978cfcc.tar.bz2 meta-impy-a408bac29378072fbf36864164149458c978cfcc.tar.xz |
Second Life viewer sources 1.17.1.0
Diffstat (limited to 'linden/indra/newview/llpaneldirclassified.cpp')
-rw-r--r-- | linden/indra/newview/llpaneldirclassified.cpp | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/linden/indra/newview/llpaneldirclassified.cpp b/linden/indra/newview/llpaneldirclassified.cpp index 8b4a49d..276b608 100644 --- a/linden/indra/newview/llpaneldirclassified.cpp +++ b/linden/indra/newview/llpaneldirclassified.cpp | |||
@@ -55,6 +55,7 @@ | |||
55 | #include "llpaneldirbrowser.h" | 55 | #include "llpaneldirbrowser.h" |
56 | #include "lltextbox.h" | 56 | #include "lltextbox.h" |
57 | #include "llviewermessage.h" | 57 | #include "llviewermessage.h" |
58 | #include "llvieweruictrlfactory.h" | ||
58 | #include "llworldmap.h" | 59 | #include "llworldmap.h" |
59 | 60 | ||
60 | // | 61 | // |
@@ -85,7 +86,8 @@ BOOL LLPanelDirClassified::postBuild() | |||
85 | childSetKeystrokeCallback("name", onKeystrokeNameClassified, this); | 86 | childSetKeystrokeCallback("name", onKeystrokeNameClassified, this); |
86 | 87 | ||
87 | childSetAction("Search", onClickSearchCore, this); | 88 | childSetAction("Search", onClickSearchCore, this); |
88 | setDefaultBtn( "Search" ); | 89 | childSetAction("Browse", onClickSearchCore, this); |
90 | setDefaultBtn( "Browse" ); | ||
89 | 91 | ||
90 | childSetAction("Place an Ad...", onClickCreateNewClassified, this); | 92 | childSetAction("Place an Ad...", onClickCreateNewClassified, this); |
91 | 93 | ||
@@ -186,6 +188,7 @@ void LLPanelDirClassified::performQuery() | |||
186 | void LLPanelDirClassified::onKeystrokeNameClassified(LLLineEditor* line, void* data) | 188 | void LLPanelDirClassified::onKeystrokeNameClassified(LLLineEditor* line, void* data) |
187 | { | 189 | { |
188 | LLPanelDirClassified *self = (LLPanelDirClassified*)data; | 190 | LLPanelDirClassified *self = (LLPanelDirClassified*)data; |
191 | |||
189 | S32 len = line->getLength(); | 192 | S32 len = line->getLength(); |
190 | if (len == 0 | 193 | if (len == 0 |
191 | || len >= 3) | 194 | || len >= 3) |
@@ -199,4 +202,17 @@ void LLPanelDirClassified::onKeystrokeNameClassified(LLLineEditor* line, void* d | |||
199 | self->setDefaultBtn(); | 202 | self->setDefaultBtn(); |
200 | self->childDisable("Search"); | 203 | self->childDisable("Search"); |
201 | } | 204 | } |
205 | |||
206 | // Change the Browse to Search or vice versa | ||
207 | if (len > 0) | ||
208 | { | ||
209 | self->childSetVisible("Search", TRUE); | ||
210 | self->childSetVisible("Browse", FALSE); | ||
211 | } | ||
212 | else | ||
213 | { | ||
214 | self->setDefaultBtn( "Browse" ); | ||
215 | self->childSetVisible("Search", FALSE); | ||
216 | self->childSetVisible("Browse", TRUE); | ||
217 | } | ||
202 | } | 218 | } |