From 7d71af116ddf2f0120640a985c82077630f6ba4c Mon Sep 17 00:00:00 2001 From: makeworld Date: Fri, 10 Jul 2020 19:49:17 -0400 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20Can't=20change=20links=20while?= =?UTF-8?q?=20page=20is=20loading?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 5 +++++ README.md | 2 +- display/tab.go | 6 +++++- 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 3ec2e85..e9e540c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,11 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [Unreleased] +### Fixed +- You can't change link selection while the page is loading + + ## [1.3.0] - 2020-07-10 ### Added - **Downloading content** (#38) diff --git a/README.md b/README.md index a09beeb..0cdb4cd 100644 --- a/README.md +++ b/README.md @@ -72,7 +72,7 @@ Features in *italics* are in the master branch, but not in the latest release. - [x] Multiple charset support (over 55) - [x] Built-in search (uses GUS by default) - [x] Bookmarks -- [x] *Download pages and arbitrary data* +- [x] Download pages and arbitrary data - [ ] Search in pages with Ctrl-F - [ ] Emoji favicons - See `gemini://mozz.us/files/rfc_gemini_favicon.gmi` for details diff --git a/display/tab.go b/display/tab.go index 78d34f6..977a6ca 100644 --- a/display/tab.go +++ b/display/tab.go @@ -55,7 +55,11 @@ func makeNewTab() *tab { tab := curTab // Don't let it change in the middle of the code - if key == tcell.KeyEsc && tabs[tab].mode == tabModeDone { + if tabs[tab].mode != tabModeDone { + return + } + + if key == tcell.KeyEsc { // Stop highlighting bottomBar.SetLabel("") bottomBar.SetText(tabs[tab].page.Url)