Print at Dec 19, 2025, 3:48:41 AM

Posted by Daniels118 at Aug 25, 2022, 9:58:40 AM
Re: Plugin Load
Maybe you should first understand the workflow.

You have to create at least 2 classes:
- a class which extends Plugin;
- one or more classes which extend PluginAction. One for each menu entry or toolbar button.

The first class must implement the getActions method, which must return an array of instances of the second classes (one instance for each of them). Each of these instances will be rendered as a menu item or a toolbar button. These classes must implement the execute method which will be called whenever the user clicks on the corresponding menu item/toolbar button.
What to do in this method is up to you, you may open a window or shutdown the user's pc, it depends on what your plugin should do.

Read the developer's guide for further details.