Dali 3D User Interface Engine
List of all members | Classes | Public Member Functions | Private Member Functions | Private Attributes
Dali::Internal::Adaptor::Framework Class Reference

The Framework class is used to register callbacks with the TIZEN platform so that we know when any of the application lifecycle events occur. More...

#include <framework.h>

Collaboration diagram for Dali::Internal::Adaptor::Framework:
Collaboration graph
[legend]

Classes

class  Observer
 Observer class for the framework. More...
 

Public Member Functions

 Framework (Observer &observer, int *argc, char ***argv)
 Constructor. More...
 
 ~Framework ()
 Destructor. More...
 
void Run ()
 Runs the main loop of framework. More...
 
void Quit ()
 Quits the main loop. More...
 
bool IsMainLoopRunning ()
 Checks whether the main loop of the framework is running. More...
 
void AddAbortCallback (CallbackBase *callback)
 If the main loop aborts unexpectedly, then the connected callback function is called. More...
 
std::string GetBundleName () const
 Gets bundle name which was passed in app_reset callback. More...
 
std::string GetBundleId () const
 Gets bundle id which was passed in app_reset callback. More...
 

Private Member Functions

 Framework (const Framework &)
 
Frameworkoperator= (Framework &)
 
bool AppStatusHandler (int type, void *bundleData)
 Called by the App framework when an application lifecycle event occurs. More...
 
void SetBundleName (const std::string &name)
 Called app_reset callback was called with bundle. More...
 
void SetBundleId (const std::string &id)
 Called app_reset callback was called with bundle. More...
 
void AbortCallback ()
 Called if the application is aborted. More...
 
void InitThreads ()
 Called for initializing on specified backend. More...
 

Private Attributes

ObservermObserver
 
bool mInitialised
 
bool mRunning
 
int * mArgc
 
char *** mArgv
 
std::string mBundleName
 
std::string mBundleId
 
AbortHandler mAbortHandler
 
Impl * mImpl
 

Detailed Description

The Framework class is used to register callbacks with the TIZEN platform so that we know when any of the application lifecycle events occur.

This includes events like when our application is to be initialised, terminated, paused, resumed etc.

Definition at line 42 of file framework.h.

Constructor & Destructor Documentation

Dali::Internal::Adaptor::Framework::Framework ( Observer observer,
int *  argc,
char ***  argv 
)

Constructor.

Parameters
[in]observerThe observer of the Framework.
[in]argcA pointer to the number of arguments.
[in]argvA pointer the the argument list.
Dali::Internal::Adaptor::Framework::~Framework ( )

Destructor.

Dali::Internal::Adaptor::Framework::Framework ( const Framework )
private

Member Function Documentation

void Dali::Internal::Adaptor::Framework::AbortCallback ( )
private

Called if the application is aborted.

void Dali::Internal::Adaptor::Framework::AddAbortCallback ( CallbackBase callback)

If the main loop aborts unexpectedly, then the connected callback function is called.

Parameters
[in]callBackThe function to call.
Note
Only one callback can be registered. The last callback to be set will be called on abort.
The ownership of callback is passed onto this class.

Referenced by Dali::Internal::Adaptor::Application::OnInit().

Here is the caller graph for this function:

bool Dali::Internal::Adaptor::Framework::AppStatusHandler ( int  type,
void *  bundleData 
)
private

Called by the App framework when an application lifecycle event occurs.

Parameters
[in]typeThe type of event occurred.
[in]bundleDataThe bundle data of event occurred.
std::string Dali::Internal::Adaptor::Framework::GetBundleId ( ) const

Gets bundle id which was passed in app_reset callback.

std::string Dali::Internal::Adaptor::Framework::GetBundleName ( ) const

Gets bundle name which was passed in app_reset callback.

void Dali::Internal::Adaptor::Framework::InitThreads ( )
private

Called for initializing on specified backend.

(X11 or Wayland)

bool Dali::Internal::Adaptor::Framework::IsMainLoopRunning ( )

Checks whether the main loop of the framework is running.

Returns
true, if the main loop is running, false otherwise.
Framework& Dali::Internal::Adaptor::Framework::operator= ( Framework )
private
void Dali::Internal::Adaptor::Framework::Quit ( )

Quits the main loop.

Referenced by Dali::Internal::Adaptor::Application::QuitFromMainLoop().

Here is the caller graph for this function:

void Dali::Internal::Adaptor::Framework::Run ( )

Runs the main loop of framework.

Referenced by Dali::Internal::Adaptor::Application::MainLoop().

Here is the caller graph for this function:

void Dali::Internal::Adaptor::Framework::SetBundleId ( const std::string &  id)
private

Called app_reset callback was called with bundle.

void Dali::Internal::Adaptor::Framework::SetBundleName ( const std::string &  name)
private

Called app_reset callback was called with bundle.

Member Data Documentation

AbortHandler Dali::Internal::Adaptor::Framework::mAbortHandler
private

Definition at line 198 of file framework.h.

int* Dali::Internal::Adaptor::Framework::mArgc
private

Definition at line 194 of file framework.h.

char*** Dali::Internal::Adaptor::Framework::mArgv
private

Definition at line 195 of file framework.h.

std::string Dali::Internal::Adaptor::Framework::mBundleId
private

Definition at line 197 of file framework.h.

std::string Dali::Internal::Adaptor::Framework::mBundleName
private

Definition at line 196 of file framework.h.

Impl* Dali::Internal::Adaptor::Framework::mImpl
private

Definition at line 202 of file framework.h.

bool Dali::Internal::Adaptor::Framework::mInitialised
private

Definition at line 192 of file framework.h.

Observer& Dali::Internal::Adaptor::Framework::mObserver
private

Definition at line 191 of file framework.h.

bool Dali::Internal::Adaptor::Framework::mRunning
private

Definition at line 193 of file framework.h.


The documentation for this class was generated from the following file:
Dali Docs Home
Read more about Dali