Ticket #8048: diggui.diff

File diggui.diff, 1.9 KB (added by eriktorbjorn, 22 years ago)

Patch against a September 14 CVS snapshot

  • scummvm/gui/gui.cpp

    diff -ur ScummVM-cvs20020914/scummvm/gui/gui.cpp ScummVM-cvs20020914+hack/scummvm/gui/gui.cpp
    old new  
    2929#include "config-file.h"
    3030
    3131#include <ctype.h>
     32#include <string.h>
    3233
    3334#define hline(x, y, x2, color) line(x, y, x2, y, color);
    3435#define vline(x, y, y2, color) line(x, y, x, y2, color);
     
    931932
    932933        result = (char *)_s->getStringAddress(string);
    933934
     935        if (result && *result == '/') {
     936                result = strchr(result + 1, '/');
     937                if (result != NULL)
     938                        result++;
     939        }
     940       
    934941        if (!result) {                                                                  // Gracelessly degrade to english :)
    935                 if (_s->_features & GF_AFTER_V6)
     942                if (_s->_features & GF_AFTER_V7)
     943                        return string_map_table_v7[stringno - 1].string;
     944                else if (_s->_features & GF_AFTER_V6)
    936945                        return string_map_table_v6[stringno - 1].string;
    937946                else
    938947                        return string_map_table_v5[stringno - 1].string;
  • scummvm/gui/newgui.cpp

    diff -ur ScummVM-cvs20020914/scummvm/gui/newgui.cpp ScummVM-cvs20020914+hack/scummvm/gui/newgui.cpp
    old new  
    2626#include "guimaps.h"
    2727#include "dialog.h"
    2828
     29#include <string.h>
     30
    2931/*
    3032 * TODO list
    3133 * - implement the missing / incomplete dialogs
     
    281283
    282284        result = (char *)_s->getStringAddress(string);
    283285
     286        if (result && *result == '/') {
     287                result = strchr(result + 1, '/');
     288                if (result)
     289                        result++;
     290        }
     291
    284292        if (!result) {                                                          // Gracelessly degrade to english :)
    285                 if (_s->_features & GF_AFTER_V6)
     293                if (_s->_features & GF_AFTER_V7)
     294                        return string_map_table_v7[stringno - 1].string;
     295                else if (_s->_features & GF_AFTER_V6)
    286296                        return string_map_table_v6[stringno - 1].string;
    287297                else
    288298                        return string_map_table_v5[stringno - 1].string;