Run a prepackaged Hybrid App in the iOS
Hybrid Web Container so that the Hybrid Web Container
functions as a single-purpose application rather than a general purpose one.
- Package the Hybrid App files.
You can use a Hybrid App that was
generated with the Hybrid App Designer, or you
can use the packaging tool to generate a new Hybrid App.
When packaging the Hybrid App, optimize
the size by generating a version for each specific platform that includes only files
for that platform.
See Packaging Hybrid Apps Using the Packaging Tool.
- Copy the generated Hybrid App folder to a
location that is accessible to your
Xcode
project.
- In the
Xcode
Project Navigator, right-click the Resources group folder, and
select Add Files to
HWC.
- Navigate
to the directory you just created that contains the generated package, and select the
top-level directory of the package.
Create folder
references, not
group references, when you add the
files.
The directories
appear
directly under Resources.
- In the Project Navigator, find and open the
CustomizationHelper.m file, which is located in the
Classes group folder.
- Locate the customization
point,
designated by the comment IOS_CUSTOMIZATION_POINT_PREPACKAGED_APP,
that
accompanies the getPrepackagedAppPath function, and change the
contents of this function
to
return the name of the top-level directory you just added to the
project.
- Rebuild the HWC.xcodeproj project.
- From the Xcode menu, select .
- Select .