6 Commits

Author SHA1 Message Date
Kostas Karmas
fd3c985440 Fix ambiguous Ctrl+O shortcut not opening the local file dialog
Ctrl+O was assigned as a shortcut in two places:
  1. To the "File->Open File(s)" menu item, which is visible when only the local file
	 provider is enabled (i.e. the DF file provider is disabled)
  2. To the "File->Open File(s)->From Disk" menu item, which is visible when there are
     more than one file providers enabled.

This was creating an ambiguous shortcut, thus never opening the local file dialog.

This is now fixed by disabling the shortcuts when the respective items are not visible.

CURA-7868
2021-01-11 17:50:26 +01:00
Kostas Karmas
96c4d66029 Revert making the open file dialog a separate LocalFileProvider plugin
This reverts commits 00de7497a4c2986cf8fd13be8f598a0f615f3d63 to 5f6b3b52c1848416c98f7d276fe02f08d067f675

CURA-7868
2021-01-07 16:35:40 +01:00
Ghostkeeper
b266904d76
Replace other references to the open action with the file provider model
This adds a function 'triggerFirst' to the file provider that triggers the first file provider in the model. That should then be the local file provider, but if the plug-in is disabled for some reason it would use another plug-in.

Contributes to issue CURA-7868.
2021-01-04 18:12:15 +01:00
Kostas Karmas
e5038ab46d Update year in the copyright comment.
CURA-7868
2021-01-04 15:12:53 +01:00
Kostas Karmas
71994eaaf9 Change the Open File(s) option according to the file providers count
When there is only one file provider (i.e. the local file provider), the Open File(s) will be a
simple item in the File menu.
When there are more than one file providers, the Open File(s) will become a submenu in the File
menu, which will contain all the file providers as submenu items.

CURA-7868
2020-12-23 17:13:14 +01:00
Kostas Karmas
430550452f Add a new file menu option when there are multiple file providers
CURA-7868
2020-12-15 18:31:15 +01:00