Opened 12 years ago
Last modified 11 years ago
#11037 assigned Bug
No link&unlink option in context menu opened on widget
| Reported by: | Piotrek Koszuliński | Owned by: | Marek Lewandowski |
|---|---|---|---|
| Priority: | Normal | Milestone: | |
| Component: | General | Version: | 4.3 |
| Keywords: | Cc: |
Description
- Open MathJax sample.
- Select some text containing widget (or just widget).
- Create link.
- Right click widget.
- There are no link and unlink options in context menu.
Change History (5)
comment:1 Changed 11 years ago by
| Status: | new → confirmed |
|---|
comment:2 Changed 11 years ago by
| Owner: | set to Marek Lewandowski |
|---|---|
| Status: | confirmed → assigned |
comment:3 Changed 11 years ago by
comment:4 Changed 11 years ago by
This is not the right solution. If inline widget is inside a link the link option should be automatically enabled in context menu. This has to be solved on link plugin side.
comment:5 Changed 11 years ago by
PS. image2 is a totally different case, because it handles links in a custom way.

The solution for this issue was initially commited by Olek in git:78c4fbdf56b - in case of widgets like mathjax and placeholder plugins it comes down to:
widget.on( 'contextMenu', function( evt ) { // Integrate context menu items for link. if ( widget.wrapper.getAscendant( 'a' ) ) evt.data.link = evt.data.unlink = CKEDITOR.TRISTATE_OFF; } );