-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from TheAlphamerc/develop
merge develop branch to master
- Loading branch information
Showing
28 changed files
with
1,303 additions
and
867 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,3 +2,4 @@ org.gradle.jvmargs=-Xmx1536M | |
|
||
android.useAndroidX=true | ||
android.enableJetifier=true | ||
android.enableR8=true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,5 +5,6 @@ enum AuthStatus { | |
} | ||
enum TweetType{ | ||
Tweet, | ||
Detail, | ||
Reply | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
import 'package:flutter/material.dart'; | ||
import '../page/Auth/signin.dart'; | ||
import '../helper/customRoute.dart'; | ||
import '../page/feed/createFeed.dart'; | ||
import '../page/feed/imageViewPage.dart'; | ||
import '../page/SearchPage.dart'; | ||
import '../page/Auth/forgetPasswordPage.dart'; | ||
import '../page/Auth/signin.dart'; | ||
import '../page/Auth/signup.dart'; | ||
import '../page/feed/feedPostDetail.dart'; | ||
import '../page/feed/feedPostreply.dart'; | ||
import '../page/profile/EditProfilePage.dart'; | ||
import '../page/message/chatScreenPage.dart'; | ||
import '../page/profile/profilePage.dart'; | ||
import '../widgets/customWidgets.dart'; | ||
|
||
class Routes{ | ||
static Route onGenerateRoute(RouteSettings settings) { | ||
final List<String> pathElements = settings.name.split('/'); | ||
if (pathElements[0] != '' || pathElements.length == 1) { | ||
return null; | ||
} | ||
if(pathElements[1].contains('SignIn')){ | ||
return CustomRoute<bool>(builder:(BuildContext context)=> SignIn()); | ||
} | ||
else if(pathElements[1].contains('SignUp')){ | ||
return CustomRoute<bool>(builder:(BuildContext context)=> Signup()); | ||
} | ||
else if(pathElements[1].contains('SearchPage')){ | ||
return CustomRoute<bool>(builder:(BuildContext context)=> SearchPage()); | ||
} | ||
else if(pathElements[1].contains('CreateFeedPage')){ | ||
return CustomRoute<bool>(builder:(BuildContext context)=> CreateFeedPage()); | ||
} | ||
else if(pathElements[1].contains('FeedPostReplyPage')){ | ||
var postId = pathElements[2]; | ||
return CustomRoute<bool>(builder:(BuildContext context)=> FeedPostReplyPage(postId: postId,)); | ||
} | ||
else if(pathElements[1].contains('FeedPostDetail')){ | ||
var postId = pathElements[2]; | ||
return CustomRoute<bool>(builder:(BuildContext context)=> FeedPostDetail(postId: postId,)); | ||
} | ||
else if(pathElements[1].contains('ForgetPasswordPage')){ | ||
return CustomRoute<bool>(builder:(BuildContext context)=> ForgetPasswordPage()); | ||
} | ||
else if(pathElements[1].contains('ImageViewPge')){ | ||
return CustomRoute<bool>(builder:(BuildContext context)=> ImageViewPge()); | ||
} | ||
else if(pathElements[1].contains('ProfilePage')){ | ||
String profileId; | ||
if(pathElements.length > 2){ | ||
profileId = pathElements[2]; | ||
} | ||
return CustomRoute<bool>(builder:(BuildContext context)=> ProfilePage(profileId: profileId,)); | ||
} | ||
else if(pathElements[1].contains('EditProfile')){ | ||
return CustomRoute<bool>(builder:(BuildContext context)=> EditProfilePage()); | ||
} | ||
else if(pathElements[1].contains('ChatScreenPage')){ | ||
return CustomRoute<bool>(builder:(BuildContext context)=> ChatScreenPage()); | ||
} | ||
} | ||
|
||
static Route onUnknownRoute(RouteSettings settings){ | ||
return MaterialPageRoute( | ||
builder: (_) => Scaffold( | ||
appBar: AppBar(title: customTitleText(settings.name.split('/')[1]),centerTitle: true,), | ||
body: Center( | ||
child: Text('${settings.name.split('/')[1]} Comming soon..'), | ||
), | ||
), | ||
); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.