Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
likorn
/
Lavina
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
91b25ff1
authored
May 14, 2018
by
Paktalin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixed bug with images in expandable list view
parent
15ebe070
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
2 deletions
app/src/main/java/com/example/paktalin/lavina/adapters/ExpandableListAdapter.java
app/src/main/java/com/example/paktalin/lavina/adapters/ExpandableListAdapter.java
View file @
91b25ff1
...
...
@@ -3,6 +3,7 @@ package com.example.paktalin.lavina.adapters;
import
android.content.Context
;
import
android.graphics.Bitmap
;
import
android.graphics.Typeface
;
import
android.util.Log
;
import
android.view.LayoutInflater
;
import
android.view.View
;
import
android.view.ViewGroup
;
...
...
@@ -58,9 +59,17 @@ public class ExpandableListAdapter extends BaseExpandableListAdapter {
}
TextView
txtListChild
=
convertView
.
findViewById
(
R
.
id
.
lblListItem
);
if
(
groupPosition
==
0
)
{
ImageView
imageView
=
convertView
.
findViewById
(
R
.
id
.
image_item
);
String
group
=
(
String
)
getGroup
(
groupPosition
);
Log
.
d
(
"TEST"
,
"current group"
+
group
);
ImageView
imageView
=
convertView
.
findViewById
(
R
.
id
.
image_item
);
if
(
group
.
equals
(
"COLOR"
))
{
Log
.
d
(
"TEST"
,
"wohoo"
);
imageView
.
setImageBitmap
(
colorImages
[
childPosition
]);
}
else
{
imageView
.
setImageResource
(
android
.
R
.
color
.
transparent
);
}
txtListChild
.
setText
(
childText
);
...
...
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