Arma Reforger Explorer 1.7.0.54
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
Loading...
Searching...
No Matches
SCR_CompareLocalizeProperty.c
Go to the documentation of this file.
1
2//-------------------------------------------------------------------------------------------
3class SCR_CompareLocalizeProperty : SCR_SortCompare<SCR_LocalizedProperty>
4{
5 //-------------------------------------------------------------------------------------------
6 override static int Compare(SCR_LocalizedProperty left, SCR_LocalizedProperty right)
7 {
8 if (!left || !right)
9 return -1;
10
11 string name1 = ResolveName(left.m_sLabel);
12 string name2 = ResolveName(right.m_sLabel);
13
14 if (name1.Compare(name2) == -1)
15 return 1;
16 else
17 return 0;
18 }
19
20 //-------------------------------------------------------------------------------------------
21 static string ResolveName(string name)
22 {
23 if (name.StartsWith("#"))
24 return WidgetManager.Translate(name);
25 else
26 return name;
27 }
28};
SCR_VONRadialDisplay Compare
Sort by localized property labels.
Variable that is using localized label.