mirror of
https://github.com/thegatesbrowser/thegates.git
synced 2025-08-24 11:17:26 -04:00
gate icon and undiscoverable mode
This commit is contained in:
parent
fb6cf98f2b
commit
414ad4eeda
18 changed files with 108 additions and 52 deletions
|
@ -2,7 +2,7 @@ extends Control
|
|||
class_name BookmarkUI
|
||||
|
||||
@export var gate_events: GateEvents
|
||||
@export var image: TextureRect
|
||||
@export var icon: TextureRect
|
||||
@export var title: Label
|
||||
@export var button: Button
|
||||
@export var button_special: Button
|
||||
|
@ -23,7 +23,7 @@ func fill(gate: Gate, special: bool = false) -> void:
|
|||
|
||||
url = gate.url
|
||||
title.text = "Unnamed" if gate.title.is_empty() else gate.title
|
||||
image.texture = FileTools.load_external_tex(gate.image)
|
||||
icon.texture = FileTools.load_external_tex(gate.icon)
|
||||
|
||||
|
||||
func on_pressed() -> void:
|
||||
|
|
|
@ -29,8 +29,7 @@ func scale_content() -> void:
|
|||
|
||||
|
||||
func set_initial_screen() -> void:
|
||||
var last_screen = DataSaver.get_value("settings", "last_screen")
|
||||
if last_screen == null: last_screen = 0
|
||||
var last_screen = DataSaver.get_value("settings", "last_screen", 0)
|
||||
|
||||
DisplayServer.window_set_current_screen(last_screen)
|
||||
Debug.logclr("Initial screen: %d" % [last_screen], Debug.SILENT_CLR)
|
||||
|
|
|
@ -18,6 +18,7 @@ func _ready() -> void:
|
|||
gate_events.search.connect(func(_query): hide_buttons())
|
||||
gate_events.exit_gate.connect(hide_buttons)
|
||||
gate_events.gate_info_loaded.connect(update_info)
|
||||
gate_events.gate_icon_loaded.connect(update_info)
|
||||
gate_events.gate_image_loaded.connect(update_info)
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue