diff options
author | Strangerke | 2013-09-04 10:03:47 +0200 |
---|---|---|
committer | Strangerke | 2013-09-04 10:03:47 +0200 |
commit | a8d9978de8440bb402f55cdaf0338b947e346491 (patch) | |
tree | 7da13edbc2cd9928bfd8c4db879730c2fe01e79f /engines | |
parent | ccba9863eb3494ad7be532bf4458e752620dca2b (diff) | |
download | scummvm-rg350-a8d9978de8440bb402f55cdaf0338b947e346491.tar.gz scummvm-rg350-a8d9978de8440bb402f55cdaf0338b947e346491.tar.bz2 scummvm-rg350-a8d9978de8440bb402f55cdaf0338b947e346491.zip |
AVALANCHE: Silent a sign mismatch warning, improve loop condition
Diffstat (limited to 'engines')
-rw-r--r-- | engines/avalanche/dropdown2.cpp | 6 | ||||
-rw-r--r-- | engines/avalanche/dropdown2.h | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/engines/avalanche/dropdown2.cpp b/engines/avalanche/dropdown2.cpp index 224fb0128c..4ef65046cc 100644 --- a/engines/avalanche/dropdown2.cpp +++ b/engines/avalanche/dropdown2.cpp @@ -106,7 +106,7 @@ void onemenu::start_afresh() { } void onemenu::opt(Common::String n, char tr, Common::String key, bool val) { - int16 l = (n + key).size() + 3; + uint16 l = (n + key).size() + 3; if (width < l) width = l; @@ -127,9 +127,9 @@ void onemenu::displayopt(byte y, bool highlit) { //bar((flx1 + 1) * 8, 3 + y * 10, (flx2 + 1) * 8, 12 + y * 10); Common::String data = oo[y].title; - while ((data + oo[y].shortcut).size() < width) + while (data.size() + oo[y].shortcut.size() < width) data += ' '; /* Pad oo[y] spaces. */ - data = data + oo[y].shortcut; + data += oo[y].shortcut; if (highlit) _dr->hlchalk(left, 4 + (y + 1) * 10, oo[y].trigger, data, oo[y].valid); diff --git a/engines/avalanche/dropdown2.h b/engines/avalanche/dropdown2.h index 73325a30bc..f0f3917457 100644 --- a/engines/avalanche/dropdown2.h +++ b/engines/avalanche/dropdown2.h @@ -72,7 +72,7 @@ class onemenu { public: optiontype oo[12]; byte number; - int16 width, left; + uint16 width, left; bool firstlix; int16 flx1, flx2, fly; byte oldy; /* used by Lightup */ |