mirror of
https://github.com/edubart/otclient.git
synced 2025-10-14 19:44:54 +02:00
Option: Don't Stretch/Shrink Game Window
Sets gameMapPanel to size 480 x 352 Prevents resizing.
This commit is contained in:
@@ -42,13 +42,17 @@ Panel
|
||||
id: fullscreen
|
||||
!text: tr('Fullscreen')
|
||||
|
||||
OptionCheckBox
|
||||
id: dontStretchShrink
|
||||
!text: tr('Don\'t stretch/shrink Game Window')
|
||||
|
||||
Label
|
||||
id: backgroundFrameRateLabel
|
||||
!text: tr('Game framerate limit: %s', 'max')
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
anchors.top: prev.bottom
|
||||
margin-top: 6
|
||||
margin-top: 16
|
||||
@onSetup: |
|
||||
local value = Options.getOption('backgroundFrameRate')
|
||||
local text = value
|
||||
|
@@ -5,6 +5,7 @@ local defaultOptions = {
|
||||
showFps = true,
|
||||
showPing = true,
|
||||
fullscreen = false,
|
||||
dontStretchShrink = false,
|
||||
classicControl = false,
|
||||
walkBooster = false,
|
||||
smartWalk = false,
|
||||
@@ -144,6 +145,10 @@ function Options.setOption(key, value)
|
||||
end)
|
||||
elseif key == 'fullscreen' then
|
||||
g_window.setFullscreen(value)
|
||||
elseif key == 'dontStretchShrink' then
|
||||
addEvent(function()
|
||||
modules.game_interface.updateStretchShrink()
|
||||
end)
|
||||
elseif key == 'enableMusic' then
|
||||
g_sounds.enableMusic(value)
|
||||
elseif key == 'showLeftPanel' then
|
||||
|
@@ -17,7 +17,7 @@ OptionCheckBox < CheckBox
|
||||
MainWindow
|
||||
id: optionsWindow
|
||||
!text: tr('Options')
|
||||
size: 350 280
|
||||
size: 350 290
|
||||
|
||||
@onEnter: Options.hide()
|
||||
@onEscape: Options.hide()
|
||||
|
Reference in New Issue
Block a user