Editor Selected Event

1 Answer 107 Views
Editor
Bastian
Top achievements
Rank 1
Bastian asked on 14 Jun 2023, 01:49 PM

Hi,

 

ist there any "Selected" Event for the Editor? I would like to enable/disable custom Tools, based on Selection, like you do with the add/remove hyperlink button.

 

Thanks

1 Answer, 1 is accepted

Sort by
0
Tsvetomir
Telerik team
answered on 19 Jun 2023, 07:33 AM

Hi Bastian,

If the editor has custom tools, then, most probably their actions are wired via the OnClick event of the respective tool. Based on the click, you would know what has been last clicked (and perhaps, track any subsequent clicks). Within the handler, you could enable/disable buttons on the fly. 

The editor does not expose an event such as "SelectedChanged" because it cannot know what is inside the custom tools. Within the custom tool, there might be several buttons or a split button. In order for the component to raise any related event, it would have to know exactly is within the toolbar. 

Let me know if additional clarifications are needed.

Kind regards,
Tsvetomir
Progress Telerik

As of R2 2023, the default icon type will be SVG instead of Font. See this blogpost for more information.
Tags
Editor
Asked by
Bastian
Top achievements
Rank 1
Answers by
Tsvetomir
Telerik team
Share this question
or