fix potentional errors by svace
authorWonki Kim <wonki_.kim@samsung.com>
Tue, 17 Dec 2019 01:56:00 +0000 (10:56 +0900)
committerJongmin Lee <jm105.lee@samsung.com>
Mon, 30 Dec 2019 00:27:52 +0000 (09:27 +0900)
Change-Id: I54211f3fc5534f90cd9b3769313a4ce1d610b673

bootstrap/server/src/ObjectMapper.cc
libaurum/src/DeviceImpl/TM1Impl.cc

index 1c7a703..75bf956 100644 (file)
@@ -20,7 +20,7 @@ std::string ObjectMapper::addElement(std::unique_ptr<UiObject> object)
 
 UiObject *ObjectMapper::getElement(const std::string &key)
 {
-    unsigned long long keyCnt = (unsigned long long)std::stoi(key); // this key is a result of calling std:to_string(mObjCounter)
+    unsigned long long keyCnt = (unsigned long long)std::stoll(key); // this key is a result of calling std:to_string(mObjCounter)
     if (keyCnt <= 0 || keyCnt > mObjCounter) return nullptr;
     if (mObjectMap.count(key)) {
         UiObject *obj = mObjectMap[key].get();
index f55c427..82d4eef 100644 (file)
@@ -31,7 +31,7 @@ bool TM1Impl::click(const int x, const int y)
 #ifdef GBSBUILD
     efl_util_input_generate_touch(mFakeTouchHandle, 0,
                                   EFL_UTIL_INPUT_TOUCH_BEGIN, x, y);
-    usleep(50);
+    usleep(5*10000);
     efl_util_input_generate_touch(mFakeTouchHandle, 0, EFL_UTIL_INPUT_TOUCH_END,
                                   x, y);
     return true;
@@ -77,6 +77,7 @@ bool TM1Impl::drag(const int sx, const int sy, const int ex, const int ey,
     int i, j;
 
     // TODO fixed fps implementation
+    if (duration < 10) duration = 10;
 
     i = sx, j = sy;
     LOG_SCOPE_F(INFO, "flicking (%d, %d)", i, j);
@@ -138,4 +139,4 @@ bool TM1Impl::pressKeyCode(std::string keycode)
 bool TM1Impl::takeScreenshot(std::string path, float scale, int quality)
 {
     return false;
-}
\ No newline at end of file
+}