Editing hook definitions in the manifest is very limited

Bug #1400830 reported by Pat McGowan
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
qtcreator-plugin-ubuntu (Ubuntu)
Triaged
Medium
Benjamin Zeller

Bug Description

Select the manifest.json file in Edit pane
Under Hooks is a pulldown which defaults to "myapp"
There is no way to change this value

Once it is changed outside qtc the user is prompted to reload the file, but reloading doesn't show the new value. The file needs to be closed and reopened.

Should this be a simple text field?
Is it expected to have multiple entries under hooks, what is the reason for the selector dropdown?

Revision history for this message
Benjamin Zeller (zeller-benjamin) wrote :

Yes there is support for multiple hooks in manifests. A package can contain multiple apps,
or app + helper + scope.

It is possible to switch between source and gui based editor on the top of the manifest editor window.
So there is no need to reload the file or edit it outside of the IDE. The "General" and "Source" buttons
on top switch between those modes.

I considered creating multiple/renaming hooks a advanced task a developer could do in the "edit source" mode
and implementing a self explaining UI for it also is not trivial.
We could have a editable dropdown box there and add and remove buttons, but
it would make the UI more complex and less easy to understand. And the code that syncs
between Gui and Source editor more complex as well.

Also just having support for only one Hook in the Gui editor is not really a good idea, there is support
for multiple hooks. First question would be: what is the right hook to show in the gui if there are multiple?
And its not really intuitive why only one hook is shown in the gui.

Revision history for this message
Pat McGowan (pat-mcgowan) wrote :

I entered the bug because the hook name is the only field on the screen that cannot be edited in place. I would simply allow it to be. And as it defaults to "myapp" it will always need to be changed.

But now I see there are many other shortcomings with the presentation of hooks. If I add a content hub hook it does not show up in the UI. How can we present a list of interesting options here? There is a need to define multiple sets of hooks for each app/helper/scope and additional hooks within these.

summary: - No way to change the hook name in the manifest
+ Editing hook definitions in the manifest is very limited
Changed in qtcreator-plugin-ubuntu (Ubuntu):
assignee: Zoltan Balogh (bzoltan) → Benjamin Zeller (zeller-benjamin)
Revision history for this message
Benjamin Zeller (zeller-benjamin) wrote :

Agreed, the Gui part of the editor should support that but we need to come up with
a straightforward UI that is easy to understand as there is almost no place for context help.

Changed in qtcreator-plugin-ubuntu (Ubuntu):
status: New → Triaged
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.