From: <ave...@us...> - 2004-02-11 23:29:47
|
Update of /cvsroot/gemrb/gemrb/gemrb/plugins/Core In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28550/Core Modified Files: Button.cpp Button.h Log Message: Moved Draggable and Animated to the button flags Index: Button.cpp =================================================================== RCS file: /cvsroot/gemrb/gemrb/gemrb/plugins/Core/Button.cpp,v retrieving revision 1.50 retrieving revision 1.51 diff -C2 -d -r1.50 -r1.51 *** Button.cpp 11 Feb 2004 22:36:15 -0000 1.50 --- Button.cpp 11 Feb 2004 23:25:17 -0000 1.51 *************** *** 68,72 **** Picture = NULL; //MOS Draggable Stuff - Draggable = false; Dragging = false; ScrollX = 0; --- 68,71 ---- *************** *** 196,200 **** } if(Picture && (Flags&0x2)) { ! if(Draggable) { Region r(XPos, YPos, Width, Height); core->GetVideoDriver()->BlitSprite(Picture, XPos+ScrollX, YPos+ScrollY, true, &r); --- 195,199 ---- } if(Picture && (Flags&0x2)) { ! if(Flags&0x80) { Region r(XPos, YPos, Width, Height); core->GetVideoDriver()->BlitSprite(Picture, XPos+ScrollX, YPos+ScrollY, true, &r); *************** *** 241,245 **** core->GetSoundMgr()->Play(ButtonSounds[SND_BUTTON_PRESSED]); } ! if(Draggable) { Dragging = true; DragX = x; --- 240,244 ---- core->GetSoundMgr()->Play(ButtonSounds[SND_BUTTON_PRESSED]); } ! if(Flags&0x80) { Dragging = true; DragX = x; *************** *** 254,258 **** if(State == IE_GUI_BUTTON_DISABLED) return; ! if(Draggable) Dragging = false; if(State == IE_GUI_BUTTON_PRESSED) --- 253,257 ---- if(State == IE_GUI_BUTTON_DISABLED) return; ! if(Flags&0x80) Dragging = false; if(State == IE_GUI_BUTTON_PRESSED) *************** *** 401,412 **** ((Window*)Owner)->Invalidate(); } - - void SetAnimatedButton(bool animated) - { - - } - - void Button::SetDraggable(bool Value) - { - Draggable = Value; - } --- 400,401 ---- Index: Button.h =================================================================== RCS file: /cvsroot/gemrb/gemrb/gemrb/plugins/Core/Button.h,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -d -r1.20 -r1.21 *** Button.h 11 Feb 2004 22:36:15 -0000 1.20 --- Button.h 11 Feb 2004 23:25:17 -0000 1.21 *************** *** 93,99 **** /** Refreshes the button from a radio group */ void RedrawButton(char *VariableName, int Sum); - void SetAnimatedButton(bool animated); - /** MOS Draggable Functions */ - void SetDraggable(bool Value); private: // Private attributes bool Clear; --- 93,96 ---- *************** *** 123,127 **** unsigned short ScrollX, ScrollY; bool Dragging; - bool Draggable; unsigned short DragX, DragY; //Starting Dragging Positions }; --- 120,123 ---- |