fixed scroll bars

pull/21/head
scrawl 13 years ago
parent 26aae9d2ce
commit 560e702973

@ -41,7 +41,7 @@ namespace MWGui
static const int lineHeight; static const int lineHeight;
MyGUI::WidgetPtr skillAreaWidget, skillClientWidget; MyGUI::WidgetPtr skillAreaWidget, skillClientWidget;
MyGUI::VScrollPtr skillScrollerWidget; MyGUI::ScrollBar* skillScrollerWidget;
int lastPos, clientHeight; int lastPos, clientHeight;
MyGUI::EditPtr mLeftTextWidget; MyGUI::EditPtr mLeftTextWidget;
MyGUI::EditPtr mRightTextWidget; MyGUI::EditPtr mRightTextWidget;
@ -54,4 +54,4 @@ namespace MWGui
} }
#endif #endif

@ -157,7 +157,7 @@ void RaceDialog::onBackClicked(MyGUI::Widget* _sender)
eventBack(); eventBack();
} }
void RaceDialog::onHeadRotate(MyGUI::VScroll*, size_t _position) void RaceDialog::onHeadRotate(MyGUI::ScrollBar*, size_t _position)
{ {
// TODO: Rotate head // TODO: Rotate head
} }

@ -54,7 +54,7 @@ namespace MWGui
EventHandle_Void eventBack; EventHandle_Void eventBack;
protected: protected:
void onHeadRotate(MyGUI::VScroll* _sender, size_t _position); void onHeadRotate(MyGUI::ScrollBar* _sender, size_t _position);
void onSelectPreviousGender(MyGUI::Widget* _sender); void onSelectPreviousGender(MyGUI::Widget* _sender);
void onSelectNextGender(MyGUI::Widget* _sender); void onSelectNextGender(MyGUI::Widget* _sender);
@ -77,7 +77,7 @@ namespace MWGui
MyGUI::CanvasPtr appearanceBox; MyGUI::CanvasPtr appearanceBox;
MyGUI::ListPtr raceList; MyGUI::ListPtr raceList;
MyGUI::HScrollPtr headRotate; MyGUI::ScrollBar* headRotate;
MyGUI::WidgetPtr skillList; MyGUI::WidgetPtr skillList;
std::vector<MyGUI::WidgetPtr> skillItems; std::vector<MyGUI::WidgetPtr> skillItems;

@ -102,7 +102,7 @@ void ReviewDialog::open()
setVisible(true); setVisible(true);
} }
void ReviewDialog::onScrollChangePosition(MyGUI::VScrollPtr scroller, size_t pos) void ReviewDialog::onScrollChangePosition(MyGUI::ScrollBar* scroller, size_t pos)
{ {
int diff = lastPos - pos; int diff = lastPos - pos;
// Adjust position of all widget according to difference // Adjust position of all widget according to difference

@ -84,14 +84,14 @@ namespace MWGui
void updateScroller(); void updateScroller();
void updateSkillArea(); void updateSkillArea();
void onScrollChangePosition(MyGUI::VScrollPtr scroller, size_t pos); void onScrollChangePosition(MyGUI::ScrollBar* scroller, size_t pos);
void onWindowResize(MyGUI::Window* window); void onWindowResize(MyGUI::Window* window);
static const int lineHeight; static const int lineHeight;
MyGUI::TextBox *nameWidget, *raceWidget, *classWidget, *birthSignWidget; MyGUI::TextBox *nameWidget, *raceWidget, *classWidget, *birthSignWidget;
MyGUI::WidgetPtr skillAreaWidget, skillClientWidget; MyGUI::WidgetPtr skillAreaWidget, skillClientWidget;
MyGUI::VScrollPtr skillScrollerWidget; MyGUI::ScrollBar* skillScrollerWidget;
int lastPos, clientHeight; int lastPos, clientHeight;
Widgets::MWDynamicStatPtr health, magicka, fatigue; Widgets::MWDynamicStatPtr health, magicka, fatigue;

@ -61,7 +61,7 @@ StatsWindow::StatsWindow (WindowManager& parWindowManager)
t->eventWindowChangeCoord += MyGUI::newDelegate(this, &StatsWindow::onWindowResize); t->eventWindowChangeCoord += MyGUI::newDelegate(this, &StatsWindow::onWindowResize);
} }
void StatsWindow::onScrollChangePosition(MyGUI::VScrollPtr scroller, size_t pos) void StatsWindow::onScrollChangePosition(MyGUI::ScrollBar* scroller, size_t pos)
{ {
int diff = lastPos - pos; int diff = lastPos - pos;
// Adjust position of all widget according to difference // Adjust position of all widget according to difference

@ -57,13 +57,13 @@ namespace MWGui
void addItem(const std::string text, MyGUI::IntCoord &coord1, MyGUI::IntCoord &coord2); void addItem(const std::string text, MyGUI::IntCoord &coord1, MyGUI::IntCoord &coord2);
void updateScroller(); void updateScroller();
void onScrollChangePosition(MyGUI::VScrollPtr scroller, size_t pos); void onScrollChangePosition(MyGUI::ScrollBar* scroller, size_t pos);
void onWindowResize(MyGUI::Window* window); void onWindowResize(MyGUI::Window* window);
static const int lineHeight; static const int lineHeight;
MyGUI::WidgetPtr skillAreaWidget, skillClientWidget; MyGUI::WidgetPtr skillAreaWidget, skillClientWidget;
MyGUI::VScrollPtr skillScrollerWidget; MyGUI::ScrollBar* skillScrollerWidget;
int lastPos, clientHeight; int lastPos, clientHeight;
SkillList majorSkills, minorSkills, miscSkills; SkillList majorSkills, minorSkills, miscSkills;

@ -37,7 +37,7 @@
<!-- Player skills, factions, birthsign and reputation --> <!-- Player skills, factions, birthsign and reputation -->
<Widget type="Widget" skin="MW_Box" position="258 12 244 356" align="ALIGN_LEFT ALIGN_VSTRETCH" name="Skills"> <Widget type="Widget" skin="MW_Box" position="258 12 244 356" align="ALIGN_LEFT ALIGN_VSTRETCH" name="Skills">
<Widget type="Widget" skin="" position="4 4 218 346" align="ALIGN_STRETCH" name="SkillClient" /> <Widget type="Widget" skin="" position="4 4 218 346" align="ALIGN_STRETCH" name="SkillClient" />
<Widget type="VScroll" skin="MW_VScroll" position="226 4 14 346" align="ALIGN_RIGHT ALIGN_VSTRETCH" name="SkillScroller" /> <Widget type="ScrollBar" skin="MW_VScroll" position="226 4 14 346" align="ALIGN_RIGHT ALIGN_VSTRETCH" name="SkillScroller" />
</Widget> </Widget>
<!-- Dialog buttons --> <!-- Dialog buttons -->

@ -24,6 +24,6 @@
<Skin name="MW_BookPage" size="0 0 50 50"> <Skin name="MW_BookPage" size="0 0 50 50">
<Property key="WordWrap" value = "true" /> <Property key="WordWrap" value = "true" />
<Child type="Widget" skin="MW_BookClient" offset="0 0 35 10" align = "ALIGN_STRETCH" name = "Client"/> <Child type="Widget" skin="MW_BookClient" offset="0 0 35 10" align = "ALIGN_STRETCH" name = "Client"/>
<!--Child type="VScroll" skin="VScroll" offset = "35 0 15 50" align = "Right VStretch" name = "VScroll"/--> <!--Child type="ScrollBar" skin="VScroll" offset = "35 0 15 50" align = "Right VStretch" name = "VScroll"/-->
</Skin> </Skin>
</MyGUI> </MyGUI>

@ -195,7 +195,7 @@
<Property key="SkinLine" value = "MW_ListLine" /> <Property key="SkinLine" value = "MW_ListLine" />
<Property key="HeightLine" value = "20" /> <Property key="HeightLine" value = "20" />
<Child type="VScroll" skin="MW_VScroll" offset = "498 3 14 509" align = "ALIGN_RIGHT ALIGN_VSTRETCH" name = "VScroll"> <Child type="ScrollBar" skin="MW_VScroll" offset = "498 3 14 509" align = "ALIGN_RIGHT ALIGN_VSTRETCH" name = "VScroll">
</Child> </Child>
<Child type="Widget" skin="ClientDefaultSkin" offset = "3 3 493 509" align = "ALIGN_STRETCH" name = "Client"> <Child type="Widget" skin="ClientDefaultSkin" offset = "3 3 493 509" align = "ALIGN_STRETCH" name = "Client">
@ -216,7 +216,7 @@
<Property key="SkinLine" value = "MW_ListLine" /> <Property key="SkinLine" value = "MW_ListLine" />
<Property key="HeightLine" value = "20" /> <Property key="HeightLine" value = "20" />
<Child type="VScroll" skin="VScroll" offset = "498 3 14 509" align = "ALIGN_RIGHT ALIGN_VSTRETCH" name = "VScroll"> <Child type="ScrollBar" skin="VScroll" offset = "498 3 14 509" align = "ALIGN_RIGHT ALIGN_VSTRETCH" name = "VScroll">
</Child> </Child>
<Child type="Widget" skin="Default" offset = "3 3 493 509" align = "ALIGN_STRETCH" name = "Client"> <Child type="Widget" skin="Default" offset = "3 3 493 509" align = "ALIGN_STRETCH" name = "Client">

@ -55,7 +55,7 @@
<!-- Player skills, factions, birthsign and reputation --> <!-- Player skills, factions, birthsign and reputation -->
<Widget type="Widget" skin="MW_Box" position="228 8 248 292" align="ALIGN_LEFT ALIGN_VSTRETCH" name="Skills"> <Widget type="Widget" skin="MW_Box" position="228 8 248 292" align="ALIGN_LEFT ALIGN_VSTRETCH" name="Skills">
<Widget type="Widget" skin="" position="4 4 222 284" align="ALIGN_STRETCH" name="SkillClient" /> <Widget type="Widget" skin="" position="4 4 222 284" align="ALIGN_STRETCH" name="SkillClient" />
<Widget type="VScroll" skin="MW_VScroll" position="230 4 14 284" align="ALIGN_RIGHT ALIGN_VSTRETCH" name="SkillScroller" /> <Widget type="ScrollBar" skin="MW_VScroll" position="230 4 14 284" align="ALIGN_RIGHT ALIGN_VSTRETCH" name="SkillScroller" />
</Widget> </Widget>
</Widget> </Widget>
</MyGUI> </MyGUI>

@ -20,7 +20,7 @@
<Property key="AlignText" value = "ALIGN_LEFT ALIGN_TOP" /> <Property key="AlignText" value = "ALIGN_LEFT ALIGN_TOP" />
<Property key="TextColour" value = "0.6 0.6 0.6" /> <Property key="TextColour" value = "0.6 0.6 0.6" />
</Widget> </Widget>
<Widget type="VScroll" skin="MW_VScroll" position="494 3 14 14" align="Right VStretch" name="VScroll"/> <Widget type="ScrollBar" skin="MW_VScroll" position="494 3 14 14" align="Right VStretch" name="VScroll"/>
</Widget> </Widget>
</Resource> </Resource>
@ -49,7 +49,7 @@
<Widget type="EditBox" skin="MW_LogClient" position="0 0 35 10" align="Stretch" name="Client"> <Widget type="EditBox" skin="MW_LogClient" position="0 0 35 10" align="Stretch" name="Client">
<Property key="WordWrap" value = "true" /> <Property key="WordWrap" value = "true" />
</Widget> </Widget>
<!--Child type="VScroll" skin="VScroll" offset = "35 0 15 50" align = "Right VStretch" name = "VScroll"/--> <!--Child type="ScrollBar" skin="VScroll" offset = "35 0 15 50" align = "Right VStretch" name = "VScroll"/-->
</Widget> </Widget>
</Resource> </Resource>
</MyGUI> </MyGUI>

Loading…
Cancel
Save