12-27-2012 04:37 AM
I'm a newbie, so forgive me if I'm asking questions already present in one of your resources.
Firstly, where can I find the header for the App class? One of the examples state that you can write the following code:
12-27-2012 05:26 AM
Are you trying an App Sample?
App:: is the class that you create, normally I do that:
I'll create an App called PlasticEraser
So I create two files:
PlasticEraser.cpp
#include "PlasticEraser.hpp"
PlasticEraser::PlasticEraser() {
// TODO Auto-generated constructor stub
}
PlasticEraser::~PlasticEraser() {
// TODO Auto-generated destructor stub
}
and PlasticEraser.hpp
#ifndef PLASTICERASER_HPP_
#define PLASTICERASER_HPP_
class PlasticEraser {
public:
PlasticEraser();
virtual ~PlasticEraser();
};
#endif /* PLASTICERASER_HPP_ */
In your case, your class APP, have a function called handleTouch(), guessing the name, you want a SLOT to handle a TouchEvent.
you should have inside your App.hpp something like this:
#ifndef APP_HPP_
#define APP_HPP_
#include <bb/cascades/TouchEvent>
class App {
public:
App();
virtual ~App();
private slots:
void handleTouch(TouchEvent* reply);
};
#endif /* APP_HPP_ */