D22199: New plugin to open the selected file path
noreply at phabricator.kde.org
Sun Jul 21 23:11:44 BST 2019
nononux marked 2 inline comments as done.
nononux added inline comments.
> dhaumann wrote in plugin_kateopenselection.cpp:80
> A PluginViewKateOpenSelection instance is created here for every KTextEditor::MainWindow - this is ok and works as designed / intended.
> However, PluginViewKateOpenSelection inherits KTextEditor::Command, which itself registers in its constructor with the command "open-selection" in the Kate's command line. Now when you create multiple MainWindows in Kate (View > New Window), then you will add *the same* "open-selection" command twice, which is wrong.
> In short: PluginViewKateOpenSelection must not inherit KTextEditor::Command. Instead, the PluginKateOpenSelection should inherit it.
As a class cannot inherit from 2 QObjects, I've made another class included in the plugin as a member.
To: nononux, dhaumann
Cc: dhaumann, pino, yurchor, kwrite-devel, kde-doc-english, gennad, fbampaloukas, domson, michaelh, ngraham, demsking, skadinna, cullmann, sars
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the KWrite-Devel