Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 339942

Summary: Add action label can sometimes be unclear
Product: z_Archived Reporter: Konstantin Komissarchik <konstantin>
Component: SapphireAssignee: Konstantin Komissarchik <konstantin>
Status: CLOSED FIXED QA Contact:
Severity: enhancement    
Priority: P3 CC: ram.venkataswamy, troy.beecroft
Version: unspecifiedKeywords: plan
Target Milestone: ---   
Hardware: All   
OS: All   
Whiteboard:

Description Konstantin Komissarchik CLA 2011-03-14 16:31:45 EDT
In Sapphire form content outline, we are starting to run into cases where the label of the add action is unclear. Consider the following scenario from the sdef editor (the editor for Sapphire UI definition files):

Tab Group
  tab1
  tab2

The "Tab Group" node's children are tabs, but when you have no tabs defined and select context menu from the "Tab Group" node, you only see "Add" in the menu. What exactly are you adding? Not clear.

The problem could be solved by creating an intermediary node like follows:

Tab Group
  Tabs
    tab1
    tab2

Of course, such approach is not always practical or advisable, especially in editors with highly recursive content (very deep nesting already).

Note that this is only an issue for homogeneous lists. If the list is heterogeneous, the add action is a cascading menu with types clearly listed in the sub-menu.

I am going to experiment with a solution that makes the homogeneous add action label include the name of what you are adding, such that it would be "Add Tab" in the above example.

We could make this behavior configurable, but I'd rather leave things simpler unless there is reason to suspect that existing scenarios would be harmed.

Note that this only applies to the content outline. The add action in the table editor is always clear and there is no advantage to make it more verbose.

Feedback welcome.
Comment 1 Troy Beecroft CLA 2011-03-15 16:34:20 EDT
I think it makes sense to be explicit about what's getting Added. Also, it makes that particular bit of UI a little more symmetric with the heterogeneous list case.
Comment 2 Konstantin Komissarchik CLA 2011-03-16 00:36:32 EDT
Enhancement implemented. It turned to be fairly different to leave the original add action label for table editors, so I ended up applying the described behavior in both places. If this proves problematic for table editors, we can revisit.
Comment 3 Ram Venkataswamy CLA 2011-06-01 14:32:58 EDT
verified with build 0.3.0.201105261624
Comment 4 Konstantin Komissarchik CLA 2011-06-03 12:29:09 EDT
Closing.