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

Mô Dev todo mvp tablet dialogfragment #670

Open
wants to merge 28 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
0a92311
Adds tablet mode, without tablet presenter
JoseAlcerreca Jul 25, 2016
e658d6c
Adds tablet mode, using a tablet presenter
JoseAlcerreca Jul 25, 2016
95794b8
Fixes tablet UI and uses retained fragments to save state.
JoseAlcerreca Jul 28, 2016
88d7afc
Cleaning, refactoring, testing, upgrading versions
JoseAlcerreca Jul 29, 2016
062998f
Resets README
JoseAlcerreca Jul 29, 2016
3da9736
Fixes some comments
JoseAlcerreca Jul 29, 2016
7ace7d3
Bumps versions and typo fix
JoseAlcerreca Aug 22, 2016
d678482
Fixes N7 NPE
JoseAlcerreca Sep 5, 2016
1e8d218
Sets retain instances to false and refactors the whole thing
JoseAlcerreca Nov 3, 2016
e822ec6
Renames the starting methods of presenters and fixes unit tests
JoseAlcerreca Nov 3, 2016
cd4daef
Fixes UI tests in non-EN locales
JoseAlcerreca Nov 4, 2016
edd28bf
Moves isTablet to utils and uses a listSelector for highlighting
JoseAlcerreca Nov 7, 2016
d1ecfd3
Build before pushing, kids
JoseAlcerreca Nov 7, 2016
0b1a71a
Merge pull request #131 from JoseAlcerreca/dev-todo-mvp-tablet-uberpr…
malmstein Nov 7, 2016
cf25f8c
Adds README to mvp-tablet
JoseAlcerreca Nov 8, 2016
626ea26
Shows a dialog instead of a new activity when adding or editing a task
JoseAlcerreca Nov 8, 2016
61760a9
Removes longclick edits task
JoseAlcerreca Nov 9, 2016
c4d17f4
The MVP controller is now only used in tablet mode
JoseAlcerreca Nov 10, 2016
158e5f3
restores scrollview to fix the coordinatorlayout behavior
JoseAlcerreca Nov 10, 2016
8dc13f6
Fixes the empty task case on tablet
JoseAlcerreca Nov 11, 2016
ea03e27
Update README.md
JoseAlcerreca Nov 14, 2016
c487af6
Adds an interface to show that a navigator could be moved out of the …
JoseAlcerreca Nov 15, 2016
3bc6e6f
Merge pull request #232 from googlesamples/JoseAlcerreca-tablet-readme
JoseAlcerreca Nov 22, 2016
0407433
Creates Tablet Navigator
JoseAlcerreca Nov 22, 2016
fd1da06
Merge remote-tracking branch 'origin/dev-todo-mvp-tablet' into dev-to…
JoseAlcerreca Nov 22, 2016
98baaa9
Merge remote-tracking branch 'origin/todo-mvp' into dev-todo-mvp-tablet
JoseAlcerreca Nov 22, 2016
decf037
Fixes merge issue with fab ids
JoseAlcerreca Nov 22, 2016
a502194
Merge branch 'dev-todo-mvp-tablet' into dev-todo-mvp-tablet_dialogfra…
JoseAlcerreca Nov 23, 2016
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Fixes some comments
  • Loading branch information
JoseAlcerreca committed Jul 29, 2016
commit 3da9736f61c683b1e771ccfdd02186b32a0a686e
2 changes: 1 addition & 1 deletion todoapp/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ android {
}
}

// Always show the onTasksResult of every unit test, even if it passes.
// Always show the result of every unit test, even if it passes.
testOptions.unitTests.all {
testLogging {
events 'passed', 'skipped', 'failed', 'standardOut', 'standardError'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@
/**
* Manages screens in tablet mode.
*/

public class TasksTabletNavigator {

private final FragmentActivity mFragmentActivity;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,10 @@ public View onCreateView(LayoutInflater inflater, ViewGroup container,
Bundle savedInstanceState) {
View root = inflater.inflate(R.layout.taskdetail_frag, container, false);
setHasOptionsMenu(true);
// TODO: why are we retaining

// Retain the fragment to persist the presenter and its state.
// This means that it won't be recreated on a configuration change, but
// it's dangerous as it can produce bugs and leaks. Use it wisely.
setRetainInstance(true);
mDetailTitle = (TextView) root.findViewById(R.id.task_detail_title);
mDetailDescription = (TextView) root.findViewById(R.id.task_detail_description);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,9 @@ public View onCreateView(LayoutInflater inflater, ViewGroup container,
Bundle savedInstanceState) {
View root = inflater.inflate(R.layout.tasks_frag, container, false);

// Retain the fragment to persist the presenter and its state. Use it wisely.
// Retain the fragment to persist the presenter and its state.
// This means that it won't be recreated on a configuration change, but
// it's dangerous as it can produce bugs and leaks. Use it wisely.
setRetainInstance(true);

// Set up tasks view
Expand Down Expand Up @@ -148,7 +150,7 @@ public void onClick(View v) {
ContextCompat.getColor(getActivity(), R.color.colorPrimaryDark)
);
// Set the scrolling view in the custom SwipeRefreshLayout.
swipeRefreshLayout.setScrollUpChild(listView);
swqipeRefreshLayout.setScrollUpChild(listView);

swipeRefreshLayout.setOnRefreshListener(new SwipeRefreshLayout.OnRefreshListener() {
@Override
Expand Down