aboutsummaryrefslogtreecommitdiff
path: root/qmidiplayer-desktop/qmpplugin.cpp
diff options
context:
space:
mode:
authorGravatar Chris Xiong <chirs241097@gmail.com> 2017-02-12 23:33:41 +0800
committerGravatar Chris Xiong <chirs241097@gmail.com> 2017-02-12 23:33:41 +0800
commit3312e495cf54a8bd6451552216f5aeea1a06d486 (patch)
tree2de25e8b53ba2747c613451fa16c3203578fbd93 /qmidiplayer-desktop/qmpplugin.cpp
parentd779d32c8c32e0e0c22662046498620b11fa46de (diff)
downloadQMidiPlayer-3312e495cf54a8bd6451552216f5aeea1a06d486.tar.xz
UI revolution cont'd. Powered by @BLumia.
Expose new APIs to plugin developer. Use svg icons.
Diffstat (limited to 'qmidiplayer-desktop/qmpplugin.cpp')
-rw-r--r--qmidiplayer-desktop/qmpplugin.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/qmidiplayer-desktop/qmpplugin.cpp b/qmidiplayer-desktop/qmpplugin.cpp
index 7ff305c..f93cddf 100644
--- a/qmidiplayer-desktop/qmpplugin.cpp
+++ b/qmidiplayer-desktop/qmpplugin.cpp
@@ -179,6 +179,8 @@ bool qmpPluginAPI::isDarkTheme(){return qmw?qmw->isDarkTheme():false;}
void qmpPluginAPI::discardCurrentEvent(){if(qmw&&qmw->getPlayer())qmw->getPlayer()->discardCurrentEvent();}
void qmpPluginAPI::commitEventChange(SEventCallBackData d){if(qmw&&qmw->getPlayer())qmw->getPlayer()->commitEventChange(d);}
void qmpPluginAPI::callEventReaderCB(SEventCallBackData d){if(qmw&&qmw->getPlayer())qmw->getPlayer()->callEventReaderCB(d);}
+void qmpPluginAPI::setFuncState(std::string name,bool state){if(qmw)qmw->setFuncState(name,state);}
+void qmpPluginAPI::setFuncEnabled(std::string name,bool enable){if(qmw)qmw->setFuncEnabled(name,enable);}
int qmpPluginAPI::registerEventHandlerIntf(IMidiCallBack *cb,void *userdata)
{return qmw->getPlayer()->setEventHandlerCB(cb,userdata);}
@@ -192,6 +194,10 @@ void qmpPluginAPI::registerVisualizationIntf(qmpVisualizationIntf* intf,std::str
{qmw->registerVisualizationIntf(intf,name,desc,icon,iconlen);}
void qmpPluginAPI::unregisterVisualizationIntf(std::string name)
{qmw->unregisterVisualizationIntf(name);}
+void qmpPluginAPI::registerFunctionality(qmpFuncBaseIntf *i,std::string name,std::string desc,const char *icon,int iconlen,bool checkable)
+{qmw->registerFunctionality(i,name,desc,icon,iconlen,checkable);}
+void qmpPluginAPI::unregisterFunctionality(std::string name)
+{qmw->unregisterFunctionality(name);}
int qmpPluginAPI::registerFileReadFinishedHandlerIntf(IMidiCallBack* cb,void* userdata)
{return qmw->getPlayer()->setFileReadFinishedCB(cb,userdata);}
void qmpPluginAPI::unregisterFileReadFinishedHandlerIntf(int intfhandle)