(svn r13027) -Codechange: use StrEmpty instead of arr[0] == '\0' and remove the need for WE_ON_EDIT_TEXT_CANCEL.

This commit is contained in:
rubidium
2008-05-10 08:58:52 +00:00
parent 8ebfbc2bd3
commit 2c96ce4506
12 changed files with 32 additions and 21 deletions

View File

@@ -27,6 +27,7 @@
#include "settings_type.h"
#include "gfx_func.h"
#include "widgets/dropdown_func.h"
#include "string_func.h"
#include "table/sprites.h"
#include "table/strings.h"
@@ -1136,7 +1137,7 @@ static void NewVehicleWndProc(Window *w, WindowEvent *e)
break;
case WE_ON_EDIT_TEXT: {
if (e->we.edittext.str[0] != '\0') {
if (!StrEmpty(e->we.edittext.str)) {
StringID str = STR_NULL;
_cmd_text = e->we.edittext.str;
switch (bv->vehicle_type) {