Ok, I have an interesting problem. Looking for as many ideas as possible here. I am building an application that uses plugins. The plugins add additional functionality to the main application without the application having any knowledge of its existance. The user can setup configuration files that specify what the app should do if a particular event or action is created (i.e. clicking a menu item, pressing a key combo). How would you guys allow the main application call a procedure inside the plugin with only a QObject pointer (given to you by the QPluginLoader) and a string consisting of the function to call.
I have three different idea, and I am not sure if any will even work.
Using QLibrary (this would be my last resort seeing as how these functions would have to be externed as "C" functions.
Using QActions (not sure how I would do this, but I bet there is a way).
Using Signals and Slots somehow (once again not sure).
Currently, I am in the proof of concept phase of my project, and am looking for the cleanest ways to do this (that actually work). I might also be thinking about this in the wrong direction, so any suggestions are welcome.
So to some things up here, how to you call a function from a library with nothing more than a QObject pointer, and a string?
Thanks Everyone,
Rian
Bookmarks