code icon indicating copy to clipboard operation
code copied to clipboard

Welcome screen does not accept dropped tabs

Open jeremypw opened this issue 4 years ago • 2 comments

What Happened?

Attempted to move a tab to a secondary Code window with no open documents (and therefore no visible notebook) by dropping on the Welcome view. Instead a third window opened.

Dropping a text file from Files onto the Welcome view did create a new document in that window.

Steps to Reproduce

  1. Open two Code windows one with open documents and one without.
  2. Drag a tab into the empty window's Welcome view
  3. Observe that a third window opens

Expected Behavior

Dropping a tab onto a Welcome view should behave the same as dropping a text file.

OS Version

6.x (Odin)

Software Version

Compiled from git

Log Output

No response

Hardware Info

No response

jeremypw avatar Dec 06 '21 12:12 jeremypw

Not sure if this is easily fixable without modifying Granite.DynamicNotebook to make the underlying Gtk.Notebook more accessible.

jeremypw avatar Dec 07 '21 17:12 jeremypw

Now that we're now using Hdy.TabView, is this now possible?

colinkiama avatar Aug 21 '24 10:08 colinkiama

Quite possibly - I'll try and look into it soon.

jeremypw avatar Sep 01 '24 19:09 jeremypw

This issue still seems to be present in OS8 stable

zeebok avatar Oct 05 '24 14:10 zeebok

There is already code in Code accepting dropped files on the welcome view and this seems to be working in Horus at least (provided you drop a text file). As the welcome view replaces the TabView additional code is still required for it to accept dropped tabs.

jeremypw avatar Oct 07 '24 11:10 jeremypw

Looking more into this I am not sure it is soluble because the DocumentView from which the tab was dragged creates the new window and there is no obvious way for it to know where the tab was dropped. It just listens for a "create window" signal from the TabView, which is a sealed class.

jeremypw avatar Oct 07 '24 11:10 jeremypw

I am going to close this as unfixable within Code.

jeremypw avatar Oct 07 '24 11:10 jeremypw