Closed ontipto closed 10 months ago
Great idea, thanks.
I made it persistent by default and now existing refreshOnOpen
parameter can be used with webview plugin as well.
While I was at it I made this view detachable as well #374
Excellent - thanks! Looking forward to v2.
Tried this using:
webviewpersistent=false webviewPersistent=false
yet I still see a process in Activity Monitor for the page after first opened; was expecting SwiftBar webviews to act like Safari tabs, where when they're closed, all resources released.
Let me know if I have the param or expectations wrong.
Thanks - exciting to see the first 2.0.0 drop!
I made it persistent by default
This should be clearly marked as breaking change as it breaks logic of multiple plugins...
I used to display on click graphs in webview. No I am getting the same graph over and over again.
Let me re-phrase...
<swiftbar.refreshOnOpen>true</swiftbar.refreshOnOpen>
forces plugin to update on click but in my case it makes several network calls which makes plugin seem not responsive.
Still it makes webview display the same graph on each line. I need to refresh plugin again to see another graph.
I would like to not force plugin refresh and be able to see separate graph on each line.
So I suggest using separate parameter for refreshing plugin and for refreshing webview. That would allow for flexible control of plugin's behavior.
I have the same issue as @chew-z - I don't want to refresh the plugin on every click (scheduling suits better), but I want the page in webview to reload on click, otherwise I'm seeing the same old content every time I click on the icon. I have a time-related Javascript there.
"webviewpersistent=true|false" is not available as a parameter. I have to revert back to v1.5.0.
@chew-z and @x-f thanks for your input, this approach makes sense to me.
Updated as follows:
#<swiftbar.persistentWebView>true</swiftbar.persistentWebView>
, if set to true
the web view will not refresh on menu open. Defaults to false (i.e. web view refreshes on each open)persistentWebView = false
then web view process is explicitly killed and not hanging in backgroundWeb view will always refresh when Plugin refreshes, either on schedule or manually.
persistentWebView = false
works great re: killed web view process, but only when menu is detached then clicked outside of.
Also, all detached web view windows close on desktop click, even when persistentWebView = true
(process persists in latter case 👍). Should stay open unless explicitly closed, regardless of persistentWebView
?
all detached web view windows close on desktop click
This is a bug, oppened an issue #397
When using a webview, the page stays open when hidden, but reloads when redisplayed. If this could be controlled via an action attribute, persistence and background resources could be tailored to the page.
E.g., when displaying a music website, staying open works great for streaming. But, it's interrupted on redisplay as the page reloads. On a complex page, significant resources can be used even when hidden.
If the persistence and load-on-display could be controlled via something like webviewpersistent=true to only load at initial display and stay open when hidden, and =false to close the page when hidden and reload on display, these two cases would be more useful.