update
Some checks failed
Build Gurty / Build Gurty (, ubuntu-latest, linux, x86_64-unknown-linux-gnu) (push) Failing after 1m33s
Build GurtCA / Build GurtCA (, ubuntu-latest, linux, x86_64-unknown-linux-gnu) (push) Failing after 11m20s
Build GDExtension / Build GDExtension (libgurt_godot.so, ubuntu-latest, linux, x86_64-unknown-linux-gnu) (push) Failing after 16m9s
Build Flumi / Build Flumi (Linux, 4.4.1, ubuntu-latest, linux) (push) Failing after 2h10m11s
Build Flumi / Build Flumi (Windows Desktop, 4.4.1, windows-latest, windows) (push) Has been cancelled
Build GDExtension / Build GDExtension (gurt_godot.dll, windows-latest, windows, x86_64-pc-windows-msvc) (push) Has been cancelled
Build GurtCA / Build GurtCA (.exe, windows-latest, windows, x86_64-pc-windows-msvc) (push) Has been cancelled
Build Gurty / Build Gurty (.exe, windows-latest, windows, x86_64-pc-windows-msvc) (push) Has been cancelled
Some checks failed
Build Gurty / Build Gurty (, ubuntu-latest, linux, x86_64-unknown-linux-gnu) (push) Failing after 1m33s
Build GurtCA / Build GurtCA (, ubuntu-latest, linux, x86_64-unknown-linux-gnu) (push) Failing after 11m20s
Build GDExtension / Build GDExtension (libgurt_godot.so, ubuntu-latest, linux, x86_64-unknown-linux-gnu) (push) Failing after 16m9s
Build Flumi / Build Flumi (Linux, 4.4.1, ubuntu-latest, linux) (push) Failing after 2h10m11s
Build Flumi / Build Flumi (Windows Desktop, 4.4.1, windows-latest, windows) (push) Has been cancelled
Build GDExtension / Build GDExtension (gurt_godot.dll, windows-latest, windows, x86_64-pc-windows-msvc) (push) Has been cancelled
Build GurtCA / Build GurtCA (.exe, windows-latest, windows, x86_64-pc-windows-msvc) (push) Has been cancelled
Build Gurty / Build Gurty (.exe, windows-latest, windows, x86_64-pc-windows-msvc) (push) Has been cancelled
This commit is contained in:
@@ -120,8 +120,8 @@ func _on_search_submitted(url: String, add_to_history: bool = true) -> void:
|
||||
tab.start_loading()
|
||||
|
||||
var gurt_url = url
|
||||
if not gurt_url.begins_with("gurt://"):
|
||||
gurt_url = "gurt://" + gurt_url
|
||||
if not gurt_url.begins_with("lw://"):
|
||||
gurt_url = "lw://" + gurt_url
|
||||
|
||||
await fetch_gurt_content_async(gurt_url, tab, url, add_to_history)
|
||||
else:
|
||||
@@ -289,7 +289,7 @@ func _on_search_focus_entered() -> void:
|
||||
func _on_search_focus_exited() -> void:
|
||||
if not current_domain.is_empty():
|
||||
var display_text = current_domain
|
||||
if display_text.begins_with("gurt://"):
|
||||
if display_text.begins_with("lw://"):
|
||||
display_text = display_text.right(-7)
|
||||
elif display_text.begins_with("file://"):
|
||||
display_text = URLUtils.file_url_to_path(display_text)
|
||||
@@ -828,7 +828,7 @@ func reload_current_page() -> void:
|
||||
_on_search_submitted(current_domain)
|
||||
|
||||
func navigate_to_url(url: String, add_to_history: bool = true) -> void:
|
||||
if url.begins_with("gurt://") or url.begins_with("file://"):
|
||||
if url.begins_with("lw://") or url.begins_with("file://"):
|
||||
_on_search_submitted(url, add_to_history)
|
||||
else:
|
||||
var resolved_url = resolve_url(url)
|
||||
@@ -837,7 +837,7 @@ func navigate_to_url(url: String, add_to_history: bool = true) -> void:
|
||||
func update_search_bar_from_current_domain() -> void:
|
||||
if not search_bar.has_focus() and not current_domain.is_empty():
|
||||
var display_text = current_domain
|
||||
if display_text.begins_with("gurt://"):
|
||||
if display_text.begins_with("lw://"):
|
||||
display_text = display_text.right(-7)
|
||||
elif display_text.begins_with("file://"):
|
||||
display_text = URLUtils.file_url_to_path(display_text)
|
||||
@@ -878,7 +878,7 @@ func add_to_history(url: String, tab: Tab, add_to_navigation: bool = true):
|
||||
icon_url = tab.get_meta("parsed_icon_url")
|
||||
|
||||
var clean_url = url
|
||||
if clean_url.begins_with("gurt://"):
|
||||
if clean_url.begins_with("lw://"):
|
||||
clean_url = clean_url.right(-7)
|
||||
|
||||
BrowserHistory.add_entry(clean_url, title, icon_url)
|
||||
@@ -922,7 +922,7 @@ func get_startup_behavior() -> Dictionary:
|
||||
func _handle_startup_behavior():
|
||||
var args = OS.get_cmdline_args()
|
||||
for arg in args:
|
||||
if arg.begins_with("gurt://"):
|
||||
if arg.begins_with("lw://"):
|
||||
print("Opening URL from command line: ", arg)
|
||||
_on_search_submitted(arg, true)
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user