class: ewol::Context


Description:



Associated Namespace:

Constructor and Destructor:

+                                          Context                   (int32_t _argc,
const char* _argv);
+ virtual ~Context (void );

Synopsis:

+         ewol::context::CommandLine &     getCmd                    (void );
+ ewol::context::ConfigFont & getFontDefault (void );
+ ewol::widget::Manager & getWidgetManager (void );
+ ewol::object::Manager & getEObjectManager (void );
+ ewol::resource::Manager & getResourcesManager (void );
# void lockContext (void );
# void unLockContext (void );
+ virtual void setArchiveDir (int _mode,
const char* _str);
+ virtual void OS_SetInputMotion (int _pointerID,
const vec2 & _pos);
+ virtual void OS_SetInputState (int _pointerID,
bool _isDown,
const vec2 & _pos);
+ virtual void OS_SetMouseMotion (int _pointerID,
const vec2 & _pos);
+ virtual void OS_SetMouseState (int _pointerID,
bool _isDown,
const vec2 & _pos);
+ virtual void OS_SetKeyboard (ewol::key::Special & _special,
char32_t _myChar,
bool _isDown,
bool _isARepeateKey);
+ virtual void OS_SetKeyboardMove (ewol::key::Special & _special,
enum ewol::key::keyboard _move,
bool _isDown,
bool _isARepeateKey);
+ virtual void OS_Suspend (void );
+ virtual void OS_Resume (void );
+ void requestUpdateSize (void );
+ bool OS_Draw (bool _displayEveryTime);
+ void onObjectRemove (ewol::Object* _removeObject);
+ void resetIOEvent (void );
+ void OS_OpenGlContextDestroy (void );
+ void OS_Stop (void );
+ virtual void stop (void );
+ void setWindows (ewol::widget::Windows* _windows);
+ ewol::widget::Windows* getWindows (void );
+ const vec2 & getSize (void );
+ virtual void OS_Resize (const vec2 & _size);
+ virtual void setSize (const vec2 & _size);
+ void OS_Move (const vec2 & _pos);
+ virtual void setPos (const vec2 & _pos);
+ void OS_Hide (void );
+ virtual void hide (void );
+ void OS_Show (void );
+ virtual void show (void );
+ void forceRedrawAll (void );
+ void inputEventTransfertWidget (ewol::Widget* _source,
ewol::Widget* _destination);
+ void inputEventGrabPointer (ewol::Widget* _widget);
+ void inputEventUnGrabPointer (void );
+ virtual void keyboardShow (void );
+ virtual void keyboardHide (void );
+ virtual void clipBoardGet (enum ewol::context::clipBoard::clipboardListe _clipboardID);
+ virtual void clipBoardSet (enum ewol::context::clipBoard::clipboardListe _clipboardID);
+ void OS_ClipBoardArrive (enum ewol::context::clipBoard::clipboardListe _clipboardID);
+ virtual void setTitle (const std::string & _title);
+ virtual void forceOrientation (enum ewol::orientation _orientation);
+ virtual void grabPointerEvents (bool _isGrabbed,
const vec2 & _forcedPosition);
+ virtual void setCursor (enum ewol::context::cursorDisplay _newCursor);
+ virtual void setIcon (const std::string & _inputFile);
+ int64_t getTime (void );
+ int main (int _argc,
const char* _argv);

Detail:

getCmd

+ ewol::context::CommandLine & getCmd (void );



getFontDefault

+ ewol::context::ConfigFont & getFontDefault (void );



getWidgetManager

+ ewol::widget::Manager & getWidgetManager (void );



getEObjectManager

+ ewol::object::Manager & getEObjectManager (void );



getResourcesManager

+ ewol::resource::Manager & getResourcesManager (void );



Context

+  Context (int32_t _argc,
const char* _argv);



~Context

+ virtual  ~Context (void );



lockContext

# void lockContext (void );
set the curent interface.
Note: this lock the main mutex


unLockContext

# void unLockContext (void );
set the curent interface at NULL.
Note: this un-lock the main mutex


setArchiveDir

+ virtual void setArchiveDir (int _mode,
const char* _str);



OS_SetInputMotion

+ virtual void OS_SetInputMotion (int _pointerID,
const vec2 & _pos);



OS_SetInputState

+ virtual void OS_SetInputState (int _pointerID,
bool _isDown,
const vec2 & _pos);



OS_SetMouseMotion

+ virtual void OS_SetMouseMotion (int _pointerID,
const vec2 & _pos);



OS_SetMouseState

+ virtual void OS_SetMouseState (int _pointerID,
bool _isDown,
const vec2 & _pos);



OS_SetKeyboard

