Add iOS Support

android
Jonas Franz 6 years ago
parent a081bba8ff
commit 7d5f83cc06
Signed by: JonasFranzDEV
GPG Key ID: C8287A01D593AC1D
  1. 2
      gradle.properties
  2. 472
      native/KotlinNativeDemo.xcodeproj/project.pbxproj
  3. 7
      native/KotlinNativeDemo.xcodeproj/project.xcworkspace/contents.xcworkspacedata
  4. 46
      native/KotlinNativeDemo/AppDelegate.swift
  5. 93
      native/KotlinNativeDemo/Assets.xcassets/AppIcon.appiconset/Contents.json
  6. 25
      native/KotlinNativeDemo/Base.lproj/LaunchScreen.storyboard
  7. 24
      native/KotlinNativeDemo/Base.lproj/Main.storyboard
  8. 45
      native/KotlinNativeDemo/Info.plist
  9. 28
      native/KotlinNativeDemo/ViewController.swift
  10. 4
      native/build.gradle

@ -6,4 +6,4 @@ npm_version = 5.5.1
kotlin.incremental.multiplatform=true
kotlin_native_version = 0.6
kotlin_native_version=+

@ -0,0 +1,472 @@
// !$*UTF8*$!
{
archiveVersion = 1;
classes = {
};
objectVersion = 48;
objects = {
/* Begin PBXBuildFile section */
BD9680F02072B6D400D447AC /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = BD9680EF2072B6D400D447AC /* AppDelegate.swift */; };
BD9680F22072B6D400D447AC /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = BD9680F12072B6D400D447AC /* ViewController.swift */; };
BD9680F52072B6D400D447AC /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = BD9680F32072B6D400D447AC /* Main.storyboard */; };
BD9680F72072B6D400D447AC /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = BD9680F62072B6D400D447AC /* Assets.xcassets */; };
BD9680FA2072B6D400D447AC /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = BD9680F82072B6D400D447AC /* LaunchScreen.storyboard */; };
BD96810D2072B6F200D447AC /* KotlinDemoFramework.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = BD9681062072B6F200D447AC /* KotlinDemoFramework.framework */; };
BD96810E2072B6F200D447AC /* KotlinDemoFramework.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = BD9681062072B6F200D447AC /* KotlinDemoFramework.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
/* End PBXBuildFile section */
/* Begin PBXContainerItemProxy section */
BD96810B2072B6F200D447AC /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = BD9680E42072B6D400D447AC /* Project object */;
proxyType = 1;
remoteGlobalIDString = BD9681052072B6F200D447AC;
remoteInfo = KotlinDemoFramework;
};
/* End PBXContainerItemProxy section */
/* Begin PBXCopyFilesBuildPhase section */
BD9681122072B6F200D447AC /* Embed Frameworks */ = {
isa = PBXCopyFilesBuildPhase;
buildActionMask = 2147483647;
dstPath = "";
dstSubfolderSpec = 10;
files = (
BD96810E2072B6F200D447AC /* KotlinDemoFramework.framework in Embed Frameworks */,
);
name = "Embed Frameworks";
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXCopyFilesBuildPhase section */
/* Begin PBXFileReference section */
BD9680EC2072B6D400D447AC /* KotlinNativeDemo.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = KotlinNativeDemo.app; sourceTree = BUILT_PRODUCTS_DIR; };
BD9680EF2072B6D400D447AC /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; };
BD9680F12072B6D400D447AC /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = "<group>"; };
BD9680F42072B6D400D447AC /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = "<group>"; };
BD9680F62072B6D400D447AC /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
BD9680F92072B6D400D447AC /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = "<group>"; };
BD9680FB2072B6D400D447AC /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
BD9681062072B6F200D447AC /* KotlinDemoFramework.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = KotlinDemoFramework.framework; sourceTree = BUILT_PRODUCTS_DIR; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
BD9680E92072B6D400D447AC /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
BD96810D2072B6F200D447AC /* KotlinDemoFramework.framework in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
BD9680E32072B6D400D447AC = {
isa = PBXGroup;
children = (
BD9680EE2072B6D400D447AC /* KotlinNativeDemo */,
BD9680ED2072B6D400D447AC /* Products */,
);
sourceTree = "<group>";
};
BD9680ED2072B6D400D447AC /* Products */ = {
isa = PBXGroup;
children = (
BD9680EC2072B6D400D447AC /* KotlinNativeDemo.app */,
BD9681062072B6F200D447AC /* KotlinDemoFramework.framework */,
);
name = Products;
sourceTree = "<group>";
};
BD9680EE2072B6D400D447AC /* KotlinNativeDemo */ = {
isa = PBXGroup;
children = (
BD9680EF2072B6D400D447AC /* AppDelegate.swift */,
BD9680F12072B6D400D447AC /* ViewController.swift */,
BD9680F32072B6D400D447AC /* Main.storyboard */,
BD9680F62072B6D400D447AC /* Assets.xcassets */,
BD9680F82072B6D400D447AC /* LaunchScreen.storyboard */,
BD9680FB2072B6D400D447AC /* Info.plist */,
);
path = KotlinNativeDemo;
sourceTree = "<group>";
};
/* End PBXGroup section */
/* Begin PBXNativeTarget section */
BD9680EB2072B6D400D447AC /* KotlinNativeDemo */ = {
isa = PBXNativeTarget;
buildConfigurationList = BD9680FE2072B6D400D447AC /* Build configuration list for PBXNativeTarget "KotlinNativeDemo" */;
buildPhases = (
BD9680E82072B6D400D447AC /* Sources */,
BD9680E92072B6D400D447AC /* Frameworks */,
BD9680EA2072B6D400D447AC /* Resources */,
BD9681122072B6F200D447AC /* Embed Frameworks */,
);
buildRules = (
);
dependencies = (
BD96810C2072B6F200D447AC /* PBXTargetDependency */,
);
name = KotlinNativeDemo;
productName = KotlinNativeDemo;
productReference = BD9680EC2072B6D400D447AC /* KotlinNativeDemo.app */;
productType = "com.apple.product-type.application";
};
BD9681052072B6F200D447AC /* KotlinDemoFramework */ = {
isa = PBXNativeTarget;
buildConfigurationList = BD96810F2072B6F200D447AC /* Build configuration list for PBXNativeTarget "KotlinDemoFramework" */;
buildPhases = (
BD9681132072B78400D447AC /* Compile Kotlin/Native */,
);
buildRules = (
);
dependencies = (
);
name = KotlinDemoFramework;
productName = KotlinDemoFramework;
productReference = BD9681062072B6F200D447AC /* KotlinDemoFramework.framework */;
productType = "com.apple.product-type.framework";
};
/* End PBXNativeTarget section */
/* Begin PBXProject section */
BD9680E42072B6D400D447AC /* Project object */ = {
isa = PBXProject;
attributes = {
LastSwiftUpdateCheck = 0920;
LastUpgradeCheck = 0920;
ORGANIZATIONNAME = "Jonas Franz";
TargetAttributes = {
BD9680EB2072B6D400D447AC = {
CreatedOnToolsVersion = 9.2;
ProvisioningStyle = Automatic;
};
BD9681052072B6F200D447AC = {
CreatedOnToolsVersion = 9.2;
ProvisioningStyle = Automatic;
};
};
};
buildConfigurationList = BD9680E72072B6D400D447AC /* Build configuration list for PBXProject "KotlinNativeDemo" */;
compatibilityVersion = "Xcode 8.0";
developmentRegion = en;
hasScannedForEncodings = 0;
knownRegions = (
en,
Base,
);
mainGroup = BD9680E32072B6D400D447AC;
productRefGroup = BD9680ED2072B6D400D447AC /* Products */;
projectDirPath = "";
projectRoot = "";
targets = (
BD9680EB2072B6D400D447AC /* KotlinNativeDemo */,
BD9681052072B6F200D447AC /* KotlinDemoFramework */,
);
};
/* End PBXProject section */
/* Begin PBXResourcesBuildPhase section */
BD9680EA2072B6D400D447AC /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
BD9680FA2072B6D400D447AC /* LaunchScreen.storyboard in Resources */,
BD9680F72072B6D400D447AC /* Assets.xcassets in Resources */,
BD9680F52072B6D400D447AC /* Main.storyboard in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXResourcesBuildPhase section */
/* Begin PBXShellScriptBuildPhase section */
BD9681132072B78400D447AC /* Compile Kotlin/Native */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
);
name = "Compile Kotlin/Native";
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "echo \"$SRCROOT\"\necho \"$KONANTASK\"\n\"$SRCROOT/../gradlew\" -p \"$SRCROOT\" \"$KONAN_TASK\" -Pkonan.useEnvironmentVariables=true";
};
/* End PBXShellScriptBuildPhase section */
/* Begin PBXSourcesBuildPhase section */
BD9680E82072B6D400D447AC /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
BD9680F22072B6D400D447AC /* ViewController.swift in Sources */,
BD9680F02072B6D400D447AC /* AppDelegate.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */
/* Begin PBXTargetDependency section */
BD96810C2072B6F200D447AC /* PBXTargetDependency */ = {
isa = PBXTargetDependency;
target = BD9681052072B6F200D447AC /* KotlinDemoFramework */;
targetProxy = BD96810B2072B6F200D447AC /* PBXContainerItemProxy */;
};
/* End PBXTargetDependency section */
/* Begin PBXVariantGroup section */
BD9680F32072B6D400D447AC /* Main.storyboard */ = {
isa = PBXVariantGroup;
children = (
BD9680F42072B6D400D447AC /* Base */,
);
name = Main.storyboard;
sourceTree = "<group>";
};
BD9680F82072B6D400D447AC /* LaunchScreen.storyboard */ = {
isa = PBXVariantGroup;
children = (
BD9680F92072B6D400D447AC /* Base */,
);
name = LaunchScreen.storyboard;
sourceTree = "<group>";
};
/* End PBXVariantGroup section */
/* Begin XCBuildConfiguration section */
BD9680FC2072B6D400D447AC /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_NONNULL = YES;
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++14";
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
CODE_SIGN_IDENTITY = "iPhone Developer";
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = dwarf;
ENABLE_STRICT_OBJC_MSGSEND = YES;
ENABLE_TESTABILITY = YES;
GCC_C_LANGUAGE_STANDARD = gnu11;
GCC_DYNAMIC_NO_PIC = NO;
GCC_NO_COMMON_BLOCKS = YES;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PREPROCESSOR_DEFINITIONS = (
"DEBUG=1",
"$(inherited)",
);
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 11.2;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
};
name = Debug;
};
BD9680FD2072B6D400D447AC /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_NONNULL = YES;
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++14";
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
CODE_SIGN_IDENTITY = "iPhone Developer";
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
GCC_C_LANGUAGE_STANDARD = gnu11;
GCC_NO_COMMON_BLOCKS = YES;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 11.2;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule";
VALIDATE_PRODUCT = YES;
};
name = Release;
};
BD9680FF2072B6D400D447AC /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = Z48VLBM2R7;
INFOPLIST_FILE = KotlinNativeDemo/Info.plist;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = software.jonasfranz.KotlinNativeDemo;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 4.0;
TARGETED_DEVICE_FAMILY = "1,2";
VALID_ARCHS = arm64;
};
name = Debug;
};
BD9681002072B6D400D447AC /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = Z48VLBM2R7;
INFOPLIST_FILE = KotlinNativeDemo/Info.plist;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = software.jonasfranz.KotlinNativeDemo;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 4.0;
TARGETED_DEVICE_FAMILY = "1,2";
VALID_ARCHS = arm64;
};
name = Release;
};
BD9681102072B6F200D447AC /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_IDENTITY = "";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
DEFINES_MODULE = YES;
DEVELOPMENT_TEAM = Z48VLBM2R7;
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
DYLIB_INSTALL_NAME_BASE = "@rpath";
INFOPLIST_FILE = "";
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
KONAN_ENABLE_OPTIMIZATIONS = NO;
KONAN_TASK = "";
"KONAN_TASK[sdk=iphoneos*]" = compileKonanKotlinDemoFrameworkIos_arm64;
"KONAN_TASK[sdk=iphonesimulator*]" = compileKonanKotlinDemoFrameworkIos_x64;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = software.jonasfranz.KotlinDemoFramework;
PRODUCT_NAME = "$(TARGET_NAME:c99extidentifier)";
SKIP_INSTALL = YES;
SWIFT_VERSION = 4.0;
TARGETED_DEVICE_FAMILY = "1,2";
VALID_ARCHS = arm64;
VERSIONING_SYSTEM = "apple-generic";
VERSION_INFO_PREFIX = "";
};
name = Debug;
};
BD9681112072B6F200D447AC /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_IDENTITY = "";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
DEFINES_MODULE = YES;
DEVELOPMENT_TEAM = Z48VLBM2R7;
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
DYLIB_INSTALL_NAME_BASE = "@rpath";
INFOPLIST_FILE = "";
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
KONAN_ENABLE_OPTIMIZATIONS = YES;
KONAN_TASK = "";
"KONAN_TASK[sdk=iphoneos*]" = compileKonanKotlinDemoFrameworkIos_arm64;
"KONAN_TASK[sdk=iphonesimulator*]" = compileKonanKotlinDemoFrameworkIos_x64;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = software.jonasfranz.KotlinDemoFramework;
PRODUCT_NAME = "$(TARGET_NAME:c99extidentifier)";
SKIP_INSTALL = YES;
SWIFT_VERSION = 4.0;
TARGETED_DEVICE_FAMILY = "1,2";
VALID_ARCHS = arm64;
VERSIONING_SYSTEM = "apple-generic";
VERSION_INFO_PREFIX = "";
};
name = Release;
};
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
BD9680E72072B6D400D447AC /* Build configuration list for PBXProject "KotlinNativeDemo" */ = {
isa = XCConfigurationList;
buildConfigurations = (
BD9680FC2072B6D400D447AC /* Debug */,
BD9680FD2072B6D400D447AC /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
BD9680FE2072B6D400D447AC /* Build configuration list for PBXNativeTarget "KotlinNativeDemo" */ = {
isa = XCConfigurationList;
buildConfigurations = (
BD9680FF2072B6D400D447AC /* Debug */,
BD9681002072B6D400D447AC /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
BD96810F2072B6F200D447AC /* Build configuration list for PBXNativeTarget "KotlinDemoFramework" */ = {
isa = XCConfigurationList;
buildConfigurations = (
BD9681102072B6F200D447AC /* Debug */,
BD9681112072B6F200D447AC /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
};
rootObject = BD9680E42072B6D400D447AC /* Project object */;
}

@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<Workspace
version = "1.0">
<FileRef
location = "self:KotlinNativeDemo.xcodeproj">
</FileRef>
</Workspace>

@ -0,0 +1,46 @@
//
// AppDelegate.swift
// KotlinNativeDemo
//
// Created by Jonas Franz on 02.04.18.
// Copyright © 2018 Jonas Franz. All rights reserved.
//
import UIKit
@UIApplicationMain
class AppDelegate: UIResponder, UIApplicationDelegate {
var window: UIWindow?
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool {
// Override point for customization after application launch.
return true
}
func applicationWillResignActive(_ application: UIApplication) {
// Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state.
// Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game.
}
func applicationDidEnterBackground(_ application: UIApplication) {
// Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later.
// If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits.
}
func applicationWillEnterForeground(_ application: UIApplication) {
// Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background.
}
func applicationDidBecomeActive(_ application: UIApplication) {
// Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface.
}
func applicationWillTerminate(_ application: UIApplication) {
// Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:.
}
}

@ -0,0 +1,93 @@
{
"images" : [
{
"idiom" : "iphone",
"size" : "20x20",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "20x20",
"scale" : "3x"
},
{
"idiom" : "iphone",
"size" : "29x29",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "29x29",
"scale" : "3x"
},
{
"idiom" : "iphone",
"size" : "40x40",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "40x40",
"scale" : "3x"
},
{
"idiom" : "iphone",
"size" : "60x60",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "60x60",
"scale" : "3x"
},
{
"idiom" : "ipad",
"size" : "20x20",
"scale" : "1x"
},
{
"idiom" : "ipad",
"size" : "20x20",
"scale" : "2x"
},
{
"idiom" : "ipad",
"size" : "29x29",
"scale" : "1x"
},
{
"idiom" : "ipad",
"size" : "29x29",
"scale" : "2x"
},
{
"idiom" : "ipad",
"size" : "40x40",
"scale" : "1x"
},
{
"idiom" : "ipad",
"size" : "40x40",
"scale" : "2x"
},
{
"idiom" : "ipad",
"size" : "76x76",
"scale" : "1x"
},
{
"idiom" : "ipad",
"size" : "76x76",
"scale" : "2x"
},
{
"idiom" : "ipad",
"size" : "83.5x83.5",
"scale" : "2x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}

@ -0,0 +1,25 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="13122.16" systemVersion="17A277" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES" initialViewController="01J-lp-oVM">
<dependencies>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="13104.12"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<scenes>
<!--View Controller-->
<scene sceneID="EHf-IW-A2E">
<objects>
<viewController id="01J-lp-oVM" sceneMemberID="viewController">
<view key="view" contentMode="scaleToFill" id="Ze5-6b-2t3">
<rect key="frame" x="0.0" y="0.0" width="375" height="667"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<viewLayoutGuide key="safeArea" id="6Tk-OE-BBY"/>
</view>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="iYj-Kq-Ea1" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="53" y="375"/>
</scene>
</scenes>
</document>

@ -0,0 +1,24 @@
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="13122.16" systemVersion="17A277" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES" initialViewController="BYZ-38-t0r">
<dependencies>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="13104.12"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<scenes>
<!--View Controller-->
<scene sceneID="tne-QT-ifu">
<objects>
<viewController id="BYZ-38-t0r" customClass="ViewController" customModuleProvider="target" sceneMemberID="viewController">
<view key="view" contentMode="scaleToFill" id="8bC-Xf-vdC">
<rect key="frame" x="0.0" y="0.0" width="375" height="667"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<viewLayoutGuide key="safeArea" id="6Tk-OE-BBY"/>
</view>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="dkx-z0-nzr" sceneMemberID="firstResponder"/>
</objects>
</scene>
</scenes>
</document>

@ -0,0 +1,45 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>$(DEVELOPMENT_LANGUAGE)</string>
<key>CFBundleExecutable</key>
<string>$(EXECUTABLE_NAME)</string>
<key>CFBundleIdentifier</key>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>$(PRODUCT_NAME)</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleVersion</key>
<string>1</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>UILaunchStoryboardName</key>
<string>LaunchScreen</string>
<key>UIMainStoryboardFile</key>
<string>Main</string>
<key>UIRequiredDeviceCapabilities</key>
<array>
<string>armv7</string>
</array>
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
<key>UISupportedInterfaceOrientations~ipad</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationPortraitUpsideDown</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
</dict>
</plist>

@ -0,0 +1,28 @@
//
// ViewController.swift
// KotlinNativeDemo
//
// Created by Jonas Franz on 02.04.18.
// Copyright © 2018 Jonas Franz. All rights reserved.
//
import UIKit
import KotlinDemoFramework
class ViewController: UIViewController {
override func viewDidLoad() {
super.viewDidLoad()
print(KDFPlatform().platform())
// Do any additional setup after loading the view, typically from a nib.
}
override func didReceiveMemoryWarning() {
super.didReceiveMemoryWarning()
// Dispose of any resources that can be recreated.
}
}

@ -5,6 +5,10 @@ konanArtifacts {
enableMultiplatform true
}
framework('KotlinDemoFramework', targets: ['iphone', 'iphone_sim']) {
enableMultiplatform true
}
program('native-test') {
srcDir 'src/test/kotlin'
commonSourceSet 'test'

Loading…
Cancel
Save