/*---------------------------------------------------------------------------* Project: NintendoWare File: SmLytSliderBar.h Copyright (C)2009-2010 Nintendo Co., Ltd./HAL Laboratory, Inc. All rights reserved. These coded instructions, statements, and computer programs contain proprietary information of Nintendo of America Inc. and/or Nintendo Company Ltd., and are protected by Federal copyright law. They may not be disclosed to third parties or copied or duplicated in any form, in whole or in part, without the prior written consent of Nintendo. $Revision: 1 $ *---------------------------------------------------------------------------*/ #ifndef SM_LYT_SLIDERBAR_H_ #define SM_LYT_SLIDERBAR_H_ #include "../include/SmLayout.h" #include "../include/SmMessage.h" #include "../include/SmRectCollision.h" //------------------------------------------------------------------------------ // レイアウトスライダーバーを表示するクラス class SmLytSliderBar : public SmMessage { public: // コンストラクタ SmLytSliderBar( f32 x, f32 y, SmLayout* smLayout); // デストラクタ ~SmLytSliderBar(); // メッセージ受信 virtual bool ReceveMessage( SmMessageType type, void* object, uint targetId ); // 表示/非表示切り替え virtual void SetVisible( bool visible ) { // レイアウトの表示/非表示を切り替え m_Layout->SetVisible( visible ); } // 描画 virtual void Render(); // パラメータ値をセットします。 void SetParam( f32 param ); // パラメータ値を取得します。 f32 GetParam() const { return m_Param; } private: SmLayout* m_Layout; nw::lyt::Pane* m_HandlePane; SmRectCollision m_Collision; f32 m_Param; bool m_IsGrab; s32 m_RangeMinY; s32 m_RangeMaxY; f32 m_BaseY; }; #endif // SM_LYT_SLIDERBAR_H_