ICEmobile
  1. ICEmobile
  2. MOBI-236

augmentedReality component and JSP tag

    Details

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

      Description

      <mobi:augmentedReality value="#{bean.location}" urlBase="#{bean.baseURL}">
        <mobi:selectLocations value="#{bean.locationList}"
                       var="place"
                       locationLabel="#{place.name}"
                       locationLat="#{place.latitude}"
                       locationLon="#{place.longitude}"
                       locationAlt="#{place.altitude}"
                       locationIcon="#{place.icon}"
                      />
      </mobi:augmentedReality>

      This will write out the following JavaScript call for the onclick of a button:

      ice.aug(id, "ub=urlBase&labelName1=lat,lon,alt,icon&labelName2=lat,lon,alt,icon");

      If altitude is not specified, the value is written as labelName=lat,lon,,icon

      If icon is not specified, the value is written as labelName=lat,lon,alt

      If icon and altitude is not specified, the value is written as labelName=lat,lon

      The selectLocations tag relies on EL providing method names to a JavaBean.

        Activity

        Ted Goddard created issue -
        Hide
        Ted Goddard added a comment -

        Initial testing will likely need to be from static data in the application since the existing map component does not support markers.

        Show
        Ted Goddard added a comment - Initial testing will likely need to be from static data in the application since the existing map component does not support markers.
        Ted Goddard made changes -
        Field Original Value New Value
        Assignee Steve Maryka [ steve.maryka ] Judy Guglielmin [ judy.guglielmin ]
        Ted Goddard made changes -
        Assignee Judy Guglielmin [ judy.guglielmin ] Ted Goddard [ ted.goddard ]
        Hide
        Ted Goddard added a comment -

        JSP tag now implemented.

        Show
        Ted Goddard added a comment - JSP tag now implemented.
        Hide
        Ted Goddard added a comment - - edited

        It would be enough to implement a component that just renders a button; after that I could port over the JSP tag code.

        The problem is that the tag should actually be implemented in two parts as follows (since it resembles a selectOneMenu):

        <mobi:augmentedReality value="#

        {bean.location}

        " urlBase="#

        {bean.baseURL}

        ">
        <mobi:selectLocations value="#

        {bean.locationList}

        "
        var="place"
        locationLabel="#

        {place.name}

        "
        locationLat="#

        {place.latitude}

        "
        locationLon="#

        {place.longitude}

        "
        locationAlt="#

        {place.altitude}

        "
        locationIcon="#

        {place.icon}

        "
        />
        </mobi:augmentedReality>

        Whereas the current JSP tag is as follows and expects the Bean code to format the location list as "params":

        <mobi:augmentedReality id="selection"
        style="float:right" params="$

        {reality}

        "/>

        The alpha could ship with the simplified tag and component and then be enhanced later (so a component that renders a button and has a String "params" attribute is sufficient for the first version).

        (edited to match original specification)

        Show
        Ted Goddard added a comment - - edited It would be enough to implement a component that just renders a button; after that I could port over the JSP tag code. The problem is that the tag should actually be implemented in two parts as follows (since it resembles a selectOneMenu): <mobi:augmentedReality value="# {bean.location} " urlBase="# {bean.baseURL} "> <mobi:selectLocations value="# {bean.locationList} " var="place" locationLabel="# {place.name} " locationLat="# {place.latitude} " locationLon="# {place.longitude} " locationAlt="# {place.altitude} " locationIcon="# {place.icon} " /> </mobi:augmentedReality> Whereas the current JSP tag is as follows and expects the Bean code to format the location list as "params": <mobi:augmentedReality id="selection" style="float:right" params="$ {reality} "/> The alpha could ship with the simplified tag and component and then be enhanced later (so a component that renders a button and has a String "params" attribute is sufficient for the first version). (edited to match original specification)
        Ted Goddard made changes -
        Assignee Ted Goddard [ ted.goddard ] Judy Guglielmin [ judy.guglielmin ]
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #29301 Tue Jun 05 11:30:50 MDT 2012 judy.guglielmin MOBI-236 intial jsf component checkin with test page in mobitest
        Files Changed
        Commit graph ADD /icemobile/trunk/icemobile/components/component/src/org/icefaces/mobi/component/augmentedreality/AugmentedReality.java
        Commit graph ADD /icemobile/trunk/icemobile/components/component/src/org/icefaces/mobi/component/augmentedreality/AugmentedRealityRenderer.java
        Commit graph ADD /icemobile/trunk/icemobile/components/tests/mobitest/src/main/webapp/container/augmentedReality.xhtml
        Commit graph MODIFY /icemobile/trunk/icemobile/components/tests/mobitest/src/main/webapp/containerComponents.html
        Commit graph ADD /icemobile/trunk/icemobile/components/component/src/org/icefaces/mobi/component/augmentedreality/AugmentedRealityMeta.java
        Commit graph ADD /icemobile/trunk/icemobile/components/component/src/org/icefaces/mobi/component/augmentedreality
        Hide
        Judy Guglielmin added a comment -

        Initial jsf component writes the following:-

        Based on this:-

        <mobi:augmentedReality params="myparams" />

        renders:

        <input type="button" value="Reality" onclick="ice.aug(this);"
        data-params="myparams" id="myid" />

        If the value attribute is empty, it will default to "Reality" for the button. An input text field will be displayed if the container or icemobileSX is not detected.

        a test page has been created under mobitest/container/augmentedReality.xhtml

        Show
        Judy Guglielmin added a comment - Initial jsf component writes the following:- Based on this:- <mobi:augmentedReality params="myparams" /> renders: <input type="button" value="Reality" onclick="ice.aug(this);" data-params="myparams" id="myid" /> If the value attribute is empty, it will default to "Reality" for the button. An input text field will be displayed if the container or icemobileSX is not detected. a test page has been created under mobitest/container/augmentedReality.xhtml
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #29956 Thu Jul 12 13:37:09 MDT 2012 judy.guglielmin MOBI-236 implemented augmentedRealityLocations as well as augmentedRealityLocation. WIth some semblance of use. Suggestion is to place functionality of the list into the base augmentedReality class as then the decode can get the value on the list onchange event and deal with it directly.
        Files Changed
        Commit graph MODIFY /icemobile/trunk/icemobile/jsf/components/tests/mobitest/src/main/webapp/container/augmentedReality.xhtml
        Commit graph MODIFY /icemobile/trunk/icemobile/jsf/components/tests/mobitest/src/main/java/org/icefaces/mobile/PositionBean.java
        Commit graph ADD /icemobile/trunk/icemobile/jsf/components/component/src/org/icefaces/mobi/component/augmentedreality/AugmentedRealityLocationMeta.java
        Commit graph ADD /icemobile/trunk/icemobile/jsf/components/component/src/org/icefaces/mobi/component/augmentedreality/AugmentedRealityLocations.java
        Commit graph ADD /icemobile/trunk/icemobile/jsf/components/component/src/org/icefaces/mobi/component/augmentedreality/AugmentedRealityLocationRenderer.java
        Commit graph ADD /icemobile/trunk/icemobile/jsf/components/component/src/org/icefaces/mobi/component/augmentedreality/AugmentedRealityLocationsRenderer.java
        Commit graph ADD /icemobile/trunk/icemobile/jsf/components/component/src/org/icefaces/mobi/component/augmentedreality/AugmentedRealityLocationsMeta.java
        Commit graph ADD /icemobile/trunk/icemobile/jsf/components/component/src/org/icefaces/mobi/component/augmentedreality/AugmentedRealityLocation.java
        Hide
        Judy Guglielmin added a comment -

        please see mobitest/container/augmentedReality.xhtml

        my suggestion is to take the list capability and place it within the augmentedReality tag. Then the decode can deal with the change in the list selection as input into the augmentedReality container component.

        Show
        Judy Guglielmin added a comment - please see mobitest/container/augmentedReality.xhtml my suggestion is to take the list capability and place it within the augmentedReality tag. Then the decode can deal with the change in the list selection as input into the augmentedReality container component.
        Judy Guglielmin made changes -
        Assignee Judy Guglielmin [ judy.guglielmin ] Ted Goddard [ ted.goddard ]
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #30014 Mon Jul 16 17:49:07 MDT 2012 ted.goddard iteration from AugmentedReality component over AugmentedRealityLocations (MOBI-236)
        Files Changed
        Commit graph MODIFY /icemobile/trunk/icemobile/samples/mediacast/src/main/webapp/WEB-INF/includes/content/home.xhtml
        Commit graph MODIFY /icemobile/trunk/icemobile/jsf/components/tests/mobitest/src/main/webapp/container/augmentedReality.xhtml
        Commit graph MODIFY /icemobile/trunk/icemobile/jsf/components/component/src/org/icefaces/mobi/component/augmentedreality/AugmentedRealityRenderer.java
        Commit graph DEL /icemobile/trunk/icemobile/jsf/components/component/src/org/icefaces/mobi/component/augmentedreality/AugmentedRealityLocationMeta.java
        Commit graph MODIFY /icemobile/trunk/icemobile/samples/mobileshowcase/src/main/java/org/icemobile/samples/mobileshowcase/view/examples/device/reality/RealityBean.java
        Commit graph MODIFY /icemobile/trunk/icemobile/samples/mobileshowcase/src/main/webapp/WEB-INF/includes/examples/device/reality-example.xhtml
        Commit graph DEL /icemobile/trunk/icemobile/jsf/components/component/src/org/icefaces/mobi/component/augmentedreality/AugmentedRealityLocationRenderer.java
        Commit graph MODIFY /icemobile/trunk/icemobile/jsf/components/component/src/org/icefaces/mobi/component/augmentedreality/AugmentedRealityLocationsRenderer.java
        Commit graph MODIFY /icemobile/trunk/icemobile/jsf/components/component/src/org/icefaces/mobi/component/augmentedreality/AugmentedRealityLocationsMeta.java
        Commit graph DEL /icemobile/trunk/icemobile/jsf/components/component/src/org/icefaces/mobi/component/augmentedreality/AugmentedRealityLocation.java
        Commit graph MODIFY /icemobile/trunk/icemobile/samples/mediacast/src/main/java/org/icemobile/samples/mediacast/MediaStore.java
        Commit graph MODIFY /icemobile/trunk/icemobile/samples/mediacast/src/main/java/org/icemobile/samples/mediacast/MediaMessage.java
        Hide
        Ted Goddard added a comment -

        The main AugmentedReality component has been modified to perform iteration over any AugmentedRealityLocations found as children:

        <mobi:augmentedReality value="#

        {realityBean.selection}

        ">
        <mobi:augmentedRealityLocations
        value="#

        {realityBean.messages}

        " var="place"
        locationLabel="#

        {place.title}

        "
        locationLat="#

        {place.latitude}

        "
        locationLon="#

        {place.longitude}

        "
        locationIcon="#

        {place.fileName}

        " />
        </mobi:augmentedReality>

        Show
        Ted Goddard added a comment - The main AugmentedReality component has been modified to perform iteration over any AugmentedRealityLocations found as children: <mobi:augmentedReality value="# {realityBean.selection} "> <mobi:augmentedRealityLocations value="# {realityBean.messages} " var="place" locationLabel="# {place.title} " locationLat="# {place.latitude} " locationLon="# {place.longitude} " locationIcon="# {place.fileName} " /> </mobi:augmentedReality>
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #30017 Tue Jul 17 09:00:32 MDT 2012 ted.goddard adding file missed in checkin (MOBI-236)
        Files Changed
        Commit graph ADD /icemobile/trunk/icemobile/samples/mobileshowcase/src/main/java/org/icemobile/samples/mobileshowcase/view/examples/device/reality/RealityMessage.java
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #30019 Tue Jul 17 10:18:24 MDT 2012 ted.goddard urlBase for efficient AR image URLs (MOBI-236)
        Files Changed
        Commit graph MODIFY /icemobile/trunk/icemobile/jsf/components/component/src/org/icefaces/mobi/component/augmentedreality/AugmentedRealityRenderer.java
        Commit graph MODIFY /icemobile/trunk/icemobile/samples/mobileshowcase/src/main/java/org/icemobile/samples/mobileshowcase/view/examples/device/reality/RealityBean.java
        Commit graph MODIFY /icemobile/trunk/icemobile/samples/mobileshowcase/src/main/webapp/WEB-INF/includes/examples/device/reality-example.xhtml
        Commit graph MODIFY /icemobile/trunk/icemobile/jsf/components/component/src/org/icefaces/mobi/component/augmentedreality/AugmentedRealityMeta.java
        Hide
        Ted Goddard added a comment -

        The JSF component has been fully implemented, so the JSP tag should be attempted for 1.1 Final.

        Show
        Ted Goddard added a comment - The JSF component has been fully implemented, so the JSP tag should be attempted for 1.1 Final.
        Ted Goddard made changes -
        Fix Version/s 1.1 Final [ 10343 ]
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #30368 Wed Aug 01 17:46:41 MDT 2012 ted.goddard augmentedReality JSP tag supporting c:forEach augmentedRealityLocation (MOBI-236)
        Files Changed
        Commit graph MODIFY /icemobile/trunk/icemobile/samples/icemobilespring/src/main/java/org/icemobile/samples/springbasic/MediaSpotController.java
        Commit graph MODIFY /icemobile/trunk/icemobile/samples/icemobilespring/src/main/java/org/icemobile/samples/springbasic/MediaSpotBean.java
        Commit graph MODIFY /icemobile/trunk/icemobile/jsp/src/main/resources/META-INF/icemobile.tld
        Commit graph ADD /icemobile/trunk/icemobile/jsp/src/main/java/org/icemobile/jsp/tags/AugmentedRealityLocationTag.java
        Commit graph MODIFY /icemobile/trunk/icemobile/samples/icemobilespring/src/main/webapp/WEB-INF/views/mediaspot.jsp
        Commit graph MODIFY /icemobile/trunk/icemobile/jsp/src/main/java/org/icemobile/jsp/tags/AugTag.java
        Commit graph MODIFY /icemobile/trunk/icemobile/jsp/src/main/java/org/icemobile/jsp/tags/DeviceTag.java
        Hide
        Ted Goddard added a comment -

        JSP tag is now functional but previous params-based code is still present in the sample so will need cleanup.

        <mobi:augmentedReality id="selection"
        params="$

        {reality}

        ">
        <c:forEach items="$

        {locations}

        " var="location" >
        <mobi:augmentedRealityLocation
        locationLabel="$

        {location.title}

        "
        locationLat="$

        {location.latitude}

        "
        locationLon="$

        {location.longitude}

        "
        locationAlt="$

        {location.altitude}

        "
        locationDir="$

        {location.direction}

        "
        locationIcon="$

        {location.fileName}

        "
        />
        </c:forEach>
        </mobi:augmentedReality>

        Show
        Ted Goddard added a comment - JSP tag is now functional but previous params-based code is still present in the sample so will need cleanup. <mobi:augmentedReality id="selection" params="$ {reality} "> <c:forEach items="$ {locations} " var="location" > <mobi:augmentedRealityLocation locationLabel="$ {location.title} " locationLat="$ {location.latitude} " locationLon="$ {location.longitude} " locationAlt="$ {location.altitude} " locationDir="$ {location.direction} " locationIcon="$ {location.fileName} " /> </c:forEach> </mobi:augmentedReality>
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #30369 Thu Aug 02 09:31:43 MDT 2012 ted.goddard augmentedReality backing code changes for JSP tag supporting c:forEach augmentedRealityLocation (MOBI-236)
        Files Changed
        Commit graph MODIFY /icemobile/trunk/icemobile/samples/icemobilespring/src/main/java/org/icemobile/samples/springbasic/MediaSpotController.java
        Commit graph MODIFY /icemobile/trunk/icemobile/samples/icemobilespring/src/main/java/org/icemobile/samples/springbasic/MediaSpotBean.java
        Commit graph MODIFY /icemobile/trunk/icemobile/jsp/src/main/resources/META-INF/icemobile.tld
        Commit graph MODIFY /icemobile/trunk/icemobile/samples/icemobilespring/src/main/webapp/WEB-INF/views/mediaspot.jsp
        Hide
        Ted Goddard added a comment -

        Code cleanup is complete and params is deprecated, so use is as follows:

        <mobi:augmentedReality id="selection" >
        <c:forEach items="$

        {locations}

        " var="location" >
        <mobi:augmentedRealityLocation
        locationLabel="$

        {location.title}

        "
        locationLat="$

        {location.latitude}

        "
        locationLon="$

        {location.longitude}

        "
        locationAlt="$

        {location.altitude}

        "
        locationDir="$

        {location.direction}

        "
        locationIcon="$

        {location.fileName}

        "
        />
        </c:forEach>
        </mobi:augmentedReality>

        Show
        Ted Goddard added a comment - Code cleanup is complete and params is deprecated, so use is as follows: <mobi:augmentedReality id="selection" > <c:forEach items="$ {locations} " var="location" > <mobi:augmentedRealityLocation locationLabel="$ {location.title} " locationLat="$ {location.latitude} " locationLon="$ {location.longitude} " locationAlt="$ {location.altitude} " locationDir="$ {location.direction} " locationIcon="$ {location.fileName} " /> </c:forEach> </mobi:augmentedReality>
        Ted Goddard made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Migration made changes -
        Status Resolved [ 5 ] Closed [ 6 ]

          People

          • Assignee:
            Ted Goddard
            Reporter:
            Ted Goddard
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: