Ticket #1149 (confirmed New Feature)

Opened 7 years ago

Last modified 20 months ago

Add default action on face for Panel button (menu button)

Reported by: mjk Owned by:
Priority: Normal Milestone:
Component: UI : Toolbar Version: 3.0
Keywords: Cc:

Description

It's common for toolbar buttons in other applications to do a default action if you click on the button face, and only drop a panel (as FCKToolbarPanelButton does) when you click the arrow -- if there is one. At present, FCKToolbarPanelButton doesn't maintain the distinction between dropping down the panel and making a default action.

Enclosed is a patch to enable ToolbarPanelButton to pass to the toolbar command object whether or not the user clicked the dropdown arrow or the face, so that the command object can behave accordingly. This also adds the ability for ToolbarPanelButton to be context-sensitive -- necessary if you're implementing things like UL and OL.

Also enclosed is a plugin that uses the patched functionality. The plugin overloads FCKTextColorCommand so that the last color you used is the default action on the button face. It also adds DropOL, DropUL, and DropFontSize to use the same functionality to provide dropdowns for setting your OL/UL styles and font sizes.

In local testing, the patches to ToolbarPanelButton are sufficiently encapsulated so as not to break existing ToolbarPanelButtons.

Attachments

dropbar.zip (3.7 KB) - added by mjk 7 years ago.
Trunk patch and plugin

Change History

Changed 7 years ago by mjk

Trunk patch and plugin

comment:1 Changed 7 years ago by mjk

  • Keywords Review? added

comment:2 Changed 7 years ago by fredck

  • Keywords HasPatch added; Review? removed

It is nice to hear you again mjk.

We have introduced a new workflow for tickets handling, patches proposal and review. I'm correcting the Keywords in this ticket to reflect our new standards.

comment:3 Changed 4 years ago by wwalc

  • Version set to FCKeditor 2.5

comment:4 Changed 20 months ago by j.swiderski

  • Status changed from new to confirmed
  • Keywords HasPatch removed
  • Version changed from FCKeditor 2.5 to 3.0
  • Summary changed from Add default action on face for FCKToolbarPanelButton + plugin for alternate OL/UL/color/size buttons to Add default action on face for Panel button (menu button)

Currently we have 3 menu buttons - SCAYT, color and background color. Default actions could be enable scayt and set default color (auto).

There are two things I'm concerned:

  1. Currently the arrow is very little and very close to button thus I don't think users will want to aim it. This will probably bring frustration among some users as it would become very hard to get to menu.
  2. As pointed out by @Rainmar there might be some accessibility issues.

To implement such feature probably new Menu button would have to be introduced. Nevertheless I'm confirming it as it might be implemented in the future.

Note: See TracTickets for help on using tickets.
© 2003 – 2012 CKSource – Frederico Knabben. All rights reserved. | Terms of use | Privacy policy