[dali_1.2.2] Merge branch 'devel/master' 80/84580/1
authorFerran Sole <ferran.sole@samsung.com>
Fri, 19 Aug 2016 09:59:58 +0000 (10:59 +0100)
committerFerran Sole <ferran.sole@samsung.com>
Fri, 19 Aug 2016 09:59:58 +0000 (10:59 +0100)
Change-Id: I9621d13767bfb5ca17d71764bac7c16500af5e49

36 files changed:
adaptors/common/adaptor-impl.cpp
adaptors/common/adaptor-impl.h
adaptors/common/adaptor.cpp
adaptors/common/application-impl.cpp
adaptors/common/application-impl.h
adaptors/common/callback-manager.h
adaptors/common/event-loop/ecore/ecore-callback-manager.cpp
adaptors/common/event-loop/ecore/ecore-callback-manager.h
adaptors/common/event-loop/lib-uv/uv-callback-manager.cpp
adaptors/common/event-loop/lib-uv/uv-callback-manager.h
adaptors/common/framework.h
adaptors/devel-api/adaptor-framework/imf-manager.cpp
adaptors/devel-api/adaptor-framework/imf-manager.h
adaptors/ecore/wayland/event-handler-ecore-wl.cpp
adaptors/ecore/wayland/imf-manager-impl-ecore-wl.cpp
adaptors/ecore/wayland/imf-manager-impl.h
adaptors/integration-api/adaptor.h
adaptors/integration-api/x11/imf-manager-impl.h
adaptors/libuv/framework-libuv.cpp
adaptors/public-api/adaptor-framework/application.cpp
adaptors/public-api/adaptor-framework/application.h
adaptors/public-api/adaptor-framework/native-image-source.h
adaptors/public-api/adaptor-framework/tts-player.h
adaptors/public-api/adaptor-framework/window.h
adaptors/public-api/dali-adaptor-version.cpp
adaptors/tizen/framework-tizen.cpp
adaptors/ubuntu/framework-ubuntu.cpp
adaptors/wayland/input/text/imf/imf-manager-impl-wl.cpp
adaptors/wayland/input/text/imf/imf-manager-impl.h
adaptors/x11/imf-manager-impl-x.cpp
build/tizen/adaptor-uv/Makefile.am
build/tizen/adaptor-uv/configure.ac
build/tizen/adaptor/Makefile.am
build/tizen/adaptor/configure.ac
packaging/dali-adaptor.spec
platform-abstractions/tizen/image-loaders/loader-gif.cpp

index cdc1405..da9476b 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2015 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -467,6 +467,10 @@ bool Adaptor::AddIdle( CallbackBase* callback )
   return idleAdded;
 }
 
