mirror of
https://github.com/cyberarm/w3d_hub_linux_launcher.git
synced 2025-12-16 09:12:35 +00:00
Added noto font, fixed bug in Join Server button
This commit is contained in:
@@ -208,24 +208,24 @@ class W3DHub
|
||||
if server.status.password
|
||||
prompt_for_password(
|
||||
accept_callback: proc do |password|
|
||||
join_server(game, server, password)
|
||||
join_server(server, password)
|
||||
end
|
||||
)
|
||||
else
|
||||
join_server(game, server, nil)
|
||||
join_server(server, nil)
|
||||
end
|
||||
end
|
||||
)
|
||||
end
|
||||
|
||||
if server.status.password
|
||||
prompt_for_password(
|
||||
accept_callback: proc do |password|
|
||||
join_server(game, server, password)
|
||||
end
|
||||
)
|
||||
else
|
||||
join_server(game, server, nil)
|
||||
if server.status.password
|
||||
prompt_for_password(
|
||||
accept_callback: proc do |password|
|
||||
join_server(server, password)
|
||||
end
|
||||
)
|
||||
else
|
||||
join_server(server, nil)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -342,11 +342,11 @@ class W3DHub
|
||||
)
|
||||
end
|
||||
|
||||
def join_server(game, server, password)
|
||||
def join_server(server, password)
|
||||
if (
|
||||
(server.status.password && password.length.positive?) ||
|
||||
!server.status.password) &&
|
||||
window.settings[:server_list_username].to_s.length.zero?
|
||||
window.settings[:server_list_username].to_s.length.positive?
|
||||
|
||||
window.application_manager.join_server(
|
||||
server.game,
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
class W3DHub
|
||||
REGULAR_FONT = "#{GAME_ROOT_PATH}/media/fonts/NotoSans-Regular.ttf"
|
||||
BOLD_FONT = "#{GAME_ROOT_PATH}/media/fonts/NotoSans-Bold.ttf"
|
||||
|
||||
THEME = {
|
||||
ToolTip: {
|
||||
background: 0xff_dedede,
|
||||
@@ -8,7 +11,7 @@ class W3DHub
|
||||
text_shadow: false
|
||||
},
|
||||
TextBlock: {
|
||||
# font: "Inconsolata",
|
||||
font: BOLD_FONT,
|
||||
text_border: false,
|
||||
text_shadow: true,
|
||||
text_shadow_size: 1,
|
||||
|
||||
@@ -4,7 +4,7 @@ class W3DHub
|
||||
attr_accessor :account, :service_status, :applications
|
||||
|
||||
def setup
|
||||
self.caption = "#{W3DHub::NAME}"
|
||||
self.caption = I18n.t(:app_name)
|
||||
|
||||
@settings = Settings.new
|
||||
@application_manager = ApplicationManager.new
|
||||
|
||||
Reference in New Issue
Block a user