Skip to content

Reader second pass: detail view redesign, refactoring, and improvement#716

Merged
mikejohnstn merged 44 commits intodevelopfrom
feature/602-reader-detail
Dec 6, 2013
Merged

Reader second pass: detail view redesign, refactoring, and improvement#716
mikejohnstn merged 44 commits intodevelopfrom
feature/602-reader-detail

Conversation

@mikejohnstn
Copy link
Contributor

For #602 in absence of a new design for the detail view, I reused the same design we're using for the Reader list view. This reuse is both in the UI and in code. We have a new ReaderPostView that can be reused/embedded elsewhere in the future, e.g. as a way to view your own posts. This view can toggle between showing a summary, and showing the full content of the post. It works on iPhone and iPad, so this also improves the detail view on iPad.

Along the way I did a bunch of refactoring to remove redundancies, move handlers out of views and into controllers, and general cleanup. The following additional issues will be resolved as a result: #416, #620, #645, #704.

Worth highlighting is a trick to preload images before they're visible. The approach (which @tomwitkin learned from another developer) is to use a UITableView that is taller than the screen. The cost is additional maintenance of that modified height. We'll need to watch for bugs resulting from this trick, e.g. I had to fix the reblog form positioning.

readerdetail

Video:
https://cloudup.com/cOvyJ9eWoou

mikejohnstn and others added 30 commits November 19, 2013 21:41
- Moved the view hierarchy and layout logic to ReaderPostView
- Gutted ReaderPostTableViewCell and made it use ReaderPostView instead
Conflicts:
	WordPress/Classes/ReaderPostDetailView.m
	WordPress/Classes/ReaderPostDetailViewController.h
	WordPress/Classes/ReaderPostDetailViewController.m
	WordPress/Classes/ReaderPostTableViewCell.m
	WordPress/WordPress.xcodeproj/project.pbxproj
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These keyboard size adjustment methods are crufty. Once we move to translucent bars throughout the app, we should do a full pass and purge as many of these as possible.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pretty much all of this code was moved from elsewhere.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yay!

@astralbodies
Copy link
Contributor

This looks really great on the device, @mikejohnstn. Let me know if you want to discuss the code feedback I gave.

Conflicts:
	WordPress/Classes/ReaderPostsViewController.m
	WordPress/WordPress.xcodeproj/project.pbxproj
@astralbodies
Copy link
Contributor

:shipit: sir!

mikejohnstn added a commit that referenced this pull request Dec 6, 2013
Reader second pass: detail view redesign, refactoring, and improvement
@mikejohnstn mikejohnstn merged commit 566ef37 into develop Dec 6, 2013
@mikejohnstn mikejohnstn deleted the feature/602-reader-detail branch December 6, 2013 19:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants