test: close the window at exit button 15/231915/1
authorHermet Park <chuneon.park@samsung.com>
Sun, 26 Apr 2020 09:47:34 +0000 (18:47 +0900)
committerHermet Park <chuneon.park@samsung.com>
Sun, 26 Apr 2020 09:47:34 +0000 (18:47 +0900)
Change-Id: Idf46d7132ae97356637816e54dc6c267be7122e6

test/testMergeShapes.cpp
test/testMultiShapes.cpp
test/testShape.cpp

index 3242df7..549ea9e 100644 (file)
@@ -38,6 +38,12 @@ void tvgtest()
     tvg::Engine::term();
 }
 
+void
+win_del(void *data, Evas_Object *o, void *ev)
+{
+   elm_exit();
+}
+
 
 int main(int argc, char **argv)
 {
@@ -47,6 +53,7 @@ int main(int argc, char **argv)
     elm_init(argc, argv);
 
     Eo* win = elm_win_util_standard_add(NULL, "TizenVG Test");
+    evas_object_smart_callback_add(win, "delete,request", win_del, 0);
 
     Eo* img = evas_object_image_filled_add(evas_object_evas_get(win));
     evas_object_image_size_set(img, WIDTH, HEIGHT);
index a73d2b6..94d3c31 100644 (file)
@@ -43,6 +43,12 @@ void tvgtest()
     tvg::Engine::term();
 }
 
+void
+win_del(void *data, Evas_Object *o, void *ev)
+{
+   elm_exit();
+}
+
 int main(int argc, char **argv)
 {
     tvgtest();
@@ -51,6 +57,7 @@ int main(int argc, char **argv)
     elm_init(argc, argv);
 
     Eo* win = elm_win_util_standard_add(NULL, "TizenVG Test");
+    evas_object_smart_callback_add(win, "delete,request", win_del, 0);
 
     Eo* img = evas_object_image_filled_add(evas_object_evas_get(win));
     evas_object_image_size_set(img, WIDTH, HEIGHT);
index 7d0aa88..c806d99 100644 (file)
@@ -34,6 +34,11 @@ void tvgtest()
     tvg::Engine::term();
 }
 
+void
+win_del(void *data, Evas_Object *o, void *ev)
+{
+   elm_exit();
+}
 
 int main(int argc, char **argv)
 {
@@ -43,6 +48,7 @@ int main(int argc, char **argv)
     elm_init(argc, argv);
 
     Eo* win = elm_win_util_standard_add(NULL, "TizenVG Test");
+    evas_object_smart_callback_add(win, "delete,request", win_del, 0);
 
     Eo* img = evas_object_image_filled_add(evas_object_evas_get(win));
     evas_object_image_size_set(img, WIDTH, HEIGHT);