1 #ifndef __DALI_ANDROID_CALLBACK_MANAGER_H__
2 #define __DALI_ANDROID_CALLBACK_MANAGER_H__
5 * Copyright (c) 2019 Samsung Electronics Co., Ltd.
7 * Licensed under the Apache License, Version 2.0 (the "License");
8 * you may not use this file except in compliance with the License.
9 * You may obtain a copy of the License at
11 * http://www.apache.org/licenses/LICENSE-2.0
13 * Unless required by applicable law or agreed to in writing, software
14 * distributed under the License is distributed on an "AS IS" BASIS,
15 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 * See the License for the specific language governing permissions and
17 * limitations under the License.
25 #include <dali/internal/system/common/callback-manager.h>
40 * Ecore interface to install call backs in the applications main loop.
42 class AndroidCallbackManager : public CallbackManager
50 AndroidCallbackManager();
55 ~AndroidCallbackManager() = default;
58 * @copydoc CallbackManager::AddIdleCallback()
60 virtual bool AddIdleCallback( CallbackBase* callback, bool hasReturnValue );
63 * @copydoc CallbackManager::RemoveIdleCallback()
65 virtual void RemoveIdleCallback( CallbackBase* callback );
68 * @copydoc CallbackManager::AddIdleEntererCallback()
70 virtual bool AddIdleEntererCallback( CallbackBase* callback );
73 * @copydoc CallbackManager::RemoveIdleEntererCallback()
75 virtual void RemoveIdleEntererCallback( CallbackBase* callback );
78 * @copydoc CallbackManager::Start()
83 * @copydoc CallbackManager::Stop()
90 * @brief Remove all idle call backs that are pending
92 * Always called from the main thread
94 void RemoveAllCallbacks();
97 * @brief Removes a single call back from the container
98 * Always called from main thread
99 * @param callbackData callback data
101 void RemoveCallbackFromContainer(CallbackData *callbackData);
104 * @brief Remove a standard call back from ecore
105 * Always called from main thread
106 * @param callbackData callback data
108 void RemoveStandardCallback(CallbackData *callbackData);
111 typedef std::list<CallbackData *> CallbackList;
113 bool mRunning; ///< flag is set to true if when running
114 CallbackList mCallbackContainer; ///< container of live idle callbacks
117 } // namespace Adaptor
119 } // namespace Internal
123 #endif // __DALI_ANDROID_CALLBACK_MANAGER_H__