[CallLog]update CallLog(tizen_2.1)
authorji.ji <ji.ji@samsung.com>
Tue, 4 Jun 2013 07:10:08 +0000 (16:10 +0900)
committerji.ji <ji.ji@samsung.com>
Tue, 4 Jun 2013 07:10:08 +0000 (16:10 +0900)
Change-Id: I2ae7f39899c300f8b9574196f78a0b4781aa1fd7

config.xml
icon.png
js/app.ui.js

index fabf393..511eac0 100644 (file)
@@ -1,17 +1,12 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<widget xmlns="http://www.w3.org/ns/widgets" xmlns:tizen="http://tizen.org/ns/widgets"
-       id="http://sample-web-application.tizen.org/CallLog" version="2.1.0"
-       viewmodes="maximized">
-       <tizen:application id="1I49ZSFY56.CallLog" package="1I49ZSFY56"
-               required_version="2.1" />
-       <content src="index.html" />
-       <icon src="icon.png" />
+<widget xmlns="http://www.w3.org/ns/widgets" xmlns:tizen="http://tizen.org/ns/widgets" id="http://sample-web-application.tizen.org/CallLog" version="2.1.0" viewmodes="maximized">
+       <tizen:application id="1I49ZSFY56.CallLog" package="1I49ZSFY56" required_version="2.1"/>
+       <content src="index.html"/>
+       <icon src="icon.png"/>
        <name>CallLog</name>
-       <tizen:privilege name="http://tizen.org/privilege/application.launch" />
-       <tizen:privilege name="http://tizen.org/privilege/callhistory.read" />
-       <tizen:privilege name="http://tizen.org/privilege/callhistory.write" />
-       <tizen:privilege name="http://tizen.org/privilege/contact.read" />
-       <tizen:setting screen-orientation="portrait"
-               context-menu="disable" background-support="disable" encryption="disable"
-               install-location="auto" />
+       <tizen:privilege name="http://tizen.org/privilege/application.launch"/>
+       <tizen:privilege name="http://tizen.org/privilege/callhistory.read"/>
+       <tizen:privilege name="http://tizen.org/privilege/callhistory.write"/>
+       <tizen:privilege name="http://tizen.org/privilege/contact.read"/>
+       <tizen:setting screen-orientation="portrait" context-menu="disable" background-support="disable" encryption="disable" install-location="auto"/>
 </widget>
index 9765b1b..5934757 100644 (file)
Binary files a/icon.png and b/icon.png differ
index d072cb8..e08b242 100644 (file)
@@ -128,6 +128,11 @@ function Ui(contacts) {
                        $('#smsActionBtn').on('tap', function (event) {
                                event.preventDefault();
                                event.stopPropagation();
+                               if ($(this).data('activated')) {
+                                       return false;
+                               }
+
+                               self.lockOptionButtons();
                                self.hideCheckboxes();
                                app.sendSms($('#forCallerList').data('remoteParty'));
                        });
@@ -135,16 +140,11 @@ function Ui(contacts) {
                        $('#callActionBtn').on("tap", function (event) {
                                event.preventDefault();
                                event.stopPropagation();
-                               var $this = jQuery(this);
-                               if ($this.data('activated')) {
+                               if ($(this).data('activated')) {
                                        return false;
                                }
 
-                               $this.data('activated', true);
-                               setTimeout(function () {
-                                       $this.data('activated', false);
-                               }, 2000);
-
+                               self.lockOptionButtons();
                                self.hideCheckboxes();
                                app.makeCall($('#forCallerList').data('remoteParty'));
 
@@ -176,6 +176,21 @@ function Ui(contacts) {
                                .on('click', '#popupSubmitActionBtn', this.deleteCheckedLogs.bind(this));
 
                        $('#errorPopup').on('tap', '#errorPopupOkBtn', this.closeErrorPopup);
+
+                       // workaround fix for N_SE-39520
+                       window.addEventListener('softkeyboardchange', function (e) {
+                               if (e.state === 'off') {
+                                       $.mobile.activePage.page('refresh');
+                               }
+                       });
+               },
+
+               lockOptionButtons: function () {
+                       var buttons = $('#callActionBtn, #smsActionBtn');
+                       buttons.data('activated', true);
+                       setTimeout(function () {
+                               buttons.data('activated', false);
+                       }, 2000);
                },
 
                addEventsForCallerListCheckboxes: function Ui_addEventsForCallerListCheckboxes() {
@@ -207,9 +222,15 @@ function Ui(contacts) {
 
                selectAllDetails: function Ui_selectAllDetails() {
                        if ($('#selectAllDetails').attr('checked')) {
-                               $('#selectAllDetails').attr('checked', true).data('checkboxradio').refresh();
+                               $('#selectAllDetails')
+                                       .attr('checked', true)
+                                       .data('checkboxradio')
+                                       .refresh();
                        } else {
-                               $('#selectAllDetails').attr('checked', false).data('checkboxradio').refresh();
+                               $('#selectAllDetails')
+                                       .attr('checked', false)
+                                       .data('checkboxradio')
+                                       .refresh();
                        }
                        this.selectAllDetailsEach();
                },
@@ -431,6 +452,14 @@ function Ui(contacts) {
                                .empty()
                                .append(elements);
 
+                       /* workaround for registering call during working app in removeMode */
+                       if (this.removeMode) {
+                               if ($('#selectAllDetails').attr('checked')){
+                                       this.selectAllDetails();
+                               }
+                               $('#forCallerList .toRemove').show()
+                       }
+
                        /* workaround for UIFW & webkit scroll*/
                        $.mobile.activePage.css('min-height', 0);
                },
@@ -633,11 +662,8 @@ function Ui(contacts) {
                },
 
                scrollToBottom: function () {
-                       var area = $(".ui-scrollview-view"),
-                               diff = area.height() - area.parent().height();
-                       if (diff >= 0) {
-                               area.css('-webkit-transform', 'translate3d(0,-' + diff + 'px,0)');
-                       }
+                       var scrollView = $(".ui-scrollview-view");
+                       scrollView.css("-webkit-transform", "translate3d(0px, -" + scrollView.height() + "px, 0px)");
                },
 
                /**