| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677 |
- //********************************** Banshee Engine (www.banshee3d.com) **************************************************//
- //**************** Copyright (c) 2016 Marko Pintera ([email protected]). All rights reserved. **********************//
- #pragma once
- #include "BsScriptEnginePrerequisites.h"
- #include "Wrappers/GUI/BsScriptGUIElement.h"
- namespace bs
- {
- /** @addtogroup ScriptInteropEngine
- * @{
- */
- /** Interop class between C++ & CLR for GUISliderH. */
- class BS_SCR_BE_EXPORT ScriptGUISliderH : public TScriptGUIElement<ScriptGUISliderH>
- {
- public:
- SCRIPT_OBJ(ENGINE_ASSEMBLY, "BansheeEngine", "GUISliderH")
- private:
- ScriptGUISliderH(MonoObject* instance, GUISliderHorz* slider);
- /** Triggered when the native slider is moved. */
- void onChanged(float percent);
- /************************************************************************/
- /* CLR HOOKS */
- /************************************************************************/
- static void internal_createInstance(MonoObject* instance, MonoString* style, MonoArray* guiOptions);
- static void internal_setPercent(ScriptGUISliderH* nativeInstance, float percent);
- static float internal_getPercent(ScriptGUISliderH* nativeInstance);
- static float internal_getValue(ScriptGUISliderH* nativeInstance);
- static void internal_setValue(ScriptGUISliderH* nativeInstance, float percent);
- static void internal_setRange(ScriptGUISliderH* nativeInstance, float min, float max);
- static float internal_getRangeMaximum(ScriptGUISliderH* nativeInstance);
- static float internal_getRangeMinimum(ScriptGUISliderH* nativeInstance);
- static void internal_setStep(ScriptGUISliderH* nativeInstance, float step);
- static float internal_getStep(ScriptGUISliderH* nativeInstance);
- static void internal_setTint(ScriptGUISliderH* nativeInstance, Color* color);
- typedef void(BS_THUNKCALL *OnChangedThunkDef) (MonoObject*, float, MonoException**);
- static OnChangedThunkDef onChangedThunk;
- };
- /** Interop class between C++ & CLR for GUISliderV. */
- class BS_SCR_BE_EXPORT ScriptGUISliderV : public TScriptGUIElement<ScriptGUISliderV>
- {
- public:
- SCRIPT_OBJ(ENGINE_ASSEMBLY, "BansheeEngine", "GUISliderV")
- private:
- ScriptGUISliderV(MonoObject* instance, GUISliderVert* slider);
- /** Triggered when the native slider is moved. */
- void onChanged(float percent);
- /************************************************************************/
- /* CLR HOOKS */
- /************************************************************************/
- static void internal_createInstance(MonoObject* instance, MonoString* style, MonoArray* guiOptions);
- static void internal_setPercent(ScriptGUISliderV* nativeInstance, float percent);
- static float internal_getPercent(ScriptGUISliderV* nativeInstance);
- static float internal_getValue(ScriptGUISliderV* nativeInstance);
- static void internal_setValue(ScriptGUISliderV* nativeInstance, float percent);
- static void internal_setRange(ScriptGUISliderV* nativeInstance, float min, float max);
- static float internal_getRangeMaximum(ScriptGUISliderV* nativeInstance);
- static float internal_getRangeMinimum(ScriptGUISliderV* nativeInstance);
- static void internal_setStep(ScriptGUISliderV* nativeInstance, float step);
- static float internal_getStep(ScriptGUISliderV* nativeInstance);
- static void internal_setTint(ScriptGUISliderV* nativeInstance, Color* color);
- typedef void(BS_THUNKCALL *OnChangedThunkDef) (MonoObject*, float, MonoException**);
- static OnChangedThunkDef onChangedThunk;
- };
- /** @} */
- }
|