ICEmobile
  1. ICEmobile
  2. MOBI-141

Incremental Update for cloud notifications

    Details

    • Type: New Feature New Feature
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.0 Beta
    • Fix Version/s: 1.1 Beta
    • Component/s: None
    • Labels:
      None
    • Environment:
      ICEmobile

      Description

      Current strategy for handling a C2DM notification in Android container, is to cause a page reload. What we really want is to do a page update just as if it had been a normal icepush notification. The icepush bridge needs to provide an API that will allow this, and the container integration needs to use it.

        Activity

        Hide
        Steve Maryka added a comment -

        Assigning to mircea to provide the bridge api required. Can assign back to me for doing Android container integration. Once we have that working, we can look at Apple and BB.

        Show
        Steve Maryka added a comment - Assigning to mircea to provide the bridge api required. Can assign back to me for doing Android container integration. Once we have that working, we can look at Apple and BB.
        Hide
        Ted Goddard added a comment -

        The bridge already provides pause and resume APIs for the push connection, so likely the only thing necessary is an ICEfaces bridge method to request a page update.

        When we expand further to non-ICEfaces applications, we will likely need to include the pushid in the notification callback, which may or may not be possible on the different platforms.

        Show
        Ted Goddard added a comment - The bridge already provides pause and resume APIs for the push connection, so likely the only thing necessary is an ICEfaces bridge method to request a page update. When we expand further to non-ICEfaces applications, we will likely need to include the pushid in the notification callback, which may or may not be possible on the different platforms.
        Hide
        Mircea Toma added a comment -

        Made the internal ICEfaces bridge function for retrieving updates public. The function signature is ice.retrieveUpdate(pushID) where the parameter is the pushID that the function will retrieve the update for. The function returns another function that can be called repeatedly, ready to be used as a callback.

        Usage:

        var updateView = ice.retrieveUpdate(pushID);
        ice.push.register([pushID], updateView);

        Show
        Mircea Toma added a comment - Made the internal ICEfaces bridge function for retrieving updates public. The function signature is ice.retrieveUpdate(pushID) where the parameter is the pushID that the function will retrieve the update for. The function returns another function that can be called repeatedly, ready to be used as a callback. Usage: var updateView = ice.retrieveUpdate(pushID); ice.push.register( [pushID] , updateView);
        Hide
        Ted Goddard added a comment -

        We likely need something with no parameters like

        ice.ajaxRefresh()

        That will update the current page using ajax. To make this compatible with portlet applications, each view should register so that the above call would result in an ajax update of every view on the page.

        Show
        Ted Goddard added a comment - We likely need something with no parameters like ice.ajaxRefresh() That will update the current page using ajax. To make this compatible with portlet applications, each view should register so that the above call would result in an ajax update of every view on the page.
        Hide
        Mircea Toma added a comment -

        Implemented ice.ajaxRefresh(viewID) public function that can be used to retrieve the partial updates. When viewID (which is also a pushID) is not provided the function assumes that there's only one view in the page, the viewID will be looked up internally.

        Show
        Mircea Toma added a comment - Implemented ice.ajaxRefresh(viewID) public function that can be used to retrieve the partial updates. When viewID (which is also a pushID) is not provided the function assumes that there's only one view in the page, the viewID will be looked up internally.
        Hide
        Steve Maryka added a comment -

        This has been added to the Android container, and is working well. Not only less intrusive from the user perspective, but simplifies processing in the container. No longer need to disable the update if user is using the camera for instance. The thumbnail and hidden fields stay intact while the carousel updates when returning to the main activity from the camera.

        Show
        Steve Maryka added a comment - This has been added to the Android container, and is working well. Not only less intrusive from the user perspective, but simplifies processing in the container. No longer need to disable the update if user is using the camera for instance. The thumbnail and hidden fields stay intact while the carousel updates when returning to the main activity from the camera.
        Hide
        Ted Goddard added a comment -

        The native-interface.js files now contain define the function ice.mobiRefresh(). This will invoke ice.ajaxRefresh() if available or window.location.reload if not.

        Show
        Ted Goddard added a comment - The native-interface.js files now contain define the function ice.mobiRefresh(). This will invoke ice.ajaxRefresh() if available or window.location.reload if not.
        Hide
        Ted Goddard added a comment -

        ajaxRefresh was being invoked, but seemed to have no effect on the iPhone, so is now being invoked via setTimeout of 50ms.

        Show
        Ted Goddard added a comment - ajaxRefresh was being invoked, but seemed to have no effect on the iPhone, so is now being invoked via setTimeout of 50ms.

          People

          • Assignee:
            Mircea Toma
            Reporter:
            Steve Maryka
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: