Uploaded image for project: 'Titanium SDK/CLI'
  1. Titanium SDK/CLI
  2. TIMOB-18262

iOS: Cannot load images from the applicationDataDirectory

    Details

    • Story Points:
      5
    • Sprint:
      2014 Sprint 25 SDK

      Description

      Images in ImageViews, tab icons,etc, can no longer be loaded from the `applicationDataDirectory` in 3.5.0.BETA

      Here is the sample code to replicate:

      Titanium.UI.setBackgroundColor('#000');
       
      var win2 = Titanium.UI.createWindow({  
          title:'Test',
          backgroundColor:'#fff'
      });
       
      var image1 = Titanium.UI.createImageView({
        top: 10,
        image: "/appicon.png"
      });
       
      var icon = Ti.Filesystem.getFile(Ti.Filesystem.resourcesDirectory, 'appicon.png');
      var dest = Ti.Filesystem.getFile(Ti.Filesystem.applicationDataDirectory, 'appicon.png');
       
      dest.write(icon.read());
       
      var image2 = Titanium.UI.createImageView({
        bottom: 10,
        image: Ti.Filesystem.applicationDataDirectory  + 'appicon.png'
      });
       
      win2.add(image1);
      win2.add(image2);
       
      win2.open();
      

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                vduggal Vishal Duggal (Inactive)
                Reporter:
                dbankier David Bankier
                Reviewer:
                Pedro
              • Watchers:
                8 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Git Source Code