Sequel-ace: Close current connection without implicitly closing tab / window

Created on 29 Jun 2020  路  3Comments  路  Source: Sequel-Ace/Sequel-Ace

As far as I know it's currently only possible to close an connection by closing the tab or window. When there's only one tab active, closing it will close the whole window. This makes the workflow of connecting to a different server a bit verbose. For example I could:

  1. Close the current tab, which closes the current window
  2. Use cmd + t / n to open a new tab
  3. Connect to a different server

Or I could:

  1. Use cmd + t / n to open an new tab
  2. Connect to a different server
  3. Close the other window / tab

It feels intuitive to be able to skip at least one step in this process. For example:

  • An option 'close connection' in the 'Choose database...' dropdown. This closes the current connection, leaves the current tab / window intact and just shows the start-up connection dialog.
  • Or, not collapsing the tab bar when there's only one connection open. The 'close tab button (X)' can then stay in view and clicking it again just closes the current connection and shows the connection dialog.

P.S.: I'm very happy to see Sequel Pro come to life again in this fork. Thank you very much!

Enhancement PR Welcome

Most helpful comment

Would it be simpler to not reset the state of the tab you're closing, but silently open a new tab in the background (mimicking cmd+t behaviour) and then just close the current tab? In the end it gives the same result without complex logic to reset the current tab to show the connection window etc. :)

All 3 comments

Hey @SanderVanLeeuwen this is actually quite a bit more difficult than it sounds - we have to somehow be able to reset the settings in the tab back to their initial state (versus just creating a brand new tab). I'll let this sit and see if someone wants to pick it up, but likely a longer term rather than shorter term agenda item!
Maybe someone else has a really smart way to make this a simpler card!

Would it be simpler to not reset the state of the tab you're closing, but silently open a new tab in the background (mimicking cmd+t behaviour) and then just close the current tab? In the end it gives the same result without complex logic to reset the current tab to show the connection window etc. :)

@samuelbradshaw suggested using 鈱冣寴W to close the current connection in #206. I like this keystroke.
This issue remains a nice convenience feature. We would gladly review a PR if anyone opens it, but I know I personally am prioritizing bug fixes over features like this one in the short term.

Was this page helpful?
0 / 5 - 0 ratings