Results 1 to 4 of 4

Thread: Completely offline app - images in carousel

  1. #1
    Sencha User
    Join Date
    Mar 2012
    Posts
    8
    Vote Rating
    0
      0  

    Default Completely offline app - images in carousel

    Hello,

    I need to write a completely offline app, which will be packaged for iOS.

    It's quite simple, just a catalogue really, with images and text.

    Is it possible to drive the carousel with images stored locally as resources which are bundled with the app?

    Many thanks

  2. #2
    Sencha Premium Member
    Join Date
    Jan 2012
    Location
    London, UK
    Posts
    587
    Answers
    25
    Vote Rating
    88
      0  

    Default

    Absolutely. Just have the images in the app's directory, and add a reference to them in app.json. This will ensure they are copied when you build the app using sencha command.

  3. #3
    Sencha User
    Join Date
    Mar 2012
    Posts
    8
    Vote Rating
    0
      0  

    Default

    Wow, that was quick, thank you

    Do I have to access the images via the LocalStorage proxy or can I just have a direct reference to them somehow?

  4. #4
    Sencha Premium Member
    Join Date
    Jan 2012
    Location
    London, UK
    Posts
    587
    Answers
    25
    Vote Rating
    88
      0  

    Default

    when you include the images in the app (you might do this, for instance, by using the Ext.Img class and setting the src) just use a relative file path from the root of the app, to where you have the images. So if you have them at resources/images/carousel/img.jpg you'd put as the src of the Ext.Img exactly the same ("resources/images/carousel/img.jpg").

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •