Mercurial > dwindows
annotate mobile.txt @ 2671:0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
iOS and Android currently can't be built using the command line system we
use on other platforms, so these instructions provide the means to get
Dynamic Windows running on mobile platfoms. There might be better ways to do
this, so considering the information a work in progress.
Also the Android C++ file had now incorrect requirement information.
author | bsmith@81767d24-ef19-dc11-ae90-00e081727c95 |
---|---|
date | Mon, 18 Oct 2021 12:44:57 +0000 |
parents | |
children | d2c3b17a4ddf |
rev | line source |
---|---|
2671
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
1 How to create a Dynamic Windows project for iOS in Xcode and Android in Android Studio. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
2 |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
3 |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
4 Xcode |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
5 |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
6 === Dynamic Windows Project Creation === |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
7 1. File → New → Project… |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
8 2. Select “iOS” then “App” then click “Next” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
9 3. Fill in the following: |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
10 “Product Name” with “Dynamic Windows iOS” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
11 “Team” select the appropriate team for this project. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
12 “Organization Identifier” with “org.dbsoft” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
13 “Interface” select “Storyboard” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
14 “Language” select “Objective-C” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
15 Uncheck “Include Tests” and click “Next” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
16 4. Choose a location for the project, “Don’t add to any project or workspace” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
17 5. Rename the “Dynamic Windows iOS” target to “dwtest” and remove the following files: |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
18 *.m, *.h, *.storyboard and Assets.xcassets |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
19 6. Select “dwtest” folder and File → Add Files to “Dynamic Windows iOS”… |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
20 Select “dwtest.c” from the file dialog with “Copy items if needed” unchecked. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
21 “Add to targets” should have “dwtest” checked. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
22 7. Highlight the project “Dynamic Windows iOS” in the top left then select the target “dwtest” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
23 Edit “Bundle Identifier” to be “org.dbsoft.dwindows.dwtest” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
24 8. Click the target dropdown and click “Add Target” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
25 Select “Framework” and click “Next” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
26 “Product name” with “dwindows” uncheck “Include Tests” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
27 9. Delete the created “dwindows.h” and “Move to Trash” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
28 10. Select “dwindows” folder and File → Add Files to “Dynamic Windows iOS”… |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
29 Add “dw.h” and “ios/dw.n” with “Copy items if needed” unchecked. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
30 11. Repeat steps 8 through 10 with “dwcompat” adding the dwcompat.c and dwcompat.h files. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
31 12. Highlight the project “Dynamic Windows iOS” in the top left then select the main project. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
32 Click “Build Settings” for the entire project and find “Apple Clang – Preprocessing” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
33 Double click “Preprocessor Macros” and add “__IOS__” to the list for release and debug. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
34 13. Set “Objective-C Automatic Reference Counting” to “No” in “Language – Objective-C” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
35 14. Edit the “Info.plist” in “dwtest” and remove all the settings below “Bundle version” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
36 This is required because Dynamic Windows does not use storyboards. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
37 If necessary edit the “dwtest” “Build Settings” and correct the path to “dwtest/Info.plist” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
38 15. Highlight the project “Dynamic Windows iOS” in the top left then File → New → Group |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
39 Name the new group “Resources” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
40 Copy “mac/file.png” “mac/folder.png” and “image/test.png” into “Resources” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
41 |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
42 === Project Creation === |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
43 1. File → New → Project… |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
44 2. Select “iOS” then “App” then click “Next” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
45 3. Fill in the following: |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
46 “Product Name” with your application name. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
47 “Team” select the appropriate team for this project. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
48 “Organization Identifier” with your identifier |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
49 “Interface” select “Storyboard” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
50 “Language” select “Objective-C” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
51 Uncheck “Include Tests” and click “Next” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
52 4. Choose a location for the project, “Don’t add to any project or workspace” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
53 5. Make sure you close the “Dynamic Windows iOS” main project before step 6. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
54 6. Select the project in the top left and File → Add Files to “Project Name”… |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
55 Find the “Dynamic Windows iOS” project and add it to the application project. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
56 7. Select the Project folder and File → Add Files to “Project Name”… |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
57 Add your source files with “Copy items if needed” unchecked. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
58 8. Edit the “Info.plist” in the Project and remove all the settings below “Bundle version” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
59 This is required because Dynamic Windows does not use storyboards. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
60 9. Highlight the Project Name in the top left then File → New → Group |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
61 Name the new group “Resources” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
62 10. Place any application resource images in the form “#.png” where # is the resource ID. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
63 Any other application files placed here will be accessible via dw_app_dir() at runtime. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
64 11. Open Assets.xcassets and drag the appropriate icons into the bottom sections. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
65 12. Select the project in the top left and select the application target from the drop down list. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
66 Under “General” find “Frameworks, Libraries and Embedded Content” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
67 Add “dwindows.framework” from the “Dynamic Windows iOS” project. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
68 If necessary add “dwcompat.framework” from the Dynamic Windows iOS” project. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
69 13. Highlight the project name in the top left then select the main project. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
70 Click “Info” and set the “iOS Deployment Target” to “13.0” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
71 14. Click “Build Settings” for the entire project and find “Search Paths” and add the path to |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
72 dw.h in “Header Search Paths” for Release and Debug (Any Architecture | Any SDK) |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
73 15. Also under “Build Settings” find “Apple Clang – Preprocessing” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
74 Double click “Preprocessor Macros” and add “__IOS__” to the list for release and debug. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
75 |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
76 |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
77 Android Studio |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
78 |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
79 === Project Creation === |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
80 1. File → New → New Project |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
81 2. Select “Phone and Tablet” then “Native C++” and click “Next” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
82 3. Fill in the following: |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
83 “Name” with your own application name |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
84 “Package name” with “org.dbsoft.dwindows” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
85 “Save location” can be the default |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
86 “Language” select “Kotlin” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
87 “Minimum SDK” select “API 23: Android 6.0 (Marshmallow)” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
88 click “Next” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
89 4. Select “Toolchain Default” and click “Finish” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
90 |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
91 === Source File Installation === |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
92 5. Install “android/DWindows.kt” into “app/src/main/java/org/dbsoft/dwindows” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
93 Remove “MainActivity.kt” from app/src/main/java/org/dbsoft/dwindows” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
94 6. Install “dw.h” and “android/dw.cpp” into “app/src/main/cpp” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
95 Remove “native-lib.cpp” from “app/src/main/cpp” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
96 7. Optionally install “dwcompat.h” and “dwcompat.c” into “app/src/main/cpp” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
97 8. Install your source files (or our example “dwtest.c”) into “app/src/main/cpp” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
98 9. Right click “app” in your project and click New → Folder → Assets Folder |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
99 “Target Source Set” select “main” and click “Finish” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
100 10. Place any application resource images in the form “#.png” where # is the resource ID. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
101 Any other application files placed here will be accessible via dw_app_dir() at runtime. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
102 |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
103 === Project Configuration === |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
104 11. Open “app/manifests/AndroidManifest.xml” and in the “activity” section |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
105 change “android:name” from “.MainActivity” to “.DWindows” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
106 12. Recommend adding the following (but depends on the app usage): |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
107 android:configChanges="orientation|screenSize|screenLayout|keyboardHidden" |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
108 android:screenOrientation="fullSensor" |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
109 android:persistent="true" |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
110 android:usesCleartextTraffic="true" |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
111 13: Open “app/src/main/cpp/CMakeLists.txt” and in the add_library() section: |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
112 Remove “native-lib.cpp” and add “dw.cpp” optionally “dwcompat.c” and your applications C |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
113 or C++ source files that you had installed in step 8. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
114 Also change “project()” to be your project name. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
115 14. Open “build.gradle (Module)” in “Gradle Scripts” and change “applicationId” to your App ID. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
116 |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
117 === Application Assets === |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
118 15. Remove all the files under “app/res/mipmap/ic_launcher” and app/res/mipmap/ic_launcher_round” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
119 16. Right click “app” and click New → Image Asset |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
120 “Icon Type” select “Launcher Icons (Legacy Only)” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
121 “Name” enter “ic_launcher” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
122 “Asset Type” check “Image” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
123 “Path” click the folder icon and select the largest launcher image you have. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
124 “Shape” select “Square” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
125 Click “Next” and then “Finish” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
126 17. Right click “app” and click New → Image Asset |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
127 “Icon Type” select “Launcher Icons (Legacy Only)” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
128 “Name” enter “ic_launcher_round” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
129 “Asset Type” check “Image” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
130 “Path” click the folder icon and select the largest launcher image you have. |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
131 “Shape” select “Circle” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
132 Click “Next” and then “Finish” |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
133 |
0ed61ddb9957
Add a mobile platform text file with instructions on how to create projects.
bsmith@81767d24-ef19-dc11-ae90-00e081727c95
parents:
diff
changeset
|
134 |