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
71bdc3ea
Commit
71bdc3ea
authored
Jul 20, 2016
by
Daniel Dahan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
added normal state to buttons
parent
a458553c
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
4 deletions
+8
-4
Sources/iOS/NavigationController.swift
+2
-1
Sources/iOS/SearchBar.swift
+2
-1
Sources/iOS/TextField.swift
+4
-2
No files found.
Sources/iOS/NavigationController.swift
View file @
71bdc3ea
...
@@ -110,7 +110,8 @@ public class NavigationController : UINavigationController, UIGestureRecognizerD
...
@@ -110,7 +110,8 @@ public class NavigationController : UINavigationController, UIGestureRecognizerD
if
let
v
:
NavigationBar
=
navigationBar
as?
NavigationBar
{
if
let
v
:
NavigationBar
=
navigationBar
as?
NavigationBar
{
let
backButton
:
IconButton
=
IconButton
()
let
backButton
:
IconButton
=
IconButton
()
backButton
.
pulseColor
=
Color
.
white
backButton
.
pulseColor
=
Color
.
white
backButton
.
setImage
(
v
.
backButtonImage
,
for
:
.
highlighted
)
backButton
.
setImage
(
v
.
backButtonImage
,
for
:
.
normal
)
backButton
.
setImage
(
v
.
backButtonImage
,
for
:
.
highlighted
)
backButton
.
addTarget
(
self
,
action
:
#selector(
handleBackButton
)
,
for
:
.
touchUpInside
)
backButton
.
addTarget
(
self
,
action
:
#selector(
handleBackButton
)
,
for
:
.
touchUpInside
)
if
var
c
:
Array
<
UIControl
>
=
item
.
leftControls
{
if
var
c
:
Array
<
UIControl
>
=
item
.
leftControls
{
...
...
Sources/iOS/SearchBar.swift
View file @
71bdc3ea
...
@@ -163,7 +163,8 @@ public class SearchBar : BarView {
...
@@ -163,7 +163,8 @@ public class SearchBar : BarView {
clearButton
=
IconButton
()
clearButton
=
IconButton
()
clearButton
.
contentEdgeInsets
=
UIEdgeInsets
.
zero
clearButton
.
contentEdgeInsets
=
UIEdgeInsets
.
zero
clearButton
.
tintColor
=
placeholderColor
clearButton
.
tintColor
=
placeholderColor
clearButton
.
setImage
(
image
,
for
:
.
highlighted
)
clearButton
.
setImage
(
image
,
for
:
.
normal
)
clearButton
.
setImage
(
image
,
for
:
.
highlighted
)
clearButtonAutoHandleEnabled
=
true
clearButtonAutoHandleEnabled
=
true
textField
.
clearButtonMode
=
.
never
textField
.
clearButtonMode
=
.
never
textField
.
rightViewMode
=
.
whileEditing
textField
.
rightViewMode
=
.
whileEditing
...
...
Sources/iOS/TextField.swift
View file @
71bdc3ea
...
@@ -230,7 +230,8 @@ public class TextField: UITextField {
...
@@ -230,7 +230,8 @@ public class TextField: UITextField {
clearIconButton
!.
contentEdgeInsets
=
UIEdgeInsets
.
zero
clearIconButton
!.
contentEdgeInsets
=
UIEdgeInsets
.
zero
clearIconButton
!.
pulseAnimation
=
.
center
clearIconButton
!.
pulseAnimation
=
.
center
clearIconButton
!.
tintColor
=
placeholderColor
clearIconButton
!.
tintColor
=
placeholderColor
clearIconButton
!.
setImage
(
image
,
for
:
.
highlighted
)
clearIconButton
!.
setImage
(
image
,
for
:
.
normal
)
clearIconButton
!.
setImage
(
image
,
for
:
.
highlighted
)
clearButtonMode
=
.
never
clearButtonMode
=
.
never
rightViewMode
=
.
whileEditing
rightViewMode
=
.
whileEditing
rightView
=
clearIconButton
rightView
=
clearIconButton
...
@@ -266,7 +267,8 @@ public class TextField: UITextField {
...
@@ -266,7 +267,8 @@ public class TextField: UITextField {
visibilityIconButton
!.
contentEdgeInsets
=
UIEdgeInsets
.
zero
visibilityIconButton
!.
contentEdgeInsets
=
UIEdgeInsets
.
zero
visibilityIconButton
!.
pulseAnimation
=
.
center
visibilityIconButton
!.
pulseAnimation
=
.
center
visibilityIconButton
!.
tintColor
=
placeholderColor
visibilityIconButton
!.
tintColor
=
placeholderColor
visibilityIconButton
!.
setImage
(
image
,
for
:
.
highlighted
)
visibilityIconButton
!.
setImage
(
image
,
for
:
.
normal
)
visibilityIconButton
!.
setImage
(
image
,
for
:
.
highlighted
)
visibilityIconButton
!.
tintColor
=
placeholderColor
.
withAlphaComponent
(
isSecureTextEntry
?
0.38
:
0.54
)
visibilityIconButton
!.
tintColor
=
placeholderColor
.
withAlphaComponent
(
isSecureTextEntry
?
0.38
:
0.54
)
isSecureTextEntry
=
true
isSecureTextEntry
=
true
clearButtonMode
=
.
never
clearButtonMode
=
.
never
...
...
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