Fix for small displays.
This commit is contained in:
parent
cbc4c28722
commit
28fdff65f3
1 changed files with 15 additions and 2 deletions
|
@ -6,12 +6,25 @@
|
|||
|
||||
jslisten set "-9 gmu.bin"
|
||||
|
||||
GMUCONFIG="/storage/.config/gmu/gmu.conf"
|
||||
GMUPATH="/storage/.config/gmu"
|
||||
GMUCONFIG="${GMUPATH}/gmu.conf"
|
||||
|
||||
FBHEIGHT=$(fbset | awk '/geometry/ {print $2}')
|
||||
FBWIDTH=$(fbset | awk '/geometry/ {print $3}')
|
||||
|
||||
if [ ! -d "${GMUPATH}" ]
|
||||
then
|
||||
cp -rf /usr/config/gmu ${GMUPATH}
|
||||
fi
|
||||
|
||||
sed -i "s~SDL.Height=.*\$~SDL.Height=${FBHEIGHT}~g" ${GMUCONFIG}
|
||||
sed -i "s~SDL.Width=.*\$~SDL.Height=${FBWIDTH}~g" ${GMUCONFIG}
|
||||
sed -i "s~SDL.Width=.*\$~SDL.Width=${FBWIDTH}~g" ${GMUCONFIG}
|
||||
|
||||
if (( ${FBWIDTH} <= 800 ))
|
||||
then
|
||||
sed -i "s~default-modern-large~default-modern~g" ${GMUCONFIG}
|
||||
sed -i "s~SDL.Fullscreen=.*\$~SDL.Fullscreen=no~g" ${GMUCONFIG}
|
||||
fi
|
||||
|
||||
cd /usr/local/share/gmu
|
||||
/usr/local/bin/gmu.bin -d /usr/local/etc/gmu -c /storage/.config/gmu/gmu.conf
|
||||
|
|
Loading…
Reference in a new issue