Skip to content

Commit 159a60f

Browse files
committed
Релиз 2.10.0.0
1 parent def88f5 commit 159a60f

321 files changed

Lines changed: 14244 additions & 6001 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

OneScriptForms/OneScriptForms/Action.cs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
namespace osf
55
{
6-
[ContextClass ("КлДействие", "ClAction")]
6+
[ContextClass("КлДействие", "ClAction")]
77
public class ClAction : AutoContext<ClAction>
88
{
99
public ClAction(IRuntimeContextInstance script, string methodName, IValue param = null)
@@ -12,15 +12,15 @@ public ClAction(IRuntimeContextInstance script, string methodName, IValue param
1212
MethodName = methodName;
1313
Parameter = param;
1414
}
15-
15+
1616
[ContextProperty("ИмяМетода", "MethodName")]
1717
public string MethodName { get; set; }
18-
18+
1919
[ContextProperty("Параметр", "Parameter")]
2020
public IValue Parameter { get; set; }
21-
21+
2222
[ContextProperty("Сценарий", "Script")]
2323
public IRuntimeContextInstance Script { get; set; }
24-
24+
2525
}
2626
}

OneScriptForms/OneScriptForms/AnchorStyles.cs

Lines changed: 48 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
namespace osf
77
{
8-
[ContextClass ("КлСтилиПривязки", "ClAnchorStyles")]
8+
[ContextClass("КлСтилиПривязки", "ClAnchorStyles")]
99
public class ClAnchorStyles : AutoContext<ClAnchorStyles>, ICollectionContext, IEnumerable<IValue>
1010
{
1111
private int m_none = (int)System.Windows.Forms.AnchorStyles.None; // 0 Элемент управления не привязан к краям контейнера.
@@ -39,6 +39,48 @@ IEnumerator<IValue> IEnumerable<IValue>.GetEnumerator()
3939
}
4040
}
4141

42+
[ContextProperty("Количество", "Count")]
43+
public int CountProp
44+
{
45+
get { return _list.Count; }
46+
}
47+
48+
[ContextMethod("Получить", "Get")]
49+
public IValue Get(int index)
50+
{
51+
return _list[index];
52+
}
53+
54+
[ContextMethod("Имя")]
55+
public string NameRu(decimal p1)
56+
{
57+
return namesRu.TryGetValue(p1, out string name) ? name : p1.ToString();
58+
}
59+
60+
[ContextMethod("Name")]
61+
public string NameEn(decimal p1)
62+
{
63+
return namesEn.TryGetValue(p1, out string name) ? name : p1.ToString();
64+
}
65+
66+
private static readonly Dictionary<decimal, string> namesRu = new Dictionary<decimal, string>
67+
{
68+
{1, "Верх"},
69+
{4, "Лево"},
70+
{2, "Низ"},
71+
{0, "Отсутствие"},
72+
{8, "Право"},
73+
};
74+
75+
private static readonly Dictionary<decimal, string> namesEn = new Dictionary<decimal, string>
76+
{
77+
{1, "Top"},
78+
{4, "Left"},
79+
{2, "Bottom"},
80+
{0, "None"},
81+
{8, "Right"},
82+
};
83+
4284
public ClAnchorStyles()
4385
{
4486
_list = new List<IValue>();
@@ -52,31 +94,31 @@ public ClAnchorStyles()
5294
[ContextProperty("Верх", "Top")]
5395
public int Top
5496
{
55-
get { return m_top; }
97+
get { return m_top; }
5698
}
5799

58100
[ContextProperty("Лево", "Left")]
59101
public int Left
60102
{
61-
get { return m_left; }
103+
get { return m_left; }
62104
}
63105

64106
[ContextProperty("Низ", "Bottom")]
65107
public int Bottom
66108
{
67-
get { return m_bottom; }
109+
get { return m_bottom; }
68110
}
69111

70112
[ContextProperty("Отсутствие", "None")]
71113
public int None
72114
{
73-
get { return m_none; }
115+
get { return m_none; }
74116
}
75117

76118
[ContextProperty("Право", "Right")]
77119
public int Right
78120
{
79-
get { return m_right; }
121+
get { return m_right; }
80122
}
81123
}
82124
}

