work on creating a scene ... not good now...
This commit is contained in:
parent
0a5ee4e3f1
commit
ce89a71068
@ -23,6 +23,10 @@
|
||||
*/
|
||||
|
||||
#include <ewol/WidgetManager.h>
|
||||
#include <ewol/widget/Joystick.h>
|
||||
#include <ewol/widget/Button.h>
|
||||
#include <ewol/widget/ButtonColor.h>
|
||||
#include <ewol/widget/Scene.h>
|
||||
|
||||
#undef __class__
|
||||
#define __class__ "WidgetManager"
|
||||
@ -43,6 +47,11 @@ void ewol::widgetManager::Init(void)
|
||||
// prevent android error ==> can create memory leak but I prefer
|
||||
m_focusWidgetDefault = NULL;
|
||||
m_focusWidgetCurrent = NULL;
|
||||
// init all the widget global parameters :
|
||||
ewol::WIDGET_JoystickInit();
|
||||
ewol::WIDGET_ButtonInit();
|
||||
ewol::WIDGET_ButtonColorInit();
|
||||
ewol::WIDGET_SceneInit();
|
||||
IsInit = true;
|
||||
}
|
||||
|
||||
|
@ -33,6 +33,16 @@ extern const char * const ewolEventButtonEnter = "ewol Button Enter";
|
||||
extern const char * const ewolEventButtonLeave = "ewol Button Leave";
|
||||
|
||||
|
||||
/**
|
||||
* @brief Initilise the basic widget property ==> due to the android system
|
||||
* @note all widget that have template might have this initializer ...
|
||||
* @param ---
|
||||
* @return ---
|
||||
*/
|
||||
void ewol::WIDGET_ButtonInit(void)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
#undef __class__
|
||||
#define __class__ "Button"
|
||||
|
@ -91,6 +91,14 @@ namespace ewol {
|
||||
virtual bool OnEventKb(ewol::eventKbType_te typeEvent, uniChar_t unicodeData);
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Initilise the basic widget property ==> due to the android system
|
||||
* @note all widget that have template might have this initializer ...
|
||||
* @param ---
|
||||
* @return ---
|
||||
*/
|
||||
void WIDGET_ButtonInit(void);
|
||||
|
||||
extern const char * const TYPE_EOBJECT_WIDGET_BUTTON;
|
||||
|
||||
};
|
||||
|
@ -33,6 +33,16 @@
|
||||
extern const char * const ewolEventButtonColorChange = "ewol-Button-Color-Change";
|
||||
|
||||
|
||||
/**
|
||||
* @brief Initilise the basic widget property ==> due to the android system
|
||||
* @note all widget that have template might have this initializer ...
|
||||
* @param ---
|
||||
* @return ---
|
||||
*/
|
||||
void ewol::WIDGET_ButtonColorInit(void)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
#undef __class__
|
||||
#define __class__ "ButtonColor"
|
||||
|
@ -95,6 +95,14 @@ namespace ewol {
|
||||
virtual void OnReceiveMessage(ewol::EObject * CallerObject, const char * eventId, etk::UString data);
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Initilise the basic widget property ==> due to the android system
|
||||
* @note all widget that have template might have this initializer ...
|
||||
* @param ---
|
||||
* @return ---
|
||||
*/
|
||||
void WIDGET_ButtonColorInit(void);
|
||||
|
||||
extern const char * const TYPE_EOBJECT_WIDGET_BUTTON_COLOR;
|
||||
|
||||
};
|
||||
|
@ -43,7 +43,7 @@ static etkFloat_t l_ratio(1.0/7.0);
|
||||
* @param ---
|
||||
* @return ---
|
||||
*/
|
||||
void WIDGET_JoystickInit(void)
|
||||
void ewol::WIDGET_JoystickInit(void)
|
||||
{
|
||||
l_displayBackground = true;
|
||||
l_background = "";
|
||||
@ -56,7 +56,7 @@ void WIDGET_JoystickInit(void)
|
||||
* @param[in] newRatio the new ratio that might be set
|
||||
* @return ---
|
||||
*/
|
||||
void WIDGET_JoystickDefaultRatio(etkFloat_t newRatio)
|
||||
void ewol::WIDGET_JoystickDefaultRatio(etkFloat_t newRatio)
|
||||
{
|
||||
if (newRatio > 1) {
|
||||
newRatio = 1;
|
||||
@ -70,7 +70,7 @@ void WIDGET_JoystickDefaultRatio(etkFloat_t newRatio)
|
||||
* @param[in] imageNameInData the new rbackground that might be set
|
||||
* @return ---
|
||||
*/
|
||||
void WIDGET_JoystickDefaultBackground(etk::UString imageNameInData, bool display)
|
||||
void ewol::WIDGET_JoystickDefaultBackground(etk::UString imageNameInData, bool display)
|
||||
{
|
||||
// TODO : check if it existed
|
||||
l_background = imageNameInData;
|
||||
@ -83,7 +83,7 @@ void WIDGET_JoystickDefaultBackground(etk::UString imageNameInData, bool display
|
||||
* @param[in] imageNameInData the new Foreground that might be set
|
||||
* @return ---
|
||||
*/
|
||||
void WIDGET_JoystickDefaultForeground(etk::UString imageNameInData)
|
||||
void ewol::WIDGET_JoystickDefaultForeground(etk::UString imageNameInData)
|
||||
{
|
||||
// TODO : check if it existed
|
||||
l_foreground = imageNameInData;
|
||||
|
@ -114,9 +114,36 @@ namespace ewol {
|
||||
void Foreground(etk::UString imageNameInData);
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Initilise the basic widget property ==> due to the android system
|
||||
* @note all widget that have template might have this initializer ...
|
||||
* @param ---
|
||||
* @return ---
|
||||
*/
|
||||
void WIDGET_JoystickInit(void);
|
||||
/**
|
||||
* @brief Set the default ratio of the widget joystick
|
||||
* @param[in] newRatio the new ratio that might be set
|
||||
* @return ---
|
||||
*/
|
||||
void WIDGET_JoystickDefaultRatio(etkFloat_t newRatio);
|
||||
/**
|
||||
* @brief Set the default Background of the widget joystick
|
||||
* @param[in] imageNameInData the new rbackground that might be set
|
||||
* @return ---
|
||||
*/
|
||||
void WIDGET_JoystickDefaultBackground(etk::UString imageNameInData, bool display);
|
||||
/**
|
||||
* @brief Set the default Foreground of the widget joystick
|
||||
* @param[in] imageNameInData the new Foreground that might be set
|
||||
* @return ---
|
||||
*/
|
||||
void WIDGET_JoystickDefaultForeground(etk::UString imageNameInData);
|
||||
|
||||
extern const char * const TYPE_EOBJECT_WIDGET_JOYSTICK;
|
||||
|
||||
};
|
||||
#define EWOL_CAST_WIDGET_JOYSTICK(curentPointer) EWOL_CAST(ewol::TYPE_EOBJECT_WIDGET_JOYSTICK,ewol::Button,curentPointer)
|
||||
#define EWOL_CAST_WIDGET_JOYSTICK(curentPointer) EWOL_CAST(ewol::TYPE_EOBJECT_WIDGET_JOYSTICK,ewol::Joystick,curentPointer)
|
||||
|
||||
|
||||
#endif
|
||||
|
@ -35,6 +35,7 @@ FILE_LIST = ewol/ewol.cpp \
|
||||
ewol/widget/List.cpp \
|
||||
ewol/widget/Menu.cpp \
|
||||
ewol/widget/PopUp.cpp \
|
||||
ewol/widget/Scene.cpp \
|
||||
ewol/widget/SizerHori.cpp \
|
||||
ewol/widget/SizerVert.cpp \
|
||||
ewol/widget/Slider.cpp \
|
||||
|
Loading…
x
Reference in New Issue
Block a user