+void Adaptor::RemoveIdle( CallbackBase* callback )
+{
+  mCallbackManager->RemoveIdleCallback( callback );
+}
 
 Dali::Adaptor& Adaptor::Get()
 {
index 40b9bb2..704d414 100644 (file)
@@ -2,7 +2,7 @@
 #define __DALI_INTERNAL_ADAPTOR_IMPL_H__
 
 /*
- * Copyright (c) 2015 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -220,6 +220,11 @@ public: // AdaptorInternalServices implementation
    */
   virtual bool AddIdle( CallbackBase* callback );
 
+  /**
+   * @copydoc Dali::Adaptor::RemoveIdle()
+   */
+  virtual void RemoveIdle( CallbackBase* callback );
+
 public:
 
   /**
index 9c6701c..a2e80ad 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2014 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -84,6 +84,11 @@ bool Adaptor::AddIdle( CallbackBase* callback )
   return mImpl->AddIdle( callback );
 }
 
+void Adaptor::RemoveIdle( CallbackBase* callback )
+{
+  mImpl->RemoveIdle( callback );
+}
+
 void Adaptor::ReplaceSurface( Any nativeWindow, Dali::RenderSurface& surface )
 {
   mImpl->ReplaceSurface(nativeWindow, surface);
index e43871f..3cfb156 100644 (file)
@@ -25,6 +25,7 @@
 #include <style-monitor.h>
 #include <command-line-options.h>
 #include <common/adaptor-impl.h>
+#include <common/framework.h>
 #include <singleton-service-impl.h>
 #include <lifecycle-controller-impl.h>
 
@@ -345,6 +346,11 @@ void Application::ReplaceWindow(PositionSize windowPosition, const std::string&
   mWindow = newWindow;
 }
 
+std::string Application::GetResourcePath()
+{
+  return Internal::Adaptor::Framework::GetResourcePath();
+}
+
 } // namespace Adaptor
 
 } // namespace Internal
index 68de173..506496f 100644 (file)
@@ -106,6 +106,11 @@ public:
    */
   void ReplaceWindow(PositionSize windowPosition, const std::string& name);
 
+  /**
+   * @copydoc Dali::Application::GetResourcePath();
+   */
+  static std::string GetResourcePath();
+
 public: // Stereoscopy
 
   /**
index 20f8798..fc16aca 100644 (file)
@@ -2,7 +2,7 @@
 #define __DALI_INTERNAL_CALLBACK_MANAGER_H__
 
 /*
- * Copyright (c) 2014 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -50,15 +50,26 @@ public:
     virtual ~CallbackManager() {}
 
     /**
-     * Adds a call back to be run on idle.
-     * Must be call from main thread only.
-     * @param callback custom call back function
-     * @param priority call back priority
+     * @brief Adds a @p callback to be run on idle.
+     * @note Must be called from the main thread only.
+     *
+     * @param[in] callback custom callback function.
+     *
      * @return true on success
      */
     virtual bool AddIdleCallback( CallbackBase* callback ) = 0;
 
     /**
+     * @brief Removes a previously added @p callback.
+     * @note Must be called from main thread only.
+     *
+     * Does nothing if the @p callback doesn't exist.
+     *
+     * @param[in] callback The callback to be removed.
+     */
+    virtual void RemoveIdleCallback( CallbackBase* callback ) = 0;
+
+    /**
      * Starts the callback manager.
      */
     virtual void Start() = 0;
index b6e5f3c..77b525e 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2014 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -120,7 +120,7 @@ bool EcoreCallbackManager::AddIdleCallback( CallbackBase* callback )
     return false;
   }
 
-  CallbackData *callbackData = new CallbackData( callback );
+  CallbackDatacallbackData = new CallbackData( callback );
 
   callbackData->mRemoveFromContainerFunction =  MakeCallback( this, &EcoreCallbackManager::RemoveCallbackFromContainer );
 
@@ -135,6 +135,25 @@ bool EcoreCallbackManager::AddIdleCallback( CallbackBase* callback )
   return true;
 }
 
+void EcoreCallbackManager::RemoveIdleCallback( CallbackBase* callback )
+{
+  for( CallbackList::iterator it = mCallbackContainer.begin(),
+         endIt = mCallbackContainer.end();
+       it != endIt;
+       ++it )
+  {
+    CallbackData* data = *it;
+
+    if( data->mCallback == callback )
+    {
+      // remove callback data from the container.
+      CallbackBase::Execute( *data->mRemoveFromContainerFunction, data );
+
+      ecore_idler_del( data->mIdler );
+    }
+  }
+}
+
 void EcoreCallbackManager::RemoveCallbackFromContainer(CallbackData *callbackData)
 {
   mCallbackContainer.remove(callbackData);
index f93cc72..a158a4e 100644 (file)
@@ -2,7 +2,7 @@
 #define __DALI_ECORE_CALLBACK_MANAGER_H__
 
 /*
- * Copyright (c) 2014 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -57,11 +57,16 @@ public:
     }
 
     /**
-     * @copydoc CallbackManager::AddCallback()
+     * @copydoc CallbackManager::AddIdleCallback()
      */
     virtual bool AddIdleCallback( CallbackBase* callback );
 
     /**
+     * @copydoc CallbackManager::RemoveIdleCallback()
+     */
+    virtual void RemoveIdleCallback( CallbackBase* callback );
+
+    /**
      * @copydoc CallbackManager::Start()
      */
     virtual void Start();
index ab8552d..9aca9c8 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2014 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -154,7 +154,7 @@ bool UvCallbackManager::AddIdleCallback( CallbackBase* callback )
     return false;
   }
 
-  CallbackData *callbackData = new CallbackData(callback );
+  CallbackData *callbackData = new CallbackData( callback );
 
   // To inform the manager a callback has finished, we get it to call RemoveCallbackFromContainer
   callbackData->mRemoveFromContainerFunction =  MakeCallback( this, &UvCallbackManager::RemoveCallbackFromContainer );
@@ -168,6 +168,25 @@ bool UvCallbackManager::AddIdleCallback( CallbackBase* callback )
   return true;
 }
 
+void UvCallbackManager::RemoveIdleCallback( CallbackBase* callback )
+{
+  for( CallbackList::iterator it = mCallbackContainer.begin(),
+         endIt = mCallbackContainer.end();
+       it != endIt;
+       ++it )
+  {
+    CallbackData* data = *it;
+
+    if( data->mCallback == callback )
+    {
+      // remove callback data from the container.
+      CallbackBase::Execute( *data->mRemoveFromContainerFunction, data );
+
+      delete data;
+    }
+  }
+}
+
 void UvCallbackManager::RemoveCallbackFromContainer(CallbackData *callbackData)
 {
   mCallbackContainer.remove(callbackData);
index 78abab6..0fcc2c1 100644 (file)
@@ -2,7 +2,7 @@
 #define __DALI_UV_CALLBACK_MANAGER_H__
 
 /*
- * Copyright (c) 2014 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -56,11 +56,16 @@ public:
     ~UvCallbackManager(){}
 
     /**
-     * @copydoc CallbackManager::AddCallback()
+     * @copydoc CallbackManager::AddIdleCallback()
      */
     virtual bool AddIdleCallback( CallbackBase* callback );
 
     /**
+     * @copydoc CallbackManager::RemoveIdleCallback()
+     */
+    virtual void RemoveIdleCallback( CallbackBase* callback );
+
+    /**
      * @copydoc CallbackManager::Start()
      */
     virtual void Start();
index 4dacf5f..6037d57 100644 (file)
@@ -38,9 +38,12 @@ namespace Adaptor
 {
 
 /**
- * The Framework class is used to register callbacks with the TIZEN platform so that
+ * The Framework class is ideally placed to provide key API required by Applications.
+ *
+ * The class is also 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.
+ *
  */
 class Framework
 {
@@ -179,6 +182,11 @@ public:
    */
   std::string GetBundleId() const;
 
+  /**
+   *  Gets the path at which application resources are stored.
+   */
+  static std::string GetResourcePath();
+
 private:
 
   // Undefined
index f083c8b..4410609 100644 (file)
@@ -88,6 +88,11 @@ const std::string& ImfManager::GetSurroundingText() const
   return Internal::Adaptor::ImfManager::GetImplementation(*this).GetSurroundingText();
 }
 
+void ImfManager::NotifyTextInputMultiLine( bool multiLine )
+{
+  Internal::Adaptor::ImfManager::GetImplementation(*this).NotifyTextInputMultiLine( multiLine );
+}
+
 ImfManager::ImfManagerSignalType& ImfManager::ActivatedSignal()
 {
   return Internal::Adaptor::ImfManager::GetImplementation(*this).ActivatedSignal();
index a674ce7..8123b9d 100644 (file)
@@ -211,6 +211,13 @@ public:
    */
   const std::string& GetSurroundingText() const;
 
+  /**
+ * @brief Notifies IMF context that text input is set to multi line or not
+ *
+ * @param[in] multiLine True if multiline text input is used
+ */
+  void NotifyTextInputMultiLine( bool multiLine );
+
 public:
 
   // Signals
index 1d38c49..84a8aa2 100644 (file)
@@ -193,6 +193,8 @@ struct EventHandler::Impl
       mEcoreEventHandler.push_back( ecore_event_handler_add( ECORE_EVENT_KEY_DOWN,           EcoreEventKeyDown,         handler ) );
       mEcoreEventHandler.push_back( ecore_event_handler_add( ECORE_EVENT_KEY_UP,             EcoreEventKeyUp,           handler ) );
 
+      // Register Detent event
+      mEcoreEventHandler.push_back( ecore_event_handler_add( ECORE_EVENT_DETENT_ROTATE, EcoreEventDetent, handler) );
 #ifndef DALI_PROFILE_UBUNTU
       // Register Vconf notify - font name and size
       vconf_notify_key_changed( DALI_VCONFKEY_SETAPPL_ACCESSIBILITY_FONT_SIZE, VconfNotifyFontNameChanged, handler );
@@ -649,6 +651,22 @@ struct EventHandler::Impl
     return ECORE_CALLBACK_PASS_ON;
   }
 
+  /**
+   * Called when detent event is recevied
+   */
+  static Eina_Bool EcoreEventDetent( void* data, int type, void* event )
+  {
+    DALI_LOG_INFO(gSelectionEventLogFilter, Debug::Concise, "EcoreEventDetent\n" );
+    EventHandler* handler( (EventHandler*)data );
+    Ecore_Event_Detent_Rotate *e((Ecore_Event_Detent_Rotate *)event);
+    int direction = (e->direction == ECORE_DETENT_DIRECTION_CLOCKWISE) ? 1 : -1;
+    int timeStamp = e->timestamp;
+
+    WheelEvent wheelEvent( WheelEvent::CUSTOM_WHEEL, 0, 0, Vector2(0.0f, 0.0f), direction, timeStamp );
+    handler->SendWheelEvent( wheelEvent );
+    return ECORE_CALLBACK_PASS_ON;
+  }
+
   /////////////////////////////////////////////////////////////////////////////////////////////////
   // Font Callbacks
   /////////////////////////////////////////////////////////////////////////////////////////////////
index 825b444..e88e30a 100644 (file)
@@ -516,6 +516,14 @@ const std::string& ImfManager::GetSurroundingText() const
   return mSurroundingText;
 }
 
+void ImfManager::NotifyTextInputMultiLine( bool multiLine )
+{
+  Ecore_IMF_Input_Hints currentHint = ecore_imf_context_input_hint_get(mIMFContext);
+  ecore_imf_context_input_hint_set(mIMFContext, (Ecore_IMF_Input_Hints)(multiLine ?
+    (currentHint | ECORE_IMF_INPUT_HINT_MULTILINE) :
+    (currentHint & ~ECORE_IMF_INPUT_HINT_MULTILINE)));
+}
+
 } // Adaptor
 
 } // Internal
