Title: [204378] trunk/Tools
Revision
204378
Author
[email protected]
Date
2016-08-11 11:14:05 -0700 (Thu, 11 Aug 2016)

Log Message

[iOS DRT] Allow DRT to be iPad-sized in the iPad simulator
https://bugs.webkit.org/show_bug.cgi?id=160761

Reviewed by Tim Horton.

Give iOS DRT a Launch storyboard.

Have it use a UIViewController so future forms testing works correctly.

Add TARGETED_DEVICE_FAMILY = "1,2" to the build settings for the .app, so that it
can run in iPad mode.

Remove empty InfoPlist.strings files.

* DumpRenderTree/DumpRenderTree.xcodeproj/project.pbxproj:
* DumpRenderTree/ios/Info.plist:
* DumpRenderTree/ios/Launch.storyboard: Added.
* DumpRenderTree/mac/DumpRenderTree.mm:
(createWebViewAndOffscreenWindow):
* WebKitTestRunner/WebKitTestRunner.xcodeproj/project.pbxproj:
* WebKitTestRunner/WebKitTestRunnerApp/en.lproj/InfoPlist.strings: Removed.
* WebKitTestRunner/ios/PlatformWebViewIOS.mm:
(WTR::PlatformWebView::PlatformWebView): Drive-by leak fix.

Modified Paths

Added Paths

Removed Paths

Diff

Modified: trunk/Tools/ChangeLog (204377 => 204378)


--- trunk/Tools/ChangeLog	2016-08-11 17:48:57 UTC (rev 204377)
+++ trunk/Tools/ChangeLog	2016-08-11 18:14:05 UTC (rev 204378)
@@ -1,3 +1,29 @@
+2016-08-10  Simon Fraser  <[email protected]>
+
+        [iOS DRT] Allow DRT to be iPad-sized in the iPad simulator
+        https://bugs.webkit.org/show_bug.cgi?id=160761
+
+        Reviewed by Tim Horton.
+
+        Give iOS DRT a Launch storyboard.
+
+        Have it use a UIViewController so future forms testing works correctly.
+
+        Add TARGETED_DEVICE_FAMILY = "1,2" to the build settings for the .app, so that it
+        can run in iPad mode.
+
+        Remove empty InfoPlist.strings files.
+
+        * DumpRenderTree/DumpRenderTree.xcodeproj/project.pbxproj:
+        * DumpRenderTree/ios/Info.plist:
+        * DumpRenderTree/ios/Launch.storyboard: Added.
+        * DumpRenderTree/mac/DumpRenderTree.mm:
+        (createWebViewAndOffscreenWindow):
+        * WebKitTestRunner/WebKitTestRunner.xcodeproj/project.pbxproj:
+        * WebKitTestRunner/WebKitTestRunnerApp/en.lproj/InfoPlist.strings: Removed.
+        * WebKitTestRunner/ios/PlatformWebViewIOS.mm:
+        (WTR::PlatformWebView::PlatformWebView): Drive-by leak fix.
+
 2016-08-11  Per Arne Vollan  <[email protected]>
 
         [Win] Unable to reliably run tests in parallel

Modified: trunk/Tools/DumpRenderTree/DumpRenderTree.xcodeproj/project.pbxproj (204377 => 204378)


--- trunk/Tools/DumpRenderTree/DumpRenderTree.xcodeproj/project.pbxproj	2016-08-11 17:48:57 UTC (rev 204377)
+++ trunk/Tools/DumpRenderTree/DumpRenderTree.xcodeproj/project.pbxproj	2016-08-11 18:14:05 UTC (rev 204378)
@@ -28,6 +28,7 @@
 		00F048541A0C3C9A000244DB /* URLRedirect.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 00F048531A0C3C9A000244DB /* URLRedirect.cpp */; };
 		0F37A4A711E6628700275F54 /* PluginObjectMac.mm in Sources */ = {isa = PBXBuildFile; fileRef = 0F37A4A611E6628700275F54 /* PluginObjectMac.mm */; };
 		0F37A4AA11E6629100275F54 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = B5A752A108AF5D1F00138E45 /* QuartzCore.framework */; };
+		0F4E43E31D5C2BAF008EBA5C /* Launch.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 0F4E43E11D5C037A008EBA5C /* Launch.storyboard */; };
 		141BF435096A455900E0753C /* WebKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9335435F03D75502008635CE /* WebKit.framework */; };
 		141BF436096A455900E0753C /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A84F608908B136DA00E9745F /* Cocoa.framework */; };
 		141BF438096A455900E0753C /* _javascript_Core.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A817090308B164D300CCB9FB /* _javascript_Core.framework */; };
@@ -214,6 +215,7 @@
 /* Begin PBXFileReference section */
 		00F048531A0C3C9A000244DB /* URLRedirect.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = URLRedirect.cpp; sourceTree = "<group>"; };
 		0F37A4A611E6628700275F54 /* PluginObjectMac.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = PluginObjectMac.mm; sourceTree = "<group>"; };
+		0F4E43E11D5C037A008EBA5C /* Launch.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = Launch.storyboard; path = ios/Launch.storyboard; sourceTree = "<group>"; };
 		141BF233096A44CF00E0753C /* TestNetscapePlugIn.plugin */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = TestNetscapePlugIn.plugin; sourceTree = BUILT_PRODUCTS_DIR; };
 		141BF447096A45C800E0753C /* PluginObject.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = PluginObject.h; sourceTree = "<group>"; };
 		141BF448096A45C800E0753C /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text.plist.xml; name = Info.plist; path = mac/Info.plist; sourceTree = "<group>"; };
@@ -645,6 +647,7 @@
 		A1158D6A18927CE10088C17B /* ios */ = {
 			isa = PBXGroup;
 			children = (
+				0F4E43E11D5C037A008EBA5C /* Launch.storyboard */,
 				4464CABD1C20A07000E5BB55 /* DumpRenderTreeAppMain.mm */,
 				A1158D55189273EB0088C17B /* DumpRenderTreeBrowserView.h */,
 				A1158D56189273EB0088C17B /* DumpRenderTreeBrowserView.mm */,
@@ -902,6 +905,7 @@
 			isa = PBXResourcesBuildPhase;
 			buildActionMask = 2147483647;
 			files = (
+				0F4E43E31D5C2BAF008EBA5C /* Launch.storyboard in Resources */,
 			);
 			runOnlyForDeploymentPostprocessing = 0;
 		};
@@ -1198,6 +1202,7 @@
 			baseConfigurationReference = A19317FD18928738001C52B1 /* DumpRenderTreeApp.xcconfig */;
 			buildSettings = {
 				INFOPLIST_FILE = "$(SRCROOT)/ios/Info.plist";
+				TARGETED_DEVICE_FAMILY = "1,2";
 			};
 			name = Debug;
 		};
@@ -1206,6 +1211,7 @@
 			baseConfigurationReference = A19317FD18928738001C52B1 /* DumpRenderTreeApp.xcconfig */;
 			buildSettings = {
 				INFOPLIST_FILE = "$(SRCROOT)/ios/Info.plist";
+				TARGETED_DEVICE_FAMILY = "1,2";
 			};
 			name = Release;
 		};
@@ -1214,6 +1220,7 @@
 			baseConfigurationReference = A19317FD18928738001C52B1 /* DumpRenderTreeApp.xcconfig */;
 			buildSettings = {
 				INFOPLIST_FILE = "$(SRCROOT)/ios/Info.plist";
+				TARGETED_DEVICE_FAMILY = "1,2";
 			};
 			name = Production;
 		};

Modified: trunk/Tools/DumpRenderTree/ios/Info.plist (204377 => 204378)


--- trunk/Tools/DumpRenderTree/ios/Info.plist	2016-08-11 17:48:57 UTC (rev 204377)
+++ trunk/Tools/DumpRenderTree/ios/Info.plist	2016-08-11 18:14:05 UTC (rev 204378)
@@ -27,5 +27,24 @@
 		<key>NSAllowsArbitraryLoads</key>
 		<true/>
 	</dict>
+	<key>UILaunchStoryboardName</key>
+	<string>Launch</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>

Added: trunk/Tools/DumpRenderTree/ios/Launch.storyboard (0 => 204378)


--- trunk/Tools/DumpRenderTree/ios/Launch.storyboard	                        (rev 0)
+++ trunk/Tools/DumpRenderTree/ios/Launch.storyboard	2016-08-11 18:14:05 UTC (rev 204378)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="11134" systemVersion="15F34" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES">
+    <dependencies>
+        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="11106"/>
+    </dependencies>
+    <scenes/>
+</document>

Modified: trunk/Tools/DumpRenderTree/mac/Configurations/DumpRenderTreeApp.xcconfig (204377 => 204378)


--- trunk/Tools/DumpRenderTree/mac/Configurations/DumpRenderTreeApp.xcconfig	2016-08-11 17:48:57 UTC (rev 204377)
+++ trunk/Tools/DumpRenderTree/mac/Configurations/DumpRenderTreeApp.xcconfig	2016-08-11 18:14:05 UTC (rev 204378)
@@ -30,5 +30,10 @@
 OTHER_LDFLAGS = $(PLATFORM_OTHER_LDFLAGS) $(ASAN_OTHER_LDFLAGS);
 PLATFORM_OTHER_LDFLAGS[sdk=iphone*] = -l$(WEBKIT_SYSTEM_INTERFACE_LIBRARY) -lWebCoreTestSupport -force_load $(BUILT_PRODUCTS_DIR)/libDumpRenderTree.a -framework QuartzCore -framework CFNetwork -framework CoreFoundation -framework CoreGraphics -framework Foundation -framework GraphicsServices -framework ImageIO -framework MobileCoreServices -framework UIKit -framework WebCore -framework _javascript_Core -framework WebKit $(OTHER_LDFLAGS_FONTS);
 PLATFORM_OTHER_LDFLAGS[sdk=macosx*] = -framework _javascript_Core;
+
 LD_RUNPATH_SEARCH_PATHS = "@loader_path/.";
+
+EXCLUDED_SOURCE_FILE_NAMES[sdk=macosx*] = ios/*;
+
 PRODUCT_NAME = DumpRenderTree;
+

Modified: trunk/Tools/DumpRenderTree/mac/DumpRenderTree.mm (204377 => 204378)


--- trunk/Tools/DumpRenderTree/mac/DumpRenderTree.mm	2016-08-11 17:48:57 UTC (rev 204377)
+++ trunk/Tools/DumpRenderTree/mac/DumpRenderTree.mm	2016-08-11 18:14:05 UTC (rev 204378)
@@ -820,6 +820,10 @@
     uiWindowRect.origin.y += [UIApp statusBarHeight];
     UIWindow *uiWindow = [[[UIWindow alloc] initWithFrame:uiWindowRect] autorelease];
 
+    UIViewController *viewController = [[UIViewController alloc] init];
+    [uiWindow setRootViewController:viewController];
+    [viewController release];
+
     // The UIWindow and UIWebBrowserView are released when the DumpRenderTreeWindow is closed.
     drtWindow.uiWindow = uiWindow;
     drtWindow.browserView = webBrowserView;
@@ -827,7 +831,7 @@
     UIWebScrollView *scrollView = [[UIWebScrollView alloc] initWithFrame:layoutTestViewportRect];
     [scrollView addSubview:webBrowserView];
 
-    [uiWindow addSubview:scrollView];
+    [viewController.view addSubview:scrollView];
     [scrollView release];
 
     adjustWebDocumentForStandardViewport(webBrowserView, scrollView);

Modified: trunk/Tools/WebKitTestRunner/WebKitTestRunner.xcodeproj/project.pbxproj (204377 => 204378)


--- trunk/Tools/WebKitTestRunner/WebKitTestRunner.xcodeproj/project.pbxproj	2016-08-11 17:48:57 UTC (rev 204377)
+++ trunk/Tools/WebKitTestRunner/WebKitTestRunner.xcodeproj/project.pbxproj	2016-08-11 18:14:05 UTC (rev 204378)
@@ -74,7 +74,6 @@
 		2E63EDA11891B291002A7AFC /* AccessibilityUIElementIOS.mm in Sources */ = {isa = PBXBuildFile; fileRef = 2E63ED781891ACE9002A7AFC /* AccessibilityUIElementIOS.mm */; };
 		2E63EDA61891BDC0002A7AFC /* TestRunner.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BCC9981711D3F51E0017BCA2 /* TestRunner.cpp */; };
 		2E749BF21891EBFA007FC175 /* EventSenderProxyIOS.mm in Sources */ = {isa = PBXBuildFile; fileRef = 2E63ED7A1891ACE9002A7AFC /* EventSenderProxyIOS.mm */; };
-		2EE52CED1890A9A80010ED21 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 2EE52CEB1890A9A80010ED21 /* InfoPlist.strings */; };
 		5641E2D014335E95008307E5 /* JSTextInputController.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 5641E2CE14335E95008307E5 /* JSTextInputController.cpp */; };
 		5664A49A14326384008881BE /* TextInputController.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 5664A49814326384008881BE /* TextInputController.cpp */; };
 		5670B8281386FCA5002EB355 /* EventSenderProxy.mm in Sources */ = {isa = PBXBuildFile; fileRef = 5670B8271386FCA5002EB355 /* EventSenderProxy.mm */; };
@@ -247,7 +246,6 @@
 		2EE52CE21890A9A80010ED21 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
 		2EE52CE41890A9A80010ED21 /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; };
 		2EE52CEA1890A9A80010ED21 /* WebKitTestRunnerApp-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; name = "WebKitTestRunnerApp-Info.plist"; path = "WebKitTestRunnerApp/WebKitTestRunnerApp-Info.plist"; sourceTree = "<group>"; };
-		2EE52CEC1890A9A80010ED21 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = "<group>"; };
 		2EE52CF11890A9A80010ED21 /* AppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = "<group>"; };
 		2EE52CF21890A9A80010ED21 /* AppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = "<group>"; };
 		2EE52D131890A9FB0010ED21 /* PlatformWebViewIOS.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = PlatformWebViewIOS.mm; sourceTree = "<group>"; };
@@ -562,7 +560,6 @@
 			children = (
 				2EE52CF11890A9A80010ED21 /* AppDelegate.h */,
 				2EE52CF21890A9A80010ED21 /* AppDelegate.m */,
-				2EE52CEB1890A9A80010ED21 /* InfoPlist.strings */,
 				0F4B08721D5BE88D00EC1B78 /* Launch.storyboard */,
 				2EE52D161890A9FB0010ED21 /* mainIOS.mm */,
 			);
@@ -889,7 +886,6 @@
 			isa = PBXResourcesBuildPhase;
 			buildActionMask = 2147483647;
 			files = (
-				2EE52CED1890A9A80010ED21 /* InfoPlist.strings in Resources */,
 				0F4B08731D5BE88D00EC1B78 /* Launch.storyboard in Resources */,
 			);
 			runOnlyForDeploymentPostprocessing = 0;
@@ -1068,17 +1064,6 @@
 		};
 /* End PBXTargetDependency section */
 
-/* Begin PBXVariantGroup section */
-		2EE52CEB1890A9A80010ED21 /* InfoPlist.strings */ = {
-			isa = PBXVariantGroup;
-			children = (
-				2EE52CEC1890A9A80010ED21 /* en */,
-			);
-			name = InfoPlist.strings;
-			sourceTree = "<group>";
-		};
-/* End PBXVariantGroup section */
-
 /* Begin XCBuildConfiguration section */
 		1DEB927508733DD40010E9CD /* Debug */ = {
 			isa = XCBuildConfiguration;

Deleted: trunk/Tools/WebKitTestRunner/WebKitTestRunnerApp/en.lproj/InfoPlist.strings (204377 => 204378)


--- trunk/Tools/WebKitTestRunner/WebKitTestRunnerApp/en.lproj/InfoPlist.strings	2016-08-11 17:48:57 UTC (rev 204377)
+++ trunk/Tools/WebKitTestRunner/WebKitTestRunnerApp/en.lproj/InfoPlist.strings	2016-08-11 18:14:05 UTC (rev 204378)
@@ -1,2 +0,0 @@
-/* Localized versions of Info.plist keys */
-

Modified: trunk/Tools/WebKitTestRunner/ios/PlatformWebViewIOS.mm (204377 => 204378)


--- trunk/Tools/WebKitTestRunner/ios/PlatformWebViewIOS.mm	2016-08-11 17:48:57 UTC (rev 204377)
+++ trunk/Tools/WebKitTestRunner/ios/PlatformWebViewIOS.mm	2016-08-11 18:14:05 UTC (rev 204378)
@@ -116,6 +116,7 @@
 
     UIViewController *viewController = [[UIViewController alloc] init];
     [m_window setRootViewController:viewController];
+    [viewController release];
 
     m_view = [[TestRunnerWKWebView alloc] initWithFrame:viewRectForWindowRect(rect) configuration:configuration];
 
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to