mirror of
https://github.com/wmjordan/PDFPatcher.git
synced 2026-10-17 04:41:14 +08:00
!将HistoryComboBox改成不区分大小写
This commit is contained in:
@@ -44,12 +44,25 @@ namespace PDFPatcher
|
||||
}
|
||||
|
||||
int IndexOf(string o) {
|
||||
var l = Contents;
|
||||
if (l != null) {
|
||||
return l.IndexOf(o);
|
||||
if (Contents != null) {
|
||||
var c = Contents;
|
||||
var l = c.Count;
|
||||
for (var i = 0; i < l; i++) {
|
||||
if (String.Equals(c[i], o, StringComparison.OrdinalIgnoreCase)) {
|
||||
return i;
|
||||
}
|
||||
}
|
||||
return -1;
|
||||
}
|
||||
else {
|
||||
return Items.IndexOf(o);
|
||||
var c = Items;
|
||||
var l = c.Count;
|
||||
for (var i = 0; i < l; i++) {
|
||||
if (String.Equals(c[i] as string, o, StringComparison.OrdinalIgnoreCase)) {
|
||||
return i;
|
||||
}
|
||||
}
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user