We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I tried to add image then it goes down from slider internal func setupLayers() { trackLayer.addSublayer(thumbLayer) trackLayer.addSublayer(outlineLayer) let uiview1 = UIView() let uiview2 = UIView() uiview1.frame = CGRect(x: 5, y: 0, width: thumbLayer.frame.width - 10 , height: 98) uiview2.frame = CGRect(x: 5, y: 0, width: 44 , height: 44) let appLightGrayColor = UIColor(red: 201.0/255.0, green: 201.0/255.0, blue: 201.0/255.0, alpha: 1.0) uiview1.backgroundColor = appLightGrayColor uiview1.layer.cornerRadius = 10 // uiview1.addSubview(uiview2) // uiview2.center = uiview1.center // uiview2.frame = uiview1.frame uiview2.center = uiview1.center uiview2.layer.contents = UIImage(named: "power-signal-white")?.cgImage uiview2.layer.contentsGravity = CALayerContentsGravity.resizeAspect // uiview1.center = uiview1.center // uiview1.addSubview(uiview2) uiview1.layer.addSublayer(uiview2.layer) thumbLayer.addSublayer(uiview1.layer)
thumbLayer.addSublayer(thumbOutlineLayer) }
The text was updated successfully, but these errors were encountered:
Check this pull request: #12
Sorry, something went wrong.
No branches or pull requests
I tried to add image then it goes down from slider
internal func setupLayers() {
trackLayer.addSublayer(thumbLayer)
trackLayer.addSublayer(outlineLayer)
let uiview1 = UIView()
let uiview2 = UIView()
uiview1.frame = CGRect(x: 5, y: 0, width: thumbLayer.frame.width - 10 , height: 98)
uiview2.frame = CGRect(x: 5, y: 0, width: 44 , height: 44)
let appLightGrayColor = UIColor(red: 201.0/255.0, green: 201.0/255.0, blue: 201.0/255.0, alpha: 1.0)
uiview1.backgroundColor = appLightGrayColor
uiview1.layer.cornerRadius = 10
// uiview1.addSubview(uiview2)
// uiview2.center = uiview1.center
// uiview2.frame = uiview1.frame
uiview2.center = uiview1.center
uiview2.layer.contents = UIImage(named: "power-signal-white")?.cgImage
uiview2.layer.contentsGravity = CALayerContentsGravity.resizeAspect
// uiview1.center = uiview1.center
// uiview1.addSubview(uiview2)
uiview1.layer.addSublayer(uiview2.layer)
thumbLayer.addSublayer(uiview1.layer)
The text was updated successfully, but these errors were encountered: