sidebery icon indicating copy to clipboard operation
sidebery copied to clipboard

Close tab on click, instead of just mousedown

Open FoxRefire opened this issue 1 year ago • 6 comments

Closes #1437 Closes #1682 Closes #1405 Closes #299

FoxRefire avatar Sep 08 '24 13:09 FoxRefire

I am also working on fixing Issue #1786, please define your requirements. Perhaps this is the part that should be changed. https://github.com/mbnuqw/sidebery/blob/v5/src/services/tabs.fg.actions.ts#L1184

After I checked the current behavior and the code, I found that each tab panel switches to the last active tab. In order to maintain the same behavior once the sidebar is closed, it is necessary to maintain tab information in persistent storage, but this incurs overhead. I can think of three possible options, which or else would be preferable for you?

  • Allow overhead and store per-panel tab information in persistent storage
  • Switch tabs based on lastAccessed attribute as fallback when last active tab per panel is unavailable
  • Switching tabs based on the lastAccessed attribute when explicitly set in the settings

FoxRefire avatar Sep 08 '24 14:09 FoxRefire

How does this fix #1405?

It would be a good idea to add a commit message.

siddhpant avatar Oct 20 '24 10:10 siddhpant

How does this fix #1405?

I don't know why, but after making this change the issue went away. If this issue still exists after this change, I will make not to close this issue.

FoxRefire avatar Oct 20 '24 10:10 FoxRefire

I don't know why, but after making this change the issue went away.

How did you reproduce it?

siddhpant avatar Oct 20 '24 11:10 siddhpant

How did you reproduce it?

I'm not sure how to reproduce this for sure. But this often happens when there is little free RAM, such as when watching YouTube with many tabs opened.

FoxRefire avatar Oct 20 '24 13:10 FoxRefire

How did you reproduce it?

'm not sure how to reproduce this for sure. But this often happens when there is little free RAM, such as when watching YouTube with many tabs opened.

Can you mention that in the issue thread as well?

How did you find this? If you think this is the cause, can you run a stresser (say stress-ng) and reproduce? And why would dragging fix it?

If it's a memory issue, why does this change fix it?

siddhpant avatar Oct 20 '24 13:10 siddhpant

Could you show a video demonstration showcasing that it works? @FoxRefire

Michael679089 avatar Nov 17 '24 04:11 Michael679089

I believe a much better solution would be to leave the mousedown event listener, and move "perform action" part to the mouseup listener.

And better yet - start to select tabs on mousedown, sp that user could continue moving the mouse to select more tabs, and apply the configured action on mouseup, similar to how it was done for the middle click multi selection on the tab body.

emvaized avatar Dec 21 '24 06:12 emvaized