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
45884f4a
Commit
45884f4a
authored
Feb 05, 2019
by
Varun Patil
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add following map link
parent
7296bbc1
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
27 additions
and
4 deletions
+27
-4
app/src/main/AndroidManifest.xml
app/src/main/AndroidManifest.xml
+11
-0
app/src/main/java/app/insti/Constants.java
app/src/main/java/app/insti/Constants.java
+1
-0
app/src/main/java/app/insti/activity/MainActivity.java
app/src/main/java/app/insti/activity/MainActivity.java
+6
-0
app/src/main/java/app/insti/fragment/EventFragment.java
app/src/main/java/app/insti/fragment/EventFragment.java
+1
-4
app/src/main/java/app/insti/fragment/MapFragment.java
app/src/main/java/app/insti/fragment/MapFragment.java
+8
-0
No files found.
app/src/main/AndroidManifest.xml
View file @
45884f4a
...
...
@@ -76,6 +76,17 @@
android:pathPattern=
"/event/.*"
android:scheme=
"https"
/>
</intent-filter>
<intent-filter>
<action
android:name=
"android.intent.action.VIEW"
/>
<category
android:name=
"android.intent.category.DEFAULT"
/>
<category
android:name=
"android.intent.category.BROWSABLE"
/>
<data
android:host=
"insti.app"
android:pathPattern=
"/map/.*"
android:scheme=
"https"
/>
</intent-filter>
</activity>
<activity
android:name=
".activity.LoginActivity"
...
...
app/src/main/java/app/insti/Constants.java
View file @
45884f4a
...
...
@@ -55,6 +55,7 @@ public class Constants {
public
static
final
String
DATA_TYPE_USER
=
"userprofile"
;
public
static
final
String
DATA_TYPE_NEWS
=
"newsentry"
;
public
static
final
String
DATA_TYPE_PT
=
"blogentry"
;
public
static
final
String
DATA_TYPE_MAP
=
"map"
;
public
static
final
String
CARD_TYPE_TITLE
=
"card_type_title"
;
public
static
final
String
CARD_TYPE_BODY_HEAD
=
"card_type_body_head"
;
...
...
app/src/main/java/app/insti/activity/MainActivity.java
View file @
45884f4a
...
...
@@ -81,6 +81,7 @@ import retrofit2.Response;
import
static
app
.
insti
.
Constants
.
DATA_TYPE_BODY
;
import
static
app
.
insti
.
Constants
.
DATA_TYPE_EVENT
;
import
static
app
.
insti
.
Constants
.
DATA_TYPE_MAP
;
import
static
app
.
insti
.
Constants
.
DATA_TYPE_NEWS
;
import
static
app
.
insti
.
Constants
.
DATA_TYPE_PT
;
import
static
app
.
insti
.
Constants
.
DATA_TYPE_USER
;
...
...
@@ -336,6 +337,9 @@ public class MainActivity extends AppCompatActivity implements NavigationView.On
case
DATA_TYPE_NEWS:
updateFragment
((
new
NewsFragment
()).
withId
(
id
));
return
;
case
DATA_TYPE_MAP:
updateFragment
(
MapFragment
.
newInstance
(
id
));
return
;
}
Log
.
e
(
"NOTIFICATIONS"
,
"Server sent invalid notification?"
);
}
...
...
@@ -399,6 +403,8 @@ public class MainActivity extends AppCompatActivity implements NavigationView.On
return
DATA_TYPE_EVENT
;
case
"user"
:
return
DATA_TYPE_USER
;
case
"map"
:
return
DATA_TYPE_MAP
;
}
}
catch
(
MalformedURLException
ignored
)
{}
return
null
;
...
...
app/src/main/java/app/insti/fragment/EventFragment.java
View file @
45884f4a
...
...
@@ -242,10 +242,7 @@ public class EventFragment extends BackHandledFragment implements TransitionTarg
ClickableSpan
cs
=
new
ClickableSpan
()
{
@Override
public
void
onClick
(
@NonNull
View
widget
)
{
MapFragment
mapFragment
=
new
MapFragment
();
Bundle
bundle
=
new
Bundle
();
bundle
.
putString
(
Constants
.
MAP_INITIAL_MARKER
,
MapFragment
.
getPassableName
(
venue
.
getVenueShortName
()));
mapFragment
.
setArguments
(
bundle
);
MapFragment
mapFragment
=
MapFragment
.
newInstance
(
MapFragment
.
getPassableName
(
venue
.
getVenueShortName
()));
((
MainActivity
)
getActivity
()).
updateFragment
(
mapFragment
);
}
...
...
app/src/main/java/app/insti/fragment/MapFragment.java
View file @
45884f4a
...
...
@@ -257,6 +257,14 @@ public class MapFragment extends Fragment implements TextWatcher,
super
.
onResume
();
}
public
static
MapFragment
newInstance
(
String
location
)
{
Bundle
args
=
new
Bundle
();
args
.
putString
(
Constants
.
MAP_INITIAL_MARKER
,
location
);
MapFragment
fragment
=
new
MapFragment
();
fragment
.
setArguments
(
args
);
return
fragment
;
}
private
void
getAPILocations
()
{
RetrofitInterface
retrofitInterface
=
Utils
.
getRetrofitInterface
();
retrofitInterface
.
getAllVenues
().
enqueue
(
new
Callback
<
List
<
Venue
>>()
{
...
...
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