Felix Krull committed 276b261

Display correct actions even when device objects are re-sorted.

This fixes another problem with "Show Assigned First".

Comments (0)

Files changed (1)


         if (lpdiaf->rgoAction[i].dwFlags & DIA_APPFIXED) continue;
         /* Add action string and index in the action format to the list entry */
-        if (DIDFT_GETINSTANCE(lpdiaf->rgoAction[i].dwSemantic) & DIDFT_GETTYPE(device->ddo[obj].dwType))
+        if (DIDFT_GETINSTANCE(lpdiaf->rgoAction[i].dwSemantic) & DIDFT_GETTYPE(device->ddo[lv_get_item_id(dialog, obj)].dwType))
             SendDlgItemMessage(dialog, IDC_ACTIONLIST, LB_ADDSTRING, 0, (LPARAM) lpdiaf->rgoAction[i].lptszActionName);
             SendDlgItemMessage(dialog, IDC_ACTIONLIST, LB_SETITEMDATA, added, (LPARAM) i);