Develop and Download Open Source Software

Browse Subversion Repository

Contents of /trunk/CRailwayMode.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1 - (show annotations) (download) (as text)
Sun Aug 15 01:53:13 2010 UTC (13 years, 9 months ago) by okadu
File MIME type: text/x-chdr
File size: 2294 byte(s)


1 #ifndef CRAILWAYMODE_H_INCLUDED
2 #define CRAILWAYMODE_H_INCLUDED
3
4 #include "CWindowCtrl.h"
5 #include "CPushButton.h"
6 #include "CCheckBox.h"
7 #include "CStaticCtrl.h"
8 #include "CEditCtrl.h"
9 #include "CCamera.h"
10
11 class CRailPlugin;
12 class CTiePlugin;
13 class CGirderPlugin;
14 class CPierPlugin;
15 class CLinePlugin;
16 class CPolePlugin;
17 class CRailBuilder;
18
19 /*
20 * 線路関係モード基本クラス
21 */
22 class CRailwayMode{
23 protected:
24 static int ms_CurrentType; // モードタイプ
25 static int ms_WindowPos[][2]; // ウィンドウ座標
26 static int ms_TrackNum; // 線数
27 static float ms_TrackInterval; // 線間隔
28 static CWindowCtrl ms_RailWindow; // 線路設定窓
29 static CPushButton ms_PluginSetButton; // プラグインセットボタン
30 static CStaticCtrl ms_TypeLabel; // 種類ラベル
31 static CCheckBox ms_Type[]; // 種類チェック
32 static CCheckBox ms_EnableCant; // カントチェック
33 static CCheckBox ms_LiftRailSurface; // 高度補正チェック
34 static CStaticCtrl ms_MultiTrackLabel; // 複線ラベル
35 static CCheckBox ms_MultiTrackCheck; // 複線チェック
36 static CStaticCtrl ms_TrackNumLabel; // 軌道数ラベル
37 static CEditCtrl ms_TrackNumEdit; // 軌道数
38 static CStaticCtrl ms_TrackIntLabel; // 軌道間隔ラベル
39 static CEditCtrl ms_TrackIntEdit; // 軌道間隔
40 static CCamera ms_RailwayModeCamera; // カメラ
41 public:
42 static void InitRailwayInterface();
43 static void GetPlugin(CRailPlugin **, CTiePlugin **,
44 CGirderPlugin **, CPierPlugin **, CLinePlugin **, CPolePlugin **);
45 static void SetRailwayOption(
46 bool, bool, bool, bool, bool, bool, bool, bool, bool, int, float);
47 static bool IsMultiTrack(){ return !!ms_MultiTrackCheck.GetCheck(); }
48 static bool IsCantEnabled(){ return !!ms_EnableCant.GetCheck(); }
49 static bool IsLiftRail(){ return !!ms_LiftRailSurface.GetCheck(); }
50 static int GetTrackNum(){
51 int ret; sscanf(ms_TrackNumEdit.GetText(), "%d", &ret);
52 ValueArea(&ret, 1, 100); return ret;
53 }
54 static float GetTrackInterval(){
55 float ret; sscanf(ms_TrackIntEdit.GetText(), "%f", &ret);
56 ValueArea(&ret, 0.01f, 100.0f); return Round(ret*100.0f)*0.01f;
57 }
58 static char *LoadRailwaySetting(char *);
59 static void SaveRailwaySetting(FILE *);
60 static void EnterRailway(int);
61 static void ScanInputRailway();
62 static void ReformEditValue();
63 };
64
65 #endif

Back to OSDN">Back to OSDN
ViewVC Help
Powered by ViewVC 1.1.26