From c77e6eea35a8d4792eb9b368ec2fdd2c6d9cd117 Mon Sep 17 00:00:00 2001 From: chenshuanglin <1273934588@qq.com> Date: Tue, 21 Mar 2023 20:24:28 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E9=AD=94=E6=B3=95=E5=B8=BD?= =?UTF-8?q?=E5=8D=8A=E5=B1=8F=E9=AB=98=E5=BA=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Room/View/CandyTree/View/XPCandyTreeMoreView.m | 1 + .../View/CandyTree/View/XPCandyTreeViewController.m | 3 ++- .../Main/Room/View/CandyTree/View/XPRoomHalfWebView.h | 3 +++ .../Main/Room/View/CandyTree/View/XPRoomHalfWebView.m | 10 ++++++++++ 4 files changed, 16 insertions(+), 1 deletion(-) diff --git a/xplan-ios/Main/Room/View/CandyTree/View/XPCandyTreeMoreView.m b/xplan-ios/Main/Room/View/CandyTree/View/XPCandyTreeMoreView.m index 7984ae2c..ff666269 100644 --- a/xplan-ios/Main/Room/View/CandyTree/View/XPCandyTreeMoreView.m +++ b/xplan-ios/Main/Room/View/CandyTree/View/XPCandyTreeMoreView.m @@ -118,6 +118,7 @@ NSString * const kCandyTreeHideMessage = @"kCandyTreeHideMessage"; case CandyTreeMoreItemType_Buy: { XPRoomHalfWebView * webView = [[XPRoomHalfWebView alloc] init]; + webView.isCandyTree = YES; webView.url = URLWithType(kCandyTreeURL); TTPopupService * config = [[TTPopupService alloc] init]; config.maskBackgroundAlpha = 0; diff --git a/xplan-ios/Main/Room/View/CandyTree/View/XPCandyTreeViewController.m b/xplan-ios/Main/Room/View/CandyTree/View/XPCandyTreeViewController.m index 3d24c90d..d6632878 100644 --- a/xplan-ios/Main/Room/View/CandyTree/View/XPCandyTreeViewController.m +++ b/xplan-ios/Main/Room/View/CandyTree/View/XPCandyTreeViewController.m @@ -389,6 +389,7 @@ [TTPopup alertWithConfig:config confirmHandler:^{ [TTPopup dismiss]; XPRoomHalfWebView * webView = [[XPRoomHalfWebView alloc] init]; + webView.isCandyTree = YES; webView.url = URLWithType(kCandyTreeURL); [TTPopup popupView:webView style:TTPopupStyleAlert]; } cancelHandler:^{ @@ -550,7 +551,7 @@ if (!_expendLabel) { _expendLabel = [[UILabel alloc] init]; _expendLabel.font = [UIFont fontWithName:@"PingFang-SC-Medium" size:10]; - _expendLabel.textColor = [UIColor whiteColor]; + _expendLabel.textColor = [ThemeColor colorWithHexString:@"#DCC3FF"]; _expendLabel.textAlignment = NSTextAlignmentCenter; _expendLabel.text = @"消耗1糖果连续摘"; } diff --git a/xplan-ios/Main/Room/View/CandyTree/View/XPRoomHalfWebView.h b/xplan-ios/Main/Room/View/CandyTree/View/XPRoomHalfWebView.h index fed1f8fc..b8d4f349 100644 --- a/xplan-ios/Main/Room/View/CandyTree/View/XPRoomHalfWebView.h +++ b/xplan-ios/Main/Room/View/CandyTree/View/XPRoomHalfWebView.h @@ -16,6 +16,9 @@ NS_ASSUME_NONNULL_BEGIN ///是否是航海 @property (nonatomic,assign) BOOL isSailing; +/// 是否是糖果树 +@property (nonatomic,assign) BOOL isCandyTree; + @end NS_ASSUME_NONNULL_END diff --git a/xplan-ios/Main/Room/View/CandyTree/View/XPRoomHalfWebView.m b/xplan-ios/Main/Room/View/CandyTree/View/XPRoomHalfWebView.m index ab1aa4c6..6ac05c79 100644 --- a/xplan-ios/Main/Room/View/CandyTree/View/XPRoomHalfWebView.m +++ b/xplan-ios/Main/Room/View/CandyTree/View/XPRoomHalfWebView.m @@ -128,6 +128,16 @@ } } +- (void)setIsCandyTree:(BOOL)isCandyTree { + _isCandyTree = isCandyTree; + if (_isCandyTree) { + [self.stackView mas_updateConstraints:^(MASConstraintMaker *make) { + CGFloat kscale = 600.0 / 375.0; + make.height.mas_equalTo(KScreenWidth * kscale); + }]; + } +} + - (UIStackView *)stackView { if (!_stackView) { _stackView = [[UIStackView alloc] init];