browser: fix minor status bar issues

This commit is contained in:
dece 2021-05-24 21:11:58 +02:00
parent 8e4f8c4c70
commit b22981cef6
3 changed files with 6 additions and 6 deletions

View file

@ -28,6 +28,9 @@ opt. maintain history between sessions
history (forward) (useful?) history (forward) (useful?)
search in page (ugh) search in page (ugh)
remember scroll pos in history remember scroll pos in history
identity management
"previous/next" pages
directory view for file scheme

View file

@ -73,7 +73,6 @@ def open_gemini_url(
if use_cache and url in browser.cache: if use_cache and url in browser.cache:
browser.load_page(browser.cache[url]) browser.load_page(browser.cache[url])
browser.current_url = url browser.current_url = url
browser.set_status(url)
return url return url
logging.info( logging.info(
@ -232,7 +231,6 @@ def _handle_successful_response(browser: Browser, response: Response, url: str):
browser.load_page(page) browser.load_page(page)
browser.current_url = url browser.current_url = url
browser.cache[url] = page browser.cache[url] = page
browser.set_status(url)
return url return url
elif filepath: elif filepath:
try: try:

View file

@ -39,12 +39,11 @@ def get_downloads_path() -> Path:
if line.startswith("XDG_DOWNLOAD_DIR="): if line.startswith("XDG_DOWNLOAD_DIR="):
download_path = line.rstrip().split("=", maxsplit=1)[1] download_path = line.rstrip().split("=", maxsplit=1)[1]
download_path = download_path.strip('"') download_path = download_path.strip('"')
download_path = download_path.replace("$HOME", expanduser("~")) home = expanduser("~")
break download_path = download_path.replace("$HOME", home)
return Path(download_path)
except OSError: except OSError:
pass pass
if download_path:
return Path(download_path)
return Path.home() return Path.home()