Mercurial > sumwars
changeset 2690:2972b4ab3cef
refs #29: Removed compile errors, to get the project to build with the "build tools" option enabled
(not yet finished: still need to update the layouts and code, as there are discrepancies).
line wrap: on
line diff
--- a/share/resources/gui_0.8/layouts/benchmarktab.layout Sun Mar 23 21:04:27 2014 +0100 +++ b/share/resources/gui_0.8/layouts/benchmarktab.layout Wed Mar 26 23:39:02 2014 +0200 @@ -3,97 +3,99 @@ <GUILayout version="4" > <Window type="DefaultWindow" name="BenchmarkTab" > <Property name="Area" value="{{0.209961,0},{0.175781,0},{0.81543,0},{0.761719,0}}" /> - <Window type="TaharezLook/Button" name="BenchmarkTab/StartButton" > + <Window type="TaharezLook/Button" name="StartButton" > <Property name="Text" value="Start Benchmark" /> <Property name="Area" value="{{0.0235144,0},{0.861905,0},{0.34983,0},{0.973016,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="BenchmarkTab/CPULabel" > + <Window type="TaharezLook/StaticText" name="CPULabel" > <Property name="Text" value="CPU:" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.0210526,0},{0.0428571,1},{0.0939728,2},{0.120635,1}}" /> <Property name="BackgroundEnabled" value="False" /> - <AutoWindow NameSuffix="__auto_hscrollbar__" > - <AutoWindow NameSuffix="__auto_incbtn__" /> + + <AutoWindow namePath="__auto_hscrollbar__" > + <AutoWindow namePath="__auto_incbtn__" /> </AutoWindow> - <AutoWindow NameSuffix="__auto_vscrollbar__" > - <AutoWindow NameSuffix="__auto_incbtn__" /> + <AutoWindow namePath="__auto_vscrollbar__" > + <AutoWindow namePath="__auto_incbtn__" /> </AutoWindow> + </Window> - <Window type="TaharezLook/StaticText" name="BenchmarkTab/GPULabel2" > + <Window type="TaharezLook/StaticText" name="GPULabel2" > <Property name="Text" value="GPU:" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.0210526,0},{0.136508,-1},{0.0939727,2},{0.214286,-1}}" /> <Property name="BackgroundEnabled" value="False" /> - <AutoWindow NameSuffix="__auto_hscrollbar__" > - <AutoWindow NameSuffix="__auto_incbtn__" /> + <AutoWindow namePath="__auto_hscrollbar__" > + <AutoWindow namePath="__auto_incbtn__" /> </AutoWindow> - <AutoWindow NameSuffix="__auto_vscrollbar__" > - <AutoWindow NameSuffix="__auto_incbtn__" /> + <AutoWindow namePath="__auto_vscrollbar__" > + <AutoWindow namePath="__auto_incbtn__" /> </AutoWindow> </Window> - <Window type="TaharezLook/MultiLineEditbox" name="BenchmarkTab/ResultsEditbox" > + <Window type="TaharezLook/MultiLineEditbox" name="ResultsEditbox" > <Property name="Text" > </Property> <Property name="MaxTextLength" value="1073741823" /> <Property name="Area" value="{{0.0241935,0},{0.233333,0},{0.983871,0},{0.844445,0}}" /> <Property name="TextParsingEnabled" value="False" /> - <AutoWindow NameSuffix="__auto_hscrollbar__" > - <AutoWindow NameSuffix="__auto_incbtn__" /> + <AutoWindow namePath="__auto_hscrollbar__" > + <AutoWindow namePath="__auto_incbtn__" /> </AutoWindow> - <AutoWindow NameSuffix="__auto_vscrollbar__" > - <AutoWindow NameSuffix="__auto_incbtn__" /> + <AutoWindow namePath="__auto_vscrollbar__" > + <AutoWindow namePath="__auto_incbtn__" /> </AutoWindow> </Window> - <Window type="TaharezLook/Button" name="BenchmarkTab/Button" > + <Window type="TaharezLook/Button" name="Button" > <Property name="Text" value="Save Results" /> <Property name="Disabled" value="True" /> <Property name="Area" value="{{0.362903,0},{0.866667,0},{0.66129,0},{0.966667,0}}" /> </Window> - <Window type="TaharezLook/Button" name="BenchmarkTab/Button2" > + <Window type="TaharezLook/Button" name="Button2" > <Property name="Text" value="Send by Email" /> <Property name="Disabled" value="True" /> <Property name="Area" value="{{0.677419,0},{0.866667,0},{0.983871,0},{0.966667,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="BenchmarkTab/CPULabel2" > + <Window type="TaharezLook/StaticText" name="CPULabel2" > <Property name="Text" value="OS:" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.545246,2},{0.0428571,1},{0.610102,2},{0.120635,1}}" /> <Property name="BackgroundEnabled" value="False" /> - <AutoWindow NameSuffix="__auto_hscrollbar__" > - <AutoWindow NameSuffix="__auto_incbtn__" /> + <AutoWindow namePath="__auto_hscrollbar__" > + <AutoWindow namePath="__auto_incbtn__" /> </AutoWindow> - <AutoWindow NameSuffix="__auto_vscrollbar__" > - <AutoWindow NameSuffix="__auto_incbtn__" /> + <AutoWindow namePath="__auto_vscrollbar__" > + <AutoWindow namePath="__auto_incbtn__" /> </AutoWindow> </Window> - <Window type="TaharezLook/StaticText" name="BenchmarkTab/GPULabel22" > + <Window type="TaharezLook/StaticText" name="GPULabel22" > <Property name="Text" value="Driver:" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.496859,2},{0.136508,-1},{0.585908,2},{0.214285,-1}}" /> <Property name="BackgroundEnabled" value="False" /> - <AutoWindow NameSuffix="__auto_hscrollbar__" > - <AutoWindow NameSuffix="__auto_incbtn__" /> + <AutoWindow namePath="__auto_hscrollbar__" > + <AutoWindow namePath="__auto_incbtn__" /> </AutoWindow> - <AutoWindow NameSuffix="__auto_vscrollbar__" > - <AutoWindow NameSuffix="__auto_incbtn__" /> + <AutoWindow namePath="__auto_vscrollbar__" > + <AutoWindow namePath="__auto_incbtn__" /> </AutoWindow> </Window> - <Window type="TaharezLook/Editbox" name="BenchmarkTab/CPUBox" > + <Window type="TaharezLook/Editbox" name="CPUBox" > <Property name="MaxTextLength" value="1073741823" /> <Property name="Area" value="{{0.0967742,0},{0.0444444,0},{0.483871,0},{0.122222,0}}" /> <Property name="TextParsingEnabled" value="False" /> </Window> - <Window type="TaharezLook/Editbox" name="BenchmarkTab/GPUBox" > + <Window type="TaharezLook/Editbox" name="GPUBox" > <Property name="MaxTextLength" value="1073741823" /> <Property name="Area" value="{{0.0967742,0},{0.133333,0},{0.483871,0},{0.211111,0}}" /> <Property name="TextParsingEnabled" value="False" /> </Window> - <Window type="TaharezLook/Editbox" name="BenchmarkTab/OSBox" > + <Window type="TaharezLook/Editbox" name="OSBox" > <Property name="MaxTextLength" value="1073741823" /> <Property name="Area" value="{{0.596774,0},{0.0444447,0},{0.983871,0},{0.122222,0}}" /> <Property name="TextParsingEnabled" value="False" /> </Window> - <Window type="TaharezLook/Editbox" name="BenchmarkTab/DriverBox" > + <Window type="TaharezLook/Editbox" name="DriverBox" > <Property name="MaxTextLength" value="1073741823" /> <Property name="Area" value="{{0.596774,0},{0.133334,0},{0.983871,0},{0.211111,0}}" /> <Property name="TextParsingEnabled" value="False" />
--- a/share/resources/gui_0.8/layouts/contenteditor.layout Sun Mar 23 21:04:27 2014 +0100 +++ b/share/resources/gui_0.8/layouts/contenteditor.layout Wed Mar 26 23:39:02 2014 +0200 @@ -14,15 +14,15 @@ <Property name="TabHeight" value="{0,31.1724}" /> <Property name="TabPanePosition" value="Top" /> <Property name="Area" value="{{0.00391872,0},{0.00348824,0},{0.527266,0},{1.00058,0}}" /> - <Window type="DefaultWindow" name="RITab/BasicMesh" > + <Window type="DefaultWindow" name="BasicMesh" > <Property name="Text" value="Mesh" /> <Property name="Visible" value="False" /> <Property name="Area" value="{{0,0},{0,0},{1,0},{1,0}}" /> - <Window type="TaharezLook/Combobox" name="RITab/BM/MeshSelector" > + <Window type="TaharezLook/Combobox" name="MeshSelector" > <Property name="Area" value="{{0.334514,0},{0.0363174,0},{0.662888,0},{0.905855,0}}" /> <Property name="MaxTextLength" value="1073741823" /> </Window> - <Window type="TaharezLook/StaticText" name="RITab/BM/MainMeshLabel" > + <Window type="TaharezLook/StaticText" name="MainMeshLabel" > <Property name="Text" value="Select main mesh:" /> <Property name="HorzExtent" value="115" /> <Property name="VertExtent" value="15.5148" /> @@ -30,81 +30,81 @@ <Property name="Area" value="{{0.03739,0},{0.0186585,0},{0.327415,0},{0.0879001,0}}" /> </Window> </Window> - <Window type="DefaultWindow" name="RITab/SubMesh" > + <Window type="DefaultWindow" name="SubMesh" > <Property name="Text" value="Submeshes" /> <Property name="Visible" value="False" /> <Property name="Area" value="{{0,0},{0,0},{1,0},{1,0}}" /> - <Window type="TaharezLook/Combobox" name="RITab/SubMesh/Selector" > + <Window type="TaharezLook/Combobox" name="Selector" > <Property name="Area" value="{{0.3,0},{0.023961,0},{0.65,0},{0.50428,0}}" /> <Property name="MaxTextLength" value="1073741823" /> </Window> - <Window type="TaharezLook/Button" name="RITab/SubMesh/AddSubMeshButton" > + <Window type="TaharezLook/Button" name="AddSubMeshButton" > <Property name="Text" value="Add Submesh" /> <Property name="Area" value="{{0.7,0},{0.06618,0},{0.950041,0},{0.128133,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="RITab/SM/NewSubmeshLabel" > + <Window type="TaharezLook/StaticText" name="NewSubmeshLabel" > <Property name="Text" value="New submesh:" /> <Property name="HorzExtent" value="91" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.03,0},{0.022898,0},{0.238785,0},{0.068202,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="RITab/SM/NewSMNameLabel" > + <Window type="TaharezLook/StaticText" name="NewSMNameLabel" > <Property name="Text" value="submesh name:" /> <Property name="HorzExtent" value="97" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.0270315,0},{0.0721111,0},{0.243158,0},{0.127415,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="RITab/SM/EditSMLabel" > + <Window type="TaharezLook/StaticText" name="EditSMLabel" > <Property name="Text" value="Edit submesh:" /> <Property name="HorzExtent" value="86" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.0232801,0},{0.181441,0},{0.249406,0},{0.236745,0}}" /> </Window> - <Window type="TaharezLook/Combobox" name="RITab/SubMesh/EditSMSelector" > + <Window type="TaharezLook/Combobox" name="EditSMSelector" > <Property name="Area" value="{{0.3,0},{0.185165,0},{0.65,0},{0.575544,0}}" /> <Property name="MaxTextLength" value="1073741823" /> </Window> - <Window type="TaharezLook/StaticText" name="RITab/SM/AttachMeshLabel" > + <Window type="TaharezLook/StaticText" name="AttachMeshLabel" > <Property name="Text" value="Attach to:" /> <Property name="HorzExtent" value="61" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.08,0},{0.228963,0},{0.259419,0},{0.304266,0}}" /> </Window> - <Window type="TaharezLook/Combobox" name="RITab/SubMesh/AttachMeshSelector" > + <Window type="TaharezLook/Combobox" name="AttachMeshSelector" > <Property name="Area" value="{{0.24,0},{0.251637,0},{0.55,0},{0.696243,0}}" /> <Property name="MaxTextLength" value="1073741823" /> </Window> - <Window type="TaharezLook/StaticText" name="RITab/SM/BoneLabel" > + <Window type="TaharezLook/StaticText" name="BoneLabel" > <Property name="Text" value="at bone:" /> <Property name="HorzExtent" value="51" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.57,0},{0.242082,0},{0.721903,0},{0.301351,0}}" /> </Window> - <Window type="TaharezLook/Combobox" name="RITab/SubMesh/BoneSelector" > + <Window type="TaharezLook/Combobox" name="BoneSelector" > <Property name="Area" value="{{0.7,0},{0.254553,0},{0.98,0},{0.699159,0}}" /> <Property name="MaxTextLength" value="1073741823" /> </Window> - <Window type="TaharezLook/Editbox" name="RITab/SM/SMNameEditbox" > + <Window type="TaharezLook/Editbox" name="SMNameEditbox" > <Property name="MaxTextLength" value="1073741823" /> <Property name="Area" value="{{0.3,0},{0.077842,0},{0.65,0},{0.122302,0}}" /> <Property name="TextParsingEnabled" value="False" /> </Window> - <Window type="TaharezLook/Checkbox" name="RITab/SM/AttachSMCheckbox" > + <Window type="TaharezLook/Checkbox" name="AttachSMCheckbox" > <Property name="Area" value="{{0.0329296,0},{0.24344,0},{0.0784697,0},{0.293731,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="RITab/SM/RotateLabel" > + <Window type="TaharezLook/StaticText" name="RotateLabel" > <Property name="Text" value="Rotate(x,y,z):" /> <Property name="HorzExtent" value="84" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.02,0},{0.4,0},{0.219404,0},{0.46,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="RITab/SM/SMRotateX" > + <Window type="TaharezLook/Spinner" name="SMRotateX" > <Property name="StepSize" value="5" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="3600" /> @@ -113,7 +113,7 @@ <Property name="Area" value="{{0.25,0},{0.40842,0},{0.45,0},{0.46,0}}" /> <Property name="TextParsingEnabled" value="False" /> </Window> - <Window type="TaharezLook/Spinner" name="RITab/SM/SMRotateY" > + <Window type="TaharezLook/Spinner" name="SMRotateY" > <Property name="StepSize" value="5" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="3600" /> @@ -122,7 +122,7 @@ <Property name="Area" value="{{0.5,0},{0.40842,0},{0.7,0},{0.46,0}}" /> <Property name="TextParsingEnabled" value="False" /> </Window> - <Window type="TaharezLook/Spinner" name="RITab/SM/SMRotateZ" > + <Window type="TaharezLook/Spinner" name="SMRotateZ" > <Property name="StepSize" value="5" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="3600" /> @@ -131,14 +131,14 @@ <Property name="Area" value="{{0.75,0},{0.40842,0},{0.95,0},{0.46,0}}" /> <Property name="TextParsingEnabled" value="False" /> </Window> - <Window type="TaharezLook/StaticText" name="RITab/SM/ScaleLabel" > + <Window type="TaharezLook/StaticText" name="ScaleLabel" > <Property name="Text" value="Scale:" /> <Property name="HorzExtent" value="37" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.02,0},{0.5,0},{0.22,0},{0.56,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="RITab/SM/SMScale" > + <Window type="TaharezLook/Spinner" name="SMScale" > <Property name="StepSize" value="0.1" /> <Property name="CurrentValue" value="1" /> <Property name="MaximumValue" value="100" /> @@ -147,14 +147,14 @@ <Property name="Area" value="{{0.25,0},{0.5,0},{0.45,0},{0.56,0}}" /> <Property name="TextParsingEnabled" value="False" /> </Window> - <Window type="TaharezLook/StaticText" name="RITab/SM/OffsetLabel" > + <Window type="TaharezLook/StaticText" name="OffsetLabel" > <Property name="Text" value="Offset (x,y,z):" /> <Property name="HorzExtent" value="85" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.02,0},{0.6,0},{0.22,0},{0.66,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="RITab/SM/SMOffsetX" > + <Window type="TaharezLook/Spinner" name="SMOffsetX" > <Property name="StepSize" value="0.1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="200" /> @@ -163,7 +163,7 @@ <Property name="Area" value="{{0.25,0},{0.6,0},{0.45,0},{0.66,0}}" /> <Property name="TextParsingEnabled" value="False" /> </Window> - <Window type="TaharezLook/Spinner" name="RITab/SM/SMOffsetY" > + <Window type="TaharezLook/Spinner" name="SMOffsetY" > <Property name="StepSize" value="0.1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="200" /> @@ -172,7 +172,7 @@ <Property name="Area" value="{{0.5,0},{0.6,0},{0.7,0},{0.66,0}}" /> <Property name="TextParsingEnabled" value="False" /> </Window> - <Window type="TaharezLook/Spinner" name="RITab/SM/SMOffsetZ" > + <Window type="TaharezLook/Spinner" name="SMOffsetZ" > <Property name="StepSize" value="0.1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="200" /> @@ -181,34 +181,34 @@ <Property name="Area" value="{{0.75,0},{0.6,0},{0.95,0},{0.66,0}}" /> <Property name="TextParsingEnabled" value="False" /> </Window> - <Window type="TaharezLook/Button" name="RITab/SubMesh/DelSubMeshButton" > + <Window type="TaharezLook/Button" name="DelSubMeshButton" > <Property name="Text" value="Delete Submesh" /> <Property name="Area" value="{{0.672314,0},{0.76618,0},{0.950041,0},{0.828133,0}}" /> </Window> </Window> - <Window type="DefaultWindow" name="RITab/Animations" > + <Window type="DefaultWindow" name="Animations" > <Property name="Text" value="Animations" /> <Property name="Visible" value="False" /> <Property name="Area" value="{{0,0},{0,0},{1,0},{1,0}}" /> </Window> - <Window type="DefaultWindow" name="RITab/XML" > + <Window type="DefaultWindow" name="XML" > <Property name="Text" value="XML" /> <Property name="Visible" value="False" /> <Property name="Area" value="{{0,0},{0,0},{1,0},{1,0}}" /> - <Window type="TaharezLook/MultiLineEditbox" name="RITab/XML/RIXMLEditbox" > + <Window type="TaharezLook/MultiLineEditbox" name="RIXMLEditbox" > <Property name="Text" > </Property> <Property name="MaxTextLength" value="1073741823" /> <Property name="Area" value="{{0.0229259,0},{0.0172008,0},{0.986204,0},{0.901313,0}}" /> <Property name="TextParsingEnabled" value="False" /> </Window> - <Window type="TaharezLook/Button" name="RITab/XML/SubmitButton" > + <Window type="TaharezLook/Button" name="SubmitButton" > <Property name="Text" value="Submit XML" /> <Property name="Area" value="{{0.0344625,0},{0.919477,0},{0.390245,0},{0.976916,0}}" /> </Window> </Window> </Window> - <Window type="TaharezLook/StaticImage" name="RITab/BM/meshPreview" > + <Window type="TaharezLook/StaticImage" name="meshPreview" > <Property name="Area" value="{{0.535738,0},{0.0565595,0},{0.983904,0},{0.772162,0}}" /> </Window> </Window> @@ -220,35 +220,35 @@ <Property name="TabHeight" value="{0,31.1724}" /> <Property name="TabPanePosition" value="Top" /> <Property name="Area" value="{{0.00391872,0},{0.00348824,0},{0.527266,0},{1.00058,0}}" /> - <Window type="DefaultWindow" name="FOTab/Properties" > + <Window type="DefaultWindow" name="Properties" > <Property name="Text" value="Properties" /> <Property name="Visible" value="False" /> <Property name="Area" value="{{-0.00215884,0},{0,0},{0.997841,0},{1,0}}" /> - <Window type="TaharezLook/StaticText" name="FOTab/Prop/ShapeLabel" > + <Window type="TaharezLook/StaticText" name="ShapeLabel" > <Property name="Text" value="Shape:" /> <Property name="HorzExtent" value="42" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.03,0},{0.01,0},{0.347415,0},{0.1,0}}" /> </Window> - <Window type="TaharezLook/RadioButton" name="FOTab/Prop/CircleCheckbox" > + <Window type="TaharezLook/RadioButton" name="CircleCheckbox" > <Property name="Area" value="{{0.03,0},{0.1,0},{0.1,0},{0.15,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="FOTab/Prop/CircleLabel" > + <Window type="TaharezLook/StaticText" name="CircleLabel" > <Property name="Text" value="Circle" /> <Property name="HorzExtent" value="37" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.1,0},{0.1,0},{0.2,0},{0.15,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="FOTab/Prop/RadiusLabel" > + <Window type="TaharezLook/StaticText" name="RadiusLabel" > <Property name="Text" value="Radius:" /> <Property name="HorzExtent" value="42" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.3,0},{0.1,0},{0.4,0},{0.15,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="FOTab/Prop/RadiusSpinner" > + <Window type="TaharezLook/Spinner" name="RadiusSpinner" > <Property name="StepSize" value="0.1" /> <Property name="CurrentValue" value="1" /> <Property name="MaximumValue" value="20" /> @@ -257,28 +257,28 @@ <Property name="Area" value="{{0.42,0},{0.1,0},{0.62,0},{0.15,0}}" /> <Property name="TextParsingEnabled" value="False" /> </Window> - <Window type="TaharezLook/Button" name="FOTab/Prop/DetectCircleButton" > + <Window type="TaharezLook/Button" name="DetectCircleButton" > <Property name="Text" value="Autodetect" /> <Property name="Area" value="{{0.7,0},{0.1,0},{0.92,0},{0.15,0}}" /> </Window> - <Window type="TaharezLook/RadioButton" name="FOTab/Prop/RectangleCheckbox" > + <Window type="TaharezLook/RadioButton" name="RectangleCheckbox" > <Property name="Area" value="{{0.03,0},{0.2,0},{0.1,0},{0.25,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="FOTab/Prop/RectangleLabel" > + <Window type="TaharezLook/StaticText" name="RectangleLabel" > <Property name="Text" value="Rectangle" /> <Property name="HorzExtent" value="63" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.1,0},{0.2,0},{0.2,0},{0.25,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="FOTab/Prop/WidthLabel" > + <Window type="TaharezLook/StaticText" name="WidthLabel" > <Property name="Text" value="Width:" /> <Property name="HorzExtent" value="38" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.3,0},{0.2,0},{0.4,0},{0.25,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="FOTab/Prop/WidthSpinner" > + <Window type="TaharezLook/Spinner" name="WidthSpinner" > <Property name="StepSize" value="0.1" /> <Property name="CurrentValue" value="1" /> <Property name="MaximumValue" value="20" /> @@ -287,14 +287,14 @@ <Property name="Area" value="{{0.42,0},{0.2,0},{0.62,0},{0.25,0}}" /> <Property name="TextParsingEnabled" value="False" /> </Window> - <Window type="TaharezLook/StaticText" name="FOTab/Prop/DepthLabel" > + <Window type="TaharezLook/StaticText" name="DepthLabel" > <Property name="Text" value="Depth:" /> <Property name="HorzExtent" value="42" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.3,0},{0.301493,0},{0.4,0},{0.351493,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="FOTab/Prop/DepthSpinner" > + <Window type="TaharezLook/Spinner" name="DepthSpinner" > <Property name="StepSize" value="0.1" /> <Property name="CurrentValue" value="1" /> <Property name="MaximumValue" value="20" /> @@ -303,100 +303,100 @@ <Property name="Area" value="{{0.42,0},{0.3,0},{0.62,0},{0.35,0}}" /> <Property name="TextParsingEnabled" value="False" /> </Window> - <Window type="TaharezLook/Button" name="FOTab/Prop/DetectRectButton" > + <Window type="TaharezLook/Button" name="DetectRectButton" > <Property name="Text" value="Autodetect" /> <Property name="Area" value="{{0.7,0},{0.3,0},{0.92,0},{0.35,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="FOTab/Prop/CollisionLabel" > + <Window type="TaharezLook/StaticText" name="CollisionLabel" > <Property name="Text" value="Collision type" /> <Property name="HorzExtent" value="85" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.1,0},{0.4,0},{0.4,0},{0.45,0}}" /> </Window> - <Window type="TaharezLook/Combobox" name="FOTab/Prop/LayerSelector" > + <Window type="TaharezLook/Combobox" name="LayerSelector" > <Property name="Area" value="{{0.42,0},{0.4,0},{0.62,0},{0.8,0}}" /> <Property name="MaxTextLength" value="1073741823" /> </Window> - <Window type="TaharezLook/StaticText" name="FOTab/Properties/CopyDataLabel" > + <Window type="TaharezLook/StaticText" name="CopyDataLabel" > <Property name="Text" value="Copy data from:" /> <Property name="HorzExtent" value="100" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.03,0},{0.6,0},{0.3,0},{0.65,0}}" /> </Window> - <Window type="TaharezLook/Combobox" name="FOTab/Properties/CopyDataBox" > + <Window type="TaharezLook/Combobox" name="CopyDataBox" > <Property name="Area" value="{{0.28,0},{0.6,0},{0.65,0},{0.95,0}}" /> <Property name="MaxTextLength" value="1073741823" /> </Window> - <Window type="TaharezLook/Button" name="FOTab/Properties/CopyDataButton" > + <Window type="TaharezLook/Button" name="CopyDataButton" > <Property name="Text" value="Copy" /> <Property name="Area" value="{{0.7,0},{0.6,0},{0.85,0},{0.65,0}}" /> </Window> </Window> - <Window type="DefaultWindow" name="FOTab/Create" > + <Window type="DefaultWindow" name="Create" > <Property name="Text" value="Create Object" /> <Property name="Area" value="{{0,0},{0,0},{1,0},{1,0}}" /> - <Window type="TaharezLook/Button" name="FOTab/XML/CreateButton" > + <Window type="TaharezLook/Button" name="CreateButton" > <Property name="Text" value="Create Object" /> <Property name="Area" value="{{0.0452567,0},{0.320993,0},{0.401039,0},{0.378432,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="FOTab/Create/PosLabel" > + <Window type="TaharezLook/StaticText" name="PosLabel" > <Property name="Text" value="Position:" /> <Property name="HorzExtent" value="53" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.05,0},{0.03,0},{0.22,0},{0.1,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="FOTab/Create/PosXSpinner" > + <Window type="TaharezLook/Spinner" name="PosXSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="32767" /> <Property name="MinimumValue" value="0" /> <Property name="Area" value="{{0.28,0},{0.03,0},{0.54,0},{0.1,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="FOTab/Create/PosYSpinner" > + <Window type="TaharezLook/Spinner" name="PosYSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="32767" /> <Property name="MinimumValue" value="0" /> <Property name="Area" value="{{0.61,0},{0.03,0},{0.88,0},{0.1,0}}" /> </Window> - <Window type="TaharezLook/Button" name="FOTab/Create/GetPlPosButton" > + <Window type="TaharezLook/Button" name="GetPlPosButton" > <Property name="Text" value="Get Player Position" /> <Property name="Area" value="{{0.495761,0},{0.123872,0},{0.858021,0},{0.184297,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="FOTab/Create/AngleLabel" > + <Window type="TaharezLook/StaticText" name="AngleLabel" > <Property name="Text" value="Angle:" /> <Property name="HorzExtent" value="39" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.03,0},{0.2,0},{0.2,0},{0.28,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="FOTab/Create/AngleSpinner" > + <Window type="TaharezLook/Spinner" name="AngleSpinner" > <Property name="StepSize" value="5" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="3600" /> <Property name="MinimumValue" value="-3600" /> <Property name="Area" value="{{0.28,0},{0.2,0},{0.54,0},{0.27,0}}" /> </Window> - <Window type="TaharezLook/Button" name="FOTab/Create/DelAllButton" > + <Window type="TaharezLook/Button" name="DelAllButton" > <Property name="Text" value="Delete all objects" /> <Property name="Area" value="{{0.0552785,0},{0.871688,0},{0.436968,0},{0.94256,0}}" /> </Window> </Window> - <Window type="DefaultWindow" name="FOTab/XML" > + <Window type="DefaultWindow" name="XML" > <Property name="Text" value="XML" /> <Property name="Visible" value="False" /> <Property name="Area" value="{{0,0},{0,0},{1,0},{1,0}}" /> - <Window type="TaharezLook/MultiLineEditbox" name="FOTab/XML/FOXMLEditbox" > + <Window type="TaharezLook/MultiLineEditbox" name="FOXMLEditbox" > <Property name="Text" > </Property> <Property name="MaxTextLength" value="1073741823" /> <Property name="Area" value="{{0.0229259,0},{0.0172008,0},{0.986204,0},{0.901313,0}}" /> <Property name="TextParsingEnabled" value="False" /> </Window> - <Window type="TaharezLook/Button" name="FOTab/XML/SubmitButton" > + <Window type="TaharezLook/Button" name="SubmitButton" > <Property name="Text" value="Submit XML" /> <Property name="Area" value="{{0.0344625,0},{0.919477,0},{0.390245,0},{0.976916,0}}" /> </Window> @@ -411,18 +411,18 @@ <Property name="TabHeight" value="{0,31.1724}" /> <Property name="TabPanePosition" value="Top" /> <Property name="Area" value="{{0.00391872,0},{0.00348824,0},{0.527266,0},{1.00058,0}}" /> - <Window type="DefaultWindow" name="MonsterTab/Properties" > + <Window type="DefaultWindow" name="Properties" > <Property name="Text" value="Properties" /> <Property name="Visible" value="False" /> <Property name="Area" value="{{-0.00215884,0},{0,0},{0.997841,0},{1,0}}" /> - <Window type="TaharezLook/StaticText" name="MonsterTab/Prop/RadiusLabel" > + <Window type="TaharezLook/StaticText" name="RadiusLabel" > <Property name="Text" value="Radius:" /> <Property name="HorzExtent" value="42" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.3,0},{0.1,0},{0.4,0},{0.15,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="MonsterTab/Prop/RadiusSpinner" > + <Window type="TaharezLook/Spinner" name="RadiusSpinner" > <Property name="StepSize" value="0.1" /> <Property name="CurrentValue" value="1" /> <Property name="MaximumValue" value="20" /> @@ -432,85 +432,85 @@ <Property name="TextParsingEnabled" value="False" /> </Window> - <Window type="TaharezLook/StaticText" name="MonsterTab/Properties/CopyDataLabel" > + <Window type="TaharezLook/StaticText" name="CopyDataLabel" > <Property name="Text" value="Copy data from:" /> <Property name="HorzExtent" value="100" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.03,0},{0.6,0},{0.3,0},{0.65,0}}" /> </Window> - <Window type="TaharezLook/Combobox" name="MonsterTab/Properties/CopyDataBox" > + <Window type="TaharezLook/Combobox" name="CopyDataBox" > <Property name="Area" value="{{0.28,0},{0.6,0},{0.65,0},{0.95,0}}" /> <Property name="MaxTextLength" value="1073741823" /> </Window> - <Window type="TaharezLook/Button" name="MonsterTab/Properties/CopyDataButton" > + <Window type="TaharezLook/Button" name="CopyDataButton" > <Property name="Text" value="Copy" /> <Property name="Area" value="{{0.7,0},{0.6,0},{0.85,0},{0.65,0}}" /> </Window> </Window> - <Window type="DefaultWindow" name="MonsterTab/Create" > + <Window type="DefaultWindow" name="Create" > <Property name="Text" value="Create Object" /> <Property name="Area" value="{{0,0},{0,0},{1,0},{1,0}}" /> - <Window type="TaharezLook/Button" name="MonsterTab/XML/CreateButton" > + <Window type="TaharezLook/Button" name="CreateButton" > <Property name="Text" value="Create Object" /> <Property name="Area" value="{{0.0452567,0},{0.320993,0},{0.401039,0},{0.378432,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="MonsterTab/Create/PosLabel" > + <Window type="TaharezLook/StaticText" name="PosLabel" > <Property name="Text" value="Position:" /> <Property name="HorzExtent" value="53" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.05,0},{0.03,0},{0.22,0},{0.1,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="MonsterTab/Create/PosXSpinner" > + <Window type="TaharezLook/Spinner" name="PosXSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="32767" /> <Property name="MinimumValue" value="0" /> <Property name="Area" value="{{0.28,0},{0.03,0},{0.54,0},{0.1,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="MonsterTab/Create/PosYSpinner" > + <Window type="TaharezLook/Spinner" name="PosYSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="32767" /> <Property name="MinimumValue" value="0" /> <Property name="Area" value="{{0.61,0},{0.03,0},{0.88,0},{0.1,0}}" /> </Window> - <Window type="TaharezLook/Button" name="MonsterTab/Create/GetPlPosButton" > + <Window type="TaharezLook/Button" name="GetPlPosButton" > <Property name="Text" value="Get Player Position" /> <Property name="Area" value="{{0.495761,0},{0.123872,0},{0.858021,0},{0.184297,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="MonsterTab/Create/AngleLabel" > + <Window type="TaharezLook/StaticText" name="AngleLabel" > <Property name="Text" value="Angle:" /> <Property name="HorzExtent" value="39" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.03,0},{0.2,0},{0.2,0},{0.28,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="MonsterTab/Create/AngleSpinner" > + <Window type="TaharezLook/Spinner" name="AngleSpinner" > <Property name="StepSize" value="5" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="3600" /> <Property name="MinimumValue" value="-3600" /> <Property name="Area" value="{{0.28,0},{0.2,0},{0.54,0},{0.27,0}}" /> </Window> - <Window type="TaharezLook/Button" name="MonsterTab/Create/DelAllButton" > + <Window type="TaharezLook/Button" name="DelAllButton" > <Property name="Text" value="Delete all objects" /> <Property name="Area" value="{{0.0552785,0},{0.871688,0},{0.436968,0},{0.94256,0}}" /> </Window> </Window> - <Window type="DefaultWindow" name="MonsterTab/XML" > + <Window type="DefaultWindow" name="XML" > <Property name="Text" value="XML" /> <Property name="Visible" value="False" /> <Property name="Area" value="{{0,0},{0,0},{1,0},{1,0}}" /> - <Window type="TaharezLook/MultiLineEditbox" name="MonsterTab/XML/MonsterXMLEditbox" > + <Window type="TaharezLook/MultiLineEditbox" name="MonsterXMLEditbox" > <Property name="Text" > </Property> <Property name="MaxTextLength" value="1073741823" /> <Property name="Area" value="{{0.0229259,0},{0.0172008,0},{0.986204,0},{0.901313,0}}" /> <Property name="TextParsingEnabled" value="False" /> </Window> - <Window type="TaharezLook/Button" name="MonsterTab/XML/SubmitButton" > + <Window type="TaharezLook/Button" name="SubmitButton" > <Property name="Text" value="Submit XML" /> <Property name="Area" value="{{0.0344625,0},{0.919477,0},{0.390245,0},{0.976916,0}}" /> </Window> @@ -524,94 +524,94 @@ <Property name="TabHeight" value="{0,31.1724}" /> <Property name="TabPanePosition" value="Top" /> <Property name="Area" value="{{0.00391872,0},{0.00348824,0},{0.527266,0},{1.00058,0}}" /> - <Window type="DefaultWindow" name="ItemTab/General" > + <Window type="DefaultWindow" name="General" > <Property name="Text" value="General" /> <Property name="Area" value="{{-0.00215884,0},{0,0},{0.997841,0},{1,0}}" /> - <Window type="TaharezLook/StaticText" name="ItemTab/Properties/TypeLabel" > + <Window type="TaharezLook/StaticText" name="TypeLabel" > <Property name="Text" value="Type:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.03,0},{0.09,0},{0.2,0},{0.15,0}}" /> </Window> - <Window type="TaharezLook/Combobox" name="ItemTab/Properties/TypeBox" > + <Window type="TaharezLook/Combobox" name="TypeBox" > <Property name="Area" value="{{0.2,0},{0.1,0},{0.65,0},{0.5,0}}" /> <Property name="MaxTextLength" value="1073741823" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Properties/SizeLabel" > + <Window type="TaharezLook/StaticText" name="SizeLabel" > <Property name="Text" value="Size:" /> <Property name="HorzExtent" value="29" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.03,0},{0.16,0},{0.2,0},{0.24,0}}" /> </Window> - <Window type="TaharezLook/Combobox" name="ItemTab/Properties/SizeBox" > + <Window type="TaharezLook/Combobox" name="SizeBox" > <Property name="Area" value="{{0.2,0},{0.17,0},{0.65,0},{0.65,0}}" /> <Property name="MaxTextLength" value="1073741823" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Properties/CopyDataLabel" > + <Window type="TaharezLook/StaticText" name="CopyDataLabel" > <Property name="Text" value="Copy data from:" /> <Property name="HorzExtent" value="100" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.03,0},{0.6,0},{0.3,0},{0.65,0}}" /> </Window> - <Window type="TaharezLook/Combobox" name="ItemTab/Properties/CopyDataBox" > + <Window type="TaharezLook/Combobox" name="CopyDataBox" > <Property name="Area" value="{{0.28,0},{0.6,0},{0.65,0},{0.95,0}}" /> <Property name="MaxTextLength" value="1073741823" /> </Window> - <Window type="TaharezLook/Button" name="ItemTab/Properties/CopyDataButton" > + <Window type="TaharezLook/Button" name="CopyDataButton" > <Property name="Text" value="Copy" /> <Property name="Area" value="{{0.7,0},{0.6,0},{0.85,0},{0.65,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/General/NameLabel" > + <Window type="TaharezLook/StaticText" name="NameLabel" > <Property name="Text" value="Name:" /> <Property name="HorzExtent" value="41" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.03,0},{0.03,0},{0.2,0},{0.08,0}}" /> </Window> - <Window type="TaharezLook/Editbox" name="ItemTab/General/NameBox" > + <Window type="TaharezLook/Editbox" name="NameBox" > <Property name="MaxTextLength" value="1073741823" /> <Property name="Area" value="{{0.2,0},{0.03,0},{0.65,0},{0.08,0}}" /> <Property name="TextParsingEnabled" value="False" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/General/PriceLabel" > + <Window type="TaharezLook/StaticText" name="PriceLabel" > <Property name="Text" value="Value:" /> <Property name="HorzExtent" value="38" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.03,0},{0.25,0},{0.2,0},{0.3,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/General/PriceSpinner" > + <Window type="TaharezLook/Spinner" name="PriceSpinner" > <Property name="Area" value="{{0.2,0},{0.25,0},{0.65,0},{0.3,0}}" /> <Property name="StepSize" value="50" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="10000" /> <Property name="MinimumValue" value="0" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/General/EnchantRangeLabel" > + <Window type="TaharezLook/StaticText" name="EnchantRangeLabel" > <Property name="Text" value="Enchant min:" /> <Property name="HorzExtent" value="82" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.03,0},{0.34,0},{0.24,0},{0.4,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/General/EnchantMinSpinner" > + <Window type="TaharezLook/Spinner" name="EnchantMinSpinner" > <Property name="StepSize" value="50" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="10000" /> <Property name="MinimumValue" value="0" /> <Property name="Area" value="{{0.24,0},{0.34,0},{0.5,0},{0.4,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/General/EnchantMaxLabel" > + <Window type="TaharezLook/StaticText" name="EnchantMaxLabel" > <Property name="Text" value="max:" /> <Property name="HorzExtent" value="29" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.55,0},{0.34,0},{0.65,0},{0.4,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/General/EnchantMaxSpinner" > + <Window type="TaharezLook/Spinner" name="EnchantMaxSpinner" > <Property name="StepSize" value="50" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="10000" /> @@ -619,14 +619,14 @@ <Property name="Area" value="{{0.65,0},{0.34,0},{0.9,0},{0.4,0}}" /> </Window> </Window> - <Window type="DefaultWindow" name="ItemTab/Equip" > + <Window type="DefaultWindow" name="Equip" > <Property name="Text" >Equip </Property> <Property name="Visible" value="False" /> <Property name="Area" value="{{0,0},{0,0},{1,0},{1,0}}" /> - <Window type="TaharezLook/StaticText" name="ItemTab/Equip/HealthLabel" > + <Window type="TaharezLook/StaticText" name="HealthLabel" > <Property name="Text" value="Health:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -634,7 +634,7 @@ <Property name="Area" value="{{0.03,0},{0.03,0},{0.2,0},{0.08,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Equip/HealthSpinner" > + <Window type="TaharezLook/Spinner" name="HealthSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="10000" /> @@ -642,7 +642,7 @@ <Property name="Area" value="{{0.2,0},{0.03,0},{0.40,0},{0.08,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Equip/AttrLabel" > + <Window type="TaharezLook/StaticText" name="AttrLabel" > <Property name="Text" value="Attribute:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -650,7 +650,7 @@ <Property name="Area" value="{{0.03,0},{0.10,0},{0.2,0},{0.16,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Equip/StrengthLabel" > + <Window type="TaharezLook/StaticText" name="StrengthLabel" > <Property name="Text" value="Strength:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -658,7 +658,7 @@ <Property name="Area" value="{{0.03,0},{0.17,0},{0.2,0},{0.23,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Equip/StrengthSpinner" > + <Window type="TaharezLook/Spinner" name="StrengthSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="1000" /> @@ -666,7 +666,7 @@ <Property name="Area" value="{{0.2,0},{0.17,0},{0.40,0},{0.23,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Equip/DexterityLabel" > + <Window type="TaharezLook/StaticText" name="DexterityLabel" > <Property name="Text" value="Dexterity:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -674,7 +674,7 @@ <Property name="Area" value="{{0.52,0},{0.17,0},{0.7,0},{0.23,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Equip/DexteritySpinner" > + <Window type="TaharezLook/Spinner" name="DexteritySpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="1000" /> @@ -683,7 +683,7 @@ </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Equip/MagicPowerLabel" > + <Window type="TaharezLook/StaticText" name="MagicPowerLabel" > <Property name="Text" value="Magic Power:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -691,7 +691,7 @@ <Property name="Area" value="{{0.03,0},{0.24,0},{0.2,0},{0.30,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Equip/MagicPowerSpinner" > + <Window type="TaharezLook/Spinner" name="MagicPowerSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="1000" /> @@ -699,7 +699,7 @@ <Property name="Area" value="{{0.2,0},{0.24,0},{0.40,0},{0.30,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Equip/WillpowerLabel" > + <Window type="TaharezLook/StaticText" name="WillpowerLabel" > <Property name="Text" value="Willpower:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -707,7 +707,7 @@ <Property name="Area" value="{{0.52,0},{0.24,0},{0.7,0},{0.30,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Equip/WillpowerSpinner" > + <Window type="TaharezLook/Spinner" name="WillpowerSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="1000" /> @@ -716,7 +716,7 @@ </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Equip/ResistancesLabel" > + <Window type="TaharezLook/StaticText" name="ResistancesLabel" > <Property name="Text" value="Resistances:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -724,7 +724,7 @@ <Property name="Area" value="{{0.03,0},{0.32,0},{0.4,0},{0.38,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Equip/PhysResLabel" > + <Window type="TaharezLook/StaticText" name="PhysResLabel" > <Property name="Text" value="Physical:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -732,7 +732,7 @@ <Property name="Area" value="{{0.03,0},{0.39,0},{0.2,0},{0.45,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Equip/PhysResSpinner" > + <Window type="TaharezLook/Spinner" name="PhysResSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="100" /> @@ -740,7 +740,7 @@ <Property name="Area" value="{{0.2,0},{0.39,0},{0.40,0},{0.45,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Equip/FireResLabel" > + <Window type="TaharezLook/StaticText" name="FireResLabel" > <Property name="Text" value="Fire:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -748,7 +748,7 @@ <Property name="Area" value="{{0.52,0},{0.39,0},{0.7,0},{0.45,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Equip/FireResSpinner" > + <Window type="TaharezLook/Spinner" name="FireResSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="100" /> @@ -756,7 +756,7 @@ <Property name="Area" value="{{0.7,0},{0.39,0},{0.90,0},{0.45,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Equip/IceResLabel" > + <Window type="TaharezLook/StaticText" name="IceResLabel" > <Property name="Text" value="Ice:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -764,7 +764,7 @@ <Property name="Area" value="{{0.03,0},{0.46,0},{0.2,0},{0.52,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Equip/IceResSpinner" > + <Window type="TaharezLook/Spinner" name="IceResSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="100" /> @@ -772,7 +772,7 @@ <Property name="Area" value="{{0.2,0},{0.46,0},{0.40,0},{0.52,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Equip/AirResLabel" > + <Window type="TaharezLook/StaticText" name="AirResLabel" > <Property name="Text" value="Air:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -780,7 +780,7 @@ <Property name="Area" value="{{0.52,0},{0.46,0},{0.7,0},{0.52,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Equip/AirResSpinner" > + <Window type="TaharezLook/Spinner" name="AirResSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="100" /> @@ -788,7 +788,7 @@ <Property name="Area" value="{{0.7,0},{0.46,0},{0.90,0},{0.52,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Equip/OtherLabel" > + <Window type="TaharezLook/StaticText" name="OtherLabel" > <Property name="Text" value="Other:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -796,7 +796,7 @@ <Property name="Area" value="{{0.03,0},{0.54,0},{0.2,0},{0.60,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Equip/ArmorLabel" > + <Window type="TaharezLook/StaticText" name="ArmorLabel" > <Property name="Text" value="Armor:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -804,7 +804,7 @@ <Property name="Area" value="{{0.03,0},{0.61,0},{0.2,0},{0.67,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Equip/ArmorSpinner" > + <Window type="TaharezLook/Spinner" name="ArmorSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="1000" /> @@ -812,7 +812,7 @@ <Property name="Area" value="{{0.2,0},{0.61,0},{0.40,0},{0.67,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Equip/BlockLabel" > + <Window type="TaharezLook/StaticText" name="BlockLabel" > <Property name="Text" value="Block:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -820,7 +820,7 @@ <Property name="Area" value="{{0.52,0},{0.61,0},{0.7,0},{0.67,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Equip/BlockSpinner" > + <Window type="TaharezLook/Spinner" name="BlockSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="1000" /> @@ -828,7 +828,7 @@ <Property name="Area" value="{{0.7,0},{0.61,0},{0.90,0},{0.67,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Equip/AttackLabel" > + <Window type="TaharezLook/StaticText" name="AttackLabel" > <Property name="Text" value="Precision:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -836,7 +836,7 @@ <Property name="Area" value="{{0.03,0},{0.68,0},{0.2,0},{0.74,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Equip/AttackSpinner" > + <Window type="TaharezLook/Spinner" name="AttackSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="1000" /> @@ -844,7 +844,7 @@ <Property name="Area" value="{{0.2,0},{0.68,0},{0.40,0},{0.74,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Equip/PowerLabel" > + <Window type="TaharezLook/StaticText" name="PowerLabel" > <Property name="Text" value="Power:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -852,7 +852,7 @@ <Property name="Area" value="{{0.52,0},{0.68,0},{0.7,0},{0.74,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Equip/PowerSpinner" > + <Window type="TaharezLook/Spinner" name="PowerSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="1000" /> @@ -861,13 +861,13 @@ </Window> </Window> - <Window type="DefaultWindow" name="ItemTab/Weapon" > + <Window type="DefaultWindow" name="Weapon" > <Property name="Text" >Weapon </Property> <Property name="Visible" value="False" /> <Property name="Area" value="{{0,0},{0,0},{1,0},{1,0}}" /> - <Window type="TaharezLook/StaticText" name="ItemTab/Weapon/TypeLabel" > + <Window type="TaharezLook/StaticText" name="TypeLabel" > <Property name="Text" value="Type:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -875,13 +875,13 @@ <Property name="Area" value="{{0.03,0},{0.03,0},{0.2,0},{0.08,0}}" /> </Window> - <Window type="TaharezLook/Editbox" name="ItemTab/Weapon/TypeBox" > + <Window type="TaharezLook/Editbox" name="TypeBox" > <Property name="MaxTextLength" value="1073741823" /> <Property name="Area" value="{{0.2,0},{0.03,0},{0.65,0},{0.08,0}}" /> <Property name="TextParsingEnabled" value="False" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Weapon/DamageLabel" > + <Window type="TaharezLook/StaticText" name="DamageLabel" > <Property name="Text" value="Damage:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -889,7 +889,7 @@ <Property name="Area" value="{{0.03,0},{0.10,0},{0.2,0},{0.16,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Weapon/PhysLabel" > + <Window type="TaharezLook/StaticText" name="PhysLabel" > <Property name="Text" value="Physical:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -897,7 +897,7 @@ <Property name="Area" value="{{0.03,0},{0.17,0},{0.2,0},{0.23,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Weapon/PhysMinSpinner" > + <Window type="TaharezLook/Spinner" name="PhysMinSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="32767" /> @@ -905,7 +905,7 @@ <Property name="Area" value="{{0.22,0},{0.17,0},{0.42,0},{0.23,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Weapon/PhysToLabel" > + <Window type="TaharezLook/StaticText" name="PhysToLabel" > <Property name="Text" value="-" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -913,7 +913,7 @@ <Property name="Area" value="{{0.44,0},{0.17,0},{0.48,0},{0.23,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Weapon/PhysMaxSpinner" > + <Window type="TaharezLook/Spinner" name="PhysMaxSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="32767" /> @@ -921,7 +921,7 @@ <Property name="Area" value="{{0.48,0},{0.17,0},{0.68,0},{0.23,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Weapon/PhysMultLabel" > + <Window type="TaharezLook/StaticText" name="PhysMultLabel" > <Property name="Text" value="x" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -929,7 +929,7 @@ <Property name="Area" value="{{0.75,0},{0.17,0},{0.78,0},{0.23,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Weapon/PhysMultSpinner" > + <Window type="TaharezLook/Spinner" name="PhysMultSpinner" > <Property name="StepSize" value="0.1" /> <Property name="CurrentValue" value="1" /> <Property name="MaximumValue" value="32767" /> @@ -938,7 +938,7 @@ <Property name="Area" value="{{0.78,0},{0.17,0},{0.98,0},{0.23,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Weapon/FireLabel" > + <Window type="TaharezLook/StaticText" name="FireLabel" > <Property name="Text" value="Fire:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -946,7 +946,7 @@ <Property name="Area" value="{{0.03,0},{0.24,0},{0.2,0},{0.30,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Weapon/FireMinSpinner" > + <Window type="TaharezLook/Spinner" name="FireMinSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="32767" /> @@ -954,7 +954,7 @@ <Property name="Area" value="{{0.22,0},{0.24,0},{0.42,0},{0.30,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Weapon/FireToLabel" > + <Window type="TaharezLook/StaticText" name="FireToLabel" > <Property name="Text" value="-" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -962,7 +962,7 @@ <Property name="Area" value="{{0.44,0},{0.24,0},{0.48,0},{0.30,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Weapon/FireMaxSpinner" > + <Window type="TaharezLook/Spinner" name="FireMaxSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="32767" /> @@ -970,7 +970,7 @@ <Property name="Area" value="{{0.48,0},{0.24,0},{0.68,0},{0.30,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Weapon/FireMultLabel" > + <Window type="TaharezLook/StaticText" name="FireMultLabel" > <Property name="Text" value="x" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -978,7 +978,7 @@ <Property name="Area" value="{{0.75,0},{0.24,0},{0.78,0},{0.30,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Weapon/FireMultSpinner" > + <Window type="TaharezLook/Spinner" name="FireMultSpinner" > <Property name="StepSize" value="0.1" /> <Property name="CurrentValue" value="1" /> <Property name="MaximumValue" value="32767" /> @@ -987,7 +987,7 @@ <Property name="Area" value="{{0.78,0},{0.24,0},{0.98,0},{0.30,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Weapon/IceLabel" > + <Window type="TaharezLook/StaticText" name="IceLabel" > <Property name="Text" value="Ice:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -995,7 +995,7 @@ <Property name="Area" value="{{0.03,0},{0.31,0},{0.2,0},{0.37,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Weapon/IceMinSpinner" > + <Window type="TaharezLook/Spinner" name="IceMinSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="32767" /> @@ -1003,7 +1003,7 @@ <Property name="Area" value="{{0.22,0},{0.31,0},{0.42,0},{0.37,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Weapon/IceToLabel" > + <Window type="TaharezLook/StaticText" name="IceToLabel" > <Property name="Text" value="-" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -1011,7 +1011,7 @@ <Property name="Area" value="{{0.44,0},{0.31,0},{0.48,0},{0.37,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Weapon/IceMaxSpinner" > + <Window type="TaharezLook/Spinner" name="IceMaxSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="32767" /> @@ -1019,7 +1019,7 @@ <Property name="Area" value="{{0.48,0},{0.31,0},{0.68,0},{0.37,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Weapon/IceMultLabel" > + <Window type="TaharezLook/StaticText" name="IceMultLabel" > <Property name="Text" value="x" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -1027,7 +1027,7 @@ <Property name="Area" value="{{0.75,0},{0.31,0},{0.78,0},{0.37,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Weapon/IceMultSpinner" > + <Window type="TaharezLook/Spinner" name="IceMultSpinner" > <Property name="StepSize" value="0.1" /> <Property name="CurrentValue" value="1" /> <Property name="MaximumValue" value="32767" /> @@ -1037,7 +1037,7 @@ </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Weapon/AirLabel" > + <Window type="TaharezLook/StaticText" name="AirLabel" > <Property name="Text" value="Air:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -1045,7 +1045,7 @@ <Property name="Area" value="{{0.03,0},{0.38,0},{0.2,0},{0.44,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Weapon/AirMinSpinner" > + <Window type="TaharezLook/Spinner" name="AirMinSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="32767" /> @@ -1053,7 +1053,7 @@ <Property name="Area" value="{{0.22,0},{0.38,0},{0.42,0},{0.44,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Weapon/AirToLabel" > + <Window type="TaharezLook/StaticText" name="AirToLabel" > <Property name="Text" value="-" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -1061,7 +1061,7 @@ <Property name="Area" value="{{0.44,0},{0.38,0},{0.48,0},{0.44,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Weapon/AirMaxSpinner" > + <Window type="TaharezLook/Spinner" name="AirMaxSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="32767" /> @@ -1069,7 +1069,7 @@ <Property name="Area" value="{{0.48,0},{0.38,0},{0.68,0},{0.44,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Weapon/AirMultLabel" > + <Window type="TaharezLook/StaticText" name="AirMultLabel" > <Property name="Text" value="x" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -1077,7 +1077,7 @@ <Property name="Area" value="{{0.75,0},{0.38,0},{0.78,0},{0.44,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Weapon/AirMultSpinner" > + <Window type="TaharezLook/Spinner" name="AirMultSpinner" > <Property name="StepSize" value="0.1" /> <Property name="CurrentValue" value="1" /> <Property name="MaximumValue" value="32767" /> @@ -1086,7 +1086,7 @@ <Property name="Area" value="{{0.78,0},{0.38,0},{0.98,0},{0.44,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Weapon/PrecisionLabel" > + <Window type="TaharezLook/StaticText" name="PrecisionLabel" > <Property name="Text" value="Precision:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -1094,7 +1094,7 @@ <Property name="Area" value="{{0.03,0},{0.47,0},{0.2,0},{0.53,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Weapon/PrecisionSpinner" > + <Window type="TaharezLook/Spinner" name="PrecisionSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="1" /> <Property name="MaximumValue" value="32767" /> @@ -1102,7 +1102,7 @@ <Property name="Area" value="{{0.20,0},{0.47,0},{0.40,0},{0.53,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Weapon/PowerLabel" > + <Window type="TaharezLook/StaticText" name="PowerLabel" > <Property name="Text" value="Power:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -1110,7 +1110,7 @@ <Property name="Area" value="{{0.53,0},{0.47,0},{0.7,0},{0.53,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Weapon/PowerSpinner" > + <Window type="TaharezLook/Spinner" name="PowerSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="1" /> <Property name="MaximumValue" value="32767" /> @@ -1119,7 +1119,7 @@ </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Weapon/RangeLabel" > + <Window type="TaharezLook/StaticText" name="RangeLabel" > <Property name="Text" value="Range:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -1127,7 +1127,7 @@ <Property name="Area" value="{{0.03,0},{0.54,0},{0.2,0},{0.60,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Weapon/RangeSpinner" > + <Window type="TaharezLook/Spinner" name="RangeSpinner" > <Property name="StepSize" value="0.1" /> <Property name="CurrentValue" value="1" /> <Property name="MaximumValue" value="50" /> @@ -1136,7 +1136,7 @@ <Property name="Area" value="{{0.20,0},{0.54,0},{0.40,0},{0.60,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Weapon/SpeedLabel" > + <Window type="TaharezLook/StaticText" name="SpeedLabel" > <Property name="Text" value="Speed:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -1144,7 +1144,7 @@ <Property name="Area" value="{{0.53,0},{0.54,0},{0.7,0},{0.60,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Weapon/SpeedSpinner" > + <Window type="TaharezLook/Spinner" name="SpeedSpinner" > <Property name="StepSize" value="50" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="5000" /> @@ -1153,11 +1153,11 @@ </Window> - <Window type="TaharezLook/Checkbox" name="ItemTab/Weapon/TwohandedCheckbox" > + <Window type="TaharezLook/Checkbox" name="TwohandedCheckbox" > <Property name="Area" value="{{0.03,0},{0.62,0},{0.07,0},{0.66,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Weapon/TwohandedLabel" > + <Window type="TaharezLook/StaticText" name="TwohandedLabel" > <Property name="Text" value="Twohanded weapon" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -1166,7 +1166,7 @@ </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Weapon/CritPercentLabel" > + <Window type="TaharezLook/StaticText" name="CritPercentLabel" > <Property name="Text" value="Crit. Hits:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -1174,7 +1174,7 @@ <Property name="Area" value="{{0.03,0},{0.68,0},{0.2,0},{0.74,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Weapon/CritPercentSpinner" > + <Window type="TaharezLook/Spinner" name="CritPercentSpinner" > <Property name="StepSize" value="1" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="100" /> @@ -1184,12 +1184,12 @@ </Window> - <Window type="DefaultWindow" name="ItemTab/Consume" > + <Window type="DefaultWindow" name="Consume" > <Property name="Text" >Consume</Property> <Property name="Visible" value="False" /> <Property name="Area" value="{{0,0},{0,0},{1,0},{1,0}}" /> - <Window type="TaharezLook/StaticText" name="ItemTab/Consume/TypeLabel" > + <Window type="TaharezLook/StaticText" name="TypeLabel" > <Property name="Text" value="Health:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -1197,7 +1197,7 @@ <Property name="Area" value="{{0.03,0},{0.03,0},{0.2,0},{0.08,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Consume/HealthSpinner" > + <Window type="TaharezLook/Spinner" name="HealthSpinner" > <Property name="StepSize" value="50" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="10000" /> @@ -1206,7 +1206,7 @@ </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Consume/CureLabel" > + <Window type="TaharezLook/StaticText" name="CureLabel" > <Property name="Text" value="Status heal and immunity time:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -1214,7 +1214,7 @@ <Property name="Area" value="{{0.03,0},{0.10,0},{0.7,0},{0.16,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Consume/BlindLabel" > + <Window type="TaharezLook/StaticText" name="BlindLabel" > <Property name="Text" value="Blind:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -1222,7 +1222,7 @@ <Property name="Area" value="{{0.03,0},{0.17,0},{0.2,0},{0.23,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Consume/BlindSpinner" > + <Window type="TaharezLook/Spinner" name="BlindSpinner" > <Property name="StepSize" value="1000" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="1000000" /> @@ -1230,7 +1230,7 @@ <Property name="Area" value="{{0.20,0},{0.17,0},{0.40,0},{0.23,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Consume/PoisonedLabel" > + <Window type="TaharezLook/StaticText" name="PoisonedLabel" > <Property name="Text" value="Poisoned:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -1238,7 +1238,7 @@ <Property name="Area" value="{{0.52,0},{0.17,0},{0.7,0},{0.23,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Consume/PoisonedSpinner" > + <Window type="TaharezLook/Spinner" name="PoisonedSpinner" > <Property name="StepSize" value="1000" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="1000000" /> @@ -1247,7 +1247,7 @@ </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Consume/BerserkLabel" > + <Window type="TaharezLook/StaticText" name="BerserkLabel" > <Property name="Text" value="Berserk:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -1255,7 +1255,7 @@ <Property name="Area" value="{{0.03,0},{0.24,0},{0.2,0},{0.30,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Consume/BerserkSpinner" > + <Window type="TaharezLook/Spinner" name="BerserkSpinner" > <Property name="StepSize" value="1000" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="1000000" /> @@ -1263,7 +1263,7 @@ <Property name="Area" value="{{0.20,0},{0.24,0},{0.40,0},{0.30,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Consume/ConfusedLabel" > + <Window type="TaharezLook/StaticText" name="ConfusedLabel" > <Property name="Text" value="Confused:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -1271,7 +1271,7 @@ <Property name="Area" value="{{0.52,0},{0.24,0},{0.7,0},{0.30,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Consume/ConfusedSpinner" > + <Window type="TaharezLook/Spinner" name="ConfusedSpinner" > <Property name="StepSize" value="1000" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="1000000" /> @@ -1280,7 +1280,7 @@ </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Consume/MuteLabel" > + <Window type="TaharezLook/StaticText" name="MuteLabel" > <Property name="Text" value="Mute:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -1288,7 +1288,7 @@ <Property name="Area" value="{{0.03,0},{0.31,0},{0.2,0},{0.37,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Consume/MuteSpinner" > + <Window type="TaharezLook/Spinner" name="MuteSpinner" > <Property name="StepSize" value="1000" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="1000000" /> @@ -1296,7 +1296,7 @@ <Property name="Area" value="{{0.20,0},{0.31,0},{0.40,0},{0.37,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Consume/ParalyzedLabel" > + <Window type="TaharezLook/StaticText" name="ParalyzedLabel" > <Property name="Text" value="Paralyzed:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -1304,7 +1304,7 @@ <Property name="Area" value="{{0.52,0},{0.31,0},{0.7,0},{0.37,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Consume/ParalyzedSpinner" > + <Window type="TaharezLook/Spinner" name="ParalyzedSpinner" > <Property name="StepSize" value="1000" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="1000000" /> @@ -1313,7 +1313,7 @@ </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Consume/FrozenLabel" > + <Window type="TaharezLook/StaticText" name="FrozenLabel" > <Property name="Text" value="Frozen:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -1321,7 +1321,7 @@ <Property name="Area" value="{{0.03,0},{0.38,0},{0.2,0},{0.44,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Consume/FrozenSpinner" > + <Window type="TaharezLook/Spinner" name="FrozenSpinner" > <Property name="StepSize" value="1000" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="1000000" /> @@ -1329,7 +1329,7 @@ <Property name="Area" value="{{0.20,0},{0.38,0},{0.40,0},{0.44,0}}" /> </Window> - <Window type="TaharezLook/StaticText" name="ItemTab/Consume/BurningLabel" > + <Window type="TaharezLook/StaticText" name="BurningLabel" > <Property name="Text" value="Burning:" /> <Property name="HorzExtent" value="36" /> <Property name="VertExtent" value="15.5148" /> @@ -1337,7 +1337,7 @@ <Property name="Area" value="{{0.52,0},{0.38,0},{0.7,0},{0.44,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Consume/BurningSpinner" > + <Window type="TaharezLook/Spinner" name="BurningSpinner" > <Property name="StepSize" value="1000" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="1000000" /> @@ -1345,58 +1345,58 @@ <Property name="Area" value="{{0.70,0},{0.38,0},{0.90,0},{0.44,0}}" /> </Window> </Window> - <Window type="DefaultWindow" name="ItemTab/Create" > + <Window type="DefaultWindow" name="Create" > <Property name="Text" value="Create Item" /> <Property name="Visible" value="False" /> <Property name="Area" value="{{0,0},{0,0},{1,0},{1,0}}" /> - <Window type="TaharezLook/StaticText" name="ItemTab/Create/EnchantLabel" > + <Window type="TaharezLook/StaticText" name="EnchantLabel" > <Property name="Text" value="Enchant:" /> <Property name="HorzExtent" value="55" /> <Property name="VertExtent" value="15.5148" /> <Property name="FrameEnabled" value="False" /> <Property name="Area" value="{{0.03,0},{0.03,0},{0.2,0},{0.1,0}}" /> </Window> - <Window type="TaharezLook/Spinner" name="ItemTab/Create/EnchantSpinner" > + <Window type="TaharezLook/Spinner" name="EnchantSpinner" > <Property name="StepSize" value="50" /> <Property name="CurrentValue" value="0" /> <Property name="MaximumValue" value="10000" /> <Property name="MinimumValue" value="0" /> <Property name="Area" value="{{0.2,0},{0.03,0},{0.5,0},{0.1,0}}" /> </Window> - <Window type="TaharezLook/Button" name="ItemTab/Create/CreateInventoryButton" > + <Window type="TaharezLook/Button" name="CreateInventoryButton" > <Property name="Text" value="Create in inventory" /> <Property name="Area" value="{{0.03,0},{0.2,0},{0.4,0},{0.26,0}}" /> </Window> - <Window type="TaharezLook/Button" name="ItemTab/Create/CreateDropButton" > + <Window type="TaharezLook/Button" name="CreateDropButton" > <Property name="Text" value="Create an drop" /> <Property name="Area" value="{{0.5,0},{0.2,0},{0.9,0},{0.26,0}}" /> </Window> </Window> - <Window type="DefaultWindow" name="ItemTab/XML" > + <Window type="DefaultWindow" name="XML" > <Property name="Text" value="XML" /> <Property name="Visible" value="False" /> <Property name="Area" value="{{0,0},{0,0},{1,0},{1,0}}" /> - <Window type="TaharezLook/MultiLineEditbox" name="ItemTab/XML/ItemXMLEditbox" > + <Window type="TaharezLook/MultiLineEditbox" name="ItemXMLEditbox" > <Property name="Text" > </Property> <Property name="MaxTextLength" value="1073741823" /> <Property name="Area" value="{{0.0229259,0},{0.0172008,0},{0.986204,0},{0.901313,0}}" /> <Property name="TextParsingEnabled" value="False" /> </Window> - <Window type="TaharezLook/Button" name="ItemTab/XML/SubmitButton" > + <Window type="TaharezLook/Button" name="SubmitButton" > <Property name="Text" value="Submit XML" /> <Property name="Area" value="{{0.0344625,0},{0.919477,0},{0.390245,0},{0.976916,0}}" /> </Window> </Window> </Window> - <Window type="TaharezLook/StaticImage" name="ItemTab/BM/itemPreview" > + <Window type="TaharezLook/StaticImage" name="itemPreview" > <Property name="Area" value="{{0.535738,0},{0.0565595,0},{0.983904,0},{0.772162,0}}" /> </Window> </Window> <Window type="DefaultWindow" name="GameInfoTab" > <Property name="Text" value="Info" /> <Property name="Area" value="{{0,0},{0,0},{1,0},{1,0}}" /> - <Window type="TaharezLook/MultiLineEditbox" name="GameInfoTab/TextBox" > + <Window type="TaharezLook/MultiLineEditbox" name="TextBox" > <Property name="Text" ></Property> <Property name="MaxTextLength" value="1073741823" /> <Property name="Area" value="{{0.0229259,0},{0.0172008,0},{0.986204,0},{0.901313,0}}" />
--- a/share/resources/gui_0.8/layouts/luascripttab.layout Sun Mar 23 21:04:27 2014 +0100 +++ b/share/resources/gui_0.8/layouts/luascripttab.layout Wed Mar 26 23:39:02 2014 +0200 @@ -1,5 +1,3 @@ - - <GUILayout version="4" > <Window type="TaharezLook/FrameWindow" name="luaScriptTab" > <Property name="Alpha" value="0.1" /> @@ -9,23 +7,23 @@ <Property name="TitlebarEnabled" value="False" /> <Property name="Area" value="{{0.0725001,0},{0.0133335,0},{0.928755,0},{0.936666,0}}" /> <Property name="CloseButtonEnabled" value="False" /> - <Window type="TaharezLook/Button" name="luaScriptTab/ExecuteScriptButton" > + <Window type="TaharezLook/Button" name="ExecuteScriptButton" > <Property name="Text" value="Execute" /> <Property name="InheritsAlpha" value="False" /> <Property name="Area" value="{{0.00365257,0},{0.900724,0},{0.270077,0},{0.988268,0}}" /> </Window> - <Window type="TaharezLook/Menubar" name="luaScriptTab/MenuBar" > + <Window type="TaharezLook/Menubar" name="MenuBar" > <Property name="ItemSpacing" value="10" /> <Property name="InheritsAlpha" value="False" /> <Property name="Area" value="{{0.00711788,0},{0.0104692,0},{0.992602,0},{0.070938,0}}" /> </Window> - <Window type="TaharezLook/TabControl" name="luaScriptTab/FileTabControl" > + <Window type="TaharezLook/TabControl" name="FileTabControl" > <Property name="TabHeight" value="{0,38}" /> <Property name="InheritsAlpha" value="False" /> <Property name="TabPanePosition" value="Top" /> <Property name="Area" value="{{0.00903386,0},{0.0826716,0},{0.992288,0},{0.892241,0}}" /> </Window> - <Window type="TaharezLook/Editbox" name="luaScriptTab/fileDirectoryEditBox" > + <Window type="TaharezLook/Editbox" name="FileDirectoryEditBox" > <Property name="InheritsAlpha" value="False" /> <Property name="MaxTextLength" value="1073741823" /> <Property name="Area" value="{{0.27833,0},{0.898973,0},{0.990234,0},{0.98666,0}}" />
--- a/src/gui/contenteditor/contenteditor.cpp Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/contenteditor/contenteditor.cpp Wed Mar 26 23:39:02 2014 +0200 @@ -13,12 +13,20 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ +// Utility for CEGUI cross-version compatibility +#include "ceguiutility.h" + #include "contenteditor.h" #include "OgreRoot.h" #include "debug.h" #include "config.h" +#ifdef CEGUI_07 #include "CEGUI/RendererModules/Ogre/CEGUIOgreRenderer.h" +#else +#include "CEGUI/RendererModules/Ogre/Renderer.h" +#endif + #include <OgreHardwarePixelBuffer.h> #include <OgreMeshManager.h> #include <OISMouse.h> @@ -44,26 +52,45 @@ //CEGUI::System* guiSystem = System::getSingletonPtr(); CEGUI::WindowManager* winManager = WindowManager::getSingletonPtr(); - CEGUI::Window* gameScreen = winManager->getWindow("GameScreen"); + CEGUI::Window* gameScreen = CEGUIUtility::getWindow("GameScreen"); m_lastVisibilitySwitch = 0; m_rootWindow = winManager->createWindow("TaharezLook/FrameWindow", "ContentEditor"); m_rootWindow->setPosition(UVector2(UDim(0.025f, 0.0f), UDim(0.025f, 0.0f))); - m_rootWindow->setSize(UVector2(UDim(0.9f, 0.0f), UDim(0.85f, 0.0f))); + CEGUIUtility::setWidgetSizeRel(m_rootWindow, 0.9f, 0.85f); m_rootWindow->setText((CEGUI::utf8*)"Content Editor"); - gameScreen->addChildWindow(m_rootWindow); + CEGUIUtility::addChildWidget (gameScreen, m_rootWindow); CEGUI::Window* rootWindow; - rootWindow = CEGUI::WindowManager::getSingleton().loadWindowLayout("contenteditor.layout"); + rootWindow = CEGUIUtility::loadLayoutFromFile ("contenteditor.layout"); rootWindow->setPosition(UVector2(UDim(0.0f, 0.0f), UDim(0.0f, 0.0f))); - rootWindow->setSize(UVector2(UDim(1.0f, 0.0f), UDim(1.0f, 0.0f))); - m_rootWindow->addChildWindow(rootWindow); + CEGUIUtility::setWidgetSizeRel(rootWindow, 1.0f, 1.0f); + CEGUIUtility::addChildWidget (m_rootWindow, rootWindow); // initialisation of the selected tabs for more intuitive use - static_cast<CEGUI::TabControl*>(win_mgr.getWindow("ObjectInfoTabControl"))->setSelectedTab("RenderInfoTab"); - static_cast<CEGUI::TabControl*>(win_mgr.getWindow("RenderInfoTabControl"))->setSelectedTab("RITab/BasicMesh"); - static_cast<CEGUI::TabControl*>(win_mgr.getWindow("FixedObjectTabControl"))->setSelectedTab("FOTab/Properties"); - static_cast<CEGUI::TabControl*>(win_mgr.getWindow("MonsterTabControl"))->setSelectedTab("MonsterTab/Properties"); + CEGUI::TabControl* widget = static_cast<CEGUI::TabControl*>(CEGUIUtility::getWindow("ObjectInfoTabControl")); + if (widget) + { + widget->setSelectedTab("RenderInfoTab"); + } + + widget = static_cast<CEGUI::TabControl*>(CEGUIUtility::getWindow("RenderInfoTabControl")); + if (widget) + { + widget->setSelectedTab("RITab/BasicMesh"); + } + + widget = static_cast<CEGUI::TabControl*>(CEGUIUtility::getWindow("FixedObjectTabControl")); + if (widget) + { + widget->setSelectedTab("FOTab/Properties"); + } + + widget = static_cast<CEGUI::TabControl*>(CEGUIUtility::getWindow("MonsterTabControl")); + if (widget) + { + widget->setSelectedTab("MonsterTab/Properties"); + } // create SceneManager for renderering images for the content editor Ogre::SceneManager* editor_scene_mng = Ogre::Root::getSingleton().createSceneManager(Ogre::ST_GENERIC,"EditorSceneManager"); @@ -96,25 +123,49 @@ editor_view->setBackgroundColour(Ogre::ColourValue(0,0,0,1.0) ); editor_rt->update(); + // get the OgreRenderer from CEGUI and create a CEGUI texture from the Ogre texture + CEGUI::OgreRenderer* renderer_ptr = static_cast<CEGUI::OgreRenderer*>(CEGUI::System::getSingleton().getRenderer()); + CEGUI::String imageName("editor_img"); + +#ifdef CEGUI_07 // create a CEGUI Image from the Texture - CEGUI::Texture& editor_ceguiTex = static_cast<CEGUI::OgreRenderer*>(CEGUI::System::getSingleton().getRenderer())->createTexture(editor_texture); + CEGUI::Texture& editor_ceguiTex = renderer_ptr->createTexture(editor_texture); CEGUI::Imageset& editor_textureImageSet = CEGUI::ImagesetManager::getSingleton().create("editor_imageset", editor_ceguiTex); - editor_textureImageSet.defineImage( "editor_img", + editor_textureImageSet.defineImage( + imageName, CEGUI::Point( 0.0f, 0.0f ), CEGUI::Size( editor_ceguiTex.getSize().d_width, editor_ceguiTex.getSize().d_height ), CEGUI::Point( 0.0f, 0.0f ) ); - +#else + CEGUI::Texture &editor_cegui_texture = renderer_ptr->createTexture (editor_texture->getName (), editor_texture); + { + CEGUI::TextureTarget* d_textureTarget; + CEGUI::BasicImage* d_textureTargetImage; + d_textureTarget = renderer_ptr->createTextureTarget(); + d_textureTargetImage = static_cast<CEGUI::BasicImage*>(&CEGUI::ImageManager::getSingleton().create("BasicImage", imageName)); + d_textureTargetImage->setTexture(&editor_cegui_texture); + d_textureTargetImage->setArea( + CEGUI::Rectf( + 0, + 0, + editor_cegui_texture.getSize ().d_width, + editor_cegui_texture.getSize ().d_height)); + } +#endif + // place the image in a the CEGUI label - CEGUI::Window* label = win_mgr.getWindow("RITab/BM/meshPreview"); - label->setProperty("Image", "set:editor_imageset image:editor_img"); + CEGUI::Window* label = CEGUIUtility::getWindow("RITab/BM/meshPreview"); + + CEGUI::String content_editor_image_name(CEGUIUtility::getImageNameWithSkin("editor_tex", "editor_img")); + label->setProperty("Image", content_editor_image_name); // prev: "set:editor_imageset image:editor_img" label->subscribeEvent(CEGUI::Window::EventMouseButtonDown, CEGUI::Event::Subscriber(&ContentEditor::onPreviewWindowMouseDown, this)); - label->subscribeEvent(CEGUI::Window::EventMouseLeaves, CEGUI::Event::Subscriber(&ContentEditor::onPreviewWindowMouseUp, this)); + label->subscribeEvent(CEGUIUtility::EventMouseLeavesWindowArea(), CEGUI::Event::Subscriber(&ContentEditor::onPreviewWindowMouseUp, this)); label->subscribeEvent(CEGUI::Window::EventMouseButtonUp, CEGUI::Event::Subscriber(&ContentEditor::onPreviewWindowMouseUp, this)); label->subscribeEvent(CEGUI::Window::EventMouseWheel, CEGUI::Event::Subscriber(&ContentEditor::onPreviewWindowScrollWheel, this)); - CEGUI::PushButton* closebutton = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("CloseButton")); + CEGUI::PushButton* closebutton = static_cast<CEGUI::PushButton*>(CEGUIUtility::getWindow("CloseButton")); closebutton->subscribeEvent(CEGUI::PushButton::EventClicked, CEGUI::Event::Subscriber(&ContentEditor::onClose, this)); closebutton = static_cast<CEGUI::FrameWindow*>(m_rootWindow)->getCloseButton(); @@ -124,7 +175,7 @@ m_components["RIEditor"] = new RenderInfoEditor(); m_components["ItemEditor"] = new ItemEditor(); m_components["MonsterEditor"] = new MonsterEditor(); - m_components["GameInfoTab"] = new GameInfoTab(); + m_components["GameInfoTab"] = new GameInfoTab(); std::map<std::string, ContentEditorTab*>::iterator it; for (it = m_components.begin(); it != m_components.end(); ++it) @@ -133,7 +184,9 @@ } if(!visible) + { m_rootWindow->setVisible(visible); + } updateTranslation(); } @@ -201,316 +254,316 @@ textdomain("tools"); - label = win_mgr.getWindow("RenderInfoTab"); + label = CEGUIUtility::getWindow("RenderInfoTab"); label->setText((CEGUI::utf8*) gettext("Render Info")); - label = win_mgr.getWindow("RITab/BasicMesh"); + label = CEGUIUtility::getWindow("RITab/BasicMesh"); label->setText((CEGUI::utf8*) gettext("Mesh")); - label = win_mgr.getWindow("RITab/BM/MainMeshLabel"); + label = CEGUIUtility::getWindow("RITab/BM/MainMeshLabel"); label->setText((CEGUI::utf8*) gettext("Select main mesh:")); - label = win_mgr.getWindow("RITab/SubMesh"); + label = CEGUIUtility::getWindow("RITab/SubMesh"); label->setText((CEGUI::utf8*) gettext("Submeshes")); - label = win_mgr.getWindow("RITab/SubMesh/AddSubMeshButton"); + label = CEGUIUtility::getWindow("RITab/SubMesh/AddSubMeshButton"); label->setText((CEGUI::utf8*) gettext("Add Submesh")); - label = win_mgr.getWindow("RITab/SM/NewSubmeshLabel"); + label = CEGUIUtility::getWindow("RITab/SM/NewSubmeshLabel"); label->setText((CEGUI::utf8*) gettext("New submesh:")); - label = win_mgr.getWindow("RITab/SM/NewSMNameLabel"); + label = CEGUIUtility::getWindow("RITab/SM/NewSMNameLabel"); label->setText((CEGUI::utf8*) gettext("submesh name:")); - label = win_mgr.getWindow("RITab/SM/EditSMLabel"); + label = CEGUIUtility::getWindow("RITab/SM/EditSMLabel"); label->setText((CEGUI::utf8*) gettext("Edit submesh:")); - label = win_mgr.getWindow("RITab/SM/AttachMeshLabel"); + label = CEGUIUtility::getWindow("RITab/SM/AttachMeshLabel"); label->setText((CEGUI::utf8*) gettext("Attach to:")); - label = win_mgr.getWindow("RITab/SM/BoneLabel"); + label = CEGUIUtility::getWindow("RITab/SM/BoneLabel"); label->setText((CEGUI::utf8*) gettext("at bone:")); - label = win_mgr.getWindow("RITab/SM/RotateLabel"); + label = CEGUIUtility::getWindow("RITab/SM/RotateLabel"); label->setText((CEGUI::utf8*) gettext("Rotate(x,y,z):")); - label = win_mgr.getWindow("RITab/SM/ScaleLabel"); + label = CEGUIUtility::getWindow("RITab/SM/ScaleLabel"); label->setText((CEGUI::utf8*) gettext("Scale:")); - label = win_mgr.getWindow("RITab/SM/OffsetLabel"); + label = CEGUIUtility::getWindow("RITab/SM/OffsetLabel"); label->setText((CEGUI::utf8*) gettext("Offset (x,y,z):")); - label = win_mgr.getWindow("RITab/SubMesh/DelSubMeshButton"); + label = CEGUIUtility::getWindow("RITab/SubMesh/DelSubMeshButton"); label->setText((CEGUI::utf8*) gettext("Delete Submesh")); - label = win_mgr.getWindow("RITab/Animations"); + label = CEGUIUtility::getWindow("RITab/Animations"); label->setText((CEGUI::utf8*) gettext("Animations")); - label = win_mgr.getWindow("RITab/XML"); + label = CEGUIUtility::getWindow("RITab/XML"); label->setText((CEGUI::utf8*) gettext("XML")); - label = win_mgr.getWindow("RITab/XML/SubmitButton"); + label = CEGUIUtility::getWindow("RITab/XML/SubmitButton"); label->setText((CEGUI::utf8*) gettext("Submit XML")); - label = win_mgr.getWindow("FixedObjectTab"); + label = CEGUIUtility::getWindow("FixedObjectTab"); label->setText((CEGUI::utf8*) gettext("FixedObject")); - label = win_mgr.getWindow("FOTab/Properties"); + label = CEGUIUtility::getWindow("FOTab/Properties"); label->setText((CEGUI::utf8*) gettext("Properties")); - label = win_mgr.getWindow("FOTab/Prop/ShapeLabel"); + label = CEGUIUtility::getWindow("FOTab/Prop/ShapeLabel"); label->setText((CEGUI::utf8*) gettext("Shape:")); - label = win_mgr.getWindow("FOTab/Prop/CircleLabel"); + label = CEGUIUtility::getWindow("FOTab/Prop/CircleLabel"); label->setText((CEGUI::utf8*) gettext("Circle")); - label = win_mgr.getWindow("FOTab/Prop/RadiusLabel"); + label = CEGUIUtility::getWindow("FOTab/Prop/RadiusLabel"); label->setText((CEGUI::utf8*) gettext("Radius:")); - label = win_mgr.getWindow("FOTab/Prop/DetectCircleButton"); + label = CEGUIUtility::getWindow("FOTab/Prop/DetectCircleButton"); label->setText((CEGUI::utf8*) gettext("Autodetect")); - label = win_mgr.getWindow("FOTab/Prop/RectangleLabel"); + label = CEGUIUtility::getWindow("FOTab/Prop/RectangleLabel"); label->setText((CEGUI::utf8*) gettext("Rectangle")); - label = win_mgr.getWindow("FOTab/Prop/WidthLabel"); + label = CEGUIUtility::getWindow("FOTab/Prop/WidthLabel"); label->setText((CEGUI::utf8*) gettext("Width:")); - label = win_mgr.getWindow("FOTab/Prop/DepthLabel"); + label = CEGUIUtility::getWindow("FOTab/Prop/DepthLabel"); label->setText((CEGUI::utf8*) gettext("Depth:")); - label = win_mgr.getWindow("FOTab/Prop/DetectRectButton"); + label = CEGUIUtility::getWindow("FOTab/Prop/DetectRectButton"); label->setText((CEGUI::utf8*) gettext("Autodetect")); - label = win_mgr.getWindow("FOTab/Prop/CollisionLabel"); + label = CEGUIUtility::getWindow("FOTab/Prop/CollisionLabel"); label->setText((CEGUI::utf8*) gettext("Collision type")); - label = win_mgr.getWindow("FOTab/Properties/CopyDataLabel"); + label = CEGUIUtility::getWindow("FOTab/Properties/CopyDataLabel"); label->setText((CEGUI::utf8*) gettext("Copy data from:")); - label = win_mgr.getWindow("FOTab/Properties/CopyDataButton"); + label = CEGUIUtility::getWindow("FOTab/Properties/CopyDataButton"); label->setText((CEGUI::utf8*) gettext("Copy")); - label = win_mgr.getWindow("FOTab/Create"); + label = CEGUIUtility::getWindow("FOTab/Create"); label->setText((CEGUI::utf8*) gettext("Create Object")); - label = win_mgr.getWindow("FOTab/XML/CreateButton"); + label = CEGUIUtility::getWindow("FOTab/XML/CreateButton"); label->setText((CEGUI::utf8*) gettext("Create Object")); - label = win_mgr.getWindow("FOTab/Create/PosLabel"); + label = CEGUIUtility::getWindow("FOTab/Create/PosLabel"); label->setText((CEGUI::utf8*) gettext("Position:")); - label = win_mgr.getWindow("FOTab/Create/GetPlPosButton"); + label = CEGUIUtility::getWindow("FOTab/Create/GetPlPosButton"); label->setText((CEGUI::utf8*) gettext("Get Player Position")); - label = win_mgr.getWindow("FOTab/Create/AngleLabel"); + label = CEGUIUtility::getWindow("FOTab/Create/AngleLabel"); label->setText((CEGUI::utf8*) gettext("Angle:")); - label = win_mgr.getWindow("FOTab/Create/DelAllButton"); + label = CEGUIUtility::getWindow("FOTab/Create/DelAllButton"); label->setText((CEGUI::utf8*) gettext("Delete all objects")); - label = win_mgr.getWindow("FOTab/XML"); + label = CEGUIUtility::getWindow("FOTab/XML"); label->setText((CEGUI::utf8*) gettext("XML")); - label = win_mgr.getWindow("FOTab/XML/SubmitButton"); + label = CEGUIUtility::getWindow("FOTab/XML/SubmitButton"); label->setText((CEGUI::utf8*) gettext("Submit XML")); - label = win_mgr.getWindow("ItemTab"); + label = CEGUIUtility::getWindow("ItemTab"); label->setText((CEGUI::utf8*) gettext("Item")); - label = win_mgr.getWindow("ItemTab/General"); + label = CEGUIUtility::getWindow("ItemTab/General"); label->setText((CEGUI::utf8*) gettext("General")); - label = win_mgr.getWindow("ItemTab/Properties/TypeLabel"); + label = CEGUIUtility::getWindow("ItemTab/Properties/TypeLabel"); label->setText((CEGUI::utf8*) gettext("Type:")); - label = win_mgr.getWindow("ItemTab/Properties/SizeLabel"); + label = CEGUIUtility::getWindow("ItemTab/Properties/SizeLabel"); label->setText((CEGUI::utf8*) gettext("Size:")); - label = win_mgr.getWindow("ItemTab/Properties/CopyDataLabel"); + label = CEGUIUtility::getWindow("ItemTab/Properties/CopyDataLabel"); label->setText((CEGUI::utf8*) gettext("Copy data from:")); - label = win_mgr.getWindow("ItemTab/Properties/CopyDataButton"); + label = CEGUIUtility::getWindow("ItemTab/Properties/CopyDataButton"); label->setText((CEGUI::utf8*) gettext("Copy")); - label = win_mgr.getWindow("ItemTab/General/NameLabel"); + label = CEGUIUtility::getWindow("ItemTab/General/NameLabel"); label->setText((CEGUI::utf8*) gettext("Name:")); - label = win_mgr.getWindow("ItemTab/General/PriceLabel"); + label = CEGUIUtility::getWindow("ItemTab/General/PriceLabel"); label->setText((CEGUI::utf8*) gettext("Value:")); - label = win_mgr.getWindow("ItemTab/General/EnchantRangeLabel"); + label = CEGUIUtility::getWindow("ItemTab/General/EnchantRangeLabel"); label->setText((CEGUI::utf8*) gettext("Enchant min:")); - label = win_mgr.getWindow("ItemTab/General/EnchantMaxLabel"); + label = CEGUIUtility::getWindow("ItemTab/General/EnchantMaxLabel"); label->setText((CEGUI::utf8*) gettext("max:")); - label = win_mgr.getWindow("ItemTab/Equip"); + label = CEGUIUtility::getWindow("ItemTab/Equip"); label->setText((CEGUI::utf8*) gettext("Equip")); - label = win_mgr.getWindow("ItemTab/Equip/HealthLabel"); + label = CEGUIUtility::getWindow("ItemTab/Equip/HealthLabel"); label->setText((CEGUI::utf8*) gettext("Health:")); - label = win_mgr.getWindow("ItemTab/Equip/AttrLabel"); + label = CEGUIUtility::getWindow("ItemTab/Equip/AttrLabel"); label->setText((CEGUI::utf8*) gettext("Attribute:")); - label = win_mgr.getWindow("ItemTab/Equip/StrengthLabel"); + label = CEGUIUtility::getWindow("ItemTab/Equip/StrengthLabel"); label->setText((CEGUI::utf8*) gettext("Strength:")); - label = win_mgr.getWindow("ItemTab/Equip/DexterityLabel"); + label = CEGUIUtility::getWindow("ItemTab/Equip/DexterityLabel"); label->setText((CEGUI::utf8*) gettext("Dexterity:")); - label = win_mgr.getWindow("ItemTab/Equip/MagicPowerLabel"); + label = CEGUIUtility::getWindow("ItemTab/Equip/MagicPowerLabel"); label->setText((CEGUI::utf8*) gettext("Magic Power:")); - label = win_mgr.getWindow("ItemTab/Equip/WillpowerLabel"); + label = CEGUIUtility::getWindow("ItemTab/Equip/WillpowerLabel"); label->setText((CEGUI::utf8*) gettext("Willpower:")); - label = win_mgr.getWindow("ItemTab/Equip/ResistancesLabel"); + label = CEGUIUtility::getWindow("ItemTab/Equip/ResistancesLabel"); label->setText((CEGUI::utf8*) gettext("Resistances:")); - label = win_mgr.getWindow("ItemTab/Equip/PhysResLabel"); + label = CEGUIUtility::getWindow("ItemTab/Equip/PhysResLabel"); label->setText((CEGUI::utf8*) gettext("Physical:")); - label = win_mgr.getWindow("ItemTab/Equip/FireResLabel"); + label = CEGUIUtility::getWindow("ItemTab/Equip/FireResLabel"); label->setText((CEGUI::utf8*) gettext("Fire:")); - label = win_mgr.getWindow("ItemTab/Equip/IceResLabel"); + label = CEGUIUtility::getWindow("ItemTab/Equip/IceResLabel"); label->setText((CEGUI::utf8*) gettext("Ice:")); - label = win_mgr.getWindow("ItemTab/Equip/AirResLabel"); + label = CEGUIUtility::getWindow("ItemTab/Equip/AirResLabel"); label->setText((CEGUI::utf8*) gettext("Air:")); - label = win_mgr.getWindow("ItemTab/Equip/OtherLabel"); + label = CEGUIUtility::getWindow("ItemTab/Equip/OtherLabel"); label->setText((CEGUI::utf8*) gettext("Other:")); - label = win_mgr.getWindow("ItemTab/Equip/ArmorLabel"); + label = CEGUIUtility::getWindow("ItemTab/Equip/ArmorLabel"); label->setText((CEGUI::utf8*) gettext("Armor:")); - label = win_mgr.getWindow("ItemTab/Equip/BlockLabel"); + label = CEGUIUtility::getWindow("ItemTab/Equip/BlockLabel"); label->setText((CEGUI::utf8*) gettext("Block:")); - label = win_mgr.getWindow("ItemTab/Equip/AttackLabel"); + label = CEGUIUtility::getWindow("ItemTab/Equip/AttackLabel"); label->setText((CEGUI::utf8*) gettext("Precision:")); - label = win_mgr.getWindow("ItemTab/Equip/PowerLabel"); + label = CEGUIUtility::getWindow("ItemTab/Equip/PowerLabel"); label->setText((CEGUI::utf8*) gettext("Power:")); - label = win_mgr.getWindow("ItemTab/Weapon"); + label = CEGUIUtility::getWindow("ItemTab/Weapon"); label->setText((CEGUI::utf8*) gettext("Weapon")); - label = win_mgr.getWindow("ItemTab/Weapon/TypeLabel"); + label = CEGUIUtility::getWindow("ItemTab/Weapon/TypeLabel"); label->setText((CEGUI::utf8*) gettext("Type:")); - label = win_mgr.getWindow("ItemTab/Weapon/DamageLabel"); + label = CEGUIUtility::getWindow("ItemTab/Weapon/DamageLabel"); label->setText((CEGUI::utf8*) gettext("Damage:")); - label = win_mgr.getWindow("ItemTab/Weapon/PhysLabel"); + label = CEGUIUtility::getWindow("ItemTab/Weapon/PhysLabel"); label->setText((CEGUI::utf8*) gettext("Physical:")); - label = win_mgr.getWindow("ItemTab/Weapon/PhysToLabel"); + label = CEGUIUtility::getWindow("ItemTab/Weapon/PhysToLabel"); label->setText((CEGUI::utf8*) gettext("-")); - label = win_mgr.getWindow("ItemTab/Weapon/PhysMultLabel"); + label = CEGUIUtility::getWindow("ItemTab/Weapon/PhysMultLabel"); label->setText((CEGUI::utf8*) gettext("x")); - label = win_mgr.getWindow("ItemTab/Weapon/FireLabel"); + label = CEGUIUtility::getWindow("ItemTab/Weapon/FireLabel"); label->setText((CEGUI::utf8*) gettext("Fire:")); - label = win_mgr.getWindow("ItemTab/Weapon/FireToLabel"); + label = CEGUIUtility::getWindow("ItemTab/Weapon/FireToLabel"); label->setText((CEGUI::utf8*) gettext("-")); - label = win_mgr.getWindow("ItemTab/Weapon/FireMultLabel"); + label = CEGUIUtility::getWindow("ItemTab/Weapon/FireMultLabel"); label->setText((CEGUI::utf8*) gettext("x")); - label = win_mgr.getWindow("ItemTab/Weapon/IceLabel"); + label = CEGUIUtility::getWindow("ItemTab/Weapon/IceLabel"); label->setText((CEGUI::utf8*) gettext("Ice:")); - label = win_mgr.getWindow("ItemTab/Weapon/IceToLabel"); + label = CEGUIUtility::getWindow("ItemTab/Weapon/IceToLabel"); label->setText((CEGUI::utf8*) gettext("-")); - label = win_mgr.getWindow("ItemTab/Weapon/IceMultLabel"); + label = CEGUIUtility::getWindow("ItemTab/Weapon/IceMultLabel"); label->setText((CEGUI::utf8*) gettext("x")); - label = win_mgr.getWindow("ItemTab/Weapon/AirLabel"); + label = CEGUIUtility::getWindow("ItemTab/Weapon/AirLabel"); label->setText((CEGUI::utf8*) gettext("Air:")); - label = win_mgr.getWindow("ItemTab/Weapon/AirToLabel"); + label = CEGUIUtility::getWindow("ItemTab/Weapon/AirToLabel"); label->setText((CEGUI::utf8*) gettext("-")); - label = win_mgr.getWindow("ItemTab/Weapon/AirMultLabel"); + label = CEGUIUtility::getWindow("ItemTab/Weapon/AirMultLabel"); label->setText((CEGUI::utf8*) gettext("x")); - label = win_mgr.getWindow("ItemTab/Weapon/PrecisionLabel"); + label = CEGUIUtility::getWindow("ItemTab/Weapon/PrecisionLabel"); label->setText((CEGUI::utf8*) gettext("Precision:")); - label = win_mgr.getWindow("ItemTab/Weapon/PowerLabel"); + label = CEGUIUtility::getWindow("ItemTab/Weapon/PowerLabel"); label->setText((CEGUI::utf8*) gettext("Power:")); - label = win_mgr.getWindow("ItemTab/Weapon/RangeLabel"); + label = CEGUIUtility::getWindow("ItemTab/Weapon/RangeLabel"); label->setText((CEGUI::utf8*) gettext("Range:")); - label = win_mgr.getWindow("ItemTab/Weapon/SpeedLabel"); + label = CEGUIUtility::getWindow("ItemTab/Weapon/SpeedLabel"); label->setText((CEGUI::utf8*) gettext("Speed:")); - label = win_mgr.getWindow("ItemTab/Weapon/TwohandedLabel"); + label = CEGUIUtility::getWindow("ItemTab/Weapon/TwohandedLabel"); label->setText((CEGUI::utf8*) gettext("Twohanded weapon")); - label = win_mgr.getWindow("ItemTab/Weapon/CritPercentLabel"); + label = CEGUIUtility::getWindow("ItemTab/Weapon/CritPercentLabel"); label->setText((CEGUI::utf8*) gettext("Crit. Hits:")); - label = win_mgr.getWindow("ItemTab/Consume"); + label = CEGUIUtility::getWindow("ItemTab/Consume"); label->setText((CEGUI::utf8*) gettext("Consume")); - label = win_mgr.getWindow("ItemTab/Consume/TypeLabel"); + label = CEGUIUtility::getWindow("ItemTab/Consume/TypeLabel"); label->setText((CEGUI::utf8*) gettext("Health:")); - label = win_mgr.getWindow("ItemTab/Consume/CureLabel"); + label = CEGUIUtility::getWindow("ItemTab/Consume/CureLabel"); label->setText((CEGUI::utf8*) gettext("Status heal and immunity time:")); - label = win_mgr.getWindow("ItemTab/Consume/BlindLabel"); + label = CEGUIUtility::getWindow("ItemTab/Consume/BlindLabel"); label->setText((CEGUI::utf8*) gettext("Blind:")); - label = win_mgr.getWindow("ItemTab/Consume/PoisonedLabel"); + label = CEGUIUtility::getWindow("ItemTab/Consume/PoisonedLabel"); label->setText((CEGUI::utf8*) gettext("Poisoned:")); - label = win_mgr.getWindow("ItemTab/Consume/BerserkLabel"); + label = CEGUIUtility::getWindow("ItemTab/Consume/BerserkLabel"); label->setText((CEGUI::utf8*) gettext("Berserk:")); - label = win_mgr.getWindow("ItemTab/Consume/ConfusedLabel"); + label = CEGUIUtility::getWindow("ItemTab/Consume/ConfusedLabel"); label->setText((CEGUI::utf8*) gettext("Confused:")); - label = win_mgr.getWindow("ItemTab/Consume/MuteLabel"); + label = CEGUIUtility::getWindow("ItemTab/Consume/MuteLabel"); label->setText((CEGUI::utf8*) gettext("Mute:")); - label = win_mgr.getWindow("ItemTab/Consume/ParalyzedLabel"); + label = CEGUIUtility::getWindow("ItemTab/Consume/ParalyzedLabel"); label->setText((CEGUI::utf8*) gettext("Paralyzed:")); - label = win_mgr.getWindow("ItemTab/Consume/FrozenLabel"); + label = CEGUIUtility::getWindow("ItemTab/Consume/FrozenLabel"); label->setText((CEGUI::utf8*) gettext("Frozen:")); - label = win_mgr.getWindow("ItemTab/Consume/BurningLabel"); + label = CEGUIUtility::getWindow("ItemTab/Consume/BurningLabel"); label->setText((CEGUI::utf8*) gettext("Burning:")); - label = win_mgr.getWindow("ItemTab/Create"); + label = CEGUIUtility::getWindow("ItemTab/Create"); label->setText((CEGUI::utf8*) gettext("Create Item")); - label = win_mgr.getWindow("ItemTab/Create/EnchantLabel"); + label = CEGUIUtility::getWindow("ItemTab/Create/EnchantLabel"); label->setText((CEGUI::utf8*) gettext("Enchant:")); - label = win_mgr.getWindow("ItemTab/Create/CreateInventoryButton"); + label = CEGUIUtility::getWindow("ItemTab/Create/CreateInventoryButton"); label->setText((CEGUI::utf8*) gettext("Create in inventory")); - label = win_mgr.getWindow("ItemTab/Create/CreateDropButton"); + label = CEGUIUtility::getWindow("ItemTab/Create/CreateDropButton"); label->setText((CEGUI::utf8*) gettext("Create an drop")); - label = win_mgr.getWindow("ItemTab/XML"); + label = CEGUIUtility::getWindow("ItemTab/XML"); label->setText((CEGUI::utf8*) gettext("XML")); - label = win_mgr.getWindow("ItemTab/XML/SubmitButton"); + label = CEGUIUtility::getWindow("ItemTab/XML/SubmitButton"); label->setText((CEGUI::utf8*) gettext("Submit XML")); - label = win_mgr.getWindow("CloseButton"); + label = CEGUIUtility::getWindow("CloseButton"); label->setText((CEGUI::utf8*) gettext("Close")); textdomain("menu");
--- a/src/gui/contenteditor/contenteditortab.cpp Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/contenteditor/contenteditortab.cpp Wed Mar 26 23:39:02 2014 +0200 @@ -19,11 +19,14 @@ #include "contenteditortab.h" +// Utility for CEGUI cross-version compatibility +#include "ceguiutility.h" + void ContentEditorTab::setWindowText(std::string windowname, std::string text) { CEGUI::utf8* str = (CEGUI::utf8*) (text.c_str()); - CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::Window* win = win_mgr.getWindow(windowname); + //CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); + CEGUI::Window* win = CEGUIUtility::getWindow(windowname); if (win != 0) { @@ -36,8 +39,8 @@ std::string ContentEditorTab::getWindowText(std::string windowname, std::string def) { - CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::Window* win = win_mgr.getWindow(windowname); + //CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); + CEGUI::Window* win = CEGUIUtility::getWindow(windowname); if (win != 0) { @@ -48,8 +51,8 @@ void ContentEditorTab::setSpinnerValue(std::string windowname, double value) { - CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::Spinner* spinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow(windowname)); + //CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); + CEGUI::Spinner* spinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow(windowname)); if (spinner != 0) { @@ -62,8 +65,8 @@ double ContentEditorTab::getSpinnerValue(std::string windowname, double def) { - CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::Spinner* spinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow(windowname)); + //CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); + CEGUI::Spinner* spinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow(windowname)); if (spinner != 0) { @@ -74,8 +77,8 @@ void ContentEditorTab::setCheckboxSelected(std::string windowname, bool state) { - CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::Checkbox* box = static_cast<CEGUI::Checkbox*>(win_mgr.getWindow(windowname)); + //CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); + CEGUIUtility::ToggleButton* box = static_cast<CEGUIUtility::ToggleButton*>(CEGUIUtility::getWindow(windowname)); if (box != 0) { @@ -88,8 +91,8 @@ bool ContentEditorTab::getCheckboxSelected(std::string windowname) { - CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::Checkbox* box = static_cast<CEGUI::Checkbox*>(win_mgr.getWindow(windowname)); + //CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); + CEGUIUtility::ToggleButton* box = static_cast<CEGUIUtility::ToggleButton*>(CEGUIUtility::getWindow(windowname)); if (box != 0) { @@ -100,8 +103,8 @@ std::string ContentEditorTab::getComboboxSelection(std::string windowname, std::string def) { - CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::Combobox* box = static_cast<CEGUI::Combobox*>(win_mgr.getWindow(windowname)); + //CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); + CEGUI::Combobox* box = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow(windowname)); if (box != 0) { @@ -116,8 +119,8 @@ void ContentEditorTab::setComboboxSelection(std::string windowname, std::string selection) { - CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::Combobox* box = static_cast<CEGUI::Combobox*>(win_mgr.getWindow(windowname)); + //CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); + CEGUI::Combobox* box = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow(windowname)); if (box != 0) { @@ -133,8 +136,8 @@ void ContentEditorTab::setMultiLineEditboxCursor(std::string windowname, int row, int col) { - CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::MultiLineEditbox* editor = static_cast<CEGUI::MultiLineEditbox*>(win_mgr.getWindow(windowname)); + //CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); + CEGUI::MultiLineEditbox* editor = static_cast<CEGUI::MultiLineEditbox*>(CEGUIUtility::getWindow(windowname)); if (editor != 0) { @@ -163,8 +166,8 @@ pos++; } - editor->setCaratIndex(pos); - editor->ensureCaratIsVisible(); + editor->setCaretIndex(pos); + editor->ensureCaretIsVisible(); editor->activate(); } }
--- a/src/gui/contenteditor/contenttab.h Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/contenteditor/contenttab.h Wed Mar 26 23:39:02 2014 +0200 @@ -16,7 +16,12 @@ #ifndef CONTENTTAB_H #define CONTENTTAB_H +#ifdef CEGUI_07 #include <CEGUI/CEGUIString.h> +#else +#include "CEGUI/String.h" +#endif + class ContentTab {
--- a/src/gui/contenteditor/fixedobjecteditor.cpp Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/contenteditor/fixedobjecteditor.cpp Wed Mar 26 23:39:02 2014 +0200 @@ -13,6 +13,8 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ +// Utility for CEGUI cross-version compatibility +#include "ceguiutility.h" #include "graphicmanager.h" @@ -28,15 +30,15 @@ CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::PushButton* detectCircleButton = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("FOTab/Prop/DetectCircleButton")); - CEGUI::PushButton* detectRectButton = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("FOTab/Prop/DetectRectButton")); + CEGUI::PushButton* detectCircleButton = static_cast<CEGUI::PushButton*>(CEGUIUtility::getWindow("FOTab/Prop/DetectCircleButton")); + CEGUI::PushButton* detectRectButton = static_cast<CEGUI::PushButton*>(CEGUIUtility::getWindow("FOTab/Prop/DetectRectButton")); - CEGUI::Spinner* radiusSpinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("FOTab/Prop/RadiusSpinner")); - CEGUI::Spinner* widthSpinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("FOTab/Prop/WidthSpinner")); - CEGUI::Spinner* depthSpinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("FOTab/Prop/DepthSpinner")); + CEGUI::Spinner* radiusSpinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("FOTab/Prop/RadiusSpinner")); + CEGUI::Spinner* widthSpinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("FOTab/Prop/WidthSpinner")); + CEGUI::Spinner* depthSpinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("FOTab/Prop/DepthSpinner")); - CEGUI::RadioButton* circleButton = static_cast<CEGUI::RadioButton*>(win_mgr.getWindow("FOTab/Prop/CircleCheckbox")); - CEGUI::RadioButton* rectButton = static_cast<CEGUI::RadioButton*>(win_mgr.getWindow("FOTab/Prop/RectangleCheckbox")); + CEGUI::RadioButton* circleButton = static_cast<CEGUI::RadioButton*>(CEGUIUtility::getWindow("FOTab/Prop/CircleCheckbox")); + CEGUI::RadioButton* rectButton = static_cast<CEGUI::RadioButton*>(CEGUIUtility::getWindow("FOTab/Prop/RectangleCheckbox")); radiusSpinner->subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&FixedObjectEditor::onFixedObjectModified, this)); widthSpinner->subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&FixedObjectEditor::onFixedObjectModified, this)); @@ -49,7 +51,7 @@ detectCircleButton->subscribeEvent(CEGUI::PushButton::EventClicked, CEGUI::Event::Subscriber(&FixedObjectEditor::onFixedObjectAutodetectSize, this)); detectRectButton->subscribeEvent(CEGUI::PushButton::EventClicked, CEGUI::Event::Subscriber(&FixedObjectEditor::onFixedObjectAutodetectSize, this)); - CEGUI::Combobox* layerSelector = static_cast<CEGUI::Combobox*>(win_mgr.getWindow("FOTab/Prop/LayerSelector")); + CEGUI::Combobox* layerSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("FOTab/Prop/LayerSelector")); layerSelector->addItem(new CEGUI::ListboxTextItem("Normal")); layerSelector->addItem(new CEGUI::ListboxTextItem("Base")); layerSelector->addItem(new CEGUI::ListboxTextItem("Air")); @@ -57,16 +59,16 @@ layerSelector->subscribeEvent(CEGUI::Combobox::EventListSelectionAccepted, CEGUI::Event::Subscriber(&FixedObjectEditor::onFixedObjectModified, this)); - CEGUI::PushButton* xmlsubmitButton = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("FOTab/XML/SubmitButton")); + CEGUI::PushButton* xmlsubmitButton = static_cast<CEGUI::PushButton*>(CEGUIUtility::getWindow("FOTab/XML/SubmitButton")); xmlsubmitButton->subscribeEvent(CEGUI::PushButton::EventClicked, CEGUI::Event::Subscriber(&FixedObjectEditor::onFixedObjectXMLModified, this)); - CEGUI::PushButton* createFOButton = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("FOTab/XML/CreateButton")); + CEGUI::PushButton* createFOButton = static_cast<CEGUI::PushButton*>(CEGUIUtility::getWindow("FOTab/XML/CreateButton")); createFOButton->subscribeEvent(CEGUI::PushButton::EventClicked, CEGUI::Event::Subscriber(&FixedObjectEditor::onFixedObjectCreate, this)); - CEGUI::PushButton* delallFOButton = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("FOTab/Create/DelAllButton")); + CEGUI::PushButton* delallFOButton = static_cast<CEGUI::PushButton*>(CEGUIUtility::getWindow("FOTab/Create/DelAllButton")); delallFOButton->subscribeEvent(CEGUI::PushButton::EventClicked, CEGUI::Event::Subscriber(&FixedObjectEditor::onDelAllObjects, this)); - CEGUI::PushButton* getplayerButton = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("FOTab/Create/GetPlPosButton")); + CEGUI::PushButton* getplayerButton = static_cast<CEGUI::PushButton*>(CEGUIUtility::getWindow("FOTab/Create/GetPlPosButton")); getplayerButton->subscribeEvent(CEGUI::PushButton::EventClicked, CEGUI::Event::Subscriber(&FixedObjectEditor::onGetPlayerPosition, this)); @@ -108,7 +110,7 @@ { CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::Combobox* copyfoSelector = static_cast<CEGUI::Combobox*>(win_mgr.getWindow("FOTab/Properties/CopyDataBox")); + CEGUI::Combobox* copyfoSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("FOTab/Properties/CopyDataBox")); // Fill list of all FixedObjects const std::map<GameObject::Subtype, FixedObjectData*>& all_fo = ObjectFactory::getAllFixedObjectData(); @@ -118,7 +120,7 @@ copyfoSelector->addItem(new CEGUI::ListboxTextItem(it->first.c_str())); } - CEGUI::PushButton* copyfoButton = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("FOTab/Properties/CopyDataButton")); + CEGUI::PushButton* copyfoButton = static_cast<CEGUI::PushButton*>(CEGUIUtility::getWindow("FOTab/Properties/CopyDataButton")); copyfoButton->subscribeEvent(CEGUI::PushButton::EventClicked, CEGUI::Event::Subscriber(&FixedObjectEditor::onCopyData, this)); } @@ -133,7 +135,7 @@ TiXmlPrinter printer; m_fixed_object_xml.Accept(&printer); - CEGUI::MultiLineEditbox* editor = static_cast<CEGUI::MultiLineEditbox*>(win_mgr.getWindow("FOTab/XML/FOXMLEditbox")); + CEGUI::MultiLineEditbox* editor = static_cast<CEGUI::MultiLineEditbox*>(CEGUIUtility::getWindow("FOTab/XML/FOXMLEditbox")); editor->setText(printer.CStr()); } @@ -143,14 +145,14 @@ CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::Combobox* layerSelector = static_cast<CEGUI::Combobox*>(win_mgr.getWindow("FOTab/Prop/LayerSelector")); + CEGUI::Combobox* layerSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("FOTab/Prop/LayerSelector")); - CEGUI::Spinner* radiusSpinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("FOTab/Prop/RadiusSpinner")); - CEGUI::Spinner* widthSpinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("FOTab/Prop/WidthSpinner")); - CEGUI::Spinner* depthSpinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("FOTab/Prop/DepthSpinner")); + CEGUI::Spinner* radiusSpinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("FOTab/Prop/RadiusSpinner")); + CEGUI::Spinner* widthSpinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("FOTab/Prop/WidthSpinner")); + CEGUI::Spinner* depthSpinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("FOTab/Prop/DepthSpinner")); - CEGUI::RadioButton* circleButton = static_cast<CEGUI::RadioButton*>(win_mgr.getWindow("FOTab/Prop/CircleCheckbox")); - CEGUI::RadioButton* rectButton = static_cast<CEGUI::RadioButton*>(win_mgr.getWindow("FOTab/Prop/RectangleCheckbox")); + CEGUI::RadioButton* circleButton = static_cast<CEGUI::RadioButton*>(CEGUIUtility::getWindow("FOTab/Prop/CircleCheckbox")); + CEGUI::RadioButton* rectButton = static_cast<CEGUI::RadioButton*>(CEGUIUtility::getWindow("FOTab/Prop/RectangleCheckbox")); // adjust the spinner values if (m_edited_fixed_object.m_shape.m_type == Shape::CIRCLE) @@ -193,14 +195,14 @@ CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::RadioButton* CircleButton = static_cast<CEGUI::RadioButton*>(win_mgr.getWindow("FOTab/Prop/CircleCheckbox")); - //CEGUI::RadioButton* RectButton = static_cast<CEGUI::RadioButton*>(win_mgr.getWindow("FOTab/Prop/RectangleCheckbox")); + CEGUI::RadioButton* CircleButton = static_cast<CEGUI::RadioButton*>(CEGUIUtility::getWindow("FOTab/Prop/CircleCheckbox")); + //CEGUI::RadioButton* RectButton = static_cast<CEGUI::RadioButton*>(CEGUIUtility::getWindow("FOTab/Prop/RectangleCheckbox")); - CEGUI::Spinner* radiusSpinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("FOTab/Prop/RadiusSpinner")); - CEGUI::Spinner* widthSpinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("FOTab/Prop/WidthSpinner")); - CEGUI::Spinner* depthSpinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("FOTab/Prop/DepthSpinner")); + CEGUI::Spinner* radiusSpinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("FOTab/Prop/RadiusSpinner")); + CEGUI::Spinner* widthSpinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("FOTab/Prop/WidthSpinner")); + CEGUI::Spinner* depthSpinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("FOTab/Prop/DepthSpinner")); - CEGUI::Combobox* layerSelector = static_cast<CEGUI::Combobox*>(win_mgr.getWindow("FOTab/Prop/LayerSelector")); + CEGUI::Combobox* layerSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("FOTab/Prop/LayerSelector")); if (CircleButton->getSelectedButtonInGroup() == CircleButton) { @@ -236,12 +238,12 @@ CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::PushButton* detectCircleButton = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("FOTab/Prop/DetectCircleButton")); - //CEGUI::PushButton* detectRectButton = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("FOTab/Prop/DetectRectButton")); + CEGUI::PushButton* detectCircleButton = static_cast<CEGUI::PushButton*>(CEGUIUtility::getWindow("FOTab/Prop/DetectCircleButton")); + //CEGUI::PushButton* detectRectButton = static_cast<CEGUI::PushButton*>(CEGUIUtility::getWindow("FOTab/Prop/DetectRectButton")); - CEGUI::Spinner* radiusSpinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("FOTab/Prop/RadiusSpinner")); - CEGUI::Spinner* widthSpinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("FOTab/Prop/WidthSpinner")); - CEGUI::Spinner* depthSpinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("FOTab/Prop/DepthSpinner")); + CEGUI::Spinner* radiusSpinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("FOTab/Prop/RadiusSpinner")); + CEGUI::Spinner* widthSpinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("FOTab/Prop/WidthSpinner")); + CEGUI::Spinner* depthSpinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("FOTab/Prop/DepthSpinner")); // calculate the size of the bounding box RenderInfoEditor* ri_editor = dynamic_cast<RenderInfoEditor*>(ContentEditor::getSingleton().getComponent("RIEditor")); @@ -274,7 +276,7 @@ bool FixedObjectEditor::onFixedObjectXMLModified(const CEGUI::EventArgs& evt) { CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::MultiLineEditbox* editor = static_cast<CEGUI::MultiLineEditbox*>(win_mgr.getWindow("FOTab/XML/FOXMLEditbox")); + CEGUI::MultiLineEditbox* editor = static_cast<CEGUI::MultiLineEditbox*>(CEGUIUtility::getWindow("FOTab/XML/FOXMLEditbox")); // Parse the editor text to XML // use temporary XML document for recovering from errors
--- a/src/gui/contenteditor/gameinfotab.cpp Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/contenteditor/gameinfotab.cpp Wed Mar 26 23:39:02 2014 +0200 @@ -13,6 +13,8 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ +// Utility for CEGUI cross-version compatibility +#include "ceguiutility.h" #include "gameinfotab.h" #include <sstream> @@ -27,7 +29,7 @@ ContentEditorTab::init(parent); CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - m_ShowBox = static_cast<CEGUI::MultiLineEditbox*>(win_mgr.getWindow("GameInfoTab/TextBox")); + m_ShowBox = static_cast<CEGUI::MultiLineEditbox*>(CEGUIUtility::getWindow("GameInfoTab/TextBox")); } void GameInfoTab::update()
--- a/src/gui/contenteditor/guitabs.h Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/contenteditor/guitabs.h Wed Mar 26 23:39:02 2014 +0200 @@ -17,7 +17,13 @@ #define GUITABS_H #include <contenttab.h> + +#ifdef CEGUI_07 #include <CEGUI/CEGUIWindow.h> +#else +#include "CEGUI/Window.h" +#endif + #include "OgreLog.h" namespace Ogre
--- a/src/gui/contenteditor/itemeditor.cpp Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/contenteditor/itemeditor.cpp Wed Mar 26 23:39:02 2014 +0200 @@ -13,7 +13,15 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ -#include "CEGUI/RendererModules/Ogre/CEGUIOgreRenderer.h" +// Utility for CEGUI cross-version compatibility +#include "ceguiutility.h" + +#ifdef CEGUI_07 +#include "CEGUI/RendererModules/Ogre/CEGUIOgreRenderer.h" +#else +#include "CEGUI/RendererModules/Ogre/Renderer.h" +#endif + #include <OgreHardwarePixelBuffer.h> #include <OgreMeshManager.h> @@ -29,28 +37,28 @@ CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::PushButton* xmlsubmitButton = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("ItemTab/XML/SubmitButton")); + CEGUI::PushButton* xmlsubmitButton = static_cast<CEGUI::PushButton*>(CEGUIUtility::getWindow("ItemTab/XML/SubmitButton")); xmlsubmitButton->subscribeEvent(CEGUI::PushButton::EventClicked, CEGUI::Event::Subscriber(&ItemEditor::onItemXMLModified, this)); - CEGUI::PushButton* createDropButton = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("ItemTab/Create/CreateDropButton")); + CEGUI::PushButton* createDropButton = static_cast<CEGUI::PushButton*>(CEGUIUtility::getWindow("ItemTab/Create/CreateDropButton")); createDropButton->subscribeEvent(CEGUI::PushButton::EventClicked, CEGUI::Event::Subscriber(&ItemEditor::onItemCreateDrop, this)); - CEGUI::PushButton* createInvButton = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("ItemTab/Create/CreateInventoryButton")); + CEGUI::PushButton* createInvButton = static_cast<CEGUI::PushButton*>(CEGUIUtility::getWindow("ItemTab/Create/CreateInventoryButton")); createInvButton->subscribeEvent(CEGUI::PushButton::EventClicked, CEGUI::Event::Subscriber(&ItemEditor::onItemCreateInInventory, this)); - CEGUI::Spinner* enchantMin = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/General/EnchantMinSpinner")); + CEGUI::Spinner* enchantMin = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/General/EnchantMinSpinner")); enchantMin->subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onItemModified, this)); - CEGUI::Spinner* enchantMax = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/General/EnchantMaxSpinner")); + CEGUI::Spinner* enchantMax = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/General/EnchantMaxSpinner")); enchantMax->subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onItemModified, this)); - CEGUI::Spinner* price = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/General/PriceSpinner")); + CEGUI::Spinner* price = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/General/PriceSpinner")); price->subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onItemModified, this)); - CEGUI::Editbox* nameBox = static_cast<CEGUI::Editbox*>(win_mgr.getWindow("ItemTab/General/NameBox")); + CEGUI::Editbox* nameBox = static_cast<CEGUI::Editbox*>(CEGUIUtility::getWindow("ItemTab/General/NameBox")); nameBox->subscribeEvent(CEGUI::Editbox::EventTextChanged, CEGUI::Event::Subscriber(&ItemEditor::onItemModified, this)); - CEGUI::Combobox* typeSelector = static_cast<CEGUI::Combobox*>(win_mgr.getWindow("ItemTab/Properties/TypeBox")); + CEGUI::Combobox* typeSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("ItemTab/Properties/TypeBox")); typeSelector->subscribeEvent(CEGUI::Combobox::EventListSelectionAccepted, CEGUI::Event::Subscriber(&ItemEditor::onItemModified, this)); typeSelector->addItem(new CEGUI::ListboxTextItem("Armor")); typeSelector->addItem(new CEGUI::ListboxTextItem("Weapon")); @@ -64,7 +72,7 @@ typeSelector->setSelection(0,0); - CEGUI::Combobox* sizeSelector = static_cast<CEGUI::Combobox*>(win_mgr.getWindow("ItemTab/Properties/SizeBox")); + CEGUI::Combobox* sizeSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("ItemTab/Properties/SizeBox")); sizeSelector->subscribeEvent(CEGUI::Combobox::EventListSelectionAccepted, CEGUI::Event::Subscriber(&ItemEditor::onItemModified, this)); sizeSelector->addItem(new CEGUI::ListboxTextItem("Big")); sizeSelector->addItem(new CEGUI::ListboxTextItem("Medium")); @@ -72,93 +80,93 @@ sizeSelector->setText("Big"); sizeSelector->setSelection(0,0); - CEGUI::PushButton* copyfoButton = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("ItemTab/Properties/CopyDataButton")); + CEGUI::PushButton* copyfoButton = static_cast<CEGUI::PushButton*>(CEGUIUtility::getWindow("ItemTab/Properties/CopyDataButton")); copyfoButton->subscribeEvent(CEGUI::PushButton::EventClicked, CEGUI::Event::Subscriber(&ItemEditor::onCopyData, this)); // wire weaponattr tab - CEGUI::Editbox* wtype = static_cast<CEGUI::Editbox*>(win_mgr.getWindow("ItemTab/Weapon/TypeBox")); + CEGUI::Editbox* wtype = static_cast<CEGUI::Editbox*>(CEGUIUtility::getWindow("ItemTab/Weapon/TypeBox")); wtype->subscribeEvent(CEGUI::Editbox::EventTextChanged, CEGUI::Event::Subscriber(&ItemEditor::onWeaponModified, this)); - CEGUI::Spinner* physMin = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Weapon/PhysMinSpinner")); + CEGUI::Spinner* physMin = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Weapon/PhysMinSpinner")); physMin->subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onWeaponModified, this)); - CEGUI::Spinner* physMax = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Weapon/PhysMaxSpinner")); + CEGUI::Spinner* physMax = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Weapon/PhysMaxSpinner")); physMax->subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onWeaponModified, this)); - CEGUI::Spinner* physMult = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Weapon/PhysMultSpinner")); + CEGUI::Spinner* physMult = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Weapon/PhysMultSpinner")); physMult->subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onWeaponModified, this)); - CEGUI::Spinner* fireMin = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Weapon/FireMinSpinner")); + CEGUI::Spinner* fireMin = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Weapon/FireMinSpinner")); fireMin->subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onWeaponModified, this)); - CEGUI::Spinner* fireMax = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Weapon/FireMaxSpinner")); + CEGUI::Spinner* fireMax = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Weapon/FireMaxSpinner")); fireMax->subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onItemModified, this)); - CEGUI::Spinner* fireMult = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Weapon/FireMultSpinner")); + CEGUI::Spinner* fireMult = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Weapon/FireMultSpinner")); fireMult->subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onWeaponModified, this)); - CEGUI::Spinner* iceMin = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Weapon/IceMinSpinner")); + CEGUI::Spinner* iceMin = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Weapon/IceMinSpinner")); iceMin->subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onWeaponModified, this)); - CEGUI::Spinner* iceMax = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Weapon/IceMaxSpinner")); + CEGUI::Spinner* iceMax = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Weapon/IceMaxSpinner")); iceMax->subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onWeaponModified, this)); - CEGUI::Spinner* iceMult = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Weapon/IceMultSpinner")); + CEGUI::Spinner* iceMult = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Weapon/IceMultSpinner")); iceMult->subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onWeaponModified, this)); - CEGUI::Spinner* airMin = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Weapon/AirMinSpinner")); + CEGUI::Spinner* airMin = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Weapon/AirMinSpinner")); airMin->subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onWeaponModified, this)); - CEGUI::Spinner* airMax = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Weapon/AirMaxSpinner")); + CEGUI::Spinner* airMax = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Weapon/AirMaxSpinner")); airMax->subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onWeaponModified, this)); - CEGUI::Spinner* airMult = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Weapon/AirMultSpinner")); + CEGUI::Spinner* airMult = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Weapon/AirMultSpinner")); airMult->subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onWeaponModified, this)); - CEGUI::Spinner* precision = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Weapon/PrecisionSpinner")); + CEGUI::Spinner* precision = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Weapon/PrecisionSpinner")); precision->subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onWeaponModified, this)); - CEGUI::Spinner* power = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Weapon/PowerSpinner")); + CEGUI::Spinner* power = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Weapon/PowerSpinner")); power->subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onWeaponModified, this)); - CEGUI::Spinner* range = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Weapon/RangeSpinner")); + CEGUI::Spinner* range = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Weapon/RangeSpinner")); range->subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onWeaponModified, this)); - CEGUI::Spinner* speed = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Weapon/SpeedSpinner")); + CEGUI::Spinner* speed = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Weapon/SpeedSpinner")); speed->subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onWeaponModified, this)); - CEGUI::Spinner* critperc = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Weapon/CritPercentSpinner")); + CEGUI::Spinner* critperc = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Weapon/CritPercentSpinner")); critperc->subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onWeaponModified, this)); - CEGUI::Checkbox* twohanded = static_cast<CEGUI::Checkbox*>(win_mgr.getWindow("ItemTab/Weapon/TwohandedCheckbox")); - twohanded->subscribeEvent(CEGUI::Checkbox::EventCheckStateChanged, CEGUI::Event::Subscriber(&ItemEditor::onWeaponModified, this)); + CEGUIUtility::ToggleButton* twohanded = static_cast<CEGUIUtility::ToggleButton*>(CEGUIUtility::getWindow("ItemTab/Weapon/TwohandedCheckbox")); + twohanded->subscribeEvent(CEGUIUtility::EventToggleButtonStateChanged(), CEGUI::Event::Subscriber(&ItemEditor::onWeaponModified, this)); // Wire the consume tab - static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Consume/HealthSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onConsumeEffectsModified, this)); - static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Consume/BlindSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onConsumeEffectsModified, this)); - static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Consume/PoisonedSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onConsumeEffectsModified, this)); - static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Consume/BerserkSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onConsumeEffectsModified, this)); - static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Consume/ConfusedSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onConsumeEffectsModified, this)); - static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Consume/MuteSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onConsumeEffectsModified, this)); - static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Consume/ParalyzedSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onConsumeEffectsModified, this)); - static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Consume/FrozenSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onConsumeEffectsModified, this)); - static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Consume/BurningSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onConsumeEffectsModified, this)); + static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Consume/HealthSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onConsumeEffectsModified, this)); + static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Consume/BlindSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onConsumeEffectsModified, this)); + static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Consume/PoisonedSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onConsumeEffectsModified, this)); + static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Consume/BerserkSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onConsumeEffectsModified, this)); + static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Consume/ConfusedSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onConsumeEffectsModified, this)); + static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Consume/MuteSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onConsumeEffectsModified, this)); + static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Consume/ParalyzedSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onConsumeEffectsModified, this)); + static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Consume/FrozenSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onConsumeEffectsModified, this)); + static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Consume/BurningSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onConsumeEffectsModified, this)); // wire the equip tab - static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Equip/HealthSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); - static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Equip/StrengthSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); - static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Equip/DexteritySpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); - static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Equip/MagicPowerSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); - static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Equip/WillpowerSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); - static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Equip/PhysResSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); - static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Equip/FireResSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); - static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Equip/IceResSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); - static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Equip/AirResSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); - static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Equip/ArmorSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); - static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Equip/BlockSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); - static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Equip/AttackSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); - static_cast<CEGUI::Spinner*>(win_mgr.getWindow("ItemTab/Equip/PowerSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); + static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Equip/HealthSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); + static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Equip/StrengthSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); + static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Equip/DexteritySpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); + static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Equip/MagicPowerSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); + static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Equip/WillpowerSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); + static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Equip/PhysResSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); + static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Equip/FireResSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); + static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Equip/IceResSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); + static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Equip/AirResSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); + static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Equip/ArmorSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); + static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Equip/BlockSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); + static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Equip/AttackSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); + static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("ItemTab/Equip/PowerSpinner"))-> subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&ItemEditor::onEquipEffectsModified, this)); // init the internal data @@ -218,7 +226,7 @@ { CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::Combobox* copyItemSelector = static_cast<CEGUI::Combobox*>(win_mgr.getWindow("ItemTab/Properties/CopyDataBox")); + CEGUI::Combobox* copyItemSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("ItemTab/Properties/CopyDataBox")); // Fill list of all FixedObjects const std::map<Item::Subtype,ItemBasicData*>& all_items = ItemFactory::getAllItemData(); @@ -402,7 +410,7 @@ bool ItemEditor::onItemXMLModified(const CEGUI::EventArgs& evt) { CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::MultiLineEditbox* editor = static_cast<CEGUI::MultiLineEditbox*>(win_mgr.getWindow("ItemTab/XML/ItemXMLEditbox")); + CEGUI::MultiLineEditbox* editor = static_cast<CEGUI::MultiLineEditbox*>(CEGUIUtility::getWindow("ItemTab/XML/ItemXMLEditbox")); // Parse the editor text to XML // use temporary XML document for recovering from errors @@ -491,8 +499,10 @@ item_view->setOverlaysEnabled (false); item_view->setBackgroundColour(Ogre::ColourValue(0,0,0,1.0) ); +#ifdef CEGUI_07 // create a CEGUI Image from the Texture - CEGUI::Texture& item_ceguiTex = static_cast<CEGUI::OgreRenderer*>(CEGUI::System::getSingleton().getRenderer())->createTexture(item_texture); + CEGUI::Texture& item_ceguiTex = static_cast<CEGUI::OgreRenderer*>( + CEGUI::System::getSingleton().getRenderer())->createTexture(item_texture); CEGUI::Imageset& item_textureImageSet = CEGUI::ImagesetManager::getSingleton().create(std::string("item_imageset_") + idstream.str(), item_ceguiTex); @@ -500,10 +510,29 @@ CEGUI::Point( 0.0f, 0.0f ), CEGUI::Size( item_ceguiTex.getSize().d_width, item_ceguiTex.getSize().d_height ), CEGUI::Point( 0.0f, 0.0f ) ); - +#else + + CEGUI::String imageName ("item_img_"+ idstream.str()); + CEGUI::String textureName ("ItemEditorTexture"); + + if (! CEGUI::System::getSingleton ().getRenderer ()->isTextureDefined (textureName) + && ! CEGUI::ImageManager::getSingleton().isDefined(imageName)) + { + CEGUI::Texture &item_ceguiTex = static_cast<CEGUI::OgreRenderer*> + (CEGUI::System::getSingleton ().getRenderer ())->createTexture (textureName, item_texture); + + CEGUI::OgreRenderer* rendererPtr = static_cast<CEGUI::OgreRenderer*>(CEGUI::System::getSingleton().getRenderer()); + CEGUI::TextureTarget* d_textureTarget; + CEGUI::BasicImage* d_textureTargetImage; + d_textureTarget = rendererPtr->createTextureTarget(); + d_textureTargetImage = static_cast<CEGUI::BasicImage*>(&CEGUI::ImageManager::getSingleton().create("BasicImage", imageName)); + d_textureTargetImage->setTexture(&item_ceguiTex); + d_textureTargetImage->setArea(CEGUI::Rectf(0, 0, item_ceguiTex.getSize ().d_width, item_ceguiTex.getSize ().d_height)); + } +#endif item_rt->update(); - CEGUI::Window* label = win_mgr.getWindow("ItemTab/BM/itemPreview"); + CEGUI::Window* label = CEGUIUtility::getWindow("ItemTab/BM/itemPreview"); // reparse and update the FixedObject Data // create a unique renderinfo (to avoid that the object is modified by the editor after creation) @@ -556,11 +585,16 @@ { World* world = World::getWorld(); if (world == 0) + { return true; + } WorldObject* player = world->getLocalPlayer(); if (player == 0) + { return true; + } + Region* region = player->getRegion(); // if the position is set to default, use the player position @@ -569,7 +603,10 @@ // create the object Item* item = createItem(); if (item == 0) + { return true; + } + region->dropItem(item,pos); return true; @@ -579,15 +616,22 @@ { World* world = World::getWorld(); if (world == 0) + { return true; + } WorldObject* player = world->getLocalPlayer(); if (player == 0) + { return true; + } Item* item = createItem(); if (item == 0) + { return true; + } + static_cast<Player*>(player)->insertItem(item); return true; } @@ -596,12 +640,16 @@ { std::string objname = getComboboxSelection("ItemTab/Properties/CopyDataBox", ""); if (objname == "") + { return true; + } ItemBasicData* data = ItemFactory::getItemBasicData(objname); if (data == 0) + { return true; + } data->m_subtype = "EditorItem"; @@ -624,7 +672,7 @@ TiXmlPrinter printer; m_item_xml.Accept(&printer); - CEGUI::MultiLineEditbox* editor = static_cast<CEGUI::MultiLineEditbox*>(win_mgr.getWindow("ItemTab/XML/ItemXMLEditbox")); + CEGUI::MultiLineEditbox* editor = static_cast<CEGUI::MultiLineEditbox*>(CEGUIUtility::getWindow("ItemTab/XML/ItemXMLEditbox")); editor->setText(printer.CStr()); }
--- a/src/gui/contenteditor/monstereditor.cpp Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/contenteditor/monstereditor.cpp Wed Mar 26 23:39:02 2014 +0200 @@ -14,11 +14,12 @@ */ +// Utility for CEGUI cross-version compatibility +#include "ceguiutility.h" #include "monstereditor.h" - #include "graphicmanager.h" #include "fixedobjecteditor.h" @@ -34,13 +35,13 @@ CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::Spinner* radiusSpinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("MonsterTab/Prop/RadiusSpinner")); + CEGUI::Spinner* radiusSpinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("MonsterTab/Prop/RadiusSpinner")); radiusSpinner->subscribeEvent(CEGUI::Spinner::EventValueChanged, CEGUI::Event::Subscriber(&MonsterEditor::onMonsterModified, this)); /* - CEGUI::Combobox* layerSelector = static_cast<CEGUI::Combobox*>(win_mgr.getWindow("MonsterTab/Prop/LayerSelector")); + CEGUI::Combobox* layerSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("MonsterTab/Prop/LayerSelector")); layerSelector->addItem(new CEGUI::ListboxTextItem("Normal")); layerSelector->addItem(new CEGUI::ListboxTextItem("Base")); layerSelector->addItem(new CEGUI::ListboxTextItem("Air")); @@ -49,19 +50,19 @@ layerSelector->subscribeEvent(CEGUI::Combobox::EventListSelectionAccepted, CEGUI::Event::Subscriber(&MonsterEditor::onMonsterModified, this)); */ - CEGUI::PushButton* xmlsubmitButton = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("MonsterTab/XML/SubmitButton")); + CEGUI::PushButton* xmlsubmitButton = static_cast<CEGUI::PushButton*>(CEGUIUtility::getWindow("MonsterTab/XML/SubmitButton")); xmlsubmitButton->subscribeEvent(CEGUI::PushButton::EventClicked, CEGUI::Event::Subscriber(&MonsterEditor::onMonsterXMLModified, this)); - CEGUI::PushButton* createFOButton = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("MonsterTab/XML/CreateButton")); + CEGUI::PushButton* createFOButton = static_cast<CEGUI::PushButton*>(CEGUIUtility::getWindow("MonsterTab/XML/CreateButton")); createFOButton->subscribeEvent(CEGUI::PushButton::EventClicked, CEGUI::Event::Subscriber(&MonsterEditor::onMonsterCreate, this)); - CEGUI::PushButton* delallFOButton = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("MonsterTab/Create/DelAllButton")); + CEGUI::PushButton* delallFOButton = static_cast<CEGUI::PushButton*>(CEGUIUtility::getWindow("MonsterTab/Create/DelAllButton")); delallFOButton->subscribeEvent(CEGUI::PushButton::EventClicked, CEGUI::Event::Subscriber(&MonsterEditor::onDelAllObjects, this)); - CEGUI::PushButton* getplayerButton = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("MonsterTab/Create/GetPlPosButton")); + CEGUI::PushButton* getplayerButton = static_cast<CEGUI::PushButton*>(CEGUIUtility::getWindow("MonsterTab/Create/GetPlPosButton")); getplayerButton->subscribeEvent(CEGUI::PushButton::EventClicked, CEGUI::Event::Subscriber(&MonsterEditor::onGetPlayerPosition, this)); - CEGUI::PushButton* copyfoButton = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("MonsterTab/Properties/CopyDataButton")); + CEGUI::PushButton* copyfoButton = static_cast<CEGUI::PushButton*>(CEGUIUtility::getWindow("MonsterTab/Properties/CopyDataButton")); copyfoButton->subscribeEvent(CEGUI::PushButton::EventClicked, CEGUI::Event::Subscriber(&MonsterEditor::onCopyData, this)); // init the internal data @@ -102,7 +103,7 @@ { CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::Combobox* copyfoSelector = static_cast<CEGUI::Combobox*>(win_mgr.getWindow("MonsterTab/Properties/CopyDataBox")); + CEGUI::Combobox* copyfoSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("MonsterTab/Properties/CopyDataBox")); // Fill list of all Monsters const std::map<GameObject::Subtype, MonsterBasicData*>& all_fo = ObjectFactory::getAllMonsterData(); @@ -124,7 +125,7 @@ TiXmlPrinter printer; m_monster_xml.Accept(&printer); - CEGUI::MultiLineEditbox* editor = static_cast<CEGUI::MultiLineEditbox*>(win_mgr.getWindow("MonsterTab/XML/MonsterXMLEditbox")); + CEGUI::MultiLineEditbox* editor = static_cast<CEGUI::MultiLineEditbox*>(CEGUIUtility::getWindow("MonsterTab/XML/MonsterXMLEditbox")); editor->setText(printer.CStr()); } @@ -134,9 +135,9 @@ CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); /* - CEGUI::Combobox* layerSelector = static_cast<CEGUI::Combobox*>(win_mgr.getWindow("MonsterTab/Prop/LayerSelector")); + CEGUI::Combobox* layerSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("MonsterTab/Prop/LayerSelector")); */ - CEGUI::Spinner* radiusSpinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("MonsterTab/Prop/RadiusSpinner")); + CEGUI::Spinner* radiusSpinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("MonsterTab/Prop/RadiusSpinner")); // adjust the spinner values radiusSpinner->setCurrentValue(m_edited_monster.m_radius); @@ -170,9 +171,9 @@ CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::Spinner* radiusSpinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("MonsterTab/Prop/RadiusSpinner")); + CEGUI::Spinner* radiusSpinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("MonsterTab/Prop/RadiusSpinner")); - //CEGUI::Combobox* layerSelector = static_cast<CEGUI::Combobox*>(win_mgr.getWindow("MonsterTab/Prop/LayerSelector")); + //CEGUI::Combobox* layerSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("MonsterTab/Prop/LayerSelector")); m_edited_monster.m_radius = radiusSpinner->getCurrentValue(); @@ -197,7 +198,7 @@ bool MonsterEditor::onMonsterXMLModified(const CEGUI::EventArgs& evt) { CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::MultiLineEditbox* editor = static_cast<CEGUI::MultiLineEditbox*>(win_mgr.getWindow("MonsterTab/XML/MonsterXMLEditbox")); + CEGUI::MultiLineEditbox* editor = static_cast<CEGUI::MultiLineEditbox*>(CEGUIUtility::getWindow("MonsterTab/XML/MonsterXMLEditbox")); // Parse the editor text to XML // use temporary XML document for recovering from errors
--- a/src/gui/contenteditor/renderinfoeditor.cpp Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/contenteditor/renderinfoeditor.cpp Wed Mar 26 23:39:02 2014 +0200 @@ -22,6 +22,10 @@ #include <OgreHardwarePixelBuffer.h> +// Utility for CEGUI cross-version compatibility +// TODO(Augustin Preda, 2014.03.25): remove when no longer needed. +#include "ceguiutility.h" + void RenderInfoEditor::init(CEGUI::Window* parent) { ContentEditorTab::init(parent); @@ -32,8 +36,8 @@ CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); // add parts to the mesh selectors - CEGUI::Combobox* selector = static_cast<CEGUI::Combobox*>(CEGUI::WindowManager::getSingleton().getWindow("RITab/BM/MeshSelector")); - CEGUI::Combobox* subSelector = static_cast<CEGUI::Combobox*>(CEGUI::WindowManager::getSingleton().getWindow("RITab/SubMesh/Selector")); + CEGUI::Combobox* selector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("RITab/BM/MeshSelector")); + CEGUI::Combobox* subSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("RITab/SubMesh/Selector")); Ogre::FileInfoListPtr files; Ogre::FileInfoList::iterator it; @@ -61,7 +65,7 @@ } catch (Ogre::Exception& e) { - DEBUG("failed with exception %s",e.what()); + SW_DEBUG("failed with exception %s",e.what()); } } @@ -69,30 +73,30 @@ selector->subscribeEvent(CEGUI::Combobox::EventListSelectionAccepted, CEGUI::Event::Subscriber(&RenderInfoEditor::onMeshSelected, this)); subSelector->subscribeEvent(CEGUI::Combobox::EventListSelectionAccepted, CEGUI::Event::Subscriber(&RenderInfoEditor::onSubMeshSelected, this)); - CEGUI::PushButton* addSubmeshbutton = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("RITab/SubMesh/AddSubMeshButton")); + CEGUI::PushButton* addSubmeshbutton = static_cast<CEGUI::PushButton*>(CEGUIUtility::getWindow("RITab/SubMesh/AddSubMeshButton")); addSubmeshbutton->subscribeEvent(CEGUI::PushButton::EventClicked, CEGUI::Event::Subscriber(&RenderInfoEditor::onSubMeshAdded, this)); - CEGUI::PushButton* submitRIXMLbutton = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("RITab/XML/SubmitButton")); + CEGUI::PushButton* submitRIXMLbutton = static_cast<CEGUI::PushButton*>(CEGUIUtility::getWindow("RITab/XML/SubmitButton")); submitRIXMLbutton->subscribeEvent(CEGUI::PushButton::EventClicked, CEGUI::Event::Subscriber(&RenderInfoEditor::onRenderinfoXMLModified, this)); - CEGUI::PushButton* delSubmeshbutton = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("RITab/SubMesh/DelSubMeshButton")); + CEGUI::PushButton* delSubmeshbutton = static_cast<CEGUI::PushButton*>(CEGUIUtility::getWindow("RITab/SubMesh/DelSubMeshButton")); delSubmeshbutton->subscribeEvent(CEGUI::PushButton::EventClicked, CEGUI::Event::Subscriber(&RenderInfoEditor::onSubMeshDeleted, this)); - CEGUI::Spinner* rotXspinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("RITab/SM/SMRotateX")); - CEGUI::Spinner* rotYspinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("RITab/SM/SMRotateY")); - CEGUI::Spinner* rotZspinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("RITab/SM/SMRotateZ")); + CEGUI::Spinner* rotXspinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("RITab/SM/SMRotateX")); + CEGUI::Spinner* rotYspinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("RITab/SM/SMRotateY")); + CEGUI::Spinner* rotZspinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("RITab/SM/SMRotateZ")); - CEGUI::Spinner* posXspinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("RITab/SM/SMOffsetX")); - CEGUI::Spinner* posYspinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("RITab/SM/SMOffsetY")); - CEGUI::Spinner* posZspinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("RITab/SM/SMOffsetZ")); + CEGUI::Spinner* posXspinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("RITab/SM/SMOffsetX")); + CEGUI::Spinner* posYspinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("RITab/SM/SMOffsetY")); + CEGUI::Spinner* posZspinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("RITab/SM/SMOffsetZ")); - CEGUI::Spinner* scalespinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("RITab/SM/SMScale")); + CEGUI::Spinner* scalespinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("RITab/SM/SMScale")); - CEGUI::Combobox* objSelector = static_cast<CEGUI::Combobox*>(win_mgr.getWindow("RITab/SubMesh/EditSMSelector")); - CEGUI::Combobox* boneobjSelector = static_cast<CEGUI::Combobox*>(win_mgr.getWindow("RITab/SubMesh/AttachMeshSelector")); - CEGUI::Combobox* boneSelector = static_cast<CEGUI::Combobox*>(win_mgr.getWindow("RITab/SubMesh/BoneSelector")); - CEGUI::Checkbox* attachCheckbox = static_cast<CEGUI::Checkbox*>(win_mgr.getWindow("RITab/SM/AttachSMCheckbox")); + CEGUI::Combobox* objSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("RITab/SubMesh/EditSMSelector")); + CEGUI::Combobox* boneobjSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("RITab/SubMesh/AttachMeshSelector")); + CEGUI::Combobox* boneSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("RITab/SubMesh/BoneSelector")); + CEGUIUtility::ToggleButton* attachCheckbox = static_cast<CEGUIUtility::ToggleButton*>(CEGUIUtility::getWindow("RITab/SM/AttachSMCheckbox")); objSelector->subscribeEvent(CEGUI::Combobox::EventListSelectionAccepted, CEGUI::Event::Subscriber(&RenderInfoEditor::onSubObjectSelected, this)); @@ -109,7 +113,7 @@ boneobjSelector->subscribeEvent(CEGUI::Combobox::EventListSelectionAccepted, CEGUI::Event::Subscriber(&RenderInfoEditor::onSubMeshModified, this)); boneSelector->subscribeEvent(CEGUI::Combobox::EventListSelectionAccepted, CEGUI::Event::Subscriber(&RenderInfoEditor::onSubMeshModified, this)); - attachCheckbox->subscribeEvent(CEGUI::Checkbox::EventCheckStateChanged, CEGUI::Event::Subscriber(&RenderInfoEditor::onSubMeshModified, this)); + attachCheckbox->subscribeEvent(CEGUIUtility::EventToggleButtonStateChanged(), CEGUI::Event::Subscriber(&RenderInfoEditor::onSubMeshModified, this)); // init the internal data TiXmlElement * renderinfo_root = new TiXmlElement("RenderInfo"); @@ -246,20 +250,20 @@ { CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::Spinner* rotXspinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("RITab/SM/SMRotateX")); - CEGUI::Spinner* rotYspinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("RITab/SM/SMRotateY")); - CEGUI::Spinner* rotZspinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("RITab/SM/SMRotateZ")); + CEGUI::Spinner* rotXspinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("RITab/SM/SMRotateX")); + CEGUI::Spinner* rotYspinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("RITab/SM/SMRotateY")); + CEGUI::Spinner* rotZspinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("RITab/SM/SMRotateZ")); - CEGUI::Spinner* posXspinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("RITab/SM/SMOffsetX")); - CEGUI::Spinner* posYspinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("RITab/SM/SMOffsetY")); - CEGUI::Spinner* posZspinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("RITab/SM/SMOffsetZ")); + CEGUI::Spinner* posXspinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("RITab/SM/SMOffsetX")); + CEGUI::Spinner* posYspinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("RITab/SM/SMOffsetY")); + CEGUI::Spinner* posZspinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("RITab/SM/SMOffsetZ")); - CEGUI::Spinner* scalespinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("RITab/SM/SMScale")); + CEGUI::Spinner* scalespinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("RITab/SM/SMScale")); - CEGUI::Combobox* objSelector = static_cast<CEGUI::Combobox*>(win_mgr.getWindow("RITab/SubMesh/EditSMSelector")); - CEGUI::Combobox* boneobjSelector = static_cast<CEGUI::Combobox*>(win_mgr.getWindow("RITab/SubMesh/AttachMeshSelector")); - CEGUI::Combobox* boneSelector = static_cast<CEGUI::Combobox*>(win_mgr.getWindow("RITab/SubMesh/BoneSelector")); - CEGUI::Checkbox* attachCheckbox = static_cast<CEGUI::Checkbox*>(win_mgr.getWindow("RITab/SM/AttachSMCheckbox")); + CEGUI::Combobox* objSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("RITab/SubMesh/EditSMSelector")); + CEGUI::Combobox* boneobjSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("RITab/SubMesh/AttachMeshSelector")); + CEGUI::Combobox* boneSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("RITab/SubMesh/BoneSelector")); + CEGUIUtility::ToggleButton* attachCheckbox = static_cast<CEGUIUtility::ToggleButton*>(CEGUIUtility::getWindow("RITab/SM/AttachSMCheckbox")); if (objectname == "") objectname = objSelector->getText().c_str(); @@ -427,8 +431,8 @@ void RenderInfoEditor::updateBoneList() { CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::Combobox* boneSelector = static_cast<CEGUI::Combobox*>(win_mgr.getWindow("RITab/SubMesh/BoneSelector")); - CEGUI::Combobox* boneobjSelector = static_cast<CEGUI::Combobox*>(win_mgr.getWindow("RITab/SubMesh/AttachMeshSelector")); + CEGUI::Combobox* boneSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("RITab/SubMesh/BoneSelector")); + CEGUI::Combobox* boneobjSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("RITab/SubMesh/AttachMeshSelector")); // get the selected object and the underlying RenderInfo data structure std::string boneobj = boneobjSelector->getText().c_str(); @@ -502,7 +506,7 @@ TiXmlPrinter printer; m_renderinfo_xml.Accept(&printer); - CEGUI::MultiLineEditbox* editor = static_cast<CEGUI::MultiLineEditbox*>(win_mgr.getWindow("RITab/XML/RIXMLEditbox")); + CEGUI::MultiLineEditbox* editor = static_cast<CEGUI::MultiLineEditbox*>(CEGUIUtility::getWindow("RITab/XML/RIXMLEditbox")); editor->setText(printer.CStr()); } @@ -567,7 +571,7 @@ { // place the required mesh in the editor scene std::string meshname = item->getText().c_str(); - DEBUG("selected mesh %s",meshname.c_str()); + SW_DEBUG("selected mesh %s",meshname.c_str()); updateSubmeshEditor(meshname, false); } @@ -578,8 +582,8 @@ bool RenderInfoEditor::onSubMeshSelected(const CEGUI::EventArgs& evt) { //CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::Combobox* subSelector = static_cast<CEGUI::Combobox*>(CEGUI::WindowManager::getSingleton().getWindow("RITab/SubMesh/Selector")); - CEGUI::Editbox* subMeshNameBox = static_cast<CEGUI::Editbox*>(CEGUI::WindowManager::getSingleton().getWindow("RITab/SM/SMNameEditbox")); + CEGUI::Combobox* subSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("RITab/SubMesh/Selector")); + CEGUI::Editbox* subMeshNameBox = static_cast<CEGUI::Editbox*>(CEGUIUtility::getWindow("RITab/SM/SMNameEditbox")); CEGUI::ListboxItem* item = subSelector->getSelectedItem(); if (item != 0) @@ -600,8 +604,8 @@ bool RenderInfoEditor::onSubMeshAdded(const CEGUI::EventArgs& evt) { //CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::Combobox* subSelector = static_cast<CEGUI::Combobox*>(CEGUI::WindowManager::getSingleton().getWindow("RITab/SubMesh/Selector")); - CEGUI::Editbox* subMeshNameBox = static_cast<CEGUI::Editbox*>(CEGUI::WindowManager::getSingleton().getWindow("RITab/SM/SMNameEditbox")); + CEGUI::Combobox* subSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("RITab/SubMesh/Selector")); + CEGUI::Editbox* subMeshNameBox = static_cast<CEGUI::Editbox*>(CEGUIUtility::getWindow("RITab/SM/SMNameEditbox")); CEGUI::ListboxItem* item = subSelector->getSelectedItem(); if (item != 0) @@ -657,20 +661,20 @@ CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); // the the GUI parts - CEGUI::Spinner* rotXspinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("RITab/SM/SMRotateX")); - CEGUI::Spinner* rotYspinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("RITab/SM/SMRotateY")); - CEGUI::Spinner* rotZspinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("RITab/SM/SMRotateZ")); + CEGUI::Spinner* rotXspinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("RITab/SM/SMRotateX")); + CEGUI::Spinner* rotYspinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("RITab/SM/SMRotateY")); + CEGUI::Spinner* rotZspinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("RITab/SM/SMRotateZ")); - CEGUI::Spinner* posXspinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("RITab/SM/SMOffsetX")); - CEGUI::Spinner* posYspinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("RITab/SM/SMOffsetY")); - CEGUI::Spinner* posZspinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("RITab/SM/SMOffsetZ")); + CEGUI::Spinner* posXspinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("RITab/SM/SMOffsetX")); + CEGUI::Spinner* posYspinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("RITab/SM/SMOffsetY")); + CEGUI::Spinner* posZspinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("RITab/SM/SMOffsetZ")); - CEGUI::Spinner* scalespinner = static_cast<CEGUI::Spinner*>(win_mgr.getWindow("RITab/SM/SMScale")); + CEGUI::Spinner* scalespinner = static_cast<CEGUI::Spinner*>(CEGUIUtility::getWindow("RITab/SM/SMScale")); - CEGUI::Combobox* objSelector = static_cast<CEGUI::Combobox*>(win_mgr.getWindow("RITab/SubMesh/EditSMSelector")); - CEGUI::Combobox* boneobjSelector = static_cast<CEGUI::Combobox*>(win_mgr.getWindow("RITab/SubMesh/AttachMeshSelector")); - CEGUI::Combobox* boneSelector = static_cast<CEGUI::Combobox*>(win_mgr.getWindow("RITab/SubMesh/BoneSelector")); - CEGUI::Checkbox* attachCheckbox = static_cast<CEGUI::Checkbox*>(win_mgr.getWindow("RITab/SM/AttachSMCheckbox")); + CEGUI::Combobox* objSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("RITab/SubMesh/EditSMSelector")); + CEGUI::Combobox* boneobjSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("RITab/SubMesh/AttachMeshSelector")); + CEGUI::Combobox* boneSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("RITab/SubMesh/BoneSelector")); + CEGUIUtility::ToggleButton* attachCheckbox = static_cast<CEGUIUtility::ToggleButton*>(CEGUIUtility::getWindow("RITab/SM/AttachSMCheckbox")); // get the MovableObjectInfo CEGUI::ListboxItem* item = objSelector->getSelectedItem(); @@ -733,7 +737,7 @@ return true; CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::Combobox* objSelector = static_cast<CEGUI::Combobox*>(win_mgr.getWindow("RITab/SubMesh/EditSMSelector")); + CEGUI::Combobox* objSelector = static_cast<CEGUI::Combobox*>(CEGUIUtility::getWindow("RITab/SubMesh/EditSMSelector")); // get the MovableObjectInfo CEGUI::ListboxItem* item = objSelector->getSelectedItem(); @@ -754,7 +758,7 @@ bool RenderInfoEditor::onRenderinfoXMLModified(const CEGUI::EventArgs& evt) { CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); - CEGUI::MultiLineEditbox* editor = static_cast<CEGUI::MultiLineEditbox*>(win_mgr.getWindow("RITab/XML/RIXMLEditbox")); + CEGUI::MultiLineEditbox* editor = static_cast<CEGUI::MultiLineEditbox*>(CEGUIUtility::getWindow("RITab/XML/RIXMLEditbox")); // Parse the editor text to XML // use temporary XML document for recovering from errors @@ -811,8 +815,8 @@ pos++; } - editor->setCaratIndex(pos); - editor->ensureCaratIsVisible(); + editor->setCaretIndex(pos); + editor->ensureCaretIsVisible(); editor->activate(); } return true;
--- a/src/gui/debugpanel/benchmarktab.cpp Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/debugpanel/benchmarktab.cpp Wed Mar 26 23:39:02 2014 +0200 @@ -13,13 +13,21 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ +// Utility for CEGUI cross-version compatibility +#include "ceguiutility.h" + #include "benchmarktab.h" #include "sumwarshelper.h" #include "Ogre.h" #include "OgrePlatformInformation.h" +#ifdef CEGUI_07 #include "CEGUI/CEGUIWindowManager.h" +#else +#include "CEGUI/WindowManager.h" +#endif + #include "CEGUI/CEGUI.h" #include <eventsystem.h> @@ -36,13 +44,13 @@ { setText("Benchmark"); - m_tabLayout = CEGUI::WindowManager::getSingleton().loadWindowLayout("benchmarktab.layout"); + m_tabLayout = CEGUIUtility::loadLayoutFromFile ("benchmarktab.layout"); m_tabLayout->setPosition(UVector2(UDim(0.0f, 0.0f), UDim(0.0f, 0.0f))); - m_tabLayout->setSize(UVector2(UDim(1.0f, 0.0f), UDim(1.0f, 0.0f))); - this->addChildWindow(m_tabLayout); + CEGUIUtility::setWidgetSizeRel (m_tabLayout, 1.0f, 1.0f); + CEGUIUtility::addChildWidget(this, m_tabLayout); - m_CapsBox = static_cast<CEGUI::MultiLineEditbox*>(m_tabLayout->getChild("BenchmarkTab/ResultsEditbox")); - m_startBenchmarkButton = static_cast<CEGUI::PushButton*>(m_tabLayout->getChild("BenchmarkTab/StartButton")); + m_CapsBox = static_cast<CEGUI::MultiLineEditbox*>(m_tabLayout->getChild("ResultsEditbox")); + m_startBenchmarkButton = static_cast<CEGUI::PushButton*>(m_tabLayout->getChild("StartButton")); m_ogreRoot = Ogre::Root::getSingletonPtr();
--- a/src/gui/debugpanel/benchmarktab.h Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/debugpanel/benchmarktab.h Wed Mar 26 23:39:02 2014 +0200 @@ -17,7 +17,13 @@ #define BENCHMARKTAB_H #include <debugtab.h> + +#ifdef CEGUI_07 #include <CEGUI/CEGUIWindow.h> +#else +#include "CEGUI/Window.h" +#endif + #include "OgreLog.h" namespace Ogre
--- a/src/gui/debugpanel/debugcameratab.cpp Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/debugpanel/debugcameratab.cpp Wed Mar 26 23:39:02 2014 +0200 @@ -13,10 +13,19 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ +// Utility for CEGUI cross-version compatibility +#include "ceguiutility.h" + #include "debugcameratab.h" #include "CEGUI/CEGUI.h" #include "OgreRoot.h" -#include "CEGUI/RendererModules/Ogre/CEGUIOgreRenderer.h" + +#ifdef CEGUI_07 +#include "CEGUI/RendererModules/Ogre/CEGUIOgreRenderer.h" +#else +#include "CEGUI/RendererModules/Ogre/Renderer.h" +#endif + #include <OgreHardwarePixelBuffer.h> #include <OISInputManager.h> #include <OISMouse.h> @@ -29,36 +38,43 @@ { setText ( "Camera" ); - CEGUI::TabControl* camtabs = ( CEGUI::TabControl* ) WindowManager::getSingleton().createWindow ( "TaharezLook/TabControl", "DebugCameraTabTabs" ); + CEGUI::TabControl* camtabs = static_cast<CEGUI::TabControl*>(WindowManager::getSingleton().createWindow( + "TaharezLook/TabControl", "DebugCameraTabTabs" )); + camtabs->setPosition ( UVector2 ( UDim ( 0.0f, 0.0f ), UDim ( 0.0f, 0.0f ) ) ); - camtabs->setSize ( UVector2 ( UDim ( 1.0f, 0.0f ), UDim ( 1.0f, 0.0f ) ) ); - addChildWindow ( camtabs ); + CEGUIUtility::setWidgetSizeRel (camtabs, 1.0f, 1.0f); + CEGUIUtility::addChildWidget (this, camtabs); - CEGUI::Window* playerCamTab = ( CEGUI::DefaultWindow* ) WindowManager::getSingleton().createWindow ( "TaharezLook/TabContentPane", "DebugCameraTab/PlayerCamOptions" ); + CEGUI::Window* playerCamTab = static_cast<CEGUI::DefaultWindow*>(WindowManager::getSingleton().createWindow( + "TaharezLook/TabContentPane", "PlayerCamOptions")); + playerCamTab->setText ( "PlayerCam Options" ); - CEGUI::Combobox* cb = ( CEGUI::Combobox* ) WindowManager::getSingleton().createWindow ( "TaharezLook/Combobox", "DebugCameraTab/PlayerCamOptions/ViewModes" ); + CEGUI::Combobox* cb = ( CEGUI::Combobox* ) WindowManager::getSingleton().createWindow ( "TaharezLook/Combobox", "ViewModes" ); cb->addItem ( new ListboxTextItem ( "Solid" ) ); cb->addItem ( new ListboxTextItem ( "Wireframe" ) ); cb->addItem ( new ListboxTextItem ( "Point" ) ); cb->setPosition ( UVector2 ( UDim ( 0.05f, 0.0f ), UDim ( 0.05f, 0.0f ) ) ); - cb->setSize ( UVector2 ( UDim ( 0.4f, 0.0f ), UDim ( 1.0f, 0.0f ) ) ); + CEGUIUtility::setWidgetSizeRel (cb, 0.4f, 1.0f); cb->subscribeEvent ( CEGUI::Combobox::EventListSelectionAccepted, CEGUI::Event::Subscriber ( &DebugCameraTab::onPlayerCameraModeChanged, this ) ); - playerCamTab->addChildWindow ( cb ); + CEGUIUtility::addChildWidget (playerCamTab, cb); + camtabs->addTab ( playerCamTab ); setupCamera(); - CEGUI::Window* debugCamTab = ( CEGUI::DefaultWindow* ) WindowManager::getSingleton().createWindow ( "TaharezLook/TabContentPane", "DebugCameraTab/DebugCamViewTab" ); + CEGUI::Window* debugCamTab = ( CEGUI::DefaultWindow* ) WindowManager::getSingleton().createWindow ( "TaharezLook/TabContentPane", "DebugCamViewTab" ); debugCamTab->setText ( "DebugCam" ); camtabs->addTab ( debugCamTab ); - CEGUI::Window *dcv = WindowManager::getSingleton().createWindow ( "TaharezLook/StaticImage", "DebugCameraTab/DebugCamView" ); + CEGUI::Window *dcv = WindowManager::getSingleton().createWindow ( "TaharezLook/StaticImage", "DebugCamView" ); dcv->setPosition ( UVector2 ( UDim ( 0.05f, 0.0f ), UDim ( 0.05f, 0.0f ) ) ); - dcv->setSize ( UVector2 ( UDim ( 0.9f, 0.0f ), UDim ( 0.9f, 0.0f ) ) ); - dcv->setProperty ( "Image", "set:debug_imageset image:debugCam_img" ); + CEGUIUtility::setWidgetSizeRel (dcv, 0.9f, 0.9f); + + CEGUI::String debug_camera_image_name("debugCam_img"); + dcv->setProperty ("Image", debug_camera_image_name); // prev: "set:debug_imageset image:debugCam_img" dcv->subscribeEvent ( CEGUI::Window::EventMouseButtonDown, CEGUI::Event::Subscriber ( &DebugCameraTab::onDebugWindowMouseDown, this ) ); - dcv->subscribeEvent ( CEGUI::Window::EventMouseLeaves, CEGUI::Event::Subscriber ( &DebugCameraTab::onDebugWindowMouseUp, this ) ); + dcv->subscribeEvent ( CEGUIUtility::EventMouseLeavesWindowArea(), CEGUI::Event::Subscriber ( &DebugCameraTab::onDebugWindowMouseUp, this ) ); dcv->subscribeEvent ( CEGUI::Window::EventMouseButtonUp, CEGUI::Event::Subscriber ( &DebugCameraTab::onDebugWindowMouseUp, this ) ); - debugCamTab->addChildWindow ( dcv ); + CEGUIUtility::addChildWidget (debugCamTab, dcv); m_leftMouseDown = m_rightMouseDown = false; } @@ -70,7 +86,8 @@ bool DebugCameraTab::onPlayerCameraModeChanged ( const CEGUI::EventArgs& evt ) { - CEGUI::Combobox* cbo = static_cast<CEGUI::Combobox*> ( CEGUI::WindowManager::getSingleton().getWindow ( "DebugCameraTab/PlayerCamOptions/ViewModes" ) ); + CEGUI::Combobox* cbo = static_cast<CEGUI::Combobox*> ( + CEGUIUtility::getWindow("DebugCameraTab/PlayerCamOptions/ViewModes")); CEGUI::String txt = cbo->getSelectedItem()->getText(); Ogre::Camera *cam = Ogre::Root::getSingleton().getSceneManager ( "DefaultSceneManager" )->getCamera ( "camera" ); @@ -131,15 +148,40 @@ editor_view->setBackgroundColour ( Ogre::ColourValue ( 0,0,0,1.0 ) ); editor_rt->update(); + // get the OgreRenderer from CEGUI and create a CEGUI texture from the Ogre texture + CEGUI::OgreRenderer* renderer_ptr = static_cast<CEGUI::OgreRenderer*>(CEGUI::System::getSingleton().getRenderer()); + CEGUI::String imageName("debugCam_img"); + // create a CEGUI Image from the Texture - CEGUI::Texture& debug_ceguiTex = static_cast<CEGUI::OgreRenderer*> ( CEGUI::System::getSingleton().getRenderer() )->createTexture ( debug_texture ); +#ifdef CEGUI_07 + CEGUI::Texture& debug_cegui_texture = renderer_ptr->createTexture (debug_texture); - CEGUI::Imageset& editor_textureImageSet = CEGUI::ImagesetManager::getSingleton().create ( "debug_imageset", debug_ceguiTex ); + CEGUI::Imageset& editor_textureImageSet = CEGUI::ImagesetManager::getSingleton().create ( "debug_imageset", debug_cegui_texture ); - editor_textureImageSet.defineImage ( "debugCam_img", - CEGUI::Point ( 0.0f, 0.0f ), - CEGUI::Size ( debug_ceguiTex.getSize().d_width, debug_ceguiTex.getSize().d_height ), - CEGUI::Point ( 0.0f, 0.0f ) ); + editor_textureImageSet.defineImage( + imageName, + CEGUI::Point ( 0.0f, 0.0f ), + CEGUI::Size ( debug_cegui_texture.getSize().d_width, debug_cegui_texture.getSize().d_height ), + CEGUI::Point ( 0.0f, 0.0f ) ); +#else + CEGUI::Texture &debug_cegui_texture = renderer_ptr->createTexture(debug_texture->getName(), debug_texture); + { + + CEGUI::TextureTarget* d_textureTarget; + CEGUI::BasicImage* d_textureTargetImage; + d_textureTarget = renderer_ptr->createTextureTarget(); + d_textureTargetImage = static_cast<CEGUI::BasicImage*>(&CEGUI::ImageManager::getSingleton().create("BasicImage", imageName)); + d_textureTargetImage->setTexture(&debug_cegui_texture); + + d_textureTargetImage->setArea( + CEGUI::Rectf( + 0, + 0, + debug_cegui_texture.getSize().d_width, + debug_cegui_texture.getSize ().d_height)); + } + +#endif }
--- a/src/gui/debugpanel/debugcameratab.h Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/debugpanel/debugcameratab.h Wed Mar 26 23:39:02 2014 +0200 @@ -17,7 +17,13 @@ #define DEBUGCAMERA_H #include "debugtab.h" -#include "CEGUI/CEGUIWindow.h" + +#ifdef CEGUI_07 +#include <CEGUI/CEGUIWindow.h> +#else +#include "CEGUI/Window.h" +#endif + #include "OgreSceneNode.h" class DebugCameraTab : public CEGUI::Window, public DebugTab
--- a/src/gui/debugpanel/debugpanel.cpp Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/debugpanel/debugpanel.cpp Wed Mar 26 23:39:02 2014 +0200 @@ -20,10 +20,17 @@ #include "iconeditortab.h" #include "benchmarktab.h" #include "contenttab.h" -//#include "reloadtab.h" + +// TODO(Augustin Preda, 2014.03.25): re-enable when functionality can be added. +// #include "reloadtab.h" + #include "OgreRoot.h" #include "config.h" +// Utility for CEGUI cross-version compatibility +// TODO(Augustin Preda, 2014.03.25): remove when no longer needed. +#include "ceguiutility.h" + using namespace CEGUI; template<> DebugPanel* Ogre::Singleton<DebugPanel>::SUMWARS_OGRE_SINGLETON = 0; @@ -32,7 +39,7 @@ { m_guiSystem = System::getSingletonPtr(); m_winManager = WindowManager::getSingletonPtr(); - m_gameScreen = m_winManager->getWindow("GameScreen"); + m_gameScreen = CEGUIUtility::getWindow("GameScreen"); m_lastVisibilitySwitch = 0; createPanel(visible); } @@ -51,49 +58,54 @@ { m_rootWindow = m_winManager->createWindow("TaharezLook/FrameWindow", "DebugPanel"); m_rootWindow->setPosition(UVector2(UDim(0.1f, 0.0f), UDim(0.1f, 0.0f))); - m_rootWindow->setSize(UVector2(UDim(0.6f, 0.0f), UDim(0.6f, 0.0f))); + CEGUIUtility::setWidgetSizeRel (m_rootWindow, 0.6f, 0.6f); m_rootWindow->setText((CEGUI::utf8*)"Debug Panel"); - m_gameScreen->addChildWindow(m_rootWindow); + CEGUIUtility::addChildWidget(m_gameScreen, m_rootWindow); m_rootWindow->subscribeEvent(CEGUI::FrameWindow::EventCloseClicked, Event::Subscriber(&DebugPanel::handleCloseWindow, this)); m_tabControl = static_cast<TabControl*>(m_winManager->createWindow("TaharezLook/TabControl", "DebugPanelTabControl")); m_tabControl->setPosition(UVector2(UDim(0.03f, 0.0f), UDim(0.06f, 0.0f))); - m_tabControl->setSize(UVector2(UDim(0.95f, 0.0f), UDim(0.9f, 0.0f))); - m_rootWindow->addChildWindow(m_tabControl); + CEGUIUtility::setWidgetSizeRel (m_tabControl,0.95f, 0.9f); + CEGUIUtility::addChildWidget(m_gameScreen, m_tabControl); GuiDebugTab *guiTab = static_cast<GuiDebugTab*>(m_winManager->createWindow("GuiDebugTab", "GuiDebugTab")); guiTab->setPosition(UVector2(UDim(0.0f, 0.0f), UDim(0.0f, 0.0f))); - guiTab->setSize(UVector2(UDim(1.0f, 0.0f), UDim(1.0f, 0.0f))); + CEGUIUtility::setWidgetSizeRel (guiTab, 1.0f, 1.0f); addTabWindow("GuiDebugTab", guiTab); LuaScriptTab *luaTab = static_cast<LuaScriptTab*>(m_winManager->createWindow("LuaScriptTab", "LuaScriptTab")); luaTab->setPosition(UVector2(UDim(0.0f, 0.0f), UDim(0.0f, 0.0f))); - luaTab->setSize(UVector2(UDim(1.0f, 0.0f), UDim(1.0f, 0.0f))); + CEGUIUtility::setWidgetSizeRel (luaTab, 1.0f, 1.0f); addTabWindow("LuaScriptTab", luaTab); IconEditorTab *iconEdTab = static_cast<IconEditorTab*>(m_winManager->createWindow("IconEditorTab", "IconEditorTab")); iconEdTab->setPosition(UVector2(UDim(0.0f, 0.0f), UDim(0.0f, 0.0f))); - iconEdTab->setSize(UVector2(UDim(1.0f, 0.0f), UDim(1.0f, 0.0f))); + CEGUIUtility::setWidgetSizeRel (iconEdTab, 1.0f, 1.0f); addTabWindow("IconEditorTab", iconEdTab); BenchmarkTab *benchTab = static_cast<BenchmarkTab*>(m_winManager->createWindow("BenchmarkTab", "BenchmarkTab")); benchTab->setPosition(UVector2(UDim(0.0f, 0.0f), UDim(0.0f, 0.0f))); - benchTab->setSize(UVector2(UDim(1.0f, 0.0f), UDim(1.0f, 0.0f))); + CEGUIUtility::setWidgetSizeRel (benchTab, 1.0f, 1.0f); addTabWindow("BenchmarkTab", benchTab); DebugCameraTab *camTab = static_cast<DebugCameraTab*>(m_winManager->createWindow("DebugCamera", "DebugCamera")); camTab->setPosition(UVector2(UDim(0.0f, 0.0f), UDim(0.0f, 0.0f))); - camTab->setSize(UVector2(UDim(1.0f, 0.0f), UDim(1.0f, 0.0f))); + CEGUIUtility::setWidgetSizeRel (camTab, 1.0f, 1.0f); addTabWindow("DebugCamera", camTab); - /* not yet implemented + + // TODO(Augustin Preda, 2014.03.25): Think about implementing the Reload functionality. + /* ReloadTab *reloadTab = static_cast<ReloadTab*>(m_winManager->createWindow("ReloadTab", "ReloadTab")); reloadTab->setPosition(UVector2(UDim(0.0f, 0.0f), UDim(0.0f, 0.0f))); reloadTab->setSize(UVector2(UDim(1.0f, 0.0f), UDim(1.0f, 0.0f))); addTabWindow("ReloadTab", reloadTab); */ + if(!visible) + { m_rootWindow->setVisible(visible); + } } void DebugPanel::addTabWindow(std::string name, DebugTab* tab)
--- a/src/gui/debugpanel/debugtab.h Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/debugpanel/debugtab.h Wed Mar 26 23:39:02 2014 +0200 @@ -16,7 +16,11 @@ #ifndef DEBUGTAB_H #define DEBUGTAB_H +#ifdef CEGUI_07 #include <CEGUI/CEGUIString.h> +#else +#include "CEGUI/String.h" +#endif namespace OIS {
--- a/src/gui/debugpanel/filebrowser/filebrowser.cpp Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/debugpanel/filebrowser/filebrowser.cpp Wed Mar 26 23:39:02 2014 +0200 @@ -13,6 +13,9 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ +// Utility for CEGUI cross-version compatibility +#include "ceguiutility.h" + #include "filebrowser.h" #include "listitem.h" #include "logger.h" @@ -39,10 +42,10 @@ m_type = type; m_guiSystem = System::getSingletonPtr(); m_winManager = WindowManager::getSingletonPtr(); - m_gameScreen = m_winManager->getWindow("GameScreen"); + m_gameScreen = CEGUIUtility::getWindow("GameScreen"); - m_rootWindow = m_winManager->loadWindowLayout("filebrowser.layout"); - m_gameScreen->addChildWindow(m_rootWindow); + m_rootWindow = CEGUIUtility::loadLayoutFromFile ("filebrowser.layout"); + CEGUIUtility::addChildWidget (m_gameScreen, m_rootWindow); m_rootWindow->setVisible(visible); m_acceptBtn = static_cast<PushButton*>(m_rootWindow->getChild("Ok"));
--- a/src/gui/debugpanel/guidebugtab.cpp Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/debugpanel/guidebugtab.cpp Wed Mar 26 23:39:02 2014 +0200 @@ -13,6 +13,9 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ +// Utility for CEGUI cross-version compatibility +#include "ceguiutility.h" + #include "guidebugtab.h" #include "CEGUI/CEGUI.h" @@ -26,11 +29,11 @@ { setText("Gui"); - m_tabLayout = WindowManager::getSingleton().loadWindowLayout("guidebugtab.layout"); + m_tabLayout = CEGUIUtility::loadLayoutFromFile ("guidebugtab.layout"); m_tabLayout->setPosition(UVector2(UDim(0.0f, 0.0f), UDim(0.0f, 0.0f))); - m_tabLayout->setSize(UVector2(UDim(1.0f, 0.0f), UDim(1.0f, 0.0f))); + CEGUIUtility::setWidgetSizeRel(m_tabLayout, 1.0f, 1.0f); - this->addChildWindow(m_tabLayout); + CEGUIUtility::addChildWidget (this, m_tabLayout); } void GuiDebugTab::initialiseComponents(void ) @@ -40,22 +43,22 @@ void GuiDebugTab::update(OIS::Keyboard *keyboard, OIS::Mouse *mouse) { - CEGUI::Window *win = CEGUI::System::getSingleton().getWindowContainingMouse(); + CEGUI::Window *win = CEGUIUtility::getWindowContainingMouse(CEGUI::System::getSingletonPtr()); m_tabLayout->getChild("windowUnderMouseStaticText")->setText(win->getName()); m_tabLayout->getChild("typeStaticText")->setText(win->getType()); std::ostringstream floatStringHelper; - floatStringHelper << win->getSize().d_x.d_offset; + floatStringHelper << win->getSize().d_width.d_offset; m_tabLayout->getChild("xSizeLabel")->setText(floatStringHelper.str()); - floatStringHelper << win->getSize().d_y.d_offset; + floatStringHelper << win->getSize().d_height.d_offset; m_tabLayout->getChild("ySizeLabel")->setText(floatStringHelper.str()); m_tabLayout->getChild("contentsTextbox")->setText(win->getText()); } -void GuiDebugTab::onSized(CEGUI::WindowEventArgs& e) +void GuiDebugTab::onSized(CEGUI::ElementEventArgs& e) { CEGUI::Window::onSized(e); }
--- a/src/gui/debugpanel/guidebugtab.h Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/debugpanel/guidebugtab.h Wed Mar 26 23:39:02 2014 +0200 @@ -17,7 +17,12 @@ #define GUIDEBUGTAB_H #include "debugtab.h" -#include "CEGUI/CEGUIWindow.h" + +#ifdef CEGUI_07 +#include <CEGUI/CEGUIWindow.h> +#else +#include "CEGUI/Window.h" +#endif class GuiDebugTab : public CEGUI::Window, public DebugTab { @@ -29,7 +34,7 @@ virtual void initialiseComponents(void ); protected: - virtual void onSized(CEGUI::WindowEventArgs& e); + virtual void onSized(CEGUI::ElementEventArgs& e); private: CEGUI::Window *m_tabLayout;
--- a/src/gui/debugpanel/iconeditortab.cpp Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/debugpanel/iconeditortab.cpp Wed Mar 26 23:39:02 2014 +0200 @@ -13,6 +13,9 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ +// Utility for CEGUI cross-version compatibility +#include "ceguiutility.h" + #include "iconeditortab.h" #include "CEGUI/CEGUI.h" using namespace CEGUI; @@ -23,10 +26,10 @@ { setText("IconEd"); - CEGUI::Window *m_tabLayout = WindowManager::getSingleton().loadWindowLayout("iconedittab.layout"); + CEGUI::Window *m_tabLayout = CEGUIUtility::loadLayoutFromFile ("iconedittab.layout"); m_tabLayout->setPosition(UVector2(UDim(0.0f, 0.0f), UDim(0.0f, 0.0f))); - m_tabLayout->setSize(UVector2(UDim(1.0f, 0.0f), UDim(1.0f, 0.0f))); - this->addChildWindow(m_tabLayout); + CEGUIUtility::setWidgetSizeRel(m_tabLayout, 1.0f, 1.0f); + CEGUIUtility::addChildWidget (this, m_tabLayout); } @@ -35,7 +38,7 @@ } -void IconEditorTab::onSized(CEGUI::WindowEventArgs& e) +void IconEditorTab::onSized(CEGUI::ElementEventArgs& e) { CEGUI::Window::onSized(e); }
--- a/src/gui/debugpanel/iconeditortab.h Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/debugpanel/iconeditortab.h Wed Mar 26 23:39:02 2014 +0200 @@ -16,7 +16,12 @@ #ifndef ICONEDITORTAB_H #define ICONEDITORTAB_H +#ifdef CEGUI_07 #include <CEGUI/CEGUIWindow.h> +#else +#include "CEGUI/Window.h" +#endif + #include "debugtab.h" class IconEditorTab : public CEGUI::Window, public DebugTab @@ -26,7 +31,7 @@ virtual void update(OIS::Keyboard *keyboard, OIS::Mouse *mouse); protected: - virtual void onSized(CEGUI::WindowEventArgs& e); + virtual void onSized(CEGUI::ElementEventArgs& e); virtual void onTextChanged(CEGUI::WindowEventArgs& e); virtual void onMouseMove(CEGUI::MouseEventArgs& e); virtual void onMouseWheel(CEGUI::MouseEventArgs& e);
--- a/src/gui/debugpanel/luascripttab.cpp Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/debugpanel/luascripttab.cpp Wed Mar 26 23:39:02 2014 +0200 @@ -13,13 +13,15 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ +// Utility for CEGUI cross-version compatibility +#include "ceguiutility.h" + #include "luascripttab.h" #include "CEGUI/CEGUI.h" #include <iostream> #include "textfileeditwindow.h" #include "OgreString.h" -#include "ceguiutility.h" using namespace CEGUI; @@ -33,17 +35,17 @@ setText("Lua"); m_newFileCtr = 0; - m_tabLayout = WindowManager::getSingleton().loadWindowLayout("luascripttab.layout"); + m_tabLayout = CEGUIUtility::loadLayoutFromFile ("luascripttab.layout"); m_tabLayout->setPosition(UVector2(UDim(0.0f, 0.0f), UDim(0.0f, 0.0f))); - m_tabLayout->setSize(UVector2(UDim(1.0f, 0.0f), UDim(1.0f, 0.0f))); + CEGUIUtility::setWidgetSizeRel (m_tabLayout, 1.0f, 1.0f); - m_fileTabControl = static_cast<TabControl*>(m_tabLayout->getChild("luaScriptTab/FileTabControl")); - m_filePathEditBox = static_cast<Editbox*>(m_tabLayout->getChild("luaScriptTab/fileDirectoryEditBox")); + m_fileTabControl = static_cast<TabControl*>(m_tabLayout->getChild("FileTabControl")); + m_filePathEditBox = static_cast<Editbox*>(m_tabLayout->getChild("FileDirectoryEditBox")); m_filePathEditBox->setText("./data/lua/debug.lua"); createMenu(); - this->addChildWindow(m_tabLayout); + CEGUIUtility::addChildWidget (this, m_tabLayout); m_fileTabControl->subscribeEvent(TabControl::EventSelectionChanged, CEGUI::Event::Subscriber(&LuaScriptTab::handleTabChanged, this)); @@ -54,7 +56,7 @@ } -void LuaScriptTab::onSized(CEGUI::WindowEventArgs& e) +void LuaScriptTab::onSized(CEGUI::ElementEventArgs& e) { CEGUI::Window::onSized(e); } @@ -119,7 +121,8 @@ TextFileEditWindow *win = static_cast<TextFileEditWindow*>(WindowManager::getSingleton().createWindow("TextFileEditWindow")); m_fileTabControl->addTab(win); win->setPosition(UVector2(UDim(0.0f, 0.0f), UDim(0.0f, 0.0f))); - win->setSize(UVector2(UDim(1.0f, 0.0f), UDim(1.0f, 0.0f))); + CEGUIUtility::setWidgetSizeRel (win, 1.0f, 1.0f); + win->handleTextChanged(CEGUI::EventArgs()); m_newFileCtr++; return true; @@ -165,7 +168,7 @@ TextFileEditWindow *win = static_cast<TextFileEditWindow*>(WindowManager::getSingleton().createWindow("TextFileEditWindow")); m_fileTabControl->addTab(win); win->setPosition(UVector2(UDim(0.0f, 0.0f), UDim(0.0f, 0.0f))); - win->setSize(UVector2(UDim(1.0f, 0.0f), UDim(1.0f, 0.0f))); + CEGUIUtility::setWidgetSizeRel (win, 1.0f, 1.0f); win->load(m_fb->getCurrentSelected()); m_newFileCtr++; } @@ -188,13 +191,16 @@ void LuaScriptTab::createMenu() { - m_menubar = static_cast<CEGUI::Menubar*>(m_tabLayout->getChild("luaScriptTab/MenuBar")); + m_menubar = static_cast<CEGUI::Menubar*>(m_tabLayout->getChild("MenuBar")); MenuItem *fileItem = static_cast<MenuItem*>(WindowManager::getSingleton().createWindow (CEGUIUtility::getWidgetWithSkin (m_ceguiSkinName, "MenuItem"), "luaScriptTab/MenuBar/FileItem")); fileItem->setText("File"); m_menubar->addItem(fileItem); - PopupMenu *filePopup = static_cast<PopupMenu*>(WindowManager::getSingleton().createWindow (CEGUIUtility::getWidgetWithSkin (m_ceguiSkinName, "PopupMenu"), "luaScriptTab/MenuBar/FilePopup")); + PopupMenu *filePopup = static_cast<PopupMenu*>( + WindowManager::getSingleton().createWindow( + CEGUIUtility::getWidgetWithSkin(m_ceguiSkinName, "PopupMenu"), + "luaScriptTab/MenuBar/FilePopup")); MenuItem *it = static_cast<MenuItem*>(WindowManager::getSingleton().createWindow (CEGUIUtility::getWidgetWithSkin (m_ceguiSkinName, "MenuItem"), "luaScriptTab/MenuBar/FileItemNew")); it->setText("New");
--- a/src/gui/debugpanel/luascripttab.h Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/debugpanel/luascripttab.h Wed Mar 26 23:39:02 2014 +0200 @@ -16,7 +16,12 @@ #ifndef LUASCRIPTTAB_H #define LUASCRIPTTAB_H +#ifdef CEGUI_07 #include <CEGUI/CEGUIWindow.h> +#else +#include "CEGUI/Window.h" +#endif + #include "debugtab.h" #include "filebrowser/filebrowser.h" @@ -27,7 +32,7 @@ virtual void update(OIS::Keyboard *keyboard, OIS::Mouse *mouse); protected: - virtual void onSized(CEGUI::WindowEventArgs& e); + virtual void onSized(CEGUI::ElementEventArgs& e); virtual void onTextChanged(CEGUI::WindowEventArgs& e); virtual void onMouseMove(CEGUI::MouseEventArgs& e); virtual void onMouseWheel(CEGUI::MouseEventArgs& e);
--- a/src/gui/debugpanel/textfileeditwindow.cpp Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/debugpanel/textfileeditwindow.cpp Wed Mar 26 23:39:02 2014 +0200 @@ -13,6 +13,9 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ +// Utility for CEGUI cross-version compatibility +#include "ceguiutility.h" + #include "textfileeditwindow.h" #include "CEGUI/CEGUI.h" #include <iostream> @@ -38,8 +41,9 @@ ss << m_ceguiSkinName << "/MultiLineEditbox"; m_textEditBox = static_cast<MultiLineEditbox*>(WindowManager::getSingleton().createWindow(ss.str ().c_str (), name + "EditBox")); m_textEditBox->setPosition(UVector2(UDim(0.0f, 0.0f), UDim(0.0f, 0.0f))); - m_textEditBox->setSize(UVector2(UDim(1.0f, 0.0f), UDim(1.0f, 0.0f))); - addChildWindow(m_textEditBox); + CEGUIUtility::setWidgetSizeRel(m_textEditBox, 1.0f, 1.0f); + CEGUIUtility::addChildWidget (this, m_textEditBox); + m_isDirty = false; m_fb = 0; @@ -169,23 +173,23 @@ int pos = m_textEditBox->getSelectionStartIndex(); s = s.insert(pos, TAB); m_textEditBox->setText(s); - m_textEditBox->setCaratIndex(pos+3); + m_textEditBox->setCaretIndex(pos+3); return true; } else if(e.codepoint == 40) { // Handle ( - m_textEditBox->insertText(")", m_textEditBox->getCaratIndex()); + m_textEditBox->insertText(")", m_textEditBox->getCaretIndex()); } else if(e.codepoint == 91) { // Handle [ - m_textEditBox->insertText("]", m_textEditBox->getCaratIndex()); + m_textEditBox->insertText("]", m_textEditBox->getCaretIndex()); } else if(e.codepoint == 123) { // Handle { - m_textEditBox->insertText("}", m_textEditBox->getCaratIndex()); + m_textEditBox->insertText("}", m_textEditBox->getCaretIndex()); } return false;
--- a/src/gui/debugpanel/textfileeditwindow.h Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/debugpanel/textfileeditwindow.h Wed Mar 26 23:39:02 2014 +0200 @@ -16,8 +16,14 @@ #ifndef TEXTFILEEDITWINDOW_H #define TEXTFILEEDITWINDOW_H +#ifdef CEGUI_07 #include <CEGUI/CEGUIWindow.h> #include <CEGUI/CEGUIEvent.h> +#else +#include "CEGUI/Window.h" +#include "CEGUI/Event.h" +#endif + #include "filebrowser/filebrowser.h" #include "boost/filesystem/path.hpp"
--- a/src/gui/mainmenu.cpp Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/mainmenu.cpp Wed Mar 26 23:39:02 2014 +0200 @@ -172,8 +172,8 @@ btn = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("LoginButton")); btn->subscribeEvent(CEGUI::PushButton::EventClicked, CEGUI::Event::Subscriber(&MainMenu::onLoginToOnlineService, this)); - CEGUI::FrameWindow* login_dialog = (CEGUI::FrameWindow*) win_mgr.loadWindowLayout( "LoginDialog.layout" ); - m_window->addChildWindow(login_dialog); + CEGUI::FrameWindow* login_dialog = static_cast<CEGUI::FrameWindow*>(CEGUIUtility::loadLayoutFromFile ("LoginDialog.layout")); + CEGUIUtility::addChildWidget (m_window, login_dialog); login_dialog->hide(); btn = static_cast<CEGUI::PushButton*>(win_mgr.getWindow("LoginDialog/LoginButton"));
--- a/src/gui/mainwindow.cpp Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/mainwindow.cpp Wed Mar 26 23:39:02 2014 +0200 @@ -842,8 +842,8 @@ CEGUI::WindowManager& win_mgr = CEGUI::WindowManager::getSingleton(); // Oberstes Fenster der Hauptmenue Schicht - m_game_screen = win_mgr.createWindow("DefaultWindow", "GameScreen"); - m_game_screen->setMousePassThroughEnabled(true); + m_game_screen = win_mgr.createWindow("DefaultWindow", "GameScreen"); + m_game_screen->setMousePassThroughEnabled(true); // Kontrollleiste anlegen setupControlPanel();
--- a/src/gui/savegamelist.cpp Sun Mar 23 21:04:27 2014 +0100 +++ b/src/gui/savegamelist.cpp Wed Mar 26 23:39:02 2014 +0200 @@ -172,8 +172,8 @@ SW_DEBUG ("Loading layout file [saveitem.layout]"); saveItem = (CEGUI::FrameWindow*) (CEGUIUtility::loadLayoutFromFile ("saveitem.layout")); SW_DEBUG ("Loaded layout file [saveitem.layout]"); - //saveItem = (CEGUI::Window*) win_mgr.loadWindowLayout("saveitem.layout", s.str()); - m_currentSelected = saveItem; + + m_currentSelected = saveItem; saveItem->setName (layoutRootItemName); saveItem->subscribeEvent(CEGUI::PushButton::EventClicked, CEGUI::Event::Subscriber(&SavegameList::onSavegameChosen, this)); saveItem->subscribeEvent(CEGUIUtility::EventMouseEntersPushButtonArea (), CEGUI::Event::Subscriber(&SavegameList::onItemButtonHover, this));