bullet3/examples/ThirdPartyLibs/Gwen/Controls/VerticalScrollBar.h
erwincoumans ab8f16961e Code-style consistency improvement:
Apply clang-format-all.sh using the _clang-format file through all the cpp/.h files.
make sure not to apply it to certain serialization structures, since some parser expects the * as part of the name, instead of type.
This commit contains no other changes aside from adding and applying clang-format-all.sh
2018-09-23 14:17:31 -07:00

45 lines
1.1 KiB
C++

/*
GWEN
Copyright (c) 2010 Facepunch Studios
See license in Gwen.h
*/
#pragma once
#ifndef GWEN_CONTROLS_VERTICALSCROLLBAR_H
#define GWEN_CONTROLS_VERTICALSCROLLBAR_H
#include "Gwen/Controls/Base.h"
#include "Gwen/Controls/ScrollBar.h"
#include "Gwen/Gwen.h"
#include "Gwen/Skin.h"
namespace Gwen
{
namespace Controls
{
class GWEN_EXPORT VerticalScrollBar : public BaseScrollBar
{
GWEN_CONTROL(VerticalScrollBar, BaseScrollBar);
virtual void Layout(Skin::Base* skin);
virtual void OnMouseClickLeft(int x, int y, bool bDown);
virtual void OnBarMoved(Controls::Base* control);
virtual int GetBarSize() { return m_Bar->Height(); }
virtual int GetBarPos() { return m_Bar->Y() - Width(); }
virtual void SetBarSize(int size) { m_Bar->SetHeight(size); }
virtual int GetButtonSize() { return Width(); }
virtual void ScrollToTop();
virtual void ScrollToBottom();
virtual void NudgeUp(Base* control);
virtual void NudgeDown(Base* control);
virtual float GetNudgeAmount();
virtual float CalculateScrolledAmount();
virtual bool SetScrolledAmount(float amount, bool forceUpdate);
};
} // namespace Controls
} // namespace Gwen
#endif