Revert "[3.0] Temporary implement copy/paste text" 85/97685/1
authordongsug.song <dongsug.song@samsung.com>
Tue, 15 Nov 2016 00:34:36 +0000 (09:34 +0900)
committerdongsug.song <dongsug.song@samsung.com>
Tue, 15 Nov 2016 00:34:39 +0000 (09:34 +0900)
This reverts commit 322efb8d4c64d95cb2a5f3fe0b7d97d34d0c58b9.

Change-Id: Ia5223ead429595976d5c161b5430a28069d50e8b

adaptors/ecore/wayland/clipboard-impl-ecore-wl.cpp

index 513ec21..cea687c 100644 (file)
 #include <dali/public-api/object/any.h>
 #include <dali/public-api/object/type-registry.h>
 #include <dali/integration-api/debug.h>
-#include <bundle.h>
 
 // INTERNAL INCLUDES
 #include <singleton-service-impl.h>
 
-#define CLIPBOARD_STR  "CLIPBOARD_STR"
+namespace //unnamed namespace
+{
+const char* const CBHM_WINDOW = "CBHM_XWIN";
+const char* const CBHM_MSG = "CBHM_MSG";
+const char* const CBHM_ITEM = "CBHM_ITEM";
+const char* const CBHM_cCOUNT = "CBHM_cCOUNT";
+const char* const CBHM_ERROR = "CBHM_ERROR";
+const char* const SET_ITEM = "SET_ITEM";
+const char* const SHOW = "show0";
+const char* const HIDE = "cbhm_hide";
+}
 
 ///////////////////////////////////////////////////////////////////////////////////////////////////
 // Clipboard
@@ -46,33 +55,7 @@ namespace Adaptor
 
 struct Clipboard::Impl
 {
-  Impl()
-  {
-    mBundle = bundle_create();
-  }
-
-  void SetItem(const char *data)
-  {
-    bundle_add_str(mBundle, CLIPBOARD_STR, data);
-  }
-
-  char *GetItem()
-  {
-    char *data = NULL;
-
-    if ( bundle_get_count(mBundle) )
-    {
-      bundle_get_str(mBundle, CLIPBOARD_STR, &data);
-    }
-    return data;
-  }
-
-  int GetCount()
-  {
-    return bundle_get_count(mBundle);
-  }
-
-  bundle *mBundle;
+  // Put implementation here.
 };
 
 Clipboard::Clipboard(Impl* impl)
@@ -111,7 +94,6 @@ Dali::Clipboard Clipboard::Get()
 
 bool Clipboard::SetItem(const std::string &itemData )
 {
-  mImpl->SetItem( const_cast<char*>( itemData.c_str()) );
   return true;
 }
 
@@ -120,8 +102,16 @@ bool Clipboard::SetItem(const std::string &itemData )
  */
 std::string Clipboard::GetItem( unsigned int index )  // change string to a Dali::Text object.
 {
-  std::string clipboardString(mImpl->GetItem());
-  return clipboardString;
+  if ( index >= NumberOfItems() )
+  {
+    return "";
+  }
+
+  std::string emptyString( "" );
+  char sendBuf[20];
+
+  snprintf( sendBuf, 20,  "%s%d", CBHM_ITEM, index );
+  return emptyString;
 }
 
 /*
@@ -129,7 +119,9 @@ std::string Clipboard::GetItem( unsigned int index )  // change string to a Dali
  */
 unsigned int Clipboard::NumberOfItems()
 {
-  return mImpl->GetCount();
+  int count = -1;
+
+  return count;
 }
 
 /**