Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
I
InstiApp
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
RAHUL SHARMA
InstiApp
Commits
d184dc07
Commit
d184dc07
authored
Feb 03, 2019
by
Varun Patil
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Prevent showing low res image onResume in EventFragment
parent
297fec0e
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
3 deletions
+8
-3
app/src/main/java/app/insti/fragment/EventFragment.java
app/src/main/java/app/insti/fragment/EventFragment.java
+8
-3
No files found.
app/src/main/java/app/insti/fragment/EventFragment.java
View file @
d184dc07
...
@@ -75,7 +75,8 @@ public class EventFragment extends BackHandledFragment implements TransitionTarg
...
@@ -75,7 +75,8 @@ public class EventFragment extends BackHandledFragment implements TransitionTarg
ImageButton
shareEventButton
;
ImageButton
shareEventButton
;
RecyclerView
bodyRecyclerView
;
RecyclerView
bodyRecyclerView
;
String
TAG
=
"EventFragment"
;
String
TAG
=
"EventFragment"
;
int
appBarOffset
=
0
;
private
int
appBarOffset
=
0
;
private
boolean
creatingView
=
false
;
// Hold a reference to the current animator,
// Hold a reference to the current animator,
// so that it can be canceled mid-way.
// so that it can be canceled mid-way.
...
@@ -127,6 +128,9 @@ public class EventFragment extends BackHandledFragment implements TransitionTarg
...
@@ -127,6 +128,9 @@ public class EventFragment extends BackHandledFragment implements TransitionTarg
@Override
@Override
public
View
onCreateView
(
LayoutInflater
inflater
,
ViewGroup
container
,
public
View
onCreateView
(
LayoutInflater
inflater
,
ViewGroup
container
,
Bundle
savedInstanceState
)
{
Bundle
savedInstanceState
)
{
// Check if we are not returning after a pause
creatingView
=
true
;
// Inflate the layout for this fragment
// Inflate the layout for this fragment
return
inflater
.
inflate
(
R
.
layout
.
fragment_event
,
container
,
false
);
return
inflater
.
inflate
(
R
.
layout
.
fragment_event
,
container
,
false
);
}
}
...
@@ -154,9 +158,10 @@ public class EventFragment extends BackHandledFragment implements TransitionTarg
...
@@ -154,9 +158,10 @@ public class EventFragment extends BackHandledFragment implements TransitionTarg
Toolbar
toolbar
=
getActivity
().
findViewById
(
R
.
id
.
toolbar
);
Toolbar
toolbar
=
getActivity
().
findViewById
(
R
.
id
.
toolbar
);
toolbar
.
setTitle
(
event
.
getEventName
());
toolbar
.
setTitle
(
event
.
getEventName
());
if
(
bundle
.
getBoolean
(
Constants
.
NO_SHARED_ELEM
,
true
))
{
if
(
creatingView
&&
bundle
.
getBoolean
(
Constants
.
NO_SHARED_ELEM
,
true
))
{
this
.
transitionEnd
();
this
.
transitionEnd
();
}
}
creatingView
=
false
;
setupAppBarLayout
();
setupAppBarLayout
();
}
}
...
@@ -205,7 +210,7 @@ public class EventFragment extends BackHandledFragment implements TransitionTarg
...
@@ -205,7 +210,7 @@ public class EventFragment extends BackHandledFragment implements TransitionTarg
webEventButton
=
getActivity
().
findViewById
(
R
.
id
.
web_event_button
);
webEventButton
=
getActivity
().
findViewById
(
R
.
id
.
web_event_button
);
shareEventButton
=
getActivity
().
findViewById
(
R
.
id
.
share_event_button
);
shareEventButton
=
getActivity
().
findViewById
(
R
.
id
.
share_event_button
);
if
(
event
.
isEventBigImage
())
{
if
(
event
.
isEventBigImage
()
||
!
creatingView
)
{
Picasso
.
get
().
load
(
event
.
getEventImageURL
()).
into
(
eventPicture
);
Picasso
.
get
().
load
(
event
.
getEventImageURL
()).
into
(
eventPicture
);
}
else
{
}
else
{
Picasso
.
get
().
load
(
Utils
.
resizeImageUrl
(
event
.
getEventImageURL
())).
into
(
eventPicture
);
Picasso
.
get
().
load
(
Utils
.
resizeImageUrl
(
event
.
getEventImageURL
())).
into
(
eventPicture
);
...
...
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