OneScriptForms/OneScriptForms/AnnuallyBoldedDates.cs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
namespace osf
66
{
7-
[ContextClass ("КлЕжегодныеДаты", "ClAnnuallyBoldedDates")]
7+
[ContextClass("КлЕжегодныеДаты", "ClAnnuallyBoldedDates")]
88
public class ClAnnuallyBoldedDates : AutoContext<ClAnnuallyBoldedDates>
99
{
1010
public osf.MonthCalendar M_MonthCalendar;
@@ -14,13 +14,13 @@ public System.DateTime[] M_Object
1414
get { return M_MonthCalendar.AnnuallyBoldedDates; }
1515
set { M_MonthCalendar.AnnuallyBoldedDates = value; }
1616
}
17-
17+
1818
[ContextProperty("Количество", "Count")]
1919
public int Count
2020
{
2121
get { return M_Object.Length; }
2222
}
23-
23+
2424
[ContextMethod("Добавить", "Add")]
2525
public IValue Add(IValue p1)
2626
{
@@ -31,13 +31,13 @@ public IValue Add(IValue p1)
3131
M_Object = DateTime2;
3232
return p1;
3333
}
34-
34+
3535
[ContextMethod("Очистить", "Clear")]
3636
public void Clear()
3737
{
3838
M_Object = new DateTime[0];
3939
}
40-
40+
4141
[ContextMethod("Элемент", "Item")]
4242
public IValue Item(int p1)
4343
{

OneScriptForms/OneScriptForms/Appearance.cs

Lines changed: 39 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
namespace osf
77
{
8-
[ContextClass ("КлОформление", "ClAppearance")]
8+
[ContextClass("КлОформление", "ClAppearance")]
99
public class ClAppearance : AutoContext<ClAppearance>, ICollectionContext, IEnumerable<IValue>
1010
{
1111
private int m_normal = (int)System.Windows.Forms.Appearance.Normal; // 0 Внешний вид по умолчанию, определенный классом элемента управления.
@@ -36,6 +36,42 @@ IEnumerator<IValue> IEnumerable<IValue>.GetEnumerator()
3636
}
3737
}
3838

39+
[ContextProperty("Количество", "Count")]
40+
public int CountProp
41+
{
42+
get { return _list.Count; }
43+
}
44+
45+
[ContextMethod("Получить", "Get")]
46+
public IValue Get(int index)
47+
{
48+
return _list[index];
49+
}
50+
51+
[ContextMethod("Имя")]
52+
public string NameRu(decimal p1)
53+
{
54+
return namesRu.TryGetValue(p1, out string name) ? name : p1.ToString();
55+
}
56+
57+
[ContextMethod("Name")]
58+
public string NameEn(decimal p1)
59+
{
60+
return namesEn.TryGetValue(p1, out string name) ? name : p1.ToString();
61+
}
62+
63+
private static readonly Dictionary<decimal, string> namesRu = new Dictionary<decimal, string>
64+
{
65+
{1, "Кнопка"},
66+
{0, "Стандартное"},
67+
};
68+
69+
private static readonly Dictionary<decimal, string> namesEn = new Dictionary<decimal, string>
70+
{
71+
{1, "Button"},
72+
{0, "Normal"},
73+
};
74+
3975
public ClAppearance()
4076
{
4177
_list = new List<IValue>();
@@ -46,13 +82,13 @@ public ClAppearance()
4682
[ContextProperty("Кнопка", "Button")]
4783
public int Button
4884
{
49-
get { return m_button; }
85+
get { return m_button; }
5086
}
5187

5288
[ContextProperty("Стандартное", "Normal")]
5389
public int Normal
5490
{
55-
get { return m_normal; }
91+
get { return m_normal; }
5692
}
5793
}
5894
}

OneScriptForms/OneScriptForms/Application.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ public void Run(Form form = null)
5454
}
5555
}
5656