index 1fd8e16..391c56d 100644 (file)
@@ -151,6 +151,11 @@ public:
    */
   const std::string& GetSurroundingText() const;
 
+  /**
+  * @copydoc Dali::ImfManager::NotifyTextInputMultiLine()
+  */
+  void NotifyTextInputMultiLine( bool multiLine );
+
 public:  // Signals
 
   /**
index 8eabd4a..7de4d65 100644 (file)
@@ -2,7 +2,7 @@
 #define __DALI_INTEGRATION_ADAPTOR_H__
 
 /*
- * Copyright (c) 2014 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -198,6 +198,16 @@ public:
   bool AddIdle( CallbackBase* callback );
 
   /**
+   * @brief Removes a previously added @p callback.
+   * @note Function must be called from the main event thread only.
+   *
+   * Does nothing if the @p callback doesn't exist.
+   *
+   * @param[in] callback The callback to be removed.
+   */
+  void RemoveIdle( CallbackBase* callback );
+
+  /**
    * @brief Replaces the rendering surface
    *
    * @param[in] nativeWindow native window handle
index 1791792..ea7fe87 100644 (file)
@@ -154,6 +154,11 @@ public:
    */
   const std::string& GetSurroundingText() const;
 
+  /**
+  * @copydoc Dali::ImfManager::NotifyTextInputMultiLine()
+  */
+  void NotifyTextInputMultiLine( bool multiLine );
+
 public:  // Signals
 
   /**
index cc7dc77..3a8f3ae 100644 (file)
@@ -158,6 +158,12 @@ std::string Framework::GetBundleId() const
   return "";
 }
 
+std::string Framework::GetResourcePath()
+{
+  // TIZEN_PLATFORM_CONFIG_SUPPORTED not defined for libuv so path not available.
+  return "";
+}
+
 void Framework::SetBundleId(const std::string& id)
 {
 }
index 0a5e4f3..62908dd 100644 (file)
@@ -110,6 +110,11 @@ void Application::ReplaceWindow(PositionSize windowPosition, const std::string&
   Internal::Adaptor::GetImplementation(*this).ReplaceWindow(windowPosition, name);
 }
 
+std::string Application::GetResourcePath()
+{
+  return Internal::Adaptor::Application::GetResourcePath();
+}
+
 void Application::SetViewMode( ViewMode viewMode )
 {
   Internal::Adaptor::GetImplementation(*this).SetViewMode( viewMode );
index 997423f..5242ded 100644 (file)
@@ -145,6 +145,7 @@ public:
    * @param[in,out]  argc        A pointer to the number of arguments
    * @param[in,out]  argv        A pointer the the argument list
    * @param[in]      stylesheet  The path to user defined theme file
+   * @note If the stylesheet is not specified, then the library's default stylesheet will not be overridden.
    */
   static Application New( int* argc, char **argv[], const std::string& stylesheet );
 
@@ -156,6 +157,7 @@ public:
    * @param[in,out]  argv        A pointer the the argument list
    * @param[in]      stylesheet  The path to user defined theme file
    * @param[in]      windowMode  A member of WINDOW_MODE
+   * @note If the stylesheet is not specified, then the library's default stylesheet will not be overridden.
    */
   static Application New( int* argc, char **argv[], const std::string& stylesheet, WINDOW_MODE windowMode );
 
@@ -258,6 +260,15 @@ public:
    */
   void ReplaceWindow(PositionSize windowPosition, const std::string& name);
 
+  /**
+   * @brief Get path application resources are stored at
+   *
+   * @SINCE_1_2.2
+   * @return the full path of the resources
+   */
+  static std::string GetResourcePath();
+
+
 public: // Stereoscopy
 
   /**
@@ -277,6 +288,8 @@ public: // Stereoscopy
   /**
    * @brief Set the stereo base (eye separation) for Stereoscopic 3D
    *
+   * The stereo base is the distance in millimetres between the eyes. Typical values are
+   * between 50mm and 70mm. The default value is 65mm.
    * @SINCE_1_0.0
    * @param[in] stereoBase The stereo base (eye separation) for Stereoscopic 3D
    */
index 9e9ff5a..0332739 100755 (executable)
@@ -53,8 +53,11 @@ typedef Dali::IntrusivePtr<Dali::NativeImageSource> NativeImageSourcePtr;
  *
  * NativeImageSource can be created internally or
  * externally by native image source.
+ * NativeImage is a platform specific way of providing pixel data to the GPU for rendering,
+ * for example via an EGL image.
  *
  * @SINCE_1_1.4
+ * @see NativeImage
  */
 class DALI_IMPORT_API NativeImageSource : public NativeImageInterface
 {
@@ -91,6 +94,7 @@ public:
    * @SINCE_1_0.0
    * @param[in] nativeImageSource must be a any handle with native image source
    * @return A smart-pointer to a newly allocated image.
+   * @see NativeImageInterface
    */
   static NativeImageSourcePtr New( Any nativeImageSource );
 
index f2c46ca..cef2e92 100644 (file)
@@ -52,8 +52,8 @@ public: // ENUMs
   enum Mode
   {
     DEFAULT = 0,  ///< Default mode for normal application @SINCE_1_0.0
-    NOTIFICATION, ///< Notification mode @SINCE_1_0.0
-    SCREEN_READER, ///< Screen reader mode @SINCE_1_0.0
+    NOTIFICATION, ///< Notification mode, such as playing utterance is started or completed @SINCE_1_0.0
+    SCREEN_READER, ///< Screen reader mode. To help visually impaired users interact with their devices, screen reader reads text or graphic elements on the screen using the TTS engine. @SINCE_1_0.0
     MODE_NUM
   };
 
index ac10e5a..40872cd 100644 (file)
@@ -63,13 +63,13 @@ public:
   // Enumerations
 
   /**
-   * @brief Orientation of the window.
+   * @brief Orientation of the window is the way in which a rectangular page is oriented for normal viewing.
    * @SINCE_1_0.0
    */
   enum WindowOrientation
   {
-    PORTRAIT = 0,  ///< Portrait orientation @SINCE_1_0.0
-    LANDSCAPE = 90,  ///< Landscape orientation @SINCE_1_0.0
+    PORTRAIT = 0,  ///< Portrait orientation. The height of the display area is greater than the width. @SINCE_1_0.0
+    LANDSCAPE = 90,  ///< Landscape orientation. A wide view area is needed. @SINCE_1_0.0
     PORTRAIT_INVERSE = 180,  ///< Portrait inverse orientation @SINCE_1_0.0
     LANDSCAPE_INVERSE = 270  ///< Landscape inverse orientation @SINCE_1_0.0
   };
@@ -232,6 +232,7 @@ public:
 
   /**
    * @brief Returns the Drag & drop detector which can be used to receive drag & drop events.
+   * @note  Not intended for application developers.
    * @SINCE_1_0.0
    * @return A handle to the DragAndDropDetector.
    */
@@ -239,6 +240,8 @@ public:
 
   /**
    * @brief Get the native handle of the window.
+   *
+   * When users call this function, it wraps the actual type used by the underlying window system.
    * @SINCE_1_0.0
    * @return The native handle of the window or an empty handle.
    */
index 5717213..65daa11 100644 (file)
@@ -28,7 +28,7 @@ namespace Dali
 
 const unsigned int ADAPTOR_MAJOR_VERSION = 1;
 const unsigned int ADAPTOR_MINOR_VERSION = 2;
-const unsigned int ADAPTOR_MICRO_VERSION = 1;
+const unsigned int ADAPTOR_MICRO_VERSION = 2;
 const char * const ADAPTOR_BUILD_DATE    = __DATE__ " " __TIME__;
 
 #ifdef DEBUG_ENABLED
index 47ef3c4..d140a99 100644 (file)
 #include <appcore-watch/watch_app.h>
 #endif
 
+#if defined( TIZEN_PLATFORM_CONFIG_SUPPORTED ) && TIZEN_PLATFORM_CONFIG_SUPPORTED
+#include <tzplatform_config.h>
+#endif // TIZEN_PLATFORM_CONFIG_SUPPORTED
+
 #include <dali/integration-api/debug.h>
 
 // INTERNAL INCLUDES
@@ -391,6 +395,16 @@ std::string Framework::GetBundleId() const
   return mBundleId;
 }
 
+std::string Framework::GetResourcePath()
+{
+  std::string resourcePath = "";
+#if defined( TIZEN_PLATFORM_CONFIG_SUPPORTED ) && TIZEN_PLATFORM_CONFIG_SUPPORTED
+  resourcePath = app_get_resource_path();
+#endif //TIZEN_PLATFORM_CONFIG_SUPPORTED
+
+  return resourcePath;
+}
+
 void Framework::SetBundleId(const std::string& id)
 {
   mBundleId = id;
index fe706ea..22203cc 100644 (file)
@@ -194,6 +194,20 @@ std::string Framework::GetBundleId() const
   return mBundleId;
 }
 
+std::string Framework::GetResourcePath()
+{
+  // "DALI_APPLICATION_PACKAGE" is used by Ubuntu specifically to get the already configured Application package path.
+  const char* ubuntuEnvironmentVariable = "DALI_APPLICATION_PACKAGE";
+  char* value = getenv( ubuntuEnvironmentVariable );
+  std::string resourcePath;
+  if ( value != NULL )
+  {
+    resourcePath = value;
+  }
+
+  return resourcePath;
+}
+
 void Framework::SetBundleId(const std::string& id)
 {
   mBundleId = id;
index ad95ac5..731763e 100644 (file)
@@ -303,6 +303,10 @@ const std::string& ImfManager::GetSurroundingText() const
   return mSurroundingText;
 }
 
+void ImfManager::NotifyTextInputMultiLine( bool multiLine )
+{
+}
+
 } // Adaptor
 
 } // Internal
index 7a0d287..1af41bc 100644 (file)
@@ -148,6 +148,11 @@ public:
    */
   const std::string& GetSurroundingText() const;
 
+  /**
+  * @copydoc Dali::ImfManager::NotifyTextInputMultiLine()
+  */
+  void NotifyTextInputMultiLine( bool multiLine );
+
 public:  // Signals
 
   /**
index 57ffb35..14dc385 100644 (file)
@@ -516,6 +516,10 @@ const std::string& ImfManager::GetSurroundingText() const
   return mSurroundingText;
 }
 
+void ImfManager::NotifyTextInputMultiLine( bool multiLine )
+{
+}
+
 } // Adaptor
 
 } // Internal
index 15b99df..4e8e1d7 100644 (file)
@@ -356,6 +356,7 @@ libdali_adaptor_uv_la_CXXFLAGS = \
                       -DFONT_DOWNLOADED_PATH="\"${fontDownloadedPath}\"" \
                       -DFONT_APPLICATION_PATH="\"${fontApplicationPath}\"" \
                       -DFONT_CONFIGURATION_FILE="\"${fontConfigurationFile}\"" \
+                      -DTIZEN_PLATFORM_CONFIG_SUPPORTED=${tizenPlatformConfigSupported} \
                       -DNON_POWER_OF_TWO_TEXTURES \
                       -DDALI_COMPILATION -DDALI_ADAPTOR_COMPILATION \
                       -Werror -Wall -lgcc \
index 3e54632..e61fccf 100644 (file)
@@ -332,11 +332,18 @@ if test x$FONT_CONFIGURATION_FILE != x; then
   fontConfigurationFile=$FONT_CONFIGURATION_FILE
 fi
 
+if test x$TIZEN_PLATFORM_CONFIG_SUPPORTED != x; then
+  tizenPlatformConfigSupported=$TIZEN_PLATFORM_CONFIG_SUPPORTED
+else
+  tizenPlatformConfigSupported=0
+fi
+
 AC_SUBST(dataReadWriteDir)
 AC_SUBST(dataReadOnlyDir)
 AC_SUBST(DALI_ADAPTOR_CFLAGS)
 AC_SUBST(DALI_PROFILE_CFLAGS)
 AC_SUBST(fontConfigurationFile)
+AC_SUBST(tizenPlatformConfigSupported)
 
 # Specify the include directory for development headers
 #devincludepath=${includedir}/dali/internal
@@ -374,7 +381,9 @@ Configuration
   Font config file:                 $fontConfigurationFile
   Building with EFL Libraries:      $enable_efl
   Using Tizen APP FW libraries:     $enable_appfw
-  OpenGL ES version:                $enable_gles"
+  OpenGL ES version:                $enable_gles
+  Tizen Platform Config supported:  $tizenPlatformConfigSupported
+"
 # optional output of node.js source path if we're building with libuv
 if test "x$build_for_libuv" != "xno"; then
 echo "  LibUV header path                 $with_libuv"
index 1ddadf0..8670157 100644 (file)
@@ -375,6 +375,7 @@ libdali_adaptor_la_CXXFLAGS = \
                       -DFONT_DOWNLOADED_PATH="\"${fontDownloadedPath}\"" \
                       -DFONT_APPLICATION_PATH="\"${fontApplicationPath}\"" \
                       -DFONT_CONFIGURATION_FILE="\"${fontConfigurationFile}\"" \
+                      -DTIZEN_PLATFORM_CONFIG_SUPPORTED=${tizenPlatformConfigSupported} \
                       -DNON_POWER_OF_TWO_TEXTURES \
                       -DDALI_COMPILATION -DDALI_ADAPTOR_COMPILATION \
                       -Werror -Wall -lgcc \
index e9f3994..de27247 100644 (file)
@@ -314,6 +314,12 @@ else
   dataReadOnlyDir=${prefix}/share/dali/
 fi
 
+if test x$TIZEN_PLATFORM_CONFIG_SUPPORTED != x; then
+  tizenPlatformConfigSupported=$TIZEN_PLATFORM_CONFIG_SUPPORTED
+else
+  tizenPlatformConfigSupported=0
+fi
+
 if test x$FONT_CONFIGURATION_FILE != x; then
   fontConfigurationFile=$FONT_CONFIGURATION_FILE
 fi
@@ -323,6 +329,7 @@ AC_SUBST(dataReadOnlyDir)
 AC_SUBST(DALI_ADAPTOR_CFLAGS)
 AC_SUBST(DALI_PROFILE_CFLAGS)
 AC_SUBST(fontConfigurationFile)
+AC_SUBST(tizenPlatformConfigSupported)
 
 # Specify the include directory for development headers
 #devincludepath=${includedir}/dali/internal
@@ -362,6 +369,7 @@ Configuration
   Building with EFL Libraries:      $enable_efl
   Using Tizen APP FW libraries:     $enable_appfw
   OpenGL ES version:                $enable_gles
+  Tizen Platform Config supported   $tizenPlatformConfigSupported
 "
 # optional output of node.js source path if we're building with libuv
 if test "x$build_for_libuv" != "xno"; then
index 379c7a6..5b095ed 100644 (file)
@@ -14,7 +14,7 @@
 
 Name:       dali-adaptor
 Summary:    The DALi Tizen Adaptor
-Version:    1.2.1
+Version:    1.2.2
 Release:    1
 Group:      System/Libraries
 License:    Apache-2.0 and BSD-2-Clause and MIT
@@ -27,7 +27,8 @@ Requires:       giflib
 
 #need libtzplatform-config for directory if tizen version is 3.x
 
-%if "%{tizen_version_major}" == "3"
+%if "%{tizen_version_major}" >= "3"
+%define tizen_platform_config_supported 1
 BuildRequires:  pkgconfig(libtzplatform-config)
 %endif
 
@@ -228,22 +229,22 @@ VideoPlayer plugin to play a video file for Dali
 %prep
 %setup -q
 
-#Use TZ_PATH when tizen version is 3.x
+#Use TZ_PATH when tizen version is 3.x or greater
 
-%if "%{tizen_version_major}" == "2"
-%define dali_data_rw_dir         /usr/share/dali/
-%define dali_data_ro_dir         /usr/share/dali/
-%define font_preloaded_path      /usr/share/fonts/
-%define font_downloaded_path     /opt/share/fonts/
-%define font_application_path    /usr/share/app_fonts/
-%define font_configuration_file  /opt/etc/fonts/conf.avail/99-slp.conf
-%else
+%if "%{tizen_version_major}" >= "3"
 %define dali_data_rw_dir         %TZ_SYS_RO_SHARE/dali/
 %define dali_data_ro_dir         %TZ_SYS_RO_SHARE/dali/
 %define font_preloaded_path      %TZ_SYS_RO_SHARE/fonts/
 %define font_downloaded_path     %TZ_SYS_SHARE/fonts/
 %define font_application_path    %TZ_SYS_RO_SHARE/app_fonts/
 %define font_configuration_file  %TZ_SYS_ETC/fonts/conf.avail/99-slp.conf
+%else
+%define dali_data_rw_dir         /usr/share/dali/
+%define dali_data_ro_dir         /usr/share/dali/
+%define font_preloaded_path      /usr/share/fonts/
+%define font_downloaded_path     /opt/share/fonts/
+%define font_application_path    /usr/share/app_fonts/
+%define font_configuration_file  /opt/etc/fonts/conf.avail/99-slp.conf
 %endif
 
 %define user_shader_cache_dir    %{dali_data_ro_dir}/core/shaderbin/
@@ -283,6 +284,9 @@ FONT_PRELOADED_PATH="%{font_preloaded_path}" ; export FONT_PRELOADED_PATH
 FONT_DOWNLOADED_PATH="%{font_downloaded_path}" ; export FONT_DOWNLOADED_PATH
 FONT_APPLICATION_PATH="%{font_application_path}"  ; export FONT_APPLICATION_PATH
 FONT_CONFIGURATION_FILE="%{font_configuration_file}" ; export FONT_CONFIGURATION_FILE
+%if 0%{?tizen_platform_config_supported}
+TIZEN_PLATFORM_CONFIG_SUPPORTED="%{tizen_platform_config_supported}" ; export TIZEN_PLATFORM_CONFIG_SUPPORTED
+%endif
 
 # Default to GLES 2.0 if not specified.
 %{!?target_gles_version: %define target_gles_version 20}
index 9bb3657..8f8481c 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2014 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -259,13 +259,16 @@ bool HandleImageDescriptionRecordType( Bitmap& bitmap, GifFileType* gifInfo, uns
 bool HandleExtensionRecordType( GifFileType* gifInfo )
 {
   SavedImage image;
-  image.ExtensionBlocks     = NULL;
-  image.ExtensionBlockCount = 0;
   GifByteType *extensionByte( NULL );
 
 #ifdef LIBGIF_VERSION_5_1_OR_ABOVE
+  ExtensionBlock extensionBlocks;
+  image.ExtensionBlocks          = &extensionBlocks;
+  image.ExtensionBlockCount      = 1;
   int *extensionBlockTypePointer = &image.ExtensionBlocks->Function;
 #else
+  image.ExtensionBlocks     = NULL;
+  image.ExtensionBlockCount = 0;
   int *extensionBlockTypePointer = &image.Function;
 #endif