+ virtual void OS_SetKeyboard (ewol::key::Special & _special,
char32_t _myChar,
bool _isDown,
bool _isARepeateKey);



OS_SetKeyboardMove

+ virtual void OS_SetKeyboardMove (ewol::key::Special & _special,
enum ewol::key::keyboard _move,
bool _isDown,
bool _isARepeateKey);



OS_Suspend

+ virtual void OS_Suspend (void );
The current context is suspended


OS_Resume

+ virtual void OS_Resume (void );
The current context is resumed


requestUpdateSize

+ void requestUpdateSize (void );



OS_Draw

+ bool OS_Draw (bool _displayEveryTime);



onObjectRemove

+ void onObjectRemove (ewol::Object* _removeObject);
Inform object that an other object is removed ...
Note: : Sub classes must call this class


resetIOEvent

+ void resetIOEvent (void );
reset event management for the IO like Input ou Mouse or keyborad


OS_OpenGlContextDestroy

+ void OS_OpenGlContextDestroy (void );
The OS inform that the openGL constext has been destroy == > use to automaticly reload the texture and other thinks ...


OS_Stop

+ void OS_Stop (void );
The OS Inform that the Window has been killed


stop

+ virtual void stop (void );
The application request that the Window will be killed


setWindows

+ void setWindows (ewol::widget::Windows* _windows);
set the current windows to display :


getWindows

+ ewol::widget::Windows* getWindows (void );
get the current windows that is displayed


getSize

+ const vec2 & getSize (void );
get the current windows size


OS_Resize

+ virtual void OS_Resize (const vec2 & _size);
The OS inform that the current windows has change his size.


setSize

+ virtual void setSize (const vec2 & _size);
The application request a change of his curent size.


OS_Move

+ void OS_Move (const vec2 & _pos);
The OS inform that the current windows has change his position.


setPos

+ virtual void setPos (const vec2 & _pos);
The Application request that the current windows will change his position.


OS_Hide

+ void OS_Hide (void );
The OS inform that the Windows is now Hidden.


hide

+ virtual void hide (void );
The Application request that the Windows will be Hidden.


OS_Show

+ void OS_Show (void );
The OS inform that the Windows is now visible.


show

+ virtual void show (void );
The Application request that the Windows will be visible.


forceRedrawAll

+ void forceRedrawAll (void );
Redraw all the windows


inputEventTransfertWidget

+ void inputEventTransfertWidget (ewol::Widget* _source,
ewol::Widget* _destination);
This is to transfert the event from one widget to another one


inputEventGrabPointer

+ void inputEventGrabPointer (ewol::Widget* _widget);
This fonction lock the pointer properties to move in relative instead of absolute


inputEventUnGrabPointer

+ void inputEventUnGrabPointer (void );
This fonction un-lock the pointer properties to move in relative instead of absolute


keyboardShow

+ virtual void keyboardShow (void );
display the virtal keyboard (for touch system only)


keyboardHide

+ virtual void keyboardHide (void );
Hide the virtal keyboard (for touch system only)


clipBoardGet

+ virtual void clipBoardGet (enum ewol::context::clipBoard::clipboardListe _clipboardID);
Inform the Gui that we want to have a copy of the clipboard


clipBoardSet

+ virtual void clipBoardSet (enum ewol::context::clipBoard::clipboardListe _clipboardID);
Inform the Gui that we are the new owner of the clipboard


OS_ClipBoardArrive

+ void OS_ClipBoardArrive (enum ewol::context::clipBoard::clipboardListe _clipboardID);
Call by the OS when a clipboard arrive to US (previously requested by a widget)


setTitle

+ virtual void setTitle (const std::string & _title);
set the new title of the windows


forceOrientation

+ virtual void forceOrientation (enum ewol::orientation _orientation);
force the screen orientation (availlable on portable elements ...


grabPointerEvents

+ virtual void grabPointerEvents (bool _isGrabbed,
const vec2 & _forcedPosition);
get all the event from the X system


setCursor

+ virtual void setCursor (enum ewol::context::cursorDisplay _newCursor);
set the cursor display type.


setIcon

+ virtual void setIcon (const std::string & _inputFile);
set the Icon of the program


getTime

+ int64_t getTime (void );
get the curent time in micro-second
Note: : must be implemented in all system OS implementation


main

+ int main (int _argc,
const char* _argv);
This is the only one things the User might done in his main();
Note: : must be implemented in all system OPS implementation
Note: To answare you before you ask the question, this is really simple: Due to the fect that the current system is multiple-platform, you "main" Does not exist in the android platform, then ewol call other start and stop function, to permit to have only one code
Note: The main can not be in the ewol, due to the fact thet is an librairy