Treestyletab: Add option to disable drag and drop

Created on 6 Nov 2020  路  17Comments  路  Source: piroor/treestyletab

I would like to see a change to the Prefrences -> Drag and Drop selection menu to disable drag actions.

There is currently no option to disable Drag operations. Shift-Drag has the ability to be disabled, but none of the options for Drag include a 'disable' choice.

I have experienced many accidental drag operations which have wasted to me to revert. It would be helpful to disable this unwated functionality by an option setting.

Thank you.

bug of Firefox itself fixed

All 17 comments

I've also been experiencing a lot of "accidental" drags. To the point where I thought my mouse might be breaking. But I don't experience any such issues in any other place than TST.

Thus I would suggest that maybe the issue is that somehow TST sometimes causes faulty drag actions on click and if that were fixed your use-case would be gone.

That doesn't mean the feature doesn't have value on itself though, of course.

@maritz That is what I experienced as well. Recent FF versions have been breaking so many UI features that I wasn't sure if that is what caused this--or a new hardware issue. I've had to pause FF updates due to the UI breakage. Sadly, this feature will be a workaround for what may be a different root cause.

Still, I don't use the drag/drop feature ever, so it would remain a good thing to be able to disable.

@dwillmore Did you mean disabling about not only detaching of dragged tab from the window but moving of dragged tabs also?

Maybe I'm seeing the same thing. It's maddening (under Ubuntu 20.04, but not happening at all in Windows 10). My TST are on the left, and the bottom-most item is a one-level tree of tabs. It gets in a mode where every single time I click on the root of that sub-tree, it detaches the whole sub-tree into a new window. Sometimes it's not as reliably broken as this. But in general (I'm switching between Ubuntu and Windows multiple times per day) there's an obvious difference between the two. It's extraordinarily easy under Ubuntu to have initiated a drag and drop by clicking on the TST tab where none was intended.

Example, I just (Ubuntu, of course) positioned the mouse over a tab, then removed my hand from the mouse and clicked the left-most button with a pencil to try to be sure the mouse location did not move a single pixel. Indeed, that worked, in the sense that all that appeared to happen was the tab was selected. But then (seconds later!) when I moved the mouse a pixel or two, the hand icon appeared and it was apparent that a drag-and-drop operation had been initiated anyway.

I tried poking at some options in the TST option panel (normally I just run with the default options), but didn't stumble on anything that affected this behavior. Don't know how to figure out if the problem is Linux, Firefox, or TST, but I can't tolerate Firefox without TST so I'm just living with it for now and hoping a fix happens along...

@maritz That is what I experienced as well. Recent FF versions have been breaking so many UI features that I wasn't sure if that is what caused this--or a new hardware issue. I've had to pause FF updates due to the UI breakage. Sadly, this feature will be a workaround for what may be a different root cause.

Still, I don't use the drag/drop feature ever, so it would remain a good thing to be able to disable.

@piroor Yes, sir, that's what I'm talking about. Completely disable the ability to move tabs or tab groups either within the side bar or to detach them--through mouse actions. If it's left in a sub menu, that's good enough for the very few times that it might come in handy. Thank you.

Related issues:

  • #2629
  • #2444
  • #2185

To solve the root problem (due to unexpectedly dispatched dragend event with invalid coordinates screenX=0 and screenY=0) I've introduced some more safe guards. I hope it should solve this problem fundamentally...

And I've added a new choice to deactivate moving of tabs by drag and drop completely. It is hidden by default for safety and shown when expert options are activated.

Wow, thank you! I'd love to try this out. How do I know if I'm using a fixed version? I assume it takes some time for released code to make its way through Mozilla and get to the browser itself, but I know nothing about that.

Here is an instruction to try the development build: https://github.com/piroor/treestyletab#development-builds

I installed version 3.6.1.11116 and I see the option to disable drag and drop. I have both colums set to nothing. At first, I could still do it, but after a minute, I no longer can drag and drop tabs! This is wonderful, thank you. I'll see if the accidental drag and drop events still occur.

Thank you.

For what it's worth, I haven't had accidental drags since about 10 days ago, if I remember correctly. So Mozilla might've changed something on their end?! Or maybe I just got lucky.

And... my Ubuntu behavior now matches Windows, no accidental drags. Ubuntu 20.0.4, FF 82.0.3, TST 3.6.1. What a pleasant improvement!

I've removed the version hold on FF and allowed it to update from 80 to 83 and I'm still seeing false drag events with 3.6.1.11116 with drag and drop disabled. It acts like I have the button pressed when I do not. I can click again to 'drop' them and they do not move or detach. So, that part of the feature works great!

But I'l still seeing false drag activation with the updated extension and current FF.

@dwillmore With the commit 62ee591 now TST don't start any drag session for tabs when you choose "Do nothing / Do nothing". I hope it helps you.

@dwillmore can you try with the latest version and close out this issue if things are good?

@irvinm Yes, sorry, I have tested the most current build and it shows the expected behavior--there is no click/drag ability anymore if disabled. Tabs immediately become selected when down-clicked and any movement while down-clicked does nothing. Perfect!!!

Thank you all so much, this have made life a lot more plesant for me. I hope it helps others as well.

Version tested from December 2, 2020 Reported as version 3.6.3.

Was this page helpful?
0 / 5 - 0 ratings