Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Develop #83

Merged
merged 60 commits into from
Nov 30, 2017
Merged
Show file tree
Hide file tree
Changes from 7 commits
Commits
Show all changes
60 commits
Select commit Hold shift + click to select a range
5c019fb
fix: [ #27 ] Current location will be set when app starts
CloudyPadmal Mar 30, 2017
64286b2
Merge pull request #29 from CloudyPadmal/currentLocation
Dilu9218 Apr 12, 2017
4473920
Added the switch activity switching between private and public reposi…
icancode23 Jun 19, 2017
81f2eed
resolving conflicts
icancode23 Jun 19, 2017
3a78807
Merge branch 'master' into develop
icancode23 Jun 19, 2017
26b85ae
ignore google services
icancode23 Jun 19, 2017
eb9d22b
added the original google services json
icancode23 Jun 19, 2017
f125c79
Minor change Switch activity for public and private vehicles ready
icancode23 Jun 19, 2017
4639492
Added the HomeBaseScreen
icancode23 Jun 19, 2017
5f86b14
Facebook profile extracted person registered as a user in firebase db
icancode23 Jun 23, 2017
ae64dfa
Merge pull request #70 from KuteGSOC/HomeBaseScreen
NickHub4017 Jun 23, 2017
af7dd27
Added Feature for Friend Profile Viewing also improved fragment flow…
icancode23 Jun 25, 2017
db1049a
Replaced google services json and removed my own keys
icancode23 Jun 25, 2017
e3dd479
Code Refactor to remove unnecessary spaces between brackets and unne…
icancode23 Jun 26, 2017
2c30d1d
Replaced google services json and removed my own keys
icancode23 Jun 26, 2017
6d18f95
Merge pull request #71 from KuteGSOC/ConnectViewFriends
NickHub4017 Jun 30, 2017
ab5d123
Some Changes
icancode23 Jul 3, 2017
cc50fe7
Added the feature for custom profile Image
icancode23 Jul 3, 2017
377c596
Changed the layout a bit
icancode23 Jul 3, 2017
b4fa3f9
minor change
icancode23 Jul 5, 2017
44e7266
check
icancode23 Jul 5, 2017
e3df3b7
minor change
icancode23 Jul 5, 2017
a4eb9bd
minor change
icancode23 Jul 5, 2017
d610803
Completed profile edit without integrating edit profile image
icancode23 Jul 6, 2017
14af78b
Merge pull request #72 from KuteGSOC/ProfilePictureEdit
NickHub4017 Jul 7, 2017
35af0b9
midway
icancode23 Jul 7, 2017
f5ed115
Replaced google services and removed self ids from strings
icancode23 Jul 7, 2017
2c303cd
few changes
icancode23 Jul 7, 2017
31bd401
dialog layouts done
icancode23 Jul 7, 2017
fffefde
Deleted some test data sent to git by mistake
icancode23 Jul 7, 2017
4418eac
Complete But not tested
icancode23 Jul 9, 2017
bd86bf1
Dynamic loading of friends using a pull to load recycler view
icancode23 Jul 11, 2017
b4d654e
minor change
icancode23 Jul 12, 2017
11b210e
Merge pull request #73 from KuteGSOC/UserSelfProfileFilling
NickHub4017 Jul 14, 2017
60dff52
small fix
icancode23 Jul 17, 2017
4139a2c
Support for base64 in recycler
icancode23 Jul 21, 2017
9ac333c
replaced google services json
icancode23 Jul 22, 2017
6f7bb5e
fix
icancode23 Jul 22, 2017
7d9e9f8
fix
icancode23 Jul 22, 2017
ef597b2
fix
icancode23 Jul 22, 2017
742ab5c
fix
icancode23 Jul 22, 2017
a73774b
Merge pull request #75 from KuteGSOC/WorkflowFix
NickHub4017 Jul 22, 2017
45a03f5
added routes backend
icancode23 Aug 3, 2017
c75a11d
added routes backend
icancode23 Aug 3, 2017
c65ff11
Merge pull request #76 from KuteGSOC/routesBackend
NickHub4017 Aug 4, 2017
ba5d489
check
icancode23 Aug 13, 2017
f7c04e6
Majorly Complete
icancode23 Aug 21, 2017
64d2e67
Majorly Complete
icancode23 Aug 21, 2017
061a655
Added backend project
icancode23 Aug 21, 2017
b94523a
Added backend project
icancode23 Aug 21, 2017
f0a44f6
Added backend project
icancode23 Aug 21, 2017
e8360b0
Added Send Notification end point on server
icancode23 Aug 22, 2017
7e687e7
Added Send Notification end point on server
icancode23 Aug 22, 2017
67fed75
Merge pull request #77 from KuteGSOC/TripUI
NickHub4017 Aug 23, 2017
dec96c8
Beta Done and completed
icancode23 Aug 26, 2017
b68a026
Beta Done and completed
icancode23 Aug 26, 2017
512d728
Beta Backend
icancode23 Aug 26, 2017
07cd0a8
Beta Backend
icancode23 Aug 26, 2017
ddf5023
Merge pull request #78 from KuteGSOC/BetaComplete
NickHub4017 Aug 26, 2017
b123d3e
Merge branch 'master' into develop
NickHub4017 Nov 30, 2017
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
The diff you're trying to view is too large. We only load the first 3000 changed files.
18 changes: 11 additions & 7 deletions kute-android-app/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -36,19 +36,23 @@ dependencies {



compile 'com.google.firebase:firebase-core:10.0.1'
compile 'com.google.firebase:firebase-auth:10.0.1'
compile 'com.google.firebase:firebase-database:10.0.1'
compile 'com.google.android.gms:play-services-auth:10.0.1'
compile 'com.google.android.gms:play-services-plus:10.0.1'
compile 'com.google.android.gms:play-services-maps:10.0.1'
compile 'com.google.android.gms:play-services-location:10.0.1'
compile 'com.google.firebase:firebase-core:11.0.1'
compile 'com.google.firebase:firebase-auth:11.0.1'
compile 'com.google.firebase:firebase-database:11.0.1'
compile 'com.google.android.gms:play-services-auth:11.0.1'
compile 'com.google.android.gms:play-services-plus:11.0.1'
compile 'com.google.android.gms:play-services-maps:11.0.1'
compile 'com.google.android.gms:play-services-location:11.0.1'
compile 'com.google.android.gms:play-services-places:11.0.1'
compile 'com.facebook.android:facebook-android-sdk:4.25.0'
compile 'com.android.volley:volley:1.0.0'
compile 'com.android.support:appcompat-v7:25.1.1'
compile 'com.android.support:design:25.1.1'
compile 'de.hdodenhof:circleimageview:2.1.0'
compile 'com.android.support.constraint:constraint-layout:1.0.2'
compile 'org.osmdroid:osmdroid-android:5.6.4'
compile 'com.google.firebase:firebase-messaging:11.0.1'
compile 'com.google.firebase:firebase-core:11.0.1'
testCompile 'junit:junit:4.12'
}

Expand Down
179 changes: 98 additions & 81 deletions kute-android-app/app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,86 +4,103 @@
package="com.scorelab.kute.kute">


<uses-permission android:name="android.permission.GET_ACCOUNTS" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"></uses-permission>
<uses-permission android:name="android.permission.CAMERA"/>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
<uses-feature
android:name="android.hardware.camera"
android:required="false" />
<uses-feature
android:name="android.hardware.camera.autofocus"
android:required="false" />
<uses-feature
android:name="android.hardware.camera.flash"
android:required="false" />

<application
android:name=".KuteApplication"
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
<uses-permission android:name="android.permission.GET_ACCOUNTS"/>
<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"></uses-permission>
<uses-permission android:name="android.permission.CAMERA"/>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
<uses-feature
android:name="android.hardware.camera"
android:required="false"/>
<uses-feature
android:name="android.hardware.camera.autofocus"
android:required="false"/>
<uses-feature
android:name="android.hardware.camera.flash"
android:required="false"/>

<application
android:name=".KuteApplication"
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:supportsRtl="true"
android:theme="@style/AppTheme">
<meta-data
android:name="com.facebook.sdk.ApplicationId"
android:value="@string/facebook_app_id"/>
<meta-data
android:name="com.google.android.geo.API_KEY"
android:value="@string/googlemapApi"/>

<activity android:name=".SplashActivity">
<intent-filter>
<action android:name="android.intent.action.MAIN" />

<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity android:name=".Activity.RegisterActivity">
</activity>
<activity
android:name="com.facebook.FacebookActivity"
android:configChanges="keyboard|keyboardHidden|screenLayout|screenSize|orientation"
android:label="@string/app_name"
android:supportsRtl="true"
/>
<activity android:name=".Activity.MainActivity">
</activity>
<activity
android:name=".LandActivity"
android:label="@string/title_activity_land"
android:theme="@style/AppTheme">
<meta-data
android:name="com.facebook.sdk.ApplicationId"
android:value="@string/facebook_app_id"/>
<meta-data
android:name="com.google.android.geo.API_KEY"
android:value="@string/googlemapApi"/>

<activity android:name=".SplashActivity">
<intent-filter>
<action android:name="android.intent.action.MAIN" />

<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity android:name=".Activity.RegisterActivity">
</activity>
<activity
android:name="com.facebook.FacebookActivity"
android:configChanges="keyboard|keyboardHidden|screenLayout|screenSize|orientation"
android:label="@string/app_name"
/>
<activity android:name=".Activity.MainActivity">
</activity>
<activity
android:name=".LandActivity"
android:label="@string/title_activity_land"
android:theme="@style/AppTheme">
</activity>
<activity android:name=".Activity.TaskSelection"/>
<activity android:name=".Activity.VehicleSelection"/>

<service
android:name=".Services.BacKService"
android:process=":backservice"/>

<activity android:name=".Activity.SwitchPrivatePublicActivity"/>
<activity android:name=".PrivateVehicles.App.Activities.Main"/>
<activity android:name=".PrivateVehicles.App.Activities.CurrentFriendList"/>

<service android:name=".PrivateVehicles.App.Services.SyncFacebookFriendsToFirebase"/>

<activity android:name=".PrivateVehicles.App.Activities.PersonDetail"
android:screenOrientation="portrait"/> <!-- to avoid memory leaks via screen orientation change -->

<activity android:name=".PrivateVehicles.App.Activities.ProfilePictureActivity"/>
<activity android:name=".PrivateVehicles.App.Activities.InitialDetailDialogs">

</activity>
<activity android:name=".PrivateVehicles.App.Activities.Routes.SelfRouteDetailActivity">

</activity>
<activity android:name=".PrivateVehicles.App.Activities.Routes.AddRouteActivity">

</activity>
<activity android:name=".PrivateVehicles.App.Activities.Routes.RouteDetail"/>
<activity android:name=".PrivateVehicles.App.Activities.Utils.DaysPicker"/>
<activity android:name=".PrivateVehicles.App.Activities.Routes.RouteListPerson"/>

</application>

</manifest>
</activity>
<activity android:name=".Activity.TaskSelection"/>
<activity android:name=".Activity.VehicleSelection"/>

<service
android:name=".Services.BacKService"
android:process=":backservice"/>

<activity android:name=".Activity.SwitchPrivatePublicActivity"/>
<activity android:name=".PrivateVehicles.App.Activities.Main"/>
<activity android:name=".PrivateVehicles.App.Activities.CurrentFriendList"/>

<service android:name=".PrivateVehicles.App.Services.SyncFacebookFriendsToFirebase"/>

<activity android:name=".PrivateVehicles.App.Activities.PersonDetail"
android:screenOrientation="portrait"/> <!-- to avoid memory leaks via screen orientation change -->

<activity android:name=".PrivateVehicles.App.Activities.ProfilePictureActivity"/>
<activity android:name=".PrivateVehicles.App.Activities.InitialDetailDialogs">

</activity>
<activity android:name=".PrivateVehicles.App.Activities.Routes.SelfRouteDetailActivity">

</activity>
<activity android:name=".PrivateVehicles.App.Activities.Routes.AddRouteActivity">

</activity>
<activity android:name=".PrivateVehicles.App.Activities.Routes.RouteDetail"/>
<activity android:name=".PrivateVehicles.App.Activities.Utils.DaysPicker"/>
<activity android:name=".PrivateVehicles.App.Activities.Routes.RouteListPerson"/>
<activity android:name=".PrivateVehicles.App.Activities.Travel.StartRide">

</activity>
<activity android:name=".PrivateVehicles.App.Activities.Travel.AddTrip"/>
<activity android:name=".PrivateVehicles.App.Activities.Travel.GetSeatsInfo"/>

<service android:name=".PrivateVehicles.App.Services.MyFirebaseInstanceIDService">
<intent-filter>
<action android:name="com.google.firebase.INSTANCE_ID_EVENT"/>
</intent-filter>
</service>
<service android:name=".PrivateVehicles.App.Services.MyFirebaseMessagingService">
<intent-filter>
<action android:name="com.google.firebase.MESSAGING_EVENT"/>
</intent-filter>
</service>

</application>

</manifest>

Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@
import com.google.android.gms.tasks.OnFailureListener;
import com.google.firebase.database.DatabaseReference;
import com.google.firebase.database.FirebaseDatabase;
import com.google.firebase.iid.FirebaseInstanceId;
import com.google.firebase.iid.FirebaseInstanceIdService;
import com.scorelab.kute.kute.LandActivity;
import com.scorelab.kute.kute.PrivateVehicles.App.Activities.InitialDetailDialogs;
import com.scorelab.kute.kute.PrivateVehicles.App.Activities.Main;
Expand Down Expand Up @@ -96,7 +98,7 @@ public void onClick(View v) {
/**************** Custom Functions Invoked only once on app installation *******/

public void registerFirebaseDbSelf(final SharedPreferences pref) {
Person temp = new Person(pref.getString("Name", null), pref.getString("Id", null), pref.getString("Profile_Image", null));
Person temp = new Person(pref.getString("Name", null), pref.getString("Id", null), pref.getString("Profile_Image", null), FirebaseInstanceId.getInstance().getToken());
DatabaseReference root = FirebaseDatabase.getInstance().getReference();
DatabaseReference users = root.child("Users");
Log.d(TAG, "Saving Self To db");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,13 +35,19 @@ public class CurrentFriendList extends AppCompatActivity implements RecyclerItem
ProgressBar progressBar;
boolean is_async_task_running=false;// A boolean created to prevent a new asynctask being created everytime we scroll down
LoadFirebaseFriends load_friends_async;
String source;
@Override
protected void onCreate(@Nullable Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.current_friends_activity);

person_list = (ArrayList<String>)getIntent().getSerializableExtra("FriendList");
person_detail_list=(ArrayList<Person>) getIntent().getSerializableExtra("FriendDetailList");
source=(String) getIntent().getSerializableExtra("Source");
if(source.equals("Trip"))
recycler_adapter = new FriendRecyclerAdapter("Travelling With",person_detail_list, this, this);
else
recycler_adapter = new FriendRecyclerAdapter("Current Friends",person_detail_list, this, this);
/************** Initialise the views *********/
//TODO get friends from facebook and google and get their images
Log.d(TAG,"The length of the person list is:"+Integer.toString(person_list.size()));
Expand All @@ -54,7 +60,7 @@ public void onClick(View v) {
}
});
friend_recycler = (RecyclerView) findViewById(R.id.personRecycler);
recycler_adapter = new FriendRecyclerAdapter(person_detail_list, this, this);

final android.support.v7.widget.LinearLayoutManager mLayoutManager = new LinearLayoutManager(getApplicationContext());
friend_recycler.setLayoutManager(mLayoutManager);
friend_recycler.setItemAnimator(new DefaultItemAnimator());
Expand All @@ -64,17 +70,21 @@ public void onClick(View v) {
public void onScrolled(RecyclerView recyclerView,
int dx, int dy) {
super.onScrolled(recyclerView, dx, dy);
visibleItemCount[0] = mLayoutManager.getChildCount();//Gives the number of children currently on the screen
totalItemCount[0] = mLayoutManager.getItemCount();//gives total items of recycler view
pastVisiblesItems[0] = mLayoutManager.findFirstVisibleItemPosition();//gives the index of item at the top of the screen
Log.d("Recycler",String.format("visible %d past visible %d total %d",visibleItemCount[0],pastVisiblesItems[0],totalItemCount[0]));
if ((visibleItemCount[0] + pastVisiblesItems[0]) >= totalItemCount[0]&& visibleItemCount[0]!=totalItemCount[0] ) {
if(mLayoutManager.findLastCompletelyVisibleItemPosition()==recycler_adapter.getItemCount()-1 /*&& recycleradapter.getItemCount()>5 You have your ofset values here*/){
//************************* Reached the End of recycler View ***********/
Log.d(TAG,"reached the Bottom");
//******************** Call The function to load more data *********//
loadRecyclerItems(recycler_adapter.getItemCount()-1);
try {
visibleItemCount[0] = mLayoutManager.getChildCount();//Gives the number of children currently on the screen
totalItemCount[0] = mLayoutManager.getItemCount();//gives total items of recycler view
pastVisiblesItems[0] = mLayoutManager.findFirstVisibleItemPosition();//gives the index of item at the top of the screen
Log.d("Recycler", String.format("visible %d past visible %d total %d", visibleItemCount[0], pastVisiblesItems[0], totalItemCount[0]));
if ((visibleItemCount[0] + pastVisiblesItems[0]) >= totalItemCount[0] && visibleItemCount[0] != totalItemCount[0]) {
if (mLayoutManager.findLastCompletelyVisibleItemPosition() == recycler_adapter.getItemCount() - 1 /*&& recycleradapter.getItemCount()>5 You have your ofset values here*/) {
//************************* Reached the End of recycler View ***********/
Log.d(TAG, "reached the Bottom");
//******************** Call The function to load more data *********//
loadRecyclerItems(recycler_adapter.getItemCount() - 1);
}
}
}catch (Exception e){
Log.d(TAG,"Exception in OnScroll "+e.toString());
}
}
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@ protected void onCreate(Bundle savedInstanceState) {
setContentView(R.layout.activity_main);
route_request_number = (TextView) findViewById(R.id.numberRouteRequests);
route_request=(ImageButton)findViewById(R.id.routeRequests);
search=(ImageButton)findViewById(R.id.searchIcon);
Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar);
setSupportActionBar(toolbar);
getSupportActionBar().setDisplayShowTitleEnabled(false);
Expand Down Expand Up @@ -114,16 +113,16 @@ public void onBackPressed() {
private void setupProfileFragment()
{
getSupportFragmentManager().beginTransaction().replace(R.id.frameDrawer, new UserSelfProfileFragment(), "UserSelfProfileFragment").commit();
search.setImageResource(R.drawable.ic_mode_edit_white_24dp);
route_request.setImageResource(R.drawable.ic_mode_edit_white_24dp);
route_request_number.setVisibility(View.GONE);
route_request.setVisibility(View.GONE);

}

private void setupHomeFragment(){
getSupportFragmentManager().beginTransaction().replace(R.id.frameDrawer, new HomeBaseFragment(), "HomeBaseFragment").commit();
search.setImageResource(R.drawable.ic_search_white_24dp);
route_request.setImageResource(R.drawable.ic_search_white_24dp);
route_request_number.setVisibility(View.VISIBLE);
route_request.setVisibility(View.VISIBLE);

}

}
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ private void fillPersonDetails() {
//setting up the routes detail of a person
private void setupRoutesRow(){
load_routes=new LoadPersonRoutesAsyncTask(this);
load_routes.execute(p.name);
load_routes.execute(p.id);
view_all_routes=(AppCompatButton)findViewById(R.id.viewAllRoutes);
view_all_routes.setOnClickListener(this);
view_all_routes.setEnabled(false);
Expand Down
Loading