Skip to content

Commit ff931af

Browse files
author
Pavel Kovalenko
committed
Merge branch 'dev'
2 parents 414fcdb + 135a531 commit ff931af

File tree

388 files changed

+53700
-50492
lines changed

Some content is hidden

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

388 files changed

+53700
-50492
lines changed

src/xrCore/ChooseTypes.H

Lines changed: 39 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
#ifndef ChooseTypesH
22
#define ChooseTypesH
33

4-
enum EChooseMode{
4+
enum EChooseMode
5+
{
56
smCustom = 0,
67
smSoundSource,
78
smSoundEnv,
@@ -25,50 +26,54 @@ enum EChooseMode{
2526
smGameSMotions,
2627
};
2728

28-
enum EChooseFlags{
29-
cfMultiSelect = (1<<0),
30-
cfAllowNone = (1<<1),
31-
cfFullExpand = (1<<2),
29+
enum EChooseFlags
30+
{
31+
cfMultiSelect = (1 << 0),
32+
cfAllowNone = (1 << 1),
33+
cfFullExpand = (1 << 2),
3234
};
3335

34-
struct SChooseItem{
35-
shared_str name;
36-
shared_str hint;
37-
SChooseItem (LPCSTR nm, LPCSTR ht):name(nm),hint(ht){}
36+
struct SChooseItem
37+
{
38+
shared_str name;
39+
shared_str hint;
40+
SChooseItem(LPCSTR nm, LPCSTR ht) :name(nm), hint(ht) {}
3841
};
39-
DEFINE_VECTOR(SChooseItem,ChooseItemVec,ChooseItemVecIt);
42+
DEFINE_VECTOR(SChooseItem, ChooseItemVec, ChooseItemVecIt);
4043

4144
// typedef
42-
typedef fastdelegate::FastDelegate2<ChooseItemVec&,void*> TOnChooseFillItems;
43-
typedef fastdelegate::FastDelegate2<SChooseItem*, PropItemVec&> TOnChooseSelectItem;
44-
typedef fastdelegate::FastDelegate3<LPCSTR, HDC, const Irect&> TOnDrawThumbnail;
45-
typedef fastdelegate::FastDelegate0<> TOnChooseClose;
45+
typedef fastdelegate::FastDelegate2<ChooseItemVec&, void*> TOnChooseFillItems;
46+
typedef fastdelegate::FastDelegate2<SChooseItem*, PropItemVec&> TOnChooseSelectItem;
47+
typedef fastdelegate::FastDelegate3<LPCSTR, HDC, const Irect&> TOnDrawThumbnail;
48+
typedef fastdelegate::FastDelegate0<> TOnChooseClose;
4649

47-
typedef void (*TOnChooseFillEvents)();
50+
typedef void(*TOnChooseFillEvents)();
4851

49-
struct SChooseEvents{
50-
enum{
51-
flAnimated = (1<<0),
52+
struct SChooseEvents
53+
{
54+
enum
55+
{
56+
flAnimated = (1 << 0),
5257
};
53-
shared_str caption;
54-
TOnChooseFillItems on_fill;
55-
TOnChooseSelectItem on_sel;
56-
TOnDrawThumbnail on_thm;
57-
TOnChooseClose on_close;
58-
Flags32 flags;
59-
SChooseEvents (){caption="Select Item";flags.zero();}
60-
SChooseEvents (LPCSTR capt, TOnChooseFillItems f, TOnChooseSelectItem s, TOnDrawThumbnail t, TOnChooseClose c, u32 fl)
58+
shared_str caption;
59+
TOnChooseFillItems on_fill;
60+
TOnChooseSelectItem on_sel;
61+
TOnDrawThumbnail on_thm;
62+
TOnChooseClose on_close;
63+
Flags32 flags;
64+
SChooseEvents() { caption = "Select Item"; flags.zero(); }
65+
SChooseEvents(LPCSTR capt, TOnChooseFillItems f, TOnChooseSelectItem s, TOnDrawThumbnail t, TOnChooseClose c, u32 fl)
6166
{
62-
Set (capt,f,s,t,c,fl);
67+
Set(capt, f, s, t, c, fl);
6368
}
64-
void Set (LPCSTR capt, TOnChooseFillItems f, TOnChooseSelectItem s, TOnDrawThumbnail t, TOnChooseClose c, u32 fl)
69+
void Set(LPCSTR capt, TOnChooseFillItems f, TOnChooseSelectItem s, TOnDrawThumbnail t, TOnChooseClose c, u32 fl)
6570
{
66-
caption = capt;
67-
on_fill = f;
68-
on_sel = s;
69-
on_thm = t;
70-
on_close = c;
71-
flags.assign (fl);
71+
caption = capt;
72+
on_fill = f;
73+
on_sel = s;
74+
on_thm = t;
75+
on_close = c;
76+
flags.assign(fl);
7277
}
7378
};
7479

0 commit comments

Comments
 (0)