diff options
| author | jacksonmj <mj-pt@jacksonmj.co.uk> | 2012-05-26 21:24:02 (GMT) |
|---|---|---|
| committer | jacksonmj <mj-pt@jacksonmj.co.uk> | 2012-05-26 21:24:02 (GMT) |
| commit | ebda0f9b4d8e7d8e8857e91f1184f279adfaf64a (patch) | |
| tree | 46427282b1a24347d0eb7f509fd4744b498a5329 /src/interface.c | |
| parent | 961efc9d2fe63da596f90a945c38986524e1e8e1 (diff) | |
| download | powder-ebda0f9b4d8e7d8e8857e91f1184f279adfaf64a.zip powder-ebda0f9b4d8e7d8e8857e91f1184f279adfaf64a.tar.gz | |
Don't show disabled elements in element search
Diffstat (limited to 'src/interface.c')
| -rw-r--r-- | src/interface.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/interface.c b/src/interface.c index 1af2e91..c1b8df2 100644 --- a/src/interface.c +++ b/src/interface.c @@ -1055,7 +1055,7 @@ void element_search_ui(pixel *vid_buf, int * slp, int * srp) { c = 0; while (ptypes[i].name[c]) { tempCompare[c] = tolower(ptypes[i].name[c]); c++; } tempCompare[c] = 0; - if(strstr(tempCompare, tempString)!=0) + if(strstr(tempCompare, tempString)!=0 && ptypes[i].enabled) { if(firstResult==-1) firstResult = i; @@ -1100,7 +1100,7 @@ void element_search_ui(pixel *vid_buf, int * slp, int * srp) { c = 0; while (ptypes[i].descs[c]) { tempCompare[c] = tolower(ptypes[i].descs[c]); c++; } tempCompare[c] = 0; - if(strstr(tempCompare, tempString)!=0) + if(strstr(tempCompare, tempString)!=0 && ptypes[i].enabled) { tempInts[found].first = strstr(tempCompare, tempString); tempInts[found++].second = i; |
