Flexible entergame window, changes to logout window
This commit is contained in:
parent
345e9f4926
commit
7b1aba1fa5
|
@ -175,7 +175,7 @@ function EnterGame.displayMotd()
|
|||
displayInfoBox(tr('Message of the day'), G.motdMessage)
|
||||
end
|
||||
|
||||
function EnterGame.setUniqueServer(host, port, protocol, windowHeight)
|
||||
function EnterGame.setUniqueServer(host, port, protocol, windowWidth, windowHeight)
|
||||
local hostTextEdit = enterGame:getChildById('serverHostTextEdit')
|
||||
hostTextEdit:setText(host)
|
||||
hostTextEdit:setVisible(false)
|
||||
|
@ -202,6 +202,8 @@ function EnterGame.setUniqueServer(host, port, protocol, windowHeight)
|
|||
local rememberPasswordBox = enterGame:getChildById('rememberPasswordBox')
|
||||
rememberPasswordBox:setMarginTop(-5)
|
||||
|
||||
if not windowWidth then windowWidth = 236 end
|
||||
enterGame:setWidth(windowWidth)
|
||||
if not windowHeight then windowHeight = 200 end
|
||||
enterGame:setHeight(windowHeight)
|
||||
end
|
||||
|
|
|
@ -1,4 +1,6 @@
|
|||
MainWindow
|
||||
EnterGameWindow < MainWindow
|
||||
|
||||
EnterGameWindow
|
||||
id: enterGame
|
||||
!text: tr('Enter Game')
|
||||
margin-top: 100
|
||||
|
|
Binary file not shown.
Before Width: | Height: | Size: 3.0 KiB After Width: | Height: | Size: 3.0 KiB |
|
@ -1,28 +1,27 @@
|
|||
LogoutWindow < MainWindow
|
||||
id: logoutWindow
|
||||
!text: tr('Logout')
|
||||
size: 300 100
|
||||
size: 230 100
|
||||
|
||||
Label
|
||||
!text: tr('Are you sure you want to logout?')
|
||||
width: 200
|
||||
anchors.left: parent.left
|
||||
text-auto-resize: true
|
||||
anchors.horizontalCenter: parent.horizontalCenter
|
||||
anchors.top: parent.top
|
||||
margin-left: 30
|
||||
margin-top: 2
|
||||
|
||||
Button
|
||||
id: buttonYes
|
||||
!text: tr('Yes')
|
||||
width: 64
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.horizontalCenter
|
||||
anchors.bottom: parent.bottom
|
||||
margin-left: 65
|
||||
margin-right: 5
|
||||
|
||||
Button
|
||||
id: buttonNo
|
||||
!text: tr('No')
|
||||
width: 64
|
||||
anchors.left: prev.right
|
||||
anchors.left: parent.horizontalCenter
|
||||
anchors.bottom: parent.bottom
|
||||
margin-left: 5
|
||||
|
|
Loading…
Reference in New Issue