[Scummvm-git-logs] scummvm master -> 866b54f688f9a7212c5243e38f9427268a2f7668

sev- noreply at scummvm.org
Sun Mar 19 23:18:34 UTC 2023


This automated email contains information about 3 new commits which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
6c5c6f8140 GUI: Add a resolution property for layouts
48ed15011c GUI: Allow comparing the width with the height in resolution checks
866b54f688 GUI: Add a portrait version of the launcher


Commit: 6c5c6f8140a61f6a4055ea9fe648985d43d53b1d
    https://github.com/scummvm/scummvm/commit/6c5c6f8140a61f6a4055ea9fe648985d43d53b1d
Author: Cameron Cawley (ccawley2011 at gmail.com)
Date: 2023-03-20T00:18:25+01:00

Commit Message:
GUI: Add a resolution property for layouts

Changed paths:
    gui/ThemeParser.cpp
    gui/ThemeParser.h


diff --git a/gui/ThemeParser.cpp b/gui/ThemeParser.cpp
index f13292cd36d..dc7f733b78b 100644
--- a/gui/ThemeParser.cpp
+++ b/gui/ThemeParser.cpp
@@ -813,6 +813,11 @@ bool ThemeParser::parserCallback_import(ParserNode *node) {
 }
 
 bool ThemeParser::parserCallback_layout(ParserNode *node) {
+	if (resolutionCheck(node->values["resolution"]) == false) {
+		node->ignore = true;
+		return true;
+	}
+
 	int spacing = -1;
 
 	if (node->values.contains("spacing")) {
diff --git a/gui/ThemeParser.h b/gui/ThemeParser.h
index a117966d94e..661154dd801 100644
--- a/gui/ThemeParser.h
+++ b/gui/ThemeParser.h
@@ -204,6 +204,7 @@ protected:
 					XML_PROP(align, false)
 					XML_PROP(padding, false)
 					XML_PROP(spacing, false)
+					XML_PROP(resolution, false)
 
 					XML_KEY(import)
 						XML_PROP(layout, true)


Commit: 48ed15011c5fc4b54cde46fba4ec97565f83e577
    https://github.com/scummvm/scummvm/commit/48ed15011c5fc4b54cde46fba4ec97565f83e577
Author: Cameron Cawley (ccawley2011 at gmail.com)
Date: 2023-03-20T00:18:25+01:00

Commit Message:
GUI: Allow comparing the width with the height in resolution checks

Changed paths:
    gui/ThemeParser.cpp


diff --git a/gui/ThemeParser.cpp b/gui/ThemeParser.cpp
index dc7f733b78b..aff4ef5c2b0 100644
--- a/gui/ThemeParser.cpp
+++ b/gui/ThemeParser.cpp
@@ -1091,6 +1091,10 @@ bool ThemeParser::resolutionCheck(const Common::String &resolution) {
 			// theme by default
 			token = 375;
 #endif
+		} else if (cur[offset] == 'x') {
+			token = _baseWidth;
+		} else if (cur[offset] == 'y') {
+			token = _baseHeight;
 		} else {
 			token = atoi(cur.c_str() + offset);
 		}


Commit: 866b54f688f9a7212c5243e38f9427268a2f7668
    https://github.com/scummvm/scummvm/commit/866b54f688f9a7212c5243e38f9427268a2f7668
Author: Cameron Cawley (ccawley2011 at gmail.com)
Date: 2023-03-20T00:18:25+01:00

Commit Message:
GUI: Add a portrait version of the launcher

Changed paths:
    gui/themes/common/highres_layout.stx


diff --git a/gui/themes/common/highres_layout.stx b/gui/themes/common/highres_layout.stx
index a5dfb37b129..c07ea9c4676 100644
--- a/gui/themes/common/highres_layout.stx
+++ b/gui/themes/common/highres_layout.stx
@@ -150,7 +150,7 @@
 		/>
 	</globals>
 
-	<dialog name = 'Launcher' overlays = 'screen'>
+	<dialog name = 'Launcher' overlays = 'screen' resolution = 'y<=x'>
 		<layout type = 'vertical' align = 'center' padding = '23, 23, 8, 40'>
 			<widget name = 'Logo'
 					width = '287'
@@ -238,6 +238,90 @@
 		</layout>
 	</dialog>
 
+	<dialog name = 'Launcher' overlays = 'screen' resolution = 'y>x'>
+		<layout type = 'vertical' align = 'center' padding = '23, 23, 8, 92'>
+			<widget name = 'Logo'
+					width = '287'
+					height = '80'
+					rtl = 'no'
+			/>
+			<layout type = 'horizontal'  spacing = '5' padding = '10, 0, 0, 0'>
+				<widget name = 'SearchPic'
+						width = '16'
+						height = '17'
+						rtl = 'no'
+				/>
+				<widget name = 'Search'
+						width = '120'
+						height = 'Globals.Line.Height'
+				/>
+				<widget name = 'SearchClearButton'
+						height = 'Globals.Line.Height'
+						width = 'Globals.Line.Height'
+				/>
+				<space size = '5' />
+				<widget name = 'GroupPic'
+						width = '17'
+						height = '17'
+						rtl = 'no'
+				/>
+				<widget name = 'laGroupPopup'
+						width = '100'
+						type = 'PopUp'
+				/>
+				<space />
+				<widget name = 'Version'
+						width = '310'
+						height = 'Globals.Line.Height'
+						textalign = 'center'
+				/>
+				<space />
+			</layout>
+			<layout type = 'horizontal' padding = '0, 0, 2, 0' spacing = '2'>
+				<widget name = 'GameList'/>
+			</layout>
+			<layout type = 'horizontal' padding = '0, 0, 2, 0' spacing = '2'>
+				<widget name = 'LoadGameButton'
+						height = 'Globals.Button.Height'
+				/>
+				<widget name = 'AddGameButton'
+						height = 'Globals.Button.Height'
+				/>
+				<widget name = 'EditGameButton'
+						height = 'Globals.Button.Height'
+				/>
+				<widget name = 'RemoveGameButton'
+						height = 'Globals.Button.Height'
+				/>
+			</layout>
+			<layout type = 'horizontal' padding = '0, 0, 0, 0' spacing = '2'>
+				<widget name = 'QuitButton'
+						height = 'Globals.Button.Height'
+				/>
+				<widget name = 'AboutButton'
+						height = 'Globals.Button.Height'
+				/>
+				<widget name = 'OptionsButton'
+						height = 'Globals.Button.Height'
+				/>
+				<widget name = 'StartButton'
+						height = 'Globals.Button.Height'
+				/>
+			</layout>
+			<layout type = 'horizontal' padding = '0, 0, 6, 0' spacing = '2'>
+				<widget name = 'ListSwitch'
+						height = 'Globals.Button.Height'
+						width = 'Globals.Button.Height'
+				/>
+				<widget name = 'GridSwitch'
+						height = 'Globals.Button.Height'
+						width = 'Globals.Button.Height'
+				/>
+				<space />
+			</layout>
+		</layout>
+	</dialog>
+
 	<dialog name = 'LauncherGrid' overlays = 'screen'>
 		<layout type = 'vertical' align = 'center' padding = '23, 23, 8, 40'>
 			<widget name = 'Logo'




More information about the Scummvm-git-logs mailing list