Bug 125011 [Contributions] ActionContributionItem should use text for tooltip in toolitems
If an action is added to a toolbar, and it has a name, but no tooltip set, the name should be used as the tooltip (except when the text is actually displayed on the toolitem using setText()) Clients sometimes forget to set the tooltip text when no specific tooltip message exists.
bundles/org.eclipse.jface/src/org/eclipse/jface/action/ActionContributionItem.java
ExternalActionManager.ICallback callback = ExternalActionManager
                        .getInstance().getCallback();
                if ((callback != null) && (commandId != null)) {
                    callback.addPropertyChangeListener(commandId,
                            actionTextListener);
                }
            }
        }
    }
    /**
     * The <code>ActionContributionItem</code> implementation of this ,
     * <code>IContributionItem</code> method creates an SWT <code>ToolItem</code>
     * for the action using the action's style. If the action's checked property has
     * been set, a button is created and primed to the value of the checked
     * property. If the action's menu creator property has been set, a drop-down
     * tool item is created.
     */
    public void fill(ToolBar parent, int index) {
        if (widget == null && parent != null) {
            int flags = SWT.PUSH;
            if (action != null) {
                int style = action.getStyle();
                if (style == IAction.AS_CHECK_BOX)
                    flags = SWT.CHECK;
                else if (style == IAction.AS_RADIO_BUTTON)
                    flags = SWT.RADIO;
                else if (style == IAction.AS_DROP_DOWN_MENU)
                    flags = SWT.DROP_DOWN;
            }
            ToolItem ti = null;