57-
[ContextClass ("КлПриложение", "ClApplication")]
57+
[ContextClass("КлПриложение", "ClApplication")]
5858
public class ClApplication : AutoContext<ClApplication>
5959
{
6060
public ClApplication()
@@ -63,16 +63,16 @@ public ClApplication()
6363
Application1.dll_obj = this;
6464
Base_obj = Application1;
6565
}
66-
66+
6767
public ClApplication(Application p1)
6868
{
6969
Application Application1 = p1;
7070
Application1.dll_obj = this;
7171
Base_obj = Application1;
7272
}
73-
73+
7474
public Application Base_obj;
75-
75+
7676
[ContextProperty("Версия", "Version")]
7777
public ClVersion Version
7878
{
@@ -90,13 +90,13 @@ public string ProductName
9090
{
9191
get { return ((AssemblyTitleAttribute)Assembly.GetExecutingAssembly().GetCustomAttributes(typeof(AssemblyTitleAttribute), false)[0]).Title.ToString(); }
9292
}
93-
93+
9494
[ContextProperty("ПутьДанныхПриложенияПользователя", "UserAppDataPath")]
9595
public string UserAppDataPath
9696
{
9797
get { return Base_obj.UserAppDataPath; }
9898
}
99-
99+
100100
[ContextMethod("ВключитьВизуальныеСтили", "EnableVisualStyles")]
101101
public void EnableVisualStyles()
102102
{

OneScriptForms/OneScriptForms/ArrayList.cs

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ public int Compare(object x, object y)
156156
}
157157
else if (sortOrder == 1)
158158
{
159-
159+
160160
}
161161
else if (sortOrder == 2)
162162
{
@@ -261,7 +261,7 @@ public int Compare(object x, object y)
261261
}
262262
}
263263

264-
[ContextClass ("КлМассивСписок", "ClArrayList")]
264+
[ContextClass("КлМассивСписок", "ClArrayList")]
265265
public class ClArrayList : AutoContext<ClArrayList>
266266
{
267267
public ClArrayList()
@@ -270,34 +270,34 @@ public ClArrayList()
270270
ArrayList1.dll_obj = this;
271271
Base_obj = ArrayList1;
272272
}
273-
273+
274274
public ClArrayList(ArrayList p1)
275275
{
276276
ArrayList ArrayList1 = p1;
277277
ArrayList1.dll_obj = this;
278278
Base_obj = ArrayList1;
279279
}
280-
280+
281281
public ArrayList Base_obj;
282-
282+
283283
[ContextProperty("Количество", "Count")]
284284
public int Count
285285
{
286286
get { return Base_obj.Count; }
287287
}
288-
288+
289289
[ContextMethod("Вставить", "Insert")]
290290
public IValue Insert(int p1, IValue p2)
291291
{
292292
return (IValue)Base_obj.Insert(p1, p2);
293293
}
294-
294+
295295
[ContextMethod("Добавить", "Add")]
296296
public IValue Add(IValue p1 = null)
297297
{
298298
return (IValue)Base_obj.Add(p1);
299299
}
300-
300+
301301
[ContextMethod("Индекс", "IndexOf")]
302302
public int IndexOf(IValue p1)
303303
{
@@ -309,13 +309,13 @@ public void Reverse()
309309
{
310310
Base_obj.Reverse();
311311
}
312-
312+
313313
[ContextMethod("Очистить", "Clear")]
314314
public void Clear()
315315
{
316316
Base_obj.Clear();
317317
}
318-
318+
319319
[ContextMethod("Содержит", "Contains")]
320320
public bool Contains(IValue p1)
321321
{

0 commit comments

Comments
 (0)