Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
Material
Overview
Overview
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
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Dmitriy Stepanets
Material
Commits
7862f082
Commit
7862f082
authored
Oct 27, 2018
by
Orkhan Alikhanov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Renamed internal attribute function to anchor
parent
492b64fe
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
18 deletions
+18
-18
Sources/iOS/LayoutAnchor.swift
+18
-18
No files found.
Sources/iOS/LayoutAnchor.swift
View file @
7862f082
...
...
@@ -51,81 +51,81 @@ public struct LayoutAnchor {
public
extension
Layout
{
/// A layout anchor representing top of the view.
var
top
:
LayoutAnchor
{
return
a
ttribute
(
.
top
)
return
a
nchor
(
.
top
)
}
/// A layout anchor representing bottom of the view.
var
bottom
:
LayoutAnchor
{
return
a
ttribute
(
.
bottom
)
return
a
nchor
(
.
bottom
)
}
/// A layout anchor representing left of the view.
var
left
:
LayoutAnchor
{
return
a
ttribute
(
.
left
)
return
a
nchor
(
.
left
)
}
/// A layout anchor representing right of the view.
var
right
:
LayoutAnchor
{
return
a
ttribute
(
.
right
)
return
a
nchor
(
.
right
)
}
/// A layout anchor representing top-left of the view.
var
topLeft
:
LayoutAnchor
{
return
a
ttribute
(
.
topLeft
)
return
a
cnhor
(
.
topLeft
)
}
/// A layout anchor representing top-right of the view.
var
topRight
:
LayoutAnchor
{
return
a
ttribute
(
.
topRight
)
return
a
cnhor
(
.
topRight
)
}
/// A layout anchor representing bottom-left of the view.
var
bottomLeft
:
LayoutAnchor
{
return
a
ttribute
(
.
bottomLeft
)
return
a
cnhor
(
.
bottomLeft
)
}
/// A layout anchor representing bottom-right of the view.
var
bottomRight
:
LayoutAnchor
{
return
a
ttribute
(
.
bottomRight
)
return
a
cnhor
(
.
bottomRight
)
}
/// A layout anchor representing top and bottom of the view.
var
topBottom
:
LayoutAnchor
{
return
a
ttribute
(
.
topBottom
)
return
a
cnhor
(
.
topBottom
)
}
/// A layout anchor representing left and right of the view.
var
leftRight
:
LayoutAnchor
{
return
a
ttribute
(
.
leftRight
)
return
a
cnhor
(
.
leftRight
)
}
/// A layout anchor representing center of the view.
var
center
:
LayoutAnchor
{
return
a
ttribute
(
.
center
)
return
a
cnhor
(
.
center
)
}
/// A layout anchor representing horizontal center of the view.
var
centerX
:
LayoutAnchor
{
return
a
ttribute
(
.
centerX
)
return
a
nchor
(
.
centerX
)
}
/// A layout anchor representing vertical center of the view.
var
centerY
:
LayoutAnchor
{
return
a
ttribute
(
.
centerY
)
return
a
nchor
(
.
centerY
)
}
/// A layout anchor representing top, left, bottom and right of the view.
var
edges
:
LayoutAnchor
{
return
a
ttribute
(
.
edges
)
return
a
cnhor
(
.
edges
)
}
/// A layout anchor representing width of the view.
var
width
:
LayoutAnchor
{
return
a
ttribute
(
.
width
)
return
a
nchor
(
.
width
)
}
/// A layout anchor representing height of the view.
var
height
:
LayoutAnchor
{
return
a
ttribute
(
.
height
)
return
a
nchor
(
.
height
)
}
}
...
...
@@ -135,7 +135,7 @@ private extension Layout {
- Parameter attribute: A LayoutAttribute.
- Returns: A LayoutAnchor.
*/
func
a
ttribute
(
_
attribute
:
LayoutAttribute
)
->
LayoutAnchor
{
func
a
nchor
(
_
attribute
:
LayoutAttribute
)
->
LayoutAnchor
{
return
LayoutAnchor
(
view
:
view
,
attributes
:
[
attribute
])
}
...
...
@@ -144,7 +144,7 @@ private extension Layout {
- Parameter attributes: An array of LayoutAttribute.
- Returns: A LayoutAnchor.
*/
func
a
ttribute
(
_
attributes
:
[
LayoutAttribute
])
->
LayoutAnchor
{
func
a
cnhor
(
_
attributes
:
[
LayoutAttribute
])
->
LayoutAnchor
{
return
LayoutAnchor
(
view
:
view
,
attributes
:
attributes
)
}
}
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