Tottish
16th February 2011, 13:18
Hey!
I've been developing a program with two custom listviews (custom views derived from QTableView) in it. They both read from the same model which is a derived QSortFilterProxyModel that in turn has a QSqlQueryModel as sourcemodel.
I've recently discovered that "sometimes" when the QSqlQueryModel is updated the listview "pops" all the way to the top.
The QSqlQueryModel is updated every 2 seconds in a separate thread against a local MySQL server.
How many updates it takes before the list "pops" varies from maybe 5 to 10 minutes. An interesting note is that if I'm running a virus scan the pop is much more prone to occur and the list seldom go a minute without popping to the top.
It doesn't seem to matter whether I use it intensely (clicking and scrolling around like a mad man) or just sit back in my chair and watch.
I realize it's impossible to tell what the error is providing there is many custom classes and loads of code. But I'm just wondering if this type of behavior is ringing a bell for anyone?
Any ideas on where to start looking?
Thank you!
/Tottish
I've been developing a program with two custom listviews (custom views derived from QTableView) in it. They both read from the same model which is a derived QSortFilterProxyModel that in turn has a QSqlQueryModel as sourcemodel.
I've recently discovered that "sometimes" when the QSqlQueryModel is updated the listview "pops" all the way to the top.
The QSqlQueryModel is updated every 2 seconds in a separate thread against a local MySQL server.
How many updates it takes before the list "pops" varies from maybe 5 to 10 minutes. An interesting note is that if I'm running a virus scan the pop is much more prone to occur and the list seldom go a minute without popping to the top.
It doesn't seem to matter whether I use it intensely (clicking and scrolling around like a mad man) or just sit back in my chair and watch.
I realize it's impossible to tell what the error is providing there is many custom classes and loads of code. But I'm just wondering if this type of behavior is ringing a bell for anyone?
Any ideas on where to start looking?
Thank you!
/Tottish