summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2012-10-26 16:30:03 +0000
committerGeorge Hazan <george.hazan@gmail.com>2012-10-26 16:30:03 +0000
commit962555da3092fbe8ff6e65eb590c1fa38bf1a124 (patch)
treeaae4dcd322ed41be5294fa33b01a8ae7c7664a31 /src
parent03641e5604df02401380428a5382def79a266704 (diff)
more efficient sorting
git-svn-id: http://svn.miranda-ng.org/main/trunk@2086 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'src')
-rw-r--r--src/modules/plugins/pluginopts.cpp7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/modules/plugins/pluginopts.cpp b/src/modules/plugins/pluginopts.cpp
index 7a7956a5da..7e6012577c 100644
--- a/src/modules/plugins/pluginopts.cpp
+++ b/src/modules/plugins/pluginopts.cpp
@@ -230,11 +230,8 @@ static LRESULT CALLBACK PluginListWndProc(HWND hwnd, UINT msg, WPARAM wParam, LP
static int CALLBACK SortPlugins(WPARAM i1, LPARAM i2, LPARAM lParamSort)
{
- HWND hwndList = (HWND)lParamSort;
- TCHAR tszFile1[MAX_PATH], tszFile2[MAX_PATH];
- ListView_GetItemText(hwndList, i1, 2, tszFile1, SIZEOF(tszFile1));
- ListView_GetItemText(hwndList, i2, 2, tszFile2, SIZEOF(tszFile2));
- return _tcscmp(tszFile1, tszFile2); // always sorting backwards
+ PluginListItemData *p1 = (PluginListItemData*)i1, *p2 = (PluginListItemData*)i2;
+ return _tcscmp(p1->fileName, p2->fileName);
}
INT_PTR CALLBACK DlgPluginOpt(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam)