mirror of https://github.com/stella-emu/stella.git
Fixed some compiler warnings picked up by Xcode 4.3
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2417 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
This commit is contained in:
parent
89cd0b897d
commit
5ce726f180
|
@ -818,7 +818,7 @@ int DiStella::mark(uInt32 address, uInt8 mask, bool directive)
|
||||||
if(directive) myDirectives[address-myOffset] = mask;
|
if(directive) myDirectives[address-myOffset] = mask;
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
else if (address >= 0 && address <= 0x3f)
|
else if (address <= 0x3f)
|
||||||
{
|
{
|
||||||
return 2;
|
return 2;
|
||||||
}
|
}
|
||||||
|
|
|
@ -637,7 +637,7 @@ void DataGridWidget::startEditMode()
|
||||||
if (_editable && !_editMode && _selectedItem >= 0)
|
if (_editable && !_editMode && _selectedItem >= 0)
|
||||||
{
|
{
|
||||||
_editMode = true;
|
_editMode = true;
|
||||||
setEditString(""); // Erase current entry when starting editing
|
setEditString("", true ); // Erase current entry when starting editing
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -150,8 +150,7 @@ Console::Console(OSystem* osystem, Cartridge* cart, const Properties& props)
|
||||||
|
|
||||||
// TODO - query these values directly from the TIA if value is 'AUTO'
|
// TODO - query these values directly from the TIA if value is 'AUTO'
|
||||||
uInt32 ystart = atoi(myProperties.get(Display_YStart).c_str());
|
uInt32 ystart = atoi(myProperties.get(Display_YStart).c_str());
|
||||||
if(ystart < 0) ystart = 0;
|
if(ystart > 64) ystart = 64;
|
||||||
else if(ystart > 64) ystart = 64;
|
|
||||||
uInt32 height = atoi(myProperties.get(Display_Height).c_str());
|
uInt32 height = atoi(myProperties.get(Display_Height).c_str());
|
||||||
if(height < 210) height = 210;
|
if(height < 210) height = 210;
|
||||||
else if(height > 256) height = 256;
|
else if(height > 256) height = 256;
|
||||||
|
@ -537,21 +536,21 @@ void Console::changeYStart(int direction)
|
||||||
|
|
||||||
if(direction == +1) // increase YStart
|
if(direction == +1) // increase YStart
|
||||||
{
|
{
|
||||||
ystart++;
|
if(ystart >= 64)
|
||||||
if(ystart > 64)
|
|
||||||
{
|
{
|
||||||
myOSystem->frameBuffer().showMessage("YStart at maximum");
|
myOSystem->frameBuffer().showMessage("YStart at maximum");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
ystart++;
|
||||||
}
|
}
|
||||||
else if(direction == -1) // decrease YStart
|
else if(direction == -1) // decrease YStart
|
||||||
{
|
{
|
||||||
ystart--;
|
if(ystart == 0)
|
||||||
if(ystart < 0)
|
|
||||||
{
|
{
|
||||||
myOSystem->frameBuffer().showMessage("YStart at minimum");
|
myOSystem->frameBuffer().showMessage("YStart at minimum");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
ystart--;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -149,7 +149,7 @@ uInt8 TIASound::get(uInt16 address) const
|
||||||
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||||
void TIASound::volume(uInt32 percent)
|
void TIASound::volume(uInt32 percent)
|
||||||
{
|
{
|
||||||
if((percent >= 0) && (percent <= 100))
|
if(percent <= 100)
|
||||||
myVolumePercentage = percent;
|
myVolumePercentage = percent;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -992,7 +992,7 @@ extern int ZEXPORT unzReadCurrentFile
|
||||||
return UNZ_PARAMERROR;
|
return UNZ_PARAMERROR;
|
||||||
|
|
||||||
|
|
||||||
if ((pfile_in_zip_read_info->read_buffer == NULL))
|
if (pfile_in_zip_read_info->read_buffer == NULL)
|
||||||
return UNZ_END_OF_LIST_OF_FILE;
|
return UNZ_END_OF_LIST_OF_FILE;
|
||||||
if (len==0)
|
if (len==0)
|
||||||
return 0;
|
return 0;
|
||||||
|
|
|
@ -44,7 +44,7 @@ EditTextWidget::EditTextWidget(GuiObject* boss, const GUI::Font& font,
|
||||||
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||||
void EditTextWidget::setEditString(const string& str, bool changed)
|
void EditTextWidget::setEditString(const string& str, bool changed)
|
||||||
{
|
{
|
||||||
EditableWidget::setEditString(str);
|
EditableWidget::setEditString(str, changed);
|
||||||
_backupString = str;
|
_backupString = str;
|
||||||
_changed = changed;
|
_changed = changed;
|
||||||
}
|
}
|
||||||
|
|
|
@ -36,7 +36,7 @@ class EditTextWidget : public EditableWidget
|
||||||
|
|
||||||
void setEditString(const string& str, bool changed = false);
|
void setEditString(const string& str, bool changed = false);
|
||||||
|
|
||||||
virtual void handleMouseDown(int x, int y, int button, int clickCount);
|
void handleMouseDown(int x, int y, int button, int clickCount);
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void drawWidget(bool hilite);
|
void drawWidget(bool hilite);
|
||||||
|
|
|
@ -51,7 +51,7 @@ EditableWidget::~EditableWidget()
|
||||||
}
|
}
|
||||||
|
|
||||||
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||||
void EditableWidget::setEditString(const string& str)
|
void EditableWidget::setEditString(const string& str, bool)
|
||||||
{
|
{
|
||||||
// TODO: We probably should filter the input string here,
|
// TODO: We probably should filter the input string here,
|
||||||
// e.g. using tryInsertChar.
|
// e.g. using tryInsertChar.
|
||||||
|
|
|
@ -43,7 +43,7 @@ class EditableWidget : public Widget, public CommandSender
|
||||||
int x, int y, int w, int h);
|
int x, int y, int w, int h);
|
||||||
virtual ~EditableWidget();
|
virtual ~EditableWidget();
|
||||||
|
|
||||||
virtual void setEditString(const string& str);
|
virtual void setEditString(const string& str, bool changed = false);
|
||||||
virtual const string& getEditString() const { return _editString; }
|
virtual const string& getEditString() const { return _editString; }
|
||||||
|
|
||||||
bool isEditable() const { return _editable; }
|
bool isEditable() const { return _editable; }
|
||||||
|
|
Loading…
Reference in New Issue