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
7570c5b1
Commit
7570c5b1
authored
Jul 08, 2018
by
Varun Patil
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update libraries for HTTP/2 support
parent
f0e37858
Changes
12
Hide whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
15 additions
and
19 deletions
+15
-19
app/build.gradle
app/build.gradle
+3
-5
app/src/main/java/app/insti/MainActivity.java
app/src/main/java/app/insti/MainActivity.java
+2
-4
app/src/main/java/app/insti/adapter/BodyAdapter.java
app/src/main/java/app/insti/adapter/BodyAdapter.java
+1
-1
app/src/main/java/app/insti/adapter/FeedAdapter.java
app/src/main/java/app/insti/adapter/FeedAdapter.java
+1
-1
app/src/main/java/app/insti/adapter/RoleAdapter.java
app/src/main/java/app/insti/adapter/RoleAdapter.java
+1
-1
app/src/main/java/app/insti/adapter/UserAdapter.java
app/src/main/java/app/insti/adapter/UserAdapter.java
+1
-1
app/src/main/java/app/insti/fragment/AboutFragment.java
app/src/main/java/app/insti/fragment/AboutFragment.java
+1
-1
app/src/main/java/app/insti/fragment/AddEventFragment.java
app/src/main/java/app/insti/fragment/AddEventFragment.java
+1
-1
app/src/main/java/app/insti/fragment/BodyFragment.java
app/src/main/java/app/insti/fragment/BodyFragment.java
+1
-1
app/src/main/java/app/insti/fragment/EventFragment.java
app/src/main/java/app/insti/fragment/EventFragment.java
+1
-1
app/src/main/java/app/insti/fragment/ProfileFragment.java
app/src/main/java/app/insti/fragment/ProfileFragment.java
+1
-1
app/src/main/java/app/insti/fragment/SettingsFragment.java
app/src/main/java/app/insti/fragment/SettingsFragment.java
+1
-1
No files found.
app/build.gradle
View file @
7570c5b1
...
@@ -27,13 +27,12 @@ ext {
...
@@ -27,13 +27,12 @@ ext {
playServicesVersion
=
'15.0.1'
playServicesVersion
=
'15.0.1'
butterKnifeVersion
=
'8.8.1'
butterKnifeVersion
=
'8.8.1'
appAuthVersion
=
'0.2.0'
appAuthVersion
=
'0.2.0'
retrofitVersion
=
'2.
1
.0'
retrofitVersion
=
'2.
3
.0'
okhttpVersion
=
'3.
4.1
'
okhttpVersion
=
'3.
10.0
'
picassoVersion
=
'2.
5.0
'
picassoVersion
=
'2.
71828
'
archRoomVersion
=
'1.1.1'
archRoomVersion
=
'1.1.1'
circleImageViewVersion
=
'2.2.0'
circleImageViewVersion
=
'2.2.0'
markwonVersion
=
'1.0.4'
markwonVersion
=
'1.0.4'
picassoOkhttpVersion
=
'1.1.0'
}
}
dependencies
{
dependencies
{
...
@@ -63,6 +62,5 @@ dependencies {
...
@@ -63,6 +62,5 @@ dependencies {
implementation
"com.android.support:cardview-v7:${supportLibVersion}"
implementation
"com.android.support:cardview-v7:${supportLibVersion}"
implementation
"de.hdodenhof:circleimageview:${circleImageViewVersion}"
implementation
"de.hdodenhof:circleimageview:${circleImageViewVersion}"
implementation
"ru.noties:markwon:${markwonVersion}"
implementation
"ru.noties:markwon:${markwonVersion}"
implementation
"com.jakewharton.picasso:picasso2-okhttp3-downloader:${picassoOkhttpVersion}"
}
}
apply
plugin:
'com.google.gms.google-services'
apply
plugin:
'com.google.gms.google-services'
app/src/main/java/app/insti/MainActivity.java
View file @
7570c5b1
...
@@ -24,13 +24,11 @@ import android.widget.TextView;
...
@@ -24,13 +24,11 @@ import android.widget.TextView;
import
android.widget.Toast
;
import
android.widget.Toast
;
import
com.google.gson.Gson
;
import
com.google.gson.Gson
;
import
com.jakewharton.picasso.OkHttp3Downloader
;
import
com.squareup.picasso.Picasso
;
import
com.squareup.picasso.Picasso
;
import
app.insti.api.UnsafeOkHttpClient
;
import
app.insti.api.UnsafeOkHttpClient
;
import
app.insti.api.model.NotificationsResponse
;
import
app.insti.api.model.NotificationsResponse
;
import
app.insti.data.User
;
import
app.insti.data.User
;
import
app.insti.fragment.AboutFragment
;
import
app.insti.fragment.CalendarFragment
;
import
app.insti.fragment.CalendarFragment
;
import
app.insti.fragment.FeedFragment
;
import
app.insti.fragment.FeedFragment
;
import
app.insti.fragment.MapFragment
;
import
app.insti.fragment.MapFragment
;
...
@@ -121,7 +119,7 @@ public class MainActivity extends AppCompatActivity implements NavigationView.On
...
@@ -121,7 +119,7 @@ public class MainActivity extends AppCompatActivity implements NavigationView.On
nameTextView
.
setText
(
currentUser
.
getUserName
());
nameTextView
.
setText
(
currentUser
.
getUserName
());
rollNoTextView
.
setText
(
currentUser
.
getUserRollNumber
());
rollNoTextView
.
setText
(
currentUser
.
getUserRollNumber
());
Picasso
.
with
(
this
)
Picasso
.
get
(
)
.
load
(
currentUser
.
getUserProfilePictureUrl
())
.
load
(
currentUser
.
getUserProfilePictureUrl
())
.
resize
(
200
,
0
)
.
resize
(
200
,
0
)
.
placeholder
(
R
.
drawable
.
user_placeholder
)
.
placeholder
(
R
.
drawable
.
user_placeholder
)
...
@@ -326,7 +324,7 @@ public class MainActivity extends AppCompatActivity implements NavigationView.On
...
@@ -326,7 +324,7 @@ public class MainActivity extends AppCompatActivity implements NavigationView.On
public
void
initPicasso
()
{
public
void
initPicasso
()
{
Picasso
.
Builder
builder
=
new
Picasso
.
Builder
(
getApplicationContext
());
Picasso
.
Builder
builder
=
new
Picasso
.
Builder
(
getApplicationContext
());
builder
.
downloader
(
new
OkHttp3Downloader
((
builder
.
downloader
(
new
com
.
squareup
.
picasso
.
OkHttp3Downloader
((
UnsafeOkHttpClient
.
getUnsafeOkHttpClient
(
getApplicationContext
())
UnsafeOkHttpClient
.
getUnsafeOkHttpClient
(
getApplicationContext
())
)));
)));
Picasso
built
=
builder
.
build
();
Picasso
built
=
builder
.
build
();
...
...
app/src/main/java/app/insti/adapter/BodyAdapter.java
View file @
7570c5b1
...
@@ -51,7 +51,7 @@ public class BodyAdapter extends RecyclerView.Adapter<BodyAdapter.ViewHolder> {
...
@@ -51,7 +51,7 @@ public class BodyAdapter extends RecyclerView.Adapter<BodyAdapter.ViewHolder> {
Body
body
=
bodyList
.
get
(
position
);
Body
body
=
bodyList
.
get
(
position
);
holder
.
name
.
setText
(
body
.
getBodyName
());
holder
.
name
.
setText
(
body
.
getBodyName
());
holder
.
description
.
setText
(
body
.
getBodyShortDescription
());
holder
.
description
.
setText
(
body
.
getBodyShortDescription
());
Picasso
.
with
(
context
).
load
(
body
.
getBodyImageURL
()).
into
(
holder
.
image
);
Picasso
.
get
(
).
load
(
body
.
getBodyImageURL
()).
into
(
holder
.
image
);
}
}
...
...
app/src/main/java/app/insti/adapter/FeedAdapter.java
View file @
7570c5b1
...
@@ -68,7 +68,7 @@ public class FeedAdapter extends RecyclerView.Adapter<FeedAdapter.ViewHolder> {
...
@@ -68,7 +68,7 @@ public class FeedAdapter extends RecyclerView.Adapter<FeedAdapter.ViewHolder> {
if
(!
eventVenueName
.
toString
().
equals
(
""
))
if
(!
eventVenueName
.
toString
().
equals
(
""
))
viewHolder
.
eventVenue
.
setText
(
eventVenueName
.
toString
().
substring
(
2
));
viewHolder
.
eventVenue
.
setText
(
eventVenueName
.
toString
().
substring
(
2
));
Picasso
.
with
(
context
).
load
(
currentEvent
.
getEventImageURL
()).
into
(
viewHolder
.
eventPicture
);
Picasso
.
get
(
).
load
(
currentEvent
.
getEventImageURL
()).
into
(
viewHolder
.
eventPicture
);
}
}
@Override
@Override
...
...
app/src/main/java/app/insti/adapter/RoleAdapter.java
View file @
7570c5b1
...
@@ -55,7 +55,7 @@ public class RoleAdapter extends RecyclerView.Adapter<RoleAdapter.ViewHolder> {
...
@@ -55,7 +55,7 @@ public class RoleAdapter extends RecyclerView.Adapter<RoleAdapter.ViewHolder> {
Body
roleBody
=
role
.
getRoleBodyDetails
();
Body
roleBody
=
role
.
getRoleBodyDetails
();
holder
.
bodyName
.
setText
(
roleBody
.
getBodyName
());
holder
.
bodyName
.
setText
(
roleBody
.
getBodyName
());
holder
.
role
.
setText
(
role
.
getRoleName
());
holder
.
role
.
setText
(
role
.
getRoleName
());
Picasso
.
with
(
context
).
load
(
roleBody
.
getBodyImageURL
()).
into
(
holder
.
image
);
Picasso
.
get
(
).
load
(
roleBody
.
getBodyImageURL
()).
into
(
holder
.
image
);
}
}
...
...
app/src/main/java/app/insti/adapter/UserAdapter.java
View file @
7570c5b1
...
@@ -49,7 +49,7 @@ public class UserAdapter extends RecyclerView.Adapter<UserAdapter.ViewHolder> {
...
@@ -49,7 +49,7 @@ public class UserAdapter extends RecyclerView.Adapter<UserAdapter.ViewHolder> {
User
user
=
userList
.
get
(
position
);
User
user
=
userList
.
get
(
position
);
holder
.
userName
.
setText
(
user
.
getUserName
());
holder
.
userName
.
setText
(
user
.
getUserName
());
holder
.
role
.
setText
(
user
.
getCurrentRole
());
holder
.
role
.
setText
(
user
.
getCurrentRole
());
Picasso
.
with
(
context
)
Picasso
.
get
(
)
.
load
(
user
.
getUserProfilePictureUrl
())
.
load
(
user
.
getUserProfilePictureUrl
())
.
resize
(
150
,
0
)
.
resize
(
150
,
0
)
.
placeholder
(
R
.
drawable
.
user_placeholder
)
.
placeholder
(
R
.
drawable
.
user_placeholder
)
...
...
app/src/main/java/app/insti/fragment/AboutFragment.java
View file @
7570c5b1
...
@@ -72,7 +72,7 @@ public class AboutFragment extends BaseFragment {
...
@@ -72,7 +72,7 @@ public class AboutFragment extends BaseFragment {
/* Show team pics */
/* Show team pics */
for
(
final
Map
.
Entry
<
Integer
,
String
>
entry
:
team
.
entrySet
())
{
for
(
final
Map
.
Entry
<
Integer
,
String
>
entry
:
team
.
entrySet
())
{
CircleImageView
circleImageView
=
getActivity
().
findViewById
(
entry
.
getKey
());
CircleImageView
circleImageView
=
getActivity
().
findViewById
(
entry
.
getKey
());
Picasso
.
with
(
getContext
()
).
load
(
"https://insti.app/team-pics/"
+
entry
.
getValue
()).
into
(
circleImageView
);
Picasso
.
get
(
).
load
(
"https://insti.app/team-pics/"
+
entry
.
getValue
()).
into
(
circleImageView
);
}
}
/* Map TextView ids to links */
/* Map TextView ids to links */
...
...
app/src/main/java/app/insti/fragment/AddEventFragment.java
View file @
7570c5b1
...
@@ -314,7 +314,7 @@ public class AddEventFragment extends BaseFragment {
...
@@ -314,7 +314,7 @@ public class AddEventFragment extends BaseFragment {
String
picturePath
=
cursor
.
getString
(
columnIndex
);
String
picturePath
=
cursor
.
getString
(
columnIndex
);
cursor
.
close
();
cursor
.
close
();
ImageViewCompat
.
setImageTintList
(
eventPictureImageView
,
null
);
ImageViewCompat
.
setImageTintList
(
eventPictureImageView
,
null
);
Picasso
.
with
(
getContext
()
).
load
(
selectedImage
).
into
(
eventPictureImageView
);
Picasso
.
get
(
).
load
(
selectedImage
).
into
(
eventPictureImageView
);
base64Image
=
convertImageToString
(
getScaledBitmap
(
picturePath
,
800
,
800
));
base64Image
=
convertImageToString
(
getScaledBitmap
(
picturePath
,
800
,
800
));
Log
.
d
(
TAG
,
"onActivityResult: "
+
base64Image
);
Log
.
d
(
TAG
,
"onActivityResult: "
+
base64Image
);
}
}
...
...
app/src/main/java/app/insti/fragment/BodyFragment.java
View file @
7570c5b1
...
@@ -161,7 +161,7 @@ public class BodyFragment extends Fragment {
...
@@ -161,7 +161,7 @@ public class BodyFragment extends Fragment {
/* Set body information */
/* Set body information */
bodyName
.
setText
(
body
.
getBodyName
());
bodyName
.
setText
(
body
.
getBodyName
());
Picasso
.
with
(
getContext
()
).
load
(
body
.
getBodyImageURL
()).
into
(
eventPicture
);
Picasso
.
get
(
).
load
(
body
.
getBodyImageURL
()).
into
(
eventPicture
);
/* Return if it's a min body */
/* Return if it's a min body */
if
(
body
.
getBodyDescription
()
==
null
)
{
if
(
body
.
getBodyDescription
()
==
null
)
{
...
...
app/src/main/java/app/insti/fragment/EventFragment.java
View file @
7570c5b1
...
@@ -101,7 +101,7 @@ public class EventFragment extends BaseFragment {
...
@@ -101,7 +101,7 @@ public class EventFragment extends BaseFragment {
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
);
Picasso
.
with
(
getContext
()
).
load
(
event
.
getEventImageURL
()).
into
(
eventPicture
);
Picasso
.
get
(
).
load
(
event
.
getEventImageURL
()).
into
(
eventPicture
);
eventTitle
.
setText
(
event
.
getEventName
());
eventTitle
.
setText
(
event
.
getEventName
());
Markwon
.
setMarkdown
(
eventDescription
,
event
.
getEventDescription
());
Markwon
.
setMarkdown
(
eventDescription
,
event
.
getEventDescription
());
Timestamp
timestamp
=
event
.
getEventStartTime
();
Timestamp
timestamp
=
event
.
getEventStartTime
();
...
...
app/src/main/java/app/insti/fragment/ProfileFragment.java
View file @
7570c5b1
...
@@ -108,7 +108,7 @@ public class ProfileFragment extends BaseFragment {
...
@@ -108,7 +108,7 @@ public class ProfileFragment extends BaseFragment {
userRoleRecyclerView
.
setAdapter
(
roleAdapter
);
userRoleRecyclerView
.
setAdapter
(
roleAdapter
);
userRoleRecyclerView
.
setLayoutManager
(
new
LinearLayoutManager
(
getContext
()));
userRoleRecyclerView
.
setLayoutManager
(
new
LinearLayoutManager
(
getContext
()));
Picasso
.
with
(
getContext
()
)
Picasso
.
get
(
)
.
load
(
user
.
getUserProfilePictureUrl
())
.
load
(
user
.
getUserProfilePictureUrl
())
.
resize
(
800
,
0
)
.
resize
(
800
,
0
)
.
placeholder
(
R
.
drawable
.
user_placeholder
)
.
placeholder
(
R
.
drawable
.
user_placeholder
)
...
...
app/src/main/java/app/insti/fragment/SettingsFragment.java
View file @
7570c5b1
...
@@ -76,7 +76,7 @@ public class SettingsFragment extends Fragment {
...
@@ -76,7 +76,7 @@ public class SettingsFragment extends Fragment {
ImageView
userProfilePictureImageView
=
getActivity
().
findViewById
(
R
.
id
.
user_card_avatar
);
ImageView
userProfilePictureImageView
=
getActivity
().
findViewById
(
R
.
id
.
user_card_avatar
);
TextView
userNameTextView
=
getActivity
().
findViewById
(
R
.
id
.
user_card_name
);
TextView
userNameTextView
=
getActivity
().
findViewById
(
R
.
id
.
user_card_name
);
Picasso
.
with
(
getContext
()
)
Picasso
.
get
(
)
.
load
(
user
.
getUserProfilePictureUrl
())
.
load
(
user
.
getUserProfilePictureUrl
())
.
resize
(
800
,
0
)
.
resize
(
800
,
0
)
.
placeholder
(
R
.
drawable
.
user_placeholder
)
.
placeholder
(
R
.
drawable
.
user_placeholder
)
...
...
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