?? You can't access the parameters of one function in another.. You need to store it as a member..
class MyThread : ..
{
public:
{
m_data = p_Map;
}
void run()
{
//use m_data ..;
}
private:
map<int>& m_data;
}
class MyThread : ..
{
public:
MyThread(map <int> &p_Map,QObject* parent): QThread(parent)
{
m_data = p_Map;
}
void run()
{
//use m_data ..;
}
private:
map<int>& m_data;
}
To copy to clipboard, switch view to plain text mode
I never tried references in that way.. if it doesn't work just use a pointer to the map.
HIH
Johannes
Bookmarks