diff --git a/.DS_Store b/.DS_Store index 02b9aef..5008ddf 100644 Binary files a/.DS_Store and b/.DS_Store differ diff --git a/.gitignore b/.gitignore index e69de29..e43b0f9 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1 @@ +.DS_Store diff --git a/Verdnatura/Verdnatura.xcodeproj/project.pbxproj b/Verdnatura/Verdnatura.xcodeproj/project.pbxproj deleted file mode 100644 index e437020..0000000 --- a/Verdnatura/Verdnatura.xcodeproj/project.pbxproj +++ /dev/null @@ -1,348 +0,0 @@ -// !$*UTF8*$! -{ - archiveVersion = 1; - classes = { - }; - objectVersion = 50; - objects = { - -/* Begin PBXBuildFile section */ - EBC33AA22595B47600CD89D7 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = EBC33AA12595B47600CD89D7 /* AppDelegate.swift */; }; - EBC33AA62595B47600CD89D7 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = EBC33AA52595B47600CD89D7 /* ViewController.swift */; }; - EBC33AA92595B47600CD89D7 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = EBC33AA72595B47600CD89D7 /* Main.storyboard */; }; - EBC33AAB2595B47900CD89D7 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = EBC33AAA2595B47900CD89D7 /* Assets.xcassets */; }; - EBC33AAE2595B47900CD89D7 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = EBC33AAC2595B47900CD89D7 /* LaunchScreen.storyboard */; }; -/* End PBXBuildFile section */ - -/* Begin PBXFileReference section */ - EBC33A9E2595B47600CD89D7 /* Verdnatura.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Verdnatura.app; sourceTree = BUILT_PRODUCTS_DIR; }; - EBC33AA12595B47600CD89D7 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; - EBC33AA52595B47600CD89D7 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; - EBC33AA82595B47600CD89D7 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; - EBC33AAA2595B47900CD89D7 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; - EBC33AAD2595B47900CD89D7 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; - EBC33AAF2595B47900CD89D7 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; -/* End PBXFileReference section */ - -/* Begin PBXFrameworksBuildPhase section */ - EBC33A9B2595B47600CD89D7 /* Frameworks */ = { - isa = PBXFrameworksBuildPhase; - buildActionMask = 2147483647; - files = ( - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXFrameworksBuildPhase section */ - -/* Begin PBXGroup section */ - EBC33A952595B47600CD89D7 = { - isa = PBXGroup; - children = ( - EBC33AA02595B47600CD89D7 /* Verdnatura */, - EBC33A9F2595B47600CD89D7 /* Products */, - ); - sourceTree = ""; - }; - EBC33A9F2595B47600CD89D7 /* Products */ = { - isa = PBXGroup; - children = ( - EBC33A9E2595B47600CD89D7 /* Verdnatura.app */, - ); - name = Products; - sourceTree = ""; - }; - EBC33AA02595B47600CD89D7 /* Verdnatura */ = { - isa = PBXGroup; - children = ( - EBC33AA12595B47600CD89D7 /* AppDelegate.swift */, - EBC33AA52595B47600CD89D7 /* ViewController.swift */, - EBC33AA72595B47600CD89D7 /* Main.storyboard */, - EBC33AAA2595B47900CD89D7 /* Assets.xcassets */, - EBC33AAC2595B47900CD89D7 /* LaunchScreen.storyboard */, - EBC33AAF2595B47900CD89D7 /* Info.plist */, - ); - path = Verdnatura; - sourceTree = ""; - }; -/* End PBXGroup section */ - -/* Begin PBXNativeTarget section */ - EBC33A9D2595B47600CD89D7 /* Verdnatura */ = { - isa = PBXNativeTarget; - buildConfigurationList = EBC33AB22595B47900CD89D7 /* Build configuration list for PBXNativeTarget "Verdnatura" */; - buildPhases = ( - EBC33A9A2595B47600CD89D7 /* Sources */, - EBC33A9B2595B47600CD89D7 /* Frameworks */, - EBC33A9C2595B47600CD89D7 /* Resources */, - ); - buildRules = ( - ); - dependencies = ( - ); - name = Verdnatura; - productName = Verdnatura; - productReference = EBC33A9E2595B47600CD89D7 /* Verdnatura.app */; - productType = "com.apple.product-type.application"; - }; -/* End PBXNativeTarget section */ - -/* Begin PBXProject section */ - EBC33A962595B47600CD89D7 /* Project object */ = { - isa = PBXProject; - attributes = { - LastSwiftUpdateCheck = 1210; - LastUpgradeCheck = 1210; - TargetAttributes = { - EBC33A9D2595B47600CD89D7 = { - CreatedOnToolsVersion = 12.1; - }; - }; - }; - buildConfigurationList = EBC33A992595B47600CD89D7 /* Build configuration list for PBXProject "Verdnatura" */; - compatibilityVersion = "Xcode 9.3"; - developmentRegion = en; - hasScannedForEncodings = 0; - knownRegions = ( - en, - Base, - ); - mainGroup = EBC33A952595B47600CD89D7; - productRefGroup = EBC33A9F2595B47600CD89D7 /* Products */; - projectDirPath = ""; - projectRoot = ""; - targets = ( - EBC33A9D2595B47600CD89D7 /* Verdnatura */, - ); - }; -/* End PBXProject section */ - -/* Begin PBXResourcesBuildPhase section */ - EBC33A9C2595B47600CD89D7 /* Resources */ = { - isa = PBXResourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - EBC33AAE2595B47900CD89D7 /* LaunchScreen.storyboard in Resources */, - EBC33AAB2595B47900CD89D7 /* Assets.xcassets in Resources */, - EBC33AA92595B47600CD89D7 /* Main.storyboard in Resources */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXResourcesBuildPhase section */ - -/* Begin PBXSourcesBuildPhase section */ - EBC33A9A2595B47600CD89D7 /* Sources */ = { - isa = PBXSourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - EBC33AA62595B47600CD89D7 /* ViewController.swift in Sources */, - EBC33AA22595B47600CD89D7 /* AppDelegate.swift in Sources */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXSourcesBuildPhase section */ - -/* Begin PBXVariantGroup section */ - EBC33AA72595B47600CD89D7 /* Main.storyboard */ = { - isa = PBXVariantGroup; - children = ( - EBC33AA82595B47600CD89D7 /* Base */, - ); - name = Main.storyboard; - sourceTree = ""; - }; - EBC33AAC2595B47900CD89D7 /* LaunchScreen.storyboard */ = { - isa = PBXVariantGroup; - children = ( - EBC33AAD2595B47900CD89D7 /* Base */, - ); - name = LaunchScreen.storyboard; - sourceTree = ""; - }; -/* End PBXVariantGroup section */ - -/* Begin XCBuildConfiguration section */ - EBC33AB02595B47900CD89D7 /* 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_ENABLE_OBJC_WEAK = YES; - CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; - CLANG_WARN_BOOL_CONVERSION = YES; - CLANG_WARN_COMMA = YES; - CLANG_WARN_CONSTANT_CONVERSION = YES; - CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = 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_IMPLICIT_RETAIN_SELF = YES; - CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; - CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; - CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; - 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; - 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 = 14.1; - MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; - MTL_FAST_MATH = YES; - ONLY_ACTIVE_ARCH = YES; - SDKROOT = iphoneos; - SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; - SWIFT_OPTIMIZATION_LEVEL = "-Onone"; - }; - name = Debug; - }; - EBC33AB12595B47900CD89D7 /* 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_ENABLE_OBJC_WEAK = YES; - CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; - CLANG_WARN_BOOL_CONVERSION = YES; - CLANG_WARN_COMMA = YES; - CLANG_WARN_CONSTANT_CONVERSION = YES; - CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = 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_IMPLICIT_RETAIN_SELF = YES; - CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; - CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; - CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; - 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; - 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 = 14.1; - MTL_ENABLE_DEBUG_INFO = NO; - MTL_FAST_MATH = YES; - SDKROOT = iphoneos; - SWIFT_COMPILATION_MODE = wholemodule; - SWIFT_OPTIMIZATION_LEVEL = "-O"; - VALIDATE_PRODUCT = YES; - }; - name = Release; - }; - EBC33AB32595B47900CD89D7 /* Debug */ = { - isa = XCBuildConfiguration; - buildSettings = { - ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; - ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; - CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 15; - DEVELOPMENT_TEAM = S2MKP69DVN; - INFOPLIST_FILE = Verdnatura/Info.plist; - IPHONEOS_DEPLOYMENT_TARGET = 9.0; - LD_RUNPATH_SEARCH_PATHS = ( - "$(inherited)", - "@executable_path/Frameworks", - ); - MARKETING_VERSION = 2.0.0; - PRODUCT_BUNDLE_IDENTIFIER = com.verdnatura.Verdnaturaventas; - PRODUCT_NAME = "$(TARGET_NAME)"; - SWIFT_VERSION = 5.0; - TARGETED_DEVICE_FAMILY = "1,2"; - }; - name = Debug; - }; - EBC33AB42595B47900CD89D7 /* Release */ = { - isa = XCBuildConfiguration; - buildSettings = { - ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; - ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; - CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 15; - DEVELOPMENT_TEAM = S2MKP69DVN; - INFOPLIST_FILE = Verdnatura/Info.plist; - IPHONEOS_DEPLOYMENT_TARGET = 9.0; - LD_RUNPATH_SEARCH_PATHS = ( - "$(inherited)", - "@executable_path/Frameworks", - ); - MARKETING_VERSION = 2.0.0; - PRODUCT_BUNDLE_IDENTIFIER = com.verdnatura.Verdnaturaventas; - PRODUCT_NAME = "$(TARGET_NAME)"; - SWIFT_VERSION = 5.0; - TARGETED_DEVICE_FAMILY = "1,2"; - }; - name = Release; - }; -/* End XCBuildConfiguration section */ - -/* Begin XCConfigurationList section */ - EBC33A992595B47600CD89D7 /* Build configuration list for PBXProject "Verdnatura" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - EBC33AB02595B47900CD89D7 /* Debug */, - EBC33AB12595B47900CD89D7 /* Release */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = Release; - }; - EBC33AB22595B47900CD89D7 /* Build configuration list for PBXNativeTarget "Verdnatura" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - EBC33AB32595B47900CD89D7 /* Debug */, - EBC33AB42595B47900CD89D7 /* Release */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = Release; - }; -/* End XCConfigurationList section */ - }; - rootObject = EBC33A962595B47600CD89D7 /* Project object */; -} diff --git a/Verdnatura/Verdnatura.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/Verdnatura/Verdnatura.xcodeproj/project.xcworkspace/contents.xcworkspacedata deleted file mode 100644 index 919434a..0000000 --- a/Verdnatura/Verdnatura.xcodeproj/project.xcworkspace/contents.xcworkspacedata +++ /dev/null @@ -1,7 +0,0 @@ - - - - - diff --git a/Verdnatura/Verdnatura.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/Verdnatura/Verdnatura.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist deleted file mode 100644 index 18d9810..0000000 --- a/Verdnatura/Verdnatura.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist +++ /dev/null @@ -1,8 +0,0 @@ - - - - - IDEDidComputeMac32BitWarning - - - diff --git a/Verdnatura/Verdnatura.xcodeproj/project.xcworkspace/xcuserdata/enriqueblascoblanquer.xcuserdatad/UserInterfaceState.xcuserstate b/Verdnatura/Verdnatura.xcodeproj/project.xcworkspace/xcuserdata/enriqueblascoblanquer.xcuserdatad/UserInterfaceState.xcuserstate deleted file mode 100644 index 7c9cd3a..0000000 Binary files a/Verdnatura/Verdnatura.xcodeproj/project.xcworkspace/xcuserdata/enriqueblascoblanquer.xcuserdatad/UserInterfaceState.xcuserstate and /dev/null differ diff --git a/Verdnatura/Verdnatura.xcodeproj/xcuserdata/enriqueblascoblanquer.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist b/Verdnatura/Verdnatura.xcodeproj/xcuserdata/enriqueblascoblanquer.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist deleted file mode 100644 index 23fd0c0..0000000 --- a/Verdnatura/Verdnatura.xcodeproj/xcuserdata/enriqueblascoblanquer.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist +++ /dev/null @@ -1,6 +0,0 @@ - - - diff --git a/Verdnatura/Verdnatura.xcodeproj/xcuserdata/enriqueblascoblanquer.xcuserdatad/xcschemes/xcschememanagement.plist b/Verdnatura/Verdnatura.xcodeproj/xcuserdata/enriqueblascoblanquer.xcuserdatad/xcschemes/xcschememanagement.plist deleted file mode 100644 index 6e46435..0000000 --- a/Verdnatura/Verdnatura.xcodeproj/xcuserdata/enriqueblascoblanquer.xcuserdatad/xcschemes/xcschememanagement.plist +++ /dev/null @@ -1,14 +0,0 @@ - - - - - SchemeUserState - - Verdnatura.xcscheme_^#shared#^_ - - orderHint - 0 - - - - diff --git a/Verdnatura/Verdnatura/AppDelegate.swift b/Verdnatura/Verdnatura/AppDelegate.swift index 6cc0fe9..eff0379 100644 --- a/Verdnatura/Verdnatura/AppDelegate.swift +++ b/Verdnatura/Verdnatura/AppDelegate.swift @@ -6,6 +6,7 @@ // import UIKit +import WebKit @main class AppDelegate: UIResponder, UIApplicationDelegate { @@ -30,6 +31,5 @@ class AppDelegate: UIResponder, UIApplicationDelegate { window?.rootViewController = rootController } - } diff --git a/Verdnatura/Verdnatura/Base.lproj/Main.storyboard b/Verdnatura/Verdnatura/Base.lproj/Main.storyboard index 6fdb735..8f51bf7 100644 --- a/Verdnatura/Verdnatura/Base.lproj/Main.storyboard +++ b/Verdnatura/Verdnatura/Base.lproj/Main.storyboard @@ -1,9 +1,9 @@ - + - + @@ -71,31 +71,24 @@ - - - - - - - - + + - diff --git a/Verdnatura/Verdnatura/Info.plist b/Verdnatura/Verdnatura/Info.plist index a57993a..d9c253b 100644 --- a/Verdnatura/Verdnatura/Info.plist +++ b/Verdnatura/Verdnatura/Info.plist @@ -1,48 +1,53 @@ - - CFBundleDevelopmentRegion - $(DEVELOPMENT_LANGUAGE) - CFBundleExecutable - $(EXECUTABLE_NAME) - CFBundleIdentifier - $(PRODUCT_BUNDLE_IDENTIFIER) - CFBundleInfoDictionaryVersion - 6.0 - CFBundleName - $(PRODUCT_NAME) - CFBundlePackageType - $(PRODUCT_BUNDLE_PACKAGE_TYPE) - CFBundleShortVersionString - $(MARKETING_VERSION) - CFBundleVersion - $(CURRENT_PROJECT_VERSION) - LSRequiresIPhoneOS - - UIApplicationSupportsIndirectInputEvents - - UILaunchStoryboardName - LaunchScreen - UIMainStoryboardFile - Main - UIRequiredDeviceCapabilities - - armv7 - - UISupportedInterfaceOrientations - - UIInterfaceOrientationPortrait - UIInterfaceOrientationLandscapeLeft - UIInterfaceOrientationLandscapeRight - UIInterfaceOrientationPortraitUpsideDown - - UISupportedInterfaceOrientations~ipad - - UIInterfaceOrientationPortrait - UIInterfaceOrientationPortraitUpsideDown - UIInterfaceOrientationLandscapeLeft - UIInterfaceOrientationLandscapeRight - - + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + $(PRODUCT_BUNDLE_PACKAGE_TYPE) + CFBundleShortVersionString + $(MARKETING_VERSION) + CFBundleVersion + $(CURRENT_PROJECT_VERSION) + LSRequiresIPhoneOS + + UIApplicationSupportsIndirectInputEvents + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UIRequiredDeviceCapabilities + + armv7 + + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + UIInterfaceOrientationPortraitUpsideDown + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + NSAppTransportSecurity + + NSAllowsArbitraryLoads + + + diff --git a/Verdnatura/Verdnatura/ViewController.swift b/Verdnatura/Verdnatura/ViewController.swift index 4c80e36..6cb1b81 100644 --- a/Verdnatura/Verdnatura/ViewController.swift +++ b/Verdnatura/Verdnatura/ViewController.swift @@ -6,36 +6,48 @@ // import UIKit +import WebKit class ViewController: UIViewController ,UIWebViewDelegate{ - @IBOutlet weak var webView: UIWebView! @IBOutlet weak var loadingview: UIView! @IBOutlet weak var btnBack: UIButton! - + private var newWebView:WKWebView! + override func viewDidLoad() { super.viewDidLoad() - self.webView.delegate = self } override func viewDidAppear(_ animated: Bool) { - let url = URL (string: "https://www.verdnatura.es/") - let requestObj = URLRequest(url: url!) - webView.loadRequest(requestObj) + let webViewPrefs = WKPreferences() + webViewPrefs.javaScriptEnabled = true + webViewPrefs.javaScriptCanOpenWindowsAutomatically = true + let webViewConf = WKWebViewConfiguration() + webViewConf.preferences = webViewPrefs + newWebView = WKWebView(frame: view.frame, configuration: webViewConf) + newWebView.autoresizingMask = [.flexibleWidth, .flexibleHeight] + newWebView.scrollView.keyboardDismissMode = .onDrag + + view.addSubview(newWebView) + view.addSubview(btnBack) + load(url: "https://shop.verdnatura.es/") } - func webViewDidStartLoad(_ webView: UIWebView) { + func webViewDidStartLoad(_ webView: UIButton) { loadingview.isHidden = false } + private func load(url: String) { + newWebView.load(URLRequest(url:URL(string:url)!)) + newWebView.allowsBackForwardNavigationGestures = true + } func webViewDidFinishLoad(_ webView: UIWebView) { - loadingview.isHidden = true + loadingview.isHidden = true } @IBAction func goBack(_ sender: Any) { - self.webView.goBack() + self.newWebView.goBack() } - }