1 #ifndef __DALI_INTERNAL_FEEDBACK_PLUGIN_PROXY_H__
2 #define __DALI_INTERNAL_FEEDBACK_PLUGIN_PROXY_H__
5 * Copyright (c) 2014 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 <feedback-plugin.h>
36 typedef Dali::FeedbackPlugin::SoundStopCallBack SoundStopCallBack;
37 typedef Dali::FeedbackPlugin::CreateFeedbackPlugin CreateFeedbackPlugin;
40 * Proxy class to dynamically load, use and unload feedback plugin.
42 class FeedbackPluginProxy
47 * The default feedback plugin proxy.
49 static const char * const DEFAULT_OBJECT_NAME;
56 FeedbackPluginProxy( const std::string& sharedObjectName );
61 ~FeedbackPluginProxy();
64 * @copydoc Dali::Integration::FeedbackPlugin::PlayHaptic()
66 void PlayHaptic( const std::string& filePath );
69 * @copydoc Dali::FeedbackPlugin::PlayHapticMonotone()
71 void PlayHapticMonotone( unsigned int duration );
74 * @copydoc Dali::FeedbackPlugin::StopHaptic()
79 * @copydoc Dali::FeedbackPlugin::PlaySound()
81 int PlaySound( const std::string& fileName );
84 * @copydoc Dali::FeedbackPlugin::StopSound()
86 void StopSound( int handle );
89 * @copydoc Dali::FeedbackPlugin::PlayFeedbackPattern()
91 void PlayFeedbackPattern( int type, int pattern );
96 * Dynamically loads the feedback plugin.
102 bool mInitializeAttempted;
104 std::string mSharedObjectName;
105 CreateFeedbackPlugin* mCreatePluginFunctionPtr;
106 Dali::FeedbackPlugin* mFeedbackPlugin;
109 } // namespace Adaptor
111 } // namespace Internal
115 #endif // __DALI_INTERNAL_FEEDBACK_PLUGIN_PROXY_H__