[Scummvm-git-logs] scummvm master -> 47a0ab346abfa20072493bd3e4faf7c827202ab7
sev-
sev at scummvm.org
Mon Apr 27 12:55:13 UTC 2020
This automated email contains information about 7 new commits which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
6fcc39810e GUI: Added sanity check
bc378c6999 GUI: Initialize variable and remove redundant check
1b01ecc511 GRAPHICS: Const'ness
86712a3680 GUI: Initialize class variables in ListWidget
3a0ddbf667 GUI: Added sanity check
20334118b9 GUI: Added sanity check to ThemeEngine
47a0ab346a GRAPHICS: Fix potential sign extension
Commit: 6fcc39810e6aa60a805818abb7dee9c0502f2670
https://github.com/scummvm/scummvm/commit/6fcc39810e6aa60a805818abb7dee9c0502f2670
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2020-04-27T14:04:04+02:00
Commit Message:
GUI: Added sanity check
Changed paths:
gui/saveload.cpp
diff --git a/gui/saveload.cpp b/gui/saveload.cpp
index f9b32d613d..a6036eaef4 100644
--- a/gui/saveload.cpp
+++ b/gui/saveload.cpp
@@ -77,6 +77,9 @@ Common::String SaveLoadChooser::createDefaultSaveDescription(const int slot) con
int SaveLoadChooser::runModalWithCurrentTarget() {
const Plugin *plugin = EngineMan.findPlugin(ConfMan.get("engineid"));
+ if (!plugin) {
+ error("SaveLoadChooser::runModalWithCurrentTarget(): Cannot find plugin");
+ }
return runModalWithPluginAndTarget(plugin, ConfMan.getActiveDomainName());
}
Commit: bc378c69998c210d6ae34036393af87647bf1797
https://github.com/scummvm/scummvm/commit/bc378c69998c210d6ae34036393af87647bf1797
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2020-04-27T14:38:58+02:00
Commit Message:
GUI: Initialize variable and remove redundant check
Changed paths:
gui/about.cpp
diff --git a/gui/about.cpp b/gui/about.cpp
index c1ac23e9aa..f38d0b4e92 100644
--- a/gui/about.cpp
+++ b/gui/about.cpp
@@ -779,9 +779,9 @@ bool EE::moveball() {
hitfloor = true;
}
- if (rbvely > 0)
- rbvely += 1;
- else
+ //if (rbvely > 0) // Checked with original, this is how it is
+ // rbvely += 1;
+ //else
rbvely += 1;
_tbx = _bx >> 6;
@@ -1085,6 +1085,8 @@ void EE::init() {
_serve = _servevel = 1;
_rmode = false;
+
+ _shouldQuit = false;
}
void EE::drawStatus(Common::String str, int x, uint32 color, int y, int color2, int w) {
Commit: 1b01ecc511dc4cd6345fb1e1484a0aac4219244c
https://github.com/scummvm/scummvm/commit/1b01ecc511dc4cd6345fb1e1484a0aac4219244c
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2020-04-27T14:42:08+02:00
Commit Message:
GRAPHICS: Const'ness
Changed paths:
gui/remotebrowser.cpp
gui/remotebrowser.h
diff --git a/gui/remotebrowser.cpp b/gui/remotebrowser.cpp
index 6c6c88d79a..ffc066976b 100644
--- a/gui/remotebrowser.cpp
+++ b/gui/remotebrowser.cpp
@@ -186,7 +186,7 @@ void RemoteBrowserDialog::goUp() {
listDirectory(Cloud::StorageFile(path, 0, 0, true));
}
-void RemoteBrowserDialog::listDirectory(Cloud::StorageFile node) {
+void RemoteBrowserDialog::listDirectory(const Cloud::StorageFile &node) {
if (_navigationLocked || _workingRequest)
return;
diff --git a/gui/remotebrowser.h b/gui/remotebrowser.h
index ae9353b43e..df75aac294 100644
--- a/gui/remotebrowser.h
+++ b/gui/remotebrowser.h
@@ -64,7 +64,7 @@ protected:
void updateListing();
void goUp();
- void listDirectory(Cloud::StorageFile node);
+ void listDirectory(const Cloud::StorageFile &node);
void directoryListedCallback(Cloud::Storage::ListDirectoryResponse response);
void directoryListedErrorCallback(Networking::ErrorResponse error);
Commit: 86712a3680a04f9df34db65a35e6fb021bed26e5
https://github.com/scummvm/scummvm/commit/86712a3680a04f9df34db65a35e6fb021bed26e5
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2020-04-27T14:46:58+02:00
Commit Message:
GUI: Initialize class variables in ListWidget
Changed paths:
gui/widgets/list.cpp
diff --git a/gui/widgets/list.cpp b/gui/widgets/list.cpp
index 759622a329..b695929c33 100644
--- a/gui/widgets/list.cpp
+++ b/gui/widgets/list.cpp
@@ -62,6 +62,12 @@ ListWidget::ListWidget(Dialog *boss, const String &name, const char *tooltip, ui
_dictionarySelect = false;
_lastRead = -1;
+
+ _hlLeftPadding = _hlRightPadding = 0;
+ _leftPadding = _rightPadding = 0;
+ _topPadding = _bottomPadding = 0;
+
+ _scrollBarWidth = 0;
}
ListWidget::ListWidget(Dialog *boss, int x, int y, int w, int h, const char *tooltip, uint32 cmd)
Commit: 3a0ddbf667fd06fde58eb1b9f24ad55ada24d40d
https://github.com/scummvm/scummvm/commit/3a0ddbf667fd06fde58eb1b9f24ad55ada24d40d
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2020-04-27T14:50:58+02:00
Commit Message:
GUI: Added sanity check
Changed paths:
gui/saveload-dialog.cpp
diff --git a/gui/saveload-dialog.cpp b/gui/saveload-dialog.cpp
index 17e6fd591d..56a4d4c708 100644
--- a/gui/saveload-dialog.cpp
+++ b/gui/saveload-dialog.cpp
@@ -509,9 +509,9 @@ void SaveLoadChooserSimple::reflowLayout() {
textLines++; // add a line of padding at the bottom
if (_thumbnailSupport) {
- _gfxWidget->resize(thumbX, thumbY, thumbW, thumbH);
+ _gfxWidget->resize(thumbX, thumbY, thumbW, thumbH);
_gfxWidget->setVisible(true);
- } else {
+ } else {
// choose sensible values for displaying playtime and date/time when a thumbnail is not being used
thumbH = 0;
thumbY = y;
@@ -923,7 +923,8 @@ void SaveLoadChooserGrid::reflowLayout() {
int16 x, y;
uint16 w;
- g_gui.xmlEval()->getWidgetData("SaveLoadChooser.List", x, y, w, availableHeight);
+ if (!g_gui.xmlEval()->getWidgetData("SaveLoadChooser.List", x, y, w, availableHeight))
+ error("Could not load widget position for 'SaveLoadChooser.List'");
const int16 buttonWidth = kThumbnailWidth + 6;
const int16 buttonHeight = kThumbnailHeight2 + 6;
Commit: 20334118b91a1fb651c6ae57837dfeee03231585
https://github.com/scummvm/scummvm/commit/20334118b91a1fb651c6ae57837dfeee03231585
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2020-04-27T14:51:53+02:00
Commit Message:
GUI: Added sanity check to ThemeEngine
Changed paths:
gui/ThemeEngine.cpp
diff --git a/gui/ThemeEngine.cpp b/gui/ThemeEngine.cpp
index 9c3fa53c1f..4e42388ddb 100644
--- a/gui/ThemeEngine.cpp
+++ b/gui/ThemeEngine.cpp
@@ -1713,7 +1713,9 @@ bool ThemeEngine::themeConfigUsable(const Common::FSNode &node, Common::String &
Common::FSNode headerfile = node.getChild("THEMERC");
if (!headerfile.exists() || !headerfile.isReadable() || headerfile.isDirectory())
return false;
- stream.open(headerfile);
+
+ if (!stream.open(headerfile))
+ return false;
}
if (stream.isOpen()) {
Commit: 47a0ab346abfa20072493bd3e4faf7c827202ab7
https://github.com/scummvm/scummvm/commit/47a0ab346abfa20072493bd3e4faf7c827202ab7
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2020-04-27T14:54:44+02:00
Commit Message:
GRAPHICS: Fix potential sign extension
Changed paths:
gui/ThemeEngine.cpp
diff --git a/gui/ThemeEngine.cpp b/gui/ThemeEngine.cpp
index 4e42388ddb..b5f5c3d9cd 100644
--- a/gui/ThemeEngine.cpp
+++ b/gui/ThemeEngine.cpp
@@ -1337,7 +1337,7 @@ void ThemeEngine::debugWidgetPosition(const char *name, const Common::Rect &r) {
* Screen/overlay management
*********************************************************/
void ThemeEngine::copyBackBufferToScreen() {
- memcpy(_screen.getPixels(), _backBuffer.getPixels(), _screen.pitch * _screen.h);
+ memcpy(_screen.getPixels(), _backBuffer.getPixels(), (size_t)(_screen.pitch * _screen.h));
}
void ThemeEngine::updateScreen() {
More information about the Scummvm-git-logs
mailing list