Skip to content

Commit 271ae99

Browse files
feat: clean up
1 parent 57dc0d0 commit 271ae99

File tree

1 file changed

+1
-43
lines changed

1 file changed

+1
-43
lines changed

InternalTestApp/PrebidMobileDemoRendering/ViewControllers/Adapters/Prebid/OriginalAPI/PrebidUniversalCreativeTestingGAMController.swift

+1-43
Original file line numberDiff line numberDiff line change
@@ -80,49 +80,7 @@ final class PrebidUniversalCreativeTestingGAMController:
8080
rootController.bannerView.constraints.first { $0.firstAttribute == .width }?.constant = 300
8181
rootController.bannerView.constraints.first { $0.firstAttribute == .height }?.constant = 500
8282

83-
let targetWebView = bannerView.allSubViewsOf(type: WKWebView.self).first
84-
85-
if #available(iOS 14.0, *) {
86-
targetWebView?.configuration.defaultWebpagePreferences.allowsContentJavaScript = true
87-
} else {
88-
targetWebView?.configuration.preferences.javaScriptEnabled = true
89-
}
90-
91-
targetWebView?.navigationDelegate = self
92-
93-
// let js = """
94-
// function loadNewIframe() {
95-
// // The URL to load in the iframe
96-
// const iframeUrl = "http://192.168.0.102:9876"; // You can change this dynamically
97-
//
98-
// // Create the iframe element
99-
// const iframe = document.createElement("iframe");
100-
// iframe.src = iframeUrl;
101-
//
102-
// // Optional: Set other attributes like width, height, and frameBorder
103-
// iframe.width = "100%";
104-
// iframe.height = "400px";
105-
// iframe.frameBorder = "0"; // Removes the border of the iframe
106-
//
107-
// // Append the iframe to the end of the body
108-
// document.body.appendChild(iframe);
109-
// }
110-
//
111-
// // Call the function to load the iframe (you can bind this to a button or another event)
112-
// loadNewIframe();
113-
// """
114-
//
115-
// targetWebView?.evaluateJavaScript(js)
116-
83+
// let targetWebView = bannerView.allSubViewsOf(type: WKWebView.self).first
11784
// targetWebView?.load(URLRequest(url: URL(string: "http://192.168.0.102:9876")!))
11885
}
119-
120-
func bannerView(_ bannerView: GADBannerView, didFailToReceiveAdWithError error: any Error) {
121-
print(error.localizedDescription)
122-
}
123-
124-
125-
126-
127-
12886
}

0 commit comments

Comments
 (0)