qt - QSortFilterProxyModel: index from wrong model passed to mapToSource - why? -


i'm getting in application output , can't figure out problem. code, in subclass of qtableview, model() returning qsortfilterproxymodel:

  const qsortfilterproxymodel *proxy = dynamic_cast<const qsortfilterproxymodel*>(model());   qmodelindex proxy_index2 = proxy->index(row, column, qmodelindex());   qmodelindex model_index = proxy->maptosource(proxy_index2); 

what doing wrong? i'm using qt 4.7.

edit:

i'm not sure what's going on, code working fine now. did check index valid, proceeded time being. i'm not sure changed fixed problem, code above working fine @ point.

it helpful know fixed problem of course can understand how use qt better, i'd have give guys rest of code @ point when saw problem - , have no copy of code in state. so, guess have remain mystery unless run again! thanks


Comments

Popular posts from this blog

ASP.NET/SQL find the element ID and update database -

jquery - appear modal windows bottom -

c++ - Compiling static TagLib 1.6.3 libraries for Windows -