Recover PixmapImage::GetPixmap() without any parameters (no build break) 31/33631/1
authorYoonsang Lee <ysang114.lee@samsung.com>
Tue, 13 Jan 2015 10:32:36 +0000 (19:32 +0900)
committerYoonsang Lee <ysang114.lee@samsung.com>
Tue, 13 Jan 2015 10:33:22 +0000 (19:33 +0900)
Change-Id: I5521d11379c3f26088f86a56bc030e6815072377

adaptors/public-api/adaptor-framework/pixmap-image.cpp
adaptors/public-api/adaptor-framework/pixmap-image.h
adaptors/wayland/pixmap-image-impl-wl.cpp
adaptors/wayland/pixmap-image-impl.h
adaptors/x11/pixmap-image-impl-x.cpp
adaptors/x11/pixmap-image-impl.h

index e4b16eb..fcc8715 100644 (file)
@@ -34,6 +34,11 @@ PixmapImagePtr PixmapImage::New( unsigned int width, unsigned int height, ColorD
   return image;
 }
 
+Any PixmapImage::GetPixmap()
+{
+  return mImpl->GetPixmap();
+}
+
 PixmapImagePtr PixmapImage::New( Any pixmap )
 {
   PixmapImagePtr image = new PixmapImage(0, 0, COLOR_DEPTH_DEFAULT, pixmap);
index e0425a7..4960a65 100644 (file)
@@ -85,6 +85,13 @@ public:
   static PixmapImagePtr New( Any pixmap );
 
   /**
+   * @brief Retrieve the internal pixmap
+   *
+   * @return pixmap any object containing the internal pixmap
+   */
+  Any GetPixmap();
+
+  /**
    * @brief Get a copy of the pixels used by PixmapImage.
    *
    * This is only supported for 24 bit RGB and 32 bit RGBA internal formats
index 70a6423..86d7c51 100644 (file)
@@ -78,6 +78,12 @@ PixmapImage::~PixmapImage()
 {
 }
 
+Any PixmapImage::GetPixmap() const
+{
+  DALI_ASSERT_ALWAYS( false && "PixmapImage::GetPixmap() is not supported for Wayland." );
+  return Any();
+}
+
 bool PixmapImage::GetPixels(std::vector<unsigned char>& pixbuf, unsigned& width, unsigned& height, Pixel::Format& pixelFormat) const
 {
     return false;
index 86120ff..7ef1fed 100644 (file)
@@ -55,6 +55,11 @@ public:
                           Any pixmap);
 
   /**
+   * @copydoc Dali::PixmapImage::GetPixmap()
+   */
+  Any GetPixmap() const;
+
+  /**
    * @copydoc Dali::PixmapImage::GetPixels()
    */
   bool GetPixels(std::vector<unsigned char> &pixbuf, unsigned int &width, unsigned int &height, Pixel::Format& pixelFormat ) const;
index c200b64..3f96cc6 100644 (file)
@@ -136,6 +136,12 @@ PixmapImage::~PixmapImage()
   }
 }
 
+Any PixmapImage::GetPixmap() const
+{
+  // return ecore x11 type
+  return Any(mPixmap);
+}
+
 bool PixmapImage::GetPixels(std::vector<unsigned char>& pixbuf, unsigned& width, unsigned& height, Pixel::Format& pixelFormat) const
 {
   DALI_ASSERT_DEBUG(sizeof(unsigned) == 4);
index bd47110..215323d 100644 (file)
@@ -54,6 +54,10 @@ public:
                           unsigned int height,
                           Dali::PixmapImage::ColorDepth depth,
                           Any pixmap);
+  /**
+   * @copydoc Dali::PixmapImage::GetPixmap()
+   */
+  Any GetPixmap() const;
 
   /**
    * @copydoc Dali::PixmapImage::GetPixels()