[TSAM-1699] Corrected the size check on full mode 87/64887/1 accepted/tizen/mobile/20160407.002116 submit/tizen_mobile/20160406.114947
authorRahul Dadhich <r.dadhich@samsung.com>
Wed, 6 Apr 2016 04:38:18 +0000 (10:08 +0530)
committerRahul Dadhich <r.dadhich@samsung.com>
Wed, 6 Apr 2016 04:38:18 +0000 (10:08 +0530)
Change-Id: I648e3f6a2baddfb6dc1dc8f1b5e6ff800a1a727a
Signed-off-by: Rahul Dadhich <r.dadhich@samsung.com>
src/view/ge-albums.c

index da2fe96..c46bbb3 100644 (file)
@@ -1011,7 +1011,7 @@ __ge_check_state_changed_cb(void *data, Evas_Object *obj, void *ei)
                        return;
                }
 #ifdef FEATURE_SIZE_CHECK
-               if (ugd->selsize + stFileInfo.st_size > ugd->limitsize) {
+               if (ugd->limitsize > 0 && ugd->selsize + stFileInfo.st_size > ugd->limitsize) {
                        elm_check_state_set(obj, EINA_FALSE);
                        notification_status_message_post("maximum of 2MB can be selected");
                        _ge_data_util_free_sel_item(sit);
@@ -1342,7 +1342,7 @@ __ge_gengrid_item_sel_cb(void *data, Evas_Object *obj, void *ei)
 #ifdef FEATURE_SIZE_CHECK
                        struct stat stFileInfo;
                        stat(sit->file_url, &stFileInfo);
-                       if (ugd->selsize + stFileInfo.st_size > ugd->limitsize) {
+                       if (ugd->limitsize > 0 && ugd->selsize + stFileInfo.st_size > ugd->limitsize) {
                                notification_status_message_post("maximum of 2MB can be selected");
                                _ge_data_util_free_sel_item(sit);
                                return;