aboutsummaryrefslogtreecommitdiff
path: root/main.F90
diff options
context:
space:
mode:
Diffstat (limited to 'main.F90')
-rw-r--r--main.F9010
1 files changed, 8 insertions, 2 deletions
diff --git a/main.F90 b/main.F90
index 9af9708..0926192 100644
--- a/main.F90
+++ b/main.F90
@@ -256,7 +256,13 @@ implicit none
loaded = .false.
case (render_action_favorite)
- call add_favorite(faves, current_url, current_url)
+ if(is_favorite(faves, current_url)) then
+ call remove_favorite(faves, current_url)
+ call r%report_status(trim(current_url)//" removed as favorite")
+ else
+ call add_favorite(faves, current_url, current_url)
+ call r%report_status("Added favorite: "//trim(current_url))
+ end if
call save_favorites(faves)
end select
@@ -345,7 +351,7 @@ contains
use favorite_handling, only: write_favorites, favorite
implicit none
- type(favorite), dimension(:)::faves
+ type(favorite), dimension(:), intent(in), pointer::faves
character(260)::filename
integer::ios, loadunit