送礼物面板的初始布局

This commit is contained in:
fengshuo
2021-11-10 18:42:27 +08:00
parent 8f3d012607
commit 440dc212cf
38 changed files with 1117 additions and 1 deletions

View File

@@ -150,6 +150,15 @@
E874B88827215D39003954B9 /* MicroStateModel.m in Sources */ = {isa = PBXBuildFile; fileRef = E874B88727215D39003954B9 /* MicroStateModel.m */; };
E874B88B27215EAF003954B9 /* MicroQueueModel.m in Sources */ = {isa = PBXBuildFile; fileRef = E874B88A27215EAF003954B9 /* MicroQueueModel.m */; };
E87888F42738C30E00BF1D57 /* StoreKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E87888F32738C30E00BF1D57 /* StoreKit.framework */; };
E8788934273A53D700BF1D57 /* XPSendGiftView.m in Sources */ = {isa = PBXBuildFile; fileRef = E8788933273A53D700BF1D57 /* XPSendGiftView.m */; };
E878893C273A54C300BF1D57 /* Api+Gift.m in Sources */ = {isa = PBXBuildFile; fileRef = E878893B273A54C300BF1D57 /* Api+Gift.m */; };
E878893F273A54F500BF1D57 /* XPGiftPresenter.m in Sources */ = {isa = PBXBuildFile; fileRef = E878893E273A54F500BF1D57 /* XPGiftPresenter.m */; };
E8788942273A55AD00BF1D57 /* XPGiftUsersView.m in Sources */ = {isa = PBXBuildFile; fileRef = E8788941273A55AD00BF1D57 /* XPGiftUsersView.m */; };
E8788945273A55C200BF1D57 /* XPGiftInfoView.m in Sources */ = {isa = PBXBuildFile; fileRef = E8788944273A55C200BF1D57 /* XPGiftInfoView.m */; };
E8788948273A55D000BF1D57 /* XPGiftBarView.m in Sources */ = {isa = PBXBuildFile; fileRef = E8788947273A55D000BF1D57 /* XPGiftBarView.m */; };
E878894C273A607C00BF1D57 /* XPGiftUserCollectionViewCell.m in Sources */ = {isa = PBXBuildFile; fileRef = E878894B273A607C00BF1D57 /* XPGiftUserCollectionViewCell.m */; };
E8788950273A699900BF1D57 /* ThemeColor+SendGift.m in Sources */ = {isa = PBXBuildFile; fileRef = E878894F273A699900BF1D57 /* ThemeColor+SendGift.m */; };
E8788960273BB14200BF1D57 /* XPGiftMicroUserModel.m in Sources */ = {isa = PBXBuildFile; fileRef = E878895F273BB14200BF1D57 /* XPGiftMicroUserModel.m */; };
E87A24F1272935920086A794 /* XPMessageRemoteExtModel.m in Sources */ = {isa = PBXBuildFile; fileRef = E87A24F0272935920086A794 /* XPMessageRemoteExtModel.m */; };
E88B5CA526FB088600DA9178 /* XPMineTeenagerViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = E88B5CA426FB088600DA9178 /* XPMineTeenagerViewController.m */; };
E88B5CA826FB089C00DA9178 /* XPMineTeenagePwdViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = E88B5CA726FB089C00DA9178 /* XPMineTeenagePwdViewController.m */; };
@@ -520,6 +529,25 @@
E87888F12738C23F00BF1D57 /* xplan-ios.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = "xplan-ios.entitlements"; sourceTree = "<group>"; };
E87888F22738C2D400BF1D57 /* xplan-iosRelease.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = "xplan-iosRelease.entitlements"; sourceTree = "<group>"; };
E87888F32738C30E00BF1D57 /* StoreKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = StoreKit.framework; path = System/Library/Frameworks/StoreKit.framework; sourceTree = SDKROOT; };
E8788932273A53D700BF1D57 /* XPSendGiftView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPSendGiftView.h; sourceTree = "<group>"; };
E8788933273A53D700BF1D57 /* XPSendGiftView.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = XPSendGiftView.m; sourceTree = "<group>"; };
E878893A273A54C300BF1D57 /* Api+Gift.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Api+Gift.h"; sourceTree = "<group>"; };
E878893B273A54C300BF1D57 /* Api+Gift.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = "Api+Gift.m"; sourceTree = "<group>"; };
E878893D273A54F500BF1D57 /* XPGiftPresenter.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPGiftPresenter.h; sourceTree = "<group>"; };
E878893E273A54F500BF1D57 /* XPGiftPresenter.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = XPGiftPresenter.m; sourceTree = "<group>"; };
E8788940273A55AD00BF1D57 /* XPGiftUsersView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPGiftUsersView.h; sourceTree = "<group>"; };
E8788941273A55AD00BF1D57 /* XPGiftUsersView.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = XPGiftUsersView.m; sourceTree = "<group>"; };
E8788943273A55C200BF1D57 /* XPGiftInfoView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPGiftInfoView.h; sourceTree = "<group>"; };
E8788944273A55C200BF1D57 /* XPGiftInfoView.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = XPGiftInfoView.m; sourceTree = "<group>"; };
E8788946273A55D000BF1D57 /* XPGiftBarView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPGiftBarView.h; sourceTree = "<group>"; };
E8788947273A55D000BF1D57 /* XPGiftBarView.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = XPGiftBarView.m; sourceTree = "<group>"; };
E878894A273A607C00BF1D57 /* XPGiftUserCollectionViewCell.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPGiftUserCollectionViewCell.h; sourceTree = "<group>"; };
E878894B273A607C00BF1D57 /* XPGiftUserCollectionViewCell.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = XPGiftUserCollectionViewCell.m; sourceTree = "<group>"; };
E878894D273A672200BF1D57 /* XPGiftProtocol.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPGiftProtocol.h; sourceTree = "<group>"; };
E878894E273A699900BF1D57 /* ThemeColor+SendGift.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "ThemeColor+SendGift.h"; sourceTree = "<group>"; };
E878894F273A699900BF1D57 /* ThemeColor+SendGift.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = "ThemeColor+SendGift.m"; sourceTree = "<group>"; };
E878895E273BB14200BF1D57 /* XPGiftMicroUserModel.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPGiftMicroUserModel.h; sourceTree = "<group>"; };
E878895F273BB14200BF1D57 /* XPGiftMicroUserModel.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = XPGiftMicroUserModel.m; sourceTree = "<group>"; };
E87A24EF272935920086A794 /* XPMessageRemoteExtModel.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPMessageRemoteExtModel.h; sourceTree = "<group>"; };
E87A24F0272935920086A794 /* XPMessageRemoteExtModel.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = XPMessageRemoteExtModel.m; sourceTree = "<group>"; };
E88B5CA326FB088600DA9178 /* XPMineTeenagerViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPMineTeenagerViewController.h; sourceTree = "<group>"; };
@@ -1023,6 +1051,7 @@
189DD56C26DF5B5400AB55B1 /* UI */ = {
isa = PBXGroup;
children = (
E8788931273A53B000BF1D57 /* SendGiftView */,
E8659640270160F200846EBD /* VagueImageView */,
E8AC720A26F435AF007D6E91 /* UIImageView */,
E81366F926F0D27A0076364C /* UIButton */,
@@ -1444,6 +1473,80 @@
path = Model;
sourceTree = "<group>";
};
E8788931273A53B000BF1D57 /* SendGiftView */ = {
isa = PBXGroup;
children = (
E8788935273A540400BF1D57 /* Model */,
E8788936273A541500BF1D57 /* Api */,
E8788937273A542700BF1D57 /* View */,
E8788938273A542E00BF1D57 /* Presenter */,
E8788939273A544000BF1D57 /* Protocol */,
E878894E273A699900BF1D57 /* ThemeColor+SendGift.h */,
E878894F273A699900BF1D57 /* ThemeColor+SendGift.m */,
);
path = SendGiftView;
sourceTree = "<group>";
};
E8788935273A540400BF1D57 /* Model */ = {
isa = PBXGroup;
children = (
E878895E273BB14200BF1D57 /* XPGiftMicroUserModel.h */,
E878895F273BB14200BF1D57 /* XPGiftMicroUserModel.m */,
);
path = Model;
sourceTree = "<group>";
};
E8788936273A541500BF1D57 /* Api */ = {
isa = PBXGroup;
children = (
E878893A273A54C300BF1D57 /* Api+Gift.h */,
E878893B273A54C300BF1D57 /* Api+Gift.m */,
);
path = Api;
sourceTree = "<group>";
};
E8788937273A542700BF1D57 /* View */ = {
isa = PBXGroup;
children = (
E8788949273A594C00BF1D57 /* Cell */,
E8788932273A53D700BF1D57 /* XPSendGiftView.h */,
E8788933273A53D700BF1D57 /* XPSendGiftView.m */,
E8788940273A55AD00BF1D57 /* XPGiftUsersView.h */,
E8788941273A55AD00BF1D57 /* XPGiftUsersView.m */,
E8788943273A55C200BF1D57 /* XPGiftInfoView.h */,
E8788944273A55C200BF1D57 /* XPGiftInfoView.m */,
E8788946273A55D000BF1D57 /* XPGiftBarView.h */,
E8788947273A55D000BF1D57 /* XPGiftBarView.m */,
);
path = View;
sourceTree = "<group>";
};
E8788938273A542E00BF1D57 /* Presenter */ = {
isa = PBXGroup;
children = (
E878893D273A54F500BF1D57 /* XPGiftPresenter.h */,
E878893E273A54F500BF1D57 /* XPGiftPresenter.m */,
);
path = Presenter;
sourceTree = "<group>";
};
E8788939273A544000BF1D57 /* Protocol */ = {
isa = PBXGroup;
children = (
E878894D273A672200BF1D57 /* XPGiftProtocol.h */,
);
path = Protocol;
sourceTree = "<group>";
};
E8788949273A594C00BF1D57 /* Cell */ = {
isa = PBXGroup;
children = (
E878894A273A607C00BF1D57 /* XPGiftUserCollectionViewCell.h */,
E878894B273A607C00BF1D57 /* XPGiftUserCollectionViewCell.m */,
);
path = Cell;
sourceTree = "<group>";
};
E88B5CA926FB15B900DA9178 /* Teenager */ = {
isa = PBXGroup;
children = (
@@ -2046,6 +2149,7 @@
189DD76226E60DDC00AB55B1 /* Api+Login.m in Sources */,
18E7B22626E8CDCF0064BC9B /* XplanFlutterBoostDelegate.m in Sources */,
E8EEB8F326FC2050007C6EBA /* SDWaitingView.m in Sources */,
E8788942273A55AD00BF1D57 /* XPGiftUsersView.m in Sources */,
E8B846CB26FDD7CD00A777FE /* XPMineRechargeViewController.m in Sources */,
E86596512701A1C000846EBD /* StatisticsService.m in Sources */,
E824544026F58F9400BE8163 /* XPMinePayPwdViewController.m in Sources */,
@@ -2063,12 +2167,14 @@
E84B0E3F2727EDF6008818C6 /* XPRoomMessageTableViewCell.m in Sources */,
E8EEB8F226FC2050007C6EBA /* SDPhotoBrowser.m in Sources */,
E81C27AB26EF2D920031E639 /* ThirdUserInfo.m in Sources */,
E8788950273A699900BF1D57 /* ThemeColor+SendGift.m in Sources */,
E81C279D26EEEC620031E639 /* XPConstant.m in Sources */,
187EEEFE26E8A82C002833B2 /* NSObject+AutoCoding.m in Sources */,
E8AC721926F46E0B007D6E91 /* XPMineSettingItemModel.m in Sources */,
189DD55A26DE39D200AB55B1 /* BaseMvpPresenter.m in Sources */,
180806D827293794001FD836 /* NSObject+MJExtension.m in Sources */,
189DD6FF26E20E5900AB55B1 /* HttpRequestHelper.m in Sources */,
E8788945273A55C200BF1D57 /* XPGiftInfoView.m in Sources */,
E8AEAED6271412EC0017FCE0 /* XPRoomViewController.m in Sources */,
E8E70D9226F2F60C00F03460 /* XPMineItemModel.m in Sources */,
189DD74A26E21D8400AB55B1 /* SSKeychain.m in Sources */,
@@ -2101,6 +2207,7 @@
E8EEB91726FC7B35007C6EBA /* XPMineUserInfoDesViewController.m in Sources */,
180806FB2729A354001FD836 /* ThemeColor+Room.m in Sources */,
E8E70D8626F2F55C00F03460 /* XPMineAccountView.m in Sources */,
E878893C273A54C300BF1D57 /* Api+Gift.m in Sources */,
E81C279026EB314D0031E639 /* LoginForgetEditView.m in Sources */,
E8AC721026F43955007D6E91 /* UIImageConstant.m in Sources */,
E81C27A026EEF83D0031E639 /* XPHtmlUrl.m in Sources */,
@@ -2162,6 +2269,7 @@
186A536926FC6F2E00D67B2C /* XCShareView.m in Sources */,
186A534C26FC6ED900D67B2C /* TTAlertView.m in Sources */,
E8B825BF26E9E57D009E8E9F /* LoginTicketInfo.m in Sources */,
E878894C273A607C00BF1D57 /* XPGiftUserCollectionViewCell.m in Sources */,
181D7F212727D9DB00B7C059 /* SocialStageView.m in Sources */,
187EEEF026E89FE8002833B2 /* AccountInfoStorage.m in Sources */,
186A536B26FC6F2E00D67B2C /* XCShareItemCell.m in Sources */,
@@ -2175,6 +2283,7 @@
E824546426F5FF1C00BE8163 /* XPMineResetPayPasswordPresenter.m in Sources */,
E8B846BC26FD7C1200A777FE /* UploadImage.m in Sources */,
186A534D26FC6ED900D67B2C /* TTActionSheetView.m in Sources */,
E878893F273A54F500BF1D57 /* XPGiftPresenter.m in Sources */,
E8AEAEED27141AE20017FCE0 /* XPRoomBackContainerView.m in Sources */,
E88B5CC126FB407B00DA9178 /* XPMineUserInfoViewController.m in Sources */,
E824545926F5E65900BE8163 /* XPMineVerifIdentityView.m in Sources */,
@@ -2196,6 +2305,7 @@
18E7B29026EA0E6B0064BC9B /* FlutterBoost+Xplan.m in Sources */,
E8B846DC26FDE24300A777FE /* RechargeListModel.m in Sources */,
189DD75926E6003C00AB55B1 /* Api.m in Sources */,
E8788934273A53D700BF1D57 /* XPSendGiftView.m in Sources */,
E88B5CB826FB325200DA9178 /* XPMineTeenagerPwdPresenter.m in Sources */,
E84B0E462727EF9D008818C6 /* XPRoomMessageParser.m in Sources */,
E874B88827215D39003954B9 /* MicroStateModel.m in Sources */,
@@ -2203,8 +2313,10 @@
E89DA66727006443008483C1 /* RechargeStorage.m in Sources */,
189DD53F26DE255600AB55B1 /* main.m in Sources */,
E872308D26E89DAA00B90D4F /* LoginInputView.m in Sources */,
E8788948273A55D000BF1D57 /* XPGiftBarView.m in Sources */,
189DD58F26DF97E700AB55B1 /* LoginPresenter.m in Sources */,
E89DA67227008D59008483C1 /* WalletInfoModel.m in Sources */,
E8788960273BB14200BF1D57 /* XPGiftMicroUserModel.m in Sources */,
189DD55026DE37F900AB55B1 /* MvpViewController.m in Sources */,
E81366F326F0B7C80076364C /* LoginFullInfoViewController.m in Sources */,
);

View File

@@ -0,0 +1,6 @@
{
"info" : {
"author" : "xcode",
"version" : 1
}
}

View File

@@ -0,0 +1,22 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "gift_all_micro_normal@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "gift_all_micro_normal@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.5 KiB

View File

@@ -0,0 +1,22 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "gift_all_micro_select@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "gift_all_micro_select@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.6 KiB

View File

@@ -0,0 +1,22 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "gift_bar_count_arrow@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "gift_bar_count_arrow@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 157 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 213 B

View File

@@ -0,0 +1,22 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "gift_bar_count_up_arrow@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "gift_bar_count_up_arrow@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 197 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 287 B

View File

@@ -0,0 +1,22 @@
{
"images" : [
{
"idiom" : "universal",
"scale" : "1x"
},
{
"filename" : "gift_bar_recharge_arrow@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
"filename" : "gift_bar_recharge_arrow@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 186 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 261 B

View File

@@ -0,0 +1,16 @@
//
// Api+Gift.h
// xplan-ios
//
// Created by 冯硕 on 2021/11/9.
//
#import "Api.h"
NS_ASSUME_NONNULL_BEGIN
@interface Api (Gift)
@end
NS_ASSUME_NONNULL_END

View File

@@ -0,0 +1,12 @@
//
// Api+Gift.m
// xplan-ios
//
// Created by on 2021/11/9.
//
#import "Api+Gift.h"
@implementation Api (Gift)
@end

View File

@@ -0,0 +1,19 @@
//
// XPGiftMicroUserModel.h
// xplan-ios
//
// Created by 冯硕 on 2021/11/10.
//
#import <Foundation/Foundation.h>
NS_ASSUME_NONNULL_BEGIN
@class MicroQueueModel;
@interface XPGiftMicroUserModel : NSObject
///是否选择 本地字段刷新页面使用
@property (nonatomic,assign) BOOL isSelect;
///麦序信息
@property (nonatomic,strong) MicroQueueModel *microQueue;
@end
NS_ASSUME_NONNULL_END

View File

@@ -0,0 +1,19 @@
//
// XPGiftMicroUserModel.m
// xplan-ios
//
// Created by on 2021/11/10.
//
#import "XPGiftMicroUserModel.h"
@implementation XPGiftMicroUserModel
- (instancetype)init {
if (self = [super init]) {
self.isSelect = NO;
}
return self;
}
@end

View File

@@ -0,0 +1,16 @@
//
// XPGiftPresenter.h
// xplan-ios
//
// Created by 冯硕 on 2021/11/9.
//
#import "BaseMvpPresenter.h"
NS_ASSUME_NONNULL_BEGIN
@interface XPGiftPresenter : BaseMvpPresenter
@end
NS_ASSUME_NONNULL_END

View File

@@ -0,0 +1,12 @@
//
// XPGiftPresenter.m
// xplan-ios
//
// Created by on 2021/11/9.
//
#import "XPGiftPresenter.h"
@implementation XPGiftPresenter
@end

View File

@@ -0,0 +1,16 @@
//
// XPGiftProtocol.h
// xplan-ios
//
// Created by 冯硕 on 2021/11/9.
//
#import <Foundation/Foundation.h>
NS_ASSUME_NONNULL_BEGIN
@protocol XPGiftProtocol <NSObject>
@end
NS_ASSUME_NONNULL_END

View File

@@ -0,0 +1,21 @@
//
// ThemeColor+SendGift.h
// xplan-ios
//
// Created by 冯硕 on 2021/11/9.
//
#import "ThemeColor.h"
NS_ASSUME_NONNULL_BEGIN
@interface ThemeColor (SendGift)
/// 没有选择送礼物的人的头像 UIColorRGBAlpha(0x000000, 0.3)
+ (UIColor *)avatarCoverColor;
/// 送礼物 充值 0xFF903E
+ (UIColor *)giftRechargeColor;
/// 礼物主背景色 #0B0B0D
+ (UIColor *)giftBackGroundColor;
@end
NS_ASSUME_NONNULL_END

View File

@@ -0,0 +1,27 @@
//
// ThemeColor+SendGift.m
// xplan-ios
//
// Created by on 2021/11/9.
//
#import "ThemeColor+SendGift.h"
@implementation ThemeColor (SendGift)
/// UIColorRGBAlpha(0x000000, 0.3)
+ (UIColor *)avatarCoverColor {
return [UIColor colorWithWhite:0 alpha:0.3];
}
/// 0xFF903E
+ (UIColor *)giftRechargeColor {
return UIColorFromRGB(0xFF903E);
}
/// #0B0B0D
+ (UIColor *)giftBackGroundColor {
return UIColorRGBAlpha(0x0C0B0C, 0.9);
}
@end

View File

@@ -0,0 +1,17 @@
//
// XPGiftUserCollectionViewCell.h
// xplan-ios
//
// Created by 冯硕 on 2021/11/9.
//
#import <UIKit/UIKit.h>
NS_ASSUME_NONNULL_BEGIN
@class XPGiftMicroUserModel;
@interface XPGiftUserCollectionViewCell : UICollectionViewCell
///数据模型
@property (nonatomic,strong) XPGiftMicroUserModel *microModel;
@end
NS_ASSUME_NONNULL_END

View File

@@ -0,0 +1,120 @@
//
// XPGiftUserCollectionViewCell.m
// xplan-ios
//
// Created by on 2021/11/9.
//
#import "XPGiftUserCollectionViewCell.h"
///Third
#import <Masonry/Masonry.h>
///Tool
#import "ThemeColor+SendGift.h"
///Model
#import "MicroQueueModel.h"
#import "UserInfoModel.h"
#import "MicroStateModel.h"
#import "XPGiftMicroUserModel.h"
///View
#import "NetImageView.h"
@interface XPGiftUserCollectionViewCell ()
///
@property (nonatomic,strong) NetImageView *avatarImageView;
///
@property (nonatomic,strong) UILabel *positionLabel;
///
@property (nonatomic,strong) UIView * coverView;
@end
@implementation XPGiftUserCollectionViewCell
- (instancetype)initWithFrame:(CGRect)frame {
if (self = [super initWithFrame:frame]) {
[self initSubViews];
[self initSubViewConstraints];
}
return self;
}
- (void)layoutSubviews {
[super layoutSubviews];
self.coverView.layer.cornerRadius = self.coverView.frame.size.width / 2;
}
#pragma mark - Private Method
- (void)initSubViews {
[self.contentView addSubview:self.avatarImageView];
[self.contentView addSubview:self.positionLabel];
[self.contentView addSubview:self.coverView];
}
- (void)initSubViewConstraints {
[self.avatarImageView mas_makeConstraints:^(MASConstraintMaker *make) {
make.left.right.top.mas_equalTo(self.contentView);
make.height.mas_equalTo(self.avatarImageView.mas_width);
}];
[self.positionLabel mas_makeConstraints:^(MASConstraintMaker *make) {
make.height.mas_equalTo(10);
make.centerY.mas_equalTo(self.avatarImageView.mas_bottom);
make.width.mas_equalTo(10);
}];
[self.coverView mas_makeConstraints:^(MASConstraintMaker *make) {
make.edges.mas_equalTo(self.contentView);
}];
}
#pragma mark - Getters And Setters
- (void)setMicroModel:(XPGiftMicroUserModel *)microModel {
_microModel = microModel;
if (_microModel.microQueue.microState.position == -1) {
self.positionLabel.text = @"房主位";
[self.positionLabel mas_updateConstraints:^(MASConstraintMaker *make) {
make.width.mas_equalTo(23);
}];
} else {
self.positionLabel.text = [NSString stringWithFormat:@"%d", microModel.microQueue.microState.position];
[self.positionLabel mas_updateConstraints:^(MASConstraintMaker *make) {
make.width.mas_equalTo(10);
}];
}
UserInfoModel * userInfo = microModel.microQueue.userInfo;
self.avatarImageView.imageUrl = userInfo.avatar;
self.coverView.hidden = microModel.isSelect;
}
- (NetImageView *)avatarImageView {
if (!_avatarImageView) {
_avatarImageView = [[NetImageView alloc] init];
_avatarImageView.layer.masksToBounds = YES;
_avatarImageView.layer.cornerRadius = 15;
_avatarImageView.imageType = ImageTypeUserIcon;
_avatarImageView.image = [UIImageConstant defaultAvatarPlaceholder];
}
return _avatarImageView;
}
- (UILabel *)positionLabel{
if (!_positionLabel) {
_positionLabel = [[UILabel alloc] init];
_positionLabel.font = [UIFont systemFontOfSize:14];
_positionLabel.textColor = [ThemeColor mainTextColor];
_positionLabel.textAlignment = NSTextAlignmentCenter;
}
return _positionLabel;
}
- (UIView *)coverView {
if (!_coverView) {
_coverView = [[UIView alloc] init];
_coverView.backgroundColor = [ThemeColor avatarCoverColor];
_coverView.layer.masksToBounds = YES;
_coverView.layer.cornerRadius = 38/2;
}
return _coverView;
}
@end

View File

@@ -0,0 +1,16 @@
//
// XPGiftBottomView.h
// xplan-ios
//
// Created by 冯硕 on 2021/11/9.
//
#import <UIKit/UIKit.h>
NS_ASSUME_NONNULL_BEGIN
@interface XPGiftBarView : UIView
@end
NS_ASSUME_NONNULL_END

View File

@@ -0,0 +1,200 @@
//
// XPGiftBottomView.m
// xplan-ios
//
// Created by on 2021/11/9.
//
#import "XPGiftBarView.h"
///Third
#import <Masonry/Masonry.h>
///Tool
#import "ThemeColor+SendGift.h"
#import "UIImage+Utils.h"
@interface XPGiftBarView ()
///
@property (nonatomic,strong) UILabel *balanceLabel;
///
@property (nonatomic,strong) UIStackView *rechargeStackView;
///
@property (nonatomic,strong) UILabel *rechargeLabel;
///
@property (nonatomic,strong) UIImageView *rechageImageView;
///
@property (nonatomic,strong) UIView *sendOperationView;
///
@property (nonatomic,strong) UILabel *countLabel;
///
@property (nonatomic,strong) UIButton *arrowButton;
///
@property (nonatomic,strong) UIButton *sendGiftButton;
@end
@implementation XPGiftBarView
- (instancetype)initWithFrame:(CGRect)frame {
self = [super initWithFrame:frame];
if (self) {
[self initSubViews];
[self initSubViewConstraints];
}
return self;
}
#pragma mark - Response
- (void)sendButtonAction:(UIButton *)sender {
}
- (void)rechargeButtonAction:(UIButton *)sender {
}
- (void)arrowButtonAction:(UIButton *)sender {
}
#pragma mark - Private Method
- (void)initSubViews {
self.backgroundColor= [UIColor clearColor];
[self addSubview:self.balanceLabel];
[self addSubview:self.rechargeStackView];
[self addSubview:self.sendOperationView];
[self.rechargeStackView addArrangedSubview:self.rechargeLabel];
[self.rechargeStackView addArrangedSubview:self.rechageImageView];
[self.sendOperationView addSubview:self.countLabel];
[self.sendOperationView addSubview:self.arrowButton];
[self.sendOperationView addSubview:self.sendGiftButton];
}
- (void)initSubViewConstraints {
[self mas_makeConstraints:^(MASConstraintMaker *make) {
make.height.mas_equalTo(45);
}];
[self.balanceLabel mas_makeConstraints:^(MASConstraintMaker *make) {
make.left.mas_equalTo(15);
make.centerY.mas_equalTo(self.sendOperationView);
}];
[self.rechargeStackView mas_makeConstraints:^(MASConstraintMaker *make) {
make.centerY.mas_equalTo(self.sendOperationView);
make.left.mas_equalTo(self.balanceLabel.mas_right).offset(12);
}];
[self.sendOperationView mas_makeConstraints:^(MASConstraintMaker *make) {
make.right.mas_equalTo(self).offset(-15);
make.bottom.mas_equalTo(-11);
make.height.mas_equalTo(30);
make.left.mas_equalTo(self.countLabel.mas_left).offset(-13);
}];
[self.countLabel mas_makeConstraints:^(MASConstraintMaker *make) {
make.centerY.mas_equalTo(self.sendGiftButton);
make.right.mas_equalTo(self.arrowButton.mas_left).offset(-10);
}];
[self.arrowButton mas_makeConstraints:^(MASConstraintMaker *make) {
make.size.mas_equalTo(CGSizeMake(10, 10));
make.centerY.mas_equalTo(self.sendGiftButton);
make.right.mas_equalTo(self.sendGiftButton.mas_left).offset(-10);
}];
[self.sendGiftButton mas_makeConstraints:^(MASConstraintMaker *make) {
make.size.mas_equalTo(CGSizeMake(67, 30));
make.right.centerY.mas_equalTo(self.sendOperationView);
}];
}
#pragma mark - Getters And Setters
- (UILabel *)balanceLabel {
if (!_balanceLabel) {
_balanceLabel = [[UILabel alloc] init];
_balanceLabel.textColor = [ThemeColor mainTextColor];
_balanceLabel.font = [UIFont systemFontOfSize:13];
_balanceLabel.text = @"余额10000";
}
return _balanceLabel;
}
- (UIStackView *)rechargeStackView {
if (!_rechargeStackView) {
_rechargeStackView = [[UIStackView alloc] init];
_rechargeStackView.axis = UILayoutConstraintAxisHorizontal;
_rechargeStackView.distribution = UIStackViewDistributionFill;
_rechargeStackView.alignment = UIStackViewAlignmentCenter;
_rechargeStackView.spacing = 5;
}
return _rechargeStackView;
}
- (UILabel *)rechargeLabel {
if (!_rechargeLabel) {
_rechargeLabel = [[UILabel alloc] init];
_rechargeLabel.text = @"充值";
_rechargeLabel.font = [UIFont systemFontOfSize:13];
_rechargeLabel.textColor = [ThemeColor giftRechargeColor];
}
return _rechargeLabel;
}
- (UIImageView *)rechageImageView {
if (!_rechageImageView) {
_rechageImageView = [[UIImageView alloc] init];
_rechageImageView.userInteractionEnabled = YES;
_rechageImageView.image = [UIImage imageNamed:@"gift_bar_recharge_arrow"];
}
return _rechageImageView;
}
- (UIView *)sendOperationView {
if (!_sendOperationView) {
_sendOperationView = [[UIView alloc] init];
_sendOperationView.layer.masksToBounds = YES;
_sendOperationView.layer.cornerRadius = 15;
_sendOperationView.layer.borderColor = [ThemeColor appMainColor].CGColor;
_sendOperationView.layer.borderWidth = 1;
}
return _sendOperationView;
}
- (UILabel *)countLabel {
if (!_countLabel) {
_countLabel = [[UILabel alloc] init];
_countLabel.textAlignment = NSTextAlignmentCenter;
_countLabel.textColor = [ThemeColor mainTextColor];
_countLabel.text = @"1";
_countLabel.font = [UIFont systemFontOfSize:13];
}
return _countLabel;
}
- (UIButton *)arrowButton {
if (!_arrowButton) {
_arrowButton = [UIButton buttonWithType:UIButtonTypeCustom];
[_arrowButton setImage:[UIImage imageNamed:@"gift_bar_count_arrow"] forState:UIControlStateNormal];
[_arrowButton setImage:[UIImage imageNamed:@"gift_bar_count_up_arrow"] forState:UIControlStateSelected];
[_arrowButton addTarget:self action:@selector(arrowButtonAction:) forControlEvents:UIControlEventTouchUpInside];
}
return _arrowButton;
}
- (UIButton *)sendGiftButton {
if (!_sendGiftButton) {
_sendGiftButton = [UIButton buttonWithType:UIButtonTypeCustom];
[_sendGiftButton setTitle:@"赠送" forState:UIControlStateNormal];
[_sendGiftButton setTitleColor:[ThemeColor mainTextColor] forState:UIControlStateNormal];
[_sendGiftButton setBackgroundImage:[UIImage gradientColorImageFromColors:@[[ThemeColor confirmButtonGradientStartColor], [ThemeColor confirmButtonGradientEndColor]] gradientType:GradientTypeLeftToRight imgSize:CGSizeMake(10, 10)] forState:UIControlStateNormal];
_sendGiftButton.titleLabel.font = [UIFont systemFontOfSize:13];
_sendGiftButton.layer.masksToBounds = YES;
_sendGiftButton.layer.cornerRadius = 15;
[_sendGiftButton addTarget:self action:@selector(sendButtonAction:) forControlEvents:UIControlEventTouchUpInside];
}
return _sendGiftButton;
}
@end

View File

@@ -0,0 +1,16 @@
//
// XPGiftMiddleView.h
// xplan-ios
//
// Created by 冯硕 on 2021/11/9.
//
#import <UIKit/UIKit.h>
NS_ASSUME_NONNULL_BEGIN
@interface XPGiftInfoView : UIView
@end
NS_ASSUME_NONNULL_END

View File

@@ -0,0 +1,36 @@
//
// XPGiftMiddleView.m
// xplan-ios
//
// Created by on 2021/11/9.
//
#import "XPGiftInfoView.h"
///Third
#import <Masonry/Masonry.h>
@implementation XPGiftInfoView
- (instancetype)initWithFrame:(CGRect)frame
{
self = [super initWithFrame:frame];
if (self) {
[self initSubViews];
[self initSubViewConstraints];
}
return self;
}
#pragma mark - Private Method
- (void)initSubViews {
self.backgroundColor = [UIColor yellowColor];
}
- (void)initSubViewConstraints {
[self mas_makeConstraints:^(MASConstraintMaker *make) {
make.height.mas_equalTo(250);
}];
}
@end

View File

@@ -0,0 +1,20 @@
//
// XPGiftUsersView.h
// xplan-ios
//
// Created by 冯硕 on 2021/11/9.
//
#import <UIKit/UIKit.h>
#import "XPSendGiftView.h"
#import "MicroQueueProtocol.h"
NS_ASSUME_NONNULL_BEGIN
@interface XPGiftUsersView : UIView<MicroQueueProtocol>
- (instancetype)initWithType:(SendGiftType)type;
///选中的人 送给谁礼物
@property (nonatomic,strong, readonly) NSMutableArray<NSString *> *selectUserArray;
@end
NS_ASSUME_NONNULL_END

View File

@@ -0,0 +1,169 @@
//
// XPGiftUsersView.m
// xplan-ios
//
// Created by on 2021/11/9.
//
#import "XPGiftUsersView.h"
///Third
#import <Masonry/Masonry.h>
///Tool
#import "AccountInfoStorage.h"
///Model
#import "UserInfoModel.h"
#import "MicroQueueModel.h"
#import "XPGiftMicroUserModel.h"
///view
#import "XPGiftUserCollectionViewCell.h"
@interface XPGiftUsersView ()<UICollectionViewDelegate, UICollectionViewDataSource>
///
@property (nonatomic,strong) UIStackView *stackView;
///
@property (nonatomic,strong) UIButton *allMicroButton;
///
@property (nonatomic,strong) UICollectionView *collectionView;
///
@property (nonatomic,assign) SendGiftType type;
///
@property (nonatomic,strong) NSArray<XPGiftMicroUserModel *> *userArray;
///
@property (nonatomic,strong) NSMutableArray<NSString *> *selectUserArray;
@end
@implementation XPGiftUsersView
- (instancetype)initWithType:(SendGiftType)type {
if (self = [super init]) {
[self initSubViews];
[self initSubViewConstraints];
}
return self;
}
#pragma mark - Response
- (void)allMicroButtonAction:(UIButton *)sender {
sender.selected = !sender.selected;
[self.userArray enumerateObjectsUsingBlock:^(XPGiftMicroUserModel * _Nonnull obj, NSUInteger idx, BOOL * _Nonnull stop) {
obj.isSelect = YES;
}];
[self.collectionView reloadData];
}
#pragma mark - Private Method
- (void)initSubViews {
self.backgroundColor = [UIColor purpleColor];
[self addSubview:self.stackView];
[self.stackView addArrangedSubview:self.allMicroButton];
[self.stackView addArrangedSubview:self.collectionView];
if (self.type == SendGiftType_User) {
self.allMicroButton.hidden = YES;
}
}
- (void)initSubViewConstraints {
[self mas_makeConstraints:^(MASConstraintMaker *make) {
make.height.mas_equalTo(28 + 15 * 2);
}];
[self.stackView mas_makeConstraints:^(MASConstraintMaker *make) {
make.edges.mas_equalTo(self);
}];
}
///
/// @param users
- (NSArray *)findSendGiftAllUsers:(NSArray<MicroQueueModel *> *)users {
NSMutableArray * tempArray = [NSMutableArray array];
NSString * uid = [AccountInfoStorage instance].getUid;
for (int i = 0; i < users.count; i++) {
MicroQueueModel * micModel = [users objectAtIndex:i];
UserInfoModel * userInfo = micModel.userInfo;
if (userInfo && userInfo.uid > 0 && userInfo.uid != uid.integerValue) { ///
XPGiftMicroUserModel * giftUserModel = [[XPGiftMicroUserModel alloc] init];
if ([self.selectUserArray containsObject:[NSString stringWithFormat:@"%ld", userInfo.uid]]){
giftUserModel.isSelect = YES;
}
[tempArray addObject:giftUserModel];
}
}
return [tempArray copy];
}
#pragma mark - MicroQueueProtocol
- (void)onMicroQueueUpdate:(NSMutableDictionary<NSString *,MicroQueueModel *> *)queue {
self.userArray = [self findSendGiftAllUsers:queue.allValues];
[self.collectionView reloadData];
}
#pragma mark - UICollectionViewDataSource And UICollectionViewDelegate
- (NSInteger)collectionView:(UICollectionView *)collectionView numberOfItemsInSection:(NSInteger)section {
return self.userArray.count;
}
-(__kindof UICollectionViewCell *)collectionView:(UICollectionView *)collectionView cellForItemAtIndexPath:(NSIndexPath *)indexPath {
XPGiftUserCollectionViewCell * cell = [collectionView dequeueReusableCellWithReuseIdentifier:NSStringFromClass([XPGiftUserCollectionViewCell class]) forIndexPath:indexPath];
XPGiftMicroUserModel * queue = [self.userArray objectAtIndex:indexPath.row];
cell.microModel = queue;
return cell;
}
- (void)collectionView:(UICollectionView *)collectionView didSelectItemAtIndexPath:(NSIndexPath *)indexPath {
[collectionView deselectItemAtIndexPath:indexPath animated:YES];
XPGiftMicroUserModel * queue = [self.userArray objectAtIndex:indexPath.row];
queue.isSelect = !queue.isSelect;
[self.collectionView reloadData];
NSString * selectUid = [NSString stringWithFormat:@"%ld", queue.microQueue.userInfo.uid];
if (queue.isSelect) {
[self.selectUserArray addObject:selectUid];
} else {
if ([self.selectUserArray containsObject:selectUid]) {
[self.selectUserArray removeObject:selectUid];
}
}
}
#pragma mark - Getters And Setters
- (UIStackView *)stackView {
if (!_stackView) {
_stackView = [[UIStackView alloc] init];
_stackView.axis = UILayoutConstraintAxisHorizontal;
_stackView.distribution = UIStackViewDistributionFill;
_stackView.alignment = UIStackViewAlignmentCenter;
_stackView.spacing = 10;
}
return _stackView;
}
- (UIButton *)allMicroButton {
if (!_allMicroButton) {
_allMicroButton = [UIButton buttonWithType:UIButtonTypeCustom];
[_allMicroButton setImage:[UIImage imageNamed:@"gift_all_micro_normal"] forState:UIControlStateNormal];
[_allMicroButton setImage:[UIImage imageNamed:@"gift_all_micro_select"] forState:UIControlStateSelected];
[_allMicroButton addTarget:self action:@selector(allMicroButtonAction:) forControlEvents:UIControlEventTouchUpInside];
}
return _allMicroButton;
}
- (UICollectionView *)collectionView{
if (!_collectionView) {
UICollectionViewFlowLayout *layout = [[UICollectionViewFlowLayout alloc] init];
layout.itemSize = CGSizeMake(28, 35);
layout.minimumLineSpacing = 6;
layout.sectionInset = UIEdgeInsetsMake(0, 0, 0,0);
_collectionView = [[UICollectionView alloc] initWithFrame:CGRectZero collectionViewLayout:layout];
_collectionView.dataSource = self;
_collectionView.delegate = self;
_collectionView.backgroundColor = [UIColor clearColor];
_collectionView.showsHorizontalScrollIndicator = NO;
[_collectionView registerClass:[XPGiftUserCollectionViewCell class] forCellWithReuseIdentifier:NSStringFromClass([XPGiftUserCollectionViewCell class])];
}
return _collectionView;
}
- (NSMutableArray<NSString *> *)selectUserArray {
if (!_selectUserArray) {
_selectUserArray = [NSMutableArray array];
}
return _selectUserArray;
}
@end

View File

@@ -0,0 +1,31 @@
//
// XPSendGiftView.h
// xplan-ios
//
// Created by 冯硕 on 2021/11/9.
//
#import <UIKit/UIKit.h>
NS_ASSUME_NONNULL_BEGIN
typedef NS_ENUM(NSInteger, SendGiftType) {
SendGiftType_Room = 1, ///房间内送礼物
SendGiftType_User, ///送给某一个人
};
@interface XPSendGiftView : UIView
/// 送礼物的
/// @param type 送礼物的类型
/// @param uid 送礼物的人
- (instancetype)initWithType:(SendGiftType)type uid:(NSString *)uid;
- (instancetype)init NS_UNAVAILABLE;
+ (instancetype)new NS_UNAVAILABLE;
- (instancetype)copy NS_UNAVAILABLE;
- (instancetype)mutableCopy NS_UNAVAILABLE;
@end
NS_ASSUME_NONNULL_END

View File

@@ -0,0 +1,96 @@
//
// XPSendGiftView.m
// xplan-ios
//
// Created by on 2021/11/9.
//
#import "XPSendGiftView.h"
///Third
#import <Masonry/Masonry.h>
///Tool
#import "XPMacro.h"
#import "ThemeColor+SendGift.h"
///View
#import "XPGiftUsersView.h"
#import "XPGiftInfoView.h"
#import "XPGiftBarView.h"
@interface XPSendGiftView ()
///
@property (nonatomic,strong) UIStackView *stackView;
///
@property (nonatomic,strong) XPGiftUsersView *userView;
///
@property (nonatomic,strong) XPGiftInfoView *giftInfoView;
///
@property (nonatomic,strong) XPGiftBarView *giftBarView;
@end
@implementation XPSendGiftView
- (instancetype)initWithType:(SendGiftType)type uid:(NSString *)uid {
if (self = [super init]) {
[self initSubViews];
[self initSubViewConstraints];
}
return self;
}
#pragma mark - Private Method
- (void)initSubViews {
self.backgroundColor = [ThemeColor giftBackGroundColor];
[self addSubview:self.stackView];
[self.stackView addArrangedSubview:self.userView];
[self.stackView addArrangedSubview:self.giftInfoView];
[self.stackView addArrangedSubview:self.giftBarView];
}
- (void)initSubViewConstraints {
[self mas_makeConstraints:^(MASConstraintMaker *make) {
make.width.mas_equalTo(KScreenWidth);
make.bottom.mas_equalTo(self.stackView.mas_bottom);
}];
[self.stackView mas_makeConstraints:^(MASConstraintMaker *make) {
make.left.right.top.mas_equalTo(self);
}];
}
#pragma mark - Getters And Setters
- (XPGiftUsersView *)userView {
if (!_userView) {
_userView = [[XPGiftUsersView alloc] initWithType:SendGiftType_Room];
}
return _userView;
}
- (XPGiftInfoView *)giftInfoView {
if (!_giftInfoView) {
_giftInfoView = [[XPGiftInfoView alloc] init];
}
return _giftInfoView;
}
- (XPGiftBarView *)giftBarView {
if (!_giftBarView) {
_giftBarView = [[XPGiftBarView alloc] init];
}
return _giftBarView;
}
- (UIStackView *)stackView {
if (!_stackView) {
_stackView = [[UIStackView alloc] init];
_stackView.axis = UILayoutConstraintAxisVertical;
_stackView.distribution = UIStackViewDistributionFill;
_stackView.alignment = UIStackViewAlignmentFill;
_stackView.spacing = 0;
_stackView.backgroundColor = [UIColor clearColor];
}
return _stackView;
}
@end

View File

@@ -9,6 +9,7 @@
#define UIColorFromRGB(rgbValue) [UIColor colorWithRed:((float)((rgbValue & 0xFF0000) >> 16))/255.0 green:((float)((rgbValue & 0xFF00) >> 8))/255.0 blue:((float)(rgbValue & 0xFF))/255.0 alpha:1.0]
#define UIColorRGBAlpha(rgbValue,a) [UIColor colorWithRed:((float)((rgbValue & 0xFF0000) >> 16))/255.0 green:((float)((rgbValue & 0xFF00) >> 8))/255.0 blue:((float)(rgbValue & 0xFF))/255.0 alpha:(a)]
NS_ASSUME_NONNULL_BEGIN
@interface ThemeColor : NSObject

View File

@@ -10,13 +10,16 @@
#import <Masonry/Masonry.h>
///Tool
#import "AccountInfoStorage.h"
#import "TTPopup.h"
///Model
#import "XPRoomMenuItem.h"
#import "MicroQueueModel.h"
#import "UserInfoModel.h"
#import "MicroStateModel.h"
#import "RoomInfoModel.h"
///View
#import "XPRoomSendTextView.h"
#import "XPSendGiftView.h"
#import "RtcManager.h"
@@ -73,6 +76,12 @@
case XPRoomMenuItemType_Voice: {
[RtcManager instance].remoteMuted = !self.voiceButton.isSelected;
self.voiceButton.selected = [RtcManager instance].isRemoteMuted;
}
break;
case XPRoomMenuItemType_Gift: {
NSString * roomUid = [NSString stringWithFormat:@"%ld", [self.delegate getRoomInfo].uid];
XPSendGiftView * giftView = [[XPSendGiftView alloc] initWithType:SendGiftType_Room uid:roomUid];
[TTPopup popupView:giftView style:TTPopupStyleActionSheet];
}
break;
@@ -214,7 +223,6 @@
[_giftButton setImage:[UIImage imageNamed:@"room_menu_gift"] forState:UIControlStateSelected];
_giftButton.tag = XPRoomMenuItemType_Gift;
[_giftButton addTarget:self action:@selector(menuButtonAction:) forControlEvents:UIControlEventTouchUpInside];
_giftButton.hidden = YES;
}
return _giftButton;
}