Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Krishna Vemulavada
/
vera_2.1_app
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
b735c905
authored
Sep 09, 2016
by
Kunj Gupta
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
UOFLMA-77: Fix - Remove hardcode string.
parent
a26400fe
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
1 deletions
app/src/main/java/com/vsoft/uoflservicenow/utils/Util.java
app/src/main/res/values/strings.xml
app/src/main/java/com/vsoft/uoflservicenow/utils/Util.java
View file @
b735c905
...
@@ -42,7 +42,10 @@ public class Util {
...
@@ -42,7 +42,10 @@ public class Util {
case
YES_NO:
case
YES_NO:
Spinner
spinner
=
new
Spinner
(
context
);
Spinner
spinner
=
new
Spinner
(
context
);
ArrayAdapter
<
String
>
spinnerArrayAdapter
=
ArrayAdapter
<
String
>
spinnerArrayAdapter
=
new
ArrayAdapter
<>(
context
,
android
.
R
.
layout
.
simple_spinner_item
,
new
String
[]
{
"None"
,
"Yes"
,
"No"
});
new
ArrayAdapter
<>(
context
,
android
.
R
.
layout
.
simple_spinner_item
,
new
String
[]
{
context
.
getResources
().
getString
(
R
.
string
.
none_string
),
context
.
getResources
().
getString
(
R
.
string
.
yes_string
),
context
.
getResources
().
getString
(
R
.
string
.
no_string
)});
spinnerArrayAdapter
.
setDropDownViewResource
(
android
.
R
.
layout
.
simple_spinner_dropdown_item
);
spinnerArrayAdapter
.
setDropDownViewResource
(
android
.
R
.
layout
.
simple_spinner_dropdown_item
);
spinner
.
setAdapter
(
spinnerArrayAdapter
);
spinner
.
setAdapter
(
spinnerArrayAdapter
);
return
spinner
;
return
spinner
;
...
...
app/src/main/res/values/strings.xml
View file @
b735c905
...
@@ -6,6 +6,8 @@
...
@@ -6,6 +6,8 @@
<string
name=
"back_string"
>
Back
</string>
<string
name=
"back_string"
>
Back
</string>
<string
name=
"error_string"
>
* Required
</string>
<string
name=
"error_string"
>
* Required
</string>
<string
name=
"none_string"
>
-None-
</string>
<string
name=
"none_string"
>
-None-
</string>
<string
name=
"yes_string"
>
Yes
</string>
<string
name=
"no_string"
>
No
</string>
<string
name=
"search_for_reference_string"
>
Reference
</string>
<string
name=
"search_for_reference_string"
>
Reference
</string>
<string
name=
"home_screen_string"
>
Home Screen
</string>
<string
name=
"home_screen_string"
>
Home Screen
</string>
<string
name=
"login_screen_string"
>
Login Screen
</string>
<string
name=
"login_screen_string"
>
Login Screen
</string>
...
...
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