PDA

View Full Version : Custom Keyboard Plugin Error-QT Embedded



augusbas
3rd August 2009, 07:49
Hi,

We have developed a custom keyboard plugin for Qt-Embedded and Qtopia.

The plugin works fine with Qtopia. But the same plugin, if we compile for Qt-Embedded we have compilation error for the follwing code.



QWSKeyboardHandler* IMX31KbdDriverPlugin::create( const QString& driver)
{
if (driver.toLower() == "imx31kbdhandler") {
qWarning("Before call IMX31KbdHandler()");
return new IMX31KbdHandler();
}
return 0;
}

Error:

imx31kbddriverplugin.cpp:57: error: expected type-specifier before ‘IMX31KbdHandler’
imx31kbddriverplugin.cpp:57: error: cannot convert ‘int*’ to ‘QWSKeyboardHandler*’ in return
imx31kbddriverplugin.cpp:57: error: expected ‘;’ before ‘IMX31KbdHandler’
imx31kbddriverplugin.cpp:57: error: ‘IMX31KbdHandler’ was not declared in this scope

return new IMX31KbdHandler(); is the only instruction which creates the error. No idea what could be the reason. Suggestions please.