Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
D
dz_TZImagePickerController
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
shuijing
dz_TZImagePickerController
Commits
00008117
Commit
00008117
authored
Dec 22, 2016
by
Wilson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix subview frame issue
parent
9456dbbc
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
30 additions
and
4 deletions
+30
-4
TZImagePickerController/TZImagePickerController/TZImagePickerController.m
...troller/TZImagePickerController/TZImagePickerController.m
+10
-1
TZImagePickerController/TZImagePickerController/TZPhotoPickerController.m
...troller/TZImagePickerController/TZPhotoPickerController.m
+20
-3
No files found.
TZImagePickerController/TZImagePickerController/TZImagePickerController.m
View file @
00008117
...
...
@@ -516,11 +516,20 @@
albumModel
.
selectedModels
=
imagePickerVc
.
selectedModels
;
}
if
(
!
_tableView
)
{
CGFloat
top
=
0
;
if
(
self
.
navigationController
.
navigationBar
.
translucent
)
{
CGFloat
tableViewHeight
=
0
;
if
(
self
.
navigationController
.
navigationBar
.
isTranslucent
)
{
top
=
44
;
if
(
iOS7Later
)
top
+=
20
;
tableViewHeight
=
self
.
view
.
tz_height
-
top
;
}
else
{
CGFloat
navigationHeight
=
44
;
if
(
iOS7Later
)
navigationHeight
+=
20
;
tableViewHeight
=
self
.
view
.
tz_height
-
navigationHeight
;
}
_tableView
=
[[
UITableView
alloc
]
initWithFrame
:
CGRectMake
(
0
,
top
,
self
.
view
.
tz_width
,
self
.
view
.
tz_height
-
top
)
style
:
UITableViewStylePlain
];
_tableView
.
rowHeight
=
70
;
_tableView
.
tableFooterView
=
[[
UIView
alloc
]
init
];
...
...
TZImagePickerController/TZImagePickerController/TZPhotoPickerController.m
View file @
00008117
...
...
@@ -121,11 +121,18 @@ static CGSize AssetGridThumbnailSize;
layout
.
minimumLineSpacing
=
margin
;
CGFloat
top
=
0
;
if
(
self
.
navigationController
.
navigationBar
.
translucent
)
{
CGFloat
collectionViewHeight
=
0
;
if
(
self
.
navigationController
.
navigationBar
.
isTranslucent
)
{
top
=
44
;
if
(
iOS7Later
)
top
+=
20
;
collectionViewHeight
=
tzImagePickerVc
.
showSelectBtn
?
self
.
view
.
tz_height
-
50
-
top
:
self
.
view
.
tz_height
-
top
;;
}
CGFloat
collectionViewHeight
=
tzImagePickerVc
.
showSelectBtn
?
self
.
view
.
tz_height
-
50
-
top
:
self
.
view
.
tz_height
-
top
;
else
{
CGFloat
navigationHeight
=
44
;
if
(
iOS7Later
)
navigationHeight
+=
20
;
collectionViewHeight
=
tzImagePickerVc
.
showSelectBtn
?
self
.
view
.
tz_height
-
50
-
navigationHeight
:
self
.
view
.
tz_height
-
navigationHeight
;
}
_collectionView
=
[[
TZCollectionView
alloc
]
initWithFrame
:
CGRectMake
(
0
,
top
,
self
.
view
.
tz_width
,
collectionViewHeight
)
collectionViewLayout
:
layout
];
_collectionView
.
backgroundColor
=
[
UIColor
whiteColor
];
_collectionView
.
dataSource
=
self
;
...
...
@@ -166,7 +173,17 @@ static CGSize AssetGridThumbnailSize;
TZImagePickerController
*
tzImagePickerVc
=
(
TZImagePickerController
*
)
self
.
navigationController
;
if
(
!
tzImagePickerVc
.
showSelectBtn
)
return
;
UIView
*
bottomToolBar
=
[[
UIView
alloc
]
initWithFrame
:
CGRectMake
(
0
,
self
.
view
.
tz_height
-
50
,
self
.
view
.
tz_width
,
50
)];
CGFloat
yOffset
=
0
;
if
(
self
.
navigationController
.
navigationBar
.
isTranslucent
)
{
yOffset
=
self
.
view
.
tz_height
-
50
;
}
else
{
CGFloat
navigationHeight
=
44
;
if
(
iOS7Later
)
navigationHeight
+=
20
;
yOffset
=
self
.
view
.
tz_height
-
50
-
navigationHeight
;
}
UIView
*
bottomToolBar
=
[[
UIView
alloc
]
initWithFrame
:
CGRectMake
(
0
,
yOffset
,
self
.
view
.
tz_width
,
50
)];
CGFloat
rgb
=
253
/
255
.
0
;
bottomToolBar
.
backgroundColor
=
[
UIColor
colorWithRed
:
rgb
green
:
rgb
blue
:
rgb
alpha
:
1
.
0
];
...
...
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