Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Sign in / Register
Toggle navigation
S
SuperCleaner
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lmj
SuperCleaner
Commits
8dfbba44
Commit
8dfbba44
authored
Aug 20, 2020
by
Mazy
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of gitlab.huolea.com:lmi/superclear
parents
cb99e28a
93bade83
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
303 additions
and
142 deletions
+303
-142
project.pbxproj
superCleaner.xcodeproj/project.pbxproj
+10
-0
Main.storyboard
superCleaner/Base.lproj/Main.storyboard
+17
-109
ICIAPViewController.m
superCleaner/Base/ICIAPViewController.m
+8
-2
ICHomeViewController.m
superCleaner/Home/Controller/ICHomeViewController.m
+79
-26
WKClearPhotoViewController.m
superCleaner/Home/Controller/WKClearPhotoViewController.m
+33
-0
SCHomeHeaderView.h
superCleaner/Home/View/SCHomeHeaderView.h
+23
-0
SCHomeHeaderView.m
superCleaner/Home/View/SCHomeHeaderView.m
+18
-0
SCHomeHeaderView.xib
superCleaner/Home/View/SCHomeHeaderView.xib
+101
-0
ICUserManager.m
superCleaner/Manager/ICUserManager.m
+11
-2
ICPurchaseManager.swift
superCleaner/Manager/Network/ICPurchaseManager.swift
+2
-2
ICNetworkSpeedViewController.m
superCleaner/Other/ICNetworkSpeedViewController.m
+1
-1
No files found.
superCleaner.xcodeproj/project.pbxproj
View file @
8dfbba44
...
...
@@ -159,6 +159,8 @@
A94C0E8624DA7044007F577D
/* UIImageView+Rotate.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
A94C0E0724DA7044007F577D
/* UIImageView+Rotate.m */
;
};
A94C0E8724DA7044007F577D
/* UIColor+StoryBoard.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
A94C0E0824DA7044007F577D
/* UIColor+StoryBoard.m */
;
};
A94C0E8E24DBABA9007F577D
/* ICIAPViewController.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
A94C0E8C24DBABA9007F577D
/* ICIAPViewController.m */
;
};
A94C0F6F24DC0606007F577D
/* SCHomeHeaderView.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
A94C0F6D24DC0606007F577D
/* SCHomeHeaderView.m */
;
};
A94C0F7024DC0606007F577D
/* SCHomeHeaderView.xib in Resources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
A94C0F6E24DC0606007F577D
/* SCHomeHeaderView.xib */
;
};
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
...
...
@@ -413,6 +415,9 @@
A94C0E0824DA7044007F577D
/* UIColor+StoryBoard.m */
=
{
isa
=
PBXFileReference
;
fileEncoding
=
4
;
lastKnownFileType
=
sourcecode.c.objc
;
path
=
"UIColor+StoryBoard.m"
;
sourceTree
=
"<group>"
;
};
A94C0E8C24DBABA9007F577D
/* ICIAPViewController.m */
=
{
isa
=
PBXFileReference
;
fileEncoding
=
4
;
lastKnownFileType
=
sourcecode.c.objc
;
path
=
ICIAPViewController.m
;
sourceTree
=
"<group>"
;
};
A94C0E8D24DBABA9007F577D
/* ICIAPViewController.h */
=
{
isa
=
PBXFileReference
;
fileEncoding
=
4
;
lastKnownFileType
=
sourcecode.c.h
;
path
=
ICIAPViewController.h
;
sourceTree
=
"<group>"
;
};
A94C0F6C24DC0606007F577D
/* SCHomeHeaderView.h */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.c.h
;
path
=
SCHomeHeaderView.h
;
sourceTree
=
"<group>"
;
};
A94C0F6D24DC0606007F577D
/* SCHomeHeaderView.m */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
sourcecode.c.objc
;
path
=
SCHomeHeaderView.m
;
sourceTree
=
"<group>"
;
};
A94C0F6E24DC0606007F577D
/* SCHomeHeaderView.xib */
=
{
isa
=
PBXFileReference
;
lastKnownFileType
=
file.xib
;
path
=
SCHomeHeaderView.xib
;
sourceTree
=
"<group>"
;
};
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
...
...
@@ -729,6 +734,9 @@
A94C0D9124DA7043007F577D
/* WKSimilarPhotoCell.m */
,
A94C0D9724DA7043007F577D
/* WKSimilarPhotoHeadView.h */
,
A94C0D9224DA7043007F577D
/* WKSimilarPhotoHeadView.m */
,
A94C0F6C24DC0606007F577D
/* SCHomeHeaderView.h */
,
A94C0F6D24DC0606007F577D
/* SCHomeHeaderView.m */
,
A94C0F6E24DC0606007F577D
/* SCHomeHeaderView.xib */
,
);
path
=
View
;
sourceTree
=
"<group>"
;
...
...
@@ -1043,6 +1051,7 @@
A94C0D0424DA69B3007F577D
/* pets.mp3 in Resources */
,
A94C0E2C24DA7044007F577D
/* BatteryCareLocation.plist in Resources */
,
A94C0E2F24DA7044007F577D
/* ICBatteryCareMainTextViewCell.xib in Resources */
,
A94C0F7024DC0606007F577D
/* SCHomeHeaderView.xib in Resources */
,
A94C0E7D24DA7044007F577D
/* ICContactManageViewCell.xib in Resources */
,
A94C0E2624DA7044007F577D
/* BatteryCareNotification.plist in Resources */
,
A94C0E2A24DA7044007F577D
/* BatteryCareLowPowerMode.plist in Resources */
,
...
...
@@ -1152,6 +1161,7 @@
A94C0E2224DA7044007F577D
/* ICNetworkSpeedViewController.m in Sources */
,
A94C0E4624DA7044007F577D
/* ICNormalPhotoViewController.m in Sources */
,
A94C0E2E24DA7044007F577D
/* SCNetWorkDashBoardView.swift in Sources */
,
A94C0F6F24DC0606007F577D
/* SCHomeHeaderView.m in Sources */
,
A94C0E2724DA7044007F577D
/* ICDbTestViewController.m in Sources */
,
A94C0E7324DA7044007F577D
/* ICContactListViewController.m in Sources */
,
A94C0E3424DA7044007F577D
/* ICBatteryCareMainTextViewCell.m in Sources */
,
...
...
superCleaner/Base.lproj/Main.storyboard
View file @
8dfbba44
...
...
@@ -17,62 +17,8 @@
<rect
key=
"frame"
x=
"0.0"
y=
"0.0"
width=
"375"
height=
"667"
/>
<autoresizingMask
key=
"autoresizingMask"
widthSizable=
"YES"
heightSizable=
"YES"
/>
<subviews>
<imageView
clipsSubviews=
"YES"
userInteractionEnabled=
"NO"
contentMode=
"scaleAspectFit"
horizontalHuggingPriority=
"251"
verticalHuggingPriority=
"251"
image=
"home_cycle_bg_img"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"wmu-x0-Mk9"
>
<rect
key=
"frame"
x=
"103.5"
y=
"14"
width=
"168"
height=
"168"
/>
<constraints>
<constraint
firstAttribute=
"width"
secondItem=
"wmu-x0-Mk9"
secondAttribute=
"height"
id=
"Ade-2U-sH3"
/>
</constraints>
</imageView>
<label
opaque=
"NO"
userInteractionEnabled=
"NO"
contentMode=
"left"
horizontalHuggingPriority=
"251"
verticalHuggingPriority=
"251"
text=
"52.3/64 GB"
textAlignment=
"natural"
lineBreakMode=
"tailTruncation"
baselineAdjustment=
"alignBaselines"
adjustsFontSizeToFit=
"NO"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"GIL-aJ-tee"
>
<rect
key=
"frame"
x=
"150.5"
y=
"190"
width=
"74.5"
height=
"17"
/>
<fontDescription
key=
"fontDescription"
type=
"system"
pointSize=
"14"
/>
<nil
key=
"textColor"
/>
<nil
key=
"highlightedColor"
/>
</label>
<button
opaque=
"NO"
contentMode=
"scaleToFill"
contentHorizontalAlignment=
"center"
contentVerticalAlignment=
"center"
buttonType=
"roundedRect"
lineBreakMode=
"middleTruncation"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"XKd-Oj-r0n"
>
<rect
key=
"frame"
x=
"145.5"
y=
"56"
width=
"84"
height=
"84"
/>
<color
key=
"backgroundColor"
red=
"0.14901960784313725"
green=
"0.74117647058823533"
blue=
"0.36078431372549019"
alpha=
"1"
colorSpace=
"custom"
customColorSpace=
"sRGB"
/>
<constraints>
<constraint
firstAttribute=
"width"
secondItem=
"XKd-Oj-r0n"
secondAttribute=
"height"
id=
"AEe-EP-YM5"
/>
</constraints>
<fontDescription
key=
"fontDescription"
type=
"system"
weight=
"medium"
pointSize=
"16"
/>
<state
key=
"normal"
>
<color
key=
"titleColor"
red=
"1"
green=
"1"
blue=
"1"
alpha=
"1"
colorSpace=
"custom"
customColorSpace=
"displayP3"
/>
</state>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute
type=
"color"
keyPath=
"massBackgroundColor"
>
<color
key=
"value"
white=
"0.0"
alpha=
"1"
colorSpace=
"custom"
customColorSpace=
"genericGamma22GrayColorSpace"
/>
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
<connections>
<action
selector=
"smartClearAction:"
destination=
"BYZ-38-t0r"
eventType=
"touchUpInside"
id=
"6lA-1G-Fqd"
/>
</connections>
</button>
<stackView
opaque=
"NO"
userInteractionEnabled=
"NO"
contentMode=
"scaleToFill"
axis=
"vertical"
distribution=
"fillEqually"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"Z7S-k2-nm1"
>
<rect
key=
"frame"
x=
"171"
y=
"88.5"
width=
"33.5"
height=
"19.5"
/>
<subviews>
<label
opaque=
"NO"
userInteractionEnabled=
"NO"
contentMode=
"left"
horizontalHuggingPriority=
"251"
verticalHuggingPriority=
"251"
text=
"82%"
textAlignment=
"natural"
lineBreakMode=
"tailTruncation"
baselineAdjustment=
"alignBaselines"
adjustsFontSizeToFit=
"NO"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"HQx-4u-FB6"
>
<rect
key=
"frame"
x=
"0.0"
y=
"0.0"
width=
"33.5"
height=
"19.5"
/>
<fontDescription
key=
"fontDescription"
type=
"system"
weight=
"medium"
pointSize=
"16"
/>
<color
key=
"textColor"
red=
"0.13333333333333333"
green=
"0.16078431372549018"
blue=
"0.23921568627450979"
alpha=
"1"
colorSpace=
"custom"
customColorSpace=
"sRGB"
/>
<nil
key=
"highlightedColor"
/>
</label>
</subviews>
</stackView>
<button
clipsSubviews=
"YES"
contentMode=
"scaleToFill"
contentHorizontalAlignment=
"center"
contentVerticalAlignment=
"center"
lineBreakMode=
"middleTruncation"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"1sG-bW-WsD"
>
<rect
key=
"frame"
x=
"93.5"
y=
"219"
width=
"188"
height=
"50"
/>
<state
key=
"normal"
title=
"立即清理"
backgroundImage=
"home_button_bg"
>
<color
key=
"titleColor"
red=
"0.20392156862745098"
green=
"0.20392156862745098"
blue=
"0.20392156862745098"
alpha=
"1"
colorSpace=
"calibratedRGB"
/>
</state>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute
type=
"boolean"
keyPath=
"kMassColor"
value=
"YES"
/>
</userDefinedRuntimeAttributes>
<connections>
<action
selector=
"manualClearAction:"
destination=
"BYZ-38-t0r"
eventType=
"touchUpInside"
id=
"PfZ-yQ-Chy"
/>
</connections>
</button>
<collectionView
clipsSubviews=
"YES"
multipleTouchEnabled=
"YES"
contentMode=
"scaleToFill"
dataMode=
"prototypes"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"Zue-L2-u5X"
>
<rect
key=
"frame"
x=
"
6"
y=
"281"
width=
"363"
height=
"350
"
/>
<rect
key=
"frame"
x=
"
10"
y=
"10"
width=
"355"
height=
"627
"
/>
<color
key=
"backgroundColor"
systemColor=
"systemBackgroundColor"
cocoaTouchSystemColor=
"whiteColor"
/>
<collectionViewFlowLayout
key=
"collectionViewLayout"
automaticEstimatedItemSize=
"YES"
minimumLineSpacing=
"10"
minimumInteritemSpacing=
"10"
id=
"io8-Nh-8vt"
>
<size
key=
"itemSize"
width=
"327"
height=
"92"
/>
...
...
@@ -82,7 +28,7 @@
</collectionViewFlowLayout>
<cells>
<collectionViewCell
opaque=
"NO"
clipsSubviews=
"YES"
multipleTouchEnabled=
"YES"
contentMode=
"center"
reuseIdentifier=
"SCHomeCell"
id=
"n5F-3D-esz"
customClass=
"SCHomeCell"
>
<rect
key=
"frame"
x=
"1
8
"
y=
"0.0"
width=
"327"
height=
"92"
/>
<rect
key=
"frame"
x=
"1
4
"
y=
"0.0"
width=
"327"
height=
"92"
/>
<autoresizingMask
key=
"autoresizingMask"
flexibleMaxX=
"YES"
flexibleMaxY=
"YES"
/>
<collectionViewCellContentView
key=
"contentView"
opaque=
"NO"
clipsSubviews=
"YES"
multipleTouchEnabled=
"YES"
contentMode=
"center"
insetsLayoutMarginsFromSafeArea=
"NO"
id=
"qF0-JD-PDf"
>
<rect
key=
"frame"
x=
"0.0"
y=
"0.0"
width=
"327"
height=
"92"
/>
...
...
@@ -95,64 +41,44 @@
</constraints>
</imageView>
<label
opaque=
"NO"
userInteractionEnabled=
"NO"
contentMode=
"left"
horizontalHuggingPriority=
"251"
verticalHuggingPriority=
"251"
text=
"Label"
textAlignment=
"natural"
lineBreakMode=
"tailTruncation"
baselineAdjustment=
"alignBaselines"
adjustsFontSizeToFit=
"NO"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"FUe-po-yXc"
>
<rect
key=
"frame"
x=
"78.5"
y=
"27"
width=
"3
5.5
"
height=
"17"
/>
<fontDescription
key=
"fontDescription"
type=
"system"
pointSize=
"14"
/>
<color
key=
"textColor"
red=
"0.20
392156862745098"
green=
"0.20392156862745098"
blue=
"0.20392156862745098
"
alpha=
"0.84705882352941175"
colorSpace=
"calibratedRGB"
/>
<rect
key=
"frame"
x=
"78.5"
y=
"27"
width=
"3
6
"
height=
"17"
/>
<fontDescription
key=
"fontDescription"
type=
"system"
weight=
"medium"
pointSize=
"14"
/>
<color
key=
"textColor"
red=
"0.20
000000000000001"
green=
"0.20000000000000001"
blue=
"0.20000000000000001
"
alpha=
"0.84705882352941175"
colorSpace=
"calibratedRGB"
/>
<nil
key=
"highlightedColor"
/>
</label>
<label
opaque=
"NO"
userInteractionEnabled=
"NO"
contentMode=
"left"
horizontalHuggingPriority=
"251"
verticalHuggingPriority=
"251"
text=
"Label"
textAlignment=
"natural"
lineBreakMode=
"tailTruncation"
baselineAdjustment=
"alignBaselines"
adjustsFontSizeToFit=
"NO"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"Qr2-CO-OPH"
>
<rect
key=
"frame"
x=
"78.5"
y=
"52"
width=
"2
8.
5"
height=
"13.5"
/>
<label
opaque=
"NO"
userInteractionEnabled=
"NO"
contentMode=
"left"
horizontalHuggingPriority=
"251"
verticalHuggingPriority=
"251"
text=
"Label"
textAlignment=
"natural"
lineBreakMode=
"tailTruncation"
numberOfLines=
"0"
baselineAdjustment=
"alignBaselines"
adjustsFontSizeToFit=
"NO"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"Qr2-CO-OPH"
>
<rect
key=
"frame"
x=
"78.5"
y=
"52"
width=
"2
4
5"
height=
"13.5"
/>
<fontDescription
key=
"fontDescription"
type=
"system"
pointSize=
"11"
/>
<color
key=
"textColor"
red=
"0.
60784313725490191"
green=
"0.70196078431372544"
blue=
"0.82352941176470584"
alpha=
"0.84705882352941175
"
colorSpace=
"calibratedRGB"
/>
<color
key=
"textColor"
red=
"0.
59999999999999998"
green=
"0.59999999999999998"
blue=
"0.59999999999999998"
alpha=
"0.84999999999999998
"
colorSpace=
"calibratedRGB"
/>
<nil
key=
"highlightedColor"
/>
</label>
<view
hidden=
"YES"
contentMode=
"scaleToFill"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"YJh-Qm-QMN"
>
<rect
key=
"frame"
x=
"0.0"
y=
"0.0"
width=
"327"
height=
"0.5"
/>
<color
key=
"backgroundColor"
red=
"0.
71372549019607845"
green=
"0.83921568627450982
"
blue=
"1"
alpha=
"1"
colorSpace=
"calibratedRGB"
/>
<color
key=
"backgroundColor"
red=
"0.
8901960784313725"
green=
"0.93725490196078431
"
blue=
"1"
alpha=
"1"
colorSpace=
"calibratedRGB"
/>
<constraints>
<constraint
firstAttribute=
"height"
constant=
"0.5"
id=
"4F4-Qx-peC"
/>
</constraints>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute
type=
"color"
keyPath=
"massBackgroundColor"
>
<color
key=
"value"
white=
"0.0"
alpha=
"1"
colorSpace=
"custom"
customColorSpace=
"genericGamma22GrayColorSpace"
/>
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
</view>
<view
hidden=
"YES"
contentMode=
"scaleToFill"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"gXT-DX-0tB"
>
<rect
key=
"frame"
x=
"0.0"
y=
"91.5"
width=
"327"
height=
"0.5"
/>
<color
key=
"backgroundColor"
red=
"0.
71372549019607845"
green=
"0.83921568627450982
"
blue=
"1"
alpha=
"1"
colorSpace=
"calibratedRGB"
/>
<color
key=
"backgroundColor"
red=
"0.
8901960784313725"
green=
"0.93725490196078431
"
blue=
"1"
alpha=
"1"
colorSpace=
"calibratedRGB"
/>
<constraints>
<constraint
firstAttribute=
"height"
constant=
"0.5"
id=
"eYN-wY-6mm"
/>
</constraints>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute
type=
"color"
keyPath=
"massBackgroundColor"
>
<color
key=
"value"
white=
"0.0"
alpha=
"1"
colorSpace=
"custom"
customColorSpace=
"genericGamma22GrayColorSpace"
/>
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
</view>
<view
hidden=
"YES"
contentMode=
"scaleToFill"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"ueJ-Hi-iHu"
>
<rect
key=
"frame"
x=
"0.0"
y=
"0.0"
width=
"0.5"
height=
"92"
/>
<color
key=
"backgroundColor"
red=
"0.
71372549019607845"
green=
"0.83921568627450982
"
blue=
"1"
alpha=
"1"
colorSpace=
"calibratedRGB"
/>
<color
key=
"backgroundColor"
red=
"0.
8901960784313725"
green=
"0.93725490196078431
"
blue=
"1"
alpha=
"1"
colorSpace=
"calibratedRGB"
/>
<constraints>
<constraint
firstAttribute=
"width"
constant=
"0.5"
id=
"2HY-KF-4Uk"
/>
</constraints>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute
type=
"color"
keyPath=
"massBackgroundColor"
>
<color
key=
"value"
white=
"0.0"
alpha=
"1"
colorSpace=
"custom"
customColorSpace=
"genericGamma22GrayColorSpace"
/>
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
</view>
<view
hidden=
"YES"
contentMode=
"scaleToFill"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"cNF-xd-ZI3"
>
<rect
key=
"frame"
x=
"326.5"
y=
"0.0"
width=
"0.5"
height=
"92"
/>
<color
key=
"backgroundColor"
red=
"0.
71372549019607845"
green=
"0.83921568627450982
"
blue=
"1"
alpha=
"1"
colorSpace=
"calibratedRGB"
/>
<color
key=
"backgroundColor"
red=
"0.
8901960784313725"
green=
"0.93725490196078431
"
blue=
"1"
alpha=
"1"
colorSpace=
"calibratedRGB"
/>
<constraints>
<constraint
firstAttribute=
"width"
constant=
"0.5"
id=
"dMT-k5-LvS"
/>
</constraints>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute
type=
"color"
keyPath=
"massBackgroundColor"
>
<color
key=
"value"
white=
"0.0"
alpha=
"1"
colorSpace=
"custom"
customColorSpace=
"genericGamma22GrayColorSpace"
/>
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
</view>
</subviews>
<constraints>
...
...
@@ -163,6 +89,7 @@
<constraint
firstItem=
"q6x-Wi-XlX"
firstAttribute=
"centerY"
secondItem=
"qF0-JD-PDf"
secondAttribute=
"centerY"
id=
"Bfh-9b-clB"
/>
<constraint
firstAttribute=
"bottom"
secondItem=
"cNF-xd-ZI3"
secondAttribute=
"bottom"
id=
"GBq-tj-zlW"
/>
<constraint
firstAttribute=
"bottom"
secondItem=
"gXT-DX-0tB"
secondAttribute=
"bottom"
id=
"Ghl-BA-NS0"
/>
<constraint
firstItem=
"cNF-xd-ZI3"
firstAttribute=
"leading"
secondItem=
"Qr2-CO-OPH"
secondAttribute=
"trailing"
constant=
"3"
id=
"Hc6-bk-mo3"
/>
<constraint
firstItem=
"Qr2-CO-OPH"
firstAttribute=
"top"
secondItem=
"FUe-po-yXc"
secondAttribute=
"bottom"
constant=
"8"
id=
"Jcq-qe-SD3"
/>
<constraint
firstAttribute=
"trailing"
secondItem=
"cNF-xd-ZI3"
secondAttribute=
"trailing"
id=
"Pyf-Ko-c7B"
/>
<constraint
firstItem=
"Qr2-CO-OPH"
firstAttribute=
"leading"
secondItem=
"FUe-po-yXc"
secondAttribute=
"leading"
id=
"QYI-r0-Jks"
/>
...
...
@@ -194,32 +121,15 @@
</subviews>
<color
key=
"backgroundColor"
systemColor=
"systemBackgroundColor"
cocoaTouchSystemColor=
"whiteColor"
/>
<constraints>
<constraint
firstItem=
"1sG-bW-WsD"
firstAttribute=
"top"
secondItem=
"GIL-aJ-tee"
secondAttribute=
"bottom"
constant=
"12"
id=
"15E-bu-HkO"
/>
<constraint
firstItem=
"wmu-x0-Mk9"
firstAttribute=
"top"
secondItem=
"6Tk-OE-BBY"
secondAttribute=
"top"
constant=
"14"
id=
"Cwl-JC-xeO"
/>
<constraint
firstItem=
"Zue-L2-u5X"
firstAttribute=
"leading"
secondItem=
"6Tk-OE-BBY"
secondAttribute=
"leading"
constant=
"6"
id=
"FUw-Dc-y7h"
/>
<constraint
firstItem=
"6Tk-OE-BBY"
firstAttribute=
"trailing"
secondItem=
"Zue-L2-u5X"
secondAttribute=
"trailing"
constant=
"6"
id=
"IKP-Tz-m87"
/>
<constraint
firstItem=
"wmu-x0-Mk9"
firstAttribute=
"centerY"
secondItem=
"XKd-Oj-r0n"
secondAttribute=
"centerY"
id=
"ISX-fB-zjC"
/>
<constraint
firstItem=
"1sG-bW-WsD"
firstAttribute=
"centerX"
secondItem=
"GIL-aJ-tee"
secondAttribute=
"centerX"
id=
"Ko8-p2-PkU"
/>
<constraint
firstItem=
"Z7S-k2-nm1"
firstAttribute=
"centerX"
secondItem=
"XKd-Oj-r0n"
secondAttribute=
"centerX"
id=
"KrE-vQ-NZc"
/>
<constraint
firstItem=
"wmu-x0-Mk9"
firstAttribute=
"centerX"
secondItem=
"8bC-Xf-vdC"
secondAttribute=
"centerX"
id=
"MxY-Ax-f30"
/>
<constraint
firstItem=
"wmu-x0-Mk9"
firstAttribute=
"width"
secondItem=
"8bC-Xf-vdC"
secondAttribute=
"width"
multiplier=
"168:375"
id=
"N7y-RJ-yio"
/>
<constraint
firstItem=
"GIL-aJ-tee"
firstAttribute=
"top"
secondItem=
"wmu-x0-Mk9"
secondAttribute=
"bottom"
constant=
"8"
id=
"X1o-ek-Au6"
/>
<constraint
firstItem=
"wmu-x0-Mk9"
firstAttribute=
"centerX"
secondItem=
"XKd-Oj-r0n"
secondAttribute=
"centerX"
id=
"jeJ-kW-Q4s"
/>
<constraint
firstItem=
"Zue-L2-u5X"
firstAttribute=
"top"
secondItem=
"1sG-bW-WsD"
secondAttribute=
"bottom"
constant=
"12"
id=
"kX6-w6-7tx"
/>
<constraint
firstItem=
"6Tk-OE-BBY"
firstAttribute=
"bottom"
secondItem=
"Zue-L2-u5X"
secondAttribute=
"bottom"
constant=
"36"
id=
"riZ-Pq-fVh"
/>
<constraint
firstItem=
"XKd-Oj-r0n"
firstAttribute=
"width"
secondItem=
"wmu-x0-Mk9"
secondAttribute=
"width"
multiplier=
"1:2"
id=
"xJp-bR-jUI"
/>
<constraint
firstItem=
"Z7S-k2-nm1"
firstAttribute=
"centerY"
secondItem=
"XKd-Oj-r0n"
secondAttribute=
"centerY"
id=
"xQl-z4-W0d"
/>
<constraint
firstItem=
"GIL-aJ-tee"
firstAttribute=
"centerX"
secondItem=
"wmu-x0-Mk9"
secondAttribute=
"centerX"
id=
"zxi-uS-0QC"
/>
<constraint
firstItem=
"Zue-L2-u5X"
firstAttribute=
"leading"
secondItem=
"6Tk-OE-BBY"
secondAttribute=
"leading"
constant=
"10"
id=
"FUw-Dc-y7h"
/>
<constraint
firstItem=
"6Tk-OE-BBY"
firstAttribute=
"trailing"
secondItem=
"Zue-L2-u5X"
secondAttribute=
"trailing"
constant=
"10"
id=
"IKP-Tz-m87"
/>
<constraint
firstItem=
"Zue-L2-u5X"
firstAttribute=
"top"
secondItem=
"6Tk-OE-BBY"
secondAttribute=
"top"
constant=
"10"
id=
"WCE-es-jxA"
/>
<constraint
firstItem=
"6Tk-OE-BBY"
firstAttribute=
"bottom"
secondItem=
"Zue-L2-u5X"
secondAttribute=
"bottom"
constant=
"30"
id=
"riZ-Pq-fVh"
/>
</constraints>
<viewLayoutGuide
key=
"safeArea"
id=
"6Tk-OE-BBY"
/>
</view>
<connections>
<outlet
property=
"collectionView"
destination=
"Zue-L2-u5X"
id=
"ZTE-H5-bkB"
/>
<outlet
property=
"cycleImageView"
destination=
"wmu-x0-Mk9"
id=
"Urr-Ar-eVo"
/>
<outlet
property=
"manualButton"
destination=
"1sG-bW-WsD"
id=
"ibd-c8-udH"
/>
<outlet
property=
"smartClearButton"
destination=
"XKd-Oj-r0n"
id=
"z7V-R1-dNA"
/>
<outlet
property=
"spacePercentLabel"
destination=
"GIL-aJ-tee"
id=
"8Bn-fb-iSA"
/>
<outlet
property=
"usedSpaceScaleLabel"
destination=
"HQx-4u-FB6"
id=
"FcO-D7-eKn"
/>
</connections>
</viewController>
<placeholder
placeholderIdentifier=
"IBFirstResponder"
id=
"dkx-z0-nzr"
sceneMemberID=
"firstResponder"
/>
...
...
@@ -1878,8 +1788,6 @@
<image
name=
"contact_choose"
width=
"22"
height=
"22"
/>
<image
name=
"contact_choosed"
width=
"22"
height=
"22"
/>
<image
name=
"global_green_btn_bg"
width=
"324"
height=
"62"
/>
<image
name=
"home_button_bg"
width=
"188"
height=
"50"
/>
<image
name=
"home_cycle_bg_img"
width=
"168"
height=
"168"
/>
<image
name=
"home_pause_btn_bg"
width=
"26"
height=
"26"
/>
<image
name=
"inAppPurchase_cancel"
width=
"20"
height=
"20"
/>
<image
name=
"inAppPurchase_discount_icon"
width=
"74"
height=
"18"
/>
...
...
superCleaner/Base/ICIAPViewController.m
View file @
8dfbba44
...
...
@@ -10,6 +10,7 @@
#import "superCleaner-Swift.h"
#import "ICWebViewController.h"
#import "ICIPAProductModel.h"
#import "Data.h"
@interface
ICIAPViewController
()
...
...
@@ -48,6 +49,13 @@
UITapGestureRecognizer
*
yearTap
=
[[
UITapGestureRecognizer
alloc
]
initWithTarget
:
self
action
:
@selector
(
selectedYearAction
)];
[
self
.
yearContentView
addGestureRecognizer
:
yearTap
];
self
.
weakPriceLabel
.
text
=
@"3天免费试用,之后"
;
Data
*
data
=
[[
Data
alloc
]
init
];
NSDictionary
*
dic
=
[[
data
Read
]
objectForKey
:
@"config"
];
if
(
dic
)
{
self
.
weakPriceLabel
.
text
=
[
dic
objectForKey
:
@"pay_3day_txt"
];
}
self
.
products
=
[
NSMutableArray
array
];
[
self
getIpaList
];
...
...
@@ -69,10 +77,8 @@
[
weakSelf
.
products
addObject
:
model
];
if
([
model
.
productId
containsString
:
@"week"
])
{
weakSelf
.
weakPeriodOfUseLabel
.
text
=
model
.
name
;
weakSelf
.
weakPriceLabel
.
text
=
model
.
payDesc
;
}
else
if
([
model
.
productId
containsString
:
@"year"
])
{
weakSelf
.
yearPeriodOfUseLabel
.
text
=
model
.
name
;
weakSelf
.
yearPriceLabel
.
text
=
[
NSString
stringWithFormat
:
@"%@ (%@)"
,
model
.
payDesc
,
model
.
greyBgStr
];
}
}
}
...
...
superCleaner/Home/Controller/ICHomeViewController.m
View file @
8dfbba44
...
...
@@ -23,15 +23,18 @@
#import "ICPhotoManageViewController.h"
#import "ICContactsViewController.h"
#import "ICCalendarManageController.h"
#import "SCHomeHeaderView.h"
@interface
ICHomeViewController
()
<
UICollectionViewDelegate
,
UICollectionViewDataSource
>
@property
(
weak
,
nonatomic
)
IBOutlet
UILabel
*
usedSpaceScaleLabel
;
@property
(
weak
,
nonatomic
)
IBOutlet
UILabel
*
spacePercentLabel
;
@property
(
weak
,
nonatomic
)
IBOutlet
UIButton
*
smartClearButton
;
@property
(
weak
,
nonatomic
)
IBOutlet
UIImageView
*
cycleImageView
;
@property
(
weak
,
nonatomic
)
IBOutlet
UIButton
*
manualButton
;
//@property (weak, nonatomic) IBOutlet UILabel *usedSpaceScaleLabel;
//@property (weak, nonatomic) IBOutlet UILabel *spacePercentLabel;
//@property (weak, nonatomic) IBOutlet UIButton *smartClearButton;
//@property (weak, nonatomic) IBOutlet UIImageView *cycleImageView;
//@property (weak, nonatomic) IBOutlet UIButton *manualButton;
@property
(
weak
,
nonatomic
)
IBOutlet
UICollectionView
*
collectionView
;
@property
(
strong
,
nonatomic
)
SCHomeHeaderView
*
headerView
;
@property
(
strong
,
nonatomic
)
NSArray
*
dataSource
;
@end
...
...
@@ -51,8 +54,8 @@
@{
@"image"
:
@""
,
@"title"
:
@""
,
@"details"
:
@""
}];
[
self
setupUI
];
[
self
getDivceSize
];
[
self
rotateAction
];
//
[self getDivceSize];
//
[self rotateAction];
[[
ICUserManager
shared
]
loginAndGetUserInfo
:
^
(
ZTUserInfoModel
*
_Nonnull
model
)
{
[[
ICUserManager
shared
]
getServiceInfo
];
...
...
@@ -75,7 +78,7 @@
-
(
void
)
viewDidAppear
:
(
BOOL
)
animated
{
[
super
viewDidAppear
:
animated
];
[
self
.
smartClearButton
addRadarAnimation
];
// [self.headerView
.smartClearButton addRadarAnimation];
}
-
(
void
)
viewWillAppear
:
(
BOOL
)
animated
{
...
...
@@ -85,7 +88,7 @@
-
(
void
)
viewWillDisappear
:
(
BOOL
)
animated
{
[
super
viewWillDisappear
:
animated
];
[
self
.
smartClearButton
removeRadarAnimation
];
[
self
.
headerView
.
smartClearButton
removeRadarAnimation
];
}
-
(
void
)
setupUI
{
...
...
@@ -106,25 +109,23 @@
[
self
.
view
layoutIfNeeded
];
[
self
.
view
layoutSubviews
];
self
.
smartClearButton
.
layer
.
cornerRadius
=
self
.
smartClearButton
.
frame
.
size
.
height
/
2
;
self
.
smartClearButton
.
radarColor
=
kMassColor
;
self
.
smartClearButton
.
radarBorderColor
=
kMassColor
;
UICollectionViewFlowLayout
*
layout
=
[[
UICollectionViewFlowLayout
alloc
]
init
];
layout
.
itemSize
=
CGSizeMake
((
KScreenWidth
-
12
)
/
2
,
KScaleWidth
(
78
));
layout
.
itemSize
=
CGSizeMake
((
KScreenWidth
-
20
)
/
2
,
KScaleWidth
(
78
));
layout
.
minimumLineSpacing
=
0
;
layout
.
minimumInteritemSpacing
=
0
;
layout
.
sectionInset
=
UIEdgeInsetsMake
(
0
,
0
,
0
,
0
);
_collectionView
.
collectionViewLayout
=
layout
;
_collectionView
.
delegate
=
self
;
_collectionView
.
dataSource
=
self
;
_collectionView
.
showsVerticalScrollIndicator
=
NO
;
// [_collectionView registerNib:[UINib nibWithNibName:@"ZJChooseIconCell" bundle:nil] forCellWithReuseIdentifier:@"cell"];
[
_collectionView
registerNib
:[
UINib
nibWithNibName
:
@"SCHomeHeaderView"
bundle
:
nil
]
forSupplementaryViewOfKind
:
UICollectionElementKindSectionHeader
withReuseIdentifier
:
@"SCHomeHeaderView"
];
}
//设置一个函数 便于嵌套使用
-
(
void
)
rotateAction
{
[
UIView
animateWithDuration
:
2
delay
:
0
options
:
UIViewAnimationOptionCurveLinear
animations
:^
{
self
.
cycleImageView
.
transform
=
CGAffineTransformRotate
(
self
.
cycleImageView
.
transform
,
M_PI
);
self
.
headerView
.
cycleImageView
.
transform
=
CGAffineTransformRotate
(
self
.
headerView
.
cycleImageView
.
transform
,
M_PI
);
}
completion
:^
(
BOOL
finished
)
{
[
self
rotateAction
];
}];
...
...
@@ -152,9 +153,8 @@
NSLog
(
@"%.1f/%.0f"
,
usedMem
,
totalMem
);
NSLog
(
@"%.2f"
,
usedMem
/
totalMem
);
self
.
usedSpaceScaleLabel
.
text
=
[
NSString
stringWithFormat
:
@"%@ %.0f%%"
,
ICLocalized
(
@"Used"
),
[[
ICDiskKit
takenSpace
]
floatValue
]
/
totalMem
*
100
];
self
.
spacePercentLabel
.
text
=
[
NSString
stringWithFormat
:
@"%@/%.0fGB"
,
[
ICDiskKit
takenSpace
],
totalMem
];
self
.
headerView
.
usedSpaceScaleLabel
.
text
=
[
NSString
stringWithFormat
:
@"%@ %.0f%%"
,
ICLocalized
(
@"Used"
),
[[
ICDiskKit
takenSpace
]
floatValue
]
/
totalMem
*
100
];
self
.
headerView
.
spacePercentLabel
.
text
=
[
NSString
stringWithFormat
:
@"%@/%.0fGB"
,
[
ICDiskKit
takenSpace
],
totalMem
];
}
// 智能清理
...
...
@@ -260,6 +260,35 @@
return
cell
;
}
-
(
UICollectionReusableView
*
)
collectionView
:
(
UICollectionView
*
)
collectionView
viewForSupplementaryElementOfKind
:
(
NSString
*
)
kind
atIndexPath
:
(
NSIndexPath
*
)
indexPath
{
if
(
kind
==
UICollectionElementKindSectionHeader
)
{
SCHomeHeaderView
*
header
=
[
collectionView
dequeueReusableSupplementaryViewOfKind
:
kind
withReuseIdentifier
:
@"SCHomeHeaderView"
forIndexPath
:
indexPath
];
header
.
backgroundColor
=
[
UIColor
whiteColor
];
self
.
headerView
=
header
;
self
.
headerView
.
frame
=
CGRectMake
(
0
,
0
,
KScreenWidth
-
20
,
151
+
KScaleWidth
(
168
));
[
self
.
headerView
layoutIfNeeded
];
[
self
.
headerView
layoutSubviews
];
self
.
headerView
.
smartClearButton
.
layer
.
cornerRadius
=
self
.
headerView
.
smartClearButton
.
frame
.
size
.
height
/
2
;
self
.
headerView
.
smartClearButton
.
radarColor
=
kMassColor
;
self
.
headerView
.
smartClearButton
.
radarBorderColor
=
kMassColor
;
[
self
.
headerView
.
smartClearButton
addRadarAnimation
];
[
self
rotateAction
];
[
self
getDivceSize
];
[
self
.
headerView
.
smartClearButton
addTarget
:
self
action
:
@selector
(
smartClearAction
:
)
forControlEvents
:
(
UIControlEventTouchUpInside
)];
[
self
.
headerView
.
manualButton
addTarget
:
self
action
:
@selector
(
smartClearAction
:
)
forControlEvents
:
(
UIControlEventTouchUpInside
)];
return
self
.
headerView
;
}
return
nil
;
}
-
(
CGSize
)
collectionView
:
(
UICollectionView
*
)
collectionView
layout
:
(
UICollectionViewLayout
*
)
collectionViewLayout
referenceSizeForHeaderInSection
:
(
NSInteger
)
section
{
return
CGSizeMake
(
KScreenWidth
-
20
,
151
+
KScaleWidth
(
168
));
}
-
(
void
)
collectionView
:
(
UICollectionView
*
)
collectionView
didSelectItemAtIndexPath
:
(
NSIndexPath
*
)
indexPath
{
[
collectionView
deselectItemAtIndexPath
:
indexPath
animated
:
YES
];
...
...
@@ -306,26 +335,50 @@
break
;
case
3
:
{
ICCleanDustViewController
*
vc
=
[[
UIStoryboard
storyboardWithName
:
@"Main"
bundle
:
nil
]
instantiateViewControllerWithIdentifier
:
@"ICCleanDustViewController"
];
[
self
.
navigationController
pushViewController
:
vc
animated
:
true
];
if
([
ICUserManager
shared
].
isMember
)
{
ICCleanDustViewController
*
vc
=
[[
UIStoryboard
storyboardWithName
:
@"Main"
bundle
:
nil
]
instantiateViewControllerWithIdentifier
:
@"ICCleanDustViewController"
];
[
self
.
navigationController
pushViewController
:
vc
animated
:
true
];
}
else
{
ICIAPViewController
*
iapVC
=
[[
UIStoryboard
storyboardWithName
:
@"Main"
bundle
:
nil
]
instantiateViewControllerWithIdentifier
:
@"ICIAPViewController"
];
ICNavigationController
*
navc
=
[[
ICNavigationController
alloc
]
initWithRootViewController
:
iapVC
];
[
self
presentViewController
:
navc
animated
:
true
completion
:
nil
];
}
}
break
;
case
4
:
{
ICNetworkSpeedViewController
*
vc
=
[[
UIStoryboard
storyboardWithName
:
@"Main"
bundle
:
nil
]
instantiateViewControllerWithIdentifier
:
@"ICNetworkSpeedViewController"
];
[
self
.
navigationController
pushViewController
:
vc
animated
:
true
];
if
([
ICUserManager
shared
].
isMember
)
{
ICNetworkSpeedViewController
*
vc
=
[[
UIStoryboard
storyboardWithName
:
@"Main"
bundle
:
nil
]
instantiateViewControllerWithIdentifier
:
@"ICNetworkSpeedViewController"
];
[
self
.
navigationController
pushViewController
:
vc
animated
:
true
];
}
else
{
ICIAPViewController
*
iapVC
=
[[
UIStoryboard
storyboardWithName
:
@"Main"
bundle
:
nil
]
instantiateViewControllerWithIdentifier
:
@"ICIAPViewController"
];
ICNavigationController
*
navc
=
[[
ICNavigationController
alloc
]
initWithRootViewController
:
iapVC
];
[
self
presentViewController
:
navc
animated
:
true
completion
:
nil
];
}
}
break
;
case
5
:
{
ICDbTestViewController
*
vc
=
[[
UIStoryboard
storyboardWithName
:
@"Main"
bundle
:
nil
]
instantiateViewControllerWithIdentifier
:
@"ICDbTestViewController"
];
[
self
.
navigationController
pushViewController
:
vc
animated
:
true
];
if
([
ICUserManager
shared
].
isMember
)
{
ICDbTestViewController
*
vc
=
[[
UIStoryboard
storyboardWithName
:
@"Main"
bundle
:
nil
]
instantiateViewControllerWithIdentifier
:
@"ICDbTestViewController"
];
[
self
.
navigationController
pushViewController
:
vc
animated
:
true
];
}
else
{
ICIAPViewController
*
iapVC
=
[[
UIStoryboard
storyboardWithName
:
@"Main"
bundle
:
nil
]
instantiateViewControllerWithIdentifier
:
@"ICIAPViewController"
];
ICNavigationController
*
navc
=
[[
ICNavigationController
alloc
]
initWithRootViewController
:
iapVC
];
[
self
presentViewController
:
navc
animated
:
true
completion
:
nil
];
}
}
break
;
case
6
:
{
ICBatteryCareViewController
*
vc
=
[[
ICBatteryCareViewController
alloc
]
init
];
[
self
.
navigationController
pushViewController
:
vc
animated
:
true
];
if
([
ICUserManager
shared
].
isMember
)
{
ICBatteryCareViewController
*
vc
=
[[
ICBatteryCareViewController
alloc
]
init
];
[
self
.
navigationController
pushViewController
:
vc
animated
:
true
];
}
else
{
ICIAPViewController
*
iapVC
=
[[
UIStoryboard
storyboardWithName
:
@"Main"
bundle
:
nil
]
instantiateViewControllerWithIdentifier
:
@"ICIAPViewController"
];
ICNavigationController
*
navc
=
[[
ICNavigationController
alloc
]
initWithRootViewController
:
iapVC
];
[
self
presentViewController
:
navc
animated
:
true
completion
:
nil
];
}
}
break
;
default
:
...
...
superCleaner/Home/Controller/WKClearPhotoViewController.m
View file @
8dfbba44
...
...
@@ -103,6 +103,39 @@
_similarPhotoContentView
.
backgroundColor
=
kMassColorAlpha
(
0
.
15
);
_similarVideoContentView
.
backgroundColor
=
kMassColorAlpha
(
0
.
15
);
_screenshotContentView
.
tag
=
0x8c
+
1
;
_livePhotoContentView
.
tag
=
0x8c
+
3
;
_similarPhotoContentView
.
tag
=
0x8c
;
_similarVideoContentView
.
tag
=
0x8c
+
2
;
UITapGestureRecognizer
*
tap
=
[[
UITapGestureRecognizer
alloc
]
initWithTarget
:
self
action
:
@selector
(
viewTapGes
:
)];
UITapGestureRecognizer
*
tap1
=
[[
UITapGestureRecognizer
alloc
]
initWithTarget
:
self
action
:
@selector
(
viewTapGes
:
)];
UITapGestureRecognizer
*
tap2
=
[[
UITapGestureRecognizer
alloc
]
initWithTarget
:
self
action
:
@selector
(
viewTapGes
:
)];
UITapGestureRecognizer
*
tap3
=
[[
UITapGestureRecognizer
alloc
]
initWithTarget
:
self
action
:
@selector
(
viewTapGes
:
)];
[
_screenshotContentView
addGestureRecognizer
:
tap
];
[
_livePhotoContentView
addGestureRecognizer
:
tap1
];
[
_similarPhotoContentView
addGestureRecognizer
:
tap2
];
[
_similarVideoContentView
addGestureRecognizer
:
tap3
];
}
-
(
void
)
viewTapGes
:
(
UITapGestureRecognizer
*
)
ges
{
switch
(
ges
.
view
.
tag
-
0x8c
)
{
case
0
:
[
self
similarPhotoDetailAction
];
break
;
case
1
:
[
self
screenshotDetailAction
];
break
;
case
2
:
break
;
case
3
:
[
self
livePhotoDetailAction
];
break
;
default
:
break
;
}
}
-
(
void
)
updateUI
{
...
...
superCleaner/Home/View/SCHomeHeaderView.h
0 → 100644
View file @
8dfbba44
//
// SCHomeHeaderView.h
// superCleaner
//
// Created by 明津李 on 2020/8/6.
// Copyright © 2020 Mazy. All rights reserved.
//
#import <UIKit/UIKit.h>
NS_ASSUME_NONNULL_BEGIN
@interface
SCHomeHeaderView
:
UICollectionReusableView
@property
(
weak
,
nonatomic
)
IBOutlet
UILabel
*
usedSpaceScaleLabel
;
@property
(
weak
,
nonatomic
)
IBOutlet
UILabel
*
spacePercentLabel
;
@property
(
weak
,
nonatomic
)
IBOutlet
UIButton
*
smartClearButton
;
@property
(
weak
,
nonatomic
)
IBOutlet
UIImageView
*
cycleImageView
;
@property
(
weak
,
nonatomic
)
IBOutlet
UIButton
*
manualButton
;
@end
NS_ASSUME_NONNULL_END
superCleaner/Home/View/SCHomeHeaderView.m
0 → 100644
View file @
8dfbba44
//
// SCHomeHeaderView.m
// superCleaner
//
// Created by 明津李 on 2020/8/6.
// Copyright © 2020 Mazy. All rights reserved.
//
#import "SCHomeHeaderView.h"
@implementation
SCHomeHeaderView
-
(
void
)
awakeFromNib
{
[
super
awakeFromNib
];
// Initialization code
}
@end
superCleaner/Home/View/SCHomeHeaderView.xib
0 → 100644
View file @
8dfbba44
<?xml version="1.0" encoding="UTF-8"?>
<document
type=
"com.apple.InterfaceBuilder3.CocoaTouch.XIB"
version=
"3.0"
toolsVersion=
"16097.2"
targetRuntime=
"iOS.CocoaTouch"
propertyAccessControl=
"none"
useAutolayout=
"YES"
useTraitCollections=
"YES"
useSafeAreas=
"YES"
colorMatched=
"YES"
>
<device
id=
"retina6_1"
orientation=
"portrait"
appearance=
"light"
/>
<dependencies>
<deployment
identifier=
"iOS"
/>
<plugIn
identifier=
"com.apple.InterfaceBuilder.IBCocoaTouchPlugin"
version=
"16087"
/>
<capability
name=
"Safe area layout guides"
minToolsVersion=
"9.0"
/>
<capability
name=
"documents saved in the Xcode 8 format"
minToolsVersion=
"8.0"
/>
</dependencies>
<objects>
<placeholder
placeholderIdentifier=
"IBFilesOwner"
id=
"-1"
userLabel=
"File's Owner"
/>
<placeholder
placeholderIdentifier=
"IBFirstResponder"
id=
"-2"
customClass=
"UIResponder"
/>
<collectionReusableView
opaque=
"NO"
clipsSubviews=
"YES"
multipleTouchEnabled=
"YES"
contentMode=
"center"
reuseIdentifier=
"SCHomeHeaderView"
id=
"U6b-Vx-4bR"
customClass=
"SCHomeHeaderView"
>
<rect
key=
"frame"
x=
"0.0"
y=
"0.0"
width=
"415"
height=
"350"
/>
<autoresizingMask
key=
"autoresizingMask"
/>
<subviews>
<imageView
clipsSubviews=
"YES"
userInteractionEnabled=
"NO"
contentMode=
"scaleAspectFit"
horizontalHuggingPriority=
"251"
verticalHuggingPriority=
"251"
image=
"home_cycle_bg_img"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"Zv4-WU-omb"
>
<rect
key=
"frame"
x=
"109.5"
y=
"25"
width=
"196"
height=
"196.5"
/>
<constraints>
<constraint
firstAttribute=
"width"
secondItem=
"Zv4-WU-omb"
secondAttribute=
"height"
id=
"8bM-lL-T2A"
/>
</constraints>
</imageView>
<label
opaque=
"NO"
userInteractionEnabled=
"NO"
contentMode=
"left"
horizontalHuggingPriority=
"251"
verticalHuggingPriority=
"251"
text=
"52.3/64 GB"
textAlignment=
"natural"
lineBreakMode=
"tailTruncation"
baselineAdjustment=
"alignBaselines"
adjustsFontSizeToFit=
"NO"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"zHw-24-34Q"
>
<rect
key=
"frame"
x=
"170.5"
y=
"241.5"
width=
"74.5"
height=
"17"
/>
<fontDescription
key=
"fontDescription"
type=
"system"
pointSize=
"14"
/>
<nil
key=
"textColor"
/>
<nil
key=
"highlightedColor"
/>
</label>
<button
clipsSubviews=
"YES"
contentMode=
"scaleToFill"
contentHorizontalAlignment=
"center"
contentVerticalAlignment=
"center"
lineBreakMode=
"middleTruncation"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"kdu-zn-cpc"
>
<rect
key=
"frame"
x=
"113.5"
y=
"272.5"
width=
"188"
height=
"50"
/>
<state
key=
"normal"
title=
"立即清理"
backgroundImage=
"home_button_bg"
>
<color
key=
"titleColor"
red=
"0.20392156859999999"
green=
"0.20392156859999999"
blue=
"0.20392156859999999"
alpha=
"1"
colorSpace=
"calibratedRGB"
/>
</state>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute
type=
"boolean"
keyPath=
"kMassColor"
value=
"YES"
/>
</userDefinedRuntimeAttributes>
</button>
<button
opaque=
"NO"
contentMode=
"scaleToFill"
contentHorizontalAlignment=
"center"
contentVerticalAlignment=
"center"
buttonType=
"roundedRect"
lineBreakMode=
"middleTruncation"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"1jd-Wk-3GP"
>
<rect
key=
"frame"
x=
"152"
y=
"67.5"
width=
"111"
height=
"111"
/>
<color
key=
"backgroundColor"
red=
"0.14901960780000001"
green=
"0.74117647060000003"
blue=
"0.36078431370000003"
alpha=
"1"
colorSpace=
"custom"
customColorSpace=
"sRGB"
/>
<constraints>
<constraint
firstAttribute=
"width"
secondItem=
"1jd-Wk-3GP"
secondAttribute=
"height"
id=
"8Oy-XT-kKI"
/>
</constraints>
<fontDescription
key=
"fontDescription"
type=
"system"
weight=
"medium"
pointSize=
"16"
/>
<state
key=
"normal"
>
<color
key=
"titleColor"
red=
"1"
green=
"1"
blue=
"1"
alpha=
"1"
colorSpace=
"custom"
customColorSpace=
"displayP3"
/>
</state>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute
type=
"color"
keyPath=
"massBackgroundColor"
>
<color
key=
"value"
white=
"0.0"
alpha=
"1"
colorSpace=
"custom"
customColorSpace=
"genericGamma22GrayColorSpace"
/>
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
</button>
<stackView
opaque=
"NO"
userInteractionEnabled=
"NO"
contentMode=
"scaleToFill"
axis=
"vertical"
distribution=
"fillEqually"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"ggP-Tm-Bko"
>
<rect
key=
"frame"
x=
"191"
y=
"113.5"
width=
"33.5"
height=
"19.5"
/>
<subviews>
<label
opaque=
"NO"
userInteractionEnabled=
"NO"
contentMode=
"left"
horizontalHuggingPriority=
"251"
verticalHuggingPriority=
"251"
text=
"82%"
textAlignment=
"natural"
lineBreakMode=
"tailTruncation"
baselineAdjustment=
"alignBaselines"
adjustsFontSizeToFit=
"NO"
translatesAutoresizingMaskIntoConstraints=
"NO"
id=
"yC1-rk-Hns"
>
<rect
key=
"frame"
x=
"0.0"
y=
"0.0"
width=
"33.5"
height=
"19.5"
/>
<fontDescription
key=
"fontDescription"
type=
"system"
weight=
"medium"
pointSize=
"16"
/>
<color
key=
"textColor"
red=
"0.1333333333"
green=
"0.16078431369999999"
blue=
"0.23921568630000001"
alpha=
"1"
colorSpace=
"custom"
customColorSpace=
"sRGB"
/>
<nil
key=
"highlightedColor"
/>
</label>
</subviews>
</stackView>
</subviews>
<constraints>
<constraint
firstItem=
"ggP-Tm-Bko"
firstAttribute=
"centerX"
secondItem=
"1jd-Wk-3GP"
secondAttribute=
"centerX"
id=
"4Jk-2s-Isl"
/>
<constraint
firstItem=
"zHw-24-34Q"
firstAttribute=
"centerX"
secondItem=
"Zv4-WU-omb"
secondAttribute=
"centerX"
id=
"5lQ-Pu-Nbh"
/>
<constraint
firstItem=
"1jd-Wk-3GP"
firstAttribute=
"centerY"
secondItem=
"Zv4-WU-omb"
secondAttribute=
"centerY"
id=
"B66-oI-GDt"
/>
<constraint
firstItem=
"ggP-Tm-Bko"
firstAttribute=
"centerX"
secondItem=
"U6b-Vx-4bR"
secondAttribute=
"centerX"
id=
"CGu-e6-A6F"
/>
<constraint
firstItem=
"1jd-Wk-3GP"
firstAttribute=
"centerX"
secondItem=
"Zv4-WU-omb"
secondAttribute=
"centerX"
id=
"GUh-Om-2FR"
/>
<constraint
firstItem=
"zHw-24-34Q"
firstAttribute=
"centerX"
secondItem=
"U6b-Vx-4bR"
secondAttribute=
"centerX"
id=
"GjT-uU-6bX"
/>
<constraint
firstItem=
"Zv4-WU-omb"
firstAttribute=
"top"
secondItem=
"U6b-Vx-4bR"
secondAttribute=
"top"
constant=
"25"
id=
"Gjn-0n-8YZ"
/>
<constraint
firstItem=
"1jd-Wk-3GP"
firstAttribute=
"width"
secondItem=
"Zv4-WU-omb"
secondAttribute=
"width"
multiplier=
"95:168"
id=
"HQJ-iW-vZ9"
/>
<constraint
firstItem=
"kdu-zn-cpc"
firstAttribute=
"centerX"
secondItem=
"U6b-Vx-4bR"
secondAttribute=
"centerX"
id=
"HcD-OE-9YK"
/>
<constraint
firstItem=
"ggP-Tm-Bko"
firstAttribute=
"centerY"
secondItem=
"1jd-Wk-3GP"
secondAttribute=
"centerY"
id=
"Stx-Ch-vQ5"
/>
<constraint
firstItem=
"kdu-zn-cpc"
firstAttribute=
"top"
secondItem=
"zHw-24-34Q"
secondAttribute=
"bottom"
constant=
"14"
id=
"Vb3-jJ-47a"
/>
<constraint
firstItem=
"zHw-24-34Q"
firstAttribute=
"top"
secondItem=
"Zv4-WU-omb"
secondAttribute=
"bottom"
constant=
"20"
id=
"Vy1-Zq-bGV"
/>
<constraint
firstItem=
"Zv4-WU-omb"
firstAttribute=
"width"
secondItem=
"U6b-Vx-4bR"
secondAttribute=
"width"
multiplier=
"168:355"
id=
"X6Y-WL-zDQ"
/>
<constraint
firstItem=
"Zv4-WU-omb"
firstAttribute=
"width"
secondItem=
"Zv4-WU-omb"
secondAttribute=
"height"
id=
"ZcV-l7-Tmo"
/>
<constraint
firstItem=
"kdu-zn-cpc"
firstAttribute=
"centerX"
secondItem=
"Zv4-WU-omb"
secondAttribute=
"centerX"
id=
"Zcs-zK-Anc"
/>
<constraint
firstItem=
"1jd-Wk-3GP"
firstAttribute=
"centerX"
secondItem=
"U6b-Vx-4bR"
secondAttribute=
"centerX"
id=
"gbh-51-ooP"
/>
<constraint
firstItem=
"1jd-Wk-3GP"
firstAttribute=
"width"
secondItem=
"1jd-Wk-3GP"
secondAttribute=
"height"
id=
"jjh-CL-fBu"
/>
<constraint
firstItem=
"Zv4-WU-omb"
firstAttribute=
"centerX"
secondItem=
"U6b-Vx-4bR"
secondAttribute=
"centerX"
id=
"ulc-67-RPm"
/>
</constraints>
<viewLayoutGuide
key=
"safeArea"
id=
"9Gg-ye-v9C"
/>
<connections>
<outlet
property=
"cycleImageView"
destination=
"Zv4-WU-omb"
id=
"7R7-Y5-uew"
/>
<outlet
property=
"manualButton"
destination=
"kdu-zn-cpc"
id=
"TVz-VU-f4f"
/>
<outlet
property=
"smartClearButton"
destination=
"1jd-Wk-3GP"
id=
"MG6-5N-v0z"
/>
<outlet
property=
"spacePercentLabel"
destination=
"zHw-24-34Q"
id=
"MPT-Vt-mQ8"
/>
<outlet
property=
"usedSpaceScaleLabel"
destination=
"yC1-rk-Hns"
id=
"jN8-3G-tXo"
/>
</connections>
<point
key=
"canvasLocation"
x=
"306.52173913043481"
y=
"98.4375"
/>
</collectionReusableView>
</objects>
<resources>
<image
name=
"home_button_bg"
width=
"188"
height=
"50"
/>
<image
name=
"home_cycle_bg_img"
width=
"168"
height=
"168"
/>
</resources>
</document>
superCleaner/Manager/ICUserManager.m
View file @
8dfbba44
...
...
@@ -51,10 +51,16 @@ static ICUserManager * manager;
}
-
(
BOOL
)
isMember
{
NSString
*
dateString
=
[[
NSUserDefaults
standardUserDefaults
]
valueForKeyPath
:
@"expiryDate"
];
if
(
dateString
.
length
<=
0
)
{
#ifdef DEBUG
return
false
;
#else
return
self
.
model
.
isMember
;
#endif
}
NSDateFormatter
*
formatter
=
[[
NSDateFormatter
alloc
]
init
];
formatter
.
dateFormat
=
@"yyyy-MM-dd HH:mm"
;
NSDate
*
expiryDate
=
[
formatter
dateFromString
:
dateString
];
...
...
@@ -66,7 +72,6 @@ static ICUserManager * manager;
// else if ([expiryDate timeIntervalSinceDate:[NSDate date]] <= 0) {
// return false;
// }
return
self
.
model
.
isMember
;
}
...
...
@@ -162,7 +167,11 @@ static ICUserManager * manager;
}
else
{
[
data
removeDicForKey
:
@"urlInfo"
];
}
if
([[[
response
objectForKey
:
@"result"
]
objectForKey
:
@"data"
]
objectForKey
:
@"config"
])
{
[
data
WirteDic
:[[[
response
objectForKey
:
@"result"
]
objectForKey
:
@"data"
]
objectForKey
:
@"config"
]
Key
:
@"config"
];
}
else
{
[
data
removeDicForKey
:
@"config"
];
}
}
}
failure
:^
(
NSError
*
_Nonnull
error
)
{
...
...
superCleaner/Manager/Network/ICPurchaseManager.swift
View file @
8dfbba44
...
...
@@ -24,7 +24,7 @@ class ICPurchaseManager: NSObject {
case
.
success
(
let
product
):
print
(
"Purchase Success:
\(
product
.
productId
)
"
)
let
appleValidator
=
AppleReceiptValidator
(
service
:
.
production
,
sharedSecret
:
"
0dee7332e952467c97e5d4ecd1f788f6
"
)
let
appleValidator
=
AppleReceiptValidator
(
service
:
.
production
,
sharedSecret
:
"
ed0f68aca7964038a5cdf2a68c8c35c4
"
)
let
hud
=
MBProgressHUD
.
showAdded
(
to
:
inView
,
animated
:
true
)
SwiftyStoreKit
.
verifyReceipt
(
using
:
appleValidator
)
{
result
in
hud
.
hide
(
animated
:
true
)
...
...
@@ -230,7 +230,7 @@ class ICPurchaseManager: NSObject {
print
(
"Restore sortedResults:
\(
sortedResults
)
"
)
if
let
purchase
=
sortedResults
.
last
{
let
appleValidator
=
AppleReceiptValidator
(
service
:
.
production
,
sharedSecret
:
"
0dee7332e952467c97e5d4ecd1f788f6
"
)
let
appleValidator
=
AppleReceiptValidator
(
service
:
.
production
,
sharedSecret
:
"
ed0f68aca7964038a5cdf2a68c8c35c4
"
)
let
hud
=
MBProgressHUD
.
showAdded
(
to
:
UIApplication
.
shared
.
delegate
!.
window
!!
,
animated
:
true
)
SwiftyStoreKit
.
verifyReceipt
(
using
:
appleValidator
)
{
result
in
hud
.
hide
(
animated
:
true
)
...
...
superCleaner/Other/ICNetworkSpeedViewController.m
View file @
8dfbba44
...
...
@@ -86,7 +86,7 @@
-
(
void
)
pingActionFired
{
self
.
pingServices
=
[
STDPingServices
startPingAddress
:
@"
117.78.49.136
"
monitorTime
:
5
callbackHandler
:^
(
STDPingItem
*
pingItem
,
NSArray
*
pingItems
)
{
self
.
pingServices
=
[
STDPingServices
startPingAddress
:
@"
https://www.baidu.com
"
monitorTime
:
5
callbackHandler
:^
(
STDPingItem
*
pingItem
,
NSArray
*
pingItems
)
{
if
(
pingItem
.
status
!=
STDPingStatusFinished
)
{
NSLog
(
@"-----%@"
,
pingItem
.
description
);
}
